lorem_ipsum = """ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a diam lectus. Sed sit amet ipsum mauris. Maecenas congue ligula ac quam viverra nec consectetur ante hendrerit. Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. """ if __name__ == '__main__': print(__doc__) safe = True sample_text = lorem_ipsum + sample_text_monospaced_table() # all fonts known by the OS fontdb = wq.query() if safe: candidates = [f for f in fontdb if pyglet_safe(f)] else: canditates = fontdb # theres one fontentry for each charset supported, so reduce names font_names = list(set([f.name for f in candidates])) font_names.sort() window = Window(1024, 600) window.on_text_motion(None) pyglet.app.run()
self.text.draw() lorem_ipsum = """ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a diam lectus. Sed sit amet ipsum mauris. Maecenas congue ligula ac quam viverra nec consectetur ante hendrerit. Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. """ print(__doc__) safe = True sample_text = lorem_ipsum + sample_text_monospaced_table() # all fonts known by the OS fontdb = wq.query() if safe: candidates = [f for f in fontdb if pyglet_safe(f)] else: canditates = fontdb # theres one fontentry for each charset supported, so reduce names font_names = list(set([f.name for f in candidates])) font_names.sort() window = Window(1024, 600) window.on_text_motion(None) pyglet.app.run()