Hi Aaron,

On 03/27/09 18:48, Aaron Ehrensberger wrote:
1.      A quick way to snag a snapshot of the first page of the doc
using OO for the thumbnail?
Unfortunately there seems to be no general API to create a thumbnail of a document. May be there is an application API that would allow this. Actually it would be no problem to implement it generally in framework, I have just submitted an enhancement for this
http://qa.openoffice.org/issues/show_bug.cgi?id=100663

2.      A faster way to convert the doc?  Currently, I'm loading the
file from a URL, then storing the file (which does the conversion).  Is
there a faster utility that doesn't force me to open and save the doc?
Currently all the documents that were stored using 2.4 and 3.x versions contain an internal thumbnail. It is in png-format and has size 256x256 pixels. If it is enough, you could try to get the storage from the loaded model using css::document::XStorageBasedDocument::getDocumentStorage(), open the substorage "Thumbnails" and then open the stream "thumbnail.png" in the substorage. The stream contains the thumbnail. Please remember that very old versions of the office do not store the thumbnail, so there is a probability that a document has no thumbnail. In this case the way you are doing it currently looks to be reasonable.

Hope that helps.

Best regards,
Mikhail.
Aaron

Aaron Ehrensberger

Software Architect

DocFinity(r) by Optical Image Technology, Inc.

100 Oakwood Avenue, State College, PA  16803

ph: 814.238.0038 ext. 270

fax: 814.238.0011

email: aehrensber...@docfinity.com

web: www.docfinity.com




--
Sun Microsystems GmbH                Mikhail Voytenko
Nagelsweg 55                         Software Engineer
20097 Hamburg                        Phone: (+49 40)23646 500
Germany                              Fax:   (+49 40)23646 550
http://www.sun.de                    mailto:mikhail.voite...@sun.com

Sitz der Gesellschaft: Sonnenallee 1, D-85551 Kirchheim-Heimstetten
Amtsgericht München: HRB 161028
Geschäftsführer: Thomas Schröder, Wolfgang Engels, Dr. Roland Bömer
Vorsitzender des Aufsichtsrates: Martin Häring


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@openoffice.org
For additional commands, e-mail: dev-h...@openoffice.org

Reply via email to