I encounter a serious problem on a TCL/TK application. When I click on "Home", the cursor goes to the beginning of the paragraph and not to the beginning of the line. The same with the "End" key. It goes to the end of the paragraph and not to the end of the line. Finally, to top it all off, when I use the up or the down arrows, they don't move the cursor to the line above or below; they move it to the line where the paragraph starts or ends. What causes this serious and very painful problem? What do I do to fix it? Thanks! [NEM]: Wait for Tk 8.5 (or use an alpha release): TIP 155[http://www.tcl.tk/cgi-bin/tct/tip/155.html] provides the functionality you need, AIUI. (BTW, it's not generally a good idea to use this wiki for questions, and less so to create a new page for a single question. news:comp.lang.tcl is a better place for such queries.) I will. Thanks so much Neil. I went on your homepage and I was impressed at the diversity of projects you got involved in. True inventors (like you) touch a lot of everything before they come up with the one excellent idea that will revolutionize the world. Keep it up Doctor Madden! Well not quite Doctor yet; in a few months from now you will be able to use this title! When that happens, you'll be astonished at the people who will call you to come cure them... A doctor is still seen as many as the man with a stethoscope! :-) [MG] Jan 27th 2005 - The page [Move cursor by display line in a text widget] also shows a pure-Tcl way to fix this in 8.4, which may be better for now, as many people aren't using 8.5 yet. One thing this doesn't fix, however, is the Control-Up / Control-Down bindings (for going to the beginning of the previous/next paragraph). Thanks MG. It seems that the program does not seem to see an end of line and it can only see this when a return has been made. It thus treats a series of lines as one single line! Please don't tell me that this sort of problem can only be solved in a latter version of TCL! This is such a basic feature that I fail to see how this problem could not have been addressed very early on! Tell me I am mistaken! [MG] Feb 5th 2005 - It's the way that the text widget is coded internally that causes the problem. There's no way to get around it before Tcl 8.5, other than by recoding the text widget bindings; internally, the [text] widget just doesn't support display lines sufficiently. So, I'm afraid you'll either have to use alternative bindings every time you need it, or wait for 8.5. [LV] Actually, the above comments refer to the ''Finally'' portion of your question. Which platforms show the Home and End behavior? On SPARC Solaris GNOME, I see the opposite behavior. What's interesting though is that I would have expected HOME to take me to the top of the file and End to take me to the last line of the file. Normally, I'd expect Control-A to take one to the beginning of the line and Control-E to the end line. [LES]: Sure, you are an [emacs] addict. A [vi] addict could reasonably expect '''^''' to take one to the beginning of the line and '''$''' to the end of the line. So, instead of hard-coding these things with key bindings, perhaps the new improvements should concentrate on events only. Then it's up to each developer to decide which key binding will trigger each one of those specific events. And, just for the record, [Move cursor by display line in a text widget] really solves the problem described at the top of this page, but it kills Control + Home. [MG] Normal behaviour as I'd expect it (bearing in mind I'm a clueless Windows user:) is for Home/End to do the beginning/end of a line, and Control + Home/End to do the beginning/end of the document. As far as I can recall, there isn't usually any way in Windows apps to do "start of the paragraph" with the Home/End keys. [Robert Abitbol] Yes you are right, Mike. That is the way it works in Windows [LV] Turns out that because of the fix via the Page above, the Home and End keys were working '''correctly'' for me as described above. If I removed the change, the behavior went back to the ''broken'' behavior originally described. [Robert Abitbol] 8.5 sure fixes the Home/End problem but it creates a whole lot of other problems along the way. When I use tcl kit 8.5 with a TCL editor I have had programmed (working with Windows 98), I get error messages all the time for almost every task required! The error message is always "the program has performed an illegal function and will be terminated". And '''boum''' I am out of the program. It's pretty frustrating. :-( I'd rather not use 8.5 at this stage for the cure seems to bring more problems than the disease so '''does anyone have an idea how to solve the Home/End keys problem without upgrading to 8.5?''' ---- [Category Discussion][Category GUI]