aboutsummaryrefslogtreecommitdiff
path: root/src/components/text.py
diff options
context:
space:
mode:
authortassaron2017-07-27 17:49:08 -0400
committertassaron2017-07-27 17:49:08 -0400
commitde1324a6a75eb2a9f97d8a6b416077cfc73b2bc9 (patch)
tree2aebc32702f193280f6332a7aa6c3f21e4390ca0 /src/components/text.py
parent4329b0e947471ced7ca0b3460a5f40e2703117e9 (diff)
fixed video component eating stdout
+ made height/width into properties to simplify render methods
Diffstat (limited to 'src/components/text.py')
-rw-r--r--src/components/text.py13
1 files changed, 4 insertions, 9 deletions
diff --git a/src/components/text.py b/src/components/text.py
index 1d64617..8a302ff 100644
--- a/src/components/text.py
+++ b/src/components/text.py
@@ -97,10 +97,8 @@ class Component(Component):
saveValueStore['textColor'] = self.textColor
return saveValueStore
- def previewRender(self, previewWorker):
- width = int(self.settings.value('outputWidth'))
- height = int(self.settings.value('outputHeight'))
- return self.addText(width, height)
+ def previewRender(self):
+ return self.addText(self.width, self.height)
def properties(self):
props = ['static']
@@ -111,13 +109,10 @@ class Component(Component):
def error(self):
return "No text provided."
- def frameRender(self, layerNo, frameNo):
- width = int(self.settings.value('outputWidth'))
- height = int(self.settings.value('outputHeight'))
- return self.addText(width, height)
+ def frameRender(self, frameNo):
+ return self.addText(self.width, self.height)
def addText(self, width, height):
-
image = FramePainter(width, height)
self.titleFont.setPixelSize(self.fontSize)
image.setFont(self.titleFont)