Menu

#1028 Tab Code Completion bug

Undefined
open
nobody
Bug_Report
2020-11-03
2020-10-30
mhmdghfr
No

Like many code editors the Tab key is used to select the Highlighted code completion suggestion but in codeblocks (v.20.03 on windows 7 64bit) pressing the Tab key while the desired code completion is highlighted, wrongly completes another code (seemingly the first suggestion, not the highlighted one).
It only works if you first select the highlighted code by pressing the shortcut key Ctrl+Space and then pressing the Tab key that is very inconvinient compared to other modern IDEs since it cannot even be altered in Shortcut plugin.
I have included two screenshots of the process.

1 Attachments

Discussion

  • Teodor Petrov

    Teodor Petrov - 2020-10-30
    • labels: CodeCompletion, tab --> CodeCompletion
     
  • Teodor Petrov

    Teodor Petrov - 2020-10-30

    Are you able to reliably reproduce this? Can you do this in a file which doesn't include anything and it is part of a minimal project (just a single file)?

     

    Last edit: Teodor Petrov 2020-10-30
    • mhmdghfr

      mhmdghfr - 2020-10-30

      Yes, I just tested it in an empty one c file as the attached screenshots show, the problem still exists and regardless of the highlighted suggestion code, the first one in the list is entered into the editor after pressing the Tab key.

       
  • mhmdghfr

    mhmdghfr - 2020-10-30

    I tried another test, this time I browsed through three suggested code completions and selected the middle one, then pressed either Tab or Enter keys and again the first suggested code in the list was entered instead of the selected highlighted one.

     
  • Teodor Petrov

    Teodor Petrov - 2020-10-30

    It seems to work fine on Linux... So I guess it is a windows only problem. Have you tried a night build?

     
    • mhmdghfr

      mhmdghfr - 2020-10-30

      No, I have not tested the nightly builds. Maybe I try it later, but it would be good if someone could test it on a virtual machine sooner.

       
  • mhmdghfr

    mhmdghfr - 2020-11-03

    Hi,

    The other day I was checking my PATH string and I found out that an old installation of mingw was referenced at the end of the path string in "system variables" but the "user variables" was referencing to the updated mingw, and after deleting the old reference, suddenly the code completion was fixed!

    I wonder why it was this way since I had the compiler settings set to the new installation of mingw in the "Toolchain executables" of codeblocks (C:\CodeBlocks\MinGW)!

    Any way it sometimes again has some problems showing code completion at all where I used some other advice such as:
    - closing and opening Codeblocks
    - setting and and unsetting the "disable SmartSense" in the code completion plugin

    Thank you, the hint regarding the nightly builds was helpful in fixing the problem.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.