~ubuntu-branches/ubuntu/oneiric/denemo/oneiric

« back to all changes in this revision

Viewing changes to src/drawgrace.c

  • Committer: Bazaar Package Importer
  • Author(s): Alessio Treglia
  • Date: 2010-10-27 08:00:18 UTC
  • mfrom: (1.3.3 upstream)
  • mto: This revision was merged to the branch mainline in revision 15.
  • Revision ID: james.westby@ubuntu.com-20101027080018-tuekd0869v8ptnqv
Tags: upstream-0.8.16
ImportĀ upstreamĀ versionĀ 0.8.16

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
 *
16
16
 */
17
17
void
18
 
draw_gracebracket (GdkPixmap * pixmap, GdkGC * gc, GdkFont * font,
 
18
draw_gracebracket (cairo_t *cr,
19
19
                   gint xx, gint y, DenemoObject * theobj)
20
20
{
21
 
  PangoContext *context =
22
 
    gdk_pango_context_get_for_screen (gdk_drawable_get_screen (pixmap));
23
 
  PangoLayout *layout = pango_layout_new (context);
24
 
  PangoFontDescription *desc = pango_font_description_from_string (FONT);
25
 
 
 
21
  char *text="";
26
22
 
27
23
  if (theobj->type == GRACE_START)
28
24
    {
29
 
      pango_layout_set_text (layout, _("\\"), -1);
 
25
      text = _("\\");
30
26
    }
31
27
  else if (theobj->type == GRACE_END)
32
28
    {
33
 
      pango_layout_set_text (layout, _("'"), -1);
34
 
 
 
29
      text = _("'");
35
30
    }
36
31
 
37
 
  pango_layout_set_font_description (layout, desc);
38
 
  gdk_draw_layout (pixmap, gc, xx, y - 4, layout);
39
 
  pango_font_description_free (desc);
 
32
  drawnormaltext_cr( cr, text, xx, y - 4 );
40
33
}