10 #include <QtCore/QVariant>
11 #include <QtGui/QAction>
12 #include <QtGui/QApplication>
13 #include <QtGui/QButtonGroup>
14 #include <QtGui/QGridLayout>
15 #include <QtGui/QHBoxLayout>
16 #include <QtGui/QHeaderView>
17 #include <QtGui/QLabel>
18 #include <QtGui/QLineEdit>
19 #include <QtGui/QPushButton>
20 #include <QtGui/QSpacerItem>
21 #include <QtGui/QVBoxLayout>
22 #include <QtGui/QWidget>
29 QGridLayout *gridLayout;
31 QVBoxLayout *verticalLayout;
32 QLineEdit *sourceHighlightDataDirLineEdit;
33 QHBoxLayout *horizontalLayout;
34 QSpacerItem *horizontalSpacer;
35 QPushButton *browseButton;
36 QPushButton *defaultButton;
39 QSpacerItem *verticalSpacer;
41 void setupUi(QWidget *SourceHighlightSettingsPage)
43 if (SourceHighlightSettingsPage->objectName().isEmpty())
44 SourceHighlightSettingsPage->setObjectName(QString::fromUtf8(
"SourceHighlightSettingsPage"));
45 SourceHighlightSettingsPage->resize(400, 300);
46 gridLayout =
new QGridLayout(SourceHighlightSettingsPage);
47 gridLayout->setObjectName(QString::fromUtf8(
"gridLayout"));
48 label =
new QLabel(SourceHighlightSettingsPage);
49 label->setObjectName(QString::fromUtf8(
"label"));
51 gridLayout->addWidget(label, 0, 0, 1, 1);
53 verticalLayout =
new QVBoxLayout();
54 verticalLayout->setObjectName(QString::fromUtf8(
"verticalLayout"));
55 sourceHighlightDataDirLineEdit =
new QLineEdit(SourceHighlightSettingsPage);
56 sourceHighlightDataDirLineEdit->setObjectName(QString::fromUtf8(
"sourceHighlightDataDirLineEdit"));
58 verticalLayout->addWidget(sourceHighlightDataDirLineEdit);
60 horizontalLayout =
new QHBoxLayout();
61 horizontalLayout->setObjectName(QString::fromUtf8(
"horizontalLayout"));
62 horizontalSpacer =
new QSpacerItem(197, 20, QSizePolicy::Expanding, QSizePolicy::Minimum);
64 horizontalLayout->addItem(horizontalSpacer);
66 browseButton =
new QPushButton(SourceHighlightSettingsPage);
67 browseButton->setObjectName(QString::fromUtf8(
"browseButton"));
69 horizontalLayout->addWidget(browseButton);
71 defaultButton =
new QPushButton(SourceHighlightSettingsPage);
72 defaultButton->setObjectName(QString::fromUtf8(
"defaultButton"));
74 horizontalLayout->addWidget(defaultButton);
77 verticalLayout->addLayout(horizontalLayout);
80 gridLayout->addLayout(verticalLayout, 1, 0, 1, 2);
82 errorLabel =
new QLabel(SourceHighlightSettingsPage);
83 errorLabel->setObjectName(QString::fromUtf8(
"errorLabel"));
87 errorLabel->setFont(font);
89 gridLayout->addWidget(errorLabel, 2, 0, 1, 2);
91 okLabel =
new QLabel(SourceHighlightSettingsPage);
92 okLabel->setObjectName(QString::fromUtf8(
"okLabel"));
94 gridLayout->addWidget(okLabel, 3, 0, 1, 1);
96 verticalSpacer =
new QSpacerItem(20, 193, QSizePolicy::Minimum, QSizePolicy::Expanding);
98 gridLayout->addItem(verticalSpacer, 4, 1, 1, 1);
100 #ifndef QT_NO_SHORTCUT
101 label->setBuddy(sourceHighlightDataDirLineEdit);
102 #endif // QT_NO_SHORTCUT
104 retranslateUi(SourceHighlightSettingsPage);
106 QMetaObject::connectSlotsByName(SourceHighlightSettingsPage);
109 void retranslateUi(QWidget *SourceHighlightSettingsPage)
111 SourceHighlightSettingsPage->setWindowTitle(QApplication::translate(
"SourceHighlightSettingsPage",
"Form", 0, QApplication::UnicodeUTF8));
112 label->setText(QApplication::translate(
"SourceHighlightSettingsPage",
"Source-highlight's files path", 0, QApplication::UnicodeUTF8));
113 #ifndef QT_NO_TOOLTIP
114 sourceHighlightDataDirLineEdit->setToolTip(QApplication::translate(
"SourceHighlightSettingsPage",
"<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n"
115 "<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n"
116 "p, li { white-space: pre-wrap; }\n"
117 "</style></head><body style=\" font-family:'Sans'; font-size:10pt; font-weight:400; font-style:normal;\">\n"
118 "<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\">Sets the path where source-highlight searches for all its configuration files (e.g., .lang, .outlang, etc.); this basically corresponds to source-highlight's <span style=\" font-weight:600;\">--data-dir</span> command line option.</p></body></html>", 0, QApplication::UnicodeUTF8));
119 #endif // QT_NO_TOOLTIP
120 browseButton->setText(QApplication::translate(
"SourceHighlightSettingsPage",
"Browse...", 0, QApplication::UnicodeUTF8));
121 #ifndef QT_NO_TOOLTIP
122 defaultButton->setToolTip(QApplication::translate(
"SourceHighlightSettingsPage",
"Use the default (hardcoded) value from the source-highlight library", 0, QApplication::UnicodeUTF8));
123 #endif // QT_NO_TOOLTIP
124 defaultButton->setText(QApplication::translate(
"SourceHighlightSettingsPage",
"Default", 0, QApplication::UnicodeUTF8));
125 errorLabel->setText(QApplication::translate(
"SourceHighlightSettingsPage",
"<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n"
126 "<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n"
127 "p, li { white-space: pre-wrap; }\n"
128 "</style></head><body style=\" font-family:'Sans'; font-size:10pt; font-weight:400; font-style:normal;\">\n"
129 "<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\"><span style=\" font-weight:600; color:#ff0000;\">The path is not a valid source-highlight's path</span></p></body></html>", 0, QApplication::UnicodeUTF8));
130 okLabel->setText(QApplication::translate(
"SourceHighlightSettingsPage",
"<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n"
131 "<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n"
132 "p, li { white-space: pre-wrap; }\n"
133 "</style></head><body style=\" font-family:'Sans'; font-size:10pt; font-weight:400; font-style:normal;\">\n"
134 "<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\"><span style=\" color:#00aa00;\">Valid source-highlight path</span></p></body></html>", 0, QApplication::UnicodeUTF8));