The Gnome Chemistry Utils 0.13.3
linesdlg.h
00001 // -*- C++ -*-
00002 
00003 /* 
00004  * Gnome Crystal
00005  * linesdlg.h 
00006  *
00007  * Copyright (C) 2002-2011 Jean Bréfort <jean.brefort@normalesup.org>
00008  *
00009  * This program is free software; you can redistribute it and/or 
00010  * modify it under the terms of the GNU General Public License as 
00011  * published by the Free Software Foundation; either version 2 of the
00012  * License, or (at your option) any later version.
00013  *
00014  * This program is distributed in the hope that it will be useful,
00015  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00016  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00017  * GNU General Public License for more details.
00018  *
00019  * You should have received a copy of the GNU General Public License
00020  * along with this program; if not, write to the Free Software
00021  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301
00022  * USA
00023  */
00024 
00025 #ifndef GCR_LINESDLG_H
00026 #define GCR_LINESDLG_H
00027 
00028 #include <gcugtk/dialog.h>
00029 
00030 namespace gcr {
00031 
00032 class Document;
00033 class Application;
00034 
00035 class LinesDlg: public gcugtk::Dialog
00036 {
00037 public:
00038         LinesDlg (Application *App, Document* pDoc);
00039         virtual ~LinesDlg ();
00040         
00041         virtual bool Apply ();
00042         void LineAdd ();
00043         void LineDelete ();
00044         void LineDeleteAll ();
00045         void LineSelect (GtkTreeSelection *Selection);
00046         void OnEdited (GtkCellRendererText *cell, const gchar *path_string, const gchar *new_text);
00047         void OnToggled (GtkCellRendererToggle *cell, const gchar *path_string);
00048         void OnToggledSpecial (int Type);
00049 
00050 private:
00051         char m_buf[64];
00052         Document *m_pDoc;
00053         GtkListStore *LineList;
00054         GtkTreeSelection *Selection;
00055         GtkColorButton *LineColor, *EdgesColor, *MediansColor, *DiagsColor;
00056         GtkEntry *LineR, *EdgesR, *MediansR, *DiagsR;
00057         GtkCheckButton *Edges, *Medians, *Diags;
00058         GtkWidget *DeleteBtn, *DeleteAllBtn;
00059         GArray *m_Lines;
00060         gint m_LineSelected;
00061         GtkTreeIter m_Iter;
00062 };
00063 
00064 }       //      namespace gcr
00065 
00066 #endif //GCR_LINESDLG_H