Recent

Author Topic: Lazarus icon disappears from Alt Tab on Windows  (Read 3382 times)

valdir.marcos

  • Hero Member
  • *****
  • Posts: 822
Lazarus icon disappears from Alt Tab on Windows
« on: August 13, 2018, 11:21:42 am »
Lazarus icon disappears from Alt Tab on Windows (see attached images).

Lazarus icon appears on Alt Tab most of the time, but when I open options in Object Inspector such as Editing SQL, the icon disappears and I cannot come back using keyboard. I have to use mouse to come back to Lazarus.

Is it a bug?

Noodly

  • Jr. Member
  • **
  • Posts: 70
Re: Lazarus icon disappears from Alt Tab on Windows
« Reply #1 on: August 13, 2018, 11:37:52 am »
I don't have this problem with Win 10 / Laz 1.8.2

You didn't mention your Win / Laz versions.
Windows 10 Home, Lazarus 2.02 (svn 60954), FPC 3.04

taazz

  • Hero Member
  • *****
  • Posts: 5363
Re: Lazarus icon disappears from Alt Tab on Windows
« Reply #2 on: August 13, 2018, 11:47:35 am »
Lazarus icon disappears from Alt Tab on Windows (see attached images).

Lazarus icon appears on Alt Tab most of the time, but when I open options in Object Inspector such as Editing SQL, the icon disappears and I cannot come back using keyboard. I have to use mouse to come back to Lazarus.

Is it a bug?
yes its one of those that are impossible to ttrack down although it only happens with modal dialogs. As for the go back from the keyboard part thats all on your lack of imagination there multiple ways to navigate using the keyboard for example press the win key to focus the task bar one esc to close the menu and now you can use tab and the arrow keys to navigate the icons on the task bar, but the easiest and faster to use is to use the win+tab combination I think that the IDE is present in that list not sure though.
Good judgement is the result of experience … Experience is the result of bad judgement.

OS : Windows 7 64 bit
Laz: Lazarus 1.4.4 FPC 2.6.4 i386-win32-win32/win64

wp

  • Hero Member
  • *****
  • Posts: 6231
Re: Lazarus icon disappears from Alt Tab on Windows
« Reply #3 on: August 13, 2018, 11:49:38 am »
I don't see it with Win 10 either (Laz trunk), but I do see the issue with Win 7 (Laz trunk, too). At first I thought that the issue is related to modal component editors in general, because the SQL Editor is modal, but the issue does not occur for the ImageList Editor which is modal, too.

With other IDE dialogs do have this issue?
Lazarus trunk / fpc 3.0.4 / all 32-bit on Win-10

valdir.marcos

  • Hero Member
  • *****
  • Posts: 822
Re: Lazarus icon disappears from Alt Tab on Windows
« Reply #4 on: August 13, 2018, 12:13:28 pm »
You didn't mention your Win / Laz versions.
Windows 7 Professional 64 bit
Lazarus 1.8.2 FPC 3.0.4

valdir.marcos

  • Hero Member
  • *****
  • Posts: 822
Re: Lazarus icon disappears from Alt Tab on Windows
« Reply #5 on: August 13, 2018, 12:19:39 pm »
yes its one of those that are impossible to ttrack down although it only happens with modal dialogs.
Yes, it seems to be modal dialogs' problem.

Quote
As for the go back from the keyboard part thats all on your lack of imagination there multiple ways to navigate using the keyboard for example press the win key to focus the task bar one esc to close the menu and now you can use tab and the arrow keys to navigate the icons on the task bar, but the easiest and faster to use is to use the win+tab combination I think that the IDE is present in that list not sure though.
Yes, the win+tab combination would be the easiest and fastest solution.

valdir.marcos

  • Hero Member
  • *****
  • Posts: 822
