Hi Jake,
I would like to know how to draw border for an element (Grid / Text box etc) and how to draw a simple straight line on the screen?
Thanks a lot, Jithesh
Hi Jake,
I would like to know how to draw border for an element (Grid / Text box etc) and how to draw a simple straight line on the screen?
Thanks a lot, Jithesh
You can place elements in the background of another element. This allows you to create a rectangle with a stroke that will be a border then.
<Grid Padding="5" ...>
<Rectangle Layer="Background">
<Stroke Width="2" Color="0,1,0,1"/>
</Rectangle>
...
Note I put a Padding="5"
to make space for the border. Things in Layer="Background"
ignore the padding.
For a straight line I usually use a thin Rectangle
and rotate it. It depends on your use-case whether this would be appropriate or not. There is no general purpose line-drawing at the moment.