3 * Copyright (C) 2000 Kh. Naba Kumar Singh
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
23 #include <glade/glade.h>
24 #include "properties.h"
26 typedef struct _CommandEditor CommandEditor
;
27 typedef struct _CommandEditorPriv CommandEditorPriv
;
32 CommandEditorPriv
*priv
;
36 CommandEditor
*command_editor_new (PropsID p_global
, PropsID p_user
, PropsID p
);
38 /* Syncs the key values and the widgets */
39 void command_editor_sync (CommandEditor
*p
);
41 /* Resets the default values into the keys */
42 void command_editor_reset_defaults (CommandEditor
*);
45 void command_editor_hide (CommandEditor
*);
46 void command_editor_show (CommandEditor
*);
47 void command_editor_destroy (CommandEditor
*);
51 /* Return must be freed */
53 command_editor_get_command_file (CommandEditor
* ce
, gchar
* key
, gchar
* fname
);
55 /* Return must be freed */
57 command_editor_get_command (CommandEditor
* ce
, gchar
* key
);
59 gboolean
command_editor_save (CommandEditor
*p
, FILE* stream
);
60 gboolean
command_editor_load (CommandEditor
*p
, PropsID pr
);
63 * CommandEditor KEY definitions.
65 * Use the keys instead of using the strings directly.
67 * Call these as the second arg of the
68 * functions command_editor_get_command() and command_editor_get_command_file().
71 #define COMMAND_LANGUAGES "commands.languages"
72 #define COMMAND_OPEN_FILE "command.open.file."
73 #define COMMAND_VIEW_FILE "command.view.file."
75 #define COMMAND_COMPILE_FILE "command.compile.file."
76 #define COMMAND_MAKE_FILE "command.make.file."
77 #define COMMAND_BUILD_FILE "command.build.file."
78 #define COMMAND_EXECUTE_FILE "command.execute.file."
80 #define COMMAND_BUILD_MODULE "command.build.module"
81 #define COMMAND_BUILD_PROJECT "command.build.project"
82 #define COMMAND_BUILD_TARBALL "command.build.tarball"
83 #define COMMAND_BUILD_INSTALL "command.build.install"
84 #define COMMAND_BUILD_AUTOGEN "command.build.autogen"
85 #define COMMAND_BUILD_CLEAN "command.build.clean"
86 #define COMMAND_BUILD_CLEAN_ALL "command.build.clean.all"
88 #define COMMAND_CLEAN_BUILD_MODULE "command.clean.build.module"
89 #define COMMAND_CLEAN_BUILD_PROJECT "command.clean.build.project"
91 #define COMMAND_EXECUTE_PROJECT "command.execute.project"
93 #define COMMAND_PIXMAP_EDITOR_OPEN "command.open.file.$(file.patterns.icon)"
94 #define COMMAND_IMAGE_EDITOR_OPEN "command.open.file.$(file.patterns.image)"
95 #define COMMAND_HTML_EDITOR_OPEN "command.open.file.$(file.patterns.html)"
97 #define COMMAND_PIXMAP_EDITOR_VIEW "command.view.file.$(file.patterns.icon)"
98 #define COMMAND_IMAGE_EDITOR_VIEW "command.view.file.$(file.patterns.image)"
99 #define COMMAND_HTML_EDITOR_VIEW "command.view.file.$(file.patterns.html)"
100 #define COMMAND_TERMINAL "command.terminal"