/[svn]/gigedit/trunk/src/dimensionmanager.h
ViewVC logotype

Contents of /gigedit/trunk/src/dimensionmanager.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1107 - (show annotations) (download) (as text)
Thu Mar 22 20:00:10 2007 UTC (12 years, 8 months ago) by schoenebeck
File MIME type: text/x-c++hdr
File size: 2040 byte(s)
* added dialog for managing dimensions of a selected region
  (Add and Remove buttons not yet implemented)

1 /* -*- c++ -*-
2 * Copyright (C) 2006, 2007 Andreas Persson
3 *
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License as
6 * published by the Free Software Foundation; either version 2, or (at
7 * your option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful, but
10 * WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with program; see the file COPYING. If not, write to the Free
16 * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
17 * 02110-1301 USA.
18 */
19
20 #ifndef GIGEDIT_DIMENSIONMANAGER_H
21 #define GIGEDIT_DIMENSIONMANAGER_H
22
23 #include <gtkmm/window.h>
24 #include <gtkmm/layout.h>
25 #include <gtkmm/button.h>
26 #include <gtkmm/buttonbox.h>
27 #include <gtkmm/treeview.h>
28 #include <gtkmm/liststore.h>
29 #include <gtkmm/scrolledwindow.h>
30
31 #include <gig.h>
32
33 class DimensionManager : public Gtk::Window {
34 public:
35 DimensionManager();
36 void show(gig::Region* region);
37 protected:
38 gig::Region* region;
39 Gtk::VBox vbox;
40 Gtk::HButtonBox buttonBox;
41 Gtk::ScrolledWindow scrolledWindow;
42 Gtk::TreeView treeView;
43 Gtk::Button addButton;
44 Gtk::Button removeButton;
45
46 class ModelColumns : public Gtk::TreeModel::ColumnRecord {
47 public:
48 ModelColumns() {
49 add(m_dim_type);
50 add(m_bits);
51 add(m_zones);
52 add(m_description);
53 }
54
55 Gtk::TreeModelColumn<Glib::ustring> m_dim_type;
56 Gtk::TreeModelColumn<int> m_bits;
57 Gtk::TreeModelColumn<int> m_zones;
58 Gtk::TreeModelColumn<Glib::ustring> m_description;
59 } tableModel;
60
61 Glib::RefPtr<Gtk::ListStore> refTableModel;
62
63 void addDimension();
64 void removeDimension();
65 };
66
67 #endif // GIGEDIT_DIMENSIONMANAGER_H

  ViewVC Help
Powered by ViewVC