Monday, January 31, 2011

Input separators

Did a little more work on tikiterm.py (my hand-rolled terminal widget in Python) at home this evening. Now I've got it to the point where there are designated "output" and "input" areas in each terminal window, and a graphical separator in between. Output to the terminal automatically appears above the separator. However, I haven't yet set up the event handlers needed to confine the insertion point to the input area, so the user can still, for example, select & replace text in the output area, or even the separator graphic itself. Fix this on Wednesday.


Actually, I went ahead and did this tonight, before bed. There are still some "gotchas" - like if the user selects stuff before (or overlapping) the start of the insert area, he can still use BackSpace to delete it. Haven't figured out an easy way to prevent that yet (unless I disable selections altogether). But, at least it now prevents the user from placing the insertion point outside of the input area, or backspacing past the start of the input area.

No comments:

Post a Comment