Click here to Skip to main content
Click here to Skip to main content
Technical Blog

Tagged as

Mahhala – FluidKit

, 12 Jul 2010 CPOL
Rate this:
Please Sign up or sign in to vote.
This week I chat with Pavan Podila, the creator of FluidKit and the author of THE book about WPF control development!

Mahhala (isiZulu word for free or without charge) is a new series that showcases some of the cool free WPF/Silverlight controls available…

“You can learn a lot by reading other people's source code. That's the idea behind this series, "The Weekly Source Code." You can certainly become a better programmer by writing code but I think good writers become better by reading as much as they can.” - Scott Hanselman

This week I chat with Pavan Podila, the creator of FluidKit and the author of THE book about WPF control development!

Source: http://fluidkit.codeplex.com/

License: New BSD License (BSD)

RG – Welcome Pavan, tell us a little about yourself?

PP - I have always been interested in all things graphical and visually appealing. It was the biggest discovery of my life when I learnt that I can actually build my own User Interfaces. My first few explorations were on the Turbo C++ IDE and the Borland Graphics Interface. I played a lot with VGA cards, assembly programming and was fascinated by timer based animations. Later on, I picked up Win32 programming and explored OpenGL on Windows using GLUT. OpenGL helped me learn a lot about 3D graphics, the graphics pipeline and also all the interesting math that goes with it. When I started my bachelors in CS, Linux was really hot and so were Gnome and KDE. Not surprisingly, I gravitated towards their UI toolkits: GTK and Qt. Personally, I preferred Qt over GTK for its nice object hierarchy and programming ease.
When Java came out, I tried my hand at AWT and Swing. I liked it so much that I did my final year Bachelors project in Java and Swing. Although Swing had a good programming model, its graphical strength was limited. Eclipse SWT (Standard Widget Toolkit) felt much nicer and even had alpha-blending! Writing custom SWT controls and Eclipse plugins felt like nirvana back in 2002-2004.

In 2005, I started looking at .NET as I was preparing for my semester project in Masters. WinForms felt very easy to use and I had tremendous fun in my project. That year, my project team participated in Imagine Cup 2005 and we went all the way to Nationals in the Software Design category. We got an all-expense paid trip to Microsoft’s Redmond campus, all for choosing .NET + WinForms. We got a lot of positive feedback for our project and in fact one of the judges at Microsoft suggested that we look at Avalon, the next-generation UI platform for developing Windows apps. Avalon / WPF was love at first sight. It felt exhilarating to design in XAML and try out the various graphics features like brushes, 3D, animations, data-binding and most importantly “custom-controls”. I think WPF has an awesome controls framework and to me it feels very natural to think in DataTemplates, ControlTemplates and Styles. I think this abstraction really nails the core of building UI controls.

Even today, I feel a rush of adrenalin when I start building a custom control, be it WPF or Silverlight. It sure brings a smile on my face.

RG – What is FluidKit?

PP - Since 2006, I have been actively developing several custom controls and even posting some of them on my blog. At some point, I felt I had a good collection of controls and decided to combine them into one toolkit and thus FluidKit was born. The name FluidKit was influenced by the fact that I was working in the financial industry, where liquidity (fluid) was very important. FluidKit also has other interpretations as in being agile and flexible for various scenarios. As described on my CodePlex page: http://fluidkit.codeplex.com, it is really a “powerhouse of WPF controls, tools and helpers”. Some of the important controls include: ElementFlow, TransitionPresenter, GlassWindow, DragDrop attached behavior, GlassWindow, Simple 3D Engine. These controls use WPF in very interesting ways.

RG – Which controls are your favourites?

PP - Although I like all my controls, I am fond of ElementFlow and TransitionPresenter. These two controls have also been the most popular on the internet and hot topics in the CodePlex discussion list.

ElementFlow is an ItemsControl that allows you to layout your items in 3D space and comes with an easy framework for building your own layouts. It comes packed with 10 different 3D layouts to show you the possibilities. CoverFlow is just one of the layouts and certainly the most popular.

TransitionPresenter is also an ItemsControl but does transitions when switching between its items. Only one of the items can stay visible at any time. When you want to bring a different item to the front, you can use several cool transitions to do that, e.g. Cube rotations, Genie effects, slides, fades, 3D flips, etc. You can also create your own custom transitions and use the full power of WPF to build some rich transitions. Transitions can be changed at any time and there is also a property to do continuously repeating transitions with some delay between transitions.

All of these samples can be found in the FluidKit Showcase. I have recently updated the Showcase to make it easy to browse all examples.

RG - Tell us about your book

PP - I had never planned on writing a book as I knew by speaking to some authors that it was a tough job. One day, my wife casually remarked that it would be good to have a printed version of my blog. It wasn’t long until I realized that writing a book wasn’t really a bad idea. My co-author was of great help in getting a contract with SAMS. Thus began my journey for the next one year writing “WPF Control Development Unleashed”. This book is a guide for custom control authors on creating some awesome WPF controls. Many of the controls from FluidKit, like the ElementFlow and TransitionPresenter are explored in detail with emphasis on some of the finer techniques. You will learn how to combine animations, 3D, Styles, templates in a tasteful way to create beautiful experiences.

RG - Where can we find you ?

PP - I am always reachable on my email: pavan@pixelingene.com. I also blog actively at http://blog.pixelingene.com where I post my experiments with WPF, Silverlight and Adobe Creative Suite.

When a new platform is released, you get the “default” hello world applications… Twitter, RSS, etc… The more brave developers try to recreate popular media players… Windows Media Player, Zune, Itunes, etc… The interesting one here is ITunes, if you ever used it you might have noticed the cool cover flow animations when you browse albums… FluidKit makes this childs' play, here is the code:

<fluidkit:ElementFlow ItemsSource="{Binding}"
                      ElementWidth="400"
                      ElementHeight="300">
    <fluidkit:ElementFlow.ItemTemplate>
        <DataTemplate>
            <Image Source="{Binding}" />
        </DataTemplate>
    </fluidkit:ElementFlow.ItemTemplate>
    <fluidkit:ElementFlow.Layout>
        <fluidkit:CoverFlow />
    </fluidkit:ElementFlow.Layout>
    <fluidkit:ElementFlow.Camera>
        <PerspectiveCamera FieldOfView="60"
                           Position="0,3,6"
                           LookDirection="0,-3,-6" />
    </fluidkit:ElementFlow.Camera>
</fluidkit:ElementFlow>

And this is how it looks:

Very cool, huh? If you do not live in a 3D world every day… creating subtle 3D effects is kinda hard! Controls like this make it easy for everyday developers to create cool effects!!!

Next week I chat with Josh Smith, the creator of Thriple.

Mahhala – AvalonDock
Mahhala – Fluent Ribbon Control Suite
Mahhala – Bag o' Tricks
Mahhala - WPF NotifyIcon

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

rudigrobler

South Africa South Africa
No Biography provided

Comments and Discussions

 
-- There are no messages in this forum --
| Advertise | Privacy | Mobile
Web03 | 2.8.141015.1 | Last Updated 12 Jul 2010
Article Copyright 2010 by rudigrobler
Everything else Copyright © CodeProject, 1999-2014
Terms of Service
Layout: fixed | fluid