Button Clickable Area Bug
If a button does not have a background brush the clickable area is only the text bounds. I have to give it a background brush with a 0% opacity if I don't want to use the buttons background brush.
Re: Button Clickable Area Bug
Hi GausRoth, Dorian here,
Thanks for mentioning this; as this can be a bit of a tricky one. Basically this concept of an Element losing "Hit Test Visibility" if it has no 'fill' is something that is by design as part of the WPF framework that Noesis uses.
The reason for this is that in the framework, a 'geometry' is required to register a 'hit'.
And going one level deeper, a 'geometry' is defined by the 'fill' of an Element.
Because of this, an Element that has no 'fill', has no hitbox.
(note: lowercase 'conceptual' 'fill', that could manifest as a Background, Foreground, Stroke, Fill, etc...)
So with that said, the technique that you came up with where you set a Brush to 0% opacity (eg: #00FFFFFF), is actually the correct way to approach constructing a 'visually transparent' Element, that still offers a hitbox.
- Dorian
Thanks for mentioning this; as this can be a bit of a tricky one. Basically this concept of an Element losing "Hit Test Visibility" if it has no 'fill' is something that is by design as part of the WPF framework that Noesis uses.
The reason for this is that in the framework, a 'geometry' is required to register a 'hit'.
And going one level deeper, a 'geometry' is defined by the 'fill' of an Element.
Because of this, an Element that has no 'fill', has no hitbox.
(note: lowercase 'conceptual' 'fill', that could manifest as a Background, Foreground, Stroke, Fill, etc...)
So with that said, the technique that you came up with where you set a Brush to 0% opacity (eg: #00FFFFFF), is actually the correct way to approach constructing a 'visually transparent' Element, that still offers a hitbox.
- Dorian
Who is online
Users browsing this forum: No registered users and 4 guests