Friday, October 26, 2007

Working from Home

Yesterday my boss approved my request to work from home 3 days a week, and only go in to the office on Mondays and Wednesdays. So now I'll have a lot more time to work on Treenimation. But before I start working from home, I must set up my home computer with all our development tools, as well as install a Linux partition so I can develop the Linux version of Treenimation along with the Windows version.

I'm almost finished reading the Python tutorial, and this weekend I hope to begin translating the part of Treenimation I call the TIL Loader from Object Pascal into Python.

Benefits of working from home:
  1. More time to work on Treenimation
  2. Save money (don't need a car)
  3. Less hassle (won't have a car to worry about)
  4. More environmentally friendly (no more driving to work)
  5. Healthier lunches (fewer McDonald's/Wendy's meals)
  6. More exercise (going for walks in my neighbourhood)

To Do List:

  1. Go to http://www.laptop.org/ and find out which version of Linux they recommend
  2. Find out space requirements of Linux, Python, PyGtk, Sugar, etc.
  3. Download Linux and burn it onto DVDs
  4. Buy Partition Magic
  5. Back up my home computer's data onto a CD
  6. Make partitions for Linux and Windows XP
  7. Install Linux at home
  8. Bring my computer to work (it already has Delphi 4)
  9. Copy C:\Bdev (over 10 GB) from my work computer to my home computer
  10. Step 9 will take several hours
  11. Install Delphi 6 and all our development tools
  12. Take computer home (sometime in November)
  13. Start working from home 3 days a week
  14. Install XO Laptop emulator on Linux partition
  15. Translate TIL Loader from Object Pascal into Python
  16. Port TIL Loader to Linux/Sugar/XO Laptop
  17. Apply to OLPC for web hosting

Sunday, October 21, 2007

Navigation Keys

There exist 3 text-entry modes in the Treescript code editor:

  1. Free Form
  2. Structure Editor
  3. Code Menu

Pressing Esc toggles between Free Form and Structure Editor modes. Typing a question mark (?) enters Code Menu mode (except within comments and string literals; to enter Code Menu mode from inside those, press Ctrl+?). Pressing F1 displays context-sensitive help in all modes.

Structure Editor: a bottom-level token (e.g. a keyword, identifier, operator, or constant) or an entire list is often highlighted. Using the Shift key in conjunction with the Up/Down Arrow keys, it is possible to select more than one token/list at a time.

  • Esc - enter Free Form mode
  • Up Arrow - go to previous list element
  • Down Arrow - go to next list element
  • Left Arrow - go to parent list
  • Right Arrow - go to first child element (if none, display text cursor following current bottom-level token)
  • Shift+Up/Down Arrow - select a range of tokens/lists
  • Printable Char. - insert token/list, display text cursor
  • Backspace - undo insertion of previous printable char.
  • Delete - delete current token/list
  • Enter - display text cursor, insert space after cursor
  • Space - display text cursor, insert space before cursor
  • Ctrl+Enter – if at end of line, append blank line (otherwise break line into 2 lines)

Code Menu: a popup menu above or below text cursor (and including text cursor) is displayed. The contents of this menu include all valid code elements in the context of the text cursor (ignoring anything after the text cursor).

  • Esc - show/hide code menu
  • Up Arrow - move selection up
  • Down Arrow - move selection down
  • Left Arrow - go to parent code menu (if none, exit Code Menu mode)
  • Right Arrow - go to lower-level code menu
  • Enter - go to lower-level code menu (if none, select current menu item, and display new code menu following token/list just inserted)
  • Space - go to lower-level code menu (if none, select current menu item and exit Code Menu mode)
  • Printable Char. - incrementally select matching menu item
  • Backspace - undo operation of previous printable char.
  • Question Mark - exit Code Menu mode

Hello, World!

Several weeks ago I used Delphi (a tool I have been using at work for 11 years) to program the very first part of Treenimation to be implemented: the TIL Loader. Later I created my OLPC project wiki, and I was advised that I should use Python instead of Delphi to implement Treenimation. Yesterday I downloaded/installed Python, PyGtk, and Glade, and wrote my first Python Hello-World-style program. This little program displays 2 buttons. If you click on the 1st button, it displays its label in the main Python window (the shell). If you click on the 2nd button, it changes the label of the 1st button to a different value. If you click on the 2nd button again, it changes the 1st button back to its original value. This afternoon I'm going to go through the Python tutorial and learn the basics of Python programming. Soon I'm going to translate the TIL Loader into Python, and then I'm going to apply to OLPC for web hosting.

One Laptop Per Child

Treenimation has 2 target platforms: Windows and OLPC (Linux). OLPC is a project which aims to distribute millions of $175 laptops to schoolchildren in developing countries. Each laptop is equipped with Linux, Python (a free programming language), and wireless peer-to-peer networking. So kids can use Treenimation to create their own board games, and play them with their friends. Every OLPC project has an OLPC wiki. Please click on Treenimation to visit my wiki.

Welcome

Welcome to Mike's Treenimation blog. I am Mike Hahn, the founder of Treenimation.net, which is the future home of the Treenimation software tool (now under development). Treenimation allows you to create web-based (real-time) and email-based multiplayer board games. Subsequent versions of Treenimation will add support for games with 2D animation (and ultimately 3D animation). Treenimation is based on a powerful yet easy-to-learn, object-oriented, built-in scripting language called Treescript. Non-programmers can create drag-and-drop games, and both novice and advanced programmers can use Treescript to add functionality to these games. Treenimation will run on both Windows and Linux platforms.

This blog is meant to document the design process and implementation process of Treenimation. I have been working on the design process of Treenimation (albeit very sporadically) for over 10 years. Recently I have begun to implement Treenimation for Windows, using Python and PyGtk.