Calixte Denizet
e737638a40
Add a HTML containter for locked FreeText annotations in order to be able to display a popup (follow-up iof #17070 )
2023-10-05 14:01:34 +02:00
calixteman
c4c24c6d18
Merge pull request #17070 from calixteman/17069
...
Update the noHTML flag to take into account the hasOwnCanvas one (fixes #17069 )
2023-10-05 11:10:40 +02:00
Calixte Denizet
335cea22b3
[Editor] Add role=spinbutton to resizers when they're used with the keyboard
2023-10-04 21:30:06 +02:00
Calixte Denizet
40b1d92044
Update the noHTML flag to take into account the hasOwnCanvas one ( fixes #17069 )
...
When an element has the hasOwnCanvas flag we must have an HTML container to attach
the canvas where the element will be rendered.
So the noHTML flag must take this information into account:
- in some cases the noHTML flag is resetted depending on the hasOwnCanvas value;
- in some others, the hasOwnCanvas flag is set depending on the value of noHTML.
2023-10-04 18:06:21 +02:00
calixteman
40d6b0e1bf
Merge pull request #17062 from calixteman/resize_keyboard
...
[Editor] Support resizing editors with the keyboard (bug 1854340)
2023-10-04 13:55:04 +02:00
Calixte Denizet
05ca3fd99b
[Editor] Support resizing editors with the keyboard (bug 1854340)
2023-10-04 12:57:37 +02:00
Jonas Jenwald
bf9c33e60f
Add support for "GoToE" actions with destinations (issue 17056)
...
This shouldn't be very common in practice, since "GoToE" actions themselves seem quite uncommon; see PR 15537.
2023-10-04 11:14:23 +02:00
Calixte Denizet
1be9bbd2e1
Compute correctly the bounding box of a transformed rectangle ( fixes #17065 )
2023-10-03 23:50:59 +02:00
Jonas Jenwald
f113320bd5
Ensure that readonly TextWidget-annotations are rendered when forms are disabled (issue 17064)
...
To reduced the risk of regressing something else, given that the issue only applies to a (for the default viewer) non-default configuration, this patch is purposely limited to only TextWidget-annotations in the display layer.
2023-10-03 21:26:08 +02:00
Jonas Jenwald
426209c6e6
Merge pull request #16699 from Snuffleupagus/rm-svg
...
[api-major] Remove the SVG back-end (PR 15173 follow-up)
2023-10-03 15:13:14 +02:00
Jonas Jenwald
0edc490e1b
Merge pull request #16774 from Snuffleupagus/rm-deprecated-options
...
[api-major] Remove various deprecated functionality and options
2023-10-03 15:12:39 +02:00
Calixte Denizet
e3fbe2908a
[Editor] Use the alt text to descibe the canvas used to display the image
2023-10-02 23:28:11 +02:00
Calixte Denizet
eebd251552
[Editor] Don't show the alt-text button when the alt-text dialog is visible
...
This way, the button doens't cover the image.
2023-10-02 20:34:30 +02:00
Jonas Jenwald
3ced0dec1b
[api-major] Remove the SVG back-end (PR 15173 follow-up)
...
This has been deprecated since version `2.15.349`, which is a year ago.
Removing this will also simplify some upcoming changes, specifically outputting of JavaScript modules in the builds.
2023-10-01 23:14:29 +02:00
Calixte Denizet
b65b079ceb
[Editor] Make a deleted (when it was invisible) editor undoable
...
When the editor is invisible (because on a non-rendered page) its parent is null.
But when we undo its deletion, we need to have a parent to attach it.
2023-09-29 16:19:11 +02:00
calixteman
b6d75e736a
Merge pull request #17038 from ayushmourya/master
...
Make downloadManager optional in JSDoc types
2023-09-28 17:23:33 +02:00
Calixte Denizet
4f6fa35a28
[Editor] Disable pointer events in the parent layer while an editor is resized
2023-09-28 15:09:50 +02:00
Calixte Denizet
f2196f7803
StructParents entry isn't required on pages with no tagged contents (bug 1855641)
2023-09-28 14:23:10 +02:00
Calixte Denizet
8417eee0c1
[Editor] Clear the different timeouts when destroying
2023-09-28 12:03:11 +02:00
Calixte Denizet
bdb8410ad4
[Editor] Disabled the alt-text button when the editor is being resized
2023-09-27 15:13:17 +02:00
ayush
87a1baf29f
docs: Make downloadManager optional in JSDoc
2023-09-27 12:47:50 +05:30
Calixte Denizet
3ee5268a23
[Editor] Don't try to add data to the struct tree when there is no accessibilityData (bug 1855157)
2023-09-26 11:02:14 +02:00
calixteman
5f75404bc3
Merge pull request #17030 from calixteman/editor_remove_editing_class
...
[Editor] Remove the class fooEditing from the layer when destroying it
2023-09-25 19:44:50 +02:00
Calixte Denizet
71376f089c
[Editor] Remove the class fooEditing from the layer when destroying it
...
and simplify the way to handle the different types of editors.
2023-09-25 18:56:11 +02:00
Calixte Denizet
29bc103fad
[Editor] Slightly postpone the move in the DOM in order to not block the UI (bug 1854991)
2023-09-25 18:18:01 +02:00
Jonas Jenwald
f87ec67ab1
[api-major] Remove various deprecated functionality and options
2023-09-23 17:44:09 +02:00
Jonas Jenwald
1df31c0284
Use one noContextMenu
function in both the src/- and web/-folders
...
Currently we duplicate this event handler function in multiple places, which seems unnecessary.
2023-09-23 15:37:13 +02:00
Calixte Denizet
88f3ed7745
[Editor] Disable context menu on alt-text button and in the associated dialog
...
but keep it for the text area.
Disable pointerdown on the alt-text button to disable dragging the editor
when the button is clicked (especially when slightly moving the mouse
between the down and the up).
2023-09-22 23:27:55 +02:00
Calixte Denizet
d5936d9a15
[Editor] Let the Save button always enabled in the alt-text dialog
2023-09-22 20:46:29 +02:00
Calixte Denizet
050093c9f5
[Editor] Tweak the save flow in the alt-text dialog
...
When the user edit an existing alt-text and remove it, we want to be able
to save this state and consequently remove the done state from the
alt-text button.
Remove the button from its parent when the editor is removed: it should
help to save few Kb of memory.
2023-09-22 17:10:20 +02:00
calixteman
2fc8ab3477
Merge pull request #17002 from calixteman/alt_text_mask
...
[Editor] Avoid to darken the current editor when opening the alt-text dialog
2023-09-22 12:17:21 +02:00
Calixte Denizet
6545551e76
[Editor] Avoid to darken the current editor when opening the alt-text dialog
2023-09-21 20:44:53 +02:00
Jonas Jenwald
4cedc12341
Restore the collectFields
parameter in the Annotation code (issue 17000)
...
Rather than trying to be "clever" here, and possibly affect code readability negatively, let's just restore the `collectFields` parameter to address the unneeded parsing that now happens when printing new Annotations.
2023-09-21 19:49:31 +02:00
calixteman
237b8ce4a8
Merge pull request #16988 from calixteman/alt_text_dialog_others
...
[Editor] Tweak few values after review from UX
2023-09-21 11:03:19 +02:00
Calixte Denizet
b5d18006a7
[Editor] Tweak few values after review from UX
2023-09-21 10:52:58 +02:00
Calixte Denizet
c90ea2314e
[Editor] Add an aria-label to the alt-text button depending on its state
2023-09-20 21:56:16 +02:00
Calixte Denizet
0a278ef0bc
[Editor] Add more telemetry for the 'add image' feature (bug 1853960)
2023-09-20 17:23:23 +02:00
Calixte Denizet
7952a36384
[Editor] Add a tooltip showing the alt text when hovering the alt-text button (bug 1844952)
2023-09-20 10:50:28 +02:00
Calixte Denizet
c162b004ce
[Editor] Remove copy/paste listener when alt text dialog is displayed
2023-09-19 22:41:47 +02:00
calixteman
54f6264d5b
Merge pull request #16977 from calixteman/add_alt_text
...
[Editor] Allow the user to add and save an alt-text for images (bug 1844952)
2023-09-19 21:59:59 +02:00
Calixte Denizet
c12049db07
[Editor] Allow the user to add and save an alt-text for images (bug 1844952)
2023-09-19 21:46:48 +02:00
Jonas Jenwald
0ac8f33e13
Ignore optional content with missing /Type-entries
...
In the rare situation that an optional content dictionary lacks a /Type-entry we currently throw, which may prevent e.g. Form XObjects from rendering completely.
Fixes https://bugs.ghostscript.com/show_bug.cgi?id=707147
2023-09-19 14:11:03 +02:00
Calixte Denizet
a216836fd5
[Editor] Add a button to trigger a dialog for adding an alt text (bug 1844952)
2023-09-18 15:07:09 +02:00
calixteman
3afb717eed
Merge pull request #16938 from calixteman/update_struct_tree
...
[Editor] Add the ability to create/update the structure tree when saving a pdf containing newly added annotations (bug 1845087)
2023-09-18 13:04:52 +02:00
Calixte Denizet
a8573d4e1b
[Editor] Add the ability to create/update the structure tree when saving a pdf containing newly added annotations (bug 1845087)
...
When there is no tree, the tags for the new annotions are just put under the root element.
When there is a tree, we insert the new tags at the right place in using the value
of structTreeParentId (added in PR #16916 ).
2023-09-16 18:34:58 +02:00
Jonas Jenwald
0304b65fcd
Remove the closure from the CipherTransformFactory
class
...
Now that modern JavaScript is fully supported also in the worker-thread we no longer need to keep old closures, which slightly reduces the size of the code.
2023-09-16 16:34:24 +02:00
Tim van der Meij
7f8de83e96
Merge pull request #16957 from Snuffleupagus/SaveDocument-more-await
...
Use `await` even more in the "SaveDocument" worker-thread handler
2023-09-16 14:31:05 +02:00
Tim van der Meij
89c8f90a14
Merge pull request #16956 from Snuffleupagus/opMap-rm-getLookupTableFactory
...
Simplify the `EvaluatorPreprocessor.opMap` getter a little bit
2023-09-16 13:51:33 +02:00
Jonas Jenwald
ff96c413d3
Use await
even more in the "SaveDocument" worker-thread handler
...
Given that the function is already asynchronous we can make use of `await` even more and reduce the amount of indentation a little bit.
2023-09-16 13:06:48 +02:00
Jonas Jenwald
316d1ec5ef
Simplify the EvaluatorPreprocessor.opMap
getter a little bit
...
Given that this is a shadowed getter, the `opMap` is already lazily initialized and it shouldn't be necessary to *also* use the `getLookupTableFactory` helper function here. Looking at the history of the code, it seems that this is simply a leftover from before JavaScript classes existed.
2023-09-16 12:26:38 +02:00