Pen.StartLineCap Propiedad

Definición

Obtiene o establece el tipo de forma que se va a usar al principio de un trazo.

public:
 property System::Windows::Media::PenLineCap StartLineCap { System::Windows::Media::PenLineCap get(); void set(System::Windows::Media::PenLineCap value); };
public System.Windows.Media.PenLineCap StartLineCap { get; set; }
member this.StartLineCap : System.Windows.Media.PenLineCap with get, set
Public Property StartLineCap As PenLineCap

Valor de propiedad

Tipo de forma que inicia el trazo. El valor predeterminado es Flat.

Ejemplos

En el ejemplo siguiente se muestra cómo usar las StartLineCap propiedades y EndLineCap para crear un extremo redondeado en un lado de un trazo y un extremo triangular en el otro lado del trazo.

<Page 
  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
  <StackPanel Margin="20">

    <Canvas Margin="100"  Width="100" Height="100">
      <Canvas.Background>
        <DrawingBrush>
          <DrawingBrush.Drawing>
            <GeometryDrawing>
              <GeometryDrawing.Geometry>
                <LineGeometry StartPoint="10,10" EndPoint="50,100" />
              </GeometryDrawing.Geometry>
              <GeometryDrawing.Pen>
                
                <!-- This Pen specifies a round line cap at the beginning of
                     the line and a triangular line cap at the end of the line. -->
                <Pen Brush="Blue" Thickness="8"  StartLineCap="Round" 
                     EndLineCap="Triangle" />
              </GeometryDrawing.Pen>
            </GeometryDrawing>
          </DrawingBrush.Drawing>
        </DrawingBrush>
      </Canvas.Background>
    </Canvas>

  </StackPanel>

</Page>

Comentarios

Información sobre propiedades de dependencia

Campo identificador StartLineCapProperty
Propiedades de metadatos establecidas en true None

Se aplica a

Consulte también