Bill Reiss is a Windows Platform Development MVP and a Senior Consultant for AgileThought

All posts in Uncategorized

This is pretty cool. One of the great new features of Visual Studio 2015 for XAML apps is that you can see the XAML Visual Tree, drill into pieces of it, and do other cool tricks. Think Snoop for WPF or XAML Spy for most XAML based technologies, but now it’s built in to Visual Studio and Blend.

What’s even more interesting is that you can attach to other XAML apps, even if they aren’t yours, including apps that are shipped as part of Windows 10. Some of these are tightly integrated into the shell, but they are still using XAML and the same tools available to any Windows 10 app developer. Want to see how they implemented their UI? It’s a nice peek into their design process.

Ok so first you will need to have the Visual Studio 2015 RTM and Windows 10 SDK RTM. You will also need Windows 10, hopefully this is obvious.

Bring up the Settings dialog in Windows 10. It will look something like this:

image

Now run Visual Studio and Debug->Attach to Process. You will see two processes associated with Settings, one is ApplicationFrameHost.exe with a title of Settings. This isn’t what you want.

image

Instead pick the actual settings app process, called SystemSettings.exe

image

Now if you go to Debug->Windows->Live Visual Tree you should be able to see the XAML Visual Tree of the Settings app.

image

It should look something like this:

image

See that first button in the toolbar? That will highlight whatever you hover over so you can easily drill into it. Select that and then bring the Settings app to the foreground. Now when you hover over elements you should see a red box:

image

If you click on this box, you should see that element selected in the Live Visual Tree pane:

image

I actually thought this was was surprising, because they used a Grid as the container. I really thought it was going to be the new RelativePanel, because of the alignment changes that happen when the settings app goes into “narrow” mode. Maybe this app was written before that was available. You can also right click and show properties in the Live Properties Explorer.

If you are writing a Windows 10 UWP app, why not go and see how other apps are doing it using the new Live Visual Tree functionality in Visual Studio 2015. Enjoy!

I am very excited about the advances that XAML has made in the Windows 10 Universal Windows Platform (UWP) and I think a lot of that has to do with the Windows Shell team and the Office team embracing XAML for building their apps. The Windows Shell team especially is so focused on performance when it comes to fluidity of animations, CPU pressure, and memory pressure. The fact that a ton of UI in the Windows 10 desktop is using XAML is a testament to how far it has come, and clearly the Windows Shell team was very demanding, and that makes it better for everyone. I don’t even know how pervasive XAML is in Windows 10, but I have heard it is used for the Start Menu, Action Center, and the Date/Time popup, and I can see first hand that it is used for the Settings dialog, the Edge browser, the Store app, Xbox app, and a lot more.

This is quite a departure from when Windows 8 was launching and Steven Sinofsky and Julie Larson-Green were on stage and told everyone to use WinJS to build your apps, and the Store app, Bing apps, and many others were using WinJS. This came on the heels of the death of Silverlight, and XAML was DOA, much to the chagrin of C# and .NET developers feeling like they were being left behind. Many of the people on the stage back then are gone, including Steven Sinofsky and Jensen Harris, and others have changed positions such as Dean Hachamovitch and Julie Larson-Green. The new regime seems much more XAML friendly, which isn’t a big surprise since Terry Myerson is running the show and he was in charge of Windows Phone which primarily used XAML as its app platform.

Disclaimer: This next part is based on things that some of the presenters said at the BUILD conference, and I have heard none of it first hand one on one, so I take them at their word, and I apologize if I get it wrong.

One of the big complaints the internal teams had about XAML was that data binding was slow and memory intensive. XAML data binding uses Reflection at run time, which is very flexible but has some overhead. So the internal teams went back to the Windows SDK team and asked for help. At first they thought their recommendation might be to tell them to not use data binding, and wire everything up by hand (back to the standard operating procedures of the Windows Forms days). They finally came up with a better idea. To remove the overhead of Reflection, both from a performance and memory perspective, they came up with a way to move a lot of that overhead to compile time, using code generation. With this, compiled bindings were born. The performance benefits of using code to wire up data mapping, and the productivity benefits of data binding. Fortunately we all get the benefits, and these compiled bindings are now the preferred way to do data binding in Windows 10 UWP apps. I sincerely hope we see these in WPF too in the near future.

Another complaint was about the rigidity of Grid and StackPanel layout, and especially when it comes to responsive design. The solution to this one came from the Android layout system, and the RelativePanel was born. Instead of manipulating grid columns and rows and similar properties, now the location of elements can be defined by their relation to other elements, and this is so much easier to understand and use.

Additionally for responsive design (Microsoft calls it Adaptive UI), the very powerful and flexible (but sometimes very verbose) Visual State system of XAML has been streamlined and tailored to responsive design needs. Now you can easily trigger on screen size and use Setters to respond appropriately. New built in controls like the SplitView also help make it easier to make a UI that will work across multiple form factors.

In conclusion, if XAML is now good enough for the internal Microsoft teams, I am excited to see what we as app developers can make with it. It’s a new day for XAML and the future seems bright in Windows 10.

So you want to be a game developer. There are a few good options of a starting point these days, a lot more than not too long ago where you would be writing most of your own game code and libraries. I presented about Construct2 and Unity2D yesterday at Tampa Code Camp, and Joe Healy contributed a few minutes about GameMaker. Joe and I will do this session together again at Code Impact in Jacksonville August 22 and will provide some other game related sessions as well. Here are the demo projects, demo script, and slides from yesterday’s presentation:

http://1drv.ms/1OgqMeF

I had the pleasure of presenting a new session for me at the Tampa Code Camp yesterday focusing on getting started with the Universal Windows Platform (UWP) for Windows 10. I will be presenting this same session again next month at Code Impact http://www.codeimpact .org in Jacksonville, Florida. I hope to see you there, it’s a free event.

The demo script, sample projects, and slides are available here: http://1drv.ms/1OgqrJ8

Around the beginning of September, Shawn Hargreaves posted on the brand new Win2D blog announcing a new open source framework from Microsoft. In his own words:

Win2D is a Windows Runtime API we’re working on to expose the power of hardware accelerated Direct2D graphics to Universal App (Windows 8.1 and Windows Phone 8.1) developers

And also:

Win2D’s design makes it easier for a C#/C++ developer to use the full capabilities of the Direct2D API without it feeling like a walled garden. These APIs can be used with XAML to produce beautiful graphics apps with rich UI.

Shawn Hargreaves is someone I hold in very high regard. He was a lead developer on the XNA game framework. He was a developer on the MotoGP series of games. He created the Allegro game library in the early 1990’s and it is still in use today. Most recently Shawn was working with the Windows Phone team, and I have the feeling that some of those experiences are influencing the implementation of this new API in a positive way.

So is this a revival of XNA? I know a lot of people have hoped for that. I would say no. First of all this is 2D only where XNA was both 3D and 2D. Also this new Win2D framework is not tailored specifically to games, it is more about high performance 2D graphics in any app. XNA was developed specifically as a game framework. People tried to use it for more but usually ran into roadblocks because of what it was originally meant for. You can still use it to write great games and I will be working on a game framework to sit on top of it to help give a higher level API to write games using Win2D. David Taylor has already published probably the first game using it, you can see it here apps.microsoft.com/…/ca04fae3-de5c-43e9-b7d0-0d0d88346d8e

It also looks like there is going to be a rich set of vector graphics available. XNA 2D really just dealt with drawing bitmaps. Even the text was drawn using bitmap sprite sheets. In Win2D you can have vector fonts and you can do some things that would have been very difficult in XNA like drawing text using an image for the fill. From what I understand some code has been pulled in from the old XNA Framework where it makes sense, so if you used XNA you may see some familiar stuff.

This framework has also been designed from the ground up to play nicely with XAML and coexist so you can use XAML where it makes sense and this Win2D library where it makes sense and mix and match. This can be really powerful.

Now it’s very early in the process, and the team is doing 2 week sprints using agile methodologies and posting to GitHub every 2 weeks. The next drop will be in a few days. They have made some great progress so far, but have a long way to go. It’s been really fun to watch their progress and I feel it’s to the point where it’s worth taking a look at. This project is funded by Microsoft and putting someone as talented as Shawn on it makes me feel they are serious about it.

So whether you’re a game developer, or need high performance graphics in your Windows Store or Windows Phone app, or just like to play with cool stuff, go give it a try.

When I first saw the implementation of start screen backgrounds on Windows Phone 8.1 I really didn’t see any point in it. The backgrounds I tried there made it harder for me to see my icons and notifications and looked too “busy”. After thinking about it a bit thought and discussing with some other devs I saw an opportunity. One of the issues I had with Windows Phone 7 and 8.0 was that in order to make the accent color bright enough to see easily when it was rendering text, it then made the start screen too bright. What I really wanted was a darker start screen, and a lighter accent color.

With start screen backgrounds you can now do this pretty easily, just create a solid color image for whatever you want your start screen to be. I tried this and felt it didn’t have enough “character” though, so I created a few backgrounds with a bit of noise and some burnishing on the edges to make it more interesting. Here are a few I came up with, feel free to use any way you want or modify. I look forward to seeing what you come up with.

Cabernet (I’m a wine fan):

wallpaper_cabernet

Blue:

wallpaper_blue

Green:

wallpaper_green

DVLUP.com is a rewards site for Windows Phone developers that is operated by Nokia. Basically you get rewarded for doing the things you should do anyway as a Windows Phone developer. Add features, publish updates, publish new apps, and get experience points you can redeem for rewards. These rewards include gift cards, devices, accessories, and more. You can also use your XP to buy Campaigns, a way to get your apps more exposure.

Recently I signed up for the pilot program for a  new campaign that DVLUP was running. In this campaign, you take your paid app, make it free for a day, and in exchange the app is featured globally in the first spot on the Windows Phone Store for all Nokia phones. The app that I submitted for this campaign was Reading Lens, an app that lets you magnify small text and has other features like lighting the lamp on the phone and saving what’s on the screen to the saved photos album.

Reading Lens has been featured a few times before, some from campaigns and some from Microsoft just choosing to feature the app. I’m writing about this time because it was significantly different. In the past, when the app was featured, I kept it as a paid app during the time that it was featured and saw a bump in downloads, but this was short lived and within a few days things were back to where they were before. Now it may not seem to make sense that you can make more monry by making your app free when it is featured but I’m here to tell you that’s exactly what happened to me.

First of all, when featured in the past, I would see a bump of about 50 times normal downloads. You can see these bumps in this chart:

image

That looks pretty nice, but then if you look at the number of purchases over that same timeframe you can see that there was a temporary spike and then things back to how they were almost immediately:

image

In contrast, here is that same date range plus I’ve added this latest campaign. This is the downloads per day chart:

image

Those two little bumps correspond to the featured days in the chart above. The huge spike is the latest campaign. I received 2000 times the number of downloads while featured and making my app free. Ok so this was stupid right? In one day I gave away more copies of the app than were downloaded in the previous year combined. What’s important is what has happened since. Because of the app being free for a day and getting a huge number of downloads, once I changed it back to a paid app it was briefly the #1 paid app in the entire Windows Phone store. Even now I’m getting 10-20 times more downloads a day that what I was getting before the campaign. This has also led to more sales:

image

Notice how the spike once I made the app paid again is bigger than the others when I left it paid, and also that it’s more sustained. For the last week I’ve been making 10 times the previous number of purchases per day. I know this won’t last forever but it’s a very significant increase for now.

This has made me rethink app promotion in general and the next time I’m featured in country with a high concentration of Windows Phone users I’ll try this again without the campaign and do it on my own. I’ll be sure to report back and tell you how it goes.

Please ask for more information in the comments if you’re interested in discussing this further.

