1 // Copyright (C) 2007, 2008, 2009, 2010, 2014, 2020 Ben Asselstine 2 // 3 // This program is free software; you can redistribute it and/or modify 4 // it under the terms of the GNU General Public License as published by 5 // the Free Software Foundation; either version 3 of the License, or 6 // (at your option) any later version. 7 // 8 // This program is distributed in the hope that it will be useful, 9 // but WITHOUT ANY WARRANTY; without even the implied warranty of 10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 11 // GNU Library General Public License for more details. 12 // 13 // You should have received a copy of the GNU General Public License 14 // along with this program; if not, write to the Free Software 15 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 16 // 02110-1301, USA. 17 18 #pragma once 19 #ifndef SHIELDSET_INFO_DIALOG_H 20 #define SHIELDSET_INFO_DIALOG_H 21 22 #include <gtkmm.h> 23 #include "shieldset.h" 24 #include "lw-editor-dialog.h" 25 26 //! Shieldset Info Editor. Change the name/description/etc of the Shieldset. 27 class ShieldSetInfoDialog: public LwEditorDialog 28 { 29 public: 30 ShieldSetInfoDialog(Gtk::Window &parent, Shieldset *shieldset); 31 ~ShieldSetInfoDialog(); 32 33 //returns true if we changed anything 34 bool run(); 35 36 private: 37 Shieldset *d_shieldset; 38 bool d_changed; 39 Gtk::Entry *name_entry; 40 Gtk::TextView *copyright_textview; 41 Gtk::TextView *license_textview; 42 Gtk::Entry *filename_entry; 43 Gtk::Button *close_button; 44 Gtk::Label *status_label; 45 Gtk::TextView *description_textview; 46 Gtk::Label *location_label; 47 Gtk::Notebook *notebook; 48 Gtk::SpinButton *small_width_spinbutton; 49 Gtk::SpinButton *small_height_spinbutton; 50 Gtk::SpinButton *medium_width_spinbutton; 51 Gtk::SpinButton *medium_height_spinbutton; 52 Gtk::SpinButton *large_width_spinbutton; 53 Gtk::SpinButton *large_height_spinbutton; 54 Gtk::Button *fit_button; 55 56 void on_name_changed(); 57 void on_copyright_changed (); 58 void on_license_changed (); 59 void on_description_changed (); 60 void on_small_width_changed (); 61 void on_small_height_changed (); 62 void on_medium_width_changed (); 63 void on_medium_height_changed (); 64 void on_large_width_changed (); 65 void on_large_height_changed (); 66 void on_fit_pressed (); 67 }; 68 69 #endif 70