benruehl / adonis-ui

Lightweight UI toolkit for WPF applications offering classic but enhanced windows visuals
https://benruehl.github.io/adonis-ui/
MIT License
1.71k stars 143 forks source link

Cannot find Dimensions.HorizontalSpace resource. #25

Closed rasyidf closed 5 years ago

rasyidf commented 5 years ago

Describe the bug A Cannot find Dimensions.HorizontalSpace resource. Error occur when adding Adonis to project,

To Reproduce Steps to reproduce the behavior:

  1. Create New WPF Project
  2. Add Adonis Resource
  3. Rebuild
  4. See error

Expected behavior The Program Run normally but the error is annoying.

Screenshots image

Additional context Run using VS 2019 (16.1 Preview 3)

benruehl commented 5 years ago

Thank you for pointing this out. I noticed this as well but wasn't able to track it down so far. It seems to be raised by the Xaml designer because it never shows up when I disable the designer. But even then it appears quite randomly for me. Sometimes it is shown, other times it is not. I will see if I can find the source of the error.

rasyidf commented 5 years ago

I've found out that it is some visual studio behavior, Shown in this KB

benruehl commented 5 years ago

So I am closing this now as it seems to be an issue with the Visual Studio Designer and not the library.

FatCatTuxedo commented 4 years ago

is this still not resolved? This thing is unusable because of it...

benruehl commented 4 years ago

@osnapitzjamie have you even read the conversation?

As @rasyidf found out it is an issue of the Visual Studio Designer. The bug report clearly states:

Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.

To fix it, you can try to perform the steps listed in the "Resolution" section of the bug report. Alternatively, you can simply deactivate the XAML designer completely.

As a side note, I think speaking of "unusable" is a slight exaggeration here. It is only a design time error which appears more or less randomly. I agree that it might disturb development because it may trigger a developer's OCD. But still, it is only a false positive error that does not stop anyone from building an application with the library. It even disappears during runtime.

In case you want to dig into this yourself, please feel free to contribute a fix.