The tile maker control can be placed on the page by adding the following namespace declaration:

xmlns:mh="clr-namespace:MikeHole.TileMaker;assembly=MikeHole.TileMaker"   

Once this is in place you can add the control to the page:

<mh:TileMakerControl x:Name="maker" />

The control should look like this:

2011-05-09 14h19_04

The control then has 3 methods GetCurrentTile, SetTileImage and SetBackground.

GetCurrentTile

This has no parameters and returns a BitmapImage that contains the current tile that is visible in the tile square of the control.

SetTileImage

Takes a BitmapImage as it’s parameter. This sets the image that the design surface of the tile maker will use.

SetBackground

Takes a SolidColorBrush. This changes the background colour that will be used when rendering the tile.

Last edited May 9, 2011 at 1:34 PM by mikehole, version 3

Comments

No comments yet.