forked from openlp/openlp
Fix screen issues - not sure how though
This commit is contained in:
parent
c5b12ffaf3
commit
ac845a93ba
@ -183,6 +183,7 @@ class Ui_AmendThemeDialog(object):
|
||||
self.MainFontLayout.setWidget(4, QtGui.QFormLayout.LabelRole, self.FontMainWrapLineAdjustmentLabel)
|
||||
self.FontMainLineAdjustmentSpinBox = QtGui.QSpinBox(self.FontMainGroupBox)
|
||||
self.FontMainLineAdjustmentSpinBox.setObjectName("FontMainLineAdjustmentSpinBox")
|
||||
self.FontMainLineAdjustmentSpinBox.setMinimum(-99)
|
||||
self.MainFontLayout.setWidget(4, QtGui.QFormLayout.FieldRole, self.FontMainLineAdjustmentSpinBox)
|
||||
self.FontMainWrapIndentationLabel = QtGui.QLabel(self.FontMainGroupBox)
|
||||
self.FontMainWrapIndentationLabel.setObjectName("FontMainWrapIndentationLabel")
|
||||
|
@ -1,4 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# -*- coding: utf-8 -*-
|
||||
# vim: autoindent shiftwidth=4 expandtab textwidth=80 tabstop=4 softtabstop=4
|
||||
|
||||
###############################################################################
|
||||
@ -730,7 +731,6 @@ class MainWindow(QtGui.QMainWindow, Ui_MainWindow):
|
||||
|
||||
def loadSettings(self):
|
||||
log.debug(u'Loading QSettings')
|
||||
print self.geometry()
|
||||
settings = QtCore.QSettings()
|
||||
settings.beginGroup(self.generalSettingsSection)
|
||||
self.recentFiles = settings.value(u'recent files').toStringList()
|
||||
@ -742,7 +742,6 @@ class MainWindow(QtGui.QMainWindow, Ui_MainWindow):
|
||||
settings.value(u'main window geometry').toByteArray())
|
||||
self.restoreState(settings.value(u'main window state').toByteArray())
|
||||
settings.endGroup()
|
||||
print self.geometry()
|
||||
|
||||
def saveSettings(self):
|
||||
log.debug(u'Saving QSettings')
|
||||
|
@ -114,7 +114,6 @@ class SlideController(QtGui.QWidget):
|
||||
self.songEditList = [
|
||||
u'Edit Song',
|
||||
]
|
||||
self.labelWidth = 20
|
||||
self.timer_id = 0
|
||||
self.songEdit = False
|
||||
self.selectedRow = 0
|
||||
@ -154,12 +153,11 @@ class SlideController(QtGui.QWidget):
|
||||
self.ControllerLayout.setMargin(0)
|
||||
# Controller list view
|
||||
self.PreviewListWidget = SlideList(self)
|
||||
self.PreviewListWidget.setColumnCount(2)
|
||||
self.PreviewListWidget.setColumnCount(1)
|
||||
self.PreviewListWidget.horizontalHeader().setVisible(False)
|
||||
self.PreviewListWidget.verticalHeader().setVisible(False)
|
||||
self.PreviewListWidget.setColumnWidth(0, self.labelWidth)
|
||||
#self.PreviewListWidget.verticalHeader().setVisible(False)
|
||||
self.PreviewListWidget.setColumnWidth(
|
||||
1, self.Controller.width() - self.labelWidth)
|
||||
0, self.Controller.width())
|
||||
self.PreviewListWidget.isLive = self.isLive
|
||||
self.PreviewListWidget.setObjectName(u'PreviewListWidget')
|
||||
self.PreviewListWidget.setSelectionBehavior(1)
|
||||
@ -379,8 +377,7 @@ class SlideController(QtGui.QWidget):
|
||||
"""
|
||||
width = self.parent.ControlSplitter.sizes()[self.split]
|
||||
height = width * self.parent.RenderManager.screen_ratio
|
||||
self.PreviewListWidget.setColumnWidth(0, self.labelWidth)
|
||||
self.PreviewListWidget.setColumnWidth(1, width - self.labelWidth)
|
||||
self.PreviewListWidget.setColumnWidth(0, width)
|
||||
#Sort out image hights (Songs , bibles excluded)
|
||||
if self.serviceItem and not self.serviceItem.is_text():
|
||||
for framenumber, frame in enumerate(self.serviceItem.get_frames()):
|
||||
@ -523,20 +520,19 @@ class SlideController(QtGui.QWidget):
|
||||
self.serviceItem = serviceItem
|
||||
self.PreviewListWidget.clear()
|
||||
self.PreviewListWidget.setRowCount(0)
|
||||
self.PreviewListWidget.setColumnWidth(0, self.labelWidth)
|
||||
self.PreviewListWidget.setColumnWidth(1, width - self.labelWidth)
|
||||
self.PreviewListWidget.setColumnWidth(0, width)
|
||||
if self.isLive:
|
||||
self.SongMenu.menu().clear()
|
||||
row = 0
|
||||
text = []
|
||||
for framenumber, frame in enumerate(self.serviceItem.get_frames()):
|
||||
self.PreviewListWidget.setRowCount(
|
||||
self.PreviewListWidget.rowCount() + 1)
|
||||
rowitem = QtGui.QTableWidgetItem()
|
||||
item = QtGui.QTableWidgetItem()
|
||||
slideHeight = 0
|
||||
#It is a based Text Render
|
||||
if self.serviceItem.is_text():
|
||||
if self.isLive and frame[u'verseTag'] is not None:
|
||||
if frame[u'verseTag'] is not None:
|
||||
#only load the slot once
|
||||
bits = frame[u'verseTag'].split(u':')
|
||||
tag = None
|
||||
@ -550,10 +546,11 @@ class SlideController(QtGui.QWidget):
|
||||
tag = bits[0]
|
||||
tag1 = tag
|
||||
row = bits[0][0:1]
|
||||
if tag1 not in self.slideList:
|
||||
self.slideList[tag1] = framenumber
|
||||
self.SongMenu.menu().addAction(self.trUtf8(u'%s'%tag1),
|
||||
self.onSongBarHandler)
|
||||
if self.isLive:
|
||||
if tag1 not in self.slideList:
|
||||
self.slideList[tag1] = framenumber
|
||||
self.SongMenu.menu().addAction(self.trUtf8(u'%s'%tag1),
|
||||
self.onSongBarHandler)
|
||||
else:
|
||||
row += 1
|
||||
item.setText(frame[u'text'])
|
||||
@ -565,20 +562,18 @@ class SlideController(QtGui.QWidget):
|
||||
self.parent.RenderManager.height)
|
||||
label.setScaledContents(True)
|
||||
label.setPixmap(QtGui.QPixmap.fromImage(pixmap))
|
||||
self.PreviewListWidget.setCellWidget(framenumber, 1, label)
|
||||
self.PreviewListWidget.setCellWidget(framenumber, 0, label)
|
||||
slideHeight = width * self.parent.RenderManager.screen_ratio
|
||||
row += 1
|
||||
rowitem.setText(unicode(row))
|
||||
rowitem.setTextAlignment(QtCore.Qt.AlignVCenter)
|
||||
self.PreviewListWidget.setItem(framenumber, 0, rowitem)
|
||||
self.PreviewListWidget.setItem(framenumber, 1, item)
|
||||
text.append(unicode(row))
|
||||
self.PreviewListWidget.setItem(framenumber, 0, item)
|
||||
if slideHeight != 0:
|
||||
self.PreviewListWidget.setRowHeight(framenumber, slideHeight)
|
||||
self.PreviewListWidget.setVerticalHeaderLabels(text)
|
||||
if self.serviceItem.is_text():
|
||||
self.PreviewListWidget.resizeRowsToContents()
|
||||
self.PreviewListWidget.setColumnWidth(0, self.labelWidth)
|
||||
self.PreviewListWidget.setColumnWidth(1,
|
||||
self.PreviewListWidget.viewport().size().width() - self.labelWidth)
|
||||
self.PreviewListWidget.setColumnWidth(0,
|
||||
self.PreviewListWidget.viewport().size().width())
|
||||
if slideno > self.PreviewListWidget.rowCount():
|
||||
self.PreviewListWidget.selectRow(self.PreviewListWidget.rowCount())
|
||||
else:
|
||||
|
Loading…
Reference in New Issue
Block a user