There is one thing that has troubled me for long time (in every Delphi version since Delphi 2010). When I am typing code sometimes edit cursor jumps to one line above and I end up typing into wrong place. Has anyone else encountered this issue?

Comments

  1. Simon Stuart I have encountered this on different computers with different operating systems and different Delphi versions. I am using clean IDE without any add-ons I could blame.

    ReplyDelete
  2. Could this be a touch pad issue? I happen to touch the touch pad of my laptop sometimes with the palm om my hand whule typing and that causes a similar phenomena.

    ReplyDelete
  3. Roland Kossow I just have plain MS mouse.

    ReplyDelete
  4. Dorin Duminica Thanks for confirming.

    ReplyDelete
  5. Simon Stuart Nope, he is just encountering the same issue.

    ReplyDelete
  6. Simon Stuart I have Croatian keyboard Cherry G-83, it is a bit oldish (about 10-15 years, but I also had this with other keyboards). I don't think hardware is the probable cause. I am not experiencing this in any other editor, just Delphi. Android Studio works perfectly and so does Xcode on this same hardware (and I have been using both of them a lot).

    ReplyDelete
  7. Nope, never had that one.

    What I experience regularly and have done since I returned to Delphi is that the keyboard "behavior" changes to classic TP style (ie persistent selections, delete doesn't delete etc). Have to restart IDE to get it back to normal. Though I run both GExperts and CNPack so I've just assumed it's one of those.

    ReplyDelete
  8. Dalija Prasnikar The only place I have seen a behavior of this sort is on my laptop, where I am told, the only way to prevent it is to turn off the touch pad.

    ReplyDelete
  9. Never seen that.  Related to previous comments: Could it be a Windows locale related thing?  Do Dalija Prasnikar and Dorin Duminica have the same Windows locale? Do you have AltGr key combos?

    ReplyDelete
  10. Lars Fosdal Good point, always I'm using US english keyboard layout when using Delphi.

    ReplyDelete
  11. Right - but what about the locale settings?

    ReplyDelete
  12. Lars Fosdal everything is set to English United States, even the time(which is confusing for me) is set to 12h

    ReplyDelete
  13. I have the same problem since years now - but I thought all the time my mouse were/is the problem. It is an simple, old MS Mouse. Or my hasty fingers.

    No touchpad. German keyboard layout, locales also german.

    ReplyDelete
  14. Are you both maybe using some hotkey tool like AutoHotKey? That's the only reason I can think of if it is hardware independent. And with AutoHotKey I have had some weird issues myself.
    Oh, and then there is hardware: Some USB to serial adapters are detected up as a mouse by windows and can cause some very interesting effects.

    ReplyDelete
  15. Simon Stuart Daniela Osterhagen I don't have any suspicious software installed. I am pretty strict about things that are allowed to run on my computers.
    Only things that are running permanently (besides basic windows services) are MS Security Essentials and TortoiseHG Overlay Icon Server. And I had this issue well before I started to use any of those. 
    No special mouse or keyboard drivers or other tools that could interfere. 
    As I noted before I have this issue only in newer Delphi versions. Delphi 7 is working fine, and so are all other editors including web browsers.

    ReplyDelete
  16. Dalija Prasnikar You're not making this easy!

    ReplyDelete
  17. Lars Fosdal Croatian keyboard, Croatian locale, keyboard has AltGr functionality.
    Today I was just typing class declaration and cursor jumped in middle of  'class' word and my fingers were nowhere near Alt, Ctrl or any other key that could trigger such behavior.

    ReplyDelete
  18. Simon Stuart Dorin has everything set to English, and my settings are Croatian and Udo Treichel says he has German settings and keyboard.

    ReplyDelete
  19. Bill Meyer I know, I am not making this easy, and it is unreproducible bug. This is mostly why I didn't bother to report it for so long.
    But, now when I am spending most of my time using other tools and editors that work fine, it has started to really bug me.
    I use Android Studio all day, then I fire up Delphi and in matter of minutes edit cursor jumps.

    ReplyDelete
  20. Bill Meyer BTW, did you ever turned off touch pad on your laptop? It would be interesting to see if it happens with your touch pad turned off. Not that I am challenging you to do so.

    ReplyDelete
  21. Dalija Prasnikar I have not done so yet. I need to do that, to verify the results, but my brother suggested it, and has found issues in numerous laptops, all of which were solved in that way. Apparently the touchpad sensitivity at a distance above the pad is still sufficient to cause a move.

    ReplyDelete
  22. Bill Meyer The touchpad sensitivity does catch me off-guard  on my laptop, and it can happen with any software.  I have to be careful not to have my hands too close to the touchpad, when typing.

    ReplyDelete
  23. Daniel Rail And that's difficult to manage when using it as an actual laptop, on your lap.

    ReplyDelete
  24. Simon Stuart She did, but we're interleaving conversations. ;)

    ReplyDelete
  25. Simon Stuart Just one line up and it happens during typing.

    ReplyDelete
  26. Simon Stuart Yes, but my fingers are usually nowhere near arrows :) 
    There is no pattern, it just happens randomly and it can happen anywhere in code.

    ReplyDelete
  27. Simon Stuart I know you didn't suggested that I was hitting the arrow, that is why I used smiley.

    Don't get too worked up on this, it is hopeless. The only way this can be found and solved is by looking at IDE code. I don't think that any kind of guessing will do. 

    I just wanted to confirm that other people are seeing this so I can file bug report. I don't want it to get closed as cannot reproduce and the only way is to get some confirmation from others experiencing same thing.

    ReplyDelete
  28. What about special key combinations? I remember: in the dark ages of computing there where special key combinations used by editors like Wordstar. In Delphi we can use lots of them, like +. I do not remember, maybe there is one for moving up the cursor one line, hitting accidently? That was my second thought.

    ReplyDelete
  29. Udo Treichel I use those dark ages combinations, but you have to press Ctrl for them to work.

    ReplyDelete
  30. Udo Treichel Dorin Duminica What Delphi versions are you using? I am currently at XE4

    ReplyDelete
  31. Udo Treichel I have just tested it out, and in default IDE key mappings configuration that I am using, Ctrl+E that would be WordStart command for going up is no longer working, nor are any other "moving" commands. 
    I didn't realized that before, because I am only using WordStart block commands that are still functioning.

    ReplyDelete
  32. Dalija Prasnikar Without any plug-ins? That seems very odd. Sufficiently odd that it may be a clue to what is going on. But I have no idea what that clue might mean....

    ReplyDelete
  33. Bill Meyer If I have to suffer from bugs, I prefer to suffer from original ones ;-)
    That also makes reporting bugs easier. If there is something wrong it is all Delphi's fault.

    ReplyDelete
  34. Dalija Prasnikar Because original pain is so much better than derived pain? 

    I'm still trying to imagine how some of the shortcuts could be broken. This has moved from difficult to baffling.

    Have you tried changing the key mappings to a different selection, then back again? Just wondering whether that would affect the problem with Ctrl+E, for example.

    ReplyDelete
  35. Bill Meyer shortcuts are not broken, they just have different actions now. I was trying to say that I can eliminate WordStar moving shortcuts as cause of the problem because they do not work anymore. So I cannot accidentally use Ctrl+E to go one line up while editing code.

    ReplyDelete
  36. Dalija Prasnikar I see. I did not understand your meaning. Then definitely baffling.

    ReplyDelete
  37. Asbjørn Heid I get the bug where the editor goes into old-style editing (persistent selections) etc too, but I don't have to restart the IDE to fix it. Closing the current tab and reopening the unit is enough.

    ReplyDelete
  38. Bill Meyer Well, one thing that is baffling is that I expected either more people seeing this issue or none.
    It seems that this is not that wide spread and on the other hand it is not specific only for my hardware/software combinations (even though I am having same issue on different computers).

    ReplyDelete
  39. Dalija Prasnikar Even more baffling is that although so few seem to have experienced it, you experience it on multiple machines. At a very risky guess, that may point to some issue with internationalization settings? It would be worth knowing, I think, for those who experience the problem, what their locales are.

    ReplyDelete
  40. Bill Meyer I don't think that locale settings are the problem because Dorin Duminica has all English settings.

    ReplyDelete
  41. Dalija Prasnikar Yes, I overlooked that. But I think that the two of you need to look for what is the same between you, in things changed since installation of Delphi.

    It would be much better if a few other people reported similar problems.

    ReplyDelete
  42. OK, I have a similar problem: I see "unwanted insert" often instead of "unwanted arrow up", XE4 + German keyboard.

    ReplyDelete
  43. Have looked up Ascii codes and tested with Ctrl-E. Found a feature! Not only does Ctrl-E bring up incremental search, it also ends column selection mode (go into this mode with Shift-Alt-Arrow).

    vkUp              = $26;  {  38 }
    vkInsert        = $2D;  {  45 }
    vk8                = $38;  {  56 }
    vkE                = $45;  {  69 }


    (But I failed to fake an arrow up.)

    ReplyDelete
  44. David Millington Ah thanks, I'll try that next time.

    ReplyDelete
  45. Had a similar problem with XE7 on a laptop running windows 8.1. It was very painful. Though I was using a normal mouse, after updating the touch pad driver the problem seems to be resolved, though the issue now is that sometime when you click on a line to move the cursor it doesn't always move on the first click.

    ReplyDelete

Post a Comment