chicken-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Chicken-users] Chicken/tk widgets can't handler certain characters


From: Matt Gushee
Subject: [Chicken-users] Chicken/tk widgets can't handler certain characters
Date: Sat, 23 Apr 2005 13:30:23 -0600
User-agent: Mozilla Thunderbird 1.0 (X11/20050108)

I guess the subject line is pretty self-explanatory. I have discovered that, (at least on my system), when you attempt to load text containing certain characters into certain types of widgets, it causes errors, up to and including segfaults. So far, the bad characters that I know of are '[' and '$', and the problem affects text and listbox widgets. I would guess it also affects canvas text items, but I haven't tested them. It does not appear to affect labels.

The errors don't happen if the characters are escaped; that works for '$', which can be escaped as '\x24'. However, the escape sequence for '[' would be '\x5B', and neither the interpreter nor the compiler seem to be able to handle that--they think it's the beginning of ... a list? Anyway, if you try to use '\x5B', Chicken waits for whatever-it-is to end, and of course it doesn't end. I suppose in principle one could use '\u005B', but my build of Tk doesn't seem to support Unicode escapes. I suspect that is the case with many stock Tcl/Tk installations. And I want my package to be easy to install, so people shouldn't have to compile Tk in order to use it.

Very unfortunate for me, since I was developing a file manager with an internal file viewer, so it needed to be able to load arbitrary files into a text widget; most directory listings are not a problem, but I happen to have tested the app on /usr/bin, which contains the file name "[".

In case it makes a difference, I have

    Chicken 1.89
    latest chicken/tk (? I guess--just installed with chicken-setup a
      few days ago)
    Tcl/Tk 8.4.9
    ... on Linux.

--
Matt Gushee
Englewood, CO, USA





reply via email to

[Prev in Thread] Current Thread [Next in Thread]