WpfDesigner icon indicating copy to clipboard operation
WpfDesigner copied to clipboard

Xaml Designer - edit polyline points not possible

Open TeaJAge opened this issue 3 years ago • 1 comments

It's not possible to edit points of a polyline.

image

image

<Window xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Width="640"
        Height="480">
  <Canvas>
    <Path Width="120"
          Height="100"
          Stretch="None"
          Stroke="Black"
          StrokeThickness="2"
          Canvas.Left="120"
          Canvas.Top="204.04000000000002" />
    <Polyline Points="0,0 93,69 -4,124 -4,124 -4,124"
              Stretch="None"
              Stroke="Black"
              StrokeThickness="2"
              Canvas.Left="124"
              Canvas.Top="119.03999999999999" />
  </Canvas>
</Window>

TeaJAge avatar Jan 18 '21 15:01 TeaJAge

The Problem here is, the Points are Stored as a String and not as an Object List in Xaml

If you create the Line like this:

<Polyline 
              Stretch="None"
              Stroke="Black"
              StrokeThickness="2"
              Canvas.Left="122"
              Canvas.Top="135.04000000000002">
      <Polyline.Points>
        <Point X="1" Y="2" />
        <Point X="3" Y="4" />
        <Point X="5" Y="6" />
      </Polyline.Points>
    </Polyline>

it works. Ate the Moment the support for the other Format is missing, I think in XamlModelCollectionElementsCollection, Problem is, it returns a Empty List, cause there is no automatic conversation between the two modes.

jogibear9988 avatar Feb 03 '22 17:02 jogibear9988