Marcus Nilsson
3af71c406d
PDFViewer: Add zoom in/out/reset menu actions
...
Make PDFViewer::zoom_in() & ::zoom_out() public and add menu and toolbar
actions. Also add an action for zoom reset.
2022-01-06 21:25:02 +01:00
Elyse
086615535f
Everywhere: Use 'decrease_slider_by()' method from AbstractSlider
...
The same idea as 'increase_slider_by()', it helps us to avoid repeating
the pattern 'set_value(value() - delta)'.
2021-12-30 14:31:50 +01:00
Elyse
d53e1fa1fa
Everywhere: Use 'increase_slider_by()' method from AbstractSlider
...
This method help us to avoid repeating the pattern
'set_value(value() + delta)'.
2021-12-30 14:31:50 +01:00
Andreas Kling
0de33b3d6c
LibGfx: Use ErrorOr<T> for Bitmap::try_create()
...
Another one that was used in a fajillion places.
2021-11-08 00:35:27 +01:00
Andreas Kling
69c4614a94
LibGfx: Use ErrorOr<T> for Bitmap::rotated()
2021-11-08 00:35:27 +01:00
Andreas Kling
c7d891765c
LibGfx: Use "try_" prefix for static factory functions
...
Also mark them as [[nodiscard]].
2021-07-21 18:02:15 +02:00
FalseHonesty
4f0a75224c
PDFViewer: Update the page number when scrolling between pages
2021-06-22 06:26:44 +04:30
Andreas Kling
076018b74b
PDFViewer: Ignore wheel events when there is no document loaded
2021-05-18 21:25:35 +02:00
Matthew Olsson
fe2d4d85c4
PDFViewer: Add some padding to the outside of the page
2021-05-18 16:35:23 +02:00
Matthew Olsson
c3c2121b57
PDFViewer: Allow zooming in and out + scrolling
...
When holding ctrl and scrolling, the page will be zoomed in an out.
When zoomed in on a page, scrolling with move vertically up and down
the page (or horizontally if shift is being held).
In order to speed up zooming, zoomed bitmaps are cached per-page at
each distinct zoom level. This cache is cleared every 30 seconds to
prevent OOM problems.
2021-05-18 16:35:23 +02:00
Matthew Olsson
d5f94aaa7b
LibPDF/PDFViewer: Support rotated pages
2021-05-18 16:35:23 +02:00
Matthew Olsson
f7ea1eb610
Applications: Add a very simple PDFViewer
2021-05-18 16:35:23 +02:00