CanvasTextLayoutSetColor Method |
Namespace: Microsoft.Graphics.Canvas.Text
public void SetColor( int characterIndex, int characterCount, Color color )
This color takes effect while calling DrawTextLayout(CanvasTextLayout, Single, Single, ICanvasBrush) It overrides the brush or color passed to DrawTextLayout.
Calling GetBrush(Int32) for this same index, after calling this method, will yield a CanvasSolidColorBrush with the appropriate color.
A color set using this method replaces any brush currently set to those characters using SetBrush(Int32, Int32, ICanvasBrush) or SetCustomBrush(Int32, Int32, Object).