Chris
Chris

Reputation: 27394

WPF: Slide Grid left with fade

What I want is for a user to click "Next" and then the current "page" of content (actually just a grid) slides left (off screen) and fades out whilst the new content slides in left from off the screen whilst fading in.

How can I achieve this as easily (and reusable) as possible?

Upvotes: 0

Views: 3698

Answers (3)

John Myczek
John Myczek

Reputation: 12256

Kevin's Bag-of-Tricks has a TransitionPresenter sample with a bunch of different transitions. It includes a wipe transition and a fade transition, but not a "wipe and fade". You can download the source, so you should be able to combine the two transitions.

Upvotes: 1

Michael Brown
Michael Brown

Reputation: 9153

There is a project called Transitionals (it hasn't been updated in a while) that provides packaged transitions for WPF. You can extend it to include a Wipe and Fade transition for your needs. If you wanted to build it for yourself, it's not difficult if you have Blend (animations are not something at which the Visual Studio designer excels and I wouldn't want to code them by hand).

Upvotes: 0

Anvaka
Anvaka

Reputation: 15823

Check FluidKit library from Pavan Podila (blog). It has exactly what you need (TransitionPresenter more specifically).

Upvotes: 0

Related Questions