Commit graph

52 commits

Author SHA1 Message Date
Sune Vuorela 611dea4c0d Remove deprecated functions. Porting is needed anyways 2023-12-22 23:25:44 +00:00
Alexander Lohnau ac083e44e3 Make meaning of sponsoring note more clear 2021-06-10 08:11:56 +00:00
Alexander Lohnau 24c75071be Move sponsoring note outside of SPDX-FileCopyrightText statement 2021-06-10 08:11:56 +00:00
Alexander Lohnau 2f193a63de Convert license headers to SPDX 2021-06-10 08:11:56 +00:00
Albert Astals Cid 19d98d6a74 Run clang-format
find . \( -name "*.cpp" -or -name "*.h"  -or -name "*.c"  -or -name "*.cc" \) -exec clang-format -i {} \;

If you reached this file doing a git blame, please see README.clang-format (added 2 commits in the future of this one)
2020-07-11 09:17:33 +02:00
Albert Astals Cid 6d0d61c2ad Enable clazy copyable-polymorphic 2020-02-21 17:09:43 +01:00
Yuri Chornoivan c04ca1fa96 Fix minor EBN issues 2018-08-31 12:23:45 +03:00
Albert Astals Cid 19b7e3c112 The work in this branch was sponsored by LiMux
give them some credit in the headers
2017-11-16 09:58:31 +01:00
Albert Astals Cid 2102843273 Use the undo stack to set the modified bit
This way it's much easier to track whether we are modified or not
2017-11-14 14:52:02 +01:00
Albert Astals Cid 099d3cfcc8 Update @since to 1.3
Let's see if we can squeeze it in
2017-11-06 06:10:13 +01:00
Albert Astals Cid 04ed10d3ea Merge remote-tracking branch 'origin/master' into dont-use-docdata-for-annots-and-forms 2017-09-11 19:51:51 +02:00
Montel Laurent 5da7c5f77d port to qCDebug. Autogenerate export headers 2014-10-27 22:35:06 +01:00
Fabio D'Urso 48c324f77c Added UrlChanged notification in notifySetup to fix BookmarkList not updating after save as 2014-05-11 18:52:16 +02:00
Fabio D'Urso 57c9cae257 Don't save form contents to docdata/
But existing saved form from previous Okular versions are preserved
2014-05-11 18:52:15 +02:00
Albert Astals Cid 04c3b836ff Merge remote-tracking branch 'origin/KDE/4.10'
Conflicts:
	generators/spectre/okularApplication_ghostview.desktop
2013-03-14 23:09:57 +01:00
Albert Astals Cid 3f3f82afa1 Fix my email address 2013-03-14 23:09:07 +01:00
Albert Astals Cid 541650a4f4 Remove the concept of observer/view id
Just use the pointer as id :-)

This is BIC and SIC, increase the soversion now to makes sure we don't forget in the future

Patch based in an earlier patch by Bogdan Cristea <cristeab@gmail.com>
REVIEW: 109115
2013-02-24 23:01:02 +01:00
Tobias Koenig d3e0dadcac Introduce notifyCurrentPageChanged callback DocumentObserver interface 2012-09-06 08:46:10 +02:00
Fabio D'Urso e3f1c388de Ask "Save annotation changes?" if there are unsaved annotations that cannot be saved locally
This patch turns Okular into a ReadWritePart. Annotation editing is always
disabled if we're loaded as ReadOnlyPart, no matter the document type.

REVIEW: 105020
2012-05-23 23:43:44 +02:00
Pino Toscano c05523da2b fix #include paths in core headers to other core headers to be relative
... and with double quotes brackets, so they can properly include each other without relying on the compiler include path
2011-06-01 10:51:31 +02:00
Pino Toscano 18f486c2c1 add the possibility to store an useful bounding box of a page, and for generators to notify the document (and its observers) on its change
original patch by kde2eran@tromer.org, thanks!
CCMAIL: kde2eran@tromer.org

svn path=/trunk/KDE/kdegraphics/okular/; revision=809467
2008-05-18 23:06:21 +00:00
Pino Toscano b56ad8c3ae Change the DocumentObserver::notifySetup() to allow a better tuning of the different setup options (different layout for the pages, or different document).
svn path=/trunk/KDE/kdegraphics/okular/; revision=710227
2007-09-09 10:50:36 +00:00
Pino Toscano 73329a23cf reserve a place for the annotation model
svn path=/trunk/KDE/kdegraphics/okular/; revision=709945
2007-09-08 16:58:31 +00:00
Pino Toscano 8a31e6f3f0 Allow the user to change the visible part(s) of the document by dragging the visible areas in the thumbnails, and to change the zoom of the document by Ctrl+wheel on them.
Patch by Diego R. Brogna, thanks a lot!

BUG: 135521

svn path=/trunk/KDE/kdegraphics/okular/; revision=685273
2007-07-08 14:25:08 +00:00
Albert Astals Cid b0339a4e40 fix some easy krazy issues
svn path=/trunk/KDE/kdegraphics/okular/; revision=654317
2007-04-15 19:11:10 +00:00
Pino Toscano fda81c6a58 SVN_SILENT unused #include
svn path=/trunk/playground/graphics/okular/; revision=648134
2007-03-30 15:43:32 +00:00
Christian Ehrlicher c5c2da7c89 fix win32 compilation
warnings--

svn path=/trunk/playground/graphics/okular/; revision=643874
2007-03-18 17:14:36 +00:00
Pino Toscano 2538e1fce0 remove old enum (belongs to the external -removed- notification system)
svn path=/trunk/playground/graphics/okular/; revision=620790
2007-01-07 11:46:33 +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
Pino Toscano 539921bdf6 Improving the bookmark capabilities of okular.
Adding a BookmarkManager class that takes care of handling them in a proper way.
Adding a new tab in the sidebar to manage them:
- shows all the bookmarks in all the documents, or just in the current document
- cliking on a bookmark will bring to that bookmark, loading the document if necessary
- editing a bookmark title is possible either using F2 or right click -> Rename
- right click -> Remove to remove a bookmark
The only way to add new bookmark for the moment is the "old" way, ie right click -> Add bookmark, and it's not possible add more than one bookmark per page (but the system does not limit that).
The whole system should not be too difficult to understand, I will check with our usability master Florian next days.

svn path=/trunk/playground/graphics/okular/; revision=616979
2006-12-27 16:04:49 +00:00
André Wöbbeking 77f96ebfe2 added missing OKULAR_EXPORT
svn path=/trunk/playground/graphics/okular/; revision=616457
2006-12-25 15:10:39 +00:00
Tobias Koenig 60ef83b026 Moved dummy implementation of DocumentObserver in observer.cpp,
so we are free to change behaviour later.

API & documentation cleanup

@pinto Can you check the comments please, whether they are correct?

svn path=/trunk/playground/graphics/okular/; revision=610731
2006-12-05 08:53:26 +00:00
Albert Astals Cid 579644c631 forwardport r609253 and while at it fix broke pixmaprequest call
**** r609253 ****
Preload next and previous page if threading is enabled and not on low memory setting

svn path=/trunk/playground/graphics/okular/; revision=609258
2006-11-29 22:00:13 +00:00
Tobias Koenig 9969547b0c * observer API cleanup
* removed NotifyRequest, that looked more like a hack than a solution
  (see comment in ghostscript generator)

svn path=/trunk/playground/graphics/okular/; revision=608235
2006-11-27 08:12:39 +00:00
Albert Astals Cid ac1c0b75bc const_iterator is your friend :-)
svn path=/trunk/playground/graphics/okular/; revision=606558
2006-11-20 20:10:42 +00:00
Albert Astals Cid 5143cd2512 Report page size
It's only reported in case it makes sense for the format
Only implemented for pdf atm
If all pages have the same size it's reported on document properties
else there's a label shown in the new bottom bar with the size of the current page

svn path=/trunk/playground/graphics/okular/; revision=595822
2006-10-15 19:37:14 +00:00
Pino Toscano f27f44fd79 Detach the progress widget from the minibar, and move the minibar as a small toolbar on the bottom of the page view.
Implements KPDF wish #102788.

svn path=/trunk/playground/graphics/okular/; revision=595764
2006-10-15 15:59:22 +00:00
Pino Toscano 42310e184c Restructuring a bit how the text-editor-like selection works:
* putting it in an own view mode
* associating the selection to every page
* using a better algorithm to calculate the selection, even in a page range
* moving its drawing from the page view to the page painter, so it's possibile to draw it just like it's done with eg annotations

Other changes (more or less related):
* moved the annotation popup to a better place, so it won't interfere with annotation drawing
* commented some debug code in TextPage

svn path=/trunk/playground/graphics/okular/; revision=588795
2006-09-26 22:22:01 +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
Pino Toscano cd81b54d63 Show the current viewport in the thumbnail view, with a read contour.
svn path=/trunk/playground/graphics/okular/; revision=554363
2006-06-23 21:11:52 +00:00
Pino Toscano aa8df17b5f init correctly in all the c'tors
svn path=/branches/work/kde4/playground/graphics/okular/; revision=545757
2006-05-28 10:41:12 +00:00
Albert Astals Cid 33848a3ee8 The big poppler commit, we now don't use poppler but poppler-qt4 frontend, and that is GOOD
You need poppler from cvs as of today, i'll change the check to a bigger version number once a new poppler gets released
There are still some problems i think but i'm commiting to see if someone wants to help ;-)
Includes some EBN fixes by Christian Mueller

svn path=/branches/work/kde4/playground/graphics/okular/; revision=540404
2006-05-13 11:17:24 +00:00
Albert Astals Cid b412aba1f1 more proting, area.h still resists me
svn path=/branches/work/kde4/playground/graphics/okular/; revision=520833
2006-03-20 22:51:56 +00:00
Piotr Szymanski c7da917e38 - add minor checks for validity of requests
- fix ghostscript backend (works now)

svn path=/trunk/playground/graphics/oKular/kpdf/; revision=509917
2006-02-15 21:02:13 +00:00
Piotr Szymanski d09fd28b89 - MERGE KPDF 3.5 CHANGES
svn path=/trunk/playground/graphics/oKular/kpdf/; revision=477586
2005-11-04 11:59:51 +00:00
Enrico Ros 4d0a1ed6e1 Added a new experimental 'Reviews' widget to the toolbox. This shows
all the reviews on the document (pretty unuseful now, but that will
change ;-). Another step to good kpdf annotations.

Part:
  Added Reviews toolbox pane. Added (commented out while doing it right)
  searchline for toc; just works.
Misc:
  Observer: added id for Reviews pane (as document observer it monitors
  document/annotations changes). Page: added 2 temporary accessors for
  annotations (will change soon). Makefile: added side_reviews.cpp to
  compilation. Searchwidget: slight better spacing to look consistant with
  the review panel.

svn path=/branches/kpdf_annotations/kdegraphics/kpdf/; revision=400307
2005-03-24 19:50:28 +00:00
Enrico Ros fbc7d45083 Adding support for annotations in framework. Only need to add and
implement annotations now (and create the save/load procedure).

Annotations: converging to a stable Annotation definition. Changed a bit
  the paint functions. Added a first 'template' annotation, a simple
  pen-like segments recorder for framework testing purposes only. This
  has events filters in place and the rough paint function implemented.

PageView: removed the MouseEdit mode and using that button for toggling
  the editToolBox instead. Added Annotation support. When the Annotation
  is created, all pageView events flow through that new object. Repaint
  of damaged/old areas is done internally and is based on the geometry
  of the annotation we're creating. When an Annotation is complete, it
  is reparented to the Page that adds it to its internal list.
  From that point on the annotation will be rendered by pagePainter
  using the pixmap-based paint function provided by the annotation
  itself.

PagePainter: draws annotations stored in pages when rendering (using the
  'rought paint function' till the good pixmap based one will be in
  place.

Page: added preliminary support for adding Annotation(s) to the page
  and deleting them all.

Document: added the pass-through call to add an Annotation to the Page
  and notify observers.

PageViewToolbox: can be draged and attached to any side. Position is
  remembered between runs (choose your side and that the toolbox will
  always be there). Available on Right and Bottom sides too. Emits -1
  when the current tool is deselected.

Misc: added Annotations to both the 'observers changed flags' and the
  'pagepainter' ones and updated ui classes accordingly.

svn path=/branches/kpdf_annotations/kdegraphics/kpdf/; revision=390638
2005-02-18 18:24:45 +00:00
Enrico Ros d1e074058b cleanups and scroll api
svn path=/trunk/kdegraphics/kpdf/; revision=385040
2005-02-01 18:23:55 +00:00
Enrico Ros e65c7058c3 Added the MiniBar class, a layouted widget that displays current page
number, the total number of pages and a little grahical 'progress'
 indicator. Moved 'next page' and 'prev page' buttons from the main toolbar
 to the MiniBar. Minibar lets you edit the page number, click or wheel on
 progress, go to next/prev page, show the gotoPage dialog.
Added rmb popup when clicking on thumbnails. When clicking, the
 ThumbnailList only emits the same signal emitted by PageView so the same
 context menu is displayed.
Misc fixes: [MEM] enabled allocated pages raising in queue when displayed
 again, [ThumbnailList] enabled PageUp/PageDown.

svn path=/trunk/kdegraphics/kpdf/; revision=382597
2005-01-26 10:42:07 +00:00
Enrico Ros 962f891b80 For Users:
Display contents faster, waste less memory. Added preloading to forward-
generate pages (if threading enabled and memory profile >= normal). Main
pages are always generated first, then thumbnails come, then preload ones,
etc.. Btw memory and cpu will be happier now.
(1 bug in memory and 1 in preloading still remains.. will be spotted soon)

For Developers:
Generator: dropped moc, api changes, better functions naming.
PDFGenerator and Document: moved requests queue to the Document.
   The generator performs only a single request a time. A flag can be
   queried to know if the generator is ready for starting another pixmap
   generation or not (in case it's generating a pixmap in background).
PixmapRequest: added priority and backgound (async) attributes.
Document: queuing requests by priority in requestPixmaps.
Observer: added defines for priorities used in doc->requestpixmaps.
PageView: delayed find-ahead timer creation (not created if not needed).
   Added preload PixmapRequests to the pixmap requests list.
ThumbnailsList: adapted to pixmapRequest changes and changed naming for
   delayed thumbanils request.

svn path=/trunk/kdegraphics/kpdf/; revision=379820
2005-01-18 16:43:36 +00:00