~ubuntu-branches/ubuntu/maverick/scribus-ng/maverick-backports

« back to all changes in this revision

Viewing changes to scribus/designer/smwidgets/smspinboxplugin.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Oleksandr Moskalenko
  • Date: 2009-02-09 09:25:18 UTC
  • mfrom: (5.1.4 sid)
  • Revision ID: james.westby@ubuntu.com-20090209092518-iqsxmh3pjspgrdyd
Tags: 1.3.5.dfsg~svn20090208-2
debian/control: Use "type-handling -n arm,armel,armeb any" to generate the
list of architectures to build on.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
For general Scribus (>=1.3.2) copyright and licensing information please refer
 
3
to the COPYING file provided with the program. Following this notice may exist
 
4
a copyright and/or license notice that predates the release of Scribus 1.3.2
 
5
for which a new license (GPL+exception) is in place.
 
6
*/
 
7
#include <QtPlugin>
 
8
#include "smspinboxplugin.h"
 
9
#include "smspinbox.h"
 
10
 
 
11
 
 
12
/* SMSpinBoxPlugin */
 
13
SMSpinBoxPlugin::SMSpinBoxPlugin(QObject* parent)
 
14
        : QObject(parent), initialized(false)
 
15
{
 
16
}
 
17
 
 
18
void SMSpinBoxPlugin::initialize(QDesignerFormEditorInterface* core)
 
19
{
 
20
        Q_UNUSED(core);
 
21
        if (!initialized)
 
22
                initialized = true;
 
23
}
 
24
 
 
25
bool SMSpinBoxPlugin::isInitialized() const
 
26
{
 
27
        return initialized;
 
28
}
 
29
 
 
30
QWidget* SMSpinBoxPlugin::createWidget(QWidget* parent)
 
31
{
 
32
        return new SMSpinBox(parent, 0);
 
33
}
 
34
 
 
35
QString SMSpinBoxPlugin::name() const
 
36
{
 
37
        return QLatin1String("SMSpinBox");
 
38
}
 
39
 
 
40
QString SMSpinBoxPlugin::group() const
 
41
{
 
42
        return QLatin1String("Scribus-SM");
 
43
}
 
44
 
 
45
QIcon SMSpinBoxPlugin::icon() const
 
46
{
 
47
        return QIcon();
 
48
}
 
49
 
 
50
QString SMSpinBoxPlugin::toolTip() const
 
51
{
 
52
        return QString();
 
53
}
 
54
 
 
55
QString SMSpinBoxPlugin::whatsThis() const
 
56
{
 
57
        return QString();
 
58
}
 
59
 
 
60
bool SMSpinBoxPlugin::isContainer() const
 
61
{
 
62
        return false;
 
63
}
 
64
 
 
65
QString SMSpinBoxPlugin::domXml() const
 
66
{
 
67
        return QLatin1String("<widget class=\"SMSpinBox\" name=\"SMSpinBox1\">\n"
 
68
                " <property name=\"geometry\">\n"
 
69
                "  <rect>\n"
 
70
                "   <x>0</x>\n"
 
71
                "   <y>0</y>\n"
 
72
                "   <width>100</width>\n"
 
73
                "   <height>22</height>\n"
 
74
                "  </rect>\n"
 
75
                " </property>\n"
 
76
                "</widget>\n");
 
77
}
 
78
 
 
79
QString SMSpinBoxPlugin::includeFile() const
 
80
{
 
81
        return QLatin1String("smwidgets.h");
 
82
}
 
83
 
 
84
QString SMSpinBoxPlugin::codeTemplate() const
 
85
{
 
86
        return QString();
 
87
}
 
88
 
 
89
Q_EXPORT_PLUGIN2(scribus_smspinboxplugin, SMSpinBoxPlugin)