summaryrefslogtreecommitdiffstats
path: root/src/prefAuthor.cpp
blob: c28d7320f0ac27afe84cb91c807a4e399da2650e (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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
#include <tdelocale.h>
/****************************************************************************
** Form implementation generated from reading ui file './prefAuthor.ui'
**
** Created: dim. oct. 26 08:57:35 2008
**
** WARNING! All changes made in this file will be lost!
****************************************************************************/

#include "prefAuthor.h"

#include <tqvariant.h>
#include <tqpushbutton.h>
#include <tqgroupbox.h>
#include <tqcombobox.h>
#include <tqlabel.h>
#include <knuminput.h>
#include <kpushbutton.h>
#include <kcolorbutton.h>
#include <tqlayout.h>
#include <tqtooltip.h>
#include <tqwhatsthis.h>
#include "knuminput.h"
#include "kpushbutton.h"
#include "kcolorbutton.h"

/*
 *  Constructs a prefAuthor as a child of 'parent', with the
 *  name 'name' and widget flags set to 'f'.
 */
prefAuthor::prefAuthor( TQWidget* parent, const char* name, WFlags fl )
    : TQWidget( parent, name, fl )
{
    if ( !name )
	setName( "prefAuthor" );
    prefAuthorLayout = new TQGridLayout( this, 1, 1, 11, 6, "prefAuthorLayout"); 

    groupBox1 = new TQGroupBox( this, "groupBox1" );
    groupBox1->setColumnLayout(0, Qt::Vertical );
    groupBox1->layout()->setSpacing( 6 );
    groupBox1->layout()->setMargin( 11 );
    groupBox1Layout = new TQGridLayout( groupBox1->layout() );
    groupBox1Layout->setAlignment( TQt::AlignTop );

    cbAudioFormat = new TQComboBox( FALSE, groupBox1, "cbAudioFormat" );

    groupBox1Layout->addWidget( cbAudioFormat, 0, 1 );

    cbAudioBitrate = new TQComboBox( FALSE, groupBox1, "cbAudioBitrate" );

    groupBox1Layout->addWidget( cbAudioBitrate, 1, 1 );

    textLabel1 = new TQLabel( groupBox1, "textLabel1" );

    groupBox1Layout->addWidget( textLabel1, 0, 0 );

    textLabel2 = new TQLabel( groupBox1, "textLabel2" );

    groupBox1Layout->addWidget( textLabel2, 1, 0 );
    spacer1 = new TQSpacerItem( 151, 21, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    groupBox1Layout->addMultiCell( spacer1, 0, 1, 2, 2 );

    prefAuthorLayout->addWidget( groupBox1, 0, 0 );
    spacer3 = new TQSpacerItem( 20, 60, TQSizePolicy::Minimum, TQSizePolicy::Expanding );
    prefAuthorLayout->addItem( spacer3, 2, 0 );

    groupBox2 = new TQGroupBox( this, "groupBox2" );
    groupBox2->setColumnLayout(0, Qt::Vertical );
    groupBox2->layout()->setSpacing( 6 );
    groupBox2->layout()->setMargin( 11 );
    groupBox2Layout = new TQGridLayout( groupBox2->layout() );
    groupBox2Layout->setAlignment( TQt::AlignTop );

    textLabel3 = new TQLabel( groupBox2, "textLabel3" );

    groupBox2Layout->addWidget( textLabel3, 0, 0 );
    spacer2 = new TQSpacerItem( 121, 31, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    groupBox2Layout->addItem( spacer2, 0, 2 );

    textLabel5 = new TQLabel( groupBox2, "textLabel5" );

    groupBox2Layout->addWidget( textLabel5, 1, 0 );

    inButtonHeight = new KIntNumInput( groupBox2, "inButtonHeight" );
    inButtonHeight->setMinValue( 0 );
    inButtonHeight->setMaxValue( 480 );

    groupBox2Layout->addWidget( inButtonHeight, 1, 1 );

    inButtonWidth = new KIntNumInput( groupBox2, "inButtonWidth" );
    inButtonWidth->setMinValue( 0 );
    inButtonWidth->setMaxValue( 700 );

    groupBox2Layout->addWidget( inButtonWidth, 0, 1 );

    bButtonFont = new KPushButton( groupBox2, "bButtonFont" );

    groupBox2Layout->addWidget( bButtonFont, 4, 1 );

    textLabel6 = new TQLabel( groupBox2, "textLabel6" );

    groupBox2Layout->addWidget( textLabel6, 2, 0 );

    cbHiliteColor = new KColorButton( groupBox2, "cbHiliteColor" );

    groupBox2Layout->addWidget( cbHiliteColor, 2, 1 );

    textLabel6_2 = new TQLabel( groupBox2, "textLabel6_2" );

    groupBox2Layout->addWidget( textLabel6_2, 3, 0 );

    cbTextColor = new KColorButton( groupBox2, "cbTextColor" );

    groupBox2Layout->addWidget( cbTextColor, 3, 1 );

    prefAuthorLayout->addWidget( groupBox2, 1, 0 );
    languageChange();
    resize( TQSize(600, 480).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );

    // signals and slots connections
    connect( bButtonFont, TQT_SIGNAL( clicked() ), this, TQT_SLOT( bButtonFontClicked() ) );
}

/*
 *  Destroys the object and frees any allocated resources
 */
prefAuthor::~prefAuthor()
{
    // no need to delete child widgets, TQt does it all for us
}

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void prefAuthor::languageChange()
{
    setCaption( tr2i18n( "Authoring options" ) );
    groupBox1->setTitle( tr2i18n( "Audio" ) );
    cbAudioFormat->clear();
    cbAudioFormat->insertItem( tr2i18n( "AC3" ) );
    cbAudioFormat->insertItem( tr2i18n( "MP2" ) );
    cbAudioBitrate->clear();
    cbAudioBitrate->insertItem( tr2i18n( "128" ) );
    cbAudioBitrate->insertItem( tr2i18n( "192" ) );
    cbAudioBitrate->insertItem( tr2i18n( "320" ) );
    textLabel1->setText( tr2i18n( "Format" ) );
    textLabel2->setText( tr2i18n( "Bitrate" ) );
    groupBox2->setTitle( tr2i18n( "Buttons" ) );
    textLabel3->setText( tr2i18n( "Width" ) );
    textLabel5->setText( tr2i18n( "Height" ) );
    bButtonFont->setText( tr2i18n( "Font" ) );
    textLabel6->setText( tr2i18n( "Hilite color" ) );
    cbHiliteColor->setText( TQString() );
    textLabel6_2->setText( tr2i18n( "Text color" ) );
    cbTextColor->setText( TQString() );
}

void prefAuthor::bButtonFontClicked()
{
    tqWarning( "prefAuthor::bButtonFontClicked(): Not implemented yet" );
}

#include "prefAuthor.moc"