1 /* HomeBank -- Free, easy, personal accounting for everyone.
2 * Copyright (C) 1995-2016 Maxime DOYEN
4 * This file is part of HomeBank.
6 * HomeBank is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
11 * HomeBank is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program. If not, see <http://www.gnu.org/licenses/>.
20 #ifndef __HB_CATEGORY_GTK_H__
21 #define __HB_CATEGORY_GTK_H__
31 #define LST_DEFCAT_SORT_NAME 1
32 #define LST_DEFCAT_SORT_USED 2
54 gchar
*ui_cat_comboboxentry_get_name(GtkComboBox
*entry_box
);
55 guint32
ui_cat_comboboxentry_get_key(GtkComboBox
*entry_box
);
56 guint32
ui_cat_comboboxentry_get_key_add_new(GtkComboBox
*entry_box
);
57 Category
*ui_cat_comboboxentry_get(GtkComboBox
*entry_box
);
59 gboolean
ui_cat_comboboxentry_set_active(GtkComboBox
*entry_box
, guint32 key
);
60 void ui_cat_comboboxentry_add(GtkComboBox
*entry_box
, Category
*pay
);
61 void ui_cat_comboboxentry_populate(GtkComboBox
*entry_box
, GHashTable
*hash
);
62 void ui_cat_comboboxentry_populate_except(GtkComboBox
*entry_box
, GHashTable
*hash
, guint except_key
);
63 GtkWidget
*ui_cat_comboboxentry_new(GtkWidget
*label
);
65 /* = = = = = = = = = = */
67 void ui_cat_listview_add(GtkTreeView
*treeview
, Category
*item
, GtkTreeIter
*parent
);
68 Category
*ui_cat_listview_get_selected(GtkTreeView
*treeview
);
69 Category
*ui_cat_listview_get_selected_parent(GtkTreeView
*treeview
, GtkTreeIter
*parent
);
70 gboolean
ui_cat_listview_remove (GtkTreeModel
*liststore
, guint32 key
);
71 void ui_cat_listview_remove_selected(GtkTreeView
*treeview
);
72 void ui_cat_listview_populate(GtkWidget
*view
, gint type
);
73 GtkWidget
*ui_cat_listview_new(gboolean withtoggle
, gboolean withcount
);
75 /* = = = = = = = = = = */
77 struct ui_cat_manage_dialog_data
85 GtkWidget
*ST_name1
, *ST_name2
;
87 //GtkWidget *BT_add1, *BT_add2;
97 GtkWidget
*BT_collapse
;
99 GtkWidget
*LA_category
;
110 GtkWidget
*ui_cat_manage_dialog (void);