Here is Export HTML (notice I don't pad the end of the lines yet with color, but generally it looks pretty good...except for the horrible theme ).

Screen Shot 2012-11-06 at 6.49.40 AM.png (79 KiB) Viewed 4680 times

Transparency might not be exactly spot on, but it is pretty close. I have to guess how ST2 might be doing it, and then I have a little fudge factor in their to adjust things. In the example above, I believe the reddish and purplish colors use transparency, so they are pretty close.

The padding is trickier than you would think. I am trying to keep the text in tables so I can easily copy and paste any section to an email (which I use a lot). And I am also trying to preserve wrapping for printing. All of these things can be at odds with each other...and exhausting. This is also why, if you use certain fonts, you may see a break between code lines. It is hard for me to get the spans to fill in those lines because they don't respond to height properites, but I can't check their pixel height at compile time in python, I would have to do that at run time and then pad every span...ugh. If I remove the table, the problem goes away, but then if I copy and paste a section of the HTML, I lose page background color, and it loses the uniform right edge. If I use block elements and float them left, I lose the easy way to test for line length and wrap them. Web coding can be a real pain.

One more thing. The new background coloring feature caused one side affect for people me when copying and pasting code into Outlook.

Apparently, if outlook has html code pasted in it with spans who have a color darker than about 62 luminescence, it renders all the text in those spans as white. Kind of annoying. So I added a feature that the few people who paste dark themes into emails in Outlook might use. The feature causes ExportHTML to scale up the entire theme to ensure that all background colors are at least 62 luminescence (this can be configured to a different value if desired; between 0-255). I also fixed an issue where some themes wouldn't work because I hadn't encoded the plist proper that I stuff into the HTML; that is now fixed as well.

A fairly useless feature I added for fun. You can use filters in ExportHtml and ExportBbcode. I guess this could be useful if you wanted to apply some filter to theme. Then you could use exportHtml to apply the filter and then extract the theme from the HTML via the download option in the toolbar. Anyways, I realize this feature is pretty worthless, but it was fun nonetheless.

You can use the following: invert, grayscale, sepia, brightness, saturation, hue, colorize.