Try Python: Interactive Python Tutorial with Silverlight (and rst2xaml)
Silverlight is the Microsoft browser plugin runs on the Mac and Windows and in Safari, IE and Firefox browsers. As an added bonus it also supports IronPython, making it an ideal tool to build an interactive Python tutorial with.
Try Python is an open source project that takes the official Python tutorial and puts it alongside an interactive Python interpreter running in the browser. All of the code examples have a button to execute them in the interpreter, or you can just follow the tutorial trying out the examples yourself.
Try Python has the following features:
The Python tutorial is formatted using ReStructured Text, the popular text markup format implemented in Python. To render a nicely formatted version in Silverlight I've implemented a XAML writer for ReStructured Text and a XAML formatter for Pygments which does nice syntax highlighting of Python source code. XAML is the XML dialect for describing user interfaces in the WPF (Windows Presentation Foundation) and Silverlight user interfaces.
The XAML writer / formatter are in the rst2xaml project:
Try Python is an open source project that takes the official Python tutorial and puts it alongside an interactive Python interpreter running in the browser. All of the code examples have a button to execute them in the interpreter, or you can just follow the tutorial trying out the examples yourself.
- Try Python: Interactive Python Tutorial in the Browser
- Try Python Page on the Silverlight.net Community Site
- Try Python Announcement with Screenshots
- Try Python Google Code Project Page with Source Repository
Try Python has the following features:
- Auto-resizes with the browser
- Navigation bar through the tutorial pages at the top and bottom
- Individual pages are bookmarkable and the URL fragment auto-updates when you change page
- Mouse scroll wheel supported over the tutorial and console scroll viewers
- Control-C interrupts the running code with a keyboard interrupt
- raw_input and input work in the interpreter
- Basic auto-indent and auto-dedent in the console
- Console history, including multiline history
- Syntax highlighting in the console
- reset command to clear the console
- Assign to sys.ps1 and sys.ps2 from the console
The Python tutorial is formatted using ReStructured Text, the popular text markup format implemented in Python. To render a nicely formatted version in Silverlight I've implemented a XAML writer for ReStructured Text and a XAML formatter for Pygments which does nice syntax highlighting of Python source code. XAML is the XML dialect for describing user interfaces in the WPF (Windows Presentation Foundation) and Silverlight user interfaces.
The XAML writer / formatter are in the rst2xaml project:
- rst2xaml project and repository
- rst2xaml announcement and description
- rst2xaml 1.0 release notes and updates
Comments
Post a Comment