This commit is contained in:
Tim Bentley 2010-06-11 17:29:43 +01:00
commit 078f7952ca
34 changed files with 89 additions and 3369 deletions

View File

@ -24,7 +24,6 @@
############################################################################### ###############################################################################
import logging import logging
import types
import os import os
from PyQt4 import QtCore, QtGui from PyQt4 import QtCore, QtGui
@ -98,9 +97,9 @@ class MediaManagerItem(QtGui.QWidget):
QtGui.QWidget.__init__(self) QtGui.QWidget.__init__(self)
self.parent = parent self.parent = parent
self.settingsSection = title.lower() self.settingsSection = title.lower()
if type(icon) is QtGui.QIcon: if isinstance(icon, QtGui.QIcon):
self.icon = icon self.icon = icon
elif type(icon) is types.StringType: elif isinstance(icon, basestring):
self.icon.addPixmap(QtGui.QPixmap.fromImage(QtGui.QImage(icon)), self.icon.addPixmap(QtGui.QPixmap.fromImage(QtGui.QImage(icon)),
QtGui.QIcon.Normal, QtGui.QIcon.Off) QtGui.QIcon.Normal, QtGui.QIcon.Off)
else: else:

View File

@ -145,7 +145,7 @@ class Renderer(object):
return split_text return split_text
def pre_render_text(self, text): def pre_render_text(self, text):
metrics = QtGui.QFontMetrics(self.mainFont) metrics = QtGui.QFontMetrics(self.main_font)
#work out line width #work out line width
line_width = self._rect.width() line_width = self._rect.width()
#number of lines on a page - adjust for rounding up. #number of lines on a page - adjust for rounding up.
@ -248,7 +248,7 @@ class Renderer(object):
self.frame = QtGui.QImage(self.bg_frame) self.frame = QtGui.QImage(self.bg_frame)
if self._theme.display_slideTransition: if self._theme.display_slideTransition:
self.frame_opaque = QtGui.QImage(self.bg_frame) self.frame_opaque = QtGui.QImage(self.bg_frame)
x, y = self._correctAlignment(self._rect, bbox) x, y = self._correct_alignment(self._rect, bbox)
bbox = self._render_lines_unaligned(lines, False, (x, y), True) bbox = self._render_lines_unaligned(lines, False, (x, y), True)
if footer_lines: if footer_lines:
bbox = self._render_lines_unaligned(footer_lines, True, bbox = self._render_lines_unaligned(footer_lines, True,
@ -304,15 +304,15 @@ class Renderer(object):
gradient.setColorAt(1, gradient.setColorAt(1,
QtGui.QColor(self._theme.background_endColor)) QtGui.QColor(self._theme.background_endColor))
painter.setBrush(QtGui.QBrush(gradient)) painter.setBrush(QtGui.QBrush(gradient))
rectPath = QtGui.QPainterPath() rect_path = QtGui.QPainterPath()
max_x = self.frame.width() max_x = self.frame.width()
max_y = self.frame.height() max_y = self.frame.height()
rectPath.moveTo(0, 0) rect_path.moveTo(0, 0)
rectPath.lineTo(0, max_y) rect_path.lineTo(0, max_y)
rectPath.lineTo(max_x, max_y) rect_path.lineTo(max_x, max_y)
rectPath.lineTo(max_x, 0) rect_path.lineTo(max_x, 0)
rectPath.closeSubpath() rect_path.closeSubpath()
painter.drawPath(rectPath) painter.drawPath(rect_path)
elif self._theme.background_type == u'image': elif self._theme.background_type == u'image':
# image # image
painter.fillRect(self.frame.rect(), QtCore.Qt.black) painter.fillRect(self.frame.rect(), QtCore.Qt.black)
@ -321,7 +321,7 @@ class Renderer(object):
painter.end() painter.end()
log.debug(u'render background End') log.debug(u'render background End')
def _correctAlignment(self, rect, bbox): def _correct_alignment(self, rect, bbox):
""" """
Corrects the vertical alignment of text. Corrects the vertical alignment of text.
@ -493,19 +493,19 @@ class Renderer(object):
if self._theme.font_footer_weight == u'Bold': if self._theme.font_footer_weight == u'Bold':
footer_weight = 75 footer_weight = 75
#TODO Add myfont.setPixelSize((screen_height / 100) * font_size) #TODO Add myfont.setPixelSize((screen_height / 100) * font_size)
self.footerFont = QtGui.QFont(self._theme.font_footer_name, self.footer_font = QtGui.QFont(self._theme.font_footer_name,
self._theme.font_footer_proportion, # size self._theme.font_footer_proportion, # size
footer_weight, # weight footer_weight, # weight
self._theme.font_footer_italics) # italic self._theme.font_footer_italics) # italic
self.footerFont.setPixelSize(self._theme.font_footer_proportion) self.footer_font.setPixelSize(self._theme.font_footer_proportion)
main_weight = 50 main_weight = 50
if self._theme.font_main_weight == u'Bold': if self._theme.font_main_weight == u'Bold':
main_weight = 75 main_weight = 75
self.mainFont = QtGui.QFont(self._theme.font_main_name, self.main_font = QtGui.QFont(self._theme.font_main_name,
self._theme.font_main_proportion, # size self._theme.font_main_proportion, # size
main_weight, # weight main_weight, # weight
self._theme.font_main_italics)# italic self._theme.font_main_italics)# italic
self.mainFont.setPixelSize(self._theme.font_main_proportion) self.main_font.setPixelSize(self._theme.font_main_proportion)
def _get_extent_and_render(self, line, footer, tlcorner=(0, 0), draw=False, def _get_extent_and_render(self, line, footer, tlcorner=(0, 0), draw=False,
color=None, outline_size=0): color=None, outline_size=0):
@ -530,10 +530,10 @@ class Renderer(object):
Defaults to *None*. The colour to draw with. Defaults to *None*. The colour to draw with.
""" """
# setup defaults # setup defaults
if footer : if footer:
font = self.footerFont font = self.footer_font
else: else:
font = self.mainFont font = self.main_font
metrics = QtGui.QFontMetrics(font) metrics = QtGui.QFontMetrics(font)
w = metrics.width(line) w = metrics.width(line)
if footer: if footer:
@ -576,7 +576,7 @@ class Renderer(object):
self.painter2.drawText(x, rowpos, line) self.painter2.drawText(x, rowpos, line)
return (w, h) return (w, h)
def snoop_Image(self, image, image2=None): def snoop_image(self, image, image2=None):
""" """
Debugging method to allow images to be viewed. Debugging method to allow images to be viewed.

View File

@ -25,7 +25,6 @@
import os import os
import sys import sys
from types import StringType, NoneType, UnicodeType
from xml.etree.ElementTree import ElementTree, XML from xml.etree.ElementTree import ElementTree, XML
@ -56,11 +55,9 @@ class XmlRootClass(object):
for element in xml_iter: for element in xml_iter:
if element.tag != root_tag: if element.tag != root_tag:
text = element.text text = element.text
if type(text) is NoneType: if text is None:
val = text val = text
elif type(text) is UnicodeType : elif isinstance(text, basestring):
val = text
elif type(text) is StringType:
# Strings need special handling to sort the colours out # Strings need special handling to sort the colours out
if text[0] == u'$': if text[0] == u'$':
# This might be a hex number, let's try to convert it. # This might be a hex number, let's try to convert it.

View File

@ -23,8 +23,6 @@
# Temple Place, Suite 330, Boston, MA 02111-1307 USA # # Temple Place, Suite 330, Boston, MA 02111-1307 USA #
############################################################################### ###############################################################################
import types
from xml.etree.ElementTree import ElementTree, XML from xml.etree.ElementTree import ElementTree, XML
from PyQt4 import QtGui from PyQt4 import QtGui
@ -121,8 +119,7 @@ class Theme(object):
if element_text is None: if element_text is None:
val = element_text val = element_text
# strings need special handling to sort the colours out # strings need special handling to sort the colours out
if type(element_text) is types.StringType or \ if isinstance(element_text, basestring):
type(element_text) is types.UnicodeType:
if element_text[0] == u'$': # might be a hex number if element_text[0] == u'$': # might be a hex number
try: try:
val = int(element_text[1:], 16) val = int(element_text[1:], 16)

View File

@ -408,7 +408,7 @@ class AmendThemeForm(QtGui.QDialog, Ui_AmendThemeDialog):
def setBackground(self, background, gradient): def setBackground(self, background, gradient):
if background == 0: # Solid if background == 0: # Solid
self.theme.background_type = u'solid' self.theme.background_type = u'solid'
if self.theme.background_color is None : if self.theme.background_color is None:
self.theme.background_color = u'#000000' self.theme.background_color = u'#000000'
self.ImageLineEdit.setText(u'') self.ImageLineEdit.setText(u'')
elif background == 1: # Gradient elif background == 1: # Gradient
@ -419,9 +419,9 @@ class AmendThemeForm(QtGui.QDialog, Ui_AmendThemeDialog):
self.theme.background_direction = u'vertical' self.theme.background_direction = u'vertical'
else: else:
self.theme.background_direction = u'circular' self.theme.background_direction = u'circular'
if self.theme.background_startColor is None : if self.theme.background_startColor is None:
self.theme.background_startColor = u'#000000' self.theme.background_startColor = u'#000000'
if self.theme.background_endColor is None : if self.theme.background_endColor is None:
self.theme.background_endColor = u'#ff0000' self.theme.background_endColor = u'#ff0000'
self.ImageLineEdit.setText(u'') self.ImageLineEdit.setText(u'')
else: else:

View File

@ -74,7 +74,7 @@ class DisplayWidget(QtGui.QWidget):
QtCore.Qt.Key_Backspace: 'slidecontroller_live_previous_noloop'} QtCore.Qt.Key_Backspace: 'slidecontroller_live_previous_noloop'}
def keyPressEvent(self, event): def keyPressEvent(self, event):
if type(event) == QtGui.QKeyEvent: if isinstance(event, QtGui.QKeyEvent):
#here accept the event and do something #here accept the event and do something
if event.key() == QtCore.Qt.Key_Up: if event.key() == QtCore.Qt.Key_Up:
Receiver.send_message(u'slidecontroller_live_previous') Receiver.send_message(u'slidecontroller_live_previous')
@ -375,7 +375,7 @@ class VideoDisplay(Phonon.VideoWidget):
self.setVisible(False) self.setVisible(False)
def keyPressEvent(self, event): def keyPressEvent(self, event):
if type(event) == QtGui.QKeyEvent: if isinstance(event, QtGui.QKeyEvent):
#here accept the event and do something #here accept the event and do something
if event.key() == QtCore.Qt.Key_Escape: if event.key() == QtCore.Qt.Key_Escape:
self.onMediaStop() self.onMediaStop()

View File

@ -44,7 +44,7 @@ class ServiceManagerList(QtGui.QTreeWidget):
self.parent = parent self.parent = parent
def keyPressEvent(self, event): def keyPressEvent(self, event):
if type(event) == QtGui.QKeyEvent: if isinstance(event, QtGui.QKeyEvent):
#here accept the event and do something #here accept the event and do something
if event.key() == QtCore.Qt.Key_Enter: if event.key() == QtCore.Qt.Key_Enter:
self.parent.makeLive() self.parent.makeLive()
@ -918,7 +918,7 @@ class ServiceManager(QtGui.QWidget):
else: else:
#we are not over anything so drop #we are not over anything so drop
replace = False replace = False
if item == None: if item is None:
self.droppos = len(self.serviceItems) self.droppos = len(self.serviceItems)
else: else:
#we are over somthing so lets investigate #we are over somthing so lets investigate

View File

@ -70,7 +70,7 @@ class SlideList(QtGui.QTableWidget):
QtCore.Qt.Key_Backspace: 'slidecontroller_live_previous_noloop'} QtCore.Qt.Key_Backspace: 'slidecontroller_live_previous_noloop'}
def keyPressEvent(self, event): def keyPressEvent(self, event):
if type(event) == QtGui.QKeyEvent: if isinstance(event, QtGui.QKeyEvent):
#here accept the event and do something #here accept the event and do something
if event.key() == QtCore.Qt.Key_Up: if event.key() == QtCore.Qt.Key_Up:
self.parent.onSlideSelectedPrevious() self.parent.onSlideSelectedPrevious()

View File

@ -197,12 +197,12 @@ class ThemeManager(QtGui.QWidget):
u'Theme %s is use in %s plugin' % (theme, u'Theme %s is use in %s plugin' % (theme,
plugin.name))) plugin.name)))
return return
if unicode(self.parent.ServiceManagerContents.ThemeComboBox.currentText()) == theme: if unicode(self.parent.ServiceManagerContents.ThemeComboBox \
QtGui.QMessageBox.critical( .currentText()) == theme:
self, translate(u'ThemeManager',u'Error'), QtGui.QMessageBox.critical(self,
translate(u'ThemeManager', u'Error'),
translate(u'ThemeManager', translate(u'ThemeManager',
u'Theme %s is use by Service Manager' % theme), u'Theme %s is use by Service Manager' % theme))
QtGui.QMessageBox.StandardButtons(QtGui.QMessageBox.Ok))
return return
self.themelist.remove(theme) self.themelist.remove(theme)
th = theme + u'.png' th = theme + u'.png'
@ -228,8 +228,7 @@ class ThemeManager(QtGui.QWidget):
if item is None: if item is None:
QtGui.QMessageBox.critical(self, QtGui.QMessageBox.critical(self,
translate(u'ThemeManager', u'Error'), translate(u'ThemeManager', u'Error'),
translate(u'ThemeManager', u'You have not selected a theme.'), translate(u'ThemeManager', u'You have not selected a theme.'))
QtGui.QMessageBox.StandardButtons(QtGui.QMessageBox.Ok))
return return
theme = unicode(item.data(QtCore.Qt.UserRole).toString()) theme = unicode(item.data(QtCore.Qt.UserRole).toString())
path = QtGui.QFileDialog.getExistingDirectory(self, path = QtGui.QFileDialog.getExistingDirectory(self,
@ -243,13 +242,21 @@ class ThemeManager(QtGui.QWidget):
try: try:
zip = zipfile.ZipFile(themePath, u'w') zip = zipfile.ZipFile(themePath, u'w')
source = os.path.join(self.path, theme) source = os.path.join(self.path, theme)
for files in os.walk(source)[2]: for files in os.walk(source):
for name in files: for name in files[2]:
zip.write( zip.write(
os.path.join(source, name), os.path.join(source, name),
os.path.join(theme, name)) os.path.join(theme, name))
QtGui.QMessageBox.information(self,
translate(u'ThemeManager', u'Theme Exported'),
translate(u'ThemeManager',
u'Your theme has been successfully exported.'))
except (IOError, OSError): except (IOError, OSError):
log.exception(u'Export Theme Failed') log.exception(u'Export Theme Failed')
QtGui.QMessageBox.critical(self,
translate(u'ThemeManager', u'Theme Export Failed'),
translate(u'ThemeManager',
u'Your theme could not be exported due to an error.'))
finally: finally:
if zip: if zip:
zip.close() zip.close()
@ -359,8 +366,7 @@ class ThemeManager(QtGui.QWidget):
if os.path.splitext(file)[1].lower() in [u'.xml']: if os.path.splitext(file)[1].lower() in [u'.xml']:
if self.checkVersion1(xml_data): if self.checkVersion1(xml_data):
# upgrade theme xml # upgrade theme xml
filexml = self.migrateVersion122(filename, filexml = self.migrateVersion122(xml_data)
fullpath, xml_data)
else: else:
filexml = xml_data filexml = xml_data
outfile = open(fullpath, u'w') outfile = open(fullpath, u'w')
@ -392,13 +398,12 @@ class ThemeManager(QtGui.QWidget):
else: else:
return True return True
def migrateVersion122(self, filename, fullpath, xml_data): def migrateVersion122(self, xml_data):
""" """
Called by convert the xml data from version 1 format Called by convert the xml data from version 1 format
to the current format. to the current format.
New fields are defaulted but the new theme is useable New fields are defaulted but the new theme is useable
""" """
log.debug(u'migrateVersion122 %s %s', filename, fullpath)
theme = Theme(xml_data) theme = Theme(xml_data)
newtheme = ThemeXML() newtheme = ThemeXML()
newtheme.new_document(theme.Name) newtheme.new_document(theme.Name)
@ -438,7 +443,7 @@ class ThemeManager(QtGui.QWidget):
return newtheme.extract_xml() return newtheme.extract_xml()
def saveTheme(self, name, theme_xml, theme_pretty_xml, image_from, def saveTheme(self, name, theme_xml, theme_pretty_xml, image_from,
image_to) : image_to):
""" """
Called by thememaintenance Dialog to save the theme Called by thememaintenance Dialog to save the theme
and to trigger the reload of the theme list and to trigger the reload of the theme list

View File

@ -27,6 +27,7 @@ import logging
import os import os
from PyQt4 import QtCore, QtGui from PyQt4 import QtCore, QtGui
from openlp.core.utils import AppLocation from openlp.core.utils import AppLocation
from openlp.core.lib import translate from openlp.core.lib import translate
@ -41,7 +42,7 @@ class LanguageManager(object):
@staticmethod @staticmethod
def get_translator(language): def get_translator(language):
if LanguageManager.AutoLanguage : if LanguageManager.AutoLanguage:
language = QtCore.QLocale.system().name() language = QtCore.QLocale.system().name()
lang_Path = AppLocation.get_directory(AppLocation.AppDir) lang_Path = AppLocation.get_directory(AppLocation.AppDir)
lang_Path = os.path.join(lang_Path, u'resources', u'i18n') lang_Path = os.path.join(lang_Path, u'resources', u'i18n')
@ -81,7 +82,7 @@ class LanguageManager(object):
def set_language(action): def set_language(action):
actionName = u'%s' % action.objectName() actionName = u'%s' % action.objectName()
qmList = LanguageManager.get_qm_list() qmList = LanguageManager.get_qm_list()
if LanguageManager.AutoLanguage : if LanguageManager.AutoLanguage:
language = u'[%s]' % qmList[actionName] language = u'[%s]' % qmList[actionName]
else: else:
language = u'%s' % qmList[actionName] language = u'%s' % qmList[actionName]
@ -89,9 +90,9 @@ class LanguageManager(object):
u'general/language', QtCore.QVariant(language)) u'general/language', QtCore.QVariant(language))
log.info(u'Language file: \'%s\' written to conf file' % language) log.info(u'Language file: \'%s\' written to conf file' % language)
QtGui.QMessageBox.information(None, QtGui.QMessageBox.information(None,
translate(u'LanguageManager', u'Language'), translate(u'LanguageManager', u'Language'),
translate(u'LanguageManager', translate(u'LanguageManager',
u'After restart new Language settings will be used.')) u'After restart new Language settings will be used.'))
@staticmethod @staticmethod
def init_qm_list(): def init_qm_list():
@ -106,7 +107,7 @@ class LanguageManager(object):
@staticmethod @staticmethod
def get_qm_list(): def get_qm_list():
if LanguageManager.__qmList__ == None: if LanguageManager.__qmList__ is None:
LanguageManager.init_qm_list() LanguageManager.init_qm_list()
return LanguageManager.__qmList__ return LanguageManager.__qmList__

View File

@ -242,7 +242,7 @@ class BibleCommon(object):
text = text.replace(u''', u'\'') text = text.replace(u''', u'\'')
# Remove some other tags # Remove some other tags
start_tag = text.find(u'<') start_tag = text.find(u'<')
while start_tag > -1 : while start_tag > -1:
end_tag = text.find(u'>', start_tag) end_tag = text.find(u'>', start_tag)
text = text[:start_tag] + text[end_tag + 1:] text = text[:start_tag] + text[end_tag + 1:]
start_tag = text.find(u'<') start_tag = text.find(u'<')
@ -260,10 +260,10 @@ def unescape(text):
""" """
def fixup(markup): def fixup(markup):
text = markup.group(0) text = markup.group(0)
if text[:2] == u'&#': if text.startswith(u'&#'):
# character reference # character reference
try: try:
if text[:3] == u'&#x': if text.startswith(u'&#x'):
return unichr(int(text[3:-1], 16)) return unichr(int(text[3:-1], 16))
else: else:
return unichr(int(text[2:-1])) return unichr(int(text[2:-1]))

View File

@ -56,13 +56,6 @@ class CSVBible(BibleDB):
QtCore.QObject.connect(Receiver.get_receiver(), QtCore.QObject.connect(Receiver.get_receiver(),
QtCore.SIGNAL(u'bibles_stop_import'), self.stop_import) QtCore.SIGNAL(u'bibles_stop_import'), self.stop_import)
def stop_import(self):
"""
Stops the import of the Bible.
"""
log.debug('Stopping import!')
self.stop_import_flag = True
def do_import(self): def do_import(self):
#Populate the Tables #Populate the Tables
success = True success = True

View File

@ -92,6 +92,13 @@ class BibleDB(QtCore.QObject):
if u'file' in kwargs: if u'file' in kwargs:
self.get_name() self.get_name()
def stop_import(self):
"""
Stops the import of the Bible.
"""
log.debug('Stopping import')
self.stop_import_flag = True
def get_name(self): def get_name(self):
""" """
Returns the version name of the Bible. Returns the version name of the Bible.

View File

@ -184,7 +184,7 @@ class BGExtract(BibleCommon):
log.debug(u'init %s', proxyurl) log.debug(u'init %s', proxyurl)
self.proxyurl = proxyurl self.proxyurl = proxyurl
def get_bible_chapter(self, version, bookname, chapter) : def get_bible_chapter(self, version, bookname, chapter):
""" """
Access and decode bibles via the BibleGateway website Access and decode bibles via the BibleGateway website

View File

@ -51,13 +51,6 @@ class OpenSongBible(BibleDB):
QtCore.QObject.connect(Receiver.get_receiver(), QtCore.QObject.connect(Receiver.get_receiver(),
QtCore.SIGNAL(u'bibles_stop_import'), self.stop_import) QtCore.SIGNAL(u'bibles_stop_import'), self.stop_import)
def stop_import(self):
"""
Stops the import of the Bible.
"""
log.debug('Stopping import!')
self.stop_import_flag = True
def do_import(self): def do_import(self):
""" """
Loads a Bible from file. Loads a Bible from file.

View File

@ -86,13 +86,6 @@ class OSISBible(BibleDB):
QtCore.QObject.connect(Receiver.get_receiver(), QtCore.QObject.connect(Receiver.get_receiver(),
QtCore.SIGNAL(u'bibles_stop_import'), self.stop_import) QtCore.SIGNAL(u'bibles_stop_import'), self.stop_import)
def stop_import(self):
"""
Stops the import of the Bible.
"""
log.debug('Stopping import!')
self.stop_import_flag = True
def do_import(self): def do_import(self):
""" """
Loads a Bible from file. Loads a Bible from file.

View File

@ -370,21 +370,6 @@ class ImpressDocument(PresentationDocument):
""" """
self.control.gotoPreviousSlide() self.control.gotoPreviousSlide()
def get_slide_preview_file(self, slide_no):
"""
Returns an image path containing a preview for the
requested slide
``slide_no``
The slide an image is required for, starting at 1
"""
path = os.path.join(self.thumbnailpath,
self.controller.thumbnailprefix + unicode(slide_no) + u'.png')
if os.path.isfile(path):
return path
else:
return None
def get_slide_text(self, slide_no): def get_slide_text(self, slide_no):
""" """
Returns the text on the slide Returns the text on the slide

View File

@ -269,20 +269,6 @@ class PowerpointDocument(PresentationDocument):
""" """
self.presentation.SlideShowWindow.View.Previous() self.presentation.SlideShowWindow.View.Previous()
def get_slide_preview_file(self, slide_no):
"""
Returns an image path containing a preview for the requested slide
``slide_no``
The slide an image is required for, starting at 1
"""
path = os.path.join(self.thumbnailpath,
self.controller.thumbnailprefix + unicode(slide_no) + u'.png')
if os.path.isfile(path):
return path
else:
return None
def get_slide_text(self, slide_no): def get_slide_text(self, slide_no):
""" """
Returns the text on the slide Returns the text on the slide

View File

@ -357,7 +357,12 @@ class PresentationDocument(object):
``slide_no`` ``slide_no``
The slide an image is required for, starting at 1 The slide an image is required for, starting at 1
""" """
return None path = os.path.join(self.thumbnailpath,
self.controller.thumbnailprefix + unicode(slide_no) + u'.png')
if os.path.isfile(path):
return path
else:
return None
def poll_slidenumber(self, is_live): def poll_slidenumber(self, is_live):
""" """

View File

@ -81,10 +81,4 @@ from songbookform import SongBookForm
from editverseform import EditVerseForm from editverseform import EditVerseForm
from editsongform import EditSongForm from editsongform import EditSongForm
from songmaintenanceform import SongMaintenanceForm from songmaintenanceform import SongMaintenanceForm
#from openlpexportform import OpenLPExportForm
#from openlpimportform import OpenLPImportForm
#from opensongexportform import OpenSongExportForm
#from opensongimportform import OpenSongImportForm
from songimportform import ImportWizardForm from songimportform import ImportWizardForm

View File

