mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-06 23:05:04 +01:00
properly centered text..
..at the risk of blurring some text with some fonts when the text is shifted by 0.5px.
This commit is contained in:
parent
795451a697
commit
d717a0680a
1 changed files with 2 additions and 2 deletions
|
|
@ -400,9 +400,9 @@ ArdourButton::render (cairo_t* cr, cairo_rectangle_t *)
|
|||
* TODO this should be generalized incl rotation.
|
||||
* currently only 'user' of this API is meter_strip.cc
|
||||
*/
|
||||
if (_xalign < 0) xa = .5 + (ww * fabs(_xalign) + text_margin);
|
||||
if (_xalign < 0) xa = ceil(.5 + (ww * fabs(_xalign) + text_margin));
|
||||
|
||||
cairo_move_to (cr, rint(xa), rint(ya));
|
||||
cairo_move_to (cr, xa, ya);
|
||||
pango_cairo_update_layout(cr, _layout->gobj());
|
||||
pango_cairo_show_layout (cr, _layout->gobj());
|
||||
cairo_restore (cr);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue