Tag Archives: Expression

SCREENCAST: Implementing Single Touch Gestures with MouseGestureTrigger

digg_url = “http://blogs.msdn.com/devkeydet/archive/2010/02/15/screencast-implementing-single-touch-gestures-with-mousegesturetrigger.aspx”;digg_title = “SCREENCAST: Implementing Single Touch Gestures with MouseGestureTrigger”;digg_bgcolor = “#555555”;digg_skin = “normal”;http://digg.com/tools/diggthis.jsdigg_url = undefined;digg_title = undefined;digg_bgcolor = undefined;digg_skin = undefined;

A common need for Windows 7 touch user interfaces is to react to a touch gesture.  In this screencast, I demonstrate a very simple and easy way to interpret single touch gestures using MouseGestureTrigger from the Expression Blend Samples.

To learn more about Behaviors, Triggers, and Actions mentioned in the screencast, visit http://tinyurl.com/TriggersActionsBehaviors.  If you are interested in touch/multitouch Behaviors, then have a look at http://touch.codeplex.com/.  You can download even more Triggers, Actions, Behaviors, etc. at Expression Gallery.

Get Microsoft Silverlight

Direct link to Ch. 9 post:

https://channel9.msdn.com/posts/keydet/Implementing-Single-Touch-Gestures-with-MouseGestureTrigger/ 

Sample download:

http://tinyurl.com/TestMouseGestureTrigger

FOLLOW UP: DevDinner – Silverlight 4, WCF RIA Services, MVVM

Ok, this is a first!  I have always had good intentions of getting the follow up material for a developer dinner out before the dinner started.  However, my schedule inevitably has gotten in the way.  I can finally say MISSION ACCOMPLISHED.  Here are the decks and sample downloads:

Silverlight 4 Deck

WCF RIA Services Deck

SketchFlow & MVVM Deck

MVVM Sample App

WCF RIA Services + ViewModel Sample App

NOTE: The WCF RIA Services + ViewModel Sample App uses the MVVM approach from http://tinyurl.com/riasvcs-viewmodel.  Brad Abram’s code was written using an older version of WCF RIA Services.  There were a few breaking changes in the November release.  I went ahead and ported the MVVM and Unit Testing helpers to work with the November release of WCF RIA Services.  In the sample, ViewsHome.xaml does not use MVVM.  It uses DomainDataSource embedded in the XAML.  ViewsMvvmHome.xaml implements the same scenario, but using the MVVM approach Brad describes in the link above.

EventToCommand + DataStateBehavior eases MVVM pain

 

MVVM is a pattern.  There are all sorts of MVVM frameworks popping up that help make implementing the pattern easier.  If you select the MVVM tag off of www.codeplex.com, you will find a number of them:

http://www.codeplex.com/site/search?TagName=MVVM&ProjectSearchText=%22MVVM%22

One I have recently grown fond of is http://mvvmlight.codeplex.com/.  The reason I like this one is because they have built an Expression Blend Behavior called EventToCommand.  Details for the behavior:

http://blog.galasoft.ch/archive/2009/11/05/mvvm-light-toolkit-v3-alpha-2-eventtocommand-behavior.aspx

As the post says, ‘EventToCommand is used to bind an event to an ICommand directly in XAML.”

This is WAY COOL!!!  EventToCommand helps overcome commanding challenges in Silverlight.

I love Blend Behaviors.  If you haven’t looked into them, YOU MUST!  Every WPF and Silverlight developer should be using them (where applicable).  “A Behavior is in essence a reusable piece of interactivity that can be applied directly to user interface elements…”

Here are some resources:

Good Overviewhttp://tinyurl.com/BehaviorsOverview

More readinghttp://tinyurl.com/BehaviorsTriggersActions

Expression Blend 3 SDKhttp://tinyurl.com/blend3sdk 

Lots of folks creating and uploading them to Expression Galleryhttp://tinyurl.com/BehaviorsGallery

Behaviors from the Blend Teamhttp://expressionblend.codeplex.com/

Behaviors are part of the Blend SDK.  There is a lot of confusion about the Blend SDK because people think you have to buy Blend to use it.  You don’t!  You can download it from http://tinyurl.com/blend3sdk and use it straight from Visual Studio.  Blend definitely makes wiring up Behaviors easier so you should it for that if you are already using Blend!

The samples you can download from http://expressionblend.codeplex.com/ include DataStateBehavior and DataStateSwitchBehavior.  Peter Blois has a good post on these behaviors:

http://blois.us/blog/2009/04/datatrigger-bindings-on-non.html

DataStateBehavior/DataStateSwitchBehavior provide a nice clean way to change values in your ViewModel that result in initiating animations in your View.

I’ve been wanting to whip up a simple sample that shows both EventToCommand and DataStateBehavior/DataStateSwitchBehavior.  Unfortunately, I don’t have the time right now to do so.  Instead of sitting on this, I decided to blog about it first, then share a sample/video when I get around to it.

Hidden gems in the gaming starter kit

Yesterday I blogged about the SketchFlow starter kit and how great I thought it was.  Well, last night, I went ahead and tried the Venture into Gaming with Behaviors in Expression Blend 3 starter kit from:

http://adamkinney.com/Blog/4-Expression-Studio-3-Starter-Kits-available-for-download

Much to my surprise, this felt more like a Blend 3 Fundamentals through Building a Game.  To understand what I mean, here are the individual modules in the kit:

01_BLN03SP1EN720_Organizing_and Importing_Assets into_Expression_Blend

02_BLN03SP1EN720_Creating_the_Game_Interface_Using_Expression_Blend

03_BLN03SP1EN720_Understanding_Layout_Containers

04_BLN03SP1EN720_Creating_a_User_Control

