If you dock the Keyboard Macro widget to the IDE it will disappear when you change layouts and then return to the layout you docked with.
It also fails to respect the current IDE theme.
Strangely, Grep stays docked and is persistent across IDE layout changes. Maybe you can copy/paste the Grep docking code to Keyboard Macro?
See attached screenshot.
Delphi 13 with September patch
Windows 11-64
Hm, I don't remember doing anything to make Grep behave in this way. All dockable windows descend from a common ancestor and docking should be handled by the IDE. But I can reproduce this behavior, together with some other strange docking glitches.
And please only submit one bug per report, the IDE theme issue should be a separate report.