This commit is contained in:
Jonathan Corwin 2012-08-25 17:29:17 +01:00
parent 9864bf9084
commit 9b378fbea5
2 changed files with 5 additions and 7 deletions

View File

@ -79,8 +79,6 @@ class Renderer(object):
self.force_page = False
self.display = MainDisplay(None, self.image_manager, False, self)
self.display.setup()
QtCore.QObject.connect(Receiver.get_receiver(),
QtCore.SIGNAL(u'renderer_update_text'), self.update_text)
self._theme_dimensions = {}
self._calculate_default()
QtCore.QObject.connect(Receiver.get_receiver(),
@ -262,16 +260,13 @@ class Renderer(object):
self.display.buildHtml(serviceItem)
raw_html = serviceItem.get_rendered_frame(0)
if same_thread:
Receiver.send_message(u'renderer_update_text', raw_html)
self.display.text(raw_html)
else:
self.update_text(raw_html)
Receiver.send_message(u'renderer_display_text', raw_html)
preview = self.display.preview()
return preview
self.force_page = False
def update_text(self, text):
self.display.text(text)
com
def format_slide(self, text, item):
"""
Calculate how much text can fit on a slide.

View File

@ -155,6 +155,9 @@ class MainDisplay(Display):
QtCore.SIGNAL(u'update_display_css'), self.cssChanged)
QtCore.QObject.connect(Receiver.get_receiver(),
QtCore.SIGNAL(u'config_updated'), self.configChanged)
else:
QtCore.QObject.connect(Receiver.get_receiver(),
QtCore.SIGNAL(u'renderer_display_text'), self.text)
def setTransparency(self, enabled):
if enabled: