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

Exceptions caused by auto-sizing #2

Open
Developer-Simon opened this issue May 8, 2021 · 1 comment
Open

Exceptions caused by auto-sizing #2

Developer-Simon opened this issue May 8, 2021 · 1 comment

Comments

@Developer-Simon
Copy link

I added the example code to my own project, build in avalonia v0.10.3.
At the point, the MicrochartControl is initialized with its "Chart" property, i get an exception from the code line:

 "protected override Size MeasureOverride(Size availableSize)
            => availableSize;

thrown by the native BuildAvaloniaApp() method in the Program.cs file. Could this be a version incompatiblity or did i miss something in my code?

image

@Developer-Simon
Copy link
Author

I got a little bit deeper into it and found out, that this issue is caused by an inner failure in autosizing the charts. If I set the height and width of the charts in the .xaml file the exception doesn't trigger. But there's also an issue in the MicrochartControl class, where the .Equals() method got into an recursion infinity loop, calling itself. For implementation in my project, i temporarily disabled the method by setting it constantly true.
image

@Developer-Simon Developer-Simon changed the title Incompatiblity with Avalonia 0.10.3 Exceptions caused by auto-sizing May 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant