Bring window of another application on top of all other application windows lazarus / 66-Unix ---------------------------------------------------------------------- Ricco42 · 2024-02-25 14:46 Hi guys, I try to bring a specific window of another application on top of all other application windows if I press a button in my application. My OS is Ubuntu 20.04.3 LTS. My code highlights the other application in the Bottom Panel and if it was minimized it restores the window but it is not on top of all other application windows. Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i [...]uses  Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, StdCtrls,  xlib, x, ctypes, DateUtils;[...] procedure TForm1.Button4Click(Sender: TObject);var display: PDisplay;    fenster: TWindow;    root:TWindow;    standard_bildschirm:cint;    myevent:TXEvent;begin fenster:=$36000fc;  display := XOpenDisplay(nil); if (display = nil) then ShowMessage('Display Zugriff fehlgeschlagen :(');  standard_bildschirm:=DefaultScreen(displ ay);  root:=RootWindow(display,standard_bildschirm);  myevent._type:=C lientMessage; myevent.xclient.message_type:=XInternAtom(display,'_NET_ ACTIVE_WINDOW',false); myevent.xclient.window:=fenster; myevent.xclien t.format:=32;  XSendEvent(display,            root,            False,            VisibilityChangeMask            OR StructureNotifyMask          OR SubstructureRedirectMask            OR FocusChangeMask          OR PropertyChangeMask,            @myevent);  XMapWindow(display,fe nster);  XFlush(display);  XCloseDisplay(display); end; ---------------------------------------------------------------------- Ricco42 · 2024-03-04 21:02 Can be closed. Moved the post to » Programming » Operating Systems » Linux .