From d84abfaadbdbbf279172f7d4c2605781c90ede3b Mon Sep 17 00:00:00 2001 From: "s.mehrbrodt@exposong.org" Date: Wed, 17 Jul 2013 12:02:54 +0200 Subject: [PATCH 1/5] Set Minimum Size for PreviewPane and LivePane --- resources/forms/mainwindow.ui | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/resources/forms/mainwindow.ui b/resources/forms/mainwindow.ui index 2b422d930..60595864e 100644 --- a/resources/forms/mainwindow.ui +++ b/resources/forms/mainwindow.ui @@ -38,6 +38,12 @@ Qt::Horizontal + + + 150 + 0 + + 0 @@ -78,6 +84,12 @@ + + + 150 + 0 + + 0 From 951d8964db6dbcdf1335f2b187daa665f2df784a Mon Sep 17 00:00:00 2001 From: "s.mehrbrodt@gmail.com" Date: Fri, 19 Jul 2013 17:36:45 +0200 Subject: [PATCH 2/5] Don't allow to collapse the Live or Preview Pane. They can still be hidden via the menu. --- openlp/core/ui/mainwindow.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/openlp/core/ui/mainwindow.py b/openlp/core/ui/mainwindow.py index 307239032..e616a7b42 100644 --- a/openlp/core/ui/mainwindow.py +++ b/openlp/core/ui/mainwindow.py @@ -1196,6 +1196,9 @@ class MainWindow(QtGui.QMainWindow, Ui_MainWindow): self.live_controller.splitter.restoreState(settings.value(u'live splitter geometry')) self.preview_controller.splitter.restoreState(settings.value(u'preview splitter geometry')) self.control_splitter.restoreState(settings.value(u'main window splitter geometry')) + #This needs to be called after restoreState(), because saveState() also saves the "Collapsible" property + #which was True (by default) < OpenLP 2.1. + self.control_splitter.setChildrenCollapsible(False) settings.endGroup() def save_settings(self): From 41cfa38fb6387b4450744214d89af069c1c9f788 Mon Sep 17 00:00:00 2001 From: "s.mehrbrodt@gmail.com" Date: Fri, 19 Jul 2013 17:39:05 +0200 Subject: [PATCH 3/5] Revert changes in mainwindow.ui file --- resources/forms/mainwindow.ui | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/resources/forms/mainwindow.ui b/resources/forms/mainwindow.ui index 60595864e..2b422d930 100644 --- a/resources/forms/mainwindow.ui +++ b/resources/forms/mainwindow.ui @@ -38,12 +38,6 @@ Qt::Horizontal - - - 150 - 0 - - 0 @@ -84,12 +78,6 @@ - - - 150 - 0 - - 0 From 4894ad6dc24016345930fed911f8c65bf0f5b149 Mon Sep 17 00:00:00 2001 From: "s.mehrbrodt@gmail.com" Date: Fri, 19 Jul 2013 18:52:16 +0200 Subject: [PATCH 4/5] Improve message when an invalid order was entered It mentions that the delimiter has to be a space. Fixes: https://launchpad.net/bugs/1094809 --- openlp/plugins/songs/forms/editsongform.py | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/openlp/plugins/songs/forms/editsongform.py b/openlp/plugins/songs/forms/editsongform.py index 24d0d3024..b86606e1c 100644 --- a/openlp/plugins/songs/forms/editsongform.py +++ b/openlp/plugins/songs/forms/editsongform.py @@ -170,14 +170,17 @@ class EditSongForm(QtGui.QDialog, Ui_EditSongDialog): invalid_verses.append(order_names[count]) if invalid_verses: valid = create_separated_list(verse_names) + invalid = u', '.join(invalid_verses) if len(invalid_verses) > 1 else invalid_verses[0] if len(invalid_verses) > 1: - critical_error_message_box(message=translate('SongsPlugin.EditSongForm', - 'The verse order is invalid. There are no verses corresponding to %s. Valid entries are %s.') % - (u', '.join(invalid_verses), valid)) + msg = translate('SongsPlugin.EditSongForm', 'There are no verses corresponding to "%(invalid)s".\ +Valid entries are %(valid)s.\nPlease enter the verses seperated by spaces.') %{'invalid' : u', '.join(invalid_verses), + 'valid' : valid} else: - critical_error_message_box(message=translate('SongsPlugin.EditSongForm', - 'The verse order is invalid. There is no verse corresponding to %s. Valid entries are %s.') % - (invalid_verses[0], valid)) + msg = translate('SongsPlugin.EditSongForm', 'There is no verse corresponding to "%(invalid)s".\ +Valid entries are %(valid)s.\nPlease enter the verses seperated by spaces.') %{'invalid' : invalid_verses[0], + 'valid' : valid} + critical_error_message_box(title=translate('SongsPlugin.EditSongForm', 'Invalid Verse Order'), + message=msg) return len(invalid_verses) == 0 def _validate_song(self): From a52ffdb48348fbb018cc4b4d1ea84f2eaf8b0c0d Mon Sep 17 00:00:00 2001 From: "s.mehrbrodt@gmail.com" Date: Mon, 22 Jul 2013 22:27:51 +0200 Subject: [PATCH 5/5] Fix indentation --- openlp/plugins/songs/forms/editsongform.py | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/openlp/plugins/songs/forms/editsongform.py b/openlp/plugins/songs/forms/editsongform.py index b86606e1c..9492eba44 100644 --- a/openlp/plugins/songs/forms/editsongform.py +++ b/openlp/plugins/songs/forms/editsongform.py @@ -170,15 +170,14 @@ class EditSongForm(QtGui.QDialog, Ui_EditSongDialog): invalid_verses.append(order_names[count]) if invalid_verses: valid = create_separated_list(verse_names) - invalid = u', '.join(invalid_verses) if len(invalid_verses) > 1 else invalid_verses[0] if len(invalid_verses) > 1: - msg = translate('SongsPlugin.EditSongForm', 'There are no verses corresponding to "%(invalid)s".\ -Valid entries are %(valid)s.\nPlease enter the verses seperated by spaces.') %{'invalid' : u', '.join(invalid_verses), - 'valid' : valid} + msg = translate('SongsPlugin.EditSongForm', 'There are no verses corresponding to "%(invalid)s".' + 'Valid entries are %(valid)s.\nPlease enter the verses seperated by spaces.') \ + % {'invalid' : u', '.join(invalid_verses), 'valid' : valid} else: - msg = translate('SongsPlugin.EditSongForm', 'There is no verse corresponding to "%(invalid)s".\ -Valid entries are %(valid)s.\nPlease enter the verses seperated by spaces.') %{'invalid' : invalid_verses[0], - 'valid' : valid} + msg = translate('SongsPlugin.EditSongForm', 'There is no verse corresponding to "%(invalid)s".' + 'Valid entries are %(valid)s.\nPlease enter the verses seperated by spaces.') \ + % {'invalid' : invalid_verses[0], 'valid' : valid} critical_error_message_box(title=translate('SongsPlugin.EditSongForm', 'Invalid Verse Order'), message=msg) return len(invalid_verses) == 0