CGContext.SetStrokeColor Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
SetStrokeColor(CGColor) |
Sets the stroke color. |
SetStrokeColor(nfloat[]) |
Sets the stroke color. This API has undefined behavior if you do not set the colorspace beforehand. |
SetStrokeColor(nfloat, nfloat) |
Sets the stroke color to a grayscale value. |
SetStrokeColor(nfloat, nfloat, nfloat, nfloat) |
Sets the stroke color to an RGBA color. |
SetStrokeColor(nfloat, nfloat, nfloat, nfloat, nfloat) |
Sets the stroke color to a CMYKA color. |
SetStrokeColor(CGColor)
SetStrokeColor(nfloat[])
Sets the stroke color. This API has undefined behavior if you do not set the colorspace beforehand.
public void SetStrokeColor (nfloat[] components);
member this.SetStrokeColor : nfloat[] -> unit
Parameters
- components
- nfloat[]
An array of components, specific to the currently selected colorspace
Remarks
Sets the stroke color to the values specified in the components array. The number of elements in this array must be equal to the number of components in the current colorspace plus an additional element for the alpha value. For this API to work, you must previously set the colorspace on the context using SetStrokeColorSpace(), otherwise the results of calling this method are unspecified.
Applies to
SetStrokeColor(nfloat, nfloat)
SetStrokeColor(nfloat, nfloat, nfloat, nfloat)
Sets the stroke color to an RGBA color.
public void SetStrokeColor (nfloat red, nfloat green, nfloat blue, nfloat alpha);
member this.SetStrokeColor : nfloat * nfloat * nfloat * nfloat -> unit
Parameters
- red
- nfloat
The red component, in the range 0.0 to 1.0.
- green
- nfloat
The green component, in the range 0.0 to 1.0.
- blue
- nfloat
The blue component, in the range 0.0 to 1.0.
- alpha
- nfloat
The opacity, in the range 0.0 to 1.0.
Applies to
SetStrokeColor(nfloat, nfloat, nfloat, nfloat, nfloat)
Sets the stroke color to a CMYKA color.
public void SetStrokeColor (nfloat cyan, nfloat magenta, nfloat yellow, nfloat black, nfloat alpha);
member this.SetStrokeColor : nfloat * nfloat * nfloat * nfloat * nfloat -> unit
Parameters
- cyan
- nfloat
The cyan component, in the range 0.0 to 1.0.
- magenta
- nfloat
The magenta component, in the range 0.0 to 1.0.
- yellow
- nfloat
The yellow component, in the range 0.0 to 1.0.
- black
- nfloat
The black component, in the range 0.0 to 1.0.
- alpha
- nfloat
The opacity, in the range 0.0 to 1.0.