MYOML #9: Validation and Conclusion

The custom markup language has been designed to have a certain structure. That is, there is supposed to be one <article> tag, followed by a <section> container, followed by a <text> container. The CSS stylesheet has been designed with this in mind. However, nothing actually enforces this structure. There is nothing stopping you from writing an article with arbitrary tag structure (or even using undefined tags). There are two problems with this:

  1. Both the XSLT and CSS stylesheets were designed with a certain nesting order in mind, and allowing a different structure risks having a document that doesn't look quite right when displayed.
  2. Not having a consistent structure makes it hard or even impossible to write an XML query tool for indexing articles, etc., since there is no fixed structure to parse.

Another essential Firefox extension: IE View

IE-only websites are an unfortunate reality on the net. They are especially prevalent on the corporate intranet where I work, where the slogan "thou shalt only use IE" is seen in full effect. I use Firefox as my primary browser, and was getting really tired of having to constantly switch to the desktop, find IE, copy & paste an URL from Firefox, and continue browsing in IE.

Thoughts on bundling pysqlite in Python 2.5

I was really surprised when reading through the changes for the upcoming Python 2.5 release to discover that pysqlite will now be included in the standard library. If you aren't familiar with it, pysqlite provides an interface to SQLite which is an embedded SQL library. I use pysqlite all the time, so I found this really interesting.

Some immediate positive things I see about this:

  1. One less dependency that end-users have to care about.
  2. One less package to install on my development machines.
  3. Inclusion in the standard library (tends to) indicate that the code has been more rigorously reviewed for correctness and adherance to Python standards.

pyconfig.py updated for Python 2.5-alpha1

The first alpha release of Python 2.5 appeared on python.org Wednesday. Using Andrew Kuchling's "What's New In Python 2.5" document as a starting point, I updated pyconfig to test for the new features. (pyconfig is discussed in detail in The Python Tourist #5).

MYOML #8: Smoothing things out with PHP

The markup language is complete, but there are a few nice touches left to add. One is to make the articles compatible with non-XSLT capable browsers. Another is to add some preprocessing of <code> sections so that you (shouldn't have to) touch them up manually.

Issue #8: Smoothing things out with PHP

MYOML #7: Adding the final few tags

Agh, RealLife(tm) intruded on my writing progress for a while there, but I should be back on track for a bit at least.

This installment of Make Your Own Markup Language finalizes (for now at least) the design and adds the final tags. All that's left after this is to do a little polishing.

MYOML Issue #7: Adding the final few tags

Syncing jEdit settings between machines

As I've mentioned before, I've switched to jEdit from XEmacs. I use both WinXP and Linux, and one thing that was nice about using XEmacs was that it was easy to sync my settings between machines. All I had to do was worry about two files: init.el and custom.el. Both were portable, and could be copied directly between machines.

With jEdit, though, there is an entire tree of settings. These settings live under either ~/.jedit/ on POSIX machines, or under "Documents and Settings/USERNAME/.jedit" on a Windows machine. On my Linux machine, for example, there are 104 files under ~/.jedit. It certainly appears that it will be a huge task to sync between machines. There is a "HOWTO" page, but all it really tells you is how hard it is to do. Its more discouraging than helpful, I think.

MYOML #6: Metainfo, notes, warnings, and more HTML tags

As I get further into this series, the example template is diverging more and more from the "official" boodebr.org template, as I learn more and make improvements. This is making me antsy to go ahead and get finished with MYOML so I can start using the improved template on the whole site.

This time around I'm going to restructure the root template to add metainfo to the article. The metainfo is used to create the overall page layout, but can also be useful in if I ever want to create an article index. A script will be able to easily pull the metainfo from the article to create a database, etc.

I'm also going to add some 'note' and 'warning' boxes for highlighting important details, and add a few more HTML tags.

Issue #6: Metainfo, notes, warnings, and more HTML tags

MYOML #5: Attributes, titles, and other blocks.

So far so good, but the layout (although functional) is still pretty bland. Time to add a title= attribute to the <section> and <code> blocks, implement inline code samples, and see how to add some standard HTML tags to our markup language.

Issue #5: Attributes, titles, and other blocks.

The Python Tourist: Replacing sys.version_info with pyconfig

Gnosis_Utils is a package that (tries at least) to be compatible with everything from Python 1.5 and up. Of course, this isn't always possible, but it tries. Smile While working on xml.pickle, I found myself repeatedly using hardcoded version checks like "if sys.version_info[1] >= 2", etc. When refactoring some code that had those types of checks in it, I ran into difficulty because the version check told me nothing about what capability was actually required.

Syndicate content