Welcome to NeoOffice developer notes and announcements
NeoOffice
Developer notes and announcements
 
 

This website is an archive and is no longer active
NeoOffice announcements have moved to the NeoOffice News website


Support
· Forums
· NeoOffice Support
· NeoWiki


Announcements
· Twitter @NeoOffice


Downloads
· Download NeoOffice


  
NeoOffice :: View topic - Versions implementation
Versions implementation
 
   NeoOffice Forum Index -> NeoOffice New Feature Requests
View previous topic :: View next topic  
Author Message
OldStevenick
Agent


Joined: Sep 03, 2011
Posts: 17

PostPosted: Sat Sep 03, 2011 4:46 am    Post subject: Versions implementation

Hi, will you be able to show more of a document in Versions? Right now it only shows the first page, and so for a longer document it doesn't help me decide what to restore.

TextEdit's implementation allows scrolling within the versions display.
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Sat Sep 03, 2011 9:13 am    Post subject:

Apple's new Versions feature displays only the Quick Look previews for each past version. Since NeoOffice creates Quick Look previews when the document is saved, the bad news is that there is no way to change the previews that you see in versions that you saved in the past.

However, it is feasible for us to add an option in NeoOffice that causes a Quick Look preview of all pages in your document to be created when you save. To implement this option, we would replace the NeoOffice :: Mac OS X Options :: Disable Quick Look Support in Documents menu with a new NeoOffice :: Mac OS X Options :: Quick Look Support in Documents menu that has the following 3 menu items:

- None
- First page only
- All pages

The "First page only" menu item would remain the default option but selecting the "All pages" menu item would create a Quick Look preview of your entire document every time you save any documents.

This is fairly simple to implement but before I create a test patch, I would like to hear if anyone sees any big problems with this expanded Quick Look support. The only issue that I see is that embedding a full PDF for a very large document can slow down saving and create a very large document file. Are there any issues that anyone else sees?

Patrick
Back to top
OldStevenick
Agent


Joined: Sep 03, 2011
Posts: 17

PostPosted: Sat Sep 03, 2011 9:45 am    Post subject:

Very cool Patrick.

How does TextEdit do it then? It seems to have a scrolling preview.

Steve
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Sat Sep 03, 2011 3:54 pm    Post subject:

OldStevenick wrote:
How does TextEdit do it then? It seems to have a scrolling preview.


TextEdit uses a different approach for rendering Quick Look previews than NeoOffice. Instead of displaying a prerendered PDF file embedded in your document, TextEdit scans the contents of your document and renders its QuickLook preview immediately.

While TextEdit's approach in many cases, it has some limitations. One is that TextEdit's Quick Look plugin skips complex layout objects like headers, footers, columns, and images. As a result, you will only see a "rough rendering" of only text in your NeoOffice Writer documents with TextEdit's plugin. Another limitation is that TextEdit's plugin cannot handle NeoOffice Calc, Impress, or Math files at all.

Give these limitations in TextEdit's approach, instead of Quick Look rendering "on the fly" we used NeoOffice's built-in "save as PDF" feature to create a high resolution, accurate snapshot of your document each time you save. We limited the PDF snapshot to only one page because in Mac OS X 10.5 and 10.6, Quick Look previews were used by most users only as replacements for icons in the Finder and on the Desktop so there was little benefit of bloating your document's file size and lengthening the time to save your document until Mac OS X 10.7 started using these previews in its new Versions feature.

Patrick
Back to top
djpimley
The Anomaly
(earlier version)


Joined: Jun 11, 2006
Posts: 481
Location: Great Britain

PostPosted: Sat Sep 03, 2011 3:55 pm    Post subject:

I'm in favour. I assume the default behaviour would be first page only.

I wonder if it's possible (and desirable) to do this: save a preview of only the single page that the cursor is on at the time of saving. This would be fast but also more likely to capture recent changes in the preview.
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Sat Sep 03, 2011 6:43 pm    Post subject:

djpimley wrote:
I'm in favour. I assume the default behaviour would be first page only.


Yes. The default would be the same as now: first page only.

djpimley wrote:
I wonder if it's possible (and desirable) to do this: save a preview of only the single page that the cursor is on at the time of saving. This would be fast but also more likely to capture recent changes in the preview.


Unfortunately, this is not possible. We are limited to the options in the dialog that is displayed when you select the File :: Export as PDF menu. The only thing close is "Selection" but I do not recommend that we include this option as it can produce widely different results each time you save and, if nothing is selected, can produce an empty PDF.

Patrick
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Sun Sep 04, 2011 10:33 am    Post subject:

Below are the new menus and menu items that will replace the existing NeoOffice :: Mac OS X Options :: Disable Quick Look Support in Documents menu. Any corrections to my translations or translations for other languages are definitely appreciated:

English
New menu
- NeoOffice :: Mac OS X Options :: Quick Look Support in Documents
New submenus
- Disabled
- Only the First Page
- All Pages

German
New menu
- NeoOffice :: Mac OS X Options :: Übersicht Unterstützung für Dokumente
New submenus
- Deaktiviert
- Nur die erste Seite
- Alle Seiten

Dutch
New menu
- NeoOffice :: Mac OS X Options :: Ondersteuning voor Quick Look in documenten
New submenus
- Uitgeschakeld
- Alleen de eerste pagina
- Alle pagina's


Last edited by pluby on Mon Sep 05, 2011 5:45 pm; edited 1 time in total
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Mon Sep 05, 2011 5:43 pm    Post subject:

FYI. I have implemented the option to embed a Quick Look preview of all pages into a document when saving.

If anyone can install the following test patch, select the NeoOffice :: Mac OS X Options :: Quick Look Support in Documents :: All Pages menu, and save a few documents, do the documents now show the entire document in Quick Look previews? Also, if you are running Mac OS X 10.7 Lion, do the newly saved versions show the entire document?:

Intel:
http://joe.neooffice.org/test/NeoOffice-3.2.1-Patch-0-Test-1-Intel.dmg

Patrick
Back to top
OldStevenick
Agent


Joined: Sep 03, 2011
Posts: 17

PostPosted: Tue Sep 06, 2011 6:32 am    Post subject:

First off I want to say I discovered NeoOffice when Lion came out and you'd supported these features. It's a great program and I'll happily contribute. Your responsiveness is fantastic. THANKS!!!!!

OK, I installed the patch and it works. It does however make saving VERY slow. 1 1/2 minutes on a 600kb Calc file. It saves quickly then I get the spinner while presumably the PDF is being created. If this could happen in the background it would be great, otherwise the slowdown is probably just too much to make it desirable.

In addition of course the PDF's are paginated which for a Calc file makes them awkward as you can't scroll to the right.
Back to top
OldStevenick
Agent


Joined: Sep 03, 2011
Posts: 17

PostPosted: Tue Sep 06, 2011 7:06 am    Post subject:

Followup.

Tested on a text document and it works much better and much faster. 9 seconds for an 835Kb doc.

Totally usable and great for this.

Unfortunately for me most of my work is on fairly simple calc docs.
Back to top
ovvldc
Captain Naiobi


Joined: Sep 13, 2004
Posts: 2352
Location: Zürich, CH

PostPosted: Tue Sep 06, 2011 7:23 am    Post subject:

For the Dutch translation, the menu is called 'Mac OS X opties' in vanilla 3.2.1, and I think that should stay. But you probably just copied the English version for convenience.

As for the extra time and space this new option needs, I think that was exactly why it used to be done for the first page only. You can't have it both ways.

Best wishes,
Oscar

_________________
"What do you think of Western Civilization?"
"I think it would be a good idea!"
- Mohandas Karamchand Gandhi
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Tue Sep 06, 2011 7:31 am    Post subject:

ovvldc wrote:
For the Dutch translation, the menu is called 'Mac OS X opties' in vanilla 3.2.1, and I think that should stay. But you probably just copied the English version for convenience.


Your assumption is correct: I copied and pasted the English in my post and only forgot to copy the "Mac OS X Options" translations from the NeoOffice code into my post.

Patrick
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Tue Sep 06, 2011 7:52 am    Post subject:

OldStevenick wrote:
OK, I installed the patch and it works. It does however make saving VERY slow. 1 1/2 minutes on a 600kb Calc file. It saves quickly then I get the spinner while presumably the PDF is being created. If this could happen in the background it would be great, otherwise the slowdown is probably just too much to make it desirable.


Due to file locking issues, saving in the background is not possible. All saving in NeoOffice can only be done in the foreground.

Since you mentioned that a different file only took 9 seconds, I suspect that the slow document has some special print settings that are make PDF generation slow. Would you be able to attach a slow document so that we can see if there is anything obvious that is causing the slowness?

If so, you can attach files to your post using the instructions in this forum topic.

OldStevenick wrote:
In addition of course the PDF's are paginated which for a Calc file makes them awkward as you can't scroll to the right.


Essentially, you are asking for an "on the fly" spreadsheet renderer. As I mentioned in my first post, Apple's TextEdit uses this approach and has only been able to handle very simple Writer documents so this approach definitely has limitations.

Basically, previewing each Calc version using the "on the fly" approach would at best take as long as opening the Calc document in NeoOffice. Also, implementing the "on the fly" approach would be a massive project as we would have to duplicate most of the massive amount of NeoOffice code and force such code to work within the contraints imposed on Quick Look plugins. Essentially, implementing an "on the fly" Calc Quick Look plugin is almost as difficult as implementing an iPad version of NeoOffice. Sad

Patrick
Back to top
OldStevenick
Agent


Joined: Sep 03, 2011
Posts: 17

PostPosted: Tue Sep 06, 2011 8:02 am    Post subject:

Thanks Patrick, I understand.

The 9 seconds was a text document. The calc docs seem to take longer. I can accept this limitation and turn it on and off when needed if necessary.

The one I tested doesn't have any charts or special anything, but it is about 1,000 lines long. It does have borders around every cell pretty much and some colors.

I don't want to post it publicly as it has personal info. If you want to see it and I can send it to you only I'd do that.

Steve
Back to top
OldStevenick
Agent


Joined: Sep 03, 2011
Posts: 17

PostPosted: Tue Sep 06, 2011 8:07 am    Post subject:

Tested again with another Calc document and it only took 15 seconds.

245Kb doc with thousands of lines and multiple sheets.

No borders, no color. So that must be the issue.

Still a long time to wait for a save, but when needed the feature will be helpful.
Back to top
Display posts from previous:   
   NeoOffice Forum Index -> NeoOffice New Feature Requests All times are GMT - 7 Hours
Goto page 1, 2, 3  Next
Page 1 of 3

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum

Powered by phpBB © 2001, 2005 phpBB Group

All logos and trademarks in this site are property of their respective owner. The comments are property of their posters, all the rest © Planamesa Inc.
NeoOffice is a registered trademark of Planamesa Inc. and may not be used without permission.
PHP-Nuke Copyright © 2005 by Francisco Burzi. This is free software, and you may redistribute it under the GPL. PHP-Nuke comes with absolutely no warranty, for details, see the license.