Commit Graph

16027 Commits

Author SHA1 Message Date
Jonas Jenwald
635bd12050 Update l10n files 2022-07-31 10:23:00 +02:00
Tim van der Meij
c7b71a3376
Merge pull request #15215 from Snuffleupagus/optional-content-initial
[api-minor] Improve how we disable `PDFThumbnailView.setImage` for documents with Optional Content
2022-07-30 12:04:23 +02:00
Jonas Jenwald
ee8fab929c
Merge pull request #15244 from calixteman/15241
[Editor] Add an editor in the annotation storage only when it's non-empty (#15241)
2022-07-29 20:58:53 +02:00
Calixte Denizet
e819834505 [Editor] Add an editor in the annotation storage only when it's non-empty (#15241) 2022-07-29 18:00:52 +02:00
Jonas Jenwald
cfdf940c05
Merge pull request #15242 from calixteman/ink_avoid_move
[Editor] Avoid to slightly move ink editor when undoing/redoing
2022-07-29 17:17:40 +02:00
Jonas Jenwald
6bb800a7e1
Merge pull request #15240 from Snuffleupagus/web-factory-object
[api-minor] Change the various factories, in the viewer, to accept Objects
2022-07-29 17:00:20 +02:00
Calixte Denizet
9a464b70c1 [Editor] Avoid to slightly move ink editor when undoing/redoing 2022-07-29 16:53:03 +02:00
Jonas Jenwald
2e059727a9 [api-minor] Change the various factories, in the viewer, to accept Objects
Currently all of these factories take a bunch of (randomly ordered) parameters, which first of all doesn't look that nice in the `PDFPageView`-class when some parameters are optional.
Furthermore, it also makes deprecation/removal of any existing parameter a *potentially* breaking change.
Finally, using an Object will provide a small amount of "documentation" at the call-site which isn't really the case with a bunch of "regular" parameters.

Note that all of the `viewer component` examples still work as-is with this patch, which is why I don't believe that we necessarily have to deprecate in the usual fashion.
2022-07-29 16:31:04 +02:00
Jonas Jenwald
80689c6444
Merge pull request #15238 from calixteman/bug1782186
Fix wrong order of arguments when calling the CipherTransform ctor (bug 1782186)
2022-07-29 13:22:25 +02:00
Calixte Denizet
d092a85b6c Fix wrong order of arguments when calling the CipherTransform ctor (bug 1782186) 2022-07-29 12:46:45 +02:00
Jonas Jenwald
0c5afe9269
Merge pull request #15232 from calixteman/15229
Fix text selection with hdpi screens (#15229)
2022-07-29 09:50:49 +02:00
Calixte Denizet
51c8e2f3ab Fix text selection with hdpi screens (#15229) 2022-07-28 19:44:13 +02:00
Jonas Jenwald
d7cc47d73a
Merge pull request #15235 from Snuffleupagus/annot-isUsingOwnCanvas
Ensure that the `isUsingOwnCanvas`-parameter is consistently included in operatorLists (PR 14247 follow-up)
2022-07-28 17:04:45 +02:00
Jonas Jenwald
de02d30b00
Merge pull request #15236 from Snuffleupagus/editor-test-opacity
Set `opacity` in the reference tests (PR 15219 follow-up)
2022-07-28 15:56:26 +02:00
Jonas Jenwald
2cad5cf45b Set opacity in the reference tests (PR 15219 follow-up)
Without these changes in the manifest, the affected test-cases fail to render correctly.
2022-07-28 14:35:09 +02:00
Jonas Jenwald
2fb083f3e2 Ensure that the isUsingOwnCanvas-parameter is consistently included in operatorLists (PR 14247 follow-up)
Currently some `OPS.beginAnnotation` arguments will contain a `Number` value for the `isUsingOwnCanvas`-parameter, or in some cases an `undefined` value, which is inconsistent from an API perspective.
2022-07-28 13:37:37 +02:00
Jonas Jenwald
b06d190451
Merge pull request #15217 from calixteman/15216
[Editor] Simplify the strings for the tools in the UI
2022-07-28 10:15:59 +02:00
Calixte Denizet
a85359b031 [Editor] Simplify the strings for the tools in the UI 2022-07-28 10:02:59 +02:00
calixteman
e515a88faf
Merge pull request #15234 from calixteman/reset_undo_queue
[Editor] Reset the queue when a command is added after having undone all the commands
2022-07-28 09:43:10 +02:00
Calixte Denizet
3c10c71a91 [Editor] Reset the queue when a command is added after having undone all the commands 2022-07-27 23:23:28 +02:00
calixteman
085dd0a6c5
Merge pull request #15233 from calixteman/lock_undo
[Editor] Avoid to add unexpected commands in the undo/redo queue when undoing/redoing (bug 1781790)
2022-07-27 20:10:26 +02:00
Calixte Denizet
759116f4c5 [Editor] Avoid to add unexpected commands in the undo/redo queue when undoing/redoing (bug 1781790)
We can undo/redo a command which will at some point add a command in the queue: typically
it can happening when redoing an addition.
So the idea is to lock the queue when undoing/redoing.
2022-07-27 19:12:06 +02:00
calixteman
89d1892959
Merge pull request #15219 from calixteman/editor_opacity
[Editor] Add the possibility to change line opacity in Ink editor
2022-07-27 18:57:37 +02:00
Calixte Denizet
7831a100b3 [Editor] Add the possibility to change line opacity in Ink editor 2022-07-27 18:46:25 +02:00
calixteman
45b9e8417d
Merge pull request #15231 from calixteman/bug1781763
[Editor] Don't set as active an editor which is not (bug 1781763)
2022-07-27 18:45:07 +02:00
calixteman
c9a4062c37
Merge pull request #15230 from calixteman/bug1781762
[Editor] Avoid editor creation/selection on right click (bug 1781762)
2022-07-27 18:27:55 +02:00
Calixte Denizet
ce4144eee4 [Editor] Avoid editor creation/selection on right click (bug 1781762) 2022-07-27 17:53:22 +02:00
Calixte Denizet
59580d8986 [Editor] Don't set as active an editor which is not (bug 1781763) 2022-07-27 14:46:36 +02:00
Jonas Jenwald
8ebd2d3dfd
Merge pull request #15221 from Snuffleupagus/issue-15220
Support images with /Filter-entries that contain Arrays (issue 15220)
2022-07-25 11:14:51 +02:00
calixteman
14a8b819dc
Merge pull request #15218 from calixteman/mac_ctrl
[Editor] Fix few keyboard shortcuts on mac
2022-07-25 09:50:45 +02:00
Jonas Jenwald
fc018ea9ea Support images with /Filter-entries that contain Arrays (issue 15220)
This patch "borrows" the code found in the `Parser.makeInlineImage`-method, to ensure that JBIG2 and JPX images can be rendered correctly.
2022-07-25 08:41:37 +02:00
Calixte Denizet
85f3e23e7f [Editor] Fix few keyboard shortcuts on mac 2022-07-24 22:22:27 +02:00
Jonas Jenwald
37dc0e7d6e Limit the PDFPageView._isStandalone handling to the GENERIC viewer
This code is completely unnecessary in e.g. the Firefox PDF Viewer.
2022-07-24 17:29:37 +02:00
Jonas Jenwald
3446f15bf3 Improve how we disable PDFThumbnailView.setImage for documents with Optional Content (PR 12170 follow-up)
Rather than always disable `PDFThumbnailView.setImage` as soon as user has changed the visibility of the Optional Content, we can utilize the new method added in the previous patch to improve thumbnail performance. Note in particular how, in the old code, even *resetting* of the Optional Content to its default state wouldn't enable `PDFThumbnailView.setImage` again.

While slightly unrelated, this patch also removes the `PDFThumbnailViewer._optionalContentConfigPromise`-property since it's completely unused.
2022-07-24 17:29:37 +02:00
Jonas Jenwald
ceb4f8a6ab [api-minor] Add a new method, in OptionalContentConfig, to detect the initial Optional Content visibility state
This will allow us to improve the `PDFThumbnailView.setImage` handling in the viewer, and thanks to the added caching this should be reasonbly efficient.
2022-07-24 17:29:37 +02:00
Jonas Jenwald
f3d76b42b3 Ensure that OptionalContentGroup.visible cannot be modified from the "outside"
Given that Optional Content visibility is only intended/supported to be updated via the `OptionalContentConfig.setVisibility`-method, this patch actually enforces that now.
Note that this will be used by the next patch in the series, and will help prevent inconsistent state in the `OptionalContentConfig`-class.

*Please note:* This patch also uncovered a pre-existing bug, related to iterating through the visibility groups in the constructor, for the `baseState === "OFF"` case.
2022-07-24 17:28:08 +02:00
Jonas Jenwald
2d6ebc5801 Convert the OptionalContentConfig to use *properly* private fields/methods
To ensure that this data cannot be directly changed from the outside, use private fields/methods now that those are available.
2022-07-24 13:40:59 +02:00
Tim van der Meij
9cc5260b68
Merge pull request #15214 from Snuffleupagus/update-packages
Update packages and translations
2022-07-24 12:17:47 +02:00
Jonas Jenwald
ca9172ddec Update l10n files 2022-07-24 08:56:47 +02:00
Jonas Jenwald
878e2f726a Update npm packages 2022-07-24 08:54:23 +02:00
Jonas Jenwald
bf00068731
Merge pull request #15211 from calixteman/selection
[Editor] Fix multi-selection on touch screens
2022-07-22 16:55:12 +02:00
Calixte Denizet
a118e268af [Editor] Fix multi-selection on touch screens 2022-07-22 16:11:58 +02:00
calixteman
71db08a139
Merge pull request #15188 from calixteman/touch
[Editor] Replace mouse events by pointer ones (bug 1779015)
2022-07-22 14:14:38 +02:00
Calixte Denizet
7b25b39a17 [Editor] Replace mouse events by pointer ones (bug 1779015)
The goal is to be able to edit a pdf on a touchscreen.
2022-07-22 13:46:39 +02:00
calixteman
185102bd69
Merge pull request #15210 from calixteman/ink_select
[Editor] Unselect correctly removed editors
2022-07-22 13:31:08 +02:00
Calixte Denizet
5bbe0d0782 [Editor] Unselect correctly removed editors
- After undoing a deletion of several editors, they appeared to be selected (they had a red border)
when in fact they were not, consequently, this patch aims to remove the selectedEditor class when
an editor is removed;
- Add a test with some ink editors.
2022-07-22 13:21:08 +02:00
calixteman
6138e16ce2
Merge pull request #15200 from calixteman/multiple_selection
[Editor] Add the ability to make multiple selections (bug 1779582)
2022-07-21 23:15:16 +02:00
Calixte Denizet
d6b9ca48a5 [Editor] Add the ability to make multiple selections (bug 1779582)
- several editors can be selected/unselected using ctrl+click;
- and then they can be copied, pasted, their properties can be changed.
2022-07-21 22:53:52 +02:00
calixteman
9fe4a667bd
Merge pull request #15206 from calixteman/simplify_command_manager
[Editor] Simplify the command manager
2022-07-21 22:13:49 +02:00
Tim van der Meij
e2f6ec83d6
Merge pull request #15183 from Snuffleupagus/rm-svgviewer-example
Remove the `svgviewer` example
2022-07-21 20:18:54 +02:00