So I have just finished doing my 1st WinRT demo article (and yes it is for an article for codeproject), which I will have up soon. Coming from a place where I was working a lot with WPF I thought it might be a good idea to capture some of my thoughts/current gripes when working with Win8/WinRT.
I have tried to be as pragmatic as possible, and view WinRT as a v1 thing, which will (hopefully) get better in time. That said there were certain things I just missed a lot. I think what I will do is just list some of the things I found lacking when I was doing my little demo app, and then I will talk about how I found the whole Win8/WinRT ecco system.
Some Of The Issues That Bugged Me
So here is a list of things that I found a bit odd/off, now that is not to say that these will not get fixed, but they still bugged me all the same
- DependencyProperty system, looked far less able when compared to WPF
- On more than 1 occassion I found that my ComboBox ItemSource Binding must appear before SelectedItem Binding in XAML if you want SelectedItem to populate correctly from the ViewModel (this seemed to be a problem in 8.0 at least), also I believe I have seen this bug before in days of old in both WPF and SL
- No binding in setters within Styles (even SL has this now in SL5). This one needs fixing like NOW. Its plain wrong, and the work around sucks
- RelativeSource binding is far less able when compared to WPF
- Visibility is lacking “Hidden”, which is actually useful
- No DependencyPropertyDescriptor
- Can’t do BasedOn style that allows you to BasedOn default style (or maybe I just didn’t know how to do it)
- No x:Static markup extension. This is extremely useful for binding to singleton instance (which I use for all my ValueConverters)
- No x:Type markup extension
- No custom markup extension
- No DynamicResource markup extension
- No VisualStateManager.GoToElementState(..)
- I may be wrong on this, but didn’t seem to be able to have nested VisualStates one for top level control, and then some for some inner control.
- WebView is still 2nd class citizen, in certain scenarios its still ALWAYS on top.
- ListBox backgroundColor / BorderBrush do not work that well with Focus, you have to restyle either whole control or ListBoxItem (container) taking into account Focus VisualState (I think this is a pain others probably disagree)
- No DatePicker control (ok its coming in 8.1, but please what the heck, do people not need to amend/pick dates in Windows 8. This is plain lazy)
- No Triggers in Styles/DataTemplates. Follows the SL model of VisualState(s). In my opinion (and I am not alone here) Triggers are and ALWAYS will be more powerful than visual states. At least give us both and let us use which model we prefer
- No Blend interactivity interactions. My god so we are now back in WPF v1 land where we have to right our own attached behaviors for everything. Practically any XAML developer will have become accustomed to using the standard Blend interactions / behaviours. We want these back.
Plain Weird Issues
- Enumerable.Range(2013,2023) plain doesn’t work. Try that and see what you get. It is very odd
- DateTime object is very limited compared to .NET version
What Was The Win8 Ecco System Like To Use
WinJS or C#
Others may strongly disagree, but that was just my take on it.
I have to say I am not mad keen on the overall application structure. I mean have you seen how much boiler plate code you get in App.xaml.cs, here it is for a new project. Thats nasty if you ask me:
sealed partial class App : Application
this.Suspending += OnSuspending;
protected override async void OnLaunched(LaunchActivatedEventArgs args)
Frame rootFrame = Window.Current.Content as Frame;
if (rootFrame == null)
rootFrame = new Frame();
if (args.PreviousExecutionState == ApplicationExecutionState.Terminated)
Window.Current.Content = rootFrame;
if (rootFrame.Content == null)
if (!rootFrame.Navigate(typeof(GroupedItemsPage), "AllGroups"))
throw new Exception("Failed to create initial page");
private async void OnSuspending(object sender, SuspendingEventArgs e)
var deferral = e.SuspendingOperation.GetDeferral();
Coming from other stuff like there is a lot less clutter in the main entry point.
The other thing I really didn’t like is the way you had to have this special
ResourceDictionary called “StandardStyles.xaml“. If they truly are standard, what the hell are they doing in my app, and why aren’t they included in the framework. Also why are most of the styles in there commented out, and we have to uncomment them as we need them.
Magic Classes That Are Provided
I also didn’t like the fact that there are a bunch of classes provided which I have no idea whether I need them or not.
For example if you create a new Grid application you get this.
Now I know what a value converter is, so they are ok, but don’t things like “
LayoutAwarePage“ and “
SuspensionManager” sound like framework issues to you? They sure do to me, again why are these classes in my codebase. Surely a
LayoutAwarePage should be the defacto page for ANY WinRT application. You know we are supposed to think that the Surface is an iPad rival, yet last time I looked I could twist an iPad this way and that, and you can also do that with a Surface. So why isn’t the
LayoutAwarePage the standard. By the same token since there is a suspension type of lifecycle in WinRT why is the
SuspensionManager not in the class library.
Also what the heck is “
RichTextColumns” do I need that, what does it do. Is it required for a GridView, and if so (yes I’ll say it again) why isn’t it in the framework.
Ok, I could find out, but when I start a new app, I would much prefer to see a clean slate really.
Early Days But
To my mind it just feels like it was rushed out the door, and feels very unpolished. Now I am a massive Microsoft fan boy, but I just felt let down by WinRT. As I say I will still be putting out this WinRT article soon, but it will likely be my one and only for a while.
Anyway those are just my thoughts, no one elses, many will likely disagree, which is fine.