All pastes #146916 Raw Edit

Unnamed

public text v1 · immutable
#146916 ·published 2006-08-23 23:35 UTC
rendered paste body
#This gives access to:
#	the ScribesPlugin class to inherit from
#	the Scribes object
from scribesplugin import *

class HelloWorldPlugin(ScribesPlugin):
	"""
	A sample plugin to scribes
	
	"""
	def __init__(self):
		#Which plugins do we need to work?
		depends_on = []
		#Which events are we handling
		events_handled = {"load":self.__onload}
		ScribesPlugin(self, depends_on, events_handled)

	def __onload(self):
		#Write inserts text at the current selection
		Scribes.Editor.write("Hello World")