Leave scroll bar on build tool document, and don't scroll too far past end in doc editor

This commit is contained in:
Veronica K. B. Olsen
2020-10-11 21:39:42 +02:00
parent 2990616a5c
commit 9c75ed5b06
2 changed files with 1 additions and 12 deletions
-11
View File
@@ -1124,17 +1124,6 @@ class GuiBuildNovelDocView(QTextBrowser):
else:
self.setTabStopWidth(self.mainConf.getTabWidth())
# Scroll bars
if self.mainConf.hideVScroll:
self.setVerticalScrollBarPolicy(Qt.ScrollBarAlwaysOff)
else:
self.setVerticalScrollBarPolicy(Qt.ScrollBarAsNeeded)
if self.mainConf.hideHScroll:
self.setHorizontalScrollBarPolicy(Qt.ScrollBarAlwaysOff)
else:
self.setHorizontalScrollBarPolicy(Qt.ScrollBarAsNeeded)
docPalette = self.palette()
docPalette.setColor(QPalette.Base, QColor(255, 255, 255))
docPalette.setColor(QPalette.Text, QColor(0, 0, 0))
+1 -1
View File
@@ -440,7 +440,7 @@ class GuiDocEditor(QTextEdit):
if self.mainConf.scrollPastEnd:
docFrame = self.qDocument.rootFrame().frameFormat()
docFrame.setBottomMargin(wH - uM - lM - 4*tB - self.theTheme.fontPixelSize)
docFrame.setBottomMargin(wH - uM - lM - 5*self.theTheme.fontPixelSize)
self.qDocument.rootFrame().setFrameFormat(docFrame)
return