@ -1,326 +0,0 @@
# -*- coding: utf-8 -*-
# vim: autoindent shiftwidth=4 expandtab textwidth=80 tabstop=4 softtabstop=4
###############################################################################
# OpenLP - Open Source Lyrics Projection #
# --------------------------------------------------------------------------- #
# Copyright (c) 2008-2010 Raoul Snyman #
# Portions copyright (c) 2008-2010 Tim Bentley, Jonathan Corwin, Michael #
# Gorven, Scott Guerrieri, Christian Richter, Maikel Stuivenberg, Martin #
# Thompson, Jon Tibble, Carsten Tinggaard #
# --------------------------------------------------------------------------- #
# This program is free software; you can redistribute it and/or modify it #
# under the terms of the GNU General Public License as published by the Free #
# Software Foundation; version 2 of the License. #
# #
# This program is distributed in the hope that it will be useful, but WITHOUT #
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or #
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for #
# more details. #
# #
# You should have received a copy of the GNU General Public License along #
# with this program; if not, write to the Free Software Foundation, Inc., 59 #
# Temple Place, Suite 330, Boston, MA 02111-1307 USA #
###############################################################################
from PyQt4 import QtCore, QtGui
from openlp.core.lib import translate
class Ui_OpenLPExportDialog(object):
def setupUi(self, OpenLPExportDialog):
OpenLPExportDialog.setObjectName(u'OpenLPExportDialog')
OpenLPExportDialog.resize(473, 459)
icon = QtGui.QIcon()
icon.addPixmap(QtGui.QPixmap(u':/icon/openlp.org-icon-32.bmp'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
OpenLPExportDialog.setWindowIcon(icon)
self.verticalLayout_5 = QtGui.QVBoxLayout(OpenLPExportDialog)
self.verticalLayout_5.setMargin(8)
self.verticalLayout_5.setObjectName(u'verticalLayout_5')
self.ExportFileWidget = QtGui.QWidget(OpenLPExportDialog)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.ExportFileWidget.sizePolicy().hasHeightForWidth())
self.ExportFileWidget.setSizePolicy(sizePolicy)
self.ExportFileWidget.setObjectName(u'ExportFileWidget')
self.horizontalLayout = QtGui.QHBoxLayout(self.ExportFileWidget)
self.horizontalLayout.setSpacing(3)
self.horizontalLayout.setMargin(0)
self.horizontalLayout.setObjectName(u'horizontalLayout')
self.ExportFileLabel = QtGui.QLabel(self.ExportFileWidget)
self.ExportFileLabel.setObjectName(u'ExportFileLabel')
self.horizontalLayout.addWidget(self.ExportFileLabel)
self.ExportFileLineEdit = QtGui.QLineEdit(self.ExportFileWidget)
self.ExportFileLineEdit.setObjectName(u'ExportFileLineEdit')
self.horizontalLayout.addWidget(self.ExportFileLineEdit)
self.ExportFileSelectPushButton = QtGui.QPushButton(self.ExportFileWidget)
icon1 = QtGui.QIcon()
icon1.addPixmap(QtGui.QPixmap(u':/general/general_load.png'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.ExportFileSelectPushButton.setIcon(icon1)
self.ExportFileSelectPushButton.setObjectName(u'ExportFileSelectPushButton')
self.horizontalLayout.addWidget(self.ExportFileSelectPushButton)
self.verticalLayout_5.addWidget(self.ExportFileWidget)
self.SongListFrame = QtGui.QFrame(OpenLPExportDialog)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Expanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.SongListFrame.sizePolicy().hasHeightForWidth())
self.SongListFrame.setSizePolicy(sizePolicy)
self.SongListFrame.setFrameShape(QtGui.QFrame.Box)
self.SongListFrame.setFrameShadow(QtGui.QFrame.Raised)
self.SongListFrame.setObjectName(u'SongListFrame')
self.horizontalLayout_6 = QtGui.QHBoxLayout(self.SongListFrame)
self.horizontalLayout_6.setSpacing(8)
self.horizontalLayout_6.setMargin(8)
self.horizontalLayout_6.setObjectName(u'horizontalLayout_6')
self.ExportFileSongListWidget = QtGui.QWidget(self.SongListFrame)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Expanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.ExportFileSongListWidget.sizePolicy().hasHeightForWidth())
self.ExportFileSongListWidget.setSizePolicy(sizePolicy)
self.ExportFileSongListWidget.setObjectName(u'ExportFileSongListWidget')
self.verticalLayout = QtGui.QVBoxLayout(self.ExportFileSongListWidget)
self.verticalLayout.setSpacing(6)
self.verticalLayout.setMargin(0)
self.verticalLayout.setObjectName(u'verticalLayout')
self.ExportListLabel = QtGui.QLabel(self.ExportFileSongListWidget)
self.ExportListLabel.setObjectName(u'ExportListLabel')
self.verticalLayout.addWidget(self.ExportListLabel)
self.ExportListTable = QtGui.QTableWidget(self.ExportFileSongListWidget)
self.ExportListTable.setSelectionMode(QtGui.QAbstractItemView.MultiSelection)
self.ExportListTable.setShowGrid(False)
self.ExportListTable.setWordWrap(False)
self.ExportListTable.setCornerButtonEnabled(False)
self.ExportListTable.setObjectName(u'ExportListTable')
self.ExportListTable.setColumnCount(2)
self.ExportListTable.setRowCount(0)
item = QtGui.QTableWidgetItem()
self.ExportListTable.setHorizontalHeaderItem(0, item)
item = QtGui.QTableWidgetItem()
self.ExportListTable.setHorizontalHeaderItem(1, item)
self.verticalLayout.addWidget(self.ExportListTable)
self.ExportSelectAllWidget = QtGui.QWidget(self.ExportFileSongListWidget)
self.ExportSelectAllWidget.setObjectName(u'ExportSelectAllWidget')
self.horizontalLayout_2 = QtGui.QHBoxLayout(self.ExportSelectAllWidget)
self.horizontalLayout_2.setSpacing(6)
self.horizontalLayout_2.setMargin(0)
self.horizontalLayout_2.setObjectName(u'horizontalLayout_2')
self.ExportSelectAllPushButton = QtGui.QPushButton(self.ExportSelectAllWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.ExportSelectAllPushButton.sizePolicy().hasHeightForWidth())
self.ExportSelectAllPushButton.setSizePolicy(sizePolicy)
self.ExportSelectAllPushButton.setMinimumSize(QtCore.QSize(100, 0))
icon2 = QtGui.QIcon()
icon2.addPixmap(QtGui.QPixmap(u':/exports/export_selectall.png'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.ExportSelectAllPushButton.setIcon(icon2)
self.ExportSelectAllPushButton.setObjectName(u'ExportSelectAllPushButton')
self.horizontalLayout_2.addWidget(self.ExportSelectAllPushButton)
spacerItem = QtGui.QSpacerItem(89, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.horizontalLayout_2.addItem(spacerItem)
self.verticalLayout.addWidget(self.ExportSelectAllWidget)
self.exportFilterWidget = QtGui.QWidget(self.ExportFileSongListWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.exportFilterWidget.sizePolicy().hasHeightForWidth())
self.exportFilterWidget.setSizePolicy(sizePolicy)
self.exportFilterWidget.setMinimumSize(QtCore.QSize(0, 0))
self.exportFilterWidget.setObjectName(u'exportFilterWidget')
self.horizontalLayout_3 = QtGui.QHBoxLayout(self.exportFilterWidget)
self.horizontalLayout_3.setMargin(0)
self.horizontalLayout_3.setObjectName(u'horizontalLayout_3')
self.ExportFilterComboBox = QtGui.QComboBox(self.exportFilterWidget)
self.ExportFilterComboBox.setMinimumSize(QtCore.QSize(70, 0))
self.ExportFilterComboBox.setObjectName(u'ExportFilterComboBox')
self.ExportFilterComboBox.addItem(QtCore.QString())
self.ExportFilterComboBox.addItem(QtCore.QString())
self.ExportFilterComboBox.addItem(QtCore.QString())
self.horizontalLayout_3.addWidget(self.ExportFilterComboBox)
self.ExportFilterLineEdit = QtGui.QLineEdit(self.exportFilterWidget)
self.ExportFilterLineEdit.setObjectName(u'ExportFilterLineEdit')
self.horizontalLayout_3.addWidget(self.ExportFilterLineEdit)
self.verticalLayout.addWidget(self.exportFilterWidget)
self.horizontalLayout_6.addWidget(self.ExportFileSongListWidget)
self.AddSelectedWidget = QtGui.QWidget(self.SongListFrame)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Expanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.AddSelectedWidget.sizePolicy().hasHeightForWidth())
self.AddSelectedWidget.setSizePolicy(sizePolicy)
self.AddSelectedWidget.setObjectName(u'AddSelectedWidget')
self.verticalLayout_3 = QtGui.QVBoxLayout(self.AddSelectedWidget)
self.verticalLayout_3.setMargin(0)
self.verticalLayout_3.setObjectName(u'verticalLayout_3')
spacerItem1 = QtGui.QSpacerItem(20, 40, QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Expanding)
self.verticalLayout_3.addItem(spacerItem1)
self.AddSelectedPushButton = QtGui.QPushButton(self.AddSelectedWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Minimum)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.AddSelectedPushButton.sizePolicy().hasHeightForWidth())
self.AddSelectedPushButton.setSizePolicy(sizePolicy)
self.AddSelectedPushButton.setMinimumSize(QtCore.QSize(25, 25))
icon3 = QtGui.QIcon()
icon3.addPixmap(QtGui.QPixmap(u':/exports/export_move_to_list.png'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.AddSelectedPushButton.setIcon(icon3)
self.AddSelectedPushButton.setObjectName(u'AddSelectedPushButton')
self.verticalLayout_3.addWidget(self.AddSelectedPushButton)
spacerItem2 = QtGui.QSpacerItem(20, 40, QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Expanding)
self.verticalLayout_3.addItem(spacerItem2)
self.horizontalLayout_6.addWidget(self.AddSelectedWidget)
self.SelectedFileListWidget = QtGui.QWidget(self.SongListFrame)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Expanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.SelectedFileListWidget.sizePolicy().hasHeightForWidth())
self.SelectedFileListWidget.setSizePolicy(sizePolicy)
self.SelectedFileListWidget.setObjectName(u'SelectedFileListWidget')
self.verticalLayout_2 = QtGui.QVBoxLayout(self.SelectedFileListWidget)
self.verticalLayout_2.setMargin(0)
self.verticalLayout_2.setObjectName(u'verticalLayout_2')
self.SelectedListLabel = QtGui.QLabel(self.SelectedFileListWidget)
self.SelectedListLabel.setObjectName(u'SelectedListLabel')
self.verticalLayout_2.addWidget(self.SelectedListLabel)
self.SelectedListTable = QtGui.QTableWidget(self.SelectedFileListWidget)
self.SelectedListTable.setSelectionMode(QtGui.QAbstractItemView.MultiSelection)
self.SelectedListTable.setShowGrid(False)
self.SelectedListTable.setWordWrap(False)
self.SelectedListTable.setCornerButtonEnabled(False)
self.SelectedListTable.setObjectName(u'SelectedListTable')
self.SelectedListTable.setColumnCount(2)
self.SelectedListTable.setRowCount(0)
item = QtGui.QTableWidgetItem()
self.SelectedListTable.setHorizontalHeaderItem(0, item)
item = QtGui.QTableWidgetItem()
self.SelectedListTable.setHorizontalHeaderItem(1, item)
self.verticalLayout_2.addWidget(self.SelectedListTable)
self.SelectedSelectAllWidget = QtGui.QWidget(self.SelectedFileListWidget)
self.SelectedSelectAllWidget.setObjectName(u'SelectedSelectAllWidget')
self.horizontalLayout_4 = QtGui.QHBoxLayout(self.SelectedSelectAllWidget)
self.horizontalLayout_4.setSpacing(6)
self.horizontalLayout_4.setMargin(0)
self.horizontalLayout_4.setObjectName(u'horizontalLayout_4')
self.SelectedSelectAllPushButton = QtGui.QPushButton(self.SelectedSelectAllWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.SelectedSelectAllPushButton.sizePolicy().hasHeightForWidth())
self.SelectedSelectAllPushButton.setSizePolicy(sizePolicy)
self.SelectedSelectAllPushButton.setMinimumSize(QtCore.QSize(100, 0))
self.SelectedSelectAllPushButton.setIcon(icon2)
self.SelectedSelectAllPushButton.setObjectName(u'SelectedSelectAllPushButton')
self.horizontalLayout_4.addWidget(self.SelectedSelectAllPushButton)
spacerItem3 = QtGui.QSpacerItem(92, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.horizontalLayout_4.addItem(spacerItem3)
self.verticalLayout_2.addWidget(self.SelectedSelectAllWidget)
self.SelectedRemoveSelectedWidget = QtGui.QWidget(self.SelectedFileListWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.SelectedRemoveSelectedWidget.sizePolicy().hasHeightForWidth())
self.SelectedRemoveSelectedWidget.setSizePolicy(sizePolicy)
self.SelectedRemoveSelectedWidget.setObjectName(u'SelectedRemoveSelectedWidget')
self.horizontalLayout_5 = QtGui.QHBoxLayout(self.SelectedRemoveSelectedWidget)
self.horizontalLayout_5.setMargin(0)
self.horizontalLayout_5.setObjectName(u'horizontalLayout_5')
self.SelectedRemoveSelectedButton = QtGui.QPushButton(self.SelectedRemoveSelectedWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.SelectedRemoveSelectedButton.sizePolicy().hasHeightForWidth())
self.SelectedRemoveSelectedButton.setSizePolicy(sizePolicy)
self.SelectedRemoveSelectedButton.setMinimumSize(QtCore.QSize(140, 0))
icon4 = QtGui.QIcon()
icon4.addPixmap(QtGui.QPixmap(u':/exports/export_remove.png'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.SelectedRemoveSelectedButton.setIcon(icon4)
self.SelectedRemoveSelectedButton.setObjectName(u'SelectedRemoveSelectedButton')
self.horizontalLayout_5.addWidget(self.SelectedRemoveSelectedButton)
spacerItem4 = QtGui.QSpacerItem(49, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.horizontalLayout_5.addItem(spacerItem4)
self.verticalLayout_2.addWidget(self.SelectedRemoveSelectedWidget)
self.horizontalLayout_6.addWidget(self.SelectedFileListWidget)
self.verticalLayout_5.addWidget(self.SongListFrame)
self.ProgressGroupBox = QtGui.QGroupBox(OpenLPExportDialog)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.ProgressGroupBox.sizePolicy().hasHeightForWidth())
self.ProgressGroupBox.setSizePolicy(sizePolicy)
self.ProgressGroupBox.setObjectName(u'ProgressGroupBox')
self.verticalLayout_4 = QtGui.QVBoxLayout(self.ProgressGroupBox)
self.verticalLayout_4.setSpacing(8)
self.verticalLayout_4.setContentsMargins(8, 0, 8, 8)
self.verticalLayout_4.setObjectName(u'verticalLayout_4')
self.ProgressLabel = QtGui.QLabel(self.ProgressGroupBox)
self.ProgressLabel.setObjectName(u'ProgressLabel')
self.verticalLayout_4.addWidget(self.ProgressLabel)
self.ProgressBar = QtGui.QProgressBar(self.ProgressGroupBox)
self.ProgressBar.setProperty(u'value', QtCore.QVariant(24))
self.ProgressBar.setObjectName(u'ProgressBar')
self.verticalLayout_4.addWidget(self.ProgressBar)
self.verticalLayout_5.addWidget(self.ProgressGroupBox)
self.ButtonBarWidget = QtGui.QWidget(OpenLPExportDialog)
self.ButtonBarWidget.setObjectName(u'ButtonBarWidget')
self.horizontalLayout_7 = QtGui.QHBoxLayout(self.ButtonBarWidget)
self.horizontalLayout_7.setSpacing(8)
self.horizontalLayout_7.setMargin(0)
self.horizontalLayout_7.setObjectName(u'horizontalLayout_7')
spacerItem5 = QtGui.QSpacerItem(288, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.horizontalLayout_7.addItem(spacerItem5)
self.ExportPushButton = QtGui.QPushButton(self.ButtonBarWidget)
self.ExportPushButton.setObjectName(u'ExportPushButton')
self.horizontalLayout_7.addWidget(self.ExportPushButton)
self.ClosePushButton = QtGui.QPushButton(self.ButtonBarWidget)
self.ClosePushButton.setObjectName(u'ClosePushButton')
self.horizontalLayout_7.addWidget(self.ClosePushButton)
self.verticalLayout_5.addWidget(self.ButtonBarWidget)
self.retranslateUi(OpenLPExportDialog)
QtCore.QObject.connect(self.ClosePushButton, QtCore.SIGNAL(u'clicked()'), OpenLPExportDialog.close)
QtCore.QObject.connect(self.ExportSelectAllPushButton, QtCore.SIGNAL(u'clicked()'), self.ExportListTable.selectAll)
QtCore.QObject.connect(self.SelectedSelectAllPushButton, QtCore.SIGNAL(u'clicked()'), self.SelectedListTable.selectAll)
QtCore.QObject.connect(self.SelectedRemoveSelectedButton, QtCore.SIGNAL(u'clicked()'), self.SelectedListTable.clear)
QtCore.QMetaObject.connectSlotsByName(OpenLPExportDialog)
def retranslateUi(self, OpenLPExportDialog):
OpenLPExportDialog.setWindowTitle(
translate(u'SongsPlugin.OpenLPExportForm',
u'openlp.org Song Exporter'))
self.ExportFileLabel.setText(
translate(u'SongsPlugin.OpenLPExportForm',
u'Select openlp.org export filename:'))
self.ExportListLabel.setText(
translate(u'SongsPlugin.OpenLPExportForm', u'Full Song List'))
self.ExportListTable.horizontalHeaderItem(0).setText(
translate(u'SongsPlugin.OpenLPExportForm', u'Song Title'))
self.ExportListTable.horizontalHeaderItem(1).setText(
translate(u'SongsPlugin.OpenLPExportForm', u'Author'))
self.ExportSelectAllPushButton.setText(
translate(u'SongsPlugin.OpenLPExportForm', u'Select All'))
self.ExportFilterComboBox.setItemText(0,
translate(u'SongsPlugin.OpenLPExportForm', u'Lyrics'))
self.ExportFilterComboBox.setItemText(1,
translate(u'SongsPlugin.OpenLPExportForm', u'Title'))
self.ExportFilterComboBox.setItemText(2,
translate(u'SongsPlugin.OpenLPExportForm', u'Author'))
self.SelectedListLabel.setText(
translate(u'SongsPlugin.OpenLPExportForm', u'Song Export List'))
self.SelectedListTable.horizontalHeaderItem(0).setText(
translate(u'SongsPlugin.OpenLPExportForm', u'Song Title'))
self.SelectedListTable.horizontalHeaderItem(1).setText(
translate(u'SongsPlugin.OpenLPExportForm', u'Author'))
self.SelectedSelectAllPushButton.setText(
translate(u'SongsPlugin.OpenLPExportForm', u'Select All'))
self.SelectedRemoveSelectedButton.setText(
translate(u'SongsPlugin.OpenLPExportForm', u'Remove Selected'))
self.ProgressGroupBox.setTitle(
translate(u'SongsPlugin.OpenLPExportForm', u'Progress:'))
self.ProgressLabel.setText(
translate(u'SongsPlugin.OpenLPExportForm', u'Ready to export'))
self.ExportPushButton.setText(
translate(u'SongsPlugin.OpenLPExportForm', u'Export'))
self.ClosePushButton.setText(
translate(u'SongsPlugin.OpenLPExportForm', u'Close'))

View File

@ -1,34 +0,0 @@
# -*- coding: utf-8 -*-
# vim: autoindent shiftwidth=4 expandtab textwidth=80 tabstop=4 softtabstop=4
###############################################################################
# OpenLP - Open Source Lyrics Projection #
# --------------------------------------------------------------------------- #
# Copyright (c) 2008-2010 Raoul Snyman #
# Portions copyright (c) 2008-2010 Tim Bentley, Jonathan Corwin, Michael #
# Gorven, Scott Guerrieri, Christian Richter, Maikel Stuivenberg, Martin #
# Thompson, Jon Tibble, Carsten Tinggaard #
# --------------------------------------------------------------------------- #
# This program is free software; you can redistribute it and/or modify it #
# under the terms of the GNU General Public License as published by the Free #
# Software Foundation; version 2 of the License. #
# #
# This program is distributed in the hope that it will be useful, but WITHOUT #
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or #
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for #
# more details. #
# #
# You should have received a copy of the GNU General Public License along #
# with this program; if not, write to the Free Software Foundation, Inc., 59 #
# Temple Place, Suite 330, Boston, MA 02111-1307 USA #
###############################################################################
from PyQt4 import QtGui
from openlp.plugins.songs.forms.openlpexportdialog import Ui_OpenLPExportDialog
class OpenLPExportForm(QtGui.QDialog, Ui_OpenLPExportDialog):
def __init__(self, parent=None):
QtGui.QDialog.__init__(self, parent)
self.setupUi(self)

View File

@ -1,327 +0,0 @@
# -*- coding: utf-8 -*-
# vim: autoindent shiftwidth=4 expandtab textwidth=80 tabstop=4 softtabstop=4
###############################################################################
# OpenLP - Open Source Lyrics Projection #
# --------------------------------------------------------------------------- #
# Copyright (c) 2008-2010 Raoul Snyman #
# Portions copyright (c) 2008-2010 Tim Bentley, Jonathan Corwin, Michael #
# Gorven, Scott Guerrieri, Christian Richter, Maikel Stuivenberg, Martin #
# Thompson, Jon Tibble, Carsten Tinggaard #
# --------------------------------------------------------------------------- #
# This program is free software; you can redistribute it and/or modify it #
# under the terms of the GNU General Public License as published by the Free #
# Software Foundation; version 2 of the License. #
# #
# This program is distributed in the hope that it will be useful, but WITHOUT #
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or #
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for #
# more details. #
# #
# You should have received a copy of the GNU General Public License along #
# with this program; if not, write to the Free Software Foundation, Inc., 59 #
# Temple Place, Suite 330, Boston, MA 02111-1307 USA #
###############################################################################
from PyQt4 import QtCore, QtGui
from openlp.core.lib import translate
class Ui_OpenLPImportDialog(object):
def setupUi(self, OpenLPImportDialog):
OpenLPImportDialog.setObjectName(u'OpenLPImportDialog')
OpenLPImportDialog.resize(473, 459)
icon = QtGui.QIcon()
icon.addPixmap(QtGui.QPixmap(u':/icon/openlp.org-icon-32.bmp'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
OpenLPImportDialog.setWindowIcon(icon)
self.verticalLayout_5 = QtGui.QVBoxLayout(OpenLPImportDialog)
self.verticalLayout_5.setMargin(8)
self.verticalLayout_5.setObjectName(u'verticalLayout_5')
self.ImportFileWidget = QtGui.QWidget(OpenLPImportDialog)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.ImportFileWidget.sizePolicy().hasHeightForWidth())
self.ImportFileWidget.setSizePolicy(sizePolicy)
self.ImportFileWidget.setObjectName(u'ImportFileWidget')
self.horizontalLayout = QtGui.QHBoxLayout(self.ImportFileWidget)
self.horizontalLayout.setSpacing(3)
self.horizontalLayout.setMargin(0)
self.horizontalLayout.setObjectName(u'horizontalLayout')
self.ImportFileLabel = QtGui.QLabel(self.ImportFileWidget)
self.ImportFileLabel.setObjectName(u'ImportFileLabel')
self.horizontalLayout.addWidget(self.ImportFileLabel)
self.ImportFileLineEdit = QtGui.QLineEdit(self.ImportFileWidget)
self.ImportFileLineEdit.setObjectName(u'ImportFileLineEdit')
self.horizontalLayout.addWidget(self.ImportFileLineEdit)
self.ImportFileSelectPushButton = QtGui.QPushButton(self.ImportFileWidget)
icon1 = QtGui.QIcon()
icon1.addPixmap(QtGui.QPixmap(u':/imports/import_load.png'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.ImportFileSelectPushButton.setIcon(icon1)
self.ImportFileSelectPushButton.setObjectName(u'ImportFileSelectPushButton')
self.horizontalLayout.addWidget(self.ImportFileSelectPushButton)
self.verticalLayout_5.addWidget(self.ImportFileWidget)
self.SongListFrame = QtGui.QFrame(OpenLPImportDialog)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Expanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.SongListFrame.sizePolicy().hasHeightForWidth())
self.SongListFrame.setSizePolicy(sizePolicy)
self.SongListFrame.setFrameShape(QtGui.QFrame.Box)
self.SongListFrame.setFrameShadow(QtGui.QFrame.Raised)
self.SongListFrame.setObjectName(u'SongListFrame')
self.horizontalLayout_6 = QtGui.QHBoxLayout(self.SongListFrame)
self.horizontalLayout_6.setSpacing(8)
self.horizontalLayout_6.setMargin(8)
self.horizontalLayout_6.setObjectName(u'horizontalLayout_6')
self.ImportFileSongListWidget = QtGui.QWidget(self.SongListFrame)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Expanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.ImportFileSongListWidget.sizePolicy().hasHeightForWidth())
self.ImportFileSongListWidget.setSizePolicy(sizePolicy)
self.ImportFileSongListWidget.setObjectName(u'ImportFileSongListWidget')
self.verticalLayout = QtGui.QVBoxLayout(self.ImportFileSongListWidget)
self.verticalLayout.setSpacing(6)
self.verticalLayout.setMargin(0)
self.verticalLayout.setObjectName(u'verticalLayout')
self.ImportListLabel = QtGui.QLabel(self.ImportFileSongListWidget)
self.ImportListLabel.setObjectName(u'ImportListLabel')
self.verticalLayout.addWidget(self.ImportListLabel)
self.ImportListTable = QtGui.QTableWidget(self.ImportFileSongListWidget)
self.ImportListTable.setSelectionMode(QtGui.QAbstractItemView.MultiSelection)
self.ImportListTable.setShowGrid(False)
self.ImportListTable.setWordWrap(False)
self.ImportListTable.setCornerButtonEnabled(False)
self.ImportListTable.setObjectName(u'ImportListTable')
self.ImportListTable.setColumnCount(2)
self.ImportListTable.setRowCount(0)
item = QtGui.QTableWidgetItem()
self.ImportListTable.setHorizontalHeaderItem(0, item)
item = QtGui.QTableWidgetItem()
self.ImportListTable.setHorizontalHeaderItem(1, item)
self.verticalLayout.addWidget(self.ImportListTable)
self.ImportSelectAllWidget = QtGui.QWidget(self.ImportFileSongListWidget)
self.ImportSelectAllWidget.setObjectName(u'ImportSelectAllWidget')
self.horizontalLayout_2 = QtGui.QHBoxLayout(self.ImportSelectAllWidget)
self.horizontalLayout_2.setSpacing(6)
self.horizontalLayout_2.setMargin(0)
self.horizontalLayout_2.setObjectName(u'horizontalLayout_2')
self.ImportSelectAllPushButton = QtGui.QPushButton(self.ImportSelectAllWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.ImportSelectAllPushButton.sizePolicy().hasHeightForWidth())
self.ImportSelectAllPushButton.setSizePolicy(sizePolicy)
self.ImportSelectAllPushButton.setMinimumSize(QtCore.QSize(100, 0))
icon2 = QtGui.QIcon()
icon2.addPixmap(QtGui.QPixmap(u':/imports/import_selectall.png'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.ImportSelectAllPushButton.setIcon(icon2)
self.ImportSelectAllPushButton.setObjectName(u'ImportSelectAllPushButton')
self.horizontalLayout_2.addWidget(self.ImportSelectAllPushButton)
spacerItem = QtGui.QSpacerItem(89, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.horizontalLayout_2.addItem(spacerItem)
self.verticalLayout.addWidget(self.ImportSelectAllWidget)
self.importFilterWidget = QtGui.QWidget(self.ImportFileSongListWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.importFilterWidget.sizePolicy().hasHeightForWidth())
self.importFilterWidget.setSizePolicy(sizePolicy)
self.importFilterWidget.setMinimumSize(QtCore.QSize(0, 0))
self.importFilterWidget.setObjectName(u'importFilterWidget')
self.horizontalLayout_3 = QtGui.QHBoxLayout(self.importFilterWidget)
self.horizontalLayout_3.setMargin(0)
self.horizontalLayout_3.setObjectName(u'horizontalLayout_3')
self.ImportFilterComboBox = QtGui.QComboBox(self.importFilterWidget)
self.ImportFilterComboBox.setMinimumSize(QtCore.QSize(70, 0))
self.ImportFilterComboBox.setObjectName(u'ImportFilterComboBox')
self.ImportFilterComboBox.addItem(QtCore.QString())
self.ImportFilterComboBox.addItem(QtCore.QString())
self.ImportFilterComboBox.addItem(QtCore.QString())
self.horizontalLayout_3.addWidget(self.ImportFilterComboBox)
self.importFilterLineEdit = QtGui.QLineEdit(self.importFilterWidget)
self.importFilterLineEdit.setObjectName(u'importFilterLineEdit')
self.horizontalLayout_3.addWidget(self.importFilterLineEdit)
self.verticalLayout.addWidget(self.importFilterWidget)
self.horizontalLayout_6.addWidget(self.ImportFileSongListWidget)
self.AddSelectedWidget = QtGui.QWidget(self.SongListFrame)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Expanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.AddSelectedWidget.sizePolicy().hasHeightForWidth())
self.AddSelectedWidget.setSizePolicy(sizePolicy)
self.AddSelectedWidget.setObjectName(u'AddSelectedWidget')
self.verticalLayout_3 = QtGui.QVBoxLayout(self.AddSelectedWidget)
self.verticalLayout_3.setMargin(0)
self.verticalLayout_3.setObjectName(u'verticalLayout_3')
spacerItem1 = QtGui.QSpacerItem(20, 40, QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Expanding)
self.verticalLayout_3.addItem(spacerItem1)
self.AddSelectedPushButton = QtGui.QPushButton(self.AddSelectedWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Minimum)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.AddSelectedPushButton.sizePolicy().hasHeightForWidth())
self.AddSelectedPushButton.setSizePolicy(sizePolicy)
self.AddSelectedPushButton.setMinimumSize(QtCore.QSize(25, 25))
icon3 = QtGui.QIcon()
icon3.addPixmap(QtGui.QPixmap(u':/imports/import_move_to_list.png'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.AddSelectedPushButton.setIcon(icon3)
self.AddSelectedPushButton.setObjectName(u'AddSelectedPushButton')
self.verticalLayout_3.addWidget(self.AddSelectedPushButton)
spacerItem2 = QtGui.QSpacerItem(20, 40, QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Expanding)
self.verticalLayout_3.addItem(spacerItem2)
self.horizontalLayout_6.addWidget(self.AddSelectedWidget)
self.SelectedFileListWidget = QtGui.QWidget(self.SongListFrame)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Expanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.SelectedFileListWidget.sizePolicy().hasHeightForWidth())
self.SelectedFileListWidget.setSizePolicy(sizePolicy)
self.SelectedFileListWidget.setObjectName(u'SelectedFileListWidget')
self.verticalLayout_2 = QtGui.QVBoxLayout(self.SelectedFileListWidget)
self.verticalLayout_2.setMargin(0)
self.verticalLayout_2.setObjectName(u'verticalLayout_2')
self.SelectedListLabel = QtGui.QLabel(self.SelectedFileListWidget)
self.SelectedListLabel.setObjectName(u'SelectedListLabel')
self.verticalLayout_2.addWidget(self.SelectedListLabel)
self.SelectedListTable = QtGui.QTableWidget(self.SelectedFileListWidget)
self.SelectedListTable.setSelectionMode(QtGui.QAbstractItemView.MultiSelection)
self.SelectedListTable.setShowGrid(False)
self.SelectedListTable.setWordWrap(False)
self.SelectedListTable.setCornerButtonEnabled(False)
self.SelectedListTable.setObjectName(u'SelectedListTable')
self.SelectedListTable.setColumnCount(2)
self.SelectedListTable.setRowCount(0)
item = QtGui.QTableWidgetItem()
self.SelectedListTable.setHorizontalHeaderItem(0, item)
item = QtGui.QTableWidgetItem()
self.SelectedListTable.setHorizontalHeaderItem(1, item)
self.verticalLayout_2.addWidget(self.SelectedListTable)
self.SelectedSelectAllWidget = QtGui.QWidget(self.SelectedFileListWidget)
self.SelectedSelectAllWidget.setObjectName(u'SelectedSelectAllWidget')
self.horizontalLayout_4 = QtGui.QHBoxLayout(self.SelectedSelectAllWidget)
self.horizontalLayout_4.setSpacing(6)
self.horizontalLayout_4.setMargin(0)
self.horizontalLayout_4.setObjectName(u'horizontalLayout_4')
self.SelectedSelectAllPushButton = QtGui.QPushButton(self.SelectedSelectAllWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.SelectedSelectAllPushButton.sizePolicy().hasHeightForWidth())
self.SelectedSelectAllPushButton.setSizePolicy(sizePolicy)
self.SelectedSelectAllPushButton.setMinimumSize(QtCore.QSize(100, 0))
self.SelectedSelectAllPushButton.setIcon(icon2)
self.SelectedSelectAllPushButton.setObjectName(u'SelectedSelectAllPushButton')
self.horizontalLayout_4.addWidget(self.SelectedSelectAllPushButton)
spacerItem3 = QtGui.QSpacerItem(92, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.horizontalLayout_4.addItem(spacerItem3)
self.verticalLayout_2.addWidget(self.SelectedSelectAllWidget)
self.SelectedRemoveSelectedWidget = QtGui.QWidget(self.SelectedFileListWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.SelectedRemoveSelectedWidget.sizePolicy().hasHeightForWidth())
self.SelectedRemoveSelectedWidget.setSizePolicy(sizePolicy)
self.SelectedRemoveSelectedWidget.setObjectName(u'SelectedRemoveSelectedWidget')
self.horizontalLayout_5 = QtGui.QHBoxLayout(self.SelectedRemoveSelectedWidget)
self.horizontalLayout_5.setMargin(0)
self.horizontalLayout_5.setObjectName(u'horizontalLayout_5')
self.SelectedRemoveSelectedButton = QtGui.QPushButton(self.SelectedRemoveSelectedWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.SelectedRemoveSelectedButton.sizePolicy().hasHeightForWidth())
self.SelectedRemoveSelectedButton.setSizePolicy(sizePolicy)
self.SelectedRemoveSelectedButton.setMinimumSize(QtCore.QSize(140, 0))
icon4 = QtGui.QIcon()
icon4.addPixmap(QtGui.QPixmap(u':/imports/import_remove.png'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.SelectedRemoveSelectedButton.setIcon(icon4)
self.SelectedRemoveSelectedButton.setObjectName(u'SelectedRemoveSelectedButton')
self.horizontalLayout_5.addWidget(self.SelectedRemoveSelectedButton)
spacerItem4 = QtGui.QSpacerItem(49, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.horizontalLayout_5.addItem(spacerItem4)
self.verticalLayout_2.addWidget(self.SelectedRemoveSelectedWidget)
self.horizontalLayout_6.addWidget(self.SelectedFileListWidget)
self.verticalLayout_5.addWidget(self.SongListFrame)
self.ProgressGroupBox = QtGui.QGroupBox(OpenLPImportDialog)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.ProgressGroupBox.sizePolicy().hasHeightForWidth())
self.ProgressGroupBox.setSizePolicy(sizePolicy)
self.ProgressGroupBox.setObjectName(u'ProgressGroupBox')
self.verticalLayout_4 = QtGui.QVBoxLayout(self.ProgressGroupBox)
self.verticalLayout_4.setSpacing(8)
self.verticalLayout_4.setContentsMargins(8, 0, 8, 8)
self.verticalLayout_4.setObjectName(u'verticalLayout_4')
self.ProgressLabel = QtGui.QLabel(self.ProgressGroupBox)
self.ProgressLabel.setObjectName(u'ProgressLabel')
self.verticalLayout_4.addWidget(self.ProgressLabel)
self.ProgressBar = QtGui.QProgressBar(self.ProgressGroupBox)
self.ProgressBar.setProperty(u'value', QtCore.QVariant(24))
self.ProgressBar.setObjectName(u'ProgressBar')
self.verticalLayout_4.addWidget(self.ProgressBar)
self.verticalLayout_5.addWidget(self.ProgressGroupBox)
self.ButtonBarWidget = QtGui.QWidget(OpenLPImportDialog)
self.ButtonBarWidget.setObjectName(u'ButtonBarWidget')
self.horizontalLayout_7 = QtGui.QHBoxLayout(self.ButtonBarWidget)
self.horizontalLayout_7.setSpacing(8)
self.horizontalLayout_7.setMargin(0)
self.horizontalLayout_7.setObjectName(u'horizontalLayout_7')
spacerItem5 = QtGui.QSpacerItem(288, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.horizontalLayout_7.addItem(spacerItem5)
self.ImportPushButton = QtGui.QPushButton(self.ButtonBarWidget)
self.ImportPushButton.setObjectName(u'ImportPushButton')
self.horizontalLayout_7.addWidget(self.ImportPushButton)
self.ClosePushButton = QtGui.QPushButton(self.ButtonBarWidget)
self.ClosePushButton.setObjectName(u'ClosePushButton')
self.horizontalLayout_7.addWidget(self.ClosePushButton)
self.verticalLayout_5.addWidget(self.ButtonBarWidget)
self.retranslateUi(OpenLPImportDialog)
QtCore.QObject.connect(self.ClosePushButton, QtCore.SIGNAL(u'clicked()'), OpenLPImportDialog.close)
QtCore.QObject.connect(self.ImportSelectAllPushButton, QtCore.SIGNAL(u'clicked()'), self.ImportListTable.selectAll)
QtCore.QObject.connect(self.SelectedSelectAllPushButton, QtCore.SIGNAL(u'clicked()'), self.SelectedListTable.selectAll)
QtCore.QObject.connect(self.SelectedRemoveSelectedButton, QtCore.SIGNAL(u'clicked()'), self.SelectedListTable.clear)
QtCore.QMetaObject.connectSlotsByName(OpenLPImportDialog)
def retranslateUi(self, OpenLPImportDialog):
OpenLPImportDialog.setWindowTitle(
translate(u'SongsPlugin.OpenLPImportForm',
u'openlp.org Song Importer'))
self.ImportFileLabel.setText(
translate(u'SongsPlugin.OpenLPImportForm',
u'Select openlp.org songfile to import:'))
self.ImportListLabel.setText(
translate(u'SongsPlugin.OpenLPImportForm',
u'Import File Song List'))
self.ImportListTable.horizontalHeaderItem(0).setText(
translate(u'SongsPlugin.OpenLPImportForm', u'Song Title'))
self.ImportListTable.horizontalHeaderItem(1).setText(
translate(u'SongsPlugin.OpenLPImportForm', u'Author'))
self.ImportSelectAllPushButton.setText(
translate(u'SongsPlugin.OpenLPImportForm', u'Select All'))
self.ImportFilterComboBox.setItemText(0,
translate(u'SongsPlugin.OpenLPImportForm', u'Lyrics'))
self.ImportFilterComboBox.setItemText(1,
translate(u'SongsPlugin.OpenLPImportForm', u'Title'))
self.ImportFilterComboBox.setItemText(2,
translate(u'SongsPlugin.OpenLPImportForm', u'Author'))
self.SelectedListLabel.setText(
translate(u'SongsPlugin.OpenLPImportForm', u'Song Import List'))
self.SelectedListTable.horizontalHeaderItem(0).setText(
translate(u'SongsPlugin.OpenLPImportForm', u'Song Title'))
self.SelectedListTable.horizontalHeaderItem(1).setText(
translate(u'SongsPlugin.OpenLPImportForm', u'Author'))
self.SelectedSelectAllPushButton.setText(
translate(u'SongsPlugin.OpenLPImportForm', u'Select All'))
self.SelectedRemoveSelectedButton.setText(
translate(u'SongsPlugin.OpenLPImportForm', u'Remove Selected'))
self.ProgressGroupBox.setTitle(
translate(u'SongsPlugin.OpenLPImportForm', u'Progress:'))
self.ProgressLabel.setText(
translate(u'SongsPlugin.OpenLPImportForm', u'Ready to import'))
self.ImportPushButton.setText(
translate(u'SongsPlugin.OpenLPImportForm', u'Import'))
self.ClosePushButton.setText(
translate(u'SongsPlugin.OpenLPImportForm', u'Close'))

View File

@ -1,33 +0,0 @@
# -*- coding: utf-8 -*-
# vim: autoindent shiftwidth=4 expandtab textwidth=80 tabstop=4 softtabstop=4
###############################################################################
# OpenLP - Open Source Lyrics Projection #
# --------------------------------------------------------------------------- #
# Copyright (c) 2008-2010 Raoul Snyman #
# Portions copyright (c) 2008-2010 Tim Bentley, Jonathan Corwin, Michael #
# Gorven, Scott Guerrieri, Christian Richter, Maikel Stuivenberg, Martin #
# Thompson, Jon Tibble, Carsten Tinggaard #
# --------------------------------------------------------------------------- #
# This program is free software; you can redistribute it and/or modify it #
# under the terms of the GNU General Public License as published by the Free #
# Software Foundation; version 2 of the License. #
# #
# This program is distributed in the hope that it will be useful, but WITHOUT #
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or #
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for #
# more details. #
# #
# You should have received a copy of the GNU General Public License along #
# with this program; if not, write to the Free Software Foundation, Inc., 59 #
# Temple Place, Suite 330, Boston, MA 02111-1307 USA #
###############################################################################
from PyQt4 import QtGui
from openlp.plugins.songs.forms.openlpimportdialog import Ui_OpenLPImportDialog
class OpenLPImportForm(QtGui.QDialog, Ui_OpenLPImportDialog):
def __init__(self, parent=None):
QtGui.QDialog.__init__(self, parent)
self.setupUi(self)

View File

@ -1,324 +0,0 @@
# -*- coding: utf-8 -*-
# vim: autoindent shiftwidth=4 expandtab textwidth=80 tabstop=4 softtabstop=4
###############################################################################
# OpenLP - Open Source Lyrics Projection #
# --------------------------------------------------------------------------- #
# Copyright (c) 2008-2010 Raoul Snyman #
# Portions copyright (c) 2008-2010 Tim Bentley, Jonathan Corwin, Michael #
# Gorven, Scott Guerrieri, Christian Richter, Maikel Stuivenberg, Martin #
# Thompson, Jon Tibble, Carsten Tinggaard #
# --------------------------------------------------------------------------- #
# This program is free software; you can redistribute it and/or modify it #
# under the terms of the GNU General Public License as published by the Free #
# Software Foundation; version 2 of the License. #
# #
# This program is distributed in the hope that it will be useful, but WITHOUT #
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or #
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for #
# more details. #
# #
# You should have received a copy of the GNU General Public License along #
# with this program; if not, write to the Free Software Foundation, Inc., 59 #
# Temple Place, Suite 330, Boston, MA 02111-1307 USA #
###############################################################################
from PyQt4 import QtCore, QtGui
from openlp.core.lib import translate
class Ui_OpenSongExportDialog(object):
def setupUi(self, OpenSongExportDialog):
OpenSongExportDialog.setObjectName(u'OpenSongExportDialog')
OpenSongExportDialog.resize(473, 459)
icon = QtGui.QIcon()
icon.addPixmap(QtGui.QPixmap(u':/icon/openlp.org-icon-32.bmp'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
OpenSongExportDialog.setWindowIcon(icon)
self.verticalLayout_5 = QtGui.QVBoxLayout(OpenSongExportDialog)
self.verticalLayout_5.setMargin(8)
self.verticalLayout_5.setObjectName(u'verticalLayout_5')
self.ExportFileWidget = QtGui.QWidget(OpenSongExportDialog)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.ExportFileWidget.sizePolicy().hasHeightForWidth())
self.ExportFileWidget.setSizePolicy(sizePolicy)
self.ExportFileWidget.setObjectName(u'ExportFileWidget')
self.horizontalLayout = QtGui.QHBoxLayout(self.ExportFileWidget)
self.horizontalLayout.setSpacing(3)
self.horizontalLayout.setMargin(0)
self.horizontalLayout.setObjectName(u'horizontalLayout')
self.ExportFileLabel = QtGui.QLabel(self.ExportFileWidget)
self.ExportFileLabel.setObjectName(u'ExportFileLabel')
self.horizontalLayout.addWidget(self.ExportFileLabel)
self.ExportFileLineEdit = QtGui.QLineEdit(self.ExportFileWidget)
self.ExportFileLineEdit.setObjectName(u'ExportFileLineEdit')
self.horizontalLayout.addWidget(self.ExportFileLineEdit)
self.ExportFileSelectPushButton = QtGui.QPushButton(self.ExportFileWidget)
icon1 = QtGui.QIcon()
icon1.addPixmap(QtGui.QPixmap(u':/exports/export_load.png'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.ExportFileSelectPushButton.setIcon(icon1)
self.ExportFileSelectPushButton.setObjectName(u'ExportFileSelectPushButton')
self.horizontalLayout.addWidget(self.ExportFileSelectPushButton)
self.verticalLayout_5.addWidget(self.ExportFileWidget)
self.SongListFrame = QtGui.QFrame(OpenSongExportDialog)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Expanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.SongListFrame.sizePolicy().hasHeightForWidth())
self.SongListFrame.setSizePolicy(sizePolicy)
self.SongListFrame.setFrameShape(QtGui.QFrame.Box)
self.SongListFrame.setFrameShadow(QtGui.QFrame.Raised)
self.SongListFrame.setObjectName(u'SongListFrame')
self.horizontalLayout_6 = QtGui.QHBoxLayout(self.SongListFrame)
self.horizontalLayout_6.setSpacing(8)
self.horizontalLayout_6.setMargin(8)
self.horizontalLayout_6.setObjectName(u'horizontalLayout_6')
self.ExportFileSongListWidget = QtGui.QWidget(self.SongListFrame)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Expanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.ExportFileSongListWidget.sizePolicy().hasHeightForWidth())
self.ExportFileSongListWidget.setSizePolicy(sizePolicy)
self.ExportFileSongListWidget.setObjectName(u'ExportFileSongListWidget')
self.verticalLayout = QtGui.QVBoxLayout(self.ExportFileSongListWidget)
self.verticalLayout.setSpacing(6)
self.verticalLayout.setMargin(0)
self.verticalLayout.setObjectName(u'verticalLayout')
self.ExportListLabel = QtGui.QLabel(self.ExportFileSongListWidget)
self.ExportListLabel.setObjectName(u'ExportListLabel')
self.verticalLayout.addWidget(self.ExportListLabel)
self.ExportListTable = QtGui.QTableWidget(self.ExportFileSongListWidget)
self.ExportListTable.setSelectionMode(QtGui.QAbstractItemView.MultiSelection)
self.ExportListTable.setShowGrid(False)
self.ExportListTable.setWordWrap(False)
self.ExportListTable.setCornerButtonEnabled(False)
self.ExportListTable.setObjectName(u'ExportListTable')
self.ExportListTable.setColumnCount(2)
self.ExportListTable.setRowCount(0)
item = QtGui.QTableWidgetItem()
self.ExportListTable.setHorizontalHeaderItem(0, item)
item = QtGui.QTableWidgetItem()
self.ExportListTable.setHorizontalHeaderItem(1, item)
self.verticalLayout.addWidget(self.ExportListTable)
self.ExportSelectAllWidget = QtGui.QWidget(self.ExportFileSongListWidget)
self.ExportSelectAllWidget.setObjectName(u'ExportSelectAllWidget')
self.horizontalLayout_2 = QtGui.QHBoxLayout(self.ExportSelectAllWidget)
self.horizontalLayout_2.setSpacing(6)
self.horizontalLayout_2.setMargin(0)
self.horizontalLayout_2.setObjectName(u'horizontalLayout_2')
self.ExportSelectAllPushButton = QtGui.QPushButton(self.ExportSelectAllWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.ExportSelectAllPushButton.sizePolicy().hasHeightForWidth())
self.ExportSelectAllPushButton.setSizePolicy(sizePolicy)
self.ExportSelectAllPushButton.setMinimumSize(QtCore.QSize(100, 0))
icon2 = QtGui.QIcon()
icon2.addPixmap(QtGui.QPixmap(u':/exports/export_selectall.png'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.ExportSelectAllPushButton.setIcon(icon2)
self.ExportSelectAllPushButton.setObjectName(u'ExportSelectAllPushButton')
self.horizontalLayout_2.addWidget(self.ExportSelectAllPushButton)
spacerItem = QtGui.QSpacerItem(89, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.horizontalLayout_2.addItem(spacerItem)
self.verticalLayout.addWidget(self.ExportSelectAllWidget)
self.exportFilterWidget = QtGui.QWidget(self.ExportFileSongListWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.exportFilterWidget.sizePolicy().hasHeightForWidth())
self.exportFilterWidget.setSizePolicy(sizePolicy)
self.exportFilterWidget.setMinimumSize(QtCore.QSize(0, 0))
self.exportFilterWidget.setObjectName(u'exportFilterWidget')
self.horizontalLayout_3 = QtGui.QHBoxLayout(self.exportFilterWidget)
self.horizontalLayout_3.setMargin(0)
self.horizontalLayout_3.setObjectName(u'horizontalLayout_3')
self.ExportFilterComboBox = QtGui.QComboBox(self.exportFilterWidget)
self.ExportFilterComboBox.setMinimumSize(QtCore.QSize(70, 0))
self.ExportFilterComboBox.setObjectName(u'ExportFilterComboBox')
self.ExportFilterComboBox.addItem(QtCore.QString())
self.ExportFilterComboBox.addItem(QtCore.QString())
self.ExportFilterComboBox.addItem(QtCore.QString())
self.horizontalLayout_3.addWidget(self.ExportFilterComboBox)
self.ExportFilterLineEdit = QtGui.QLineEdit(self.exportFilterWidget)
self.ExportFilterLineEdit.setObjectName(u'ExportFilterLineEdit')
self.horizontalLayout_3.addWidget(self.ExportFilterLineEdit)
self.verticalLayout.addWidget(self.exportFilterWidget)
self.horizontalLayout_6.addWidget(self.ExportFileSongListWidget)
self.AddSelectedWidget = QtGui.QWidget(self.SongListFrame)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Expanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.AddSelectedWidget.sizePolicy().hasHeightForWidth())
self.AddSelectedWidget.setSizePolicy(sizePolicy)
self.AddSelectedWidget.setObjectName(u'AddSelectedWidget')
self.verticalLayout_3 = QtGui.QVBoxLayout(self.AddSelectedWidget)
self.verticalLayout_3.setMargin(0)
self.verticalLayout_3.setObjectName(u'verticalLayout_3')
spacerItem1 = QtGui.QSpacerItem(20, 40, QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Expanding)
self.verticalLayout_3.addItem(spacerItem1)
self.AddSelectedPushButton = QtGui.QPushButton(self.AddSelectedWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Minimum)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.AddSelectedPushButton.sizePolicy().hasHeightForWidth())
self.AddSelectedPushButton.setSizePolicy(sizePolicy)
self.AddSelectedPushButton.setMinimumSize(QtCore.QSize(25, 25))
icon3 = QtGui.QIcon()
icon3.addPixmap(QtGui.QPixmap(u':/exports/export_move_to_list.png'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.AddSelectedPushButton.setIcon(icon3)
self.AddSelectedPushButton.setObjectName(u'AddSelectedPushButton')
self.verticalLayout_3.addWidget(self.AddSelectedPushButton)
spacerItem2 = QtGui.QSpacerItem(20, 40, QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Expanding)
self.verticalLayout_3.addItem(spacerItem2)
self.horizontalLayout_6.addWidget(self.AddSelectedWidget)
self.SelectedFileListWidget = QtGui.QWidget(self.SongListFrame)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Expanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.SelectedFileListWidget.sizePolicy().hasHeightForWidth())
self.SelectedFileListWidget.setSizePolicy(sizePolicy)
self.SelectedFileListWidget.setObjectName(u'SelectedFileListWidget')
self.verticalLayout_2 = QtGui.QVBoxLayout(self.SelectedFileListWidget)
self.verticalLayout_2.setMargin(0)
self.verticalLayout_2.setObjectName(u'verticalLayout_2')
self.SelectedListLabel = QtGui.QLabel(self.SelectedFileListWidget)
self.SelectedListLabel.setObjectName(u'SelectedListLabel')
self.verticalLayout_2.addWidget(self.SelectedListLabel)
self.SelectedListTable = QtGui.QTableWidget(self.SelectedFileListWidget)
self.SelectedListTable.setSelectionMode(QtGui.QAbstractItemView.MultiSelection)
self.SelectedListTable.setShowGrid(False)
self.SelectedListTable.setWordWrap(False)
self.SelectedListTable.setCornerButtonEnabled(False)
self.SelectedListTable.setObjectName(u'SelectedListTable')
self.SelectedListTable.setColumnCount(2)
self.SelectedListTable.setRowCount(0)
item = QtGui.QTableWidgetItem()
self.SelectedListTable.setHorizontalHeaderItem(0, item)
item = QtGui.QTableWidgetItem()
self.SelectedListTable.setHorizontalHeaderItem(1, item)
self.verticalLayout_2.addWidget(self.SelectedListTable)
self.SelectedSelectAllWidget = QtGui.QWidget(self.SelectedFileListWidget)
self.SelectedSelectAllWidget.setObjectName(u'SelectedSelectAllWidget')
self.horizontalLayout_4 = QtGui.QHBoxLayout(self.SelectedSelectAllWidget)
self.horizontalLayout_4.setSpacing(6)
self.horizontalLayout_4.setMargin(0)
self.horizontalLayout_4.setObjectName(u'horizontalLayout_4')
self.SelectedSelectAllPushButton = QtGui.QPushButton(self.SelectedSelectAllWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.SelectedSelectAllPushButton.sizePolicy().hasHeightForWidth())
self.SelectedSelectAllPushButton.setSizePolicy(sizePolicy)
self.SelectedSelectAllPushButton.setMinimumSize(QtCore.QSize(100, 0))
self.SelectedSelectAllPushButton.setIcon(icon2)
self.SelectedSelectAllPushButton.setObjectName(u'SelectedSelectAllPushButton')
self.horizontalLayout_4.addWidget(self.SelectedSelectAllPushButton)
spacerItem3 = QtGui.QSpacerItem(92, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.horizontalLayout_4.addItem(spacerItem3)
self.verticalLayout_2.addWidget(self.SelectedSelectAllWidget)
self.SelectedRemoveSelectedWidget = QtGui.QWidget(self.SelectedFileListWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.SelectedRemoveSelectedWidget.sizePolicy().hasHeightForWidth())
self.SelectedRemoveSelectedWidget.setSizePolicy(sizePolicy)
self.SelectedRemoveSelectedWidget.setObjectName(u'SelectedRemoveSelectedWidget')
self.horizontalLayout_5 = QtGui.QHBoxLayout(self.SelectedRemoveSelectedWidget)
self.horizontalLayout_5.setMargin(0)
self.horizontalLayout_5.setObjectName(u'horizontalLayout_5')
self.SelectedRemoveSelectedButton = QtGui.QPushButton(self.SelectedRemoveSelectedWidget)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.SelectedRemoveSelectedButton.sizePolicy().hasHeightForWidth())
self.SelectedRemoveSelectedButton.setSizePolicy(sizePolicy)
self.SelectedRemoveSelectedButton.setMinimumSize(QtCore.QSize(140, 0))
icon4 = QtGui.QIcon()
icon4.addPixmap(QtGui.QPixmap(u':/exports/export_remove.png'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.SelectedRemoveSelectedButton.setIcon(icon4)
self.SelectedRemoveSelectedButton.setObjectName(u'SelectedRemoveSelectedButton')
self.horizontalLayout_5.addWidget(self.SelectedRemoveSelectedButton)
spacerItem4 = QtGui.QSpacerItem(49, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.horizontalLayout_5.addItem(spacerItem4)
self.verticalLayout_2.addWidget(self.SelectedRemoveSelectedWidget)
self.horizontalLayout_6.addWidget(self.SelectedFileListWidget)
self.verticalLayout_5.addWidget(self.SongListFrame)
self.ProgressGroupBox = QtGui.QGroupBox(OpenSongExportDialog)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.ProgressGroupBox.sizePolicy().hasHeightForWidth())
self.ProgressGroupBox.setSizePolicy(sizePolicy)
self.ProgressGroupBox.setObjectName(u'ProgressGroupBox')
self.verticalLayout_4 = QtGui.QVBoxLayout(self.ProgressGroupBox)
self.verticalLayout_4.setSpacing(8)
self.verticalLayout_4.setContentsMargins(8, 0, 8, 8)
self.verticalLayout_4.setObjectName(u'verticalLayout_4')
self.ProgressLabel = QtGui.QLabel(self.ProgressGroupBox)
self.ProgressLabel.setObjectName(u'ProgressLabel')
self.verticalLayout_4.addWidget(self.ProgressLabel)
self.ProgressBar = QtGui.QProgressBar(self.ProgressGroupBox)
self.ProgressBar.setProperty(u'value', QtCore.QVariant(24))
self.ProgressBar.setObjectName(u'ProgressBar')
self.verticalLayout_4.addWidget(self.ProgressBar)
self.verticalLayout_5.addWidget(self.ProgressGroupBox)
self.ButtonBarWidget = QtGui.QWidget(OpenSongExportDialog)
self.ButtonBarWidget.setObjectName(u'ButtonBarWidget')
self.horizontalLayout_7 = QtGui.QHBoxLayout(self.ButtonBarWidget)
self.horizontalLayout_7.setSpacing(8)
self.horizontalLayout_7.setMargin(0)
self.horizontalLayout_7.setObjectName(u'horizontalLayout_7')
spacerItem5 = QtGui.QSpacerItem(288, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.horizontalLayout_7.addItem(spacerItem5)
self.ExportPushButton = QtGui.QPushButton(self.ButtonBarWidget)
self.ExportPushButton.setObjectName(u'ExportPushButton')
self.horizontalLayout_7.addWidget(self.ExportPushButton)
self.ClosePushButton = QtGui.QPushButton(self.ButtonBarWidget)
self.ClosePushButton.setObjectName(u'ClosePushButton')
self.horizontalLayout_7.addWidget(self.ClosePushButton)
self.verticalLayout_5.addWidget(self.ButtonBarWidget)
self.retranslateUi(OpenSongExportDialog)
QtCore.QObject.connect(self.ClosePushButton, QtCore.SIGNAL(u'clicked()'), OpenSongExportDialog.close)
QtCore.QObject.connect(self.ExportSelectAllPushButton, QtCore.SIGNAL(u'clicked()'), self.ExportListTable.selectAll)
QtCore.QObject.connect(self.SelectedSelectAllPushButton, QtCore.SIGNAL(u'clicked()'), self.SelectedListTable.selectAll)
QtCore.QObject.connect(self.SelectedRemoveSelectedButton, QtCore.SIGNAL(u'clicked()'), self.SelectedListTable.clear)
QtCore.QMetaObject.connectSlotsByName(OpenSongExportDialog)
def retranslateUi(self, OpenSongExportDialog):
OpenSongExportDialog.setWindowTitle(
translate(u'SongsPlugin.OpenSongExportForm', u'OpenSong Song Exporter'))
self.ExportFileLabel.setText(
translate(u'SongsPlugin.OpenSongExportForm', u'Select OpenSong song folder:'))
self.ExportListLabel.setText(
translate(u'SongsPlugin.OpenSongExportForm', u'Full Song List'))
self.ExportListTable.horizontalHeaderItem(0).setText(
translate(u'SongsPlugin.OpenSongExportForm', u'Song Title'))
self.ExportListTable.horizontalHeaderItem(1).setText(
translate(u'SongsPlugin.OpenSongExportForm', u'Author'))
self.ExportSelectAllPushButton.setText(
translate(u'SongsPlugin.OpenSongExportForm', u'Select All'))
self.ExportFilterComboBox.setItemText(0,
translate(u'SongsPlugin.OpenSongExportForm', u'Lyrics'))
self.ExportFilterComboBox.setItemText(1,
translate(u'SongsPlugin.OpenSongExportForm', u'Title'))
self.ExportFilterComboBox.setItemText(2,
translate(u'SongsPlugin.OpenSongExportForm', u'Author'))
self.SelectedListLabel.setText(
translate(u'SongsPlugin.OpenSongExportForm', u'Song Export List'))
self.SelectedListTable.horizontalHeaderItem(0).setText(
translate(u'SongsPlugin.OpenSongExportForm', u'Song Title'))
self.SelectedListTable.horizontalHeaderItem(1).setText(
translate(u'SongsPlugin.OpenSongExportForm', u'Author'))
self.SelectedSelectAllPushButton.setText(
translate(u'SongsPlugin.OpenSongExportForm', u'Select All'))
self.SelectedRemoveSelectedButton.setText(
translate(u'SongsPlugin.OpenSongExportForm', u'Remove Selected'))
self.ProgressGroupBox.setTitle(
translate(u'SongsPlugin.OpenSongExportForm', u'Progress:'))
self.ProgressLabel.setText(
translate(u'SongsPlugin.OpenSongExportForm', u'Ready to export'))
self.ExportPushButton.setText(
translate(u'SongsPlugin.OpenSongExportForm', u'Export'))
self.ClosePushButton.setText(
translate(u'SongsPlugin.OpenSongExportForm', u'Close'))

View File

@ -1,33 +0,0 @@
# -*- coding: utf-8 -*-
# vim: autoindent shiftwidth=4 expandtab textwidth=80 tabstop=4 softtabstop=4
###############################################################################
# OpenLP - Open Source Lyrics Projection #
# --------------------------------------------------------------------------- #
# Copyright (c) 2008-2010 Raoul Snyman #
# Portions copyright (c) 2008-2010 Tim Bentley, Jonathan Corwin, Michael #
# Gorven, Scott Guerrieri, Christian Richter, Maikel Stuivenberg, Martin #
# Thompson, Jon Tibble, Carsten Tinggaard #
# --------------------------------------------------------------------------- #
# This program is free software; you can redistribute it and/or modify it #
# under the terms of the GNU General Public License as published by the Free #
# Software Foundation; version 2 of the License. #
# #
# This program is distributed in the hope that it will be useful, but WITHOUT #
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or #
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for #
# more details. #
# #
# You should have received a copy of the GNU General Public License along #
# with this program; if not, write to the Free Software Foundation, Inc., 59 #
# Temple Place, Suite 330, Boston, MA 02111-1307 USA #
###############################################################################
from PyQt4 import QtGui
from openlp.plugins.songs.forms.opensongexportdialog import Ui_OpenSongExportDialog
class OpenSongExportForm(QtGui.QDialog, Ui_OpenSongExportDialog):
def __init__(self, parent=None):
QtGui.QDialog.__init__(self, parent)
self.setupUi(self)

View File

@ -1,115 +0,0 @@
# -*- coding: utf-8 -*-
# vim: autoindent shiftwidth=4 expandtab textwidth=80 tabstop=4 softtabstop=4
###############################################################################
# OpenLP - Open Source Lyrics Projection #
# --------------------------------------------------------------------------- #
# Copyright (c) 2008-2010 Raoul Snyman #
# Portions copyright (c) 2008-2010 Tim Bentley, Jonathan Corwin, Michael #
# Gorven, Scott Guerrieri, Christian Richter, Maikel Stuivenberg, Martin #
# Thompson, Jon Tibble, Carsten Tinggaard #
# --------------------------------------------------------------------------- #
# This program is free software; you can redistribute it and/or modify it #
# under the terms of the GNU General Public License as published by the Free #
# Software Foundation; version 2 of the License. #
# #
# This program is distributed in the hope that it will be useful, but WITHOUT #
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or #
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for #
# more details. #
# #
# You should have received a copy of the GNU General Public License along #
# with this program; if not, write to the Free Software Foundation, Inc., 59 #
# Temple Place, Suite 330, Boston, MA 02111-1307 USA #
###############################################################################
from PyQt4 import QtCore, QtGui
from openlp.core.lib import translate
class Ui_OpenSongImportDialog(object):
def setupUi(self, OpenSongImportDialog):
OpenSongImportDialog.setObjectName(u'OpenSongImportDialog')
OpenSongImportDialog.resize(481, 172)
icon = QtGui.QIcon()
icon.addPixmap(QtGui.QPixmap(u':/icon/openlp.org-icon-32.bmp'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
OpenSongImportDialog.setWindowIcon(icon)
self.verticalLayout = QtGui.QVBoxLayout(OpenSongImportDialog)
self.verticalLayout.setSpacing(6)
self.verticalLayout.setMargin(8)
self.verticalLayout.setObjectName(u'verticalLayout')
self.ImportFileWidget = QtGui.QWidget(OpenSongImportDialog)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.ImportFileWidget.sizePolicy().hasHeightForWidth())
self.ImportFileWidget.setSizePolicy(sizePolicy)
self.ImportFileWidget.setObjectName(u'ImportFileWidget')
self.horizontalLayout = QtGui.QHBoxLayout(self.ImportFileWidget)
self.horizontalLayout.setSpacing(6)
self.horizontalLayout.setMargin(0)
self.horizontalLayout.setObjectName(u'horizontalLayout')
self.ImportFileLabel = QtGui.QLabel(self.ImportFileWidget)
self.ImportFileLabel.setObjectName(u'ImportFileLabel')
self.horizontalLayout.addWidget(self.ImportFileLabel)
self.ImportFileLineEdit = QtGui.QLineEdit(self.ImportFileWidget)
self.ImportFileLineEdit.setObjectName(u'ImportFileLineEdit')
self.horizontalLayout.addWidget(self.ImportFileLineEdit)
self.ImportFileSelectPushButton = QtGui.QPushButton(self.ImportFileWidget)
icon1 = QtGui.QIcon()
icon1.addPixmap(QtGui.QPixmap(u':/imports/import_load.png'), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.ImportFileSelectPushButton.setIcon(icon1)
self.ImportFileSelectPushButton.setObjectName(u'ImportFileSelectPushButton')
self.horizontalLayout.addWidget(self.ImportFileSelectPushButton)
self.verticalLayout.addWidget(self.ImportFileWidget)
self.ProgressGroupBox = QtGui.QGroupBox(OpenSongImportDialog)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.ProgressGroupBox.sizePolicy().hasHeightForWidth())
self.ProgressGroupBox.setSizePolicy(sizePolicy)
self.ProgressGroupBox.setObjectName(u'ProgressGroupBox')
self.verticalLayout_4 = QtGui.QVBoxLayout(self.ProgressGroupBox)
self.verticalLayout_4.setSpacing(6)
self.verticalLayout_4.setContentsMargins(6, 0, 8, 8)
self.verticalLayout_4.setObjectName(u'verticalLayout_4')
self.ProgressLabel = QtGui.QLabel(self.ProgressGroupBox)
self.ProgressLabel.setObjectName(u'ProgressLabel')
self.verticalLayout_4.addWidget(self.ProgressLabel)
self.ProgressBar = QtGui.QProgressBar(self.ProgressGroupBox)
self.ProgressBar.setProperty(u'value', QtCore.QVariant(24))
self.ProgressBar.setObjectName(u'ProgressBar')
self.verticalLayout_4.addWidget(self.ProgressBar)
self.verticalLayout.addWidget(self.ProgressGroupBox)
self.ButtonBarWidget = QtGui.QWidget(OpenSongImportDialog)
self.ButtonBarWidget.setObjectName(u'ButtonBarWidget')
self.horizontalLayout_7 = QtGui.QHBoxLayout(self.ButtonBarWidget)
self.horizontalLayout_7.setSpacing(8)
self.horizontalLayout_7.setMargin(0)
self.horizontalLayout_7.setObjectName(u'horizontalLayout_7')
spacerItem = QtGui.QSpacerItem(288, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.horizontalLayout_7.addItem(spacerItem)
self.ImportPushButton = QtGui.QPushButton(self.ButtonBarWidget)
self.ImportPushButton.setObjectName(u'ImportPushButton')
self.horizontalLayout_7.addWidget(self.ImportPushButton)
self.ClosePushButton = QtGui.QPushButton(self.ButtonBarWidget)
self.ClosePushButton.setObjectName(u'ClosePushButton')
self.horizontalLayout_7.addWidget(self.ClosePushButton)
self.verticalLayout.addWidget(self.ButtonBarWidget)
self.retranslateUi(OpenSongImportDialog)
QtCore.QObject.connect(self.ClosePushButton, QtCore.SIGNAL(u'clicked()'), OpenSongImportDialog.close)
QtCore.QMetaObject.connectSlotsByName(OpenSongImportDialog)
def retranslateUi(self, OpenSongImportDialog):
OpenSongImportDialog.setWindowTitle(
translate(u'SongsPlugin.OpenSongImportForm', u'OpenSong Song Importer'))
self.ImportFileLabel.setText(
translate(u'SongsPlugin.OpenSongImportForm', u'OpenSong Folder:'))
self.ProgressGroupBox.setTitle(
translate(u'SongsPlugin.OpenSongImportForm', u'Progress:'))
self.ProgressLabel.setText(
translate(u'SongsPlugin.OpenSongImportForm', u'Ready to import'))
self.ImportPushButton.setText(
translate(u'SongsPlugin.OpenSongImportForm', u'Import'))
self.ClosePushButton.setText(
translate(u'SongsPlugin.OpenSongImportForm', u'Close'))

View File

@ -1,33 +0,0 @@
# -*- coding: utf-8 -*-
# vim: autoindent shiftwidth=4 expandtab textwidth=80 tabstop=4 softtabstop=4
###############################################################################
# OpenLP - Open Source Lyrics Projection #
# --------------------------------------------------------------------------- #
# Copyright (c) 2008-2010 Raoul Snyman #
# Portions copyright (c) 2008-2010 Tim Bentley, Jonathan Corwin, Michael #
# Gorven, Scott Guerrieri, Christian Richter, Maikel Stuivenberg, Martin #
# Thompson, Jon Tibble, Carsten Tinggaard #
# --------------------------------------------------------------------------- #
# This program is free software; you can redistribute it and/or modify it #
# under the terms of the GNU General Public License as published by the Free #
# Software Foundation; version 2 of the License. #
# #
# This program is distributed in the hope that it will be useful, but WITHOUT #
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or #
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for #
# more details. #
# #
# You should have received a copy of the GNU General Public License along #
# with this program; if not, write to the Free Software Foundation, Inc., 59 #
# Temple Place, Suite 330, Boston, MA 02111-1307 USA #
###############################################################################
from PyQt4 import QtGui
from openlp.plugins.songs.forms.opensongimportdialog import Ui_OpenSongImportDialog
class OpenSongImportForm(QtGui.QDialog, Ui_OpenSongImportDialog):
def __init__(self, parent=None):
QtGui.QDialog.__init__(self, parent)
self.setupUi(self)

View File

@ -27,7 +27,7 @@ import logging
import sys import sys
import os import os
from types import StringType, ListType from types import ListType
sys.path.append(os.path.abspath(u'./../../../..')) sys.path.append(os.path.abspath(u'./../../../..'))
@ -417,9 +417,9 @@ class Song(object):
def _list_to_string(self, strOrList): def _list_to_string(self, strOrList):
"""Force a possibly list into a string""" """Force a possibly list into a string"""
if type(strOrList) == StringType: if isinstance(strOrList, basestring):
lst = self._split_to_list(strOrList) lst = self._split_to_list(strOrList)
elif type(strOrList) == ListType: elif isinstance(strOrList, ListType):
lst = strOrList lst = strOrList
elif strOrList is None: elif strOrList is None:
lst = [] lst = []

View File

@ -1,613 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>OpenLPExportDialog</class>
<widget class="QDialog" name="OpenLPExportDialog">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>473</width>
<height>459</height>
</rect>
</property>
<property name="windowTitle">
<string>openlp.org Song Exporter</string>
</property>
<property name="windowIcon">
<iconset>
<normaloff>:/icon/openlp.org-icon-32.bmp</normaloff>:/icon/openlp.org-icon-32.bmp</iconset>
</property>
<layout class="QVBoxLayout" name="verticalLayout_5">
<property name="margin">
<number>8</number>
</property>
<item>
<widget class="QWidget" name="ExportFileWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QHBoxLayout" name="horizontalLayout">
<property name="spacing">
<number>3</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="ExportFileLabel">
<property name="text">
<string>Select openlp.org export filename:</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="ExportFileLineEdit"/>
</item>
<item>
<widget class="QPushButton" name="ExportFileSelectPushButton">
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/exports/export_load.png</normaloff>:/exports/export_load.png</iconset>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QFrame" name="SongListFrame">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="frameShape">
<enum>QFrame::Box</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Raised</enum>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_6">
<property name="spacing">
<number>8</number>
</property>
<property name="margin">
<number>8</number>
</property>
<item>
<widget class="QWidget" name="ExportFileSongListWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<property name="spacing">
<number>6</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="ExportListLabel">
<property name="text">
<string>Full Song List</string>
</property>
</widget>
</item>
<item>
<widget class="QTableWidget" name="ExportListTable">
<property name="selectionMode">
<enum>QAbstractItemView::MultiSelection</enum>
</property>
<property name="showGrid">
<bool>false</bool>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
<property name="cornerButtonEnabled">
<bool>false</bool>
</property>
<column>
<property name="text">
<string>Song Title</string>
</property>
</column>
<column>
<property name="text">
<string>Author</string>
</property>
</column>
</widget>
</item>
<item>
<widget class="QWidget" name="ExportSelectAllWidget" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_2">
<property name="spacing">
<number>6</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QPushButton" name="ExportSelectAllPushButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>100</width>
<height>0</height>
</size>
</property>
<property name="text">
<string>Select All</string>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/exports/export_selectall.png</normaloff>:/exports/export_selectall.png</iconset>
</property>
</widget>
</item>
<item>
<spacer name="ExportSelectAllHSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Expanding</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>89</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="exportFilterWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_3">
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QComboBox" name="ExportFilterComboBox">
<property name="minimumSize">
<size>
<width>70</width>
<height>0</height>
</size>
</property>
<item>
<property name="text">
<string>Lyrics</string>
</property>
</item>
<item>
<property name="text">
<string>Title</string>
</property>
</item>
<item>
<property name="text">
<string>Author</string>
</property>
</item>
</widget>
</item>
<item>
<widget class="QLineEdit" name="ExportFilterLineEdit"/>
</item>
</layout>
</widget>
</item>
</layout>
<zorder>exportFilterWidget</zorder>
<zorder>ExportListTable</zorder>
<zorder>ExportListLabel</zorder>
<zorder>ExportSelectAllWidget</zorder>
</widget>
</item>
<item>
<widget class="QWidget" name="AddSelectedWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QVBoxLayout" name="verticalLayout_3">
<property name="margin">
<number>0</number>
</property>
<item>
<spacer name="AddSelectedTopVSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="AddSelectedPushButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Minimum">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>25</width>
<height>25</height>
</size>
</property>
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/exports/export_move_to_list.png</normaloff>:/exports/export_move_to_list.png</iconset>
</property>
</widget>
</item>
<item>
<spacer name="AddSelectedBottomVSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="SelectedFileListWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="SelectedListLabel">
<property name="text">
<string>Song Export List</string>
</property>
</widget>
</item>
<item>
<widget class="QTableWidget" name="SelectedListTable">
<property name="selectionMode">
<enum>QAbstractItemView::MultiSelection</enum>
</property>
<property name="showGrid">
<bool>false</bool>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
<property name="cornerButtonEnabled">
<bool>false</bool>
</property>
<column>
<property name="text">
<string>Song Title</string>
</property>
</column>
<column>
<property name="text">
<string>Author</string>
</property>
</column>
</widget>
</item>
<item>
<widget class="QWidget" name="SelectedSelectAllWidget" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_4">
<property name="spacing">
<number>6</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QPushButton" name="SelectedSelectAllPushButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>100</width>
<height>0</height>
</size>
</property>
<property name="text">
<string>Select All</string>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/exports/export_selectall.png</normaloff>:/exports/export_selectall.png</iconset>
</property>
</widget>
</item>
<item>
<spacer name="SelectedSelectAllHSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Expanding</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>92</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="SelectedRemoveSelectedWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_5">
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QPushButton" name="SelectedRemoveSelectedButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>140</width>
<height>0</height>
</size>
</property>
<property name="text">
<string>Remove Selected</string>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/exports/export_remove.png</normaloff>:/exports/export_remove.png</iconset>
</property>
</widget>
</item>
<item>
<spacer name="SelectedRemoveSelectedHSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>49</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
</item>
</layout>
<zorder>ExportFileSongListWidget</zorder>
<zorder>SelectedFileListWidget</zorder>
<zorder>AddSelectedWidget</zorder>
</widget>
</item>
<item>
<widget class="QGroupBox" name="ProgressGroupBox">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="title">
<string>Progress:</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4">
<property name="spacing">
<number>8</number>
</property>
<property name="leftMargin">
<number>8</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>8</number>
</property>
<property name="bottomMargin">
<number>8</number>
</property>
<item>
<widget class="QLabel" name="ProgressLabel">
<property name="text">
<string>Ready to export</string>
</property>
</widget>
</item>
<item>
<widget class="QProgressBar" name="ProgressBar">
<property name="value">
<number>24</number>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="ButtonBarWidget" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_7">
<property name="spacing">
<number>8</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<spacer name="ButtonBarHSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>288</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="ExportPushButton">
<property name="text">
<string>Export</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="ClosePushButton">
<property name="text">
<string>Close</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
<resources>
<include location="../images/openlp-2.qrc"/>
</resources>
<connections>
<connection>
<sender>ClosePushButton</sender>
<signal>clicked()</signal>
<receiver>OpenLPExportDialog</receiver>
<slot>close()</slot>
<hints>
<hint type="sourcelabel">
<x>436</x>
<y>436</y>
</hint>
<hint type="destinationlabel">
<x>462</x>
<y>455</y>
</hint>
</hints>
</connection>
<connection>
<sender>ExportSelectAllPushButton</sender>
<signal>clicked()</signal>
<receiver>ExportListTable</receiver>
<slot>selectAll()</slot>
<hints>
<hint type="sourcelabel">
<x>75</x>
<y>281</y>
</hint>
<hint type="destinationlabel">
<x>88</x>
<y>176</y>
</hint>
</hints>
</connection>
<connection>
<sender>SelectedSelectAllPushButton</sender>
<signal>clicked()</signal>
<receiver>SelectedListTable</receiver>
<slot>selectAll()</slot>
<hints>
<hint type="sourcelabel">
<x>311</x>
<y>277</y>
</hint>
<hint type="destinationlabel">
<x>339</x>
<y>190</y>
</hint>
</hints>
</connection>
<connection>
<sender>SelectedRemoveSelectedButton</sender>
<signal>clicked()</signal>
<receiver>SelectedListTable</receiver>
<slot>clear()</slot>
<hints>
<hint type="sourcelabel">
<x>379</x>
<y>308</y>
</hint>
<hint type="destinationlabel">
<x>389</x>
<y>188</y>
</hint>
</hints>
</connection>
</connections>
</ui>

View File

@ -1,613 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>OpenLPImportDialog</class>
<widget class="QDialog" name="OpenLPImportDialog">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>473</width>
<height>459</height>
</rect>
</property>
<property name="windowTitle">
<string>openlp.org Song Importer</string>
</property>
<property name="windowIcon">
<iconset>
<normaloff>:/icon/openlp.org-icon-32.bmp</normaloff>:/icon/openlp.org-icon-32.bmp</iconset>
</property>
<layout class="QVBoxLayout" name="verticalLayout_5">
<property name="margin">
<number>8</number>
</property>
<item>
<widget class="QWidget" name="ImportFileWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QHBoxLayout" name="horizontalLayout">
<property name="spacing">
<number>3</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="ImportFileLabel">
<property name="text">
<string>Select openlp.org songfile to import:</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="ImportFileLineEdit"/>
</item>
<item>
<widget class="QPushButton" name="ImportFileSelectPushButton">
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/imports/import_load.png</normaloff>:/imports/import_load.png</iconset>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QFrame" name="SongListFrame">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="frameShape">
<enum>QFrame::Box</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Raised</enum>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_6">
<property name="spacing">
<number>8</number>
</property>
<property name="margin">
<number>8</number>
</property>
<item>
<widget class="QWidget" name="ImportFileSongListWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<property name="spacing">
<number>6</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="ImportListLabel">
<property name="text">
<string>Import File Song List</string>
</property>
</widget>
</item>
<item>
<widget class="QTableWidget" name="ImportListTable">
<property name="selectionMode">
<enum>QAbstractItemView::MultiSelection</enum>
</property>
<property name="showGrid">
<bool>false</bool>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
<property name="cornerButtonEnabled">
<bool>false</bool>
</property>
<column>
<property name="text">
<string>Song Title</string>
</property>
</column>
<column>
<property name="text">
<string>Author</string>
</property>
</column>
</widget>
</item>
<item>
<widget class="QWidget" name="ImportSelectAllWidget" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_2">
<property name="spacing">
<number>6</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QPushButton" name="ImportSelectAllPushButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>100</width>
<height>0</height>
</size>
</property>
<property name="text">
<string>Select All</string>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/imports/import_selectall.png</normaloff>:/imports/import_selectall.png</iconset>
</property>
</widget>
</item>
<item>
<spacer name="ImportSelectAllHSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Expanding</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>89</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="importFilterWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_3">
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QComboBox" name="ImportFilterComboBox">
<property name="minimumSize">
<size>
<width>70</width>
<height>0</height>
</size>
</property>
<item>
<property name="text">
<string>Lyrics</string>
</property>
</item>
<item>
<property name="text">
<string>Title</string>
</property>
</item>
<item>
<property name="text">
<string>Author</string>
</property>
</item>
</widget>
</item>
<item>
<widget class="QLineEdit" name="importFilterLineEdit"/>
</item>
</layout>
</widget>
</item>
</layout>
<zorder>ImportListTable</zorder>
<zorder>ImportListLabel</zorder>
<zorder>importFilterWidget</zorder>
<zorder>ImportSelectAllWidget</zorder>
</widget>
</item>
<item>
<widget class="QWidget" name="AddSelectedWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QVBoxLayout" name="verticalLayout_3">
<property name="margin">
<number>0</number>
</property>
<item>
<spacer name="AddSelectedTopVSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="AddSelectedPushButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Minimum">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>25</width>
<height>25</height>
</size>
</property>
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/imports/import_move_to_list.png</normaloff>:/imports/import_move_to_list.png</iconset>
</property>
</widget>
</item>
<item>
<spacer name="AddSelectedBottomVSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="SelectedFileListWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="SelectedListLabel">
<property name="text">
<string>Song Import List</string>
</property>
</widget>
</item>
<item>
<widget class="QTableWidget" name="SelectedListTable">
<property name="selectionMode">
<enum>QAbstractItemView::MultiSelection</enum>
</property>
<property name="showGrid">
<bool>false</bool>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
<property name="cornerButtonEnabled">
<bool>false</bool>
</property>
<column>
<property name="text">
<string>Song Title</string>
</property>
</column>
<column>
<property name="text">
<string>Author</string>
</property>
</column>
</widget>
</item>
<item>
<widget class="QWidget" name="SelectedSelectAllWidget" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_4">
<property name="spacing">
<number>6</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QPushButton" name="SelectedSelectAllPushButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>100</width>
<height>0</height>
</size>
</property>
<property name="text">
<string>Select All</string>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/imports/import_selectall.png</normaloff>:/imports/import_selectall.png</iconset>
</property>
</widget>
</item>
<item>
<spacer name="SelectedSelectAllHSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Expanding</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>92</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="SelectedRemoveSelectedWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_5">
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QPushButton" name="SelectedRemoveSelectedButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>140</width>
<height>0</height>
</size>
</property>
<property name="text">
<string>Remove Selected</string>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/imports/import_remove.png</normaloff>:/imports/import_remove.png</iconset>
</property>
</widget>
</item>
<item>
<spacer name="SelectedRemoveSelectedHSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>49</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
</item>
</layout>
<zorder>ImportFileSongListWidget</zorder>
<zorder>SelectedFileListWidget</zorder>
<zorder>AddSelectedWidget</zorder>
</widget>
</item>
<item>
<widget class="QGroupBox" name="ProgressGroupBox">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="title">
<string>Progress:</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4">
<property name="spacing">
<number>8</number>
</property>
<property name="leftMargin">
<number>8</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>8</number>
</property>
<property name="bottomMargin">
<number>8</number>
</property>
<item>
<widget class="QLabel" name="ProgressLabel">
<property name="text">
<string>Ready to import</string>
</property>
</widget>
</item>
<item>
<widget class="QProgressBar" name="ProgressBar">
<property name="value">
<number>24</number>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="ButtonBarWidget" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_7">
<property name="spacing">
<number>8</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<spacer name="ButtonBarHSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>288</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="ImportPushButton">
<property name="text">
<string>Import</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="ClosePushButton">
<property name="text">
<string>Close</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
<resources>
<include location="../images/openlp-2.qrc"/>
</resources>
<connections>
<connection>
<sender>ClosePushButton</sender>
<signal>clicked()</signal>
<receiver>OpenLPImportDialog</receiver>
<slot>close()</slot>
<hints>
<hint type="sourcelabel">
<x>436</x>
<y>436</y>
</hint>
<hint type="destinationlabel">
<x>462</x>
<y>455</y>
</hint>
</hints>
</connection>
<connection>
<sender>ImportSelectAllPushButton</sender>
<signal>clicked()</signal>
<receiver>ImportListTable</receiver>
<slot>selectAll()</slot>
<hints>
<hint type="sourcelabel">
<x>75</x>
<y>281</y>
</hint>
<hint type="destinationlabel">
<x>88</x>
<y>176</y>
</hint>
</hints>
</connection>
<connection>
<sender>SelectedSelectAllPushButton</sender>
<signal>clicked()</signal>
<receiver>SelectedListTable</receiver>
<slot>selectAll()</slot>
<hints>
<hint type="sourcelabel">
<x>311</x>
<y>277</y>
</hint>
<hint type="destinationlabel">
<x>339</x>
<y>190</y>
</hint>
</hints>
</connection>
<connection>
<sender>SelectedRemoveSelectedButton</sender>
<signal>clicked()</signal>
<receiver>SelectedListTable</receiver>
<slot>clear()</slot>
<hints>
<hint type="sourcelabel">
<x>379</x>
<y>308</y>
</hint>
<hint type="destinationlabel">
<x>389</x>
<y>188</y>
</hint>
</hints>
</connection>
</connections>
</ui>

View File

@ -1,613 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>OpenSongExportDialog</class>
<widget class="QDialog" name="OpenSongExportDialog">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>473</width>
<height>459</height>
</rect>
</property>
<property name="windowTitle">
<string>OpenSong Song Exporter</string>
</property>
<property name="windowIcon">
<iconset>
<normaloff>:/icon/openlp.org-icon-32.bmp</normaloff>:/icon/openlp.org-icon-32.bmp</iconset>
</property>
<layout class="QVBoxLayout" name="verticalLayout_5">
<property name="margin">
<number>8</number>
</property>
<item>
<widget class="QWidget" name="ExportFileWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QHBoxLayout" name="horizontalLayout">
<property name="spacing">
<number>3</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="ExportFileLabel">
<property name="text">
<string>Select OpenSong song folder:</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="ExportFileLineEdit"/>
</item>
<item>
<widget class="QPushButton" name="ExportFileSelectPushButton">
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/exports/export_load.png</normaloff>:/exports/export_load.png</iconset>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QFrame" name="SongListFrame">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="frameShape">
<enum>QFrame::Box</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Raised</enum>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_6">
<property name="spacing">
<number>8</number>
</property>
<property name="margin">
<number>8</number>
</property>
<item>
<widget class="QWidget" name="ExportFileSongListWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<property name="spacing">
<number>6</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="ExportListLabel">
<property name="text">
<string>Full Song List</string>
</property>
</widget>
</item>
<item>
<widget class="QTableWidget" name="ExportListTable">
<property name="selectionMode">
<enum>QAbstractItemView::MultiSelection</enum>
</property>
<property name="showGrid">
<bool>false</bool>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
<property name="cornerButtonEnabled">
<bool>false</bool>
</property>
<column>
<property name="text">
<string>Song Title</string>
</property>
</column>
<column>
<property name="text">
<string>Author</string>
</property>
</column>
</widget>
</item>
<item>
<widget class="QWidget" name="ExportSelectAllWidget" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_2">
<property name="spacing">
<number>6</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QPushButton" name="ExportSelectAllPushButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>100</width>
<height>0</height>
</size>
</property>
<property name="text">
<string>Select All</string>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/exports/export_selectall.png</normaloff>:/exports/export_selectall.png</iconset>
</property>
</widget>
</item>
<item>
<spacer name="ExportSelectAllHSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Expanding</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>89</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="exportFilterWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_3">
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QComboBox" name="ExportFilterComboBox">
<property name="minimumSize">
<size>
<width>70</width>
<height>0</height>
</size>
</property>
<item>
<property name="text">
<string>Lyrics</string>
</property>
</item>
<item>
<property name="text">
<string>Title</string>
</property>
</item>
<item>
<property name="text">
<string>Author</string>
</property>
</item>
</widget>
</item>
<item>
<widget class="QLineEdit" name="ExportFilterLineEdit"/>
</item>
</layout>
</widget>
</item>
</layout>
<zorder>exportFilterWidget</zorder>
<zorder>ExportListTable</zorder>
<zorder>ExportListLabel</zorder>
<zorder>ExportSelectAllWidget</zorder>
</widget>
</item>
<item>
<widget class="QWidget" name="AddSelectedWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QVBoxLayout" name="verticalLayout_3">
<property name="margin">
<number>0</number>
</property>
<item>
<spacer name="AddSelectedTopVSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="AddSelectedPushButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Minimum">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>25</width>
<height>25</height>
</size>
</property>
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/exports/export_move_to_list.png</normaloff>:/exports/export_move_to_list.png</iconset>
</property>
</widget>
</item>
<item>
<spacer name="AddSelectedBottomVSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="SelectedFileListWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="SelectedListLabel">
<property name="text">
<string>Song Export List</string>
</property>
</widget>
</item>
<item>
<widget class="QTableWidget" name="SelectedListTable">
<property name="selectionMode">
<enum>QAbstractItemView::MultiSelection</enum>
</property>
<property name="showGrid">
<bool>false</bool>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
<property name="cornerButtonEnabled">
<bool>false</bool>
</property>
<column>
<property name="text">
<string>Song Title</string>
</property>
</column>
<column>
<property name="text">
<string>Author</string>
</property>
</column>
</widget>
</item>
<item>
<widget class="QWidget" name="SelectedSelectAllWidget" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_4">
<property name="spacing">
<number>6</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QPushButton" name="SelectedSelectAllPushButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>100</width>
<height>0</height>
</size>
</property>
<property name="text">
<string>Select All</string>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/exports/export_selectall.png</normaloff>:/exports/export_selectall.png</iconset>
</property>
</widget>
</item>
<item>
<spacer name="SelectedSelectAllHSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Expanding</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>92</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="SelectedRemoveSelectedWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_5">
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QPushButton" name="SelectedRemoveSelectedButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>140</width>
<height>0</height>
</size>
</property>
<property name="text">
<string>Remove Selected</string>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/exports/export_remove.png</normaloff>:/exports/export_remove.png</iconset>
</property>
</widget>
</item>
<item>
<spacer name="SelectedRemoveSelectedHSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>49</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
</item>
</layout>
<zorder>ExportFileSongListWidget</zorder>
<zorder>SelectedFileListWidget</zorder>
<zorder>AddSelectedWidget</zorder>
</widget>
</item>
<item>
<widget class="QGroupBox" name="ProgressGroupBox">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="title">
<string>Progress:</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4">
<property name="spacing">
<number>8</number>
</property>
<property name="leftMargin">
<number>8</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>8</number>
</property>
<property name="bottomMargin">
<number>8</number>
</property>
<item>
<widget class="QLabel" name="ProgressLabel">
<property name="text">
<string>Ready to export</string>
</property>
</widget>
</item>
<item>
<widget class="QProgressBar" name="ProgressBar">
<property name="value">
<number>24</number>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="ButtonBarWidget" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_7">
<property name="spacing">
<number>8</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<spacer name="ButtonBarHSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>288</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="ExportPushButton">
<property name="text">
<string>Export</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="ClosePushButton">
<property name="text">
<string>Close</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
<resources>
<include location="../images/openlp-2.qrc"/>
</resources>
<connections>
<connection>
<sender>ClosePushButton</sender>
<signal>clicked()</signal>
<receiver>OpenSongExportDialog</receiver>
<slot>close()</slot>
<hints>
<hint type="sourcelabel">
<x>436</x>
<y>436</y>
</hint>
<hint type="destinationlabel">
<x>462</x>
<y>455</y>
</hint>
</hints>
</connection>
<connection>
<sender>ExportSelectAllPushButton</sender>
<signal>clicked()</signal>
<receiver>ExportListTable</receiver>
<slot>selectAll()</slot>
<hints>
<hint type="sourcelabel">
<x>75</x>
<y>281</y>
</hint>
<hint type="destinationlabel">
<x>88</x>
<y>176</y>
</hint>
</hints>
</connection>
<connection>
<sender>SelectedSelectAllPushButton</sender>
<signal>clicked()</signal>
<receiver>SelectedListTable</receiver>
<slot>selectAll()</slot>
<hints>
<hint type="sourcelabel">
<x>311</x>
<y>277</y>
</hint>
<hint type="destinationlabel">
<x>339</x>
<y>190</y>
</hint>
</hints>
</connection>
<connection>
<sender>SelectedRemoveSelectedButton</sender>
<signal>clicked()</signal>
<receiver>SelectedListTable</receiver>
<slot>clear()</slot>
<hints>
<hint type="sourcelabel">
<x>379</x>
<y>308</y>
</hint>
<hint type="destinationlabel">
<x>389</x>
<y>188</y>
</hint>
</hints>
</connection>
</connections>
</ui>

View File

@ -1,172 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>OpenSongImportDialog</class>
<widget class="QDialog" name="OpenSongImportDialog">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>481</width>
<height>172</height>
</rect>
</property>
<property name="windowTitle">
<string>OpenSong Song Importer</string>
</property>
<property name="windowIcon">
<iconset>
<normaloff>:/icon/openlp.org-icon-32.bmp</normaloff>:/icon/openlp.org-icon-32.bmp</iconset>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<property name="spacing">
<number>6</number>
</property>
<property name="margin">
<number>8</number>
</property>
<item>
<widget class="QWidget" name="ImportFileWidget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QHBoxLayout" name="horizontalLayout">
<property name="spacing">
<number>6</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="ImportFileLabel">
<property name="text">
<string>OpenSong Folder:</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="ImportFileLineEdit"/>
</item>
<item>
<widget class="QPushButton" name="ImportFileSelectPushButton">
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="../images/openlp-2.qrc">
<normaloff>:/imports/import_load.png</normaloff>:/imports/import_load.png</iconset>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="ProgressGroupBox">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="title">
<string>Progress:</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4">
<property name="spacing">
<number>6</number>
</property>
<property name="leftMargin">
<number>6</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>8</number>
</property>
<property name="bottomMargin">
<number>8</number>
</property>
<item>
<widget class="QLabel" name="ProgressLabel">
<property name="text">
<string>Ready to import</string>
</property>
</widget>
</item>
<item>
<widget class="QProgressBar" name="ProgressBar">
<property name="value">
<number>24</number>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="ButtonBarWidget" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_7">
<property name="spacing">
<number>8</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item>
<spacer name="ButtonBarHSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>288</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="ImportPushButton">
<property name="text">
<string>Import</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="ClosePushButton">
<property name="text">
<string>Close</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
<resources>
<include location="../images/openlp-2.qrc"/>
</resources>
<connections>
<connection>
<sender>ClosePushButton</sender>
<signal>clicked()</signal>
<receiver>OpenSongImportDialog</receiver>
<slot>close()</slot>
<hints>
<hint type="sourcelabel">
<x>424</x>
<y>132</y>
</hint>
<hint type="destinationlabel">
<x>288</x>
<y>-25</y>
</hint>
</hints>
</connection>
</connections>
</ui>

View File

@ -31,8 +31,9 @@
############################################################################### ###############################################################################
import os import os
from optparse import OptionParser
import urllib import urllib
from optparse import OptionParser
from PyQt4 import QtCore from PyQt4 import QtCore
ignore_pathes = [u"./scripts", u"./openlp/core/test"] ignore_pathes = [u"./scripts", u"./openlp/core/test"]
@ -62,16 +63,16 @@ def main():
# Set up command line options. # Set up command line options.
usage = u'Usage: %prog [options]' usage = u'Usage: %prog [options]'
parser = OptionParser(usage=usage) parser = OptionParser(usage=usage)
parser.add_option("-d", "--download-ts", action="store_true", dest="download", parser.add_option("-d", "--download-ts", action="store_true",
help="Load languages from Pootle Server") dest="download", help="Load languages from Pootle Server")
parser.add_option("-p", "--prepare", action="store_true", dest="prepare", parser.add_option("-p", "--prepare", action="store_true", dest="prepare",
help="preparation (generate pro file)") help="preparation (generate pro file)")
parser.add_option("-u", "--update", action="store_true", dest="update", parser.add_option("-u", "--update", action="store_true", dest="update",
help="update translation files") help="update translation files")
parser.add_option("-g", "--generate", action="store_true", dest="generate", parser.add_option("-g", "--generate", action="store_true", dest="generate",
help="generate qm files") help="generate qm files")
parser.add_option("-a", "--all", action="store_true", dest="all", parser.add_option("-a", "--all", action="store_true", dest="all",
help="proceed all options") help="proceed all options")
(options, args) = parser.parse_args() (options, args) = parser.parse_args()
if options.download: if options.download:
@ -90,7 +91,8 @@ def main():
def downloadTranslations(): def downloadTranslations():
print "download()" print "download()"
for language in translations: for language in translations:
filename = os.path.join(u'..',u'resources', u'i18n', u"openlp_%s.ts" % language) filename = os.path.join(u'..', u'resources', u'i18n',
u"openlp_%s.ts" % language)
print filename print filename
page = urllib.urlopen(u"%s%s.ts" % (translation_path, language)) page = urllib.urlopen(u"%s%s.ts" % (translation_path, language))
content = page.read().decode("utf8") content = page.read().decode("utf8")
@ -115,13 +117,13 @@ def preparation():
for search in ignore_pathes: for search in ignore_pathes:
if path.startswith(search): if path.startswith(search):
cond = True cond = True
if cond == True: if cond:
continue continue
cond = False cond = False
for search in ignore_files: for search in ignore_files:
if search == file: if search == file:
cond = True cond = True
if cond == True: if cond:
continue continue
if file.endswith(u'.py'): if file.endswith(u'.py'):
@ -142,7 +144,6 @@ def preparation():
write_file(os.path.join(start_dir, u'openlp.pro'), stringlist) write_file(os.path.join(start_dir, u'openlp.pro'), stringlist)
print u'done.' print u'done.'
def update(): def update():
print "update()" print "update()"
updateProcess = QtCore.QProcess() updateProcess = QtCore.QProcess()