summaryrefslogtreecommitdiffstats
path: root/kolf/config.cpp
blob: 0d9aafaeb7e99aeccd3b76ae6774a0822e679123 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#include <tqlabel.h>
#include <tqlayout.h>

#include <kdialog.h>
#include <klocale.h>

#include "config.h"

Config::Config(TQWidget *parent, const char *name)
	: TQFrame(parent, name)
{
	startedUp = false;
}

void Config::ctorDone()
{
	startedUp = true;
}

int Config::spacingHint()
{
	return KDialog::spacingHint() / 2;
}

int Config::marginHint()
{
	return KDialog::marginHint();
}

void Config::changed()
{
	if (startedUp)
		emit modified();
}

MessageConfig::MessageConfig(TQString text, TQWidget *parent, const char *name)
	: Config(parent, name)
{
	TQVBoxLayout *tqlayout = new TQVBoxLayout(this, marginHint(), spacingHint());
	tqlayout->addWidget(new TQLabel(text, this));
}

DefaultConfig::DefaultConfig(TQWidget *parent, const char *name)
	: MessageConfig(i18n("No configuration options"), parent, name)
{
}

#include "config.moc"