Welcome, Guest
Username: Password: Remember me
CodeTyphon MS Windows (Win7, Win8.x, Win10 and Win11) OS Development, discussions and problems
  • Page:
  • 1

TOPIC:

AutoComplete and Taskbar issues 2 days 21 hours ago #18792

  • Premysl Beran
  • Premysl Beran's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 54
  • Thank you received: 0
Hello,
Lately, I have wanted to add autocomplete functionality to my application editor form, and I figured out some strange behaviour of the forms and the taskbar buttons. I prepared a simple testing project that replicated it.

Here is the description. I have a main form that is open when the application is launched. When clicked on the button, a new form with the editor opens.

If I set the property ShowInTaskBar := stDefault on both forms. In this situation, when you activate the autocomplete function on the editor (Ctrl+Space) all works fine as expected. However, I would like to have the editor in the taskbar as a separate button. So, my default setting is the following.

Property ShowInTaskBar := stDefault for the main form, and for the editor form, I set it to stAlways (in the test project, you can just click the checkbox and open a new editor form). In this case, when I activate the autocomplete function, the editor form loses focus, and the main form is in the foreground with the autocomplete selection on it. The editor form is not visible if the main form is maximised. When the autocompletion is selected, the editor form gets focused again and is moved to the foreground. This is very annoying.

I tried to set  ShowInTaskBar := stAlways to both forms (also the main form). In this case, the editor form doesn't lose focus when the autocomplete function gets activated, but when the application is launched (only the main form is visible), there are two buttons in the taskbar. One with the name of the form and one with the name of the project. 

Please, can you check if you have the same behaviours or if I am doing something wrong? Thanks in advance.

Note: When compiled on Linux and macOS, all works fine. The editor doesn't lose focus when the autocomplete function is activated. 

System: Windows 10
CT: version 8.50

 

Please Log in or Create an account to join the conversation.

AutoComplete and Taskbar issues 1 day 23 hours ago #18794

  • Matis A.
  • Matis A.'s Avatar
  • Away
  • Moderator
  • Moderator
  • Posts: 1152
  • Thank you received: 175
My suggestion is to set EditorForm.FormStyle to fsStayOnTop
PilotLogic Core Programmer

Please Log in or Create an account to join the conversation.

Last edit: by Matis A..

AutoComplete and Taskbar issues 1 day 22 hours ago #18795

  • Premysl Beran
  • Premysl Beran's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 54
  • Thank you received: 0
Hi Matis,

Thanks for the suggestion. I tried this programmatically. I set StayOnTop before the autocomplete execution, and when it ended, I put it back to fsNormal. When putting it back to fsNormal the form blinked (it lost focus and got it right back). Very annoying. 

But I don't want the editor StayOnTop all the time. The medium working solution to set ShowInTaskbar := stAlways also for the main form. But there is this strange additional button in the taskbar (see picture below).


 
Attachments:

Please Log in or Create an account to join the conversation.

Last edit: by Premysl Beran. Reason: Wrongly added picture
  • Page:
  • 1