On 22.02.2021 1:45, Juha Manninen via lazarus wrote:
Help has improved lately thanks to Andrey Sobol's patches mostly.
However a new dependency was added: LazMouseAndKeyInput.
On Linux and UNIX systems it pulls in libXtst dependency.
LHelp is part of Lazarus BigIde target which is used for releases.
Extra dependencies for BigIde should be avoided if possible.

Now I studied how LazMouseAndKeyInput is used in LHelp.
Well, it is not used!
LHelpCore has MouseAndkeyInput in its uses section but removing it and the whole package dependency makes no difference.
My analysis: LazMouseAndKeyInput dependency can be removed from LHelp.
Am I right?

Regards,
Juha



Helo Juha,

You excluded this code from lcore.pas

procedure THelpForm.ShowApp();
......
{$IFDEF WINDOWS}
    // Go to TOC TreeView and to get focus on foreground window
    KeyInput.Apply([ssCtrl]);
    KeyInput.Press(VK_T);
    KeyInput.UnApply([ssCtrl]);
{$ENDIF}

Without the code on windows system we can`t get rightly a focus lHelp by an event of restore the window after hide (the window is blinking on an aplication panel sometimes). We should send an user input sentence to the foregroud window from a mouse or from keyboard to get focus (that is windows specific problem).

I see some solutions of that:
1. To rewrite that code by WinApi (that is simple).
2. To exclude the package dependency on Mac system, but I don`t know how?
3. To fix the Application.BringToFront() function at windows to rightly bring a foreground window to a front of a display.


But I don`t see that problem now :). May be the blinkg was also a part of that issue https://bugs.freepascal.org/view.php?id=38276

I redone many pieces after that, that a second round :)

--
Andrey Sobol
--
_______________________________________________
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus

Reply via email to