diff --git a/openlp/plugins/bibles/forms/editbibledialog.py b/openlp/plugins/bibles/forms/editbibledialog.py index febfa820d..c3db88e91 100644 --- a/openlp/plugins/bibles/forms/editbibledialog.py +++ b/openlp/plugins/bibles/forms/editbibledialog.py @@ -49,34 +49,52 @@ class Ui_EditBibleDialog(object): # Meta tab self.metaTab = QtGui.QWidget() self.metaTab.setObjectName(u'metaTab') - self.metaTabLayout = QtGui.QFormLayout(self.metaTab) + self.metaTabLayout = QtGui.QVBoxLayout(self.metaTab) self.metaTabLayout.setObjectName(u'metaTabLayout') - self.versionNameLabel = QtGui.QLabel(self.metaTab) + self.licenseDetailsGroupBox = QtGui.QGroupBox(self.metaTab) + self.licenseDetailsGroupBox.setObjectName(u'licenseDetailsGroupBox') + self.licenseDetailsLayout = QtGui.QFormLayout( + self.licenseDetailsGroupBox) + self.licenseDetailsLayout.setObjectName(u'licenseDetailsLayout') + self.versionNameLabel = QtGui.QLabel(self.licenseDetailsGroupBox) self.versionNameLabel.setObjectName(u'versionNameLabel') - self.versionNameEdit = QtGui.QLineEdit(self.metaTab) + self.versionNameEdit = QtGui.QLineEdit(self.licenseDetailsGroupBox) self.versionNameEdit.setObjectName(u'versionNameEdit') self.versionNameLabel.setBuddy(self.versionNameEdit) - self.metaTabLayout.addRow(self.versionNameLabel, self.versionNameEdit) - self.copyrightLabel = QtGui.QLabel(self.metaTab) + self.licenseDetailsLayout.addRow(self.versionNameLabel, + self.versionNameEdit) + self.copyrightLabel = QtGui.QLabel(self.licenseDetailsGroupBox) self.copyrightLabel.setObjectName(u'copyrightLabel') - self.copyrightEdit = QtGui.QLineEdit(self.metaTab) + self.copyrightEdit = QtGui.QLineEdit(self.licenseDetailsGroupBox) self.copyrightEdit.setObjectName(u'copyrightEdit') self.copyrightLabel.setBuddy(self.copyrightEdit) - self.metaTabLayout.addRow(self.copyrightLabel, self.copyrightEdit) - self.permissionsLabel = QtGui.QLabel(self.metaTab) + self.licenseDetailsLayout.addRow(self.copyrightLabel, + self.copyrightEdit) + self.permissionsLabel = QtGui.QLabel(self.licenseDetailsGroupBox) self.permissionsLabel.setObjectName(u'permissionsLabel') - self.permissionsEdit = QtGui.QLineEdit(self.metaTab) + self.permissionsEdit = QtGui.QLineEdit(self.licenseDetailsGroupBox) self.permissionsEdit.setObjectName(u'permissionsEdit') self.permissionsLabel.setBuddy(self.permissionsEdit) - self.metaTabLayout.addRow(self.permissionsLabel, self.permissionsEdit) - self.languageSelectionLabel = QtGui.QLabel(self.metaTab) + self.licenseDetailsLayout.addRow(self.permissionsLabel, + self.permissionsEdit) + self.metaTabLayout.addWidget(self.licenseDetailsGroupBox) + self.languageSelectionGroupBox = QtGui.QGroupBox(self.metaTab) + self.languageSelectionGroupBox.setObjectName( + u'languageSelectionGroupBox') + self.languageSelectionLayout = QtGui.QVBoxLayout( + self.languageSelectionGroupBox) + self.languageSelectionLabel = QtGui.QLabel( + self.languageSelectionGroupBox) self.languageSelectionLabel.setObjectName(u'languageSelectionLabel') - self.languageSelectionComboBox = QtGui.QComboBox(self.metaTab) + self.languageSelectionComboBox = QtGui.QComboBox( + self.languageSelectionGroupBox) self.languageSelectionComboBox.setObjectName( u'languageSelectionComboBox') self.languageSelectionComboBox.addItems([u'', u'', u'', u'']) - self.metaTabLayout.addRow(self.languageSelectionLabel, - self.languageSelectionComboBox) + self.languageSelectionLayout.addWidget(self.languageSelectionLabel) + self.languageSelectionLayout.addWidget(self.languageSelectionComboBox) + self.metaTabLayout.addWidget(self.languageSelectionGroupBox) + self.metaTabLayout.addStretch() self.bibleTabWidget.addTab(self.metaTab, u'') # Book name tab self.bookNameTab = QtGui.QWidget() @@ -97,7 +115,6 @@ class Ui_EditBibleDialog(object): self.bookNameWidgetLayout.setObjectName(u'bookNameWidgetLayout') self.bookNameLabel = {} self.bookNameEdit= {} - x = 0 for book in BiblesResourcesDB.get_books(): self.bookNameLabel[book[u'abbreviation']] = QtGui.QLabel( self.bookNameWidget) @@ -110,7 +127,6 @@ class Ui_EditBibleDialog(object): self.bookNameWidgetLayout.addRow( self.bookNameLabel[book[u'abbreviation']], self.bookNameEdit[book[u'abbreviation']]) - x = x + 1 self.scrollArea.setWidget(self.bookNameWidget) self.bookNameTabLayout.addWidget(self.scrollArea) self.bookNameTabLayout.addStretch() @@ -126,23 +142,27 @@ class Ui_EditBibleDialog(object): def retranslateUi(self, editBibleDialog): self.booknames = BibleStrings().Booknames editBibleDialog.setWindowTitle( - translate('BiblesPlugin.EditBibleForm', 'Song Editor')) + translate('BiblesPlugin.EditBibleForm', 'Bible Editor')) + # Meta tab self.bibleTabWidget.setTabText( self.bibleTabWidget.indexOf(self.metaTab), - translate('SongsPlugin.EditBibleForm', 'License Details')) + translate('SongsPlugin.EditBibleForm', 'Meta Data')) + self.licenseDetailsGroupBox.setTitle( + translate('BiblesPlugin.EditBibleForm', 'License Details')) self.versionNameLabel.setText( translate('BiblesPlugin.EditBibleForm', 'Version name:')) self.copyrightLabel.setText( translate('BiblesPlugin.EditBibleForm', 'Copyright:')) self.permissionsLabel.setText( translate('BiblesPlugin.EditBibleForm', 'Permissions:')) - self.bibleTabWidget.setTabText( - self.bibleTabWidget.indexOf(self.bookNameTab), - translate('SongsPlugin.EditBibleForm', 'Custom Book Names')) + self.languageSelectionGroupBox.setTitle(translate( + 'BiblesPlugin.EditBibleForm', 'Default Bible Language')) self.languageSelectionLabel.setText( - translate('BiblesPlugin.EditBibleForm', 'Book name language:')) + translate('BiblesPlugin.EditBibleForm', + 'Book name language in search field, search results and on ' + 'display:')) self.languageSelectionComboBox.setItemText(0, - translate('BiblesPlugin.EditBibleForm', 'General Settings')) + translate('BiblesPlugin.EditBibleForm', 'Global Settings')) self.languageSelectionComboBox.setItemText(LanguageSelection.Bible + 1, translate('BiblesPlugin.EditBibleForm', 'Bible Language')) self.languageSelectionComboBox.setItemText( @@ -151,12 +171,10 @@ class Ui_EditBibleDialog(object): self.languageSelectionComboBox.setItemText( LanguageSelection.English + 1, translate('BiblesPlugin.EditBibleForm', 'English')) - self.languageSelectionComboBox.setToolTip( - translate('BiblesPlugin.EditBibleForm', 'Multiple options:\n' - 'General Settings - the option choosen in settings section\n' - 'Bible language - the language in which the Bible book names ' - 'were imported\nApplication language - the language you have ' - 'chosen for OpenLP\nEnglish - always use English book names')) + # Book name tab + self.bibleTabWidget.setTabText( + self.bibleTabWidget.indexOf(self.bookNameTab), + translate('SongsPlugin.EditBibleForm', 'Custom Book Names')) for book in BiblesResourcesDB.get_books(): self.bookNameLabel[book[u'abbreviation']].setText( u'%s:' % unicode(self.booknames[book[u'abbreviation']])) diff --git a/openlp/plugins/bibles/forms/editbibleform.py b/openlp/plugins/bibles/forms/editbibleform.py index cb825db04..4fc73e607 100644 --- a/openlp/plugins/bibles/forms/editbibleform.py +++ b/openlp/plugins/bibles/forms/editbibleform.py @@ -82,12 +82,11 @@ class EditBibleForm(QtGui.QDialog, Ui_EditBibleDialog): self.bookNameNotice.setText(translate('BiblesPlugin.EditBibleForm', 'This is a webbible.\nIt is not possible to customize the Book ' 'Names.')) - self.bookNameTabLayout.removeWidget(self.scrollArea) - self.scrollArea.setParent(None) + self.scrollArea.hide() else: self.bookNameNotice.setText(translate('BiblesPlugin.EditBibleForm', 'To use the customized Book Names, choose the option "Bible ' - 'language"\nin general settings or explicit for this Bible.')) + 'language"\nin global settings or explicit for this Bible.')) for book in BiblesResourcesDB.get_books(): self.books[book[u'abbreviation']] = self.manager.get_book_by_id( self.bible, book[u'id']) diff --git a/openlp/plugins/bibles/lib/biblestab.py b/openlp/plugins/bibles/lib/biblestab.py index 353dc265d..751c23264 100644 --- a/openlp/plugins/bibles/lib/biblestab.py +++ b/openlp/plugins/bibles/lib/biblestab.py @@ -276,10 +276,11 @@ class BiblesTab(SettingsTab): 'end marks may be defined.\nThey have to be separated by a ' 'vertical bar "|".\nPlease clear this edit line to use the ' 'default value.')) - self.languageSelectionGroupBox.setTitle(translate('BiblesPlugin.BiblesTab', - 'Default Search Field Language')) + self.languageSelectionGroupBox.setTitle(translate( + 'BiblesPlugin.BiblesTab', 'Default Bible Language')) self.languageSelectionLabel.setText(translate('BiblesPlugin.BiblesTab', - 'Book name language in search field:')) + 'Book name language in search field,\nsearch results and on ' + 'display:')) self.languageSelectionComboBox.setItemText(LanguageSelection.Bible, translate('BiblesPlugin.BiblesTab', 'Bible language')) self.languageSelectionComboBox.setItemText(