I haven’t run a promotion for a while, so this is a little “thank you” to all of the awesome developers in the Southeast USA. You have made my job as a Nokia Developer Ambassador very easy, and in exchange I want to give back. So this is what I’m going to do. First of all, the prizes. There will be a drawing from all of the eligible entries and four winners, each for one of the following prizes:

image

Any of these prizes can really help with your app development. Whether you want to target the small form factor Windows devices, or the most popular Windows Phone in the world, or you want to support the significant number of Windows Phone 7 users still out there, there is something for you.

Ok so how to enter? First of all, you need to reside in Florida, Georgia, North Carolina, South Carolina or Alabama. If you live somewhere else in USA or Canada, ask me who your local Nokia Developer Ambassador is and I can get you connected.

Next, you need to have published a NEW Windows Phone 8 app between Feb 1 and March 31 2014. The deadline for submissions is April 1, with a drawing on April 2. You can enter multiple times, once per new app, but only one prize per developer.

Finally, you need to email me at ext-bill.reiss at nokia.com the following by April 1:

  • Subject line: Southeast Windows Phone App Contest
  • A link to your app in the Windows Phone Store
  • Your name
  • Your City, State of residence

Thank you again for your support! 2013 was a great year and I look forward to 2014 being a big year for Windows Phone developers.

There are so many great promotions right now for Windows Phone developers in the USA (and some in Canada). Here are a few, please leave any more you know of in the comments and I’ll add them. I’ll do another one of these next month.

  • Rich Dunbar, Lead Nokia Developer Ambassador, is holding a drawing for the flagship Lumia of your choice (1020 or any of the 9xx series phones). All you need to do is have published a Windows Phone app or any update to an app in the last 6 months, basically anything related to uploading a new XAP to the store. Deadline is Sept 30, details here: http://richarddunbar.blogspot.com/2013/09/september-lumia-blowout.html Even if you’ve entered a previous drawing with Rich before, you can submit the same information for this drawing as long as that app was updated or new in the last 6 months. (USA and Canada only)
  • Microsoft is doing their Tech Affiliate monthly drawing, where you can win cash in the form of gift cards. For this one you need to publish a new Windows Phone or Windows 8 Store app in September. Enter here: http://www.mstechaffiliate.com/members/billreiss (USA only)
  • Nokia is running a Nokia Create contest with great prizes, this one goes through December: http://developer.nokia.com/create/ (Worldwide)
  • If you do not yet have a Windows Phone app in the store, when you are nearly ready to publish, I (or your local Nokia Developer Ambassador) can give you a Nokia Premium Developer Program token which includes a Windows Phone Store membership for a year and other great products and services. Just contact me as your app nears completion for details. (USA and Canada only)
  • Also when you publish your first app, once it is certified and in the store you qualify for a free Windows Phone, the Lumia 800. This is not a drawing, anyone who publishes their first app in the USA or Canada qualifies. Contact me for details. (USA and Canada only)
  • You probably know about http://www.DVLUP.com by now but if not, it’s a free site where you can register and get rewards for doing the things you’re doing anyway when developing for Windows Phone. I almost have enough points for two 1020s right now through the DVLUP program. (only in a few countries, check DVLUP.com to see if you qualify)

At the Sarasota .Net Developer’s Group in July I gave a presentation about how to improve the number of downloads and reviews for Windows Phone apps. I am by no means an expert on the topic but I’ve learned a lot along the way and everyone who has seen this session the handful of times I’ve presented it have had very positive feedback for me about it.

I will be converting as much as I can of the presentation over time into blog posts, but I was fortunate enough to have Russ Fustino, lead evangelist for ComponentOne, record the Sarasota session and with the help of his team at ComponentOne, the video is now available on YouTube.

If you like the video, and appreciate the content, please say thanks by taking a moment to download and review some of my apps, I’d really appreciate it. Thanks!

Links to my apps:

Reading Lens Free
Reading Lens
Wipeout

Enjoy!