City full bar misdrawn with non-default zoom level
The attached screenshot illustrates the most obvious glitch I saw while playing some turns with zoom enabled: when the "city full bar" is enabled, the lines are drawn in the wrong place (which moves as the map is scrolled in a pantograph-like fashion), the darkened box looks too big, etc. (If "View > City Full Bar" is disabled, the alternative display looks more plausible.
This is --with-zoom, "freeciv-gtk3 --tiles trident -- --zoom 2.0". S2_6 commit:c8cad4d8dd.
#2 Updated by Jacob Nevins 2 months ago
- File m-zoom-full-citybar.patch m-zoom-full-citybar.patch added
- File 30-26-zoom-full-citybar.patch 30-26-zoom-full-citybar.patch added
- Status changed from In Progress to Resolved
- Target version set to 2.6.0-beta1
Attached patch works for me, in Gtk3 with x2 and with non-default.
It doesn't cause regressions in Qt/Gtk2 with and without scaling, or in SDL2 (no zoom or scaling).
It turns out that canvas_put_line() has different semantics wrt zoom than other canvas_put functions. I wasn't quite brave enough to try fixing it now, so I just left some comments, but it probably should be fixed.
I audited/tested other mapview-related uses of canvas_put_line (trade routes, goto lines, link marks) for zoom and found no trouble.