File: drawfakechord.c

package info (click to toggle)
denemo 0.9.2-3
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 26,724 kB
  • sloc: ansic: 59,006; lisp: 13,874; sh: 11,666; makefile: 2,082; xml: 634; sed: 16
file content (28 lines) | stat: -rw-r--r-- 565 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#include "utils.h"
#include <denemo/denemo.h>
#include <string.h>

/**
 * Draw fakechords on the score
 *
 */
void
draw_fakechord (cairo_t *cr,
	     gint xx, gint y, DenemoObject * theobj)
{
  gchar *text = NULL;
  GString *temp = g_string_new("");
  gint length = 0;
  chord *ch;
  if (theobj->type == FAKECHORD)
    {
      g_warning ("FAKECHORD type found and not handled");
    }
  else if (theobj->type == CHORD)
    {
      ch = (chord *) theobj->object;
      drawnormaltext_cr( cr,  ((GString *) ch->fakechord)->str, xx, y + STAFF_HEIGHT - 10 );
    }
}