Commit graph

273 commits

Author SHA1 Message Date
Albert Astals Cid 8ecba7f6c9 GIT_SILENT Upgrade KDE Applications version to 17.07.80. 2017-07-17 22:16:44 +02:00
Albert Astals Cid bb547c5eed 1.2.x for KDE Applications 17.08.x 2017-07-17 20:37:44 +02:00
Andreas Sturmlechner 1177c2e1a8 Merge branch 'Applications/17.04' 2017-04-23 00:11:28 +02:00
Andreas Sturmlechner decb01292e Drop unused DBusAddons
REVIEW: 130099
2017-04-22 12:55:37 +02:00
Albert Astals Cid b23df4ef98 GIT_SILENT Update version 2017-04-12 14:33:35 +02:00
Albert Astals Cid 53c9eda733 GIT_SILENT Upgrade KDE Applications version to 17.04.0. 2017-04-12 13:41:25 +02:00
Albert Astals Cid ecbfe4151e GIT_SILENT Upgrade KDE Applications version to 17.03.90. 2017-04-05 21:57:09 +02:00
Albert Astals Cid 3df3c758c8 GIT_SILENT Upgrade KDE Applications version to 17.03.80. 2017-03-20 23:47:03 +01:00
Albert Astals Cid a0595e97df GIT_SILENT increase version a bit 2017-03-20 23:38:05 +01:00
Albert Astals Cid f95952e95c GIT_SILENT Upgrade KDE Applications version to 17.07.70. 2017-03-20 23:21:26 +01:00
Albert Astals Cid 63a08bc01a Enable -Wsuggest-override 2017-03-19 23:27:04 +01:00
Tobias Deiminger 0957abc39a Add annotation resize functionality
Usage:
If you left-click an annotation, it gets selected. Resize handles appear on the selection rectangle. When cursor is moved over one of the 8 resize handles on the corners/edges, the cursor shape changes to indicate resize mode. Everywhere else on the annotation means "move", just as it was before resize feature was added. Pressing ESC or clicking an area outside the annotation cancels a selection. Pressing Del deletes a selected annotation.

Feature is only applicable for annotation types AText, AStamp and AGeom.

Implementation:
It works by eventually changing AnnotationPrivate::m_boundary and notifying generator (i.e. poppler) about that change. Annotation state handling is shifted out of PageView into a new class MouseAnnotation (ui/pageviewmouseannotation.cpp). Some functionality not related to resizing but to annotation interaction in general is also shifted to class MouseAnnotation, to build a single place of responsiblity.

Other changes:
Add method Document::adjustPageAnnotation, backed by a QUndoCommand.
class Okular::AdjustAnnotationCommand.
Add Annotation::adjust and Annotation::canBeResized methods.
Draw resize handles in PagePainter::paintCroppedPageOnPainter.

Resize and move work
-for types AText, AStamp and AGeom
-on all pages of document
-when viewport position changes
-when zoom level changes
-for all page rotations (0°, 90°, 180°, 270°)

Selection is canceled
-when currently selected annotation is deleted
-on mouse click outside of currently selected annotation
-ESC is pressed

Viewport is shifted when mouse cursor during move/resize comes close to viewport border.
Resize to negative is prevented.
Tiny annotations are still selectable.
If mouse is moved over an annotation type that we can focus, and the annotation is not yet focused, mouse cursor shape changes to arrow.
If mouse cursor rests over an annotation A, while annotation B is focused, a tooltip for annotation A is shown.
Selected Annotation is deleted when Del is pressed.

Test for regressions:
-Annotation interaction (focus, move, resize, start playback, ...) are only done in mode EnumMouseMode::Browse.
-If mouse is moved over an annotation type where we can start an action, mouse cursor shape changes to pointing hand.
-If mouse is moved over an annotation type that we can't interact with, mouse cursor shape stays a open hand.
-If mouse cursor rests over an annotation of any type, a tooltip for that annotation is shown.
-Grab/move scroll area (on left click + mouse move) is prevented, if mouse is over focused annotation, or over AMovie/AScreen/AFileAttachment annotation.
-A double click on a annotation starts the "annotator".

REVIEW: 127366
BUG: 177778
BUG: 314843
BUG: 358060
2017-03-19 23:18:17 +01:00
Oliver Sander 3859fba07d Remove dependency on KActivities on Windows.
REVIEW: 130022
REVIEW: 126378
2017-03-18 01:58:47 +01:00
Christoph Feck 7a013e3869 Require KHtml only when building CHM generator
Reviewed by: aacid

Differential Revision: D4507
2017-02-10 02:57:06 +01:00
Albert Astals Cid 61fdea2c1f Merge remote-tracking branch 'origin/Applications/16.12' 2016-12-28 19:38:22 +01:00
Albert Astals Cid e833b3ce65 Fix menu titles not showing up
QMenu title/section are optional to draw from the style side but we have crucial information in them
so reuse old KMenu code to create a fake action that behaves as title

I'll see if KF5 wants to accept this as contribution later

BUGS: 374079
2016-12-28 17:05:46 +01:00
Albert Astals Cid a3e0e630e2 Update version
GIT_SILENT
2016-12-09 23:00:22 +01:00
Albert Astals Cid 6e1d3bb1bc GIT_SILENT Upgrade KDE Applications version to 16.12.0. 2016-12-06 20:57:55 +01:00
Albert Astals Cid d248be4173 GIT_SILENT Upgrade KDE Applications version to 16.11.90. 2016-11-29 22:16:51 +01:00
Albert Astals Cid 306ca5f77b GIT_SILENT Increase version for master 2016-11-16 00:38:08 +01:00
Albert Astals Cid 235c43fc47 GIT_SILENT Upgrade KDE Applications version to 17.03.70. 2016-11-16 00:19:13 +01:00
Albert Astals Cid 7cddd9c359 GIT_SILENT Upgrade KDE Applications version to 16.11.80. 2016-11-15 23:49:21 +01:00
Albert Astals Cid fa680b6c04 Require Qt 5.6
This is not a dependency freeze break, it's just bringing cmake up to date with what the code already required

BUGS: 372339
2016-11-15 00:24:42 +01:00
Aleix Pol ebeeac8d72 Set the version to 1.0
Remove redundant version.h file in favor of the ecm-generated.
Use minor version from KDE_APPLICATIONS_VERSION_*

Reviewed by Albert Astals
2016-10-29 12:42:59 +02:00
Martin T. H. Sandsmark 5e77764ac5 Don't show mobile version in menus 2016-08-13 22:53:29 +02:00
Martin T. H. Sandsmark ff274fdecc Remove kdelibs4support 2016-08-13 22:38:02 +02:00
Martin T. H. Sandsmark 85078160fa Use normal KDE compiler settings 2016-08-13 22:32:31 +02:00
Olivier CHURLAUD 411bdee0eb Open relative path again
REVIEW: 128507
2016-08-03 16:01:30 +02:00
Martin T. H. Sandsmark 68deb82a6f We need doctools 2016-07-24 23:44:49 +02:00
Martin T. H. Sandsmark 077258f235 (re-)Implement recoloring 2016-07-24 21:34:56 +02:00
Olivier CHURLAUD ef6f5ebc3b Porting more files out of KDialog 2016-07-21 21:53:54 +02:00
Olivier CHURLAUD 630269a400 More ports out of KDialog 2016-07-17 02:28:57 +02:00
Olivier CHURLAUD 741c616c7a Port most of part.cpp out of KDELibsSupport
minor: Change header cases : <qicon.h> becomes <QIcon>
2016-07-15 21:14:50 +02:00
Martin T. H. Sandsmark a1d2d8cac7 Undo mistake in last commit 2016-07-11 19:41:37 +02:00
Martin T. H. Sandsmark 243fc02cb9 Add some missing explicit dependencies 2016-07-11 19:40:49 +02:00
Thomas Friedrichsmeier df0c41212f Fix build with MinGW on Windows.
REVIEW: 127328
2016-03-16 10:57:34 +01:00
Armin K 568079625d cmake: Port to FindPoppler from extra-cmake-modules
REVIEW: 127049
2016-03-08 19:54:21 +01:00
Albert Vaca 67f69c8871 Merge branch 'master' into frameworks
# Conflicts:
#	CMakeLists.txt
#	active/app/package/metadata.desktop
#	conf/widgetannottools.cpp
#	core/version.h
#	generators/poppler/libokularGenerator_poppler.desktop
#	generators/txt/libokularGenerator_txt.desktop
#	generators/xps/libokularGenerator_xps.desktop
#	ui/annotationwidgets.cpp
#	ui/presentationwidget.cpp
2016-02-22 03:50:54 -08:00
Aleix Pol f42a3bad65 Drop libkscreen dependency
Drops the x11 fallback. We were falling back to QX11Extras that were in
fact using QScreen internally.
Also remove the QDesktopWidget fallbacks for the same reason.
Drops some API for fetching the dpi and unifies it with ::realDpi(QWidget).

Based on Sebas's patch.
Reviewed by Albert.

REVIEW: 126913
2016-01-30 18:15:07 +01:00
Patrick Spendrin 37d5623102 Remove kdelibs4support from the generator plugins
This removes kdelibs4support for all generators except the mobipocket one.
The test executable for kimgio needs some windows fixes too, so I'll try
to make a separate review for that.

REVIEW: 126375
2016-01-30 16:51:46 +01:00
Albert Astals Cid db1c8ad751 Need new KF5 to get KPluginMetaData::mimeTypes 2016-01-30 16:49:37 +01:00
Aleix Pol 2c6cf868cf Let KDE*CompilerSettings change the policies in the project
As suggested in ECM documentation.
2016-01-28 14:59:01 +01:00
Alex Richardson 2f9246ae42 Port to new JSON plugin loading system
This means Okular can now work without ksycoca and KDELibs4Support.

REVIEW: 126193
2016-01-04 15:59:07 +01:00
Michel Ludwig b939800fb7 Add logging categories file for kdebugsettings
REVIEW: 126589
2016-01-03 09:13:06 +01:00
Gleb Popov 0928298a74 Build okularpart as SHARED library when using MSVC, as using MODULE causes errors when linking to okularpart.dll.
REVIEW: 125792
2015-12-16 01:23:08 +01:00
Albert Astals Cid 450fff8818 Increase version for KDE Applications 15.12.0
And soversion of the core library sicne there's a new virtual in it
2015-12-07 23:31:12 +01:00
Albert Astals Cid 8445660539 Merge remote-tracking branch 'origin/master' into frameworks 2015-10-18 22:29:00 +02:00
Albert Astals Cid d52a07c9d2 Merge remote-tracking branch 'origin/gsoc2015_layer_feature' 2015-09-16 22:54:42 +02:00
Montel Laurent c3decc55f7 Merge remote-tracking branch 'origin/master' into frameworks
Conflicts:
	CMakeLists.txt
	ui/pageview.cpp
2015-08-27 23:04:28 +02:00
Albert Astals Cid 21dfb2127f See if this gives us coverage support 2015-08-27 00:05:06 +02:00