Added more comments and tweaked the scroll features

This commit is contained in:
Veronica K. B. Olsen
2020-10-18 19:56:24 +02:00
parent dc4257bbf4
commit eed349ab85
2 changed files with 37 additions and 30 deletions
+2 -3
View File
@@ -441,8 +441,7 @@ class GuiDocEditor(QTextEdit):
if self.mainConf.scrollPastEnd:
docFrame = self.qDocument.rootFrame().frameFormat()
docMargin = wH - uM - lM - 4*tB - 5*self.theTheme.fontPixelSize
docFrame.setBottomMargin(max(0, docMargin))
docFrame.setBottomMargin(max(0, 0.6*(wH - uM - lM - 4*tB)))
self.qDocument.rootFrame().setFrameFormat(docFrame)
return
@@ -794,7 +793,7 @@ class GuiDocEditor(QTextEdit):
# Move the scroll bar
vBar = self.verticalScrollBar()
doAnim = QPropertyAnimation(vBar, b"value", self)
doAnim.setDuration(150)
doAnim.setDuration(120)
doAnim.setStartValue(vBar.value())
doAnim.setEndValue(vBar.value() + cMov)
doAnim.start()