aboutsummaryrefslogtreecommitdiff
path: root/lib/python/Components/ScrollLabel.py
diff options
context:
space:
mode:
Diffstat (limited to 'lib/python/Components/ScrollLabel.py')
-rw-r--r--lib/python/Components/ScrollLabel.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/python/Components/ScrollLabel.py b/lib/python/Components/ScrollLabel.py
index 4a5caf6a..62f64b1d 100644
--- a/lib/python/Components/ScrollLabel.py
+++ b/lib/python/Components/ScrollLabel.py
@@ -16,14 +16,15 @@ class ScrollLabel(HTMLComponent, GUIComponent):
skin.applyAllAttributes(self.long_text, desktop, self.skinAttributes)
s = self.long_text.size()
self.instance.move(self.long_text.position())
- self.scrollbar.move(ePoint(s.width()-20,0))
- self.scrollbar.resize(eSize(20,s.height()))
- self.scrollbar.setOrientation(eSlider.orVertical);
- self.scrollbar.setRange(0,100)
lineheight=fontRenderClass.getInstance().getLineHeight( self.long_text.getFont() )
lines = (int)(s.height() / lineheight)
self.pageHeight = (int)(lines * lineheight)
self.instance.resize(eSize(s.width(), self.pageHeight+(int)(lineheight/6)))
+ self.scrollbar.move(ePoint(s.width()-20,0))
+ self.scrollbar.resize(eSize(20,self.pageHeight+(int)(lineheight/6)))
+ self.scrollbar.setOrientation(eSlider.orVertical);
+ self.scrollbar.setRange(0,100)
+ self.scrollbar.setBorderWidth(1)
self.long_text.move(ePoint(0,0))
self.long_text.resize(eSize(s.width()-30, self.pageHeight*16))
self.setText(self.message)