Hi folks, will it be possible to hide the window t...
# compose-desktop
s
Hi folks, will it be possible to hide the window toolbar on top when it is not needed?.
k
Completely hide or extend your content into that area? Completely hiding the title is controlled by passing
undecorated=true
to your
Window
composable. Once you do that, you lose everything provided by the native OS window decorations - resizing, minimizing, maximizing, dragging, etc - and you'll need to provide that functionality yourself.
s
1. I am trying to hide it completely. I have set the
undecorated=true
attribute, and it seems to work fine. However, will it be possible to add dragging and resizing support for this element? Do you have any sample code? 2. Could we get a
tint
or
blur effect
on the window toolbar?
k
androidx.compose.foundation.window.WindowDraggableArea
can be used to get the draggable title bar. There is nothing that I know of yet that would provide out of the box support for resizing an undecorated window from edges and corners. I have some sample code at https://github.com/JetBrains/compose-jb/issues/1773 but the resizing overall (which might be coming as Swing / AWT legacy) is pretty janky. Tinting, translucency, blurring are available if you drop down to the underlying native OS APIs (mica / acrylic on Windows, for example), but there's nothing that would expose that at the Compose window level. Nor am I sure that such APIs can realistically be provided given different approaches by the platforms.
t
s
Thanks! It is working 👍