This represents the newly entered data for each keystroke. This is often a single added character, but for cases like pasting text it can be more complex.
The PDF API reference doesn't specify any algorithm to use.
The algorithm used here works by iterating through both strings from the start until the first different character is encountered. Then the rest of the new text is considered the difference.
This doesn't produce the theoretically optimal/minimal diff, but seems to work well enough for practical application.
When text is removed the diff is empty
You can opt-out using the FORCE_NOT_REQUIRED_DEPENDENCIES option
We want people to always build as much of the optional dependencies as
possible, so force them to spell out what they don't want
And except on Android because two reasons:
* The gitlab CI doesn't have some dependencies we actually have available
* Some dependencies are not really available
Better enforce them now, so that the work to port doesn't increase over
time
Not a super fan of this for regular applications, but oh well the ship
has sailed
We do that by:
* Remembering all the generators we're building
* Linking the dependencies of all those generators against the app
For that to work we do three things:
* Move the creation of the app target to after the generator targets
have been created
* Have a global variable that lists all the created generators
* Move the find_package of the generator dependencies to the top level
so it can be used from the mobile app target
The MR
1. adds a note, that the tests in the build tree depend on the install tree.
2. extends the QT_PLUGIN_PATH with KDE_INSTALL_FULL_QTPLUGINDIR in cmake before creating the tests. That removes the need to source prefix.sh before calling cmake.
Removes the smooth property of PageItem since it was never set and clazy
was complaining about it not having a NOTIFY signal
Remove two signals that already exist in parent class
Fix C++11 detach in range-loop
It's desktop unless you're building for Android where the default it's
mobile.
You can still manually specify which UI you want and you'll get that
regardless of the platform
Only require KParts if we're building the desktop UI
Two small changes in CI:
* Stop pretending we have a macOS CI
* Add Android CI
- libkexiv2, khtml and kjs would be nice but we don't have Android builds
yet
By using Poppler 20.10 new custom image stamps APIs
Instead of the incompatible hack we used before that only worked for Okular.
This is done by modifying the update function used by PopplerAnnotationProxy in order to load the image in
the correct dimensions and send it to the poppler-Qt5 frontend.
We temporarily store the stamp annotation appearance when deleting it so that we can set it again when doing an undo undo.
Also, actually fully disable the build of okularpart, which isn't needed
on Android.
With this Okular can be built for Android without the D-Bus stub, at least
once KIO doesn't pull in D-Bus anymore.
Implemented using a ColorModeMenu class,
derived from ToggleActionMenu (derived from KActionMenu),
as a child object of PageView.
* KToggleAction for every color mode, allows to set shortcuts for every mode.
Color mode actions have icons.
* KToggleAction for normal colors mode.
* ToggleActionMenu containing all color mode actions.
If triggered, toggles color mode between normal colors and last change colors mode.
"Toggle Change Colors" is replaced by "Change Colors", which is actually a toggle action.
BUG: 407217
BUG: 437755
This creates CursorWrapHelper, which wraps the cursor
from e. g. top screen edge to bottom screen edge,
and calculates the drag offset from the actual cursor movement.
* C++ instead of .ui files.
* Put every control in a QFormLayout row.
* Where possible, use only a single layout, i. e. no nesting.
* Use rows with an empty QLabel as horizontal spacer.
Content grouping by whitespace instead of group boxes.
* Where group boxes were used for labeling tool managers,
use a <h3> QLabel instead.
* Where group boxes were used for labeling control groups,
drop the label or label only the first control (like in Dolphin).
* Use combo boxes instead of radio button groups.
(I don’t know how to connect radio buttons to KConfigWidgets...)
* Don’t use checkboxes as label, that doesn’t lay out correctly.
Instead, put the checkbox in an own row, although it controls the same feature.
Some of the changes are not perfect yet, so I opened
https://invent.kde.org/graphics/okular/-/issues/45 to outline further improvements.
Source files are no longer separated by UI and non-UI and similar,
but only by their build target.
* ui/ -> part/
* Move all source files from conf/ to part/
* Keep config skeleton definitions in conf/, needed for the mobile target too
* Move editdrawingtooldialogtest.h from conf/autotests/ to autotests/
* ui/data/icons/ -> icons/
* Move /part.cpp, /part.rc and similar files to part/
* Adapt include paths in source files
* Adapt CMakeLists.txt files (in / and in subdirectories)
* Adapt /Messages.sh
f9841b0f8a and e0f45add55
They break the windows build, which shows there's something defenitely
fishy going on with the current code, but oh well, someone with more
time needs to figure out a proper solution
Read https://stackoverflow.com/a/23749273/11956287 for a full
explanation, but basically this is important for headers like the
interfaces/ and kdocumentviewer.h that are supposed to be used by third
partyies where it may happen that wrong things happen because the whole
class is inline in a header
For the classes that are defined in the .cpp or are not installed
headers this would not be necessary but it's not so hard to add a few
default defined destructors, so do that :)
Avoids all the explicit boilerplate needed, ensures the dependency on
the JSON file ia also set and allows simple export of the setup
in the installed CMake config file, so other projects importing
the config file have the respective CMake macros set as recommended.
Test Plan:
Still builds as before. Touch a plugin metadata JSON file now triggers a moc
rerun. CMake config file contains setup of variables.