00001 // $Id: QFitNamedWidgetPlugin.cpp 478 2009-10-29 12:26:09Z linev $ 00002 //----------------------------------------------------------------------- 00003 // The GSI Online Offline Object Oriented (Go4) Project 00004 // Experiment Data Processing at EE department, GSI 00005 //----------------------------------------------------------------------- 00006 // Copyright (C) 2000- GSI Helmholtzzentrum für Schwerionenforschung GmbH 00007 // Planckstr. 1, 64291 Darmstadt, Germany 00008 // Contact: http://go4.gsi.de 00009 //----------------------------------------------------------------------- 00010 // This software can be used under the license agreements as stated 00011 // in Go4License.txt file which is part of the distribution. 00012 //----------------------------------------------------------------------- 00013 00014 #include "QFitNamedWidget.h" 00015 #include "QFitNamedWidgetPlugin.h" 00016 #include <QtPlugin> 00017 00018 00019 QFitNamedWidgetPlugin::QFitNamedWidgetPlugin(QObject *parent) 00020 : QObject(parent) 00021 { 00022 initialized = false; 00023 } 00024 00025 void QFitNamedWidgetPlugin::initialize(QDesignerFormEditorInterface * /* core */) 00026 { 00027 if (initialized) 00028 return; 00029 00030 initialized = true; 00031 } 00032 00033 bool QFitNamedWidgetPlugin::isInitialized() const 00034 { 00035 return initialized; 00036 } 00037 00038 QWidget *QFitNamedWidgetPlugin::createWidget(QWidget *parent) 00039 { 00040 return new QFitNamedWidget(parent); 00041 } 00042 00043 QString QFitNamedWidgetPlugin::name() const 00044 { 00045 return "QFitNamedWidget"; 00046 } 00047 00048 QString QFitNamedWidgetPlugin::group() const 00049 { 00050 return "Go4 Custom Widgets"; 00051 } 00052 00053 QIcon QFitNamedWidgetPlugin::icon() const 00054 { 00055 return QIcon(":/go4logo2.png"); 00056 } 00057 00058 QString QFitNamedWidgetPlugin::toolTip() const 00059 { 00060 return "Widget for named items in Go4 Fit gui"; 00061 } 00062 00063 QString QFitNamedWidgetPlugin::whatsThis() const 00064 { 00065 return "Widget, connected with named items in expert mode"; 00066 } 00067 00068 bool QFitNamedWidgetPlugin::isContainer() const 00069 { 00070 return true; 00071 } 00072 00073 QString QFitNamedWidgetPlugin::domXml() const 00074 { 00075 return "<widget class=\"QFitNamedWidget\" name=\"QFitNamedWidget\">\n" 00076 " <property name=\"geometry\">\n" 00077 " <rect>\n" 00078 " <x>0</x>\n" 00079 " <y>0</y>\n" 00080 " <width>100</width>\n" 00081 " <height>100</height>\n" 00082 " </rect>\n" 00083 " </property>\n" 00084 "</widget>\n"; 00085 } 00086 00087 QString QFitNamedWidgetPlugin::includeFile() const 00088 { 00089 return "QFitNamedWidget.h"; 00090 } 00091 00092