ID2D1SvgGlyphStyle::SetStroke method (d2d1_3.h)

Provides values to an SVG glyph for stroke properties. The brush with opacity set to 1 is used as the 'context-stroke'. The opacity of the brush is used as the 'context-stroke-opacity' value.

Syntax

HRESULT SetStroke(
  [in, optional] ID2D1Brush  *brush,
                 FLOAT       strokeWidth,
  [in, optional] const FLOAT *dashes,
                 UINT32      dashesCount,
                 FLOAT       dashOffset
);

Parameters

[in, optional] brush

Type: ID2D1Brush*

Describes how the stroke is painted. A null brush will cause the context-stroke value to be none.

strokeWidth

Type: FLOAT

Specifies the 'context-value' for the 'stroke-width' property.

[in, optional] dashes

Type: const FLOAT*

Specifies the 'context-value' for the 'stroke-dasharray' property. A null value will cause the stroke-dasharray to be set to 'none'.

dashesCount

Type: UINT32

The number of dashes in the dash array.

dashOffset

Type: FLOAT

Specifies the 'context-value' for the 'stroke-dashoffset' property.

Return value

Type: HRESULT

This method returns an HRESULT success or error code.

Requirements

Requirement Value
Target Platform Windows
Header d2d1_3.h
DLL D2d1.dll

See also

ID2D1SvgGlyphStyle