-
Notifications
You must be signed in to change notification settings - Fork 263
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
Restrict portrait in overlay to maximum image size when resizing with SwingUtil.constrainTo #1583
Comments
Before submitting a PR a couple notes.
Read over these guidelines: |
… grow beyond its natural size. Make portrait in overlay/statsheet not grow beyond image size. Fixes RPTools#1583
So. If I'm on a hidpi monitor and my gm used portraits of low resolution, you are saying I can not scale those up so I can see them?? |
Maybe make it a per-token option? The picture of the token could either "scale-down" to fit the specified size (lowers its size until it fits inside the panel, but not enlarge it). Or , it could be forced to take the exact size (current behavior). |
If it was made a Token option, the Jamz would still lack control over the portrait size on his display. Could also be an preference option to go along with the setting for portrait size.
I'm guessing that folks will then want:
|
There could be more options but one could argue the GM should have sufficient resolution for hi def players. How about two boxes Statsheet portrait size [Min] and [Max]. Pictures are scaled at min to what the hiresolution player has, and restricted by max. One could fit two text boxes into the space where there's currently one. |
Right now How about we allow or maybe allow or maybe Lots of options... |
This same argument could be used against your example. It wouldn't be "ugly stretching" if the GM supplied appropriate 600x600+ hidpi images. |
Is 0 needed as a value? There's also a setting for having to use shift to reveal the portrait. One could use the number as before for a target sizE to scale to and use 0 as use-picture-native-size. A range sounds easy enough though, could make this 64-200 as suggested yes |
This still needs to be resolved. Here are the options:
I'll need a PR doing either option 2 or 3 in the next couple days or we default to option 1. |
Ultimately I think the range is too complicated. Vote to stay with #1 and stick with the old behavior, right 50% of the time. |
btw realized why the scaled images bug me - the handout and the token draw doesn't scale for quality but for speed. See the difference in handout and a couple of tokens - RIGHT as per current maptool, LEFT when I tweak the graphics2d settings There's code all over the place that modifies graphics2d - looking into whether there's a good place to tweak the appropriate hint that's currently missing [edit:fixed left/right] |
@nmeier Do you have Display Scaling enabled in Windows? |
Roger that. This can be explored later after the move to Java 14 and in the context of some of the newer features such as overlays. |
Is your feature request related to a problem? Please describe.
Currently the statsheet overlay with portrait turned on is forced to a static value from AppPreferences.getPortraitSize. I've bumped up that setting to a large value so I can get a decent sized portrait to show up (larger than 175). This works for those pics that are large enough:
Smaller images get stretched to my new limit of 600 though, which leads to ugly stretching.
Describe the solution you'd like
I think it would be better if the portrait doesn't get stretched beyond what its native resolution is. In my 2nd case above
Describe alternatives you've considered
There could be another option in the preferences but that dialog seems overloaded already.
Additional context
I have a fix ready and figuring out how to make that a pull request.
The text was updated successfully, but these errors were encountered: