Commit graph

51 commits

Author SHA1 Message Date
Pino Toscano
2de89d6eb8 don't leak the format mask and the (empty) kdjvu
svn path=/trunk/playground/graphics/okular/; revision=620781
2007-01-07 10:46:50 +00:00
Pino Toscano
4b922367e2 Use a proper enum to deal with orientation/rotation all around okular.
svn path=/trunk/playground/graphics/okular/; revision=620312
2007-01-05 17:09:47 +00:00
Tobias Koenig
ea51ee18f5 Do a lot of include cleanups... we install all important
header files now

svn path=/trunk/playground/graphics/okular/; revision=619492
2007-01-03 14:30:48 +00:00
Tobias Koenig
86a1fd3b69 Big cleanup of Document API and documentation:
* add full API docs
 * renamed getMetaData -> metaData
 * removed supportsRotation in Document and Generator
 * moved Permission and SearchDirection enums into separated header core/global.h

svn path=/trunk/playground/graphics/okular/; revision=619183
2007-01-02 22:37:55 +00:00
Tobias Koenig
6f9d0df5cd Further annotation API cleanup
svn path=/trunk/playground/graphics/okular/; revision=612395
2006-12-11 07:59:02 +00:00
Tobias Koenig
a9f58440df First large commit for the Annotation API cleanup
* Moved all public member variables of Annotation to private
    and add accessors
  * Renamed RevScope and RevType to RevisionScope and RevisionType
  * Add API documentation (@pino, please review)

svn path=/trunk/playground/graphics/okular/; revision=610749
2006-12-05 11:05:50 +00:00
Pino Toscano
5c0de8b638 Add printing support for DjVu files. (It is also PostScript exporting, as you can print to file to get a PS document.)
svn path=/trunk/playground/graphics/okular/; revision=606585
2006-11-20 22:48:44 +00:00
Tobias Koenig
a490cc0cd7 Add the following functionality:
* Bring QPixmap* back to make Albert happy ;)
 * Store only one QPixmap per page/size and rotate it directly
 * Rotate ObjectRects (boundary)
 * Rotate Annotations (point coordinates)
 * Don't reload pixmaps, ObjectRects and annotations on rotation

svn path=/trunk/playground/graphics/okular/; revision=606371
2006-11-20 07:53:32 +00:00
Pino Toscano
4f305424bc read the annotations only once, ie when loading the pages
svn path=/trunk/playground/graphics/okular/; revision=605455
2006-11-16 19:52:04 +00:00
Pino Toscano
673fe63610 generate an uid for the djvu annotations
svn path=/trunk/playground/graphics/okular/; revision=604290
2006-11-12 12:43:42 +00:00
Pino Toscano
9a232e9d88 SVN_SILENT typo
svn path=/trunk/playground/graphics/okular/; revision=604211
2006-11-12 00:53:48 +00:00
Pino Toscano
de6d8eaf1d update
svn path=/trunk/playground/graphics/okular/; revision=604210
2006-11-12 00:52:31 +00:00
Pino Toscano
5731b36fe5 the text is needed in this field, too, for the moment
svn path=/trunk/playground/graphics/okular/; revision=604209
2006-11-12 00:48:59 +00:00
Pino Toscano
cb414fbf1d remember, pino, remember: djvu coordinates refer to the lower-left corner of a page.
fix the coordinate loading for the annotations

svn path=/trunk/playground/graphics/okular/; revision=604204
2006-11-11 23:52:12 +00:00
Pino Toscano
28c63b44e8 read the 'width' info for lines
svn path=/trunk/playground/graphics/okular/; revision=604196
2006-11-11 23:23:07 +00:00
Pino Toscano
825c725eaf change the internal KDjVu data storage to an hash of variants
svn path=/trunk/playground/graphics/okular/; revision=604173
2006-11-11 20:34:07 +00:00
Pino Toscano
132daba86a update with some annotation stuff
svn path=/trunk/playground/graphics/okular/; revision=604168
2006-11-11 19:25:09 +00:00
Pino Toscano
0c4a081174 Add preliminary support for DjVu Text and Line annotations.
This means we can read them almost correctly, but there are some problems with placements and colors.

svn path=/trunk/playground/graphics/okular/; revision=604165
2006-11-11 19:15:58 +00:00
Pino Toscano
a29cbda39e The DjVu backend can now read hyperlinks whose url is decoded as "(url href target)".
svn path=/trunk/playground/graphics/okular/; revision=604073
2006-11-11 14:22:41 +00:00
Pino Toscano
5adbe4c66f there's no more need for libtool files
svn path=/trunk/playground/graphics/okular/; revision=603923
2006-11-10 20:03:50 +00:00
Pino Toscano
eb83fc5d27 adapt the djvu generator (and kdjvu) to handle images instead of pixmaps
add a basic TODO

svn path=/trunk/playground/graphics/okular/; revision=599108
2006-10-25 19:42:30 +00:00
Tobias Koenig
d22b2f1892 A rather big change:
* Hide as much private API as possible in Generator, PixmapRequest and ExportEntry/Format
 * Renamed ExportEntry to ExportFormat and made it value based
 * Removed canExportToText() and exportToText() from Generator API and implemented this
   functionality in exportFormats()/exportTo() in the generators
 * Removed the orientation parameter from PixmapRequest and let the Document handle the rotation
   of the page (pixmap) instead

CCMAIL:okular-devel@kde.org

svn path=/trunk/playground/graphics/okular/; revision=599058
2006-10-25 15:35:53 +00:00
Laurent Montel
acb44a49d5 Apply Alex patch (now we can use enable-final argument
some module compiles with enable-final now)
As discussed with Alex it's not necessary to have program name
into automoc macro

svn path=/trunk/playground/graphics/okular/; revision=598341
2006-10-23 09:29:10 +00:00
Pino Toscano
18028a8a2c API change in the Generator: use an empty construct, and set the document for the generator right after its construction.
Add a protected method to get the document, and hide the real document pointer as private, so the generators can't redefine it.

svn path=/trunk/playground/graphics/okular/; revision=598025
2006-10-22 11:25:08 +00:00
Tobias Koenig
fccd412d69 * Added documentation to Generator API
* Moved all implementations to generator.cpp
 * Added 'const' where it make sense
 * Adapted all generators (except gs)

svn path=/trunk/playground/graphics/okular/; revision=597525
2006-10-20 16:51:46 +00:00
Laurent Montel
9f317e53ca Port to new kde4_automoc macro
Necessary to change KDE4_AUTOMOC macro to support
enable-final argument

(there was not a dependancy between <name>_final.cpp file and
moc generated files => moc files were never created)

Not necessary to rebuild all kdelibs just cp kdelibs/cmake/modules/KDE4Macros.cmake <path_kde4>/share/apps/cmake/modules

I ported and tested all kde module (without enable-final argument, it compiles fines (test and program))
Don't try to use enable-final argument for the moment it doesn't compile (but dependancy works)

Regards

svn path=/trunk/playground/graphics/okular/; revision=595060
2006-10-13 08:13:52 +00:00
Pino Toscano
c52a0e622b Change the way we rotate the pages.
Instead of telling the generators to do the work themselves (that was usually destraoying the ld pages and creating the new ones), now we just rotate the page objects deleting only their "mutable" contents.
This way, generators can just return true in their supportRotation() to make okular rotate the pages for them for free. Of course they still have to generate the page pixmaps according to the given page rotation.
Now, there's a new rotationChanged() function in the Generator API so generator that needs it can be norified about the document rotation changing.

CCMAIL: developers@okular.org

svn path=/trunk/playground/graphics/okular/; revision=593632
2006-10-08 15:07:23 +00:00
Tobias Koenig
df7d144c10 Moved all classes in core/ into the 'Okular' namespace and removed
nearly all references to kpdf (knewstuff still missing).

svn path=/trunk/playground/graphics/okular/; revision=586993
2006-09-21 08:45:36 +00:00
Albert Astals Cid
8beff183b9 add desktop files indicating libokular provides a part for those mimetypes
svn path=/trunk/playground/graphics/okular/; revision=586466
2006-09-19 17:42:02 +00:00
Laurent Montel
3d62f697b2 Clean up
svn path=/trunk/playground/graphics/okular/; revision=566117
2006-07-25 13:08:23 +00:00
Pino Toscano
e147f53ab7 make sure to really close the djvu document
svn path=/trunk/playground/graphics/okular/; revision=564677
2006-07-20 20:02:02 +00:00
Pino Toscano
b6d7a36eda Small addition to the Ganarator API: bool closeDocument().
Now every generator has to implement this one and put (if necessary) all the code for cleaning up all the stuff related to the currently open document.
For now the return value it is not read, but generators as strongly suggested to return tru o false, whether all the operations in there went fine.

svn path=/trunk/playground/graphics/okular/; revision=562210
2006-07-14 10:54:29 +00:00
Pino Toscano
38593f718c delete a Link if an ObjectRect is not created; less deferences
svn path=/trunk/playground/graphics/okular/; revision=561949
2006-07-13 17:27:34 +00:00
Pino Toscano
2d64d446d7 Read correctly the 'poly' links for DjVu documents.
svn path=/trunk/playground/graphics/okular/; revision=561918
2006-07-13 16:08:50 +00:00
Pino Toscano
67fabc7659 - adapted the DjVu generators to the new ObjectRect API
- read also the links with an elliptic shape
- some code less

svn path=/trunk/playground/graphics/okular/; revision=561892
2006-07-13 15:06:47 +00:00
Pino Toscano
0211c662e9 now that KDjVu works nicely, reduce the debug
svn path=/trunk/playground/graphics/okular/; revision=559952
2006-07-08 17:51:25 +00:00
Pino Toscano
1285825aa5 use install instead of install_files
svn path=/trunk/playground/graphics/okular/; revision=558033
2006-07-04 15:24:52 +00:00
Pino Toscano
a324781264 adapt the djvu generator to make use of the okularUtils namespace
svn path=/trunk/playground/graphics/okular/; revision=556609
2006-06-30 21:43:40 +00:00
Pino Toscano
ca85816c4c take correctly into account the rotation of the document, and rotate the link rects accordingly
svn path=/trunk/playground/graphics/okular/; revision=556019
2006-06-28 22:57:01 +00:00
Pino Toscano
c39fdf8f5c Improve the hyperlink support, and make it less error-prone. Micro suppport for URL hyperlinks.
svn path=/trunk/playground/graphics/okular/; revision=555968
2006-06-28 20:44:12 +00:00
Pino Toscano
39e73f95f6 Read correctly the DjVu area maps (aka links) referring to local pages.
svn path=/trunk/playground/graphics/okular/; revision=555915
2006-06-28 17:52:00 +00:00
Pino Toscano
63c1580412 SVN_SILENT apidox
svn path=/trunk/playground/graphics/okular/; revision=555392
2006-06-27 09:33:43 +00:00
Pino Toscano
a5795e2726 Now the DjVu generator is able to extract the list of bookmarks (aka Table of Contents) from the DjVy document, if it has any.
svn path=/trunk/playground/graphics/okular/; revision=555320
2006-06-27 00:08:42 +00:00
Albert Astals Cid
38343cd4e1 drop .la as per dfaure's suggestion
svn path=/trunk/playground/graphics/okular/; revision=553685
2006-06-21 17:31:50 +00:00
Pino Toscano
066beaa1dd small changes in the Generator API:
- no need for a private empty constructor
- move the signalRequestDone 'signal' to a protected visibility, as it's not meant to be called from outside a generator
- KPDF_EXPORT_PLUGIN -> OKULAR_EXPORT_PLUGIN

svn path=/trunk/playground/graphics/okular/; revision=553077
2006-06-19 22:15:07 +00:00
Pino Toscano
49a5be93da isolate the code for creating pages in an own method, should work correctly for pages with an initial rotation different than 0
svn path=/trunk/playground/graphics/okular/; revision=552594
2006-06-18 13:04:42 +00:00
Pino Toscano
5242e3bd7e encode the file name correctly
svn path=/trunk/playground/graphics/okular/; revision=552037
2006-06-16 13:02:58 +00:00
Albert Astals Cid
eabbaeaead oKular is now okular
svn path=/branches/work/kde4/playground/graphics/okular/; revision=550782
2006-06-12 18:25:18 +00:00
Pino Toscano
dc0168a8f4 add the info about the number of components of the current document
svn path=/branches/work/kde4/playground/graphics/okular/; revision=550300
2006-06-11 13:48:39 +00:00
Pino Toscano
60eab90248 small API changes to Generator:
- more const'ness in signals
- no need to redeclare the signals in the generators, as they are already in Generator

svn path=/branches/work/kde4/playground/graphics/okular/; revision=549941
2006-06-10 12:59:09 +00:00