From 0b1e2b33f3bc1d2dfaf15f8554b66ddb70334297 Mon Sep 17 00:00:00 2001 From: Harishankar Date: Thu, 25 Nov 2010 13:21:21 +0530 Subject: [PATCH] Added the Site Configuration dialog Added the site configuration dialog for the new website dialog and website configuration. --- site_configuration_dialog.py | 10 ++ site_configuration_dialog.ui | 177 ++++++++++++++++++++++++++++++++ ui_site_configuration_dialog.py | 101 ++++++++++++++++++ 3 files changed, 288 insertions(+) create mode 100644 site_configuration_dialog.py create mode 100644 site_configuration_dialog.ui create mode 100644 ui_site_configuration_dialog.py diff --git a/site_configuration_dialog.py b/site_configuration_dialog.py new file mode 100644 index 0000000..2ba99bb --- /dev/null +++ b/site_configuration_dialog.py @@ -0,0 +1,10 @@ +# BiaWeb Website content manager (c) 2010 V.Harishankar +# Site Configuration Dialog class + +import PyQt4 +import ui_site_configuration_dialog as uscd + +class SiteConfigDialog (PyQt4.QtGui.QDialog, uscd.Ui_SiteConfigDialog): + def __init__ (self, parent): + PyQt4.QtGui.QDialog.__init__ (self, parent) + self.setupUi (self) diff --git a/site_configuration_dialog.ui b/site_configuration_dialog.ui new file mode 100644 index 0000000..11ee0d3 --- /dev/null +++ b/site_configuration_dialog.ui @@ -0,0 +1,177 @@ + + + SiteConfigDialog + + + + 0 + 0 + 562 + 367 + + + + Site Configuration + + + + + + Name of the site + + + + + + + + + + Site URL + + + + + + + + + + + + + + Keywords + + + + + + + + + + Description + + + + + + + Qt::ScrollBarAlwaysOn + + + true + + + + + + + # of RSS feed items + + + + + + + Export destination + + + + + + + + + + browse... + + + + + + + Qt::Horizontal + + + QDialogButtonBox::Cancel|QDialogButtonBox::Ok + + + + + + + http:// + + + + + + + 1 + + + 20 + + + + + + + + + + Copyright text + + + + + + + site_title + site_url + keywords + description + num_rss_items + copyright + destination + destination_browse_button + buttonBox + + + + + buttonBox + accepted() + SiteConfigDialog + accept() + + + 248 + 254 + + + 157 + 274 + + + + + buttonBox + rejected() + SiteConfigDialog + reject() + + + 316 + 260 + + + 286 + 274 + + + + + diff --git a/ui_site_configuration_dialog.py b/ui_site_configuration_dialog.py new file mode 100644 index 0000000..80d8c45 --- /dev/null +++ b/ui_site_configuration_dialog.py @@ -0,0 +1,101 @@ +# -*- coding: utf-8 -*- + +# Form implementation generated from reading ui file 'site_configuration_dialog.ui' +# +# Created: Thu Nov 25 13:17:07 2010 +# by: PyQt4 UI code generator 4.7.4 +# +# WARNING! All changes made in this file will be lost! + +from PyQt4 import QtCore, QtGui + +class Ui_SiteConfigDialog(object): + def setupUi(self, SiteConfigDialog): + SiteConfigDialog.setObjectName("SiteConfigDialog") + SiteConfigDialog.resize(562, 367) + self.gridLayout = QtGui.QGridLayout(SiteConfigDialog) + self.gridLayout.setObjectName("gridLayout") + self.label = QtGui.QLabel(SiteConfigDialog) + self.label.setObjectName("label") + self.gridLayout.addWidget(self.label, 0, 0, 1, 1) + self.site_title = QtGui.QLineEdit(SiteConfigDialog) + self.site_title.setObjectName("site_title") + self.gridLayout.addWidget(self.site_title, 0, 1, 1, 7) + self.label_2 = QtGui.QLabel(SiteConfigDialog) + self.label_2.setObjectName("label_2") + self.gridLayout.addWidget(self.label_2, 1, 0, 1, 1) + self.site_url = QtGui.QLineEdit(SiteConfigDialog) + self.site_url.setText("") + self.site_url.setObjectName("site_url") + self.gridLayout.addWidget(self.site_url, 1, 2, 1, 6) + self.label_3 = QtGui.QLabel(SiteConfigDialog) + self.label_3.setObjectName("label_3") + self.gridLayout.addWidget(self.label_3, 2, 0, 1, 1) + self.keywords = QtGui.QLineEdit(SiteConfigDialog) + self.keywords.setObjectName("keywords") + self.gridLayout.addWidget(self.keywords, 2, 1, 1, 7) + self.label_4 = QtGui.QLabel(SiteConfigDialog) + self.label_4.setObjectName("label_4") + self.gridLayout.addWidget(self.label_4, 3, 0, 1, 1) + self.description = QtGui.QPlainTextEdit(SiteConfigDialog) + self.description.setVerticalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOn) + self.description.setTabChangesFocus(True) + self.description.setObjectName("description") + self.gridLayout.addWidget(self.description, 3, 1, 1, 7) + self.label_6 = QtGui.QLabel(SiteConfigDialog) + self.label_6.setObjectName("label_6") + self.gridLayout.addWidget(self.label_6, 4, 0, 1, 2) + self.label_5 = QtGui.QLabel(SiteConfigDialog) + self.label_5.setObjectName("label_5") + self.gridLayout.addWidget(self.label_5, 5, 0, 1, 1) + self.destination = QtGui.QLineEdit(SiteConfigDialog) + self.destination.setObjectName("destination") + self.gridLayout.addWidget(self.destination, 5, 1, 1, 6) + self.destination_browse_button = QtGui.QPushButton(SiteConfigDialog) + self.destination_browse_button.setObjectName("destination_browse_button") + self.gridLayout.addWidget(self.destination_browse_button, 5, 7, 1, 1) + self.buttonBox = QtGui.QDialogButtonBox(SiteConfigDialog) + self.buttonBox.setOrientation(QtCore.Qt.Horizontal) + self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok) + self.buttonBox.setObjectName("buttonBox") + self.gridLayout.addWidget(self.buttonBox, 6, 0, 1, 8) + self.label_8 = QtGui.QLabel(SiteConfigDialog) + self.label_8.setObjectName("label_8") + self.gridLayout.addWidget(self.label_8, 1, 1, 1, 1) + self.num_rss_items = QtGui.QSpinBox(SiteConfigDialog) + self.num_rss_items.setMinimum(1) + self.num_rss_items.setMaximum(20) + self.num_rss_items.setObjectName("num_rss_items") + self.gridLayout.addWidget(self.num_rss_items, 4, 2, 1, 1) + self.copyright = QtGui.QLineEdit(SiteConfigDialog) + self.copyright.setObjectName("copyright") + self.gridLayout.addWidget(self.copyright, 4, 4, 1, 4) + self.label_7 = QtGui.QLabel(SiteConfigDialog) + self.label_7.setObjectName("label_7") + self.gridLayout.addWidget(self.label_7, 4, 3, 1, 1) + + self.retranslateUi(SiteConfigDialog) + QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL("accepted()"), SiteConfigDialog.accept) + QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL("rejected()"), SiteConfigDialog.reject) + QtCore.QMetaObject.connectSlotsByName(SiteConfigDialog) + SiteConfigDialog.setTabOrder(self.site_title, self.site_url) + SiteConfigDialog.setTabOrder(self.site_url, self.keywords) + SiteConfigDialog.setTabOrder(self.keywords, self.description) + SiteConfigDialog.setTabOrder(self.description, self.num_rss_items) + SiteConfigDialog.setTabOrder(self.num_rss_items, self.copyright) + SiteConfigDialog.setTabOrder(self.copyright, self.destination) + SiteConfigDialog.setTabOrder(self.destination, self.destination_browse_button) + SiteConfigDialog.setTabOrder(self.destination_browse_button, self.buttonBox) + + def retranslateUi(self, SiteConfigDialog): + SiteConfigDialog.setWindowTitle(QtGui.QApplication.translate("SiteConfigDialog", "Site Configuration", None, QtGui.QApplication.UnicodeUTF8)) + self.label.setText(QtGui.QApplication.translate("SiteConfigDialog", "Name of the site", None, QtGui.QApplication.UnicodeUTF8)) + self.label_2.setText(QtGui.QApplication.translate("SiteConfigDialog", "Site URL", None, QtGui.QApplication.UnicodeUTF8)) + self.label_3.setText(QtGui.QApplication.translate("SiteConfigDialog", "Keywords", None, QtGui.QApplication.UnicodeUTF8)) + self.label_4.setText(QtGui.QApplication.translate("SiteConfigDialog", "Description", None, QtGui.QApplication.UnicodeUTF8)) + self.label_6.setText(QtGui.QApplication.translate("SiteConfigDialog", "# of RSS feed items", None, QtGui.QApplication.UnicodeUTF8)) + self.label_5.setText(QtGui.QApplication.translate("SiteConfigDialog", "Export destination", None, QtGui.QApplication.UnicodeUTF8)) + self.destination_browse_button.setText(QtGui.QApplication.translate("SiteConfigDialog", "browse...", None, QtGui.QApplication.UnicodeUTF8)) + self.label_8.setText(QtGui.QApplication.translate("SiteConfigDialog", "http://", None, QtGui.QApplication.UnicodeUTF8)) + self.label_7.setText(QtGui.QApplication.translate("SiteConfigDialog", "Copyright text", None, QtGui.QApplication.UnicodeUTF8)) + -- 2.20.1