From 338f573ed1d077b6093fce0a5d5085f2e440dd0d Mon Sep 17 00:00:00 2001 From: Tim Bentley Date: Thu, 19 Feb 2009 18:35:37 +0000 Subject: [PATCH] Fix dialogs to be Qwidget instead of Qdialog bzr-revno: 323 --- .../plugins/bibles/forms/bibleeditdialog.py | 54 +++++++ .../plugins/bibles/forms/bibleimportdialog.py | 27 ++-- resources/forms/bibleeditdialog.ui | 80 +++++++++++ resources/forms/bibleimportdialog.ui | 135 ++++++++---------- 4 files changed, 207 insertions(+), 89 deletions(-) create mode 100644 openlp/plugins/bibles/forms/bibleeditdialog.py create mode 100644 resources/forms/bibleeditdialog.ui diff --git a/openlp/plugins/bibles/forms/bibleeditdialog.py b/openlp/plugins/bibles/forms/bibleeditdialog.py new file mode 100644 index 000000000..7acaf416c --- /dev/null +++ b/openlp/plugins/bibles/forms/bibleeditdialog.py @@ -0,0 +1,54 @@ +# -*- coding: utf-8 -*- + +# Form implementation generated from reading ui file 'bibleeditdialog.ui' +# +# Created: Wed Feb 18 06:02:58 2009 +# by: PyQt4 UI code generator 4.4.4 +# +# WARNING! All changes made in this file will be lost! + +from PyQt4 import QtCore, QtGui + +class Ui_dialog(object): + def setupUi(self, dialog): + dialog.setObjectName("dialog") + dialog.resize(400, 300) + icon = QtGui.QIcon() + icon.addPixmap(QtGui.QPixmap(":/icon/openlp.org-icon-32.bmp"), QtGui.QIcon.Normal, QtGui.QIcon.Off) + dialog.setWindowIcon(icon) + self.verticalLayout = QtGui.QVBoxLayout(dialog) + self.verticalLayout.setSpacing(8) + self.verticalLayout.setMargin(8) + self.verticalLayout.setObjectName("verticalLayout") + self.EditGroupBox = QtGui.QGroupBox(dialog) + self.EditGroupBox.setObjectName("EditGroupBox") + self.gridLayout = QtGui.QGridLayout(self.EditGroupBox) + self.gridLayout.setMargin(8) + self.gridLayout.setSpacing(8) + self.gridLayout.setObjectName("gridLayout") + self.VerseTextEdit = QtGui.QPlainTextEdit(self.EditGroupBox) + self.VerseTextEdit.setObjectName("VerseTextEdit") + self.gridLayout.addWidget(self.VerseTextEdit, 0, 0, 1, 1) + self.verticalLayout.addWidget(self.EditGroupBox) + self.ButtonLoayout = QtGui.QHBoxLayout() + self.ButtonLoayout.setSpacing(8) + self.ButtonLoayout.setMargin(8) + self.ButtonLoayout.setObjectName("ButtonLoayout") + self.SaveButton = QtGui.QPushButton(dialog) + self.SaveButton.setObjectName("SaveButton") + self.ButtonLoayout.addWidget(self.SaveButton) + self.CancelButton = QtGui.QPushButton(dialog) + self.CancelButton.setObjectName("CancelButton") + self.ButtonLoayout.addWidget(self.CancelButton) + self.verticalLayout.addLayout(self.ButtonLoayout) + + self.retranslateUi(dialog) + QtCore.QMetaObject.connectSlotsByName(dialog) + dialog.setTabOrder(self.VerseTextEdit, self.SaveButton) + dialog.setTabOrder(self.SaveButton, self.CancelButton) + + def retranslateUi(self, dialog): + dialog.setWindowTitle(QtGui.QApplication.translate("dialog", "Bible Edit Dialog", None, QtGui.QApplication.UnicodeUTF8)) + self.EditGroupBox.setTitle(QtGui.QApplication.translate("dialog", "Edit Verse Text", None, QtGui.QApplication.UnicodeUTF8)) + self.SaveButton.setText(QtGui.QApplication.translate("dialog", "Save", None, QtGui.QApplication.UnicodeUTF8)) + self.CancelButton.setText(QtGui.QApplication.translate("dialog", "Cancel", None, QtGui.QApplication.UnicodeUTF8)) diff --git a/openlp/plugins/bibles/forms/bibleimportdialog.py b/openlp/plugins/bibles/forms/bibleimportdialog.py index 9aaf26a1e..7a34faa14 100644 --- a/openlp/plugins/bibles/forms/bibleimportdialog.py +++ b/openlp/plugins/bibles/forms/bibleimportdialog.py @@ -2,7 +2,7 @@ # Form implementation generated from reading ui file 'bibleimportdialog.ui' # -# Created: Sat Feb 14 08:25:46 2009 +# Created: Thu Feb 19 16:01:11 2009 # by: PyQt4 UI code generator 4.4.4 # # WARNING! All changes made in this file will be lost! @@ -17,13 +17,14 @@ class Ui_BibleImportDialog(object): icon.addPixmap(QtGui.QPixmap(":/icon/openlp.org-icon-32.bmp"), QtGui.QIcon.Normal, QtGui.QIcon.Off) BibleImportDialog.setWindowIcon(icon) self.ImportToolBox = QtGui.QToolBox(BibleImportDialog) - self.ImportToolBox.setGeometry(QtCore.QRect(10, 0, 471, 431)) + self.ImportToolBox.setGeometry(QtCore.QRect(20, 20, 451, 401)) + self.ImportToolBox.setFrameShape(QtGui.QFrame.StyledPanel) self.ImportToolBox.setObjectName("ImportToolBox") self.FileImportPage = QtGui.QWidget() - self.FileImportPage.setGeometry(QtCore.QRect(0, 0, 471, 371)) + self.FileImportPage.setGeometry(QtCore.QRect(0, 0, 447, 337)) self.FileImportPage.setObjectName("FileImportPage") self.OSISGroupBox = QtGui.QGroupBox(self.FileImportPage) - self.OSISGroupBox.setGeometry(QtCore.QRect(8, 65, 451, 81)) + self.OSISGroupBox.setGeometry(QtCore.QRect(18, 65, 411, 81)) self.OSISGroupBox.setObjectName("OSISGroupBox") self.gridLayout_2 = QtGui.QGridLayout(self.OSISGroupBox) self.gridLayout_2.setMargin(8) @@ -42,7 +43,7 @@ class Ui_BibleImportDialog(object): self.OsisFileButton.setObjectName("OsisFileButton") self.gridLayout_2.addWidget(self.OsisFileButton, 0, 2, 1, 1) self.CVSGroupBox = QtGui.QGroupBox(self.FileImportPage) - self.CVSGroupBox.setGeometry(QtCore.QRect(10, 170, 451, 191)) + self.CVSGroupBox.setGeometry(QtCore.QRect(20, 170, 411, 191)) self.CVSGroupBox.setObjectName("CVSGroupBox") self.gridLayout = QtGui.QGridLayout(self.CVSGroupBox) self.gridLayout.setMargin(8) @@ -76,7 +77,7 @@ class Ui_BibleImportDialog(object): self.BibleNameLabel.setObjectName("BibleNameLabel") self.ImportToolBox.addItem(self.FileImportPage, "") self.WebBiblePage = QtGui.QWidget() - self.WebBiblePage.setGeometry(QtCore.QRect(0, 0, 471, 371)) + self.WebBiblePage.setGeometry(QtCore.QRect(0, 0, 192, 228)) self.WebBiblePage.setObjectName("WebBiblePage") self.WebBibleLayout = QtGui.QVBoxLayout(self.WebBiblePage) self.WebBibleLayout.setSpacing(8) @@ -84,23 +85,25 @@ class Ui_BibleImportDialog(object): self.WebBibleLayout.setObjectName("WebBibleLayout") self.OptionsGroupBox = QtGui.QGroupBox(self.WebBiblePage) self.OptionsGroupBox.setObjectName("OptionsGroupBox") + self.formLayout_2 = QtGui.QFormLayout(self.OptionsGroupBox) + self.formLayout_2.setObjectName("formLayout_2") self.LocationLabel = QtGui.QLabel(self.OptionsGroupBox) - self.LocationLabel.setGeometry(QtCore.QRect(11, 27, 54, 16)) self.LocationLabel.setObjectName("LocationLabel") + self.formLayout_2.setWidget(0, QtGui.QFormLayout.LabelRole, self.LocationLabel) self.LocationComboBox = QtGui.QComboBox(self.OptionsGroupBox) - self.LocationComboBox.setGeometry(QtCore.QRect(71, 27, 371, 21)) self.LocationComboBox.setObjectName("LocationComboBox") self.LocationComboBox.addItem(QtCore.QString()) + self.formLayout_2.setWidget(0, QtGui.QFormLayout.FieldRole, self.LocationComboBox) self.BibleLabel = QtGui.QLabel(self.OptionsGroupBox) - self.BibleLabel.setGeometry(QtCore.QRect(11, 54, 34, 16)) self.BibleLabel.setObjectName("BibleLabel") + self.formLayout_2.setWidget(1, QtGui.QFormLayout.LabelRole, self.BibleLabel) self.BibleComboBox = QtGui.QComboBox(self.OptionsGroupBox) - self.BibleComboBox.setGeometry(QtCore.QRect(71, 54, 371, 21)) self.BibleComboBox.setObjectName("BibleComboBox") self.BibleComboBox.addItem(QtCore.QString()) self.BibleComboBox.setItemText(0, "") self.BibleComboBox.addItem(QtCore.QString()) self.BibleComboBox.addItem(QtCore.QString()) + self.formLayout_2.setWidget(1, QtGui.QFormLayout.FieldRole, self.BibleComboBox) self.WebBibleLayout.addWidget(self.OptionsGroupBox) self.ProxyGroupBox = QtGui.QGroupBox(self.WebBiblePage) self.ProxyGroupBox.setObjectName("ProxyGroupBox") @@ -156,7 +159,7 @@ class Ui_BibleImportDialog(object): self.PermisionEdit.setObjectName("PermisionEdit") self.formLayout.setWidget(2, QtGui.QFormLayout.FieldRole, self.PermisionEdit) self.MessageLabel = QtGui.QLabel(BibleImportDialog) - self.MessageLabel.setGeometry(QtCore.QRect(20, 670, 451, 17)) + self.MessageLabel.setGeometry(QtCore.QRect(20, 670, 271, 17)) self.MessageLabel.setObjectName("MessageLabel") self.ProgressGroupBox = QtGui.QGroupBox(BibleImportDialog) self.ProgressGroupBox.setGeometry(QtCore.QRect(10, 600, 471, 70)) @@ -182,7 +185,7 @@ class Ui_BibleImportDialog(object): self.horizontalLayout.addWidget(self.CancelButton) self.retranslateUi(BibleImportDialog) - self.ImportToolBox.setCurrentIndex(1) + self.ImportToolBox.setCurrentIndex(0) QtCore.QMetaObject.connectSlotsByName(BibleImportDialog) BibleImportDialog.setTabOrder(self.BibleNameEdit, self.OSISLocationEdit) BibleImportDialog.setTabOrder(self.OSISLocationEdit, self.OsisFileButton) diff --git a/resources/forms/bibleeditdialog.ui b/resources/forms/bibleeditdialog.ui new file mode 100644 index 000000000..3a947cc17 --- /dev/null +++ b/resources/forms/bibleeditdialog.ui @@ -0,0 +1,80 @@ + + + dialog + + + + 0 + 0 + 400 + 300 + + + + Bible Edit Dialog + + + + :/icon/openlp.org-icon-32.bmp:/icon/openlp.org-icon-32.bmp + + + + 8 + + + 8 + + + + + Edit Verse Text + + + + 8 + + + 8 + + + + + + + + + + + 8 + + + 8 + + + + + Save + + + + + + + Cancel + + + + + + + + + VerseTextEdit + SaveButton + CancelButton + + + + + + diff --git a/resources/forms/bibleimportdialog.ui b/resources/forms/bibleimportdialog.ui index 1b623b784..06fcdbb1f 100644 --- a/resources/forms/bibleimportdialog.ui +++ b/resources/forms/bibleimportdialog.ui @@ -1,7 +1,7 @@ BibleImportDialog - + 0 @@ -20,22 +20,25 @@ - 10 - 0 - 471 - 431 + 20 + 20 + 451 + 401 + + QFrame::StyledPanel + - 1 + 0 0 0 - 471 - 371 + 447 + 337 @@ -44,9 +47,9 @@ - 8 + 18 65 - 451 + 411 81 @@ -86,9 +89,9 @@ - 10 + 20 170 - 451 + 411 191 @@ -175,8 +178,8 @@ 0 0 - 471 - 371 + 192 + 228 @@ -194,72 +197,50 @@ Download Options - - - - 11 - 27 - 54 - 16 - - - - Location: - - - - - - 71 - 27 - 371 - 21 - - - - - Crosswalk - + + + + + Location: + + - - - - - 11 - 54 - 34 - 16 - - - - Bible: - - - - - - 71 - 54 - 371 - 21 - - - - - - + + + + + Crosswalk + + + - - - NIV - + + + + Bible: + + - - - KJV - + + + + + + + + + + NIV + + + + + KJV + + + - + BibleComboBox LocationLabel BibleLabel @@ -382,7 +363,7 @@ 20 670 - 451 + 271 17