Blog-o! Notes from latte.ca

Fri, 31 Jan 2003
More New Stuff.
So, I've just added the capability to update the weblog over the web. Should be a nice feature for those sad days when the SSH daemon dies unexpectedly. And it works fairly well too. I wonder how well it deals with updates? Oh, and I should also make it output the text in a nicer format, but that's all stuff for later. I've also got the XML-RPC interface working, so I can use desktop tools from work to post and modify entries.
[Posted at 13:16 by Blake Winton] link
More pictures.
I took a few more pictures last weekend, and finally got the time to put them up on the web. Nothing too exciting, I don't think, but they turned out reasonably well. When I convert them to their final web-based format I scale them down so that they're smaller than 800x700. If that's still too large, or too slow, let me know, and I'll see about cutting it back further. When I'm using my laptop (which runs at 1024x768 (Shut up, you!)) I get about 15 pixels worth of scrollbar, but I don't know if that's because of my overly large IE title settings, or if the pictures are actually too large.
[Posted at 12:51 by Blake Winton] link
Thu, 23 Jan 2003
Tool of The Man.

I notice that Ian Stevens mentioned an application that the company he works at recently released.
Damn, what a sell-out! I can't wait to see what his next announcement will be.

Disclaimer: I work with Ian, and he knows that I don't actually think he's a sell-out.

[Posted at 15:24 by Blake Winton] link
Tue, 21 Jan 2003
After seeing the EffNews plugin for Andrew Kuchling's journal, I was inspired to try creating one of my own, for Neil Gaiman's journal. I think it went pretty well, although I'ld like to spend a little more time on it, to do something prettier with the dates. Perhaps later.
urls = ["http://www.neilgaiman.com/journal/journal.asp"]

def simpleprovider(context, text):
    context.push("channel", title="Neil Gaiman", link=urls[0])
    header = '<font Class="bold"> Journal:<font>'
    signature = '<blockquote>'
    i = j = k = 0
    j = text.find(header, j)
    while 1:
        i = text.find(signature, j)
        if i < 0:
            break
        j = text.find(signature, i+len(signature))
        if j < 0:
            break

        description = text[i:j]
        context.push("item", link=urls[0], description=description)

if __name__ == "__main__":
    # test wrapper
    import urllib
    class context:
        def push(self, tag, **kw):
            print tag, kw
    simpleprovider(context(), urllib.urlopen(urls[0]).read())
[Posted at 12:08 by Blake Winton] link
Mon, 20 Jan 2003
Hacked, part 2

Well, mail works now, as does web and even the cute little weblog script, but logging on an X session at the console fails pretty heinously. (Specifically, rxvt fails complaining that it couldn't open the pseudo-tty, or could not obtain control of tty, depending on what random bit I flipped before I tried to launch it.) Plain old xterm seems to work just fine, though. More debugging later, I guess. For now, I'm just going to go to sleep.

[Posted at 23:39 by Blake Winton] link

Apparently we've been hacked. Craptastic. I've changed all the files I think they affected, but I also removed a bunch of files that I didn't know I needed. Oh well, everything should get back to normal any time now.

Oh, yeah, and mail doesn't work. I'll see if I can fix that tonight.

[Posted at 19:02 by Blake Winton] link
Changes to Latte.ca
I've been playing around with the webserver here at Latte.ca, to see if there was an easier weblogging tool that I could set up for people to use. One product that caught my eye was Plone, so I tried to set it up here. It turned out that it required me to set up Zope (A python-based web application server) first, so I did that too. But after using Plone for about 30 seconds, I'm not convinced that it's a good weblogging tool (mainly because it seems too powerful, and not easy enough to use). I'm not going to uninstall it, but I think I'll stick with Blosxom for now. (Hey, maybe I'll install PyBlosxom, and see if it integrates with Zope at all.)
[Posted at 15:24 by Blake Winton] link
Thu, 16 Jan 2003
Released!

So the company I work for has just released our first product. It took a lot of time and effort to get there, but I think we did something good. The main part I've been working on these past few weeks was the "synchronized (offline) mode!" part. There are a lot of challenges to writing a Conduit for the Palm Desktop, some of which come from our framework. It was really designed to be used in an application, with Models, and Views, and asynchronous network calls. I'm trying to use it in a dll with no UI, no application, and synchronous messages. It's a bit of a mis-fit, but it mostly works.

[Posted at 14:40 by Blake Winton] link
Sat, 11 Jan 2003

So when I was writing the first iteration of the tiny web browser I looked around on the Internet for stories from other people who had done the same sort of thing, so that I could hopefully avoid some of the dumber mistakes people had made, and if I was very lucky, perhaps I might even pick up some tricks to make my implementation smaller or faster. Sadly, though, I found nothing. So I forged ahead with my design, and said that when I was done, I would put my experiences up so that other people didn't have to repeat my mistakes, and could possibly learn from what I did correctly.

The first thing I think I did correctly was to break the stream up into elements, all of which had content to paint, and all of which had a bitfield of formatting flags. In my gadget, I would figure out the bounds for any given element, splitting a long bit of content up into several lines each with their own bounds. When the time came to paint the html, I would just loop through the elements, set the colour and font based on the format flags, and draw the string at the bounds. This made the drawing extremely fast, which was a good thing.

(Next issue, Limitations...)
[Posted at 21:12 by Blake Winton] link
Tue, 07 Jan 2003

A while ago, I wrote an HtmlViewer component for the Palm. It was hard, and I made a lot of assumptions on the basis that we would be getting our data from a server that we would also write, so it made more sense to have the server do anything that was necessary to the input stream to make it easier for the small device to display. (Things such as figuring out the widths of table cells, and making sure that any start tag also contained an end tag. You know, simple stuff.) The problem came when we started using my HtmlViewer to display content that we got from a client. The content was a complete mix of tags, and had no hope in hell of validating. As well, the server guys were swamped with other requests, and didn't want to write the code it would take to fix the html up. So my component broke. Colin (a co-worker) suggested that we just modify what I had to do what we wanted. After some discussion, I convinced him that it would be faster to re-write what was there so that it didn't make the same assumptions.


(To be continued...)
[Posted at 11:57 by Blake Winton] link
Sun, 05 Jan 2003
New Art!
Amy and I bought some new art this afternoon. I had recently seen a poster that I thought she would like, and so when we went by the store, we dropped in. It turned out there was another in the same series, and we agreed that they would look pretty good above the computer. So we got them, and hung them, and I put a picture up. The other picture is of a banana bread Amy made a while ago.
[Posted at 19:49 by Blake Winton] link
Wed, 01 Jan 2003
This is mainly here to test out the various features of the weblog.
[Posted at 21:12 by Amy Brown] link