Ejemplo n.º 1
0
	def __init__(self, master=None, toplevel=None, document=None,
					show_visible=0, show_printable=1,
					resolution=None, **kw):
		apply(PyWidget.__init__, (self, master), kw)
		Viewport.__init__(self, resolution)
		QueueingPublisher.__init__(self)
		self.toplevel = toplevel

		self.move_window_count = 0
		self.show_page_outline = 1
		self.show_visible = show_visible
		self.show_printable = show_printable
		self.gcs_initialized = 0
		self.gc = GraphicsDevice()
		self.renderer = DocRenderer(self)
		self.widget_size = ()


		self.init_transactions()
		if document is not None:
			self.SetDocument(document)
		else:
			self.SetDocument(Document(create_layer=1))
Ejemplo n.º 2
0
	def destroy(self):
		self.unsubscribe_doc()
		PyWidget.destroy(self)
		QueueingPublisher.Destroy(self)
Ejemplo n.º 3
0
	def queue_message(self, Publisher):
		if self.transaction:
			QueueingPublisher.queue_message(self, Publisher)
		else:
			self.issue(Publisher)