C# Class Paint.BrushSizeSelector

Brush size selector - tool allowing the user to pick the size of the brush for drawing
Inheritance: ToolBoxToolTouchBase, IBrushSizeSelector
Mostrar archivo Open project: RandolphBurt/MonoGame-iOS-SimplePaint Class Usage Examples

Public Methods

Method Description
BrushSizeSelector ( IGraphicsDisplay graphicsDisplay, BrushSizeSelectorDefinition brushSizeDefinition ) : System

Initializes a new instance of the Paint.BrushSizeSelector class.

Draw ( bool refreshDisplay ) : void

Draw this tool on to the image

Protected Methods

Method Description
HandleTouch ( ITouchPoint touchPosition ) : void

Handle the user interaction for a particular touch/gesture type and position

OnBrushSizeChanged ( EventArgs e ) : void

Raises the brush size changed event.

Private Methods

Method Description
DrawBrush ( ) : void

Draws the brush size representation in the current color

brushSizeGauge_MarkerChanged ( object sender, EventArgs e ) : void

Fires when the gauge has been altered, indicating the brush size needs to change

Method Details

BrushSizeSelector() public method

Initializes a new instance of the Paint.BrushSizeSelector class.
public BrushSizeSelector ( IGraphicsDisplay graphicsDisplay, BrushSizeSelectorDefinition brushSizeDefinition ) : System
graphicsDisplay IGraphicsDisplay /// Graphics display. ///
brushSizeDefinition BrushSizeSelectorDefinition /// Brush size definition - layout of the control. ///
return System

Draw() public method

Draw this tool on to the image
public Draw ( bool refreshDisplay ) : void
refreshDisplay bool /// True = we should redraw the entire control /// False = just draw any updates ///
return void

HandleTouch() protected method

Handle the user interaction for a particular touch/gesture type and position
protected HandleTouch ( ITouchPoint touchPosition ) : void
touchPosition ITouchPoint /// Touch position and type of gesture ///
return void

OnBrushSizeChanged() protected method

Raises the brush size changed event.
protected OnBrushSizeChanged ( EventArgs e ) : void
e System.EventArgs /// Any relevant EventArgs (should be EventArgs.Empty) ///
return void