-
Notifications
You must be signed in to change notification settings - Fork 1.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
Adding transparent windows information to the Window API tutorial #1601
Conversation
Also closes #1339
tutorials/Window_API_new/README.md
Outdated
} | ||
``` | ||
|
||
_Important note: Window transparency is implemented based on JDK implementation, that contains known issue in case of moving a Window between two monitors with different density. So when you move an App, the Window stops being transparent. And it seems nothing can be done with this situation on Compose side. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a Linux only issue. Everything is fine on macOS and Windows.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
tutorials/Window_API_new/README.md
Outdated
@@ -605,3 +605,46 @@ private fun WindowScope.AppWindowTitleBar() = WindowDraggableArea { | |||
} | |||
``` | |||
<img alt="Draggable area" src="draggable_area.gif" height="239" /> | |||
|
|||
## Transparent windows (e.g. allows to make windows of a custom form) | |||
To create a transparent window it is enough to pass two parameners to the Window function: transparent=true and undecorate=true (it is not possible to decorate a transparent Window). Common scenario is to combine transparent window with a Surface of a custom form. Below is an example of a round-cornered Window. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should quote parameters/methods/classes and other appropriate names. Like
transparent=true
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
…tBrains#1601) * Adding transparent windows information Also closes JetBrains#1339 * Update README.md
Also closes #1339