-
Notifications
You must be signed in to change notification settings - Fork 391
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sioyek viewer --reuse-instance
#2468
Comments
First: Thanks for the very good issue description. It's clear to me that the |
Opinions? |
Fantastic! I only mentioned adding Once again, thank you for responding and fixing this issue so quickly! |
My pleasure; thanks for the useful and good issue description. I may add |
The default vimtex Sioyek viewer options automatically pass
--reuse-instance
to Sioyek.In this issue I argue that this option should be removed and a
g:vimtex_view_sioyek_options
string should be introduced similar tog:vimtex_view_zathura_options
.What happens when
--reuse-instance
is passed?Every document that is opened in VimTeX will open in the same Sioyek window. If one opens two documents in VimTeX, then one cannot see both of the pdfs at the same time. Even worse, if one already has a pdf open independently of VimTeX, VimTeX will "hijack" that window and replace its contents.
What happens when
--reuse-instance
is not passed?VimTeX spawns a new Sioyek instance for each document and all associated behvaiour is as expected. Despite the
--reuse-instance
option not being passed, when one edits a file the pdf refreshes within the same window, and when one searches with\lv
VimTeX searches within the same Sioyek window. In both cases, VimTeX does not launch a new Sioyek window. This is my desired behaviour. It is exactly the same as the defaultzathura
view method of VimTex.What about users that want to
--reuse
instances?Then can configure Sioyek to always reuse instances in their
$XDG_CONFIG_HOME/sioyek/prefs_user.config
.If VimTeX introduces a
g:vimtex_view_sioyek_options
option, then these users can always add--reuse-instance
to that.Why can't users that don't want to
--reuse
instances do that?Sioyek apparently takes priority for options stated on the command line. That is, if my
$XDG_CONFIG_HOME/sioyek/prefs_user.config
containsshould_launch_new_instance 1
, Sioyek will still--reuse
the instance because that option was passed on the command line. This is also true for Sioyek's command line option--new-instance
which is superseded by--reuse-instance
. This means I can't create a wrapperand pass this to VimTeX as
g:vimtex_view_sioyek_exe
.The text was updated successfully, but these errors were encountered: