Commit graph

2081 commits

Author SHA1 Message Date
Albert Astals Cid
cbae44467a Merge remote-tracking branch 'origin/Applications/18.12' 2018-12-26 12:03:38 +01:00
Albert Astals Cid
58038fed18 Do not crash in files without title-info
BUGS: 402558
2018-12-26 12:02:31 +01:00
Oliver Sander
2e97d58750 Implement several new print scaling options
This patch introduces the choice between three scaling
options for printing:

* Fit to printable area
* Fit to full page
* No scaling

The new options only work with the QPrinter backend.  Therefore
they are only enabled if 'force rasterization' is selected.

Differential Revision: https://phabricator.kde.org/D7962
2018-12-23 02:25:08 +01:00
Albert Astals Cid
004120917d Fix build ^_^ 2018-12-19 00:58:11 +01:00
Albert Astals Cid
c950ea92f5 PDF: Add a "Using Poppler $VERSION" string
It is sometimes useful to know which version of the poppler you're using
and to which you where built

Needs feature introduced in poppler just now
2018-12-19 00:41:37 +01:00
Albert Astals Cid
c4cf125e85 Merge remote-tracking branch 'origin/Applications/18.12' 2018-11-28 23:11:47 +01:00
Alexander Kandaurov
b04a2daa6b Fix DjVu links pointing to pages with different dimensions
Summary:
Currently the coordinates of a link rectangle in a DjVu document are computed with respect to the size of the page the link is pointing to. Because of that, links only appear in correct places if the dimensions of a target page are the same as of the page containing the link.

The attached file demonstrating the issue contains two pages, one in portrait orientation and one in landscape, the first pointing to the second. The active zone for the link is different from where it is in other viewers.
{F6443987}

Reviewers: #okular

Subscribers: okular-devel

Tags: #okular

Differential Revision: https://phabricator.kde.org/D17194
2018-11-28 23:11:00 +01:00
Yuri Chornoivan
5478b2ec92 Fix minor typos 2018-11-14 21:12:15 +02:00
Fabio Bolz
4e353aabee Add unarchiver support for cbr files
Summary:
FEATURE: 339370
When no unrar installed, Okular now utilizes the program unar for extracting the archive and lsar for listing the content in the archive.
lsar is related and comes with a unar installation.

Subscribers: aacid, okular-devel

Tags: #okular

Differential Revision: https://phabricator.kde.org/D15691
2018-11-07 23:30:22 +01:00
Laurent Montel
6f9913802c Remove qt prefix 2018-11-06 13:27:12 +01:00
Albert Astals Cid
ec692e459b Remove unused variables 2018-11-02 18:03:26 +01:00
l10n daemon script
33a5f67eb2 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2018-10-24 05:59:57 +02:00
Yuri Chornoivan
69c7b834d1 Fix minor API docs EBN issues 2018-10-19 09:00:06 +03:00
Yuri Chornoivan
2f014ccd20 Fix minor EBN issues 2018-10-18 22:04:49 +03:00
l10n daemon script
4e9bbfddb0 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2018-10-10 06:37:12 +02:00
l10n daemon script
96f4f27ba6 GIT_SILENT made messages (after extraction) 2018-10-10 04:08:48 +02:00
Dileep Sankhla
e44ff38706 Support setting text color for typewriter annotations
Summary:
Changing typewriter text color can be done in the typewriter properties dialog, or programmatically via new okular API methods TextAnnotation::textColor and TextAnnotation::setTextColor.

poppler >= 0.69 is required to store text color natively inside PDF documents. For other document types, text color is stored as metadata inside the document archive.

This work was done during GSoC 2018. See https://community.kde.org/GSoC/2018/StatusReports/DileepSankhla for details.

Test Plan:
- properties dialog of typewriter annotation has "Font Color" picker
- saving to PDF results in <r> <g> <b> rg operation in /DA
- saving to archive results in fontColor="rrggbb" attribute in metadata.xml

Reviewers: sander

Reviewed By: sander

Subscribers: kde-doc-english, sander, okular-devel

Tags: #okular, #documentation

Differential Revision: https://phabricator.kde.org/D15205
2018-10-04 20:02:55 +02:00
Yuri Chornoivan
39b6e8147d Fix minor EBN issues 2018-09-01 11:25:57 +03:00
Yuri Chornoivan
c04ca1fa96 Fix minor EBN issues 2018-08-31 12:23:45 +03:00
Albert Astals Cid
6a37055351 Merge remote-tracking branch 'origin/Applications/18.08' 2018-08-27 01:09:44 +02:00
Albert Astals Cid
0a8d2f7f85 Fix links being "lost" on save
Summary:
We need to regenerate the links when switching the file
since we won't re-render the pages since we already have
them and link generation is on page render

BUG: 397373

Reviewers: tobiasdeiminger

Reviewed By: tobiasdeiminger

Subscribers: tobiasdeiminger, sander, okular-devel

Tags: #okular

Differential Revision: https://phabricator.kde.org/D14752
2018-08-27 01:09:11 +02:00
Yuri Chornoivan
c7722c4078 Fix minor EBN issues 2018-08-17 21:05:01 +03:00
Gilbert Assaf
fcf148b75b Fixes url whitespaces in epub documents
Summary:
libepub can't handle whitespace url encodings. This is why epub documents containing whitespaces urls aren't
displayed correctly. Since libepub doesn't seem to be maintained anymore, it might be better to fix this issue here.

BUG: 334711

Test Plan: Example epubs are in the ticket.

Reviewers: #okular, aacid

Reviewed By: #okular, aacid

Subscribers: ngraham, aacid, okular-devel

Tags: #okular

Differential Revision: https://phabricator.kde.org/D14310
2018-08-15 19:14:39 +02:00
Oliver Sander
59b8770545 Remove unused file
BUGS: 397429
2018-08-14 10:18:39 +02:00
l10n daemon script
d85fe1df64 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2018-08-04 07:49:58 +02:00
l10n daemon script
bae0e13719 GIT_SILENT made messages (after extraction) 2018-08-04 06:27:24 +02:00
l10n daemon script
f1d3c68115 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2018-08-04 05:43:46 +02:00
l10n daemon script
5f93a0b90e GIT_SILENT made messages (after extraction) 2018-08-04 03:45:00 +02:00
l10n daemon script
55c1cd433e SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2018-08-01 07:46:16 +02:00
l10n daemon script
f670a18bd9 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2018-08-01 05:52:53 +02:00
Gilbert Assaf
57be655c15 Improve picture scaling issues in epub generator
CCBUG: 391625

Test Plan: I tested the file mentioned in the bug report. Pictures look less blurry

Reviewers: #okular

Subscribers: ngraham, aacid, okular-devel

Tags: #okular

Differential Revision: https://phabricator.kde.org/D13766
2018-07-28 23:13:53 +02:00
l10n daemon script
c4570f7e40 GIT_SILENT made messages (after extraction) 2018-07-16 03:26:51 +02:00
l10n daemon script
860dc697ef GIT_SILENT made messages (after extraction) 2018-07-14 03:29:12 +02:00
l10n daemon script
879a46ac55 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2018-07-07 05:17:35 +02:00
Andre Heinecke
18d404c3ee Support additional widget actions in PDF Forms
Summary:
This adds support for actions associated with form fields
through corresponding annotation widgets.

Test Plan:
Still needs a unit test, only tested manually with
the document attached in the task.

Reviewers: #okular, aacid

Reviewed By: #okular, aacid

Subscribers: okular-devel, aacid

Tags: #okular

Maniphest Tasks: T8627

Differential Revision: https://phabricator.kde.org/D12665
2018-05-30 10:04:21 +02:00
Sune Vuorela
aa800c01bc Merge branch 'Applications/18.04' 2018-05-08 21:46:20 +02:00
Sune Vuorela
3e48663fb7 Use a target in FindDiscount (modern cmake) rather than variables
Test Plan: Things still builds

Reviewers: kde-buildsystem, apol

Reviewed By: apol

Subscribers: apol, aacid, #okular

Tags: #okular

Differential Revision: https://phabricator.kde.org/D12672
2018-05-08 21:39:06 +02:00
l10n daemon script
ee57925c57 GIT_SILENT made messages (after extraction) 2018-05-06 06:09:02 +02:00
l10n daemon script
26c40ab7bd GIT_SILENT made messages (after extraction) 2018-05-06 03:31:04 +02:00
Sune Vuorela
13bdb97084 Don't crash if fopen fails
Summary:
If we have a qrc url, all checks so far fails, and this one returns null.

It might also be possible to get here in some race condition.

Reviewers: aacid

Reviewed By: aacid

Subscribers: #okular

Tags: #okular

Differential Revision: https://phabricator.kde.org/D12643
2018-05-01 22:24:24 +02:00
Andre Heinecke
1de0f5465b Add support for chained / next actions
Summary:
This adds support for multiple actions following each
other through the "Next" value of Action dictionaries.

Test Plan: Activates the corresponding part of the visibilitytest.

Reviewers: #okular

Subscribers: sander, aacid

Tags: #okular

Maniphest Tasks: T8278

Differential Revision: https://phabricator.kde.org/D11609
2018-04-30 14:02:49 +02:00
Andre Heinecke
bf90867c13 Add support for dynamic visibility
Summary:
This adds the hidden property to JavaScript fields and
uses it to implement support for HideAction.

Test Plan: Unit test in the next commit.

Reviewers: #okular

Subscribers: aacid

Tags: #okular

Maniphest Tasks: T8274

Differential Revision: https://phabricator.kde.org/D11596
2018-04-23 23:55:01 +02:00
Aleix Pol
c325b342f3 Make some frameworks optional so okular can be built on Android
Summary:
Disables KWallet integration if there's no KWallet, KJS if there's no
KJS and KDocTools.
Here's a list of frameworks that don't work on Android:
https://cgit.kde.org/sysadmin/ci-tooling.git/tree/local-metadata/project-ignore-rules.yaml

Test Plan: Still works locally, ran Okular and Okular Mobile on Android.

Reviewers: #okular, aacid

Subscribers: aacid

Tags: #okular

Differential Revision: https://phabricator.kde.org/D12177
2018-04-16 22:41:19 +02:00
Aleix Pol
52b62306f8 Also don't use KPty code for Android
Changed the defines to something more explicit of what's going on.
2018-04-13 17:44:50 +02:00
Aleix Pol
c8b0677a25 Remove unneeded dependencies 2018-04-13 17:05:16 +02:00
Albert Astals Cid
5ea455fe68 xps: fix file font unloading
Don't unload all fonts, only the ones this file loaded
2018-04-08 13:00:08 +02:00
Albert Astals Cid
985e06a2f5 Fix crash in some more xps files
Some more tweaks to path resolving.

Don't prepend a / in entryPath if path already starts with /
Fonts can also have relative paths, so use the absolutePath before
calling getFontByName

BUGS: 392826
2018-04-08 12:50:46 +02:00
Albert Astals Cid
7e1832c57a autotests: Only compile parttest if you have the pdf support
I'm sure other tests fail to run too, but this one was failing to
compile :D
2018-03-21 00:31:05 +01:00
Andre Heinecke
6897e042df Add support to set read only from scripts
Summary:
This makes it possible to set the read only state from
scripts. Requires Poppler master with the patch attached to the parent task.

Reviewers: #okular

Subscribers: aacid

Tags: #okular

Maniphest Tasks: T8097

Differential Revision: https://phabricator.kde.org/D10867
2018-03-20 23:19:29 +01:00
Albert Astals Cid
adfb3cc2d6 Add detection for poppler 0.64 2018-03-20 23:19:26 +01:00