[Commits] [wesnoth/wesnoth] 037adf: GUI2/Panel: remove border from small-res box_displ...
GitHub
noreply at github.com
Tue Jun 27 06:25:57 UTC 2017
Branch: refs/heads/accelerated_rendering
Home: https://github.com/wesnoth/wesnoth
Commit: 037adf1f377b89663a4f61fd22787103e155fe5c
https://github.com/wesnoth/wesnoth/commit/037adf1f377b89663a4f61fd22787103e155fe5c
Author: Charles Dang <exodia339 at gmail.com>
Date: 2017-06-27 (Tue, 27 Jun 2017)
Changed paths:
M data/gui/widget/panel_box_display.cfg
Log Message:
-----------
GUI2/Panel: remove border from small-res box_display_no_blur_no_border definition
Commit: f2b5d503cc2d1e94a55ac2ec9621c2ff605205d0
https://github.com/wesnoth/wesnoth/commit/f2b5d503cc2d1e94a55ac2ec9621c2ff605205d0
Author: Charles Dang <exodia339 at gmail.com>
Date: 2017-06-27 (Tue, 27 Jun 2017)
Changed paths:
M src/floating_label.cpp
Log Message:
-----------
Floating Label: formatting update
Commit: 27cf9e268927cb531d31c529d33da428ec537587
https://github.com/wesnoth/wesnoth/commit/27cf9e268927cb531d31c529d33da428ec537587
Author: Charles Dang <exodia339 at gmail.com>
Date: 2017-06-27 (Tue, 27 Jun 2017)
Changed paths:
M src/floating_label.cpp
M src/floating_label.hpp
Log Message:
-----------
Refactored floating_label implementation
* Store label as a texture instead of creating a texture from a surface every draw cycle
* Restored expired label removal and alpha fadeout (was accidentally removed earlier in my refactoring)
* Use alpha field of bg_color member for background color
* Draw tooltip backgrounds procedurally instead of with surfaces and part of the label texture itself.
See included comment for small caveat.
Commit: 254d41244a2520b53e9017b6bbd24bd9cf72d871
https://github.com/wesnoth/wesnoth/commit/254d41244a2520b53e9017b6bbd24bd9cf72d871
Author: Charles Dang <exodia339 at gmail.com>
Date: 2017-06-27 (Tue, 27 Jun 2017)
Changed paths:
M src/display.cpp
Log Message:
-----------
Display: restrict render clip rect setter to map drawing scope only
This prevents tooltips from being cut off.
Commit: 99f52d01e9747b4a7b922be2b1ce6923006b3dcb
https://github.com/wesnoth/wesnoth/commit/99f52d01e9747b4a7b922be2b1ce6923006b3dcb
Author: Charles Dang <exodia339 at gmail.com>
Date: 2017-06-27 (Tue, 27 Jun 2017)
Changed paths:
M src/tooltips.cpp
Log Message:
-----------
Fixup the floating label commit
Commit: 7aa79c38168d2e41616dae1c34cbe26c41e5bc34
https://github.com/wesnoth/wesnoth/commit/7aa79c38168d2e41616dae1c34cbe26c41e5bc34
Author: Charles Dang <exodia339 at gmail.com>
Date: 2017-06-27 (Tue, 27 Jun 2017)
Changed paths:
M src/sdl/window.cpp
M src/sdl/window.hpp
M src/video.cpp
Log Message:
-----------
Fixed some issues with the resolution list (fixes #1772)
Awhile back I added some code to remove any resolutions from the list that exceeded the current DPI.
I seem to have misunderstood some of the functionality.
First, off, GetCurrentDisplayMode doesn't seem to return current resolution. From my tests, it seems
to return a "maximum maximized size" of some sort equal to GetUsableDisplayBounds - 1 (see below):
* Render output size: 800, 600
* Display mode size: 1536, 864
* Window size: 800, 600
* Display Bounds: x: 0, y: 0, w: 1537, h: 865
* Usable display bounds: x: 0, y: 0, w: 1537, h: 865
The actual
window size, which @celticminstrel informs me is what we should be measuring here, is actually returned
by either GetWindowSize or GetRenderOutputSize. According to SDL, the latter should return pixel size
and the former screen coordinates. In my tests, though, the results are the same. This might be different
on macOS or iOS. Either way, I've changed current_resolution(), getx(), and gety() to use the results of
GetWindowSize().
Additionally, it seems I don't need to multiply any display modes by the DPI scale factor if I check the
sizes against the aforementioned "max maximized area" w/h. For that I use GetDisplayBounds however...
though again, I'm not sure that's the best way to do this. It does seem to work correctly to fix the
aforementioned bug, anyway. I'll need to figure out more about the handling of DPI on Windows vs macOS
or iOS. There's an implication that the measurements some of these functions return is different.
Compare: https://github.com/wesnoth/wesnoth/compare/d4d94a8dbc97...7aa79c38168d
More information about the Commits
mailing list