Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow for variable length status indicators in Mac OS #10325

Open
h1bernate opened this issue Jul 30, 2024 · 0 comments
Open

Allow for variable length status indicators in Mac OS #10325

h1bernate opened this issue Jul 30, 2024 · 0 comments

Comments

@h1bernate
Copy link

Describe the project you are working on

Currently leveraging Godot for a desktop UI application on MacOS. It contains multiple windows and would benefit from being able to use status indicators in the system tray to connect and bridge the interactions between different windows.

Describe the problem or limitation you are having in your project

Using version 4.3.beta3.mono and the StatusIndicator Node which was implemented by @bruvzg earlier this year, applications can utilize status bar in Mac OS in this PR.

The current implementation appears to require all icons to be squares even if the original texture has non-square dimensions, which makes sense when compared to indicators for Windows. But this limits the length and utility of that real estate in the system tray menu. For example, I would like to put both an icon that represents the application as well as a label to display relevant detail without requiring the user to click on the icon or see the popup menu.

Describe the feature / enhancement and how it helps to overcome the problem or limitation

Instead of forcing all StatusIndicator.icon textures to be squares, allow for non-square textures to affect the length of the indicator.

Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams

In perusing the Appkit documentation for Mac OS, it appears that there is an option for
variable length status indicators. Currently, it is fixed to using a "square" status length in

	IndicatorData idat;

	idat.item = [[NSStatusBar systemStatusBar] statusItemWithLength:NSSquareStatusItemLength];
        ...

Possible implementations include:

  1. When the underlying OS permits, allow for non-square indicators when the icon texture is not square.
  2. Provide an option on StatusIndicator Node to enable or allow for non-square indicators.

If this enhancement will not be used often, can it be worked around with a few lines of script?

No real workaround exists except to use square indicators and change the UI.

Is there a reason why this should be core and not an add-on in the asset library?

If StatusIndicator node is already core, this functionality is closely related and would make sense to remain in core as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants