nikitabobko / AeroSpace

AeroSpace is an i3-like tiling window manager for macOS
https://nikitabobko.github.io/AeroSpace/guide
MIT License
7.56k stars 124 forks source link

PowerPoint Presentation Window (Fullscreen) not recognized #697

Open CheariX opened 1 week ago

CheariX commented 1 week ago

Describe the bug

If I start presenting a Microsoft PowerPoint presentation, the presentation window is not recognized by aerospace.

This is the output of aerospace debug-window

com.microsoft.Powerpoint.window.18996 windowId: 18996
com.microsoft.Powerpoint.window.18996 workspace: ö
com.microsoft.Powerpoint.window.18996 treeNodeParent: AppBundle.TilingContainer
com.microsoft.Powerpoint.window.18996 recognizedAsDialog: false
com.microsoft.Powerpoint.window.18996 AXTitle: Optional(Präsentation1)
com.microsoft.Powerpoint.window.18996 AXRole: Optional(AXWindow)
com.microsoft.Powerpoint.window.18996 AXSubrole: Optional(AXStandardWindow)
com.microsoft.Powerpoint.window.18996 AXIdentifier: Optional(_NS:8)
com.microsoft.Powerpoint.window.18996 AXFocused: Optional(0)
com.microsoft.Powerpoint.window.18996 AXFullScreen: Optional(0)
com.microsoft.Powerpoint.window.18996 AXFrame: Optional(<AXValue 0x600000363980> {value = x:3.000000 y:38.000000 w:1506.000000 h:940.000000 type = kAXValueCGRectType})
com.microsoft.Powerpoint.window.18996 AXPosition: Optional(<AXValue 0x6000018d25b0> {value = x:3.000000 y:38.000000 type = kAXValueCGPointType})
com.microsoft.Powerpoint.window.18996 AXGrowArea: nil
com.microsoft.Powerpoint.window.18996 AXMinimizeButton: AXUIElement {
com.microsoft.Powerpoint.window.18996      AXRole: Optional(AXButton)
com.microsoft.Powerpoint.window.18996      AXTitle: nil
com.microsoft.Powerpoint.window.18996      AXSubrole: Optional(AXMinimizeButton)
com.microsoft.Powerpoint.window.18996      AXEnabled: Optional(0)
com.microsoft.Powerpoint.window.18996      AXParent: AXUIElement(windowId=18996, title="Präsentation1", role="AXWindow", subrole="AXStandardWindow")
com.microsoft.Powerpoint.window.18996      AXTopLevelUIElement: AXUIElement(windowId=18996, title="Präsentation1", role="AXWindow", subrole="AXStandardWindow")
com.microsoft.Powerpoint.window.18996      AXWindow: AXUIElement(windowId=18996, title="Präsentation1", role="AXWindow", subrole="AXStandardWindow")
com.microsoft.Powerpoint.window.18996      Ignored: AXFrame, AXSize, AXFocused, AXHelp, AXPosition, AXRoleDescription
com.microsoft.Powerpoint.window.18996 }
com.microsoft.Powerpoint.window.18996 AXDocument: nil
com.microsoft.Powerpoint.window.18996 AXSections: [
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionDescription = Inhalt;
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x60000180de30> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXContent;
com.microsoft.Powerpoint.window.18996         }),
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionDescription = "Navigator der obersten Ebene";
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x60000180c450> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXTopLevelNavigator;
com.microsoft.Powerpoint.window.18996         }),
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionDescription = Symbolleiste;
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x60000180e520> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXToolbar;
com.microsoft.Powerpoint.window.18996         }),
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x60000180e040> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXContainer;
com.microsoft.Powerpoint.window.18996         }),
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x600001832580> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXContainer;
com.microsoft.Powerpoint.window.18996         }),
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x6000018306c0> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXContainer;
com.microsoft.Powerpoint.window.18996         }),
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x600001832610> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXContainer;
com.microsoft.Powerpoint.window.18996         }),
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x600001830600> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXContainer;
com.microsoft.Powerpoint.window.18996         }),
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x600001833b70> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXContainer;
com.microsoft.Powerpoint.window.18996         }),
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x600001830ea0> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXContainer;
com.microsoft.Powerpoint.window.18996         }),
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x600001832e50> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXContainer;
com.microsoft.Powerpoint.window.18996         }),
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x600001831d40> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXContainer;
com.microsoft.Powerpoint.window.18996         }),
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x600001831dd0> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXContainer;
com.microsoft.Powerpoint.window.18996         }),
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x600001832fa0> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXContainer;
com.microsoft.Powerpoint.window.18996         }),
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionDescription = Suchen;
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x600001830840> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXSearch;
com.microsoft.Powerpoint.window.18996         }),
com.microsoft.Powerpoint.window.18996         Optional({
com.microsoft.Powerpoint.window.18996             SectionDescription = Inhaltsnavigator;
com.microsoft.Powerpoint.window.18996             SectionObject = "<AXUIElement 0x600001833330> {pid=88277}";
com.microsoft.Powerpoint.window.18996             SectionUniqueID = AXContentNavigator;
com.microsoft.Powerpoint.window.18996         })
com.microsoft.Powerpoint.window.18996 ]
com.microsoft.Powerpoint.window.18996 AXCloseButton: AXUIElement {
com.microsoft.Powerpoint.window.18996      AXRole: Optional(AXButton)
com.microsoft.Powerpoint.window.18996      AXTitle: nil
com.microsoft.Powerpoint.window.18996      AXSubrole: Optional(AXCloseButton)
com.microsoft.Powerpoint.window.18996      AXEnabled: Optional(1)
com.microsoft.Powerpoint.window.18996      AXParent: AXUIElement(windowId=18996, title="Präsentation1", role="AXWindow", subrole="AXStandardWindow")
com.microsoft.Powerpoint.window.18996      AXTopLevelUIElement: AXUIElement(windowId=18996, title="Präsentation1", role="AXWindow", subrole="AXStandardWindow")
com.microsoft.Powerpoint.window.18996      AXWindow: AXUIElement(windowId=18996, title="Präsentation1", role="AXWindow", subrole="AXStandardWindow")
com.microsoft.Powerpoint.window.18996      Ignored: AXFrame, AXSize, AXFocused, AXHelp, AXPosition, AXRoleDescription, AXEdited
com.microsoft.Powerpoint.window.18996 }
com.microsoft.Powerpoint.window.18996 AXMain: Optional(0)
com.microsoft.Powerpoint.window.18996 AXActivationPoint: Optional(<AXValue 0x6000018432a0> {value = x:13.000000 y:52.000000 type = kAXValueCGPointType})
com.microsoft.Powerpoint.window.18996 AXFullScreenButton: AXUIElement {
com.microsoft.Powerpoint.window.18996      AXRole: Optional(AXButton)
com.microsoft.Powerpoint.window.18996      AXTitle: nil
com.microsoft.Powerpoint.window.18996      AXSubrole: Optional(AXFullScreenButton)
com.microsoft.Powerpoint.window.18996      AXEnabled: Optional(1)
com.microsoft.Powerpoint.window.18996      AXParent: AXUIElement(windowId=18996, title="Präsentation1", role="AXWindow", subrole="AXStandardWindow")
com.microsoft.Powerpoint.window.18996      AXTopLevelUIElement: AXUIElement(windowId=18996, title="Präsentation1", role="AXWindow", subrole="AXStandardWindow")
com.microsoft.Powerpoint.window.18996      AXWindow: AXUIElement(windowId=18996, title="Präsentation1", role="AXWindow", subrole="AXStandardWindow")
com.microsoft.Powerpoint.window.18996      Ignored: AXFrame, AXSize, AXFocused, AXChildren, AXHelp, AXPosition, AXRoleDescription
com.microsoft.Powerpoint.window.18996 }
com.microsoft.Powerpoint.window.18996 AXProxy: nil
com.microsoft.Powerpoint.window.18996 AXDefaultButton: nil
com.microsoft.Powerpoint.window.18996 AXMinimized: Optional(0)
com.microsoft.Powerpoint.window.18996 AXParent: Optional(<AXUIElement Application 0x6000018432a0> {pid=88277})
com.microsoft.Powerpoint.window.18996 AXTitleUIElement: nil
com.microsoft.Powerpoint.window.18996 AXCancelButton: nil
com.microsoft.Powerpoint.window.18996 AXModal: Optional(0)
com.microsoft.Powerpoint.window.18996 AXZoomButton: AXUIElement {
com.microsoft.Powerpoint.window.18996      AXRole: Optional(AXButton)
com.microsoft.Powerpoint.window.18996      AXTitle: nil
com.microsoft.Powerpoint.window.18996      AXSubrole: Optional(AXFullScreenButton)
com.microsoft.Powerpoint.window.18996      AXEnabled: Optional(1)
com.microsoft.Powerpoint.window.18996      AXParent: AXUIElement(windowId=18996, title="Präsentation1", role="AXWindow", subrole="AXStandardWindow")
com.microsoft.Powerpoint.window.18996      AXTopLevelUIElement: AXUIElement(windowId=18996, title="Präsentation1", role="AXWindow", subrole="AXStandardWindow")
com.microsoft.Powerpoint.window.18996      AXWindow: AXUIElement(windowId=18996, title="Präsentation1", role="AXWindow", subrole="AXStandardWindow")
com.microsoft.Powerpoint.window.18996      Ignored: AXFrame, AXSize, AXFocused, AXChildren, AXHelp, AXPosition, AXRoleDescription
com.microsoft.Powerpoint.window.18996 }
com.microsoft.Powerpoint.window.18996 AXSize: Optional(<AXValue 0x60000187c8d0> {value = w:1506.000000 h:940.000000 type = kAXValueCGSizeType})
com.microsoft.Powerpoint.window.18996 AXToolbarButton: nil
com.microsoft.Powerpoint.window.18996 Ignored: AXChildrenInNavigationOrder, AXChildren, AXRoleDescription
com.microsoft.Powerpoint              AXRole: Optional(AXApplication)
com.microsoft.Powerpoint              AXTitle: Optional(PowerPoint)
com.microsoft.Powerpoint              AXFunctionRowTopLevelElements: [
com.microsoft.Powerpoint              ]
com.microsoft.Powerpoint              AXFrame: nil
com.microsoft.Powerpoint              AXFocusedUIElement: AXUIElement(windowId=19009, title="Folie 1", role="AXLayoutArea", subrole=nil)
com.microsoft.Powerpoint              AXFrontmost: Optional(1)
com.microsoft.Powerpoint              AXExtrasMenuBar: nil
com.microsoft.Powerpoint              AXMainWindow: AXUIElement(windowId=19009, title="PowerPoint-Bildschirmpräsentation - [Präsentation1]", role="AXWindow", subrole="AXUnknown")
com.microsoft.Powerpoint              AXFocusedWindow: AXUIElement(windowId=19009, title="PowerPoint-Bildschirmpräsentation - [Präsentation1]", role="AXWindow", subrole="AXUnknown")
com.microsoft.Powerpoint              AXMenuBar: Optional(<AXUIElement 0x6000018d1950> {pid=88277})
com.microsoft.Powerpoint              AXWindows: [
com.microsoft.Powerpoint                  AXUIElement(windowId=19009, title="PowerPoint-Bildschirmpräsentation - [Präsentation1]", role="AXWindow", subrole="AXUnknown"),
com.microsoft.Powerpoint                  AXUIElement(windowId=18996, title="Präsentation1", role="AXWindow", subrole="AXStandardWindow")
com.microsoft.Powerpoint              ]
com.microsoft.Powerpoint              AXSize: nil
com.microsoft.Powerpoint              AXPosition: nil
com.microsoft.Powerpoint              Ignored: AXChildren, AXChildrenInNavigationOrder, AXEnhancedUserInterface, AXPreferredLanguage, AXRoleDescription, AXHidden

com.microsoft.Powerpoint.window.19009 windowId: 19009
com.microsoft.Powerpoint.window.19009 workspace: nil
com.microsoft.Powerpoint.window.19009 treeNodeParent: AppBundle.MacosPopupWindowsContainer
com.microsoft.Powerpoint.window.19009 recognizedAsDialog: true
com.microsoft.Powerpoint.window.19009 AXTitle: Optional(PowerPoint-Bildschirmpräsentation - [Präsentation1])
com.microsoft.Powerpoint.window.19009 AXRole: Optional(AXWindow)
com.microsoft.Powerpoint.window.19009 AXSubrole: Optional(AXUnknown)
com.microsoft.Powerpoint.window.19009 AXFocused: Optional(0)
com.microsoft.Powerpoint.window.19009 AXFullScreen: Optional(0)
com.microsoft.Powerpoint.window.19009 AXFrame: Optional(<AXValue 0x6000003e1140> {value = x:0.000000 y:0.000000 w:1512.000000 h:982.000000 type = kAXValueCGRectType})
com.microsoft.Powerpoint.window.19009 AXPosition: Optional(<AXValue 0x60000180f1b0> {value = x:0.000000 y:0.000000 type = kAXValueCGPointType})
com.microsoft.Powerpoint.window.19009 AXGrowArea: nil
com.microsoft.Powerpoint.window.19009 AXMinimizeButton: nil
com.microsoft.Powerpoint.window.19009 AXDocument: nil
com.microsoft.Powerpoint.window.19009 AXSections: [
com.microsoft.Powerpoint.window.19009         Optional({
com.microsoft.Powerpoint.window.19009             SectionDescription = Inhalt;
com.microsoft.Powerpoint.window.19009             SectionObject = "<AXUIElement 0x60000180c2d0> {pid=88277}";
com.microsoft.Powerpoint.window.19009             SectionUniqueID = AXContent;
com.microsoft.Powerpoint.window.19009         })
com.microsoft.Powerpoint.window.19009 ]
com.microsoft.Powerpoint.window.19009 AXCloseButton: nil
com.microsoft.Powerpoint.window.19009 AXMain: Optional(1)
com.microsoft.Powerpoint.window.19009 AXActivationPoint: Optional(<AXValue 0x6000018d2280> {value = x:-1.000000 y:983.000000 type = kAXValueCGPointType})
com.microsoft.Powerpoint.window.19009 AXFullScreenButton: nil
com.microsoft.Powerpoint.window.19009 AXProxy: nil
com.microsoft.Powerpoint.window.19009 AXDefaultButton: nil
com.microsoft.Powerpoint.window.19009 AXMinimized: Optional(0)
com.microsoft.Powerpoint.window.19009 AXParent: Optional(<AXUIElement Application 0x6000018d2280> {pid=88277})
com.microsoft.Powerpoint.window.19009 AXTitleUIElement: nil
com.microsoft.Powerpoint.window.19009 AXCancelButton: nil
com.microsoft.Powerpoint.window.19009 AXModal: Optional(0)
com.microsoft.Powerpoint.window.19009 AXZoomButton: nil
com.microsoft.Powerpoint.window.19009 AXSize: Optional(<AXValue 0x6000018fed90> {value = w:1512.000000 h:982.000000 type = kAXValueCGSizeType})
com.microsoft.Powerpoint.window.19009 AXToolbarButton: nil
com.microsoft.Powerpoint.window.19009 Ignored: AXChildrenInNavigationOrder, AXChildren, AXRoleDescription
com.microsoft.Powerpoint              AXRole: Optional(AXApplication)
com.microsoft.Powerpoint              AXTitle: Optional(PowerPoint)
com.microsoft.Powerpoint              AXFunctionRowTopLevelElements: [
com.microsoft.Powerpoint              ]
com.microsoft.Powerpoint              AXFrame: nil
com.microsoft.Powerpoint              AXFocusedUIElement: AXUIElement(windowId=19009, title="Folie 1", role="AXLayoutArea", subrole=nil)
com.microsoft.Powerpoint              AXFrontmost: Optional(1)
com.microsoft.Powerpoint              AXExtrasMenuBar: nil
com.microsoft.Powerpoint              AXMainWindow: AXUIElement(windowId=19009, title="PowerPoint-Bildschirmpräsentation - [Präsentation1]", role="AXWindow", subrole="AXUnknown")
com.microsoft.Powerpoint              AXFocusedWindow: AXUIElement(windowId=19009, title="PowerPoint-Bildschirmpräsentation - [Präsentation1]", role="AXWindow", subrole="AXUnknown")
com.microsoft.Powerpoint              AXMenuBar: Optional(<AXUIElement 0x60000180dfe0> {pid=88277})
com.microsoft.Powerpoint              AXWindows: [
com.microsoft.Powerpoint                  AXUIElement(windowId=19009, title="PowerPoint-Bildschirmpräsentation - [Präsentation1]", role="AXWindow", subrole="AXUnknown"),
com.microsoft.Powerpoint                  AXUIElement(windowId=18996, title="Präsentation1", role="AXWindow", subrole="AXStandardWindow")
com.microsoft.Powerpoint              ]
com.microsoft.Powerpoint              AXSize: nil
com.microsoft.Powerpoint              AXPosition: nil
com.microsoft.Powerpoint              Ignored: AXChildren, AXChildrenInNavigationOrder, AXEnhancedUserInterface, AXPreferredLanguage, AXRoleDescription, AXHidden

!!! DISCLAIMER !!!
!!! 'debug-windows' command is not stable API. Please don't rely on the command existence and output format !!!
!!! The only intended use case is to report bugs about incorrect windows handling !!!

Debug session finished

Note that there are two Powerpoint windows:

  1. 18996 which is on my workspace "ö" (shown as workspace: √∂ due to the umlaut)
  2. 19009 which is the actual fullscreen presentation window.

Window 19009 is automatically placed on workspace nil, which I did not define anywhere. Interestingly, I can switch to that workspace using aerospace workspace nil and I can see the presentation window.

However, switching to the window using aerospace focus --window-id does not work:

aerospace focus --window-id 19009
Window 19009 doesn't belong to any monitor. And thus can't even define a focused workspace

As indicated, the window does exist but it is not possible to focus that window.

FYI: this is a test on a single monitor setup. If I would start a presentation using two monitors, there will be two undetected fullscreen windows.