diff options
| author | Dana Jansens <danakj@orodu.net> | 2007-04-25 01:59:56 +0000 |
|---|---|---|
| committer | Dana Jansens <danakj@orodu.net> | 2007-04-25 01:59:56 +0000 |
| commit | 092780455989da14b1a3a8c1624a0fd8bf5cdfdd (patch) | |
| tree | 65e0bf7c91c7f25c3a947e41c18abd4fe2d45749 | |
| parent | 4717b9870c48683dc1b0e862ab2a64886ec26378 (diff) | |
"text" was no longer needed
| -rw-r--r-- | render/font.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/render/font.c b/render/font.c index a0e622d5..bd4dcfc2 100644 --- a/render/font.c +++ b/render/font.c @@ -175,7 +175,6 @@ void RrFontDraw(XftDraw *d, RrTextureText *t, RrRect *area) XftColor c; gint mw; PangoRectangle rect; - gchar *text; PangoAttrList* attrs = NULL; /* center the text vertically @@ -192,13 +191,11 @@ void RrFontDraw(XftDraw *d, RrTextureText *t, RrRect *area) /* * * set up the layout * * */ - text = g_strdup(t->string); - if (t->shortcut) { gchar *i; gchar *lowertext; - lowertext = g_utf8_strdown(text, -1); + lowertext = g_utf8_strdown(t->string, -1); i = g_utf8_strchr(lowertext, -1, t->shortcut); if (i != NULL) { PangoAttribute *a; @@ -214,11 +211,9 @@ void RrFontDraw(XftDraw *d, RrTextureText *t, RrRect *area) g_free(lowertext); } - pango_layout_set_text(t->font->layout, text, -1); + pango_layout_set_text(t->font->layout, t->string, -1); pango_layout_set_width(t->font->layout, w * PANGO_SCALE); - g_free(text); - /* * * end of setting up the layout * * */ pango_layout_get_pixel_extents(t->font->layout, NULL, &rect); |
