Re-tagged 0.32
[maemopadplus.git] / src / ui / callbacks.h
blobf9e289f875e22320ab9d9dab47ae06351fb4e490
1 /*
2 * This file is part of maemopad+
5 * This software is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public License
7 * as published by the Free Software Foundation; either version 2.1 of
8 * the License, or (at your option) any later version.
10 * This software is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this software; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18 * 02110-1301 USA
22 #ifndef CALLBACKS_H
23 #define CALLBACKS_H
25 #include <ui/interface.h>
26 #include <gtk/gtk.h>
27 #include <appdata.h>
29 void prepareUIforNodeChange(MainView * mainview, nodeType typ);
31 nodeData *getSelectedNode(MainView * mainview);
32 void saveCurrentData(MainView * mainview);
33 void saveDataToNode(MainView * mainview, nodeData *selnode);
35 gboolean callback_treeview_testcollapse(GtkTreeView * treeview, GtkTreeIter * arg1, GtkTreePath * arg2, gpointer user_data);
36 void callback_treeview_celldatafunc(GtkTreeViewColumn * tree_column, GtkCellRenderer * cell, GtkTreeModel * tree_model, GtkTreeIter * iter, gpointer data);
37 void callback_treeview_change(GtkTreeSelection * selection, gpointer data);
38 gboolean treeview_canselect(GtkTreeSelection * selection, GtkTreeModel * model, GtkTreePath * path, gboolean path_currently_selected, gpointer userdata);
40 gboolean newnodedlg_key_press_cb(GtkWidget * widget, GdkEventKey * event, GtkWidget * dlg);
41 void add_new_node(nodeData * node, MainView * mainview, gboolean ischild);
43 void callback_file_new_text_node(GtkAction * action, gpointer data);
44 void callback_new_node_real(GtkAction * action, gpointer data);
46 void callback_file_new_node(GtkAction * action, gpointer data);
48 void callback_file_expand_collapse_node(GtkAction * action, gpointer data);
49 void callback_file_export_node(GtkAction * action, gpointer data);
51 void callback_file_delete_node(GtkAction * action, gpointer data);
52 void callback_delete_node_real(GtkAction * action, gpointer data);
54 void callback_about(GtkAction * action, gpointer data);
57 * edit-> cut/copy/paste
59 void callback_edit_clear(GtkAction * action, gpointer data);
60 void callback_edit_cut(GtkAction * action, gpointer data);
61 void callback_edit_copy(GtkAction * action, gpointer data);
62 void callback_edit_paste(GtkAction * action, gpointer data);
63 gint cb_popup(GtkWidget * widget, GdkEvent * event);
66 * file-> new/open/save
68 gboolean closefile(MainView * mainview);
69 gboolean callback_file_close(GtkAction * action, gpointer data);
70 void callback_file_new(GtkAction * action, gpointer data);
71 gboolean reset_ctree(GtkTreeModel * model, GtkTreePath * path, GtkTreeIter * iter, gpointer data);
72 void new_file(MainView * mainview);
73 void callback_file_open(GtkAction * action, gpointer data);
74 gboolean open_file(gchar * filename, MainView * mainview);
75 void callback_file_save(GtkAction * action, gpointer data);
78 * font/color
80 void callback_shapemenu(GtkAction * action, GtkWidget * wid);
81 void callback_eraser(GtkAction * action, MainView * mainview);
82 void callback_toggletree(GtkAction * action, MainView * mainview);
83 void callback_menu(GtkAction * action, GtkWidget * menu);
84 void callback_viewmenu(GtkAction * action, GtkWidget * wid);
85 void callback_brushsizetb(GtkAction * action, MainView *mainview);
86 void callback_brushsize(GtkAction * action, GtkWidget * wid);
87 void callback_sketchlines(GtkAction * action, GtkWidget * wid);
88 void callback_color(HildonColorButton * colorButton, MainView * mainview);
89 void callback_color_invoke(GtkAction * action, gpointer data);
90 void callback_pressure(GtkAction * action, MainView *mainview);
91 void callback_wordwrap(GtkAction * action, MainView *mainview);
92 void callback_font(GtkAction * action, gpointer data);
93 void callback_fontstyle(GtkAction * action, GtkWidget * wid);
94 void callback_textbuffer_move(WPTextBuffer *textbuffer, MainView *mainview);
96 gint wp_savecallback(const gchar *buffer, GString * gstr);
98 void callback_undo(GtkAction * action, MainView * mainview);
99 void callback_redo(GtkAction * action, MainView * mainview);
101 void callback_undotoggle(gpointer widget, gboolean st, MainView * mainview);
102 void callback_redotoggle(gpointer widget, gboolean st, MainView * mainview);
103 void callback_finger(SketchWidget * sk, gint x, gint y, gdouble pressure, MainView * mainview);
105 gboolean close_cb(GtkWidget * widget, GdkEventAny * event, MainView * mainview);
106 gboolean key_press_cb(GtkWidget * widget, GdkEventKey * event, MainView * mainview);
108 void callback_setview(MainView *mainview, int setmenu);
110 void callback_checklist_toggled(GtkCellRendererToggle *cell_renderer, gchar *path, GtkWidget *source);
111 void callback_checklist_edited(GtkCellRendererToggle *cell_renderer, gchar *arg1, gchar *arg2, GtkWidget *source);
112 void callback_checklist_change(GtkTreeSelection *selection, MainView *mainview);
113 void callback_checklist_add(GtkAction *action, MainView *mainview);
114 void callback_checklist_delete(GtkAction *action, MainView *mainview);
115 void callback_checklist_delete_real(GtkAction *action, gpointer data);
119 * buffer modified
121 void callback_buffer_modified(GtkAction * action, gpointer data);
123 void hw_event_handler(osso_hw_state_t * state, gpointer data);
124 void exit_event_handler(gboolean die_now, gpointer data);
126 #endif