'Resize NSRunningApplication window

I would like to resize a window i got with the runningApplicationWithProcessIdentifier:(pid_t) function of NSRunningApplication class in the the AppKit framework.

Problem is that the NSRunningApplication object does include the .hide() and .unhide() functions but none to resize the window of the application.

Looking forward to your suggestions or solutions.



Solution 1:[1]

When I needed to adjust the size of the application window. I resized main window container is my app.

With the help of this: window.contentSize/contentMinSize/contentMaxSize

  • In visual editor for window:

enter image description here

  • In code:

enter image description here

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Vasiliy Neskafe