diff options
| author | Tim Penhey <tim.penhey@canonical.com> | 2012-07-23 11:09:02 +1200 |
|---|---|---|
| committer | Tim Penhey <tim.penhey@canonical.com> | 2012-07-23 11:09:02 +1200 |
| commit | e8d50da9421c20d65b070891703bde69d043cd30 (patch) | |
| tree | 1bd3b5362e04888664d6e4918f111daf59a4ac5e | |
| parent | 0f67ef88cc2a123c0ca1729426c1077afe15da92 (diff) | |
Make sure that weight is always set.
(bzr r2501.4.3)
| -rw-r--r-- | unity-shared/DashStyle.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/unity-shared/DashStyle.cpp b/unity-shared/DashStyle.cpp index 4fbb32ff2..789659139 100644 --- a/unity-shared/DashStyle.cpp +++ b/unity-shared/DashStyle.cpp @@ -1359,10 +1359,6 @@ void Style::Impl::Text(cairo_t* cr, PangoWeight weight; switch (regular_text_weight_) { - case FontWeight::REGULAR: - weight = PANGO_WEIGHT_NORMAL; - break; - case FontWeight::LIGHT: weight = PANGO_WEIGHT_LIGHT; break; @@ -1370,6 +1366,10 @@ void Style::Impl::Text(cairo_t* cr, case FontWeight::BOLD: weight = PANGO_WEIGHT_BOLD; break; + + case FontWeight::REGULAR: + default: + weight = PANGO_WEIGHT_NORMAL; } pango_font_description_set_weight(desc, weight); |
