sioyek icon indicating copy to clipboard operation
sioyek copied to clipboard

Two-page/ultrawide view

Open alfureu opened this issue 3 years ago • 7 comments

Absolutely love the software, please keep up the good work!

I was wondering whether a two-page view could be introduced, as some of us have an ultrawide monitor, and it would enhance readability across pages...

alfureu avatar Nov 10 '21 09:11 alfureu

Duplicate of https://github.com/ahrm/sioyek/issues/64 . As I explained there, it is unlikely that this feature will be added to sioyek anytime soon. I will add it only if I can find a clean way to implement it without complicating the code too much.

ahrm avatar Nov 10 '21 10:11 ahrm

Ah, I see. It is weird, as I have to zoom out the text quite considerably, with 2/3 of the screen white (makes it hard to read). Also, the window size in Win10 is not really possible to change or move, so I cannot give it a portion of the screen and use other parts for something else. At least make the window then resizeable please, that would help a lot!

alfureu avatar Nov 10 '21 11:11 alfureu

Ah, I see. It is weird, as I have to zoom out the text quite considerably, with 2/3 of the screen white (makes it hard to read). Also, the window size in Win10 is not really possible to change or move, so I cannot give it a portion of the screen and use other parts for something else. At least make the window then resizeable please, that would help a lot!

The window should be resizable and movable. Is it not working for you?

ahrm avatar Nov 10 '21 12:11 ahrm

No, I cannot change the size for some reason. Also, if I hit alt+space the resize option is not enabled:

image

alfureu avatar Nov 10 '21 12:11 alfureu

No, I cannot change the size for some reason. Also, if I hit alt+space the resize option is not enabled:

image

Well, in this picture the window is maximized. First you need to minimize the window and then you can resize it.

ahrm avatar Nov 10 '21 14:11 ahrm

Ah, I see, sorry, got confused also with the fullscreen option. When I clicked on the Restore button (!) on the right, nothing changed, the window remained maximized. However, when I clicked on the Restore option in the menu (on the left), the window changed accordingly. Maybe something weird is happening with the button? In any case, now it works, I can resize the window.

alfureu avatar Nov 10 '21 14:11 alfureu

Note that while we probably will not natively support two-page view, It can easily be replicated using scripts. I added a simple script to create a dual panel version of current document here: https://github.com/ahrm/sioyek/blob/main/scripts/dual_panelify.py

Here is how it looks:

https://user-images.githubusercontent.com/6392321/182888181-e48cf3d3-7b6a-4fe1-b632-03b4c019f921.mp4

Note that the settings described in the python file probably won't work with 1.4 release version of sioyek and require new commits (this script can still be used in old versions of sioyek using the old execute_command_* style configs and %1 instead of %{file_path}).

ahrm avatar Aug 04 '22 15:08 ahrm

@ahrm any chance you know how to tweak this script for the 2.0 release? I configured it as requested in script comments, but get this error text in terminal during execution:

QString::arg: Argument missing: python /Users/jake/.sioyek/dual_panel.py "%{sioyek_path}" "%{file_path}", /Users/jake/reading/papers/cryptography/gg18.pdf

It appears maybe sioyek_path is no longer defined. I tried tweaking the variables and parsing sys.argv[1] by splitting the string at ,, but my python is poor and I had no luck.

jakehemmerle avatar Apr 11 '23 17:04 jakehemmerle

That's just an unimportant warning not an error (there are some other possible arguments that are missing). I don't know what the issue may be but it is something else (you could try pasting the command into a command line (after replacing % variables with the correct values ) and see if there are any errors).

ahrm avatar Apr 11 '23 19:04 ahrm

Is there any way to change whether the odd or even pages are to the left? Some pdfs have a cover page that offsets the dual view by one page, putting the pages on the 'wrong' side compared to the printed version. Particularly important for two page spreads.

Examples

preferred: correct

vs flipped: swapped

SuperContraptionGuy avatar Apr 24 '24 19:04 SuperContraptionGuy