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

Fix headless window transparency #16058

Merged
merged 2 commits into from
Jun 19, 2024
Merged

Fix headless window transparency #16058

merged 2 commits into from
Jun 19, 2024

Conversation

Rosentti
Copy link
Contributor

What does the pull request do?

Fixes rendering headless windows that have transparent backgrounds, to actually render as transparent.

What is the current behavior?

The background of the rendered bitmap is white, although the Window's Background is set to "Transparent".
This makes it so if the user wants a transparent background, they can use TransparencyLevelHint where it previously was never transparent.

What is the updated/expected behavior with this PR?

The background is transparent if specifying it with TransparencyLevelHint and Background="Transparent"

How was the solution implemented (if it's not obvious)?

Changed the TransparencyLevel to Transparent to allow for transparent rendering.

Checklist

Breaking changes

Obsoletions / Deprecations

Fixed issues

@avaloniaui-bot
Copy link

You can test this PR using the following package version. 11.2.999-cibuild0049126-alpha. (feed url: https://nuget-feed-all.avaloniaui.net/v3/index.json) [PRBUILDID]

@cla-avalonia
Copy link
Collaborator

cla-avalonia commented Jun 19, 2024

  • All contributors have signed the CLA.

@Rosentti Rosentti marked this pull request as ready for review June 19, 2024 01:01
@Rosentti
Copy link
Contributor Author

@cla-avalonia agree

@maxkatz6 maxkatz6 added bug area-headless backport-candidate-11.1.x Consider this PR for backporting to 11.1 branch labels Jun 19, 2024
Copy link
Member

@maxkatz6 maxkatz6 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@maxkatz6 maxkatz6 added this pull request to the merge queue Jun 19, 2024
Merged via the queue into AvaloniaUI:master with commit b718045 Jun 19, 2024
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-headless backport-candidate-11.1.x Consider this PR for backporting to 11.1 branch bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants