icsharpcode / WpfDesigner

The WPF Designer from SharpDevelop
MIT License
949 stars 251 forks source link

The reference node is not a child of this node #36

Open mnusr opened 7 years ago

mnusr commented 7 years ago

Steps to reproduce:

  1. Run XamlDesigner project and add a button.
  2. Click the left skew handle and drag it down to skew the button a bit.
  3. Try to rotate it.

Exception thrown at line 513 in XamlProperty.cs

jongleur1983 commented 4 years ago

I'd love to get some help solving this (see linked PR). I'm pretty sure, that the fix proposed in XamlProperty.cs is correct, but the functional behavior of the demo application is still strange and doesn't look correct IMHO. If anyone could verify and point me to the right direction, that would be great.

jogibear9988 commented 4 years ago

Maybe your fix in XamlProperty is correct (I'll take a look), but to fix this correctly I think you need to fix ApplyTransform in ModelTools.cs

The RotateTransform Extension does already use this, the Skew Extension not, so this needs to be fixed. And this function needs to be changed so it loads and keeps existing Transforms when applying a new one

jongleur1983 commented 4 years ago

Thanks @jogibear9988 for the hint. Good to know that I may be on the right track. Looking forward to tackle the rest of this issue in the next days.