I've managed to fix and clean up more code in the last two days than in the last four months simply by throwing out these broken toolkit parts and writing my own display class. Bugs that I never could figure out are gone; workarounds for problems that should never have been there in the first place are no longer needed. It displays, it's solid, and it works. I've been mudding with it all day long.
So far, I have a fairly primitive display class with a scroll bar, display window, and border that changes color when it locks. The display window has primitive and buggy line wrapping, but it's usable. There is currently no URL clicky support or select/copy support. Performance is even pretty good.
Performance isn't as good as it should be though - when resizing narrow, it takes far too long to recalculate line numbers. I suspect most of the time doing this is spent in pointless object conversions between various objects. First thing tomorrow, I'm going to be switching over most of the wxString objects to regular const char *'s. There's an awful lot of string processing that needs to be done, and doing it in wxString land is problematic.
After that, I need to rework the way the line data is stored so I can handle select/copy and proper line wrap. This same code will also help with URL support, so it's possible that all three could be done pretty quickly. At this point, the display window is fully featured.
Next up, after the display window, is the typing bar/input window. This one is more troublesome; it's one of those things I'd really rather not re-implement, but I suppose if I have to I can. Either way, I have to do something with it:
1) The input bar beeps if you backspace too far. This is a show-stopper. Computers should NOT make noise unless actively requested to, especially for trivially ignored failure cases. It appears to be impossible to turn off this buggy behavior in the library.
2) It also appears to be impossible to reliably set and maintain the font and font color for this object. Backspacing until it's empty often has unpredictable results. No modifications to the class have been made, and it produces different results on different windows versions more and less frequently. This smacks of being a library/DLL bug.
Hopefully I can find some other input window class that is less problematic, and still have multi-line support. Multi-line paste is mandatory, as I paste a lot of notes and descriptions.
Wednesday, February 11, 2009
Subscribe to:
Post Comments (Atom)
6 comments:
i would like to be able to change the size of the window that i type into on the custom client, like in most windows programs. when you move your cursor over the top bar of the typing window i would like a little resizer cursor thingy to appear.
also, the map sizes for the auto-mapper on the most recent release of the client seem confusing.
they say:
big map
medium map
small map
bigger map
smaller map
maybe something like this would be better:
giant map
big map
medium map
small map
micro map
or perhaps the additional ability to resize the map at will as suggested with the window where you type stuff in.
also, when i turn blind mode on in the client, i can no longer see what i'm typing in the window thinger. if this is intentional, it ought to be togglable.
There's a new board on the Alter Aeon Player Forums for client feature requests and the like. That will be the best place to put comments and the like in the future.
I'll try to grab these and make sure they don't get lost. Some are harder than others though.
why don't you just use Qt rather than that piece of shit wxWidgets. You complain about it. Use something else.
QT has licensing issues (I want to release a single static binary), and it has size issues (an 8 MB executable is unacceptable at this time.)
Note that since this post I've written my own versions of the primitives that were giving me problems in wxWidgets, so it's less of an issue now.
Post a Comment