forked from openlp/openlp
Additional fixes and tweaks
This commit is contained in:
parent
00a0748423
commit
3b3eab52c5
@ -27,7 +27,7 @@
|
||||
# Temple Place, Suite 330, Boston, MA 02111-1307 USA #
|
||||
###############################################################################
|
||||
|
||||
from PyQt4 import QtGui, QtCore
|
||||
from PyQt4 import QtGui
|
||||
|
||||
from openlp.core.lib import translate
|
||||
from openlp.core.lib.ui import critical_error_message_box
|
||||
|
@ -40,6 +40,7 @@ log = logging.getLogger(__name__)
|
||||
|
||||
VERSE_REGEX = re.compile(r'---\[(.+):\D*(\d*)\D*.*\]---')
|
||||
|
||||
|
||||
class EditVerseForm(QtGui.QDialog, Ui_EditVerseDialog):
|
||||
"""
|
||||
This is the form that is used to edit the verses of the song.
|
||||
|
@ -26,6 +26,9 @@
|
||||
# with this program; if not, write to the Free Software Foundation, Inc., 59 #
|
||||
# Temple Place, Suite 330, Boston, MA 02111-1307 USA #
|
||||
###############################################################################
|
||||
"""
|
||||
The :mod:`~openlp.plugins.songs.lib` module contains a number of library functions and classes used in the Songs plugin.
|
||||
"""
|
||||
import re
|
||||
|
||||
from PyQt4 import QtGui
|
||||
@ -37,8 +40,7 @@ from ui import SongStrings
|
||||
|
||||
WHITESPACE = re.compile(r'[\W_]+', re.UNICODE)
|
||||
APOSTROPHE = re.compile(u'[\'`’ʻ′]', re.UNICODE)
|
||||
PATTERN = re.compile(r"\\([a-z]{1,32})(-?\d{1,10})?[ ]?|\\'"
|
||||
r"([0-9a-f]{2})|\\([^a-z])|([{}])|[\r\n]+|(.)", re.I)
|
||||
PATTERN = re.compile(r"\\([a-z]{1,32})(-?\d{1,10})?[ ]?|\\'([0-9a-f]{2})|\\([^a-z])|([{}])|[\r\n]+|(.)", re.I)
|
||||
# RTF control words which specify a "destination" to be ignored.
|
||||
DESTINATIONS = frozenset((
|
||||
u'aftncn', u'aftnsep', u'aftnsepc', u'annotation', u'atnauthor',
|
||||
@ -622,6 +624,6 @@ def natcmp(a, b):
|
||||
return result
|
||||
return 1
|
||||
|
||||
from xml import OpenLyrics, SongXML
|
||||
from songstab import SongsTab
|
||||
from mediaitem import SongMediaItem
|
||||
from openlp.plugins.songs.lib.xml import OpenLyrics, SongXML
|
||||
from openlp.plugins.songs.lib.songstab import SongsTab
|
||||
from openlp.plugins.songs.lib.mediaitem import SongMediaItem
|
||||
|
@ -97,7 +97,7 @@ class TestAuthorsForm(TestCase):
|
||||
display_name = u'John'
|
||||
|
||||
# WHEN: The display_name_edit's text is set
|
||||
self.form.display_name_edit.setText(display_name)
|
||||
self.form.display_edit.setText(display_name)
|
||||
|
||||
# THEN: The display_name property should have the correct value
|
||||
self.assertEqual(self.form.display_name, display_name, u'The display name property should be correct')
|
||||
@ -113,5 +113,5 @@ class TestAuthorsForm(TestCase):
|
||||
self.form.display_name = display_name
|
||||
|
||||
# THEN: The display_name_edit should have the correct value
|
||||
self.assertEqual(self.form.display_name_edit.text(), display_name, u'The display name should be set correctly')
|
||||
self.assertEqual(self.form.display_edit.text(), display_name, u'The display name should be set correctly')
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user