05_BLN03SP1EN720_Adding_and_Applying_Behaviors

06_BLN03SP1EN720_Adding_Game_Walls_and_Creating_Animation

07_BLN03SP1EN720_Animating_Controls_with_the_Visual_State_Manager

08_BLN03SP1EN720_Working_with_Texts_and_Embeding_Fonts_with_Expression_Blend

09_BLN03SP1EN720_Adding_Audio_Resources_to_a_Silverlight_Game

10_BLN03SP1EN720_Publishing_and_Testing_Your_Silverlight_Game

If you are looking to warm up to Blend a bit more through a video walkthrough + hands-on-lab kind of approach, then I’d definitely recommend this kit.  If you already understand these concepts, then you might want to skip this one.  On the other hand, it is kind of fun to see how easy it is to build a simple game with the skills you already have.

The biggest nugget for me was the module on Behaviors.  If you haven’t looked at Behaviors, then GO DO IT NOW.  Here’s a good post on behaviors:

http://team.silverlight.net/announcements/product-feature-highlight-expression-blend-3-ndash-behaviors/

“A Behavior is in essence a reusable piece of interactivity that can be applied directly to user interface elements in Expression Blend.”

I don’t remember where, but I saw someone describe Behaviors as "ASP.NET AJAX Control Extenders for Silverlight/WPF."  Not a bad way of describing them if you are familiar with the concept of ASP.NET AJAX Control Extenders.

Once you have wrapped your head around Behaviors, you’ll want to check out the following two links to download more:

http://gallery.expression.microsoft.com/en-us/site/search?f%5B0%5D.Type=Tag&f%5B0%5D.Value=Behavior

http://expressionblend.codeplex.com/

In general, http://gallery.expression.microsoft.com is a great resource.  There are all sorts of useful things to download there including Art/Design assets, Web Templates, Samples, Themes, Behaviors, Code Snippets, Tools/Addins.

Get up to speed on SketchFlow FAST

SketchFlow is a feature of Expression Blend 3.  If you aren’t familiar with SketchFlow, then you should check out:

http://www.microsoft.com/expression/products/SketchFlow_OverView.aspx

“SketchFlow revolutionizes how quickly and efficiently you can demonstrate your vision for an application. It provides an informal and quick way to explore, iterate and prototype user interface scenarios, allowing you to evolve your concepts from a series of rough ideas into a living and breathing prototype that can be made as real as a particular client or project demands. This rapid, iterative and cost effective approach to prototyping allows you to concentrate on what matters most, being creative and building the best solution for your client, on time and within budget.”

Digging into SketchFlow has been on my TODO list for quite some time.  In many ways, I am glad I hadn’t gotten around to it.  A week or so ago, Adam Kinney blogged about:

4 Expression Studio 3 Starter Kits available for download

One of the starter kits is on SketchFlow.  I just finished it.  If you want to get your head around SketchFlow fast, then this is the resource for you!

Developer Dinner tomorrow

digg_url = “http://blogs.msdn.com/devkeydet/archive/2009/03/24/developer-dinner-tomorrow.aspx”;digg_title = “Developer Dinner tomorrow”;digg_bgcolor = “#555555”;digg_skin = “normal”;http://digg.com/tools/diggthis.jsdigg_url = undefined;digg_title = undefined;digg_bgcolor = undefined;digg_skin = undefined;

I have really been slacking when it comes to my blog.  I have a few posts planned, but I have been “heads down” on some really fun Windows Azure work that I should be able to talk about soon. 

Hopefully, you don’t use my blog as the source for Developer Dinner announcements since there are more official vehicles:

MSDN Flash: http://tinyurl.com/msdnflash

My team’s blog: http://tinyurl.com/psdevdinnertag (RSS)

In the event that you expected to see an announcement here, I am sorry for the short notice.  There is a dinner tomorrow:

Design your ASP.NET Application with Standards using Expression Web

XamlFest DC (March 4 and 5)

digg_url = “http://blogs.msdn.com/devkeydet/archive/2009/02/16/xamlfest-dc-march-4-and-5.aspx”;digg_title = “XamlFest DC (March 4 and 5)”;digg_bgcolor = “#555555”;digg_skin = “normal”;http://digg.com/tools/diggthis.jsdigg_url = undefined;digg_title = undefined;digg_bgcolor = undefined;digg_skin = undefined;

Here’s a chance at some free WPF and Silverlight training.  XamlFest is an event touring around the US enabling developers to ramp up their WPF/Silverlight skills quickly.  Here is the description of the event:

“Are you excited about the WPF but concerned about the learning curve?  Have you seen Silverlight but don’t know where to get started?  Or are you curious about how tools like Visual Studio and Expression Blend help designers and developers work together to deliver great user experiences? If so, join us at XamlFest!

XamlFest is a two day interactive event where you’ll learn about the platforms the tools and processes used to deliver differentiated user experiences. It’s a chance for you to mingle with UX minded Microsoft folks as well as industry leading design integrators.  It’s also an opportunity to pick up a free copy of Visual Studio 2008 and Expression Studio 2 for you attendance.

Each XamlFest day will start with interactive sessions by Microsoft and our design partners, followed by a free lunch and a chance to network, have some fun and win prizes. Each afternoon will be geared toward assisted development with instructor-led walkthroughs, or, better yet, come with your own project in mind and we’ll help kick start your very own proof of concept”

More details and registration information is available at:

http://blogs.msdn.com/usisvde/archive/2009/02/16/you-re-invited-to-xamlfest-dc-march-4-5.aspx

Also note:

“We’re asking that each company send no more than 4 people to this event so that we accommodate as many as possible. We’re allowing only 40 attendees to ensure we deliver a good experience during the assisted development sessions.”