Skip to content
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

ExternalViewers #4397

Closed
H5820121 opened this issue Jul 24, 2024 · 9 comments
Closed

ExternalViewers #4397

H5820121 opened this issue Jul 24, 2024 · 9 comments

Comments

@H5820121
Copy link

Can you please add arguments to ExternalViewers for the coordinates, and if possible for the zoom, something like that %x %y %z?
Thanks!

@GitHubRulesOK
Copy link
Collaborator

Unclear how that would be defined SumatraPDF based on MuPDF uses screen Top Left XY many related aps would use PDF system of Bottom Left but again many use different scalar / unit for systems call.

You can call Edge.lnk test.pdf#page=%p&zoom=175 but trying to force page location is highly variable and fickle among browsers

image

above was from

CommandLine = "C:\Program Files\Microsoft\Edge\Application\msedge.exe" --pdf-upsell-disabled --enable-features=msEdgeEpubReaderEnabled  "file:///%1#page=%p&zoom=175"

@H5820121
Copy link
Author

H5820121 commented Jul 25, 2024 via email

@GitHubRulesOK
Copy link
Collaborator

GitHubRulesOK commented Jul 25, 2024

@H5820121

unclear of what the %x is supposed to be 4 years ago there were 2 examples for different user requirements one to top of page the other to middle top, but there is no concept of "middle" in a PDF

ExternalViewers [
	[
		CommandLine = "C:\Program Files\SumatraPDF\SumatraPDF.exe" -reuse-instance -scroll 47,58
		Name = Brutalscroll
		Filter = *.pdf
	]
]

and

ExternalViewers [
	[
		CommandLine = "C:\Program Files\SumatraPDF\SumatraPDF.exe" "%1" -page %p -scroll 407,58
		Name = &Back To Second Column
		Filter = *.pdf
	]
]

@H5820121
Copy link
Author

H5820121 commented Jul 25, 2024 via email

@kjk
Copy link
Member

kjk commented Jul 25, 2024

For your use case, you probably can use DDE commands: https://www.sumatrapdfreader.org/docs/DDE-Commands

@H5820121
Copy link
Author

H5820121 commented Jul 25, 2024 via email

@H5820121
Copy link
Author

H5820121 commented Jul 25, 2024 via email

@GitHubRulesOK
Copy link
Collaborator

GitHubRulesOK commented Jul 25, 2024

@kjk
I think the point here is similar to what Nod5 wanted some time ago which was a DDE or CLI export of some current X Y Z either mouse OR top left corner position to be applied externally.

Thus 2 / 4 different OUTPUTS but perhaps both a current zoom level

for example #483 and #1411

@kjk
Copy link
Member

kjk commented Jul 27, 2024

This is just a can of worms.

It's unclear what the coordinate should be and there is no standard so it would likely have to be customized for each program you want to launch.

I'll accept a PR but no plans to work on this myself.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants