Button Event Handlers and Image Effects

With the images successfully loaded into the list box, and displayed in the central Image control, we can turn our attention to our four image editing/effects features:

• Black and white filter

• Image blur

• Rotate

• Flip

Because these four functions are controlled by the four buttons, we need to add some appropriate button images and events; we don’t cover the button stylings here because they involve external graphics resources, but you can see how they turn out in the final screenshot (at the end of this chapter), or by downloading the source from this book’s website.

The code for the events, however, is fair game. First, the XAML event declarations on each button:

Notice as you type these click events ...

Get Microsoft® Visual Studio® 2010 Unleashed now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.