BALL
1.4.1
|
00001 // -*- Mode: C++; tab-width: 2; -*- 00002 // vi: set ts=2: 00003 // 00004 00005 #ifndef BALL_VIEW_DIALOGS_LABELDIALOG_H 00006 #define BALL_VIEW_DIALOGS_LABELDIALOG_H 00007 00008 #ifndef BALL_COMMON_GLOBAL_H 00009 # include <BALL/COMMON/global.h> 00010 #endif 00011 00012 #ifndef BALL_FORMAT_INIFILE_H 00013 # include <BALL/FORMAT/INIFile.h> 00014 #endif 00015 00016 #ifndef BALL_VIEW_KERNEL_MODULARWIDGET_H 00017 # include <BALL/VIEW/KERNEL/modularWidget.h> 00018 #endif 00019 00020 #ifndef BALL_VIEW_KERNEL_MESSAGE_H 00021 # include <BALL/VIEW/KERNEL/message.h> 00022 #endif 00023 00024 #include <BALL/VIEW/UIC/ui_labelDialog.h> 00025 00026 #include <QtGui/QFont> 00027 00028 namespace BALL 00029 { 00030 namespace VIEW 00031 { 00038 class BALL_VIEW_EXPORT LabelDialog 00039 : public QDialog, 00040 public Ui_LabelDialogData, 00041 public ModularWidget 00042 { 00043 Q_OBJECT 00044 BALL_EMBEDDABLE(LabelDialog,ModularWidget) 00045 00046 public: 00047 00051 00059 LabelDialog(QWidget *parent = NULL, const char *name = "LabelDialog"); 00060 00062 00065 00068 virtual ~LabelDialog(); 00069 00071 00074 00081 virtual void onNotify(Message *message); 00082 00084 00087 00092 virtual void fetchPreferences(INIFile &inifile); 00093 00098 virtual void writePreferences(INIFile &inifile); 00099 00107 virtual void initializeWidget(MainControl& main_control); 00108 00110 00111 public slots: 00112 00116 00119 void show(); 00120 00122 00125 00126 protected slots: 00127 00133 virtual void accept(); 00134 00138 virtual void editColor(); 00139 00141 virtual void addTag(); 00142 00144 virtual void fontSelected(); 00145 00147 virtual void modeChanged(); 00148 00150 void textChanged(); 00151 00153 00155 virtual void checkMenu(MainControl& main_control); 00156 00157 protected: 00158 00159 Representation* createOneLabel_(); 00160 00161 Representation* createMultipleLabels_(); 00162 00163 00164 QAction* id_; 00165 00166 ColorRGBA custom_color_; 00167 QFont font_; 00168 }; 00169 00170 } } // namespaces 00171 00172 #endif // BALL_VIEW_DIALOGS_LABELDIALOG_H