summaryrefslogtreecommitdiff
path: root/src/file.h
blob: fddea2dc793df5cde2af8e707498edd3996400ec (plain)
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
/* file.h
 * prototypes for file I/O routines
 * 
 * for Denemo, a gtk+ frontend to GNU Lilypond 
 * (c) 2000, 2001, Adam Tee
 * (c) 2000, 2001, University of Leeds
 */
#ifndef FILE_H
#define FILE_H


typedef enum
{ DENEMO_FORMAT = 0,
  DNM_FORMAT,
  MUDELA_FORMAT,
  PDF_FORMAT,
  PNG_FORMAT,
  ABC_FORMAT,
  MIDI_FORMAT,
  CSOUND_FORMAT
}
FileFormatNames;

gboolean confirmbox (DenemoGUI *gui);

void 
file_savepartswrapper(GtkAction *action, gpointer param);

void
file_open_with_check (GtkAction *action, DenemoScriptParam * param);
void
file_import_lilypond_with_check (GtkAction *action, DenemoScriptParam * param);
void
file_import_midi_with_check (GtkAction *action, DenemoScriptParam * param);
void
file_import_musicxml_with_check (GtkAction *action, DenemoScriptParam * param);

void
file_add_staffs (GtkAction *action, DenemoScriptParam * param);

void
file_add_movements (GtkAction *action, DenemoScriptParam * param);

gint
open_user_default_template(ImportType type);

void
system_template_open_with_check (GtkAction *action, DenemoScriptParam * param);
void
system_example_open_with_check (GtkAction *action, DenemoScriptParam * param);

void
local_template_open_with_check (GtkAction *action, DenemoScriptParam * param);

void
file_savewrapper (GtkAction *action, gpointer param);

void
file_saveaswrapper (GtkAction *action, DenemoScriptParam *param);

void
file_newwrapper (GtkAction *action, gpointer param);

gint
open_for_real (gchar *filename, DenemoGUI *gui, DenemoSaveType as_template, ImportType type);



void
file_save (GtkWidget * widget, DenemoGUI *gui);

void
file_saveas (DenemoGUI *gui,  DenemoSaveType as_template);

void
template_save (GtkAction * action, gpointer param);
void
file_copy_save (GtkAction * action, gpointer param); 
void export_mudela_action (GtkAction *action, DenemoScriptParam *param);
void export_pdf_action (GtkAction *action, DenemoScriptParam *param);
void export_png_action (GtkAction *action, DenemoScriptParam *param);
void export_midi_action (GtkAction *action, DenemoScriptParam *param);
void export_csound_action (GtkAction *action, DenemoScriptParam *param);
void export_pdf (gchar *filename, DenemoGUI * gui);
void export_png (gchar *filename, gboolean show_preview, DenemoGUI * gui);
void
paste_clipboard(GtkAction * action, gpointer param);

gint
lyinput (gchar *filename, DenemoGUI *gui);

void
deletescore (GtkWidget * widget, DenemoGUI *gui);

void
updatescoreinfo (DenemoGUI *gui);

/**
 * @return TRUE if the file does not exists or the user want it to be overwritten
 */
gboolean replace_existing_file_dialog(const gchar* filename, GtkWindow* parent_window, gint format_id);

#endif /*FILE_H*/