summaryrefslogtreecommitdiff
diff options
authorMarco Trevisan (Treviño) <mail@3v1n0.net>2014-03-31 19:02:51 +0200
committerMarco Trevisan (Treviño) <mail@3v1n0.net>2014-03-31 19:02:51 +0200
commit70336a16c8dbdaf7edb61f18d79654c7c06619ed (patch)
tree27a4aa36aadb98f09e9046cfd477c59118f1092b
parent47c92b12927dbf2f65b549d5d94201043fe61998 (diff)
PanelMenuView: draw the background under the text glyphs
Fixes LP: #723167 (bzr r3748.2.3)
-rw-r--r--panel/PanelMenuView.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/panel/PanelMenuView.cpp b/panel/PanelMenuView.cpp
index 130e60434..50cf6f0fe 100644
--- a/panel/PanelMenuView.cpp
+++ b/panel/PanelMenuView.cpp
@@ -814,7 +814,9 @@ void PanelMenuView::UpdateTitleTexture(nux::Geometry const& geo, std::string con
nux::CairoGraphics cairo_graphics(CAIRO_FORMAT_ARGB32, title_geo_.width, title_geo_.height);
cairo_surface_set_device_scale(cairo_graphics.GetSurface(), dpi_scale, dpi_scale);
cairo_t* cr = cairo_graphics.GetInternalContext();
- style->DrawTitle(label, state, cr, title_geo_.width / dpi_scale, title_geo_.height / dpi_scale);
+
+ nux::Geometry text_bg(-title_geo_.x, -title_geo_.y, geo.width, geo.height);
+ style->DrawTitle(label, state, cr, title_geo_.width / dpi_scale, title_geo_.height / dpi_scale, text_bg * (1.0/dpi_scale));
title_texture_ = texture_ptr_from_cairo_graphics(cairo_graphics);
}