class Ui_CustomSlideEditDialog(object): def setupUi(self, custom_slide_edit_dialog): custom_slide_edit_dialog.setObjectName('custom_slide_edit_dialog') custom_slide_edit_dialog.setWindowIcon( build_icon(u':/icon/openlp-logo.svg')) custom_slide_edit_dialog.resize(350, 300) self.dialog_layout = QtWidgets.QVBoxLayout(custom_slide_edit_dialog) self.slide_text_edit = SpellTextEdit(self) self.slide_text_edit.setObjectName('slide_text_edit') self.dialog_layout.addWidget(self.slide_text_edit) self.split_button = create_button(custom_slide_edit_dialog, 'splitButton', icon=':/general/general_add.png') self.insert_button = create_button(custom_slide_edit_dialog, 'insertButton', icon=':/general/general_add.png') self.button_box = create_button_box( custom_slide_edit_dialog, 'button_box', ['cancel', 'save'], [self.split_button, self.insert_button]) self.dialog_layout.addWidget(self.button_box) self.retranslateUi(custom_slide_edit_dialog) def retranslateUi(self, custom_slide_edit_dialog): custom_slide_edit_dialog.setWindowTitle( translate('CustomPlugin.EditVerseForm', 'Edit Slide')) self.split_button.setText(UiStrings().Split) self.split_button.setToolTip(UiStrings().SplitToolTip) self.insert_button.setText( translate('CustomPlugin.EditCustomForm', 'Insert Slide')) self.insert_button.setToolTip( translate('CustomPlugin.EditCustomForm', 'Split a slide into two by inserting a slide splitter.'))
def setupUi(self, edit_verse_dialog): edit_verse_dialog.setObjectName('edit_verse_dialog') edit_verse_dialog.setWindowIcon(build_icon(u':/icon/openlp-logo.svg')) edit_verse_dialog.resize(400, 400) edit_verse_dialog.setModal(True) self.dialog_layout = QtGui.QVBoxLayout(edit_verse_dialog) self.dialog_layout.setObjectName('dialog_layout') self.chord_hint_label = QtGui.QLabel(edit_verse_dialog) self.chord_hint_label.setObjectName('chord_hint_label') self.dialog_layout.addWidget(self.chord_hint_label) self.verse_text_edit = SpellTextEdit(edit_verse_dialog) self.verse_text_edit.setObjectName('verse_text_edit') self.chord_font = self.verse_text_edit.document().defaultFont() self.chord_font.setFamily('Hack') self.chord_font.setStyleHint(QtGui.QFont.Courier) self.chord_font.setPointSize(9) self.verse_text_edit.document().setDefaultFont(self.chord_font) self.dialog_layout.addWidget(self.verse_text_edit) self.verse_type_layout = QtGui.QHBoxLayout() self.verse_type_layout.setObjectName('verse_type_layout') # Button to insert forced split [br] # Author: nikukatansa self.force_split_button = QtGui.QPushButton(edit_verse_dialog) self.force_split_button.setIcon( build_icon(':/general/general_add.png')) self.force_split_button.setObjectName('force_split_button') self.verse_type_layout.addWidget(self.force_split_button) # END self.split_button = QtGui.QPushButton(edit_verse_dialog) self.split_button.setIcon(build_icon(':/general/general_add.png')) self.split_button.setObjectName('split_button') self.verse_type_layout.addWidget(self.split_button) self.verse_type_label = QtGui.QLabel(edit_verse_dialog) self.verse_type_label.setObjectName('verse_type_label') self.verse_type_layout.addWidget(self.verse_type_label) self.verse_type_combo_box = QtGui.QComboBox(edit_verse_dialog) self.verse_type_combo_box.addItems(['', '', '', '', '', '', '']) self.verse_type_combo_box.setObjectName('verse_type_combo_box') self.verse_type_label.setBuddy(self.verse_type_combo_box) self.verse_type_layout.addWidget(self.verse_type_combo_box) self.verse_number_box = QtGui.QSpinBox(edit_verse_dialog) self.verse_number_box.setMinimum(1) self.verse_number_box.setObjectName('verse_number_box') self.verse_type_layout.addWidget(self.verse_number_box) self.insert_button = QtGui.QPushButton(edit_verse_dialog) self.insert_button.setIcon(build_icon(':/general/general_add.png')) self.insert_button.setObjectName('insert_button') self.verse_type_layout.addWidget(self.insert_button) self.verse_type_layout.addStretch() self.dialog_layout.addLayout(self.verse_type_layout) self.button_box = create_button_box(edit_verse_dialog, 'button_box', ['cancel', 'ok']) self.dialog_layout.addWidget(self.button_box) self.retranslateUi(edit_verse_dialog)
class Ui_EditVerseDialog(object): def setupUi(self, editVerseDialog): editVerseDialog.setObjectName(u'editVerseDialog') editVerseDialog.resize(400, 400) editVerseDialog.setModal(True) self.dialogLayout = QtGui.QVBoxLayout(editVerseDialog) self.dialogLayout.setObjectName(u'dialog_layout') self.verseTextEdit = SpellTextEdit(editVerseDialog) self.verseTextEdit.setObjectName(u'verseTextEdit') self.dialogLayout.addWidget(self.verseTextEdit) self.verseTypeLayout = QtGui.QHBoxLayout() self.verseTypeLayout.setObjectName(u'verseTypeLayout') self.splitButton = QtGui.QPushButton(editVerseDialog) self.splitButton.setIcon(build_icon(u':/general/general_add.png')) self.splitButton.setObjectName(u'splitButton') self.verseTypeLayout.addWidget(self.splitButton) self.verseTypeLabel = QtGui.QLabel(editVerseDialog) self.verseTypeLabel.setObjectName(u'verseTypeLabel') self.verseTypeLayout.addWidget(self.verseTypeLabel) self.verseTypeComboBox = QtGui.QComboBox(editVerseDialog) self.verseTypeComboBox.addItems([u'', u'', u'', u'', u'', u'', u'']) self.verseTypeComboBox.setObjectName(u'verseTypeComboBox') self.verseTypeLabel.setBuddy(self.verseTypeComboBox) self.verseTypeLayout.addWidget(self.verseTypeComboBox) self.verseNumberBox = QtGui.QSpinBox(editVerseDialog) self.verseNumberBox.setMinimum(1) self.verseNumberBox.setObjectName(u'verseNumberBox') self.verseTypeLayout.addWidget(self.verseNumberBox) self.insertButton = QtGui.QPushButton(editVerseDialog) self.insertButton.setIcon(build_icon(u':/general/general_add.png')) self.insertButton.setObjectName(u'insertButton') self.verseTypeLayout.addWidget(self.insertButton) self.verseTypeLayout.addStretch() self.dialogLayout.addLayout(self.verseTypeLayout) self.button_box = create_button_box(editVerseDialog, u'button_box', [u'cancel', u'ok']) self.dialogLayout.addWidget(self.button_box) self.retranslateUi(editVerseDialog) def retranslateUi(self, editVerseDialog): editVerseDialog.setWindowTitle(translate('SongsPlugin.EditVerseForm', 'Edit Verse')) self.verseTypeLabel.setText(translate('SongsPlugin.EditVerseForm', '&Verse type:')) self.verseTypeComboBox.setItemText(VerseType.Verse, VerseType.TranslatedNames[VerseType.Verse]) self.verseTypeComboBox.setItemText(VerseType.Chorus, VerseType.TranslatedNames[VerseType.Chorus]) self.verseTypeComboBox.setItemText(VerseType.Bridge, VerseType.TranslatedNames[VerseType.Bridge]) self.verseTypeComboBox.setItemText(VerseType.PreChorus, VerseType.TranslatedNames[VerseType.PreChorus]) self.verseTypeComboBox.setItemText(VerseType.Intro, VerseType.TranslatedNames[VerseType.Intro]) self.verseTypeComboBox.setItemText(VerseType.Ending, VerseType.TranslatedNames[VerseType.Ending]) self.verseTypeComboBox.setItemText(VerseType.Other, VerseType.TranslatedNames[VerseType.Other]) self.splitButton.setText(UiStrings().Split) self.splitButton.setToolTip(UiStrings().SplitToolTip) self.insertButton.setText(translate('SongsPlugin.EditVerseForm', '&Insert')) self.insertButton.setToolTip(translate('SongsPlugin.EditVerseForm', 'Split a slide into two by inserting a verse splitter.'))
def setupUi(self): """ Set up the UI of the dialog """ self.setObjectName('serviceNoteEdit') self.dialog_layout = QtWidgets.QVBoxLayout(self) self.dialog_layout.setContentsMargins(8, 8, 8, 8) self.dialog_layout.setSpacing(8) self.dialog_layout.setObjectName('vertical_layout') self.text_edit = SpellTextEdit(self, False) self.text_edit.setObjectName('textEdit') self.dialog_layout.addWidget(self.text_edit) self.button_box = create_button_box(self, 'button_box', ['cancel', 'save']) self.dialog_layout.addWidget(self.button_box)
class ServiceNoteForm(QtGui.QDialog): """ This is the form that is used to edit the verses of the song. """ def __init__(self): """ Constructor """ QtGui.QDialog.__init__(self, self.main_window) self.setupUi() self.retranslateUi() def exec_(self): """ Execute the form and return the result. """ self.text_edit.setFocus() return QtGui.QDialog.exec_(self) def setupUi(self): """ Set up the UI of the dialog """ self.setObjectName(u'serviceNoteEdit') self.dialog_layout = QtGui.QVBoxLayout(self) self.dialog_layout.setContentsMargins(8, 8, 8, 8) self.dialog_layout.setSpacing(8) self.dialog_layout.setObjectName(u'verticalLayout') self.text_edit = SpellTextEdit(self, False) self.text_edit.setObjectName(u'textEdit') self.dialog_layout.addWidget(self.text_edit) self.button_box = create_button_box(self, u'button_box', [u'cancel', u'save']) self.dialog_layout.addWidget(self.button_box) def retranslateUi(self): """ Translate the UI on the fly """ self.setWindowTitle(translate('OpenLP.ServiceNoteForm', 'Service Item Notes')) def _get_main_window(self): """ Adds the main window to the class dynamically """ if not hasattr(self, u'_main_window'): self._main_window = Registry().get(u'main_window') return self._main_window main_window = property(_get_main_window)
def setupUi(self, custom_slide_edit_dialog): custom_slide_edit_dialog.setObjectName('custom_slide_edit_dialog') custom_slide_edit_dialog.setWindowIcon(build_icon(u':/icon/openlp-logo.svg')) custom_slide_edit_dialog.resize(350, 300) self.dialog_layout = QtGui.QVBoxLayout(custom_slide_edit_dialog) self.slide_text_edit = SpellTextEdit(self) self.slide_text_edit.setObjectName('slide_text_edit') self.dialog_layout.addWidget(self.slide_text_edit) self.split_button = create_button(custom_slide_edit_dialog, 'splitButton', icon=':/general/general_add.png') self.insert_button = create_button(custom_slide_edit_dialog, 'insertButton', icon=':/general/general_add.png') self.button_box = create_button_box(custom_slide_edit_dialog, 'button_box', ['cancel', 'save'], [self.split_button, self.insert_button]) self.dialog_layout.addWidget(self.button_box) self.retranslateUi(custom_slide_edit_dialog)
class ServiceNoteForm(QtGui.QDialog, RegistryProperties): """ This is the form that is used to edit the verses of the song. """ def __init__(self): """ Constructor """ super(ServiceNoteForm, self).__init__(Registry().get('main_window')) self.setupUi() self.retranslateUi() def exec_(self): """ Execute the form and return the result. """ self.text_edit.setFocus() return QtGui.QDialog.exec_(self) def setupUi(self): """ Set up the UI of the dialog """ self.setObjectName('serviceNoteEdit') self.dialog_layout = QtGui.QVBoxLayout(self) self.dialog_layout.setContentsMargins(8, 8, 8, 8) self.dialog_layout.setSpacing(8) self.dialog_layout.setObjectName('vertical_layout') self.text_edit = SpellTextEdit(self, False) self.text_edit.setObjectName('textEdit') self.dialog_layout.addWidget(self.text_edit) self.button_box = create_button_box(self, 'button_box', ['cancel', 'save']) self.dialog_layout.addWidget(self.button_box) def retranslateUi(self): """ Translate the UI on the fly """ self.setWindowTitle( translate('OpenLP.ServiceNoteForm', 'Service Item Notes'))
def setupUi(self, edit_verse_dialog): edit_verse_dialog.setObjectName('edit_verse_dialog') edit_verse_dialog.setWindowIcon(build_icon(u':/icon/openlp-logo.svg')) edit_verse_dialog.resize(400, 400) edit_verse_dialog.setModal(True) self.dialog_layout = QtGui.QVBoxLayout(edit_verse_dialog) self.dialog_layout.setObjectName('dialog_layout') self.chord_hint_label = QtGui.QLabel(edit_verse_dialog) self.chord_hint_label.setObjectName('chord_hint_label') self.dialog_layout.addWidget(self.chord_hint_label) self.verse_text_edit = SpellTextEdit(edit_verse_dialog) self.verse_text_edit.setObjectName('verse_text_edit') self.chord_font = self.verse_text_edit.document().defaultFont() self.chord_font.setFamily('Hack') self.chord_font.setStyleHint(QtGui.QFont.Courier) self.chord_font.setPointSize(9) self.verse_text_edit.document().setDefaultFont(self.chord_font) self.dialog_layout.addWidget(self.verse_text_edit) self.verse_type_layout = QtGui.QHBoxLayout() self.verse_type_layout.setObjectName('verse_type_layout') # Button to insert forced split [br] # Author: nikukatansa self.force_split_button = QtGui.QPushButton(edit_verse_dialog) self.force_split_button.setIcon(build_icon(':/general/general_add.png')) self.force_split_button.setObjectName('force_split_button') self.verse_type_layout.addWidget(self.force_split_button) # END self.split_button = QtGui.QPushButton(edit_verse_dialog) self.split_button.setIcon(build_icon(':/general/general_add.png')) self.split_button.setObjectName('split_button') self.verse_type_layout.addWidget(self.split_button) self.verse_type_label = QtGui.QLabel(edit_verse_dialog) self.verse_type_label.setObjectName('verse_type_label') self.verse_type_layout.addWidget(self.verse_type_label) self.verse_type_combo_box = QtGui.QComboBox(edit_verse_dialog) self.verse_type_combo_box.addItems(['', '', '', '', '', '', '']) self.verse_type_combo_box.setObjectName('verse_type_combo_box') self.verse_type_label.setBuddy(self.verse_type_combo_box) self.verse_type_layout.addWidget(self.verse_type_combo_box) self.verse_number_box = QtGui.QSpinBox(edit_verse_dialog) self.verse_number_box.setMinimum(1) self.verse_number_box.setObjectName('verse_number_box') self.verse_type_layout.addWidget(self.verse_number_box) self.insert_button = QtGui.QPushButton(edit_verse_dialog) self.insert_button.setIcon(build_icon(':/general/general_add.png')) self.insert_button.setObjectName('insert_button') self.verse_type_layout.addWidget(self.insert_button) self.verse_type_layout.addStretch() self.dialog_layout.addLayout(self.verse_type_layout) self.button_box = create_button_box(edit_verse_dialog, 'button_box', ['cancel', 'ok']) self.dialog_layout.addWidget(self.button_box) self.retranslateUi(edit_verse_dialog)
class Ui_CustomSlideEditDialog(object): def setupUi(self, customSlideEditDialog): customSlideEditDialog.setObjectName(u'customSlideEditDialog') customSlideEditDialog.resize(350, 300) self.dialogLayout = QtGui.QVBoxLayout(customSlideEditDialog) self.slideTextEdit = SpellTextEdit(self) self.slideTextEdit.setObjectName(u'slideTextEdit') self.dialogLayout.addWidget(self.slideTextEdit) self.splitButton = create_button(customSlideEditDialog, u'splitButton', icon=u':/general/general_add.png') self.insertButton = create_button(customSlideEditDialog, u'insertButton', icon=u':/general/general_add.png') self.button_box = create_button_box(customSlideEditDialog, u'button_box', [u'cancel', u'save'], [self.splitButton, self.insertButton]) self.dialogLayout.addWidget(self.button_box) self.retranslateUi(customSlideEditDialog) def retranslateUi(self, customSlideEditDialog): customSlideEditDialog.setWindowTitle(translate('CustomPlugin.EditVerseForm', 'Edit Slide')) self.splitButton.setText(UiStrings().Split) self.splitButton.setToolTip(UiStrings().SplitToolTip) self.insertButton.setText(translate('CustomPlugin.EditCustomForm', 'Insert Slide')) self.insertButton.setToolTip(translate('CustomPlugin.EditCustomForm', 'Split a slide into two by inserting a slide splitter.'))
class ServiceNoteForm(QtGui.QDialog, RegistryProperties): """ This is the form that is used to edit the verses of the song. """ def __init__(self): """ Constructor """ super(ServiceNoteForm, self).__init__(Registry().get('main_window')) self.setupUi() self.retranslateUi() def exec_(self): """ Execute the form and return the result. """ self.text_edit.setFocus() return QtGui.QDialog.exec_(self) def setupUi(self): """ Set up the UI of the dialog """ self.setObjectName('serviceNoteEdit') self.dialog_layout = QtGui.QVBoxLayout(self) self.dialog_layout.setContentsMargins(8, 8, 8, 8) self.dialog_layout.setSpacing(8) self.dialog_layout.setObjectName('vertical_layout') self.text_edit = SpellTextEdit(self, False) self.text_edit.setObjectName('textEdit') self.dialog_layout.addWidget(self.text_edit) self.button_box = create_button_box(self, 'button_box', ['cancel', 'save']) self.dialog_layout.addWidget(self.button_box) def retranslateUi(self): """ Translate the UI on the fly """ self.setWindowTitle(translate('OpenLP.ServiceNoteForm', 'Service Item Notes'))
def setupUi(self, customSlideEditDialog): customSlideEditDialog.setObjectName(u'customSlideEditDialog') customSlideEditDialog.resize(350, 300) self.dialogLayout = QtGui.QVBoxLayout(customSlideEditDialog) self.slideTextEdit = SpellTextEdit(self) self.slideTextEdit.setObjectName(u'slideTextEdit') self.dialogLayout.addWidget(self.slideTextEdit) self.splitButton = create_button(customSlideEditDialog, u'splitButton', icon=u':/general/general_add.png') self.insertButton = create_button(customSlideEditDialog, u'insertButton', icon=u':/general/general_add.png') self.button_box = create_button_box(customSlideEditDialog, u'button_box', [u'cancel', u'save'], [self.splitButton, self.insertButton]) self.dialogLayout.addWidget(self.button_box) self.retranslateUi(customSlideEditDialog)
def setupUi(self, edit_verse_dialog): edit_verse_dialog.setObjectName('edit_verse_dialog') edit_verse_dialog.setWindowIcon(build_icon(u':/icon/openlp-logo.svg')) edit_verse_dialog.resize(400, 400) edit_verse_dialog.setModal(True) self.dialog_layout = QtWidgets.QVBoxLayout(edit_verse_dialog) self.dialog_layout.setObjectName('dialog_layout') self.verse_text_edit = SpellTextEdit(edit_verse_dialog) self.verse_text_edit.setObjectName('verse_text_edit') self.dialog_layout.addWidget(self.verse_text_edit) self.verse_type_layout = QtWidgets.QHBoxLayout() self.verse_type_layout.setObjectName('verse_type_layout') self.split_button = QtWidgets.QPushButton(edit_verse_dialog) self.split_button.setIcon(build_icon(':/general/general_add.png')) self.split_button.setObjectName('split_button') self.verse_type_layout.addWidget(self.split_button) self.verse_type_label = QtWidgets.QLabel(edit_verse_dialog) self.verse_type_label.setObjectName('verse_type_label') self.verse_type_layout.addWidget(self.verse_type_label) self.verse_type_combo_box = QtWidgets.QComboBox(edit_verse_dialog) self.verse_type_combo_box.addItems(['', '', '', '', '', '', '']) self.verse_type_combo_box.setObjectName('verse_type_combo_box') self.verse_type_label.setBuddy(self.verse_type_combo_box) self.verse_type_layout.addWidget(self.verse_type_combo_box) self.verse_number_box = QtWidgets.QSpinBox(edit_verse_dialog) self.verse_number_box.setMinimum(1) self.verse_number_box.setObjectName('verse_number_box') self.verse_type_layout.addWidget(self.verse_number_box) self.insert_button = QtWidgets.QPushButton(edit_verse_dialog) self.insert_button.setIcon(build_icon(':/general/general_add.png')) self.insert_button.setObjectName('insert_button') self.verse_type_layout.addWidget(self.insert_button) self.verse_type_layout.addStretch() self.dialog_layout.addLayout(self.verse_type_layout) self.button_box = create_button_box(edit_verse_dialog, 'button_box', ['cancel', 'ok']) self.dialog_layout.addWidget(self.button_box) self.retranslateUi(edit_verse_dialog)
def setupUi(self): """ Set up the UI of the dialog """ self.setObjectName(u'serviceNoteEdit') self.dialog_layout = QtGui.QVBoxLayout(self) self.dialog_layout.setContentsMargins(8, 8, 8, 8) self.dialog_layout.setSpacing(8) self.dialog_layout.setObjectName(u'verticalLayout') self.text_edit = SpellTextEdit(self, False) self.text_edit.setObjectName(u'textEdit') self.dialog_layout.addWidget(self.text_edit) self.button_box = create_button_box(self, u'button_box', [u'cancel', u'save']) self.dialog_layout.addWidget(self.button_box)
def setupUi(self, edit_verse_dialog): edit_verse_dialog.setObjectName('edit_verse_dialog') edit_verse_dialog.resize(400, 400) edit_verse_dialog.setModal(True) self.dialog_layout = QtGui.QVBoxLayout(edit_verse_dialog) self.dialog_layout.setObjectName('dialog_layout') self.verse_text_edit = SpellTextEdit(edit_verse_dialog) self.verse_text_edit.setObjectName('verse_text_edit') self.dialog_layout.addWidget(self.verse_text_edit) self.verse_type_layout = QtGui.QHBoxLayout() self.verse_type_layout.setObjectName('verse_type_layout') self.split_button = QtGui.QPushButton(edit_verse_dialog) self.split_button.setIcon(build_icon(':/general/general_add.png')) self.split_button.setObjectName('split_button') self.verse_type_layout.addWidget(self.split_button) self.verse_type_label = QtGui.QLabel(edit_verse_dialog) self.verse_type_label.setObjectName('verse_type_label') self.verse_type_layout.addWidget(self.verse_type_label) self.verse_type_combo_box = QtGui.QComboBox(edit_verse_dialog) self.verse_type_combo_box.addItems(['', '', '', '', '', '', '']) self.verse_type_combo_box.setObjectName('verse_type_combo_box') self.verse_type_label.setBuddy(self.verse_type_combo_box) self.verse_type_layout.addWidget(self.verse_type_combo_box) self.verse_number_box = QtGui.QSpinBox(edit_verse_dialog) self.verse_number_box.setMinimum(1) self.verse_number_box.setObjectName('verse_number_box') self.verse_type_layout.addWidget(self.verse_number_box) self.insert_button = QtGui.QPushButton(edit_verse_dialog) self.insert_button.setIcon(build_icon(':/general/general_add.png')) self.insert_button.setObjectName('insert_button') self.verse_type_layout.addWidget(self.insert_button) self.verse_type_layout.addStretch() self.dialog_layout.addLayout(self.verse_type_layout) self.button_box = create_button_box(edit_verse_dialog, 'button_box', ['cancel', 'ok']) self.dialog_layout.addWidget(self.button_box) self.retranslateUi(edit_verse_dialog)
def setupUi(self, editVerseDialog): editVerseDialog.setObjectName(u'editVerseDialog') editVerseDialog.resize(400, 400) editVerseDialog.setModal(True) self.dialogLayout = QtGui.QVBoxLayout(editVerseDialog) self.dialogLayout.setObjectName(u'dialog_layout') self.verseTextEdit = SpellTextEdit(editVerseDialog) self.verseTextEdit.setObjectName(u'verseTextEdit') self.dialogLayout.addWidget(self.verseTextEdit) self.verseTypeLayout = QtGui.QHBoxLayout() self.verseTypeLayout.setObjectName(u'verseTypeLayout') self.splitButton = QtGui.QPushButton(editVerseDialog) self.splitButton.setIcon(build_icon(u':/general/general_add.png')) self.splitButton.setObjectName(u'splitButton') self.verseTypeLayout.addWidget(self.splitButton) self.verseTypeLabel = QtGui.QLabel(editVerseDialog) self.verseTypeLabel.setObjectName(u'verseTypeLabel') self.verseTypeLayout.addWidget(self.verseTypeLabel) self.verseTypeComboBox = QtGui.QComboBox(editVerseDialog) self.verseTypeComboBox.addItems([u'', u'', u'', u'', u'', u'', u'']) self.verseTypeComboBox.setObjectName(u'verseTypeComboBox') self.verseTypeLabel.setBuddy(self.verseTypeComboBox) self.verseTypeLayout.addWidget(self.verseTypeComboBox) self.verseNumberBox = QtGui.QSpinBox(editVerseDialog) self.verseNumberBox.setMinimum(1) self.verseNumberBox.setObjectName(u'verseNumberBox') self.verseTypeLayout.addWidget(self.verseNumberBox) self.insertButton = QtGui.QPushButton(editVerseDialog) self.insertButton.setIcon(build_icon(u':/general/general_add.png')) self.insertButton.setObjectName(u'insertButton') self.verseTypeLayout.addWidget(self.insertButton) self.verseTypeLayout.addStretch() self.dialogLayout.addLayout(self.verseTypeLayout) self.button_box = create_button_box(editVerseDialog, u'button_box', [u'cancel', u'ok']) self.dialogLayout.addWidget(self.button_box) self.retranslateUi(editVerseDialog)
def setupUi(self, print_service_dialog): """ Set up the UI """ print_service_dialog.setObjectName('print_service_dialog') print_service_dialog.setWindowIcon( build_icon(u':/icon/openlp-logo.svg')) print_service_dialog.resize(664, 594) self.main_layout = QtGui.QVBoxLayout(print_service_dialog) self.main_layout.setSpacing(0) self.main_layout.setMargin(0) self.main_layout.setObjectName('main_layout') self.toolbar = QtGui.QToolBar(print_service_dialog) self.toolbar.setIconSize(QtCore.QSize(22, 22)) self.toolbar.setToolButtonStyle(QtCore.Qt.ToolButtonTextBesideIcon) self.print_button = self.toolbar.addAction( build_icon(':/general/general_print.png'), translate('OpenLP.PrintServiceForm', 'Print')) self.options_button = QtGui.QToolButton(self.toolbar) self.options_button.setToolButtonStyle( QtCore.Qt.ToolButtonTextBesideIcon) self.options_button.setIcon( build_icon(':/system/system_configure.png')) self.options_button.setCheckable(True) self.toolbar.addWidget(self.options_button) self.toolbar.addSeparator() self.plain_copy = self.toolbar.addAction( build_icon(':/system/system_edit_copy.png'), translate('OpenLP.PrintServiceForm', 'Copy')) self.html_copy = self.toolbar.addAction( build_icon(':/system/system_edit_copy.png'), translate('OpenLP.PrintServiceForm', 'Copy as HTML')) self.toolbar.addSeparator() self.zoom_in_button = QtGui.QToolButton(self.toolbar) self.zoom_in_button.setIcon( build_icon(':/general/general_zoom_in.png')) self.zoom_in_button.setObjectName('zoom_in_button') self.zoom_in_button.setIconSize(QtCore.QSize(22, 22)) self.toolbar.addWidget(self.zoom_in_button) self.zoom_out_button = QtGui.QToolButton(self.toolbar) self.zoom_out_button.setIcon( build_icon(':/general/general_zoom_out.png')) self.zoom_out_button.setObjectName('zoom_out_button') self.zoom_out_button.setIconSize(QtCore.QSize(22, 22)) self.toolbar.addWidget(self.zoom_out_button) self.zoom_original_button = QtGui.QToolButton(self.toolbar) self.zoom_original_button.setIcon( build_icon(':/general/general_zoom_original.png')) self.zoom_original_button.setObjectName('zoom_original_button') self.zoom_original_button.setIconSize(QtCore.QSize(22, 22)) self.toolbar.addWidget(self.zoom_original_button) self.zoom_combo_box = QtGui.QComboBox(print_service_dialog) self.zoom_combo_box.setObjectName('zoom_combo_box') self.toolbar.addWidget(self.zoom_combo_box) self.main_layout.addWidget(self.toolbar) self.preview_widget = QtGui.QPrintPreviewWidget(print_service_dialog) self.main_layout.addWidget(self.preview_widget) self.options_widget = QtGui.QWidget(print_service_dialog) self.options_widget.hide() self.options_widget.resize(400, 300) self.options_widget.setAutoFillBackground(True) self.options_layout = QtGui.QVBoxLayout(self.options_widget) self.options_layout.setContentsMargins(8, 8, 8, 8) self.title_label = QtGui.QLabel(self.options_widget) self.title_label.setObjectName('title_label') self.options_layout.addWidget(self.title_label) self.title_line_edit = QtGui.QLineEdit(self.options_widget) self.title_line_edit.setObjectName('title_line_edit') self.options_layout.addWidget(self.title_line_edit) self.footer_label = QtGui.QLabel(self.options_widget) self.footer_label.setObjectName('footer_label') self.options_layout.addWidget(self.footer_label) self.footer_text_edit = SpellTextEdit(self.options_widget, False) self.footer_text_edit.setObjectName('footer_text_edit') self.options_layout.addWidget(self.footer_text_edit) self.options_group_box = QtGui.QGroupBox() self.group_layout = QtGui.QVBoxLayout() self.slide_text_check_box = QtGui.QCheckBox() self.group_layout.addWidget(self.slide_text_check_box) self.page_break_after_text = QtGui.QCheckBox() self.group_layout.addWidget(self.page_break_after_text) self.notes_check_box = QtGui.QCheckBox() self.group_layout.addWidget(self.notes_check_box) self.meta_data_check_box = QtGui.QCheckBox() self.group_layout.addWidget(self.meta_data_check_box) self.group_layout.addStretch(1) self.options_group_box.setLayout(self.group_layout) self.options_layout.addWidget(self.options_group_box) self.retranslateUi(print_service_dialog) self.options_button.toggled.connect(self.toggle_options)
def setupUi(self, print_service_dialog): """ Set up the UI """ print_service_dialog.setObjectName('print_service_dialog') print_service_dialog.setWindowIcon(build_icon(u':/icon/openlp-logo.svg')) print_service_dialog.resize(664, 594) self.main_layout = QtGui.QVBoxLayout(print_service_dialog) self.main_layout.setSpacing(0) self.main_layout.setMargin(0) self.main_layout.setObjectName('main_layout') self.toolbar = QtGui.QToolBar(print_service_dialog) self.toolbar.setIconSize(QtCore.QSize(22, 22)) self.toolbar.setToolButtonStyle(QtCore.Qt.ToolButtonTextBesideIcon) self.print_button = self.toolbar.addAction(build_icon(':/general/general_print.png'), translate('OpenLP.PrintServiceForm', 'Print')) self.options_button = QtGui.QToolButton(self.toolbar) self.options_button.setToolButtonStyle(QtCore.Qt.ToolButtonTextBesideIcon) self.options_button.setIcon(build_icon(':/system/system_configure.png')) self.options_button.setCheckable(True) self.toolbar.addWidget(self.options_button) self.toolbar.addSeparator() self.plain_copy = self.toolbar.addAction(build_icon(':/system/system_edit_copy.png'), translate('OpenLP.PrintServiceForm', 'Copy')) self.html_copy = self.toolbar.addAction(build_icon(':/system/system_edit_copy.png'), translate('OpenLP.PrintServiceForm', 'Copy as HTML')) self.toolbar.addSeparator() self.zoom_in_button = QtGui.QToolButton(self.toolbar) self.zoom_in_button.setIcon(build_icon(':/general/general_zoom_in.png')) self.zoom_in_button.setObjectName('zoom_in_button') self.zoom_in_button.setIconSize(QtCore.QSize(22, 22)) self.toolbar.addWidget(self.zoom_in_button) self.zoom_out_button = QtGui.QToolButton(self.toolbar) self.zoom_out_button.setIcon(build_icon(':/general/general_zoom_out.png')) self.zoom_out_button.setObjectName('zoom_out_button') self.zoom_out_button.setIconSize(QtCore.QSize(22, 22)) self.toolbar.addWidget(self.zoom_out_button) self.zoom_original_button = QtGui.QToolButton(self.toolbar) self.zoom_original_button.setIcon(build_icon(':/general/general_zoom_original.png')) self.zoom_original_button.setObjectName('zoom_original_button') self.zoom_original_button.setIconSize(QtCore.QSize(22, 22)) self.toolbar.addWidget(self.zoom_original_button) self.zoom_combo_box = QtGui.QComboBox(print_service_dialog) self.zoom_combo_box.setObjectName('zoom_combo_box') self.toolbar.addWidget(self.zoom_combo_box) self.main_layout.addWidget(self.toolbar) self.preview_widget = QtGui.QPrintPreviewWidget(print_service_dialog) self.main_layout.addWidget(self.preview_widget) self.options_widget = QtGui.QWidget(print_service_dialog) self.options_widget.hide() self.options_widget.resize(400, 300) self.options_widget.setAutoFillBackground(True) self.options_layout = QtGui.QVBoxLayout(self.options_widget) self.options_layout.setContentsMargins(8, 8, 8, 8) self.title_label = QtGui.QLabel(self.options_widget) self.title_label.setObjectName('title_label') self.options_layout.addWidget(self.title_label) self.title_line_edit = QtGui.QLineEdit(self.options_widget) self.title_line_edit.setObjectName('title_line_edit') self.options_layout.addWidget(self.title_line_edit) self.footer_label = QtGui.QLabel(self.options_widget) self.footer_label.setObjectName('footer_label') self.options_layout.addWidget(self.footer_label) self.footer_text_edit = SpellTextEdit(self.options_widget, False) self.footer_text_edit.setObjectName('footer_text_edit') self.options_layout.addWidget(self.footer_text_edit) self.options_group_box = QtGui.QGroupBox() self.group_layout = QtGui.QVBoxLayout() self.slide_text_check_box = QtGui.QCheckBox() self.group_layout.addWidget(self.slide_text_check_box) self.page_break_after_text = QtGui.QCheckBox() self.group_layout.addWidget(self.page_break_after_text) self.notes_check_box = QtGui.QCheckBox() self.group_layout.addWidget(self.notes_check_box) self.meta_data_check_box = QtGui.QCheckBox() self.group_layout.addWidget(self.meta_data_check_box) self.group_layout.addStretch(1) self.options_group_box.setLayout(self.group_layout) self.options_layout.addWidget(self.options_group_box) self.retranslateUi(print_service_dialog) self.options_button.toggled.connect(self.toggle_options)
class Ui_EditVerseDialog(object): def setupUi(self, edit_verse_dialog): edit_verse_dialog.setObjectName('edit_verse_dialog') edit_verse_dialog.setWindowIcon(build_icon(u':/icon/openlp-logo.svg')) edit_verse_dialog.resize(400, 400) edit_verse_dialog.setModal(True) self.dialog_layout = QtWidgets.QVBoxLayout(edit_verse_dialog) self.dialog_layout.setObjectName('dialog_layout') self.verse_text_edit = SpellTextEdit(edit_verse_dialog) self.verse_text_edit.setObjectName('verse_text_edit') self.dialog_layout.addWidget(self.verse_text_edit) self.verse_type_layout = QtWidgets.QHBoxLayout() self.verse_type_layout.setObjectName('verse_type_layout') self.split_button = QtWidgets.QPushButton(edit_verse_dialog) self.split_button.setIcon(build_icon(':/general/general_add.png')) self.split_button.setObjectName('split_button') self.verse_type_layout.addWidget(self.split_button) self.verse_type_label = QtWidgets.QLabel(edit_verse_dialog) self.verse_type_label.setObjectName('verse_type_label') self.verse_type_layout.addWidget(self.verse_type_label) self.verse_type_combo_box = QtWidgets.QComboBox(edit_verse_dialog) self.verse_type_combo_box.addItems(['', '', '', '', '', '', '']) self.verse_type_combo_box.setObjectName('verse_type_combo_box') self.verse_type_label.setBuddy(self.verse_type_combo_box) self.verse_type_layout.addWidget(self.verse_type_combo_box) self.verse_number_box = QtWidgets.QSpinBox(edit_verse_dialog) self.verse_number_box.setMinimum(1) self.verse_number_box.setObjectName('verse_number_box') self.verse_type_layout.addWidget(self.verse_number_box) self.insert_button = QtWidgets.QPushButton(edit_verse_dialog) self.insert_button.setIcon(build_icon(':/general/general_add.png')) self.insert_button.setObjectName('insert_button') self.verse_type_layout.addWidget(self.insert_button) self.verse_type_layout.addStretch() self.dialog_layout.addLayout(self.verse_type_layout) self.button_box = create_button_box(edit_verse_dialog, 'button_box', ['cancel', 'ok']) self.dialog_layout.addWidget(self.button_box) self.retranslateUi(edit_verse_dialog) def retranslateUi(self, edit_verse_dialog): edit_verse_dialog.setWindowTitle( translate('SongsPlugin.EditVerseForm', 'Edit Verse')) self.verse_type_label.setText( translate('SongsPlugin.EditVerseForm', '&Verse type:')) self.verse_type_combo_box.setItemText( VerseType.Verse, VerseType.translated_names[VerseType.Verse]) self.verse_type_combo_box.setItemText( VerseType.Chorus, VerseType.translated_names[VerseType.Chorus]) self.verse_type_combo_box.setItemText( VerseType.Bridge, VerseType.translated_names[VerseType.Bridge]) self.verse_type_combo_box.setItemText( VerseType.PreChorus, VerseType.translated_names[VerseType.PreChorus]) self.verse_type_combo_box.setItemText( VerseType.Intro, VerseType.translated_names[VerseType.Intro]) self.verse_type_combo_box.setItemText( VerseType.Ending, VerseType.translated_names[VerseType.Ending]) self.verse_type_combo_box.setItemText( VerseType.Other, VerseType.translated_names[VerseType.Other]) self.split_button.setText(UiStrings().Split) self.split_button.setToolTip(UiStrings().SplitToolTip) self.insert_button.setText( translate('SongsPlugin.EditVerseForm', '&Insert')) self.insert_button.setToolTip( translate('SongsPlugin.EditVerseForm', 'Split a slide into two by inserting a verse splitter.'))
class Ui_EditVerseChordsDialog(object): def setupUi(self, edit_verse_dialog): edit_verse_dialog.setObjectName('edit_verse_dialog') edit_verse_dialog.setWindowIcon(build_icon(u':/icon/openlp-logo.svg')) edit_verse_dialog.resize(400, 400) edit_verse_dialog.setModal(True) self.dialog_layout = QtGui.QVBoxLayout(edit_verse_dialog) self.dialog_layout.setObjectName('dialog_layout') self.chord_hint_label = QtGui.QLabel(edit_verse_dialog) self.chord_hint_label.setObjectName('chord_hint_label') self.dialog_layout.addWidget(self.chord_hint_label) self.verse_text_edit = SpellTextEdit(edit_verse_dialog) self.verse_text_edit.setObjectName('verse_text_edit') self.chord_font = self.verse_text_edit.document().defaultFont() self.chord_font.setFamily('Hack') self.chord_font.setStyleHint(QtGui.QFont.Courier) self.chord_font.setPointSize(9) self.verse_text_edit.document().setDefaultFont(self.chord_font) self.dialog_layout.addWidget(self.verse_text_edit) self.verse_type_layout = QtGui.QHBoxLayout() self.verse_type_layout.setObjectName('verse_type_layout') # Button to insert forced split [br] # Author: nikukatansa self.force_split_button = QtGui.QPushButton(edit_verse_dialog) self.force_split_button.setIcon( build_icon(':/general/general_add.png')) self.force_split_button.setObjectName('force_split_button') self.verse_type_layout.addWidget(self.force_split_button) # END self.split_button = QtGui.QPushButton(edit_verse_dialog) self.split_button.setIcon(build_icon(':/general/general_add.png')) self.split_button.setObjectName('split_button') self.verse_type_layout.addWidget(self.split_button) self.verse_type_label = QtGui.QLabel(edit_verse_dialog) self.verse_type_label.setObjectName('verse_type_label') self.verse_type_layout.addWidget(self.verse_type_label) self.verse_type_combo_box = QtGui.QComboBox(edit_verse_dialog) self.verse_type_combo_box.addItems(['', '', '', '', '', '', '']) self.verse_type_combo_box.setObjectName('verse_type_combo_box') self.verse_type_label.setBuddy(self.verse_type_combo_box) self.verse_type_layout.addWidget(self.verse_type_combo_box) self.verse_number_box = QtGui.QSpinBox(edit_verse_dialog) self.verse_number_box.setMinimum(1) self.verse_number_box.setObjectName('verse_number_box') self.verse_type_layout.addWidget(self.verse_number_box) self.insert_button = QtGui.QPushButton(edit_verse_dialog) self.insert_button.setIcon(build_icon(':/general/general_add.png')) self.insert_button.setObjectName('insert_button') self.verse_type_layout.addWidget(self.insert_button) self.verse_type_layout.addStretch() self.dialog_layout.addLayout(self.verse_type_layout) self.button_box = create_button_box(edit_verse_dialog, 'button_box', ['cancel', 'ok']) self.dialog_layout.addWidget(self.button_box) self.retranslateUi(edit_verse_dialog) def retranslateUi(self, edit_verse_dialog): edit_verse_dialog.setWindowTitle( translate('SongsPlugin.EditVerseChordsForm', 'Edit Verse and Chords')) self.chord_hint_label.setText( translate( 'SongsPlugin.EditVerseChordsForm', 'Chord lines must finish with an @ and be put on the line above the corresponding lyrics.\nTo pad out lyrics to fit the chords use the # symbol.' )) self.verse_type_label.setText( translate('SongsPlugin.EditVerseChordsForm', '&Verse type:')) self.verse_type_combo_box.setItemText( VerseType.Verse, VerseType.translated_names[VerseType.Verse]) self.verse_type_combo_box.setItemText( VerseType.Chorus, VerseType.translated_names[VerseType.Chorus]) self.verse_type_combo_box.setItemText( VerseType.Bridge, VerseType.translated_names[VerseType.Bridge]) self.verse_type_combo_box.setItemText( VerseType.PreChorus, VerseType.translated_names[VerseType.PreChorus]) self.verse_type_combo_box.setItemText( VerseType.Intro, VerseType.translated_names[VerseType.Intro]) self.verse_type_combo_box.setItemText( VerseType.Ending, VerseType.translated_names[VerseType.Ending]) self.verse_type_combo_box.setItemText( VerseType.Other, VerseType.translated_names[VerseType.Other]) self.split_button.setText(UiStrings().Split) self.split_button.setToolTip(UiStrings().SplitToolTip) self.force_split_button.setText(UiStrings().ForcedSplit) self.force_split_button.setToolTip(UiStrings().ForcedSplitToolTip) self.insert_button.setText( translate('SongsPlugin.EditVerseChordsForm', '&Insert')) self.insert_button.setToolTip( translate('SongsPlugin.EditVerseChordsForm', 'Split a slide into two by inserting a verse splitter.'))
class Ui_PrintServiceDialog(object): """ The UI of the print service dialog """ def setupUi(self, print_service_dialog): """ Set up the UI """ print_service_dialog.setObjectName('print_service_dialog') print_service_dialog.setWindowIcon( build_icon(u':/icon/openlp-logo.svg')) print_service_dialog.resize(664, 594) self.main_layout = QtGui.QVBoxLayout(print_service_dialog) self.main_layout.setSpacing(0) self.main_layout.setMargin(0) self.main_layout.setObjectName('main_layout') self.toolbar = QtGui.QToolBar(print_service_dialog) self.toolbar.setIconSize(QtCore.QSize(22, 22)) self.toolbar.setToolButtonStyle(QtCore.Qt.ToolButtonTextBesideIcon) self.print_button = self.toolbar.addAction( build_icon(':/general/general_print.png'), translate('OpenLP.PrintServiceForm', 'Print')) self.options_button = QtGui.QToolButton(self.toolbar) self.options_button.setToolButtonStyle( QtCore.Qt.ToolButtonTextBesideIcon) self.options_button.setIcon( build_icon(':/system/system_configure.png')) self.options_button.setCheckable(True) self.toolbar.addWidget(self.options_button) self.toolbar.addSeparator() self.plain_copy = self.toolbar.addAction( build_icon(':/system/system_edit_copy.png'), translate('OpenLP.PrintServiceForm', 'Copy')) self.html_copy = self.toolbar.addAction( build_icon(':/system/system_edit_copy.png'), translate('OpenLP.PrintServiceForm', 'Copy as HTML')) self.toolbar.addSeparator() self.zoom_in_button = QtGui.QToolButton(self.toolbar) self.zoom_in_button.setIcon( build_icon(':/general/general_zoom_in.png')) self.zoom_in_button.setObjectName('zoom_in_button') self.zoom_in_button.setIconSize(QtCore.QSize(22, 22)) self.toolbar.addWidget(self.zoom_in_button) self.zoom_out_button = QtGui.QToolButton(self.toolbar) self.zoom_out_button.setIcon( build_icon(':/general/general_zoom_out.png')) self.zoom_out_button.setObjectName('zoom_out_button') self.zoom_out_button.setIconSize(QtCore.QSize(22, 22)) self.toolbar.addWidget(self.zoom_out_button) self.zoom_original_button = QtGui.QToolButton(self.toolbar) self.zoom_original_button.setIcon( build_icon(':/general/general_zoom_original.png')) self.zoom_original_button.setObjectName('zoom_original_button') self.zoom_original_button.setIconSize(QtCore.QSize(22, 22)) self.toolbar.addWidget(self.zoom_original_button) self.zoom_combo_box = QtGui.QComboBox(print_service_dialog) self.zoom_combo_box.setObjectName('zoom_combo_box') self.toolbar.addWidget(self.zoom_combo_box) self.main_layout.addWidget(self.toolbar) self.preview_widget = QtGui.QPrintPreviewWidget(print_service_dialog) self.main_layout.addWidget(self.preview_widget) self.options_widget = QtGui.QWidget(print_service_dialog) self.options_widget.hide() self.options_widget.resize(400, 300) self.options_widget.setAutoFillBackground(True) self.options_layout = QtGui.QVBoxLayout(self.options_widget) self.options_layout.setContentsMargins(8, 8, 8, 8) self.title_label = QtGui.QLabel(self.options_widget) self.title_label.setObjectName('title_label') self.options_layout.addWidget(self.title_label) self.title_line_edit = QtGui.QLineEdit(self.options_widget) self.title_line_edit.setObjectName('title_line_edit') self.options_layout.addWidget(self.title_line_edit) self.footer_label = QtGui.QLabel(self.options_widget) self.footer_label.setObjectName('footer_label') self.options_layout.addWidget(self.footer_label) self.footer_text_edit = SpellTextEdit(self.options_widget, False) self.footer_text_edit.setObjectName('footer_text_edit') self.options_layout.addWidget(self.footer_text_edit) self.options_group_box = QtGui.QGroupBox() self.group_layout = QtGui.QVBoxLayout() self.slide_text_check_box = QtGui.QCheckBox() self.group_layout.addWidget(self.slide_text_check_box) self.page_break_after_text = QtGui.QCheckBox() self.group_layout.addWidget(self.page_break_after_text) self.notes_check_box = QtGui.QCheckBox() self.group_layout.addWidget(self.notes_check_box) self.meta_data_check_box = QtGui.QCheckBox() self.group_layout.addWidget(self.meta_data_check_box) self.group_layout.addStretch(1) self.options_group_box.setLayout(self.group_layout) self.options_layout.addWidget(self.options_group_box) self.retranslateUi(print_service_dialog) self.options_button.toggled.connect(self.toggle_options) def retranslateUi(self, print_service_dialog): """ Translate the UI on the fly """ print_service_dialog.setWindowTitle(UiStrings().PrintService) self.zoom_out_button.setToolTip( translate('OpenLP.PrintServiceForm', 'Zoom Out')) self.zoom_original_button.setToolTip( translate('OpenLP.PrintServiceForm', 'Zoom Original')) self.zoom_in_button.setToolTip( translate('OpenLP.PrintServiceForm', 'Zoom In')) self.options_button.setText( translate('OpenLP.PrintServiceForm', 'Options')) self.title_label.setText(translate('OpenLP.PrintServiceForm', 'Title:')) self.footer_label.setText( translate('OpenLP.PrintServiceForm', 'Custom Footer Text:')) self.options_group_box.setTitle( translate('OpenLP.PrintServiceForm', 'Other Options')) self.slide_text_check_box.setText( translate('OpenLP.PrintServiceForm', 'Include slide text if available')) self.page_break_after_text.setText( translate('OpenLP.PrintServiceForm', 'Add page break before each text item')) self.notes_check_box.setText( translate('OpenLP.PrintServiceForm', 'Include service item notes')) self.meta_data_check_box.setText( translate('OpenLP.PrintServiceForm', 'Include play length of media items')) self.title_line_edit.setText( translate('OpenLP.PrintServiceForm', 'Service Sheet')) # Do not change the order. self.zoom_combo_box.addItems([ translate('OpenLP.PrintServiceDialog', 'Fit Page'), translate('OpenLP.PrintServiceDialog', 'Fit Width'), '100%', '75%', '50%', '25%' ])
class Ui_EditVerseChordsDialog(object): def setupUi(self, edit_verse_dialog): edit_verse_dialog.setObjectName('edit_verse_dialog') edit_verse_dialog.setWindowIcon(build_icon(u':/icon/openlp-logo.svg')) edit_verse_dialog.resize(400, 400) edit_verse_dialog.setModal(True) self.dialog_layout = QtGui.QVBoxLayout(edit_verse_dialog) self.dialog_layout.setObjectName('dialog_layout') self.chord_hint_label = QtGui.QLabel(edit_verse_dialog) self.chord_hint_label.setObjectName('chord_hint_label') self.dialog_layout.addWidget(self.chord_hint_label) self.verse_text_edit = SpellTextEdit(edit_verse_dialog) self.verse_text_edit.setObjectName('verse_text_edit') self.chord_font = self.verse_text_edit.document().defaultFont() self.chord_font.setFamily('Hack') self.chord_font.setStyleHint(QtGui.QFont.Courier) self.chord_font.setPointSize(9) self.verse_text_edit.document().setDefaultFont(self.chord_font) self.dialog_layout.addWidget(self.verse_text_edit) self.verse_type_layout = QtGui.QHBoxLayout() self.verse_type_layout.setObjectName('verse_type_layout') # Button to insert forced split [br] # Author: nikukatansa self.force_split_button = QtGui.QPushButton(edit_verse_dialog) self.force_split_button.setIcon(build_icon(':/general/general_add.png')) self.force_split_button.setObjectName('force_split_button') self.verse_type_layout.addWidget(self.force_split_button) # END self.split_button = QtGui.QPushButton(edit_verse_dialog) self.split_button.setIcon(build_icon(':/general/general_add.png')) self.split_button.setObjectName('split_button') self.verse_type_layout.addWidget(self.split_button) self.verse_type_label = QtGui.QLabel(edit_verse_dialog) self.verse_type_label.setObjectName('verse_type_label') self.verse_type_layout.addWidget(self.verse_type_label) self.verse_type_combo_box = QtGui.QComboBox(edit_verse_dialog) self.verse_type_combo_box.addItems(['', '', '', '', '', '', '']) self.verse_type_combo_box.setObjectName('verse_type_combo_box') self.verse_type_label.setBuddy(self.verse_type_combo_box) self.verse_type_layout.addWidget(self.verse_type_combo_box) self.verse_number_box = QtGui.QSpinBox(edit_verse_dialog) self.verse_number_box.setMinimum(1) self.verse_number_box.setObjectName('verse_number_box') self.verse_type_layout.addWidget(self.verse_number_box) self.insert_button = QtGui.QPushButton(edit_verse_dialog) self.insert_button.setIcon(build_icon(':/general/general_add.png')) self.insert_button.setObjectName('insert_button') self.verse_type_layout.addWidget(self.insert_button) self.verse_type_layout.addStretch() self.dialog_layout.addLayout(self.verse_type_layout) self.button_box = create_button_box(edit_verse_dialog, 'button_box', ['cancel', 'ok']) self.dialog_layout.addWidget(self.button_box) self.retranslateUi(edit_verse_dialog) def retranslateUi(self, edit_verse_dialog): edit_verse_dialog.setWindowTitle(translate('SongsPlugin.EditVerseChordsForm', 'Edit Verse and Chords')) self.chord_hint_label.setText(translate('SongsPlugin.EditVerseChordsForm', 'Chord lines must finish with an @ and be put on the line above the corresponding lyrics.\nTo pad out lyrics to fit the chords use the # symbol.')) self.verse_type_label.setText(translate('SongsPlugin.EditVerseChordsForm', '&Verse type:')) self.verse_type_combo_box.setItemText(VerseType.Verse, VerseType.translated_names[VerseType.Verse]) self.verse_type_combo_box.setItemText(VerseType.Chorus, VerseType.translated_names[VerseType.Chorus]) self.verse_type_combo_box.setItemText(VerseType.Bridge, VerseType.translated_names[VerseType.Bridge]) self.verse_type_combo_box.setItemText(VerseType.PreChorus, VerseType.translated_names[VerseType.PreChorus]) self.verse_type_combo_box.setItemText(VerseType.Intro, VerseType.translated_names[VerseType.Intro]) self.verse_type_combo_box.setItemText(VerseType.Ending, VerseType.translated_names[VerseType.Ending]) self.verse_type_combo_box.setItemText(VerseType.Other, VerseType.translated_names[VerseType.Other]) self.split_button.setText(UiStrings().Split) self.split_button.setToolTip(UiStrings().SplitToolTip) self.force_split_button.setText(UiStrings().ForcedSplit) self.force_split_button.setToolTip(UiStrings().ForcedSplitToolTip) self.insert_button.setText(translate('SongsPlugin.EditVerseChordsForm', '&Insert')) self.insert_button.setToolTip(translate('SongsPlugin.EditVerseChordsForm', 'Split a slide into two by inserting a verse splitter.'))
def setupUi(self, printServiceDialog): """ Set up the UI """ printServiceDialog.setObjectName(u'printServiceDialog') printServiceDialog.resize(664, 594) self.mainLayout = QtGui.QVBoxLayout(printServiceDialog) self.mainLayout.setSpacing(0) self.mainLayout.setMargin(0) self.mainLayout.setObjectName(u'mainLayout') self.toolbar = QtGui.QToolBar(printServiceDialog) self.toolbar.setIconSize(QtCore.QSize(22, 22)) self.toolbar.setToolButtonStyle(QtCore.Qt.ToolButtonTextBesideIcon) self.printButton = self.toolbar.addAction(build_icon(u':/general/general_print.png'), translate('OpenLP.PrintServiceForm', 'Print')) self.optionsButton = QtGui.QToolButton(self.toolbar) self.optionsButton.setToolButtonStyle(QtCore.Qt.ToolButtonTextBesideIcon) self.optionsButton.setIcon(build_icon(u':/system/system_configure.png')) self.optionsButton.setCheckable(True) self.toolbar.addWidget(self.optionsButton) self.toolbar.addSeparator() self.plainCopy = self.toolbar.addAction(build_icon(u':/system/system_edit_copy.png'), translate('OpenLP.PrintServiceForm', 'Copy')) self.htmlCopy = self.toolbar.addAction(build_icon(u':/system/system_edit_copy.png'), translate('OpenLP.PrintServiceForm', 'Copy as HTML')) self.toolbar.addSeparator() self.zoomInButton = QtGui.QToolButton(self.toolbar) self.zoomInButton.setIcon(build_icon(u':/general/general_zoom_in.png')) self.zoomInButton.setObjectName(u'zoomInButton') self.zoomInButton.setIconSize(QtCore.QSize(22, 22)) self.toolbar.addWidget(self.zoomInButton) self.zoomOutButton = QtGui.QToolButton(self.toolbar) self.zoomOutButton.setIcon(build_icon(u':/general/general_zoom_out.png')) self.zoomOutButton.setObjectName(u'zoomOutButton') self.zoomOutButton.setIconSize(QtCore.QSize(22, 22)) self.toolbar.addWidget(self.zoomOutButton) self.zoomOriginalButton = QtGui.QToolButton(self.toolbar) self.zoomOriginalButton.setIcon(build_icon(u':/general/general_zoom_original.png')) self.zoomOriginalButton.setObjectName(u'zoomOriginalButton') self.zoomOriginalButton.setIconSize(QtCore.QSize(22, 22)) self.toolbar.addWidget(self.zoomOriginalButton) self.zoomComboBox = QtGui.QComboBox(printServiceDialog) self.zoomComboBox.setObjectName(u'zoomComboBox') self.toolbar.addWidget(self.zoomComboBox) self.mainLayout.addWidget(self.toolbar) self.previewWidget = QtGui.QPrintPreviewWidget(printServiceDialog) self.mainLayout.addWidget(self.previewWidget) self.optionsWidget = QtGui.QWidget(printServiceDialog) self.optionsWidget.hide() self.optionsWidget.resize(400, 300) self.optionsWidget.setAutoFillBackground(True) self.optionsLayout = QtGui.QVBoxLayout(self.optionsWidget) self.optionsLayout.setContentsMargins(8, 8, 8, 8) self.titleLabel = QtGui.QLabel(self.optionsWidget) self.titleLabel.setObjectName(u'titleLabel') self.optionsLayout.addWidget(self.titleLabel) self.titleLineEdit = QtGui.QLineEdit(self.optionsWidget) self.titleLineEdit.setObjectName(u'titleLineEdit') self.optionsLayout.addWidget(self.titleLineEdit) self.footerLabel = QtGui.QLabel(self.optionsWidget) self.footerLabel.setObjectName(u'footerLabel') self.optionsLayout.addWidget(self.footerLabel) self.footerTextEdit = SpellTextEdit(self.optionsWidget, False) self.footerTextEdit.setObjectName(u'footerTextEdit') self.optionsLayout.addWidget(self.footerTextEdit) self.optionsGroupBox = QtGui.QGroupBox() self.groupLayout = QtGui.QVBoxLayout() self.slideTextCheckBox = QtGui.QCheckBox() self.groupLayout.addWidget(self.slideTextCheckBox) self.pageBreakAfterText = QtGui.QCheckBox() self.groupLayout.addWidget(self.pageBreakAfterText) self.notesCheckBox = QtGui.QCheckBox() self.groupLayout.addWidget(self.notesCheckBox) self.metaDataCheckBox = QtGui.QCheckBox() self.groupLayout.addWidget(self.metaDataCheckBox) self.groupLayout.addStretch(1) self.optionsGroupBox.setLayout(self.groupLayout) self.optionsLayout.addWidget(self.optionsGroupBox) self.retranslateUi(printServiceDialog) QtCore.QObject.connect(self.optionsButton, QtCore.SIGNAL(u'toggled(bool)'), self.toggleOptions)
class Ui_PrintServiceDialog(object): """ The UI of the print service dialog """ def setupUi(self, printServiceDialog): """ Set up the UI """ printServiceDialog.setObjectName(u'printServiceDialog') printServiceDialog.resize(664, 594) self.mainLayout = QtGui.QVBoxLayout(printServiceDialog) self.mainLayout.setSpacing(0) self.mainLayout.setMargin(0) self.mainLayout.setObjectName(u'mainLayout') self.toolbar = QtGui.QToolBar(printServiceDialog) self.toolbar.setIconSize(QtCore.QSize(22, 22)) self.toolbar.setToolButtonStyle(QtCore.Qt.ToolButtonTextBesideIcon) self.printButton = self.toolbar.addAction(build_icon(u':/general/general_print.png'), translate('OpenLP.PrintServiceForm', 'Print')) self.optionsButton = QtGui.QToolButton(self.toolbar) self.optionsButton.setToolButtonStyle(QtCore.Qt.ToolButtonTextBesideIcon) self.optionsButton.setIcon(build_icon(u':/system/system_configure.png')) self.optionsButton.setCheckable(True) self.toolbar.addWidget(self.optionsButton) self.toolbar.addSeparator() self.plainCopy = self.toolbar.addAction(build_icon(u':/system/system_edit_copy.png'), translate('OpenLP.PrintServiceForm', 'Copy')) self.htmlCopy = self.toolbar.addAction(build_icon(u':/system/system_edit_copy.png'), translate('OpenLP.PrintServiceForm', 'Copy as HTML')) self.toolbar.addSeparator() self.zoomInButton = QtGui.QToolButton(self.toolbar) self.zoomInButton.setIcon(build_icon(u':/general/general_zoom_in.png')) self.zoomInButton.setObjectName(u'zoomInButton') self.zoomInButton.setIconSize(QtCore.QSize(22, 22)) self.toolbar.addWidget(self.zoomInButton) self.zoomOutButton = QtGui.QToolButton(self.toolbar) self.zoomOutButton.setIcon(build_icon(u':/general/general_zoom_out.png')) self.zoomOutButton.setObjectName(u'zoomOutButton') self.zoomOutButton.setIconSize(QtCore.QSize(22, 22)) self.toolbar.addWidget(self.zoomOutButton) self.zoomOriginalButton = QtGui.QToolButton(self.toolbar) self.zoomOriginalButton.setIcon(build_icon(u':/general/general_zoom_original.png')) self.zoomOriginalButton.setObjectName(u'zoomOriginalButton') self.zoomOriginalButton.setIconSize(QtCore.QSize(22, 22)) self.toolbar.addWidget(self.zoomOriginalButton) self.zoomComboBox = QtGui.QComboBox(printServiceDialog) self.zoomComboBox.setObjectName(u'zoomComboBox') self.toolbar.addWidget(self.zoomComboBox) self.mainLayout.addWidget(self.toolbar) self.previewWidget = QtGui.QPrintPreviewWidget(printServiceDialog) self.mainLayout.addWidget(self.previewWidget) self.optionsWidget = QtGui.QWidget(printServiceDialog) self.optionsWidget.hide() self.optionsWidget.resize(400, 300) self.optionsWidget.setAutoFillBackground(True) self.optionsLayout = QtGui.QVBoxLayout(self.optionsWidget) self.optionsLayout.setContentsMargins(8, 8, 8, 8) self.titleLabel = QtGui.QLabel(self.optionsWidget) self.titleLabel.setObjectName(u'titleLabel') self.optionsLayout.addWidget(self.titleLabel) self.titleLineEdit = QtGui.QLineEdit(self.optionsWidget) self.titleLineEdit.setObjectName(u'titleLineEdit') self.optionsLayout.addWidget(self.titleLineEdit) self.footerLabel = QtGui.QLabel(self.optionsWidget) self.footerLabel.setObjectName(u'footerLabel') self.optionsLayout.addWidget(self.footerLabel) self.footerTextEdit = SpellTextEdit(self.optionsWidget, False) self.footerTextEdit.setObjectName(u'footerTextEdit') self.optionsLayout.addWidget(self.footerTextEdit) self.optionsGroupBox = QtGui.QGroupBox() self.groupLayout = QtGui.QVBoxLayout() self.slideTextCheckBox = QtGui.QCheckBox() self.groupLayout.addWidget(self.slideTextCheckBox) self.pageBreakAfterText = QtGui.QCheckBox() self.groupLayout.addWidget(self.pageBreakAfterText) self.notesCheckBox = QtGui.QCheckBox() self.groupLayout.addWidget(self.notesCheckBox) self.metaDataCheckBox = QtGui.QCheckBox() self.groupLayout.addWidget(self.metaDataCheckBox) self.groupLayout.addStretch(1) self.optionsGroupBox.setLayout(self.groupLayout) self.optionsLayout.addWidget(self.optionsGroupBox) self.retranslateUi(printServiceDialog) QtCore.QObject.connect(self.optionsButton, QtCore.SIGNAL(u'toggled(bool)'), self.toggleOptions) def retranslateUi(self, printServiceDialog): """ Translate the UI on the fly """ printServiceDialog.setWindowTitle(UiStrings().PrintService) self.zoomOutButton.setToolTip(translate('OpenLP.PrintServiceForm', 'Zoom Out')) self.zoomOriginalButton.setToolTip(translate('OpenLP.PrintServiceForm', 'Zoom Original')) self.zoomInButton.setToolTip(translate('OpenLP.PrintServiceForm', 'Zoom In')) self.optionsButton.setText(translate('OpenLP.PrintServiceForm', 'Options')) self.titleLabel.setText(translate('OpenLP.PrintServiceForm', 'Title:')) self.footerLabel.setText(translate('OpenLP.PrintServiceForm', 'Custom Footer Text:')) self.optionsGroupBox.setTitle(translate('OpenLP.PrintServiceForm', 'Other Options')) self.slideTextCheckBox.setText(translate('OpenLP.PrintServiceForm', 'Include slide text if available')) self.pageBreakAfterText.setText(translate('OpenLP.PrintServiceForm', 'Add page break before each text item')) self.notesCheckBox.setText(translate('OpenLP.PrintServiceForm', 'Include service item notes')) self.metaDataCheckBox.setText(translate('OpenLP.PrintServiceForm', 'Include play length of media items')) self.titleLineEdit.setText(translate('OpenLP.PrintServiceForm', 'Service Sheet')) # Do not change the order. self.zoomComboBox.addItems([ translate('OpenLP.PrintServiceDialog', 'Fit Page'), translate('OpenLP.PrintServiceDialog', 'Fit Width'), u'100%', u'75%', u'50%', u'25%' ])