1 /* exportlilypond.h
2  * Header file for lilypond generation
3 
4  * for Denemo, a gtk+ frontend to GNU Lilypond
5  * (c) 2000-2005 Matthew Hiller, Adam Tee, 2011 Richard Shann
6  */
7 #ifndef EXPORTMUDELAH
8 #define EXPORTMUDELAH
9 
10 #include <gtk/gtk.h>
11 #include <stdio.h>
12 
13 //real TAB causes mismatch between LilyPond error columns and Gtks
14 #define TAB "        "
15 
16 #define LILYPOND_SYMBOL_DEFINITIONS \
17     "\nCompactChordSymbols = {}\n#(define DenemoTransposeStep 0)\n#(define DenemoTransposeAccidental 0)\nDenemoGlobalTranspose = \\void #0\ntitledPiece = {}\nAutoBarline = {}\nAutoEndMovementBarline = \\bar \"|.\"\n"
18 void create_lilywindow (void);
19 void exportlilypond (gchar * thefilename, DenemoProject * gui, gboolean all_movements);
20 
21 void export_lilypond_parts (char *filename, DenemoProject * gui);
22 void export_lilypond_part (char *filename, DenemoProject * gui, gboolean all_movements);
23 
24 /* generate the LilyPond for the current part, all movements, into the LilyPond textview window */
25 void generate_lilypond_part (void);
26 void make_scoreblock_editable (void);
27 /* generate lilypond text for the object passed in - the string should
28    be g_freed by the caller when finished with*/
29 gchar *generate_lily (objnode * obj);
30 void refresh_lily_cb (GtkAction * action, DenemoProject * gui);
31 void force_lily_refresh (DenemoProject * gui);
32 void toggle_lily_visible_cb (GtkAction * action, gpointer param);
33 
34 void custom_lily_cb (GtkAction * action, gpointer param);
35 
36 void delete_lily_cb (GtkAction * action, gpointer param);
37 void set_lily_error (gint line, gint column);
38 void highlight_lily_error ();
39 gboolean goto_lilypond_position (gint line, gint column);
40 DenemoObject *get_object_at_lilypond (gint line, gint col);
41 
42 void set_initiate_scoreblock (DenemoMovement * si, GString * scoreblock);
43 gchar *get_lilypond_for_clef (clef * theclef);
44 gchar *get_lilypond_for_keysig (struct keysig *key);
45 gchar *get_lilypond_for_timesig (timesig * time);
46 gchar *get_lilypond_paper (void);
47 const gchar *get_prevailing_clef_as_lilypond (void);
48 const gchar *get_prevailing_keysig_as_lilypond (void);
49 const gchar *get_prevailing_timesig_as_lilypond (void);
50 void set_voice_termination (GString * str, DenemoStaff * curstaffstruct);
51 void set_staff_termination (GString * str, DenemoStaff * curstaffstruct);
52 void set_voice_definition (GString * str, DenemoStaff * curstaffstruct, gchar * denemo_name);
53 void set_staff_definition (GString * str, DenemoStaff * curstaffstruct);
54 gint get_cursor_offset (void);
55 void init_lilypond_buffer(void);
56 #endif
57