Re: Lazarus icon disappears from Alt Tab on Windows
« Reply #6 on: August 13, 2018, 12:27:56 pm »
I don't see it with Win 10 either (Laz trunk), but I do see the issue with Win 7 (Laz trunk, too). At first I thought that the issue is related to modal component editors in general, because the SQL Editor is modal, but the issue does not occur for the ImageList Editor which is modal, too.

With other IDE dialogs do have this issue?
Yes, it seems to be a modal dialogs' problem.
Windows 7 Professional 64 bit
Lazarus 1.8.2 FPC 3.0.4

The problem also happens on (modal dialogs):
TreeView.Color
ImageList.BkColor
DBGrid.Hint

But it doesn't happen on (not modal dialogs):
TreeView.Anchors
DBGrid.Columns

valdir.marcos

  • Hero Member
  • *****
  • Posts: 822
Re: Lazarus icon disappears from Alt Tab on Windows
« Reply #7 on: August 13, 2018, 12:37:56 pm »
Not dramatic, but annoying.

wp

  • Hero Member
  • *****
  • Posts: 6231
Re: Lazarus icon disappears from Alt Tab on Windows
« Reply #8 on: August 13, 2018, 04:41:53 pm »
Here: Windows 7 Home Premium 32 bit in VirtualBox
Lazarus trunk FPC 3.0.4

The problem also happens on (modal dialogs):
TreeView.Color
ImageList.BkColor
DBGrid.Hint

But it doesn't happen on (not modal dialogs):
TreeView.Anchors
DBGrid.Columns
All confirmed.

But:
ImageList Component Editor (modal dialog)
- no problem if opened by double-click on ImageList, or by ImageList's context menu (item "Image List Editor")
- problem if opened from the ImageList node in the object tree above the object inspector (context menu, again "Image List Editor").

Memo "Change Class" (modal dialog)
- no problem if opened from the context menu of the memo
- problem if opened from the context menu of the Memo's node in the object tree.
Lazarus trunk / fpc 3.0.4 / all 32-bit on Win-10

valdir.marcos

  • Hero Member
  • *****
  • Posts: 822
Re: Lazarus icon disappears from Alt Tab on Windows
« Reply #9 on: August 13, 2018, 05:34:20 pm »
Here: Windows 7 Home Premium 32 bit in VirtualBox
Lazarus trunk FPC 3.0.4

The problem also happens on (modal dialogs):
TreeView.Color
ImageList.BkColor
DBGrid.Hint

But it doesn't happen on (not modal dialogs):
TreeView.Anchors
DBGrid.Columns
All confirmed.

But:
ImageList Component Editor (modal dialog)
- no problem if opened by double-click on ImageList, or by ImageList's context menu (item "Image List Editor")
- problem if opened from the ImageList node in the object tree above the object inspector (context menu, again "Image List Editor").

Memo "Change Class" (modal dialog)
- no problem if opened from the context menu of the memo
- problem if opened from the context menu of the Memo's node in the object tree.
Should I open a bug report on Mantis?

ASerge

  • Hero Member
  • *****
  • Posts: 1406
Re: Lazarus icon disappears from Alt Tab on Windows
« Reply #10 on: August 13, 2018, 05:51:56 pm »
If the owner of the dialog has the WS_EX_TOOLWINDOW style, owner is not displayed, as described in the Microsoft documentation "A tool window does not appear in the taskbar or in the dialog that appears when the user presses ALT+TAB".

Code show this:
Code: Pascal  [Select]
  1. procedure TForm1.FormActivate(Sender: TObject);
  2. var
  3.   Form: TForm;
  4. begin
  5.   Form := TForm.CreateNew(Application);
  6.   try
  7.     Form.ShowModal; // Application visible by Alt+Tab
  8.     Self.BorderStyle := bsToolWindow;
  9.     Form.ShowModal; // Application NOT visible by Alt+Tab
  10.     Self.BorderStyle := bsDialog;
  11.     Form.ShowModal;  // Application visible by Alt+Tab
  12.   finally
  13.     Form.Free;
  14.   end;
  15. end;
Object Inspector has this style.