08.01.2015 Views

Beginning Web Development, Silverlight, and ASP.NET AJAX

Beginning Web Development, Silverlight, and ASP.NET AJAX

Beginning Web Development, Silverlight, and ASP.NET AJAX

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

CHAPTER 16 ■ PROGRAMMING SILVERLIGHT WITH XAML AND JAVASCRIPT 389<br />

Arrow: Displays the typical arrow cursor.<br />

Default: No cursor preference set. This uses this element’s parent cursor specifications.<br />

H<strong>and</strong>: Displays a pointing h<strong>and</strong> cursor, typically used for a hyperlink.<br />

IBeam: Displays an I-beam, or text cursor. This is typically used to show an area where<br />

text entry or selection is used.<br />

None: No cursor is used.<br />

Wait: Shows an hourglass, indicating a busy state.<br />

Using Shapes in XAML<br />

Many of the XAML elements used to make up your UI are XAML shapes that are composited<br />

into more complex shapes. The shapes that are supported by <strong>Silverlight</strong> are as<br />

follows:<br />

Ellipse: Draws a closed, curved shape. A circle is an ellipse with the same horizontal<br />

<strong>and</strong> vertical dimensions.<br />

Rectangle: Draws a closed, straight-edged shape. A square is a rectangle with the<br />

same horizontal <strong>and</strong> vertical dimensions.<br />

Line: Draws a line between the specified endpoints.<br />

Path: Draws a series of connected lines <strong>and</strong> curves.<br />

Polygon: Draws a closed shape made up of a connected series of straight lines.<br />

Polyline: Draws a connected series of straight lines.<br />

The Ellipse<br />

The Ellipse is used to draw a closed, curved shape. Its Height property contains its vertical<br />

height (i.e., double its vertical radius), <strong>and</strong> its Width property contains its horizontal<br />

width (i.e., double its horizontal radius).<br />

Here’s an example of an Ellipse that is twice as wide as it is high, giving an eggshaped<br />

element.<br />

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!