-
Notifications
You must be signed in to change notification settings - Fork 5.2k
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
Hide taskbar/Dock icon and menu bar #2246
Comments
I don't mind writing a Cocoa implementation, but I cannot design a good API without knowing more about the other platforms, so I require help for this. Some general feedback from core maintainers about this feature would also be useful. I am also a slight bit worried that this can cause issues for bundled applications1. Footnotes
|
Actually need this feature right now for a LWJGL wallpaper app... If it's not possible with GLFW I might just try to figure this out with SWT. Is there really no cross-platform/cross-toolkit implementation of making a window become a "background process" or desktop wallpaper? I can set the framebuffer to transparent and not decorate the window, but still shows up as a program on the taskbar in Cinnamon, Debian. Also trying to force it to the background but not sure how. |
@anthonywww I'm busy these days, so I don't have time to invest in it, at the moment. In addition, there's been no activity recently in GLFW, so the project seems to be on hold for now. |
This is a feature request to introduce a new API to GLFW to support "accessory" applications; applications with windows, but no taskbar/Dock icon, and no menu bar.
On MacOS, this internally uses
NSApplication.activationPolicy
withNSApplicationActivationPolicy
1.TYPE_REGULAR
=NSApplicationActivationPolicyRegular
TYPE_ACCESSORY
=NSApplicationActivationPolicyAccessory
TYPE_BACKGROUND
=NSApplicationActivationPolicyProhibited
I don't know Windows, but it seems like this has to be done per window. GLFW can save the state internally, and then apply this to all windows. There's the case of an application wanting N windows to have a taskbar icon, and M windows to not have that. This is not achievable on MacOS, but it should be possible to build an API which seamlessly supports this on Windows, without causing issues on MacOS. For instance, if this is a per-window flag/attribute, and not for the entire application, the Cocoa implementation can set the activation policy to
Regular
whenever a regular window is created, and change it toAccessory
when there's only accessory windows open. The application-wide state is useful for the case where there's no windows open. Some applications will prefer the Dock icon and application menu bar to show, while some will not.For a per-window state, some applications may even always want the Dock icon to show on MacOS, and may always want at least 1 taskbar icon on Windows.
I don't know how to implement this for X11 and Wayland.
Mode:
Possible APIs:
GLFW_APPLICATION_TYPE
,GLFW_APPLICATION_TYPE_REGULAR
,GLFW_APPLICATION_TYPE_ACCESSORY
andGLFW_APPLICATION_TYPE_BACKGROUND
GLFW_WINDOW_TYPE
,GLFW_WINDOW_TYPE_REGULAR
,GLFW_WINDOW_TYPE_ACCESSORY
andGLFW_WINDOW_TYPE_BACKGROUND
glfwShowApplicationIcon(bool)
glfwRepresentApplication(bool)
glfwSetApplicationType(int)
glfwSetWindowType(int)
or
or
This feature request spawned from this thread:
Implementing this functionality, will fix that issue, but this feature is not in itself required to fix it.
Replaces:
Related:
Footnotes
Only available on macOS 10.9 and above. Must emit
GLFW_FEATURE_UNAVAILABLE
on previous versions. ↩The text was updated successfully, but these errors were encountered: