Skip to content

Hide properties if they are not usable on this control #64

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

Open
DevTKSS opened this issue Feb 25, 2025 · 4 comments
Open

Hide properties if they are not usable on this control #64

DevTKSS opened this issue Feb 25, 2025 · 4 comments

Comments

@DevTKSS
Copy link

DevTKSS commented Feb 25, 2025

Current behavior

e.g. the Background Property on a TextBlock seems to be not available but is shown in the intellisense and studio also, but if it is set, nothing happens

TextBlock.Issue.mp4

Expected behavior

In cases like this, maybe those Propertie Fields should be hidden, so the User Expirience is not disturbed from nothing happens

Which tool(s) are affected?

Hot Design™

How to reproduce it (as minimally and precisely as possible)

dotnet new unoapp -preset blank -toolkit false -tfm net9.0 -platforms desktop -presentation mvux -markup xaml -theme material -di -nav regions -log default

open Presentation\MainPage.xaml or not not really making a difference
Start Debug and enter Studio
(dont know if this is relevant: set the Style to DisplaySmall in Studio UI)
now try to change the Background Property which is presented in the Studio

Workaround

try to use those Properties and recognize they are not implemented althought they are shown

Affected platforms

Desktop (Skia)

Uno.Sdk version

5.6.37

IDE used

Visual Studio 2022

IDE version

17.13.1

Uno Platform Extension version

1.2.18

Relevant plugins

No response

Anything else we need to know?

UnoApp3.zip
Minimal Repro if needed

@DevTKSS DevTKSS added difficulty/tbd triage/untriaged Indicates an issue requires triaging or verification. labels Feb 25, 2025
@nickrandolph
Copy link

This is somewhat a limitation of the XAML object model itself. Furthermore in some controls, the fact that a property isn't used may be a result of the style/control template being applied. This is great feedback and definitely something we can consider for future in terms of highlighting important/relevant properties

@DevTKSS
Copy link
Author

DevTKSS commented Mar 10, 2025

Can you explain to me what do you mean by limitations of xaml?

What I would understand from it would be: its not possible to hide those if you inherit from another control?

Is that what you mean or something else?

@nickrandolph nickrandolph removed the triage/untriaged Indicates an issue requires triaging or verification. label Mar 10, 2025
@MartinZikmund
Copy link
Member

Indeed it is odd that TextBlock would show a Background, such property really does not exist there 🤔

@DevTKSS
Copy link
Author

DevTKSS commented Mar 11, 2025

@MartinZikmund Its also confusing and maybe at least solvable in studio ui, that we have TextAlignment and HorizontalTextAlignment available while one of them is just without functionality/change same as the background. Maybe that could be reviewed in one go?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants