core icon indicating copy to clipboard operation
core copied to clipboard

Desktop features: borderless window and systray

Open lujihong opened this issue 8 months ago • 4 comments

Describe the feature

Suggested Features:

Borderless Window: Allows creating windows without standard borders and title bars, enabling custom window designs and an immersive user experience.

Hide Taskbar Icon: Provides an option to prevent the application’s icon from appearing on the taskbar while running, suitable for applications that primarily run in the background or rely on a system tray icon.

System Tray Icon and Menu: Supports adding an icon to the system tray (notification area) with a context menu, allowing users to interact with the application conveniently from the tray.

These features will enhance Cogent Core’s flexibility and usability on the Windows platform.

Relevant code


lujihong avatar Mar 20 '25 03:03 lujihong

A systray app is an intriguing thought ; However, systray apps are specific to desktop.

I'm not sure I can picture that as a builtin feature for any platform besides desktop.

it should still be possible to include a systray app using other libraries like fyne.

Custom / borderless windows might also be an interesting feature as well - though, again, it presents challenges for cross-platform compatibility and might be a feature specific to desktop if it's ever implemented.

0pcom avatar Mar 25 '25 17:03 0pcom

@lujihong @0pcom Yes, these are interesting ideas that we can implement at some point, although they are not a very high priority for us given that they are platform-specific. However, they shouldn't be too hard to implement; we can use https://github.com/fyne-io/systray for the systray functionality, and we can set glfw.Decorated to gflw.False for the borderless window.

If anyone is interested in filing a PR for these features, that would be great. You can add fields to core.Stage for the systray and decoration control; a simple Decorated bool that defaults to true would work for that. If someone attempts this, please ask me any questions you have and I can help you get things working.

Otherwise, we will get to these features at some point, but not anytime soon.

kkoreilly avatar Mar 27 '25 11:03 kkoreilly

I want to know how to control the display and hiding of windows so that they can be used with a third-party tray library.

dosgo avatar Mar 27 '25 15:03 dosgo