It's hard the user edits forms in more than one page in less than a second (though possible)
but once we introduce JS parsing that will be defenitely possible so need to store more than one page
Extending the viewport update area of the selection rectangle when dragging the mouse while in selection mode or when canceling the selection ensures that no artifacts remain on-screen in either case.
BUG: 266537
Differential Revision: https://phabricator.kde.org/D4487
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
This patch changes multiline QStringLiterals to QString::fromLatin1
as QStringLiterals doesn't understand multiline strings on windows.
Also, strncasecmp is replaced by the portable qstrnicmp function provided
by QByteArray header.
REVIEW: 126379
Changes
C1. Added submenu, moved "Trim margins" (TM mode) to it and added "Trim To Selection" (TS mode).
C2. Activating "Trim To selection" enters a new mousemode, similar to RectSelect for defining a viewport.
C3. Once a viewport has been defined, it serves as a viewport for all pages in the document.
C4. Left/Right pages are not treated differently.
Manual Testing
T1. Switching between modes enforces at most one active.
T2. Can deactivate a mode by selecting it again from the menu.
T3. When draggin bbox selection, clicking outside page does not crash.
T4. When in "Facing Pages" mode, mouse release must be over any page (or is ignored).
T5. Normalized bbox coords are computed relative to page indicated by point of mouse release.
T6. Behave as expected when switching between any pair of No Trim/Trim Margins/Trim To Selection.
T7. TM mode persisted across app restarts (existing behavior).
T8. TS mode forgotten across app restarts (as desired).
T9. Exiting and reselectin "Trim To Selection" prompts for new bbox.
T10. Choosing a small Trim bbox enforces minimium dimensions size (As percentag of total), as
it does in TM mode, because of the "scale big and crop down" implementation, to avoid huge pixmaps.
TS mode minimum set at 20% (vs. TM mode's 50%).
REVIEW: 124716
BUGS: 351156
This was broken since commit 077689c4 when this got ported away from
KAction. The code attempted to add a parent QMenu to the QAction
instances nested below that parent. I'm quite surprised that it didn't
crash, but checkable actions do not go well with actions that have
nested menus, apparently.
I haven't checked the rest of the code for similar mistakes, but I don't
see any other case of this bug in Okular's menus when reading PDFs.
REVIEW: 124842
That patch extracts the video file, which is defined in a
rich media annotation as parameter for the flash player,
and uses the normal multimedia player, to playback the video
file.
This feature requires poppler-qt5 in version 0.36.
FEATURE: 326230
REVIEW: 124612