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

Specifying a file to open at the command line forces zoom to 100% #74

Open
ssokolow opened this issue May 8, 2020 · 2 comments
Open
Labels

Comments

@ssokolow
Copy link

ssokolow commented May 8, 2020

I'm running a copy of rx installed with cargo install --git https://github.com/cloudhead/rx --tag v0.4.0 on Kubuntu Linux 16.04 LTS (64-bit) and I observe the following undesirable behaviour.

With the following in .rxrc in the current directory...

-- Set Cavernas tile size
f/resize 8 8
zoom 8.0

-- Work around the apparent inability to display "actual in-game size" and
-- "preferred editing size" simultaneously
map / :zoom 4.0
map m :zoom 16.0

-- Remap Enter to clone the last frame rather than inserting a blank one
map <return> :f/clone

-- Set Cavernas palette
p/clear
p/add #3e3d4c
p/add #5a5a63
p/add #847f7f
p/add #bcb19f
p/add #21263f
p/add #394071
p/add #4063b2
p/add #efe7ce
p/add #3a5339
p/add #6b7b39
p/add #84ad42
p/add #c0461f
p/add #6c4f40
p/add #a5845a
p/add #cead73
p/add #673347
  1. Running rx works as expected
  2. Running rx player.png obeys every command in .rxrc except the zoom 8.0 (whether or not player.png exists).

(Which suggests to me that specifying a file on the command line is causing it do something equivalent to injecting a zoom 1.0 after evaluating .rxrc.)

@cloudhead
Copy link
Owner

Yeah, the reason for this is that zoom is a command that operates on the currently active view, not a global setting. We could add a view/zoom setting for that purpose that would be read when editing new views.

@ssokolow
Copy link
Author

As long as it's clearly documented, that sounds like a good way to go about it.

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

No branches or pull requests

2 participants