“Universal” Mandelbrot

September 10, 2014

Those of you following my blog may have noticed a somewhat “obsessiveness” with the Mandelbrot Set. In the past, I’ve created a WPF version and a C++ AMP version (and privately a few more versions). I thought it was high time to write yet another version as a “Universal” app, running on Windows 8.1 and Windows Phone 8.1, while sharing as much code and XAML as possible. My approach was to port the WPF version to universal. First, I created a blank new Universal App project in C#: This results in 3 projects being created – Mandelbrot.Windows, Mandelbrot.WindowsPhone...
no comments

Tip: Accessing Binary Resources in Portable Class Library

August 10, 2014

Portable Class Libraries (PCLs) provide a nice way to share code by allowing the library to be referenced from a number of different types of projects. As I’ve blogged before, when targeting Windows Phone 8.1 and Windows 8.1 the common surface for the PCL grows significantly and even allows sharing of XAML and other UI-related types. However, when targeting more frameworks such as the desktop .NET, the common surface drops significantly. One of the things we may want to do is to add some binary resource (image, XML file, etc.) and process it as part of the PCL. This...
no comments

Data Binding for a WPF TreeView

July 12, 2014

Although the Windows Runtime (WinRT) is all the hype these days (in the Microsoft world at least), WPF is still in heavy use in the “desktop apps” space. To me, WPF is the inspiration for everything XAML-based that came out after it – mainly Silverlight and WinRT. WinRT (and Silverlight before it) still plays catchup to all the WPF features (although WinRT has some nice features not present in the current version of WPF) – there’s even a “user voice” asking to bring some of WPF’s features to WinRT, such as multi bindings, binding in style setters, data typed...
no comments

My DevGeekWeek 2014 Session Demos

June 22, 2014

Today I presented three sessions in the DevGeekWeek 2014 conference held in the Daniel Hotel in Hertzliya (Israel). The session were part of the Core .NET and C# track. My three sessions were on the Task Parallel Library (1), Async programming with C# 5.0 (2) and C# Tips with some discussion of C# 6.0 features (3). Another session was given by my colleague, Igal Tabachnik on building compiler extensions with Roslyn. Thank you all for attending, although I know it was challenging in the first half day, at least, with the A/C cranked up (or should I say...
no comments

DevGeekWeek 2014

May 26, 2014

The DevGeekWeek 2014 conference is scheduled for the 22-26 of June and will be held in the Daniel Hotel in Hertzelia (Israel). This is a developer oriented conference with a lot of great sessions and topics. We at CodeValue are managing and delivering the .NET track (officially called “Extreme .NET with C#”) consisting of 6 full day sessions. There are other tracks covering things like mobile development, Java based development, User Experience, Database development, and more. I am managing the CodeValue sessions along with my colleague Alon Fliess. Our track consists of the following full day...
2 comments

Create a second accent color in Windows Phone 8.1 (kinda)

May 17, 2014

Windows Phone has the notion of an “accent color” that appears as the default background for transparent tile areas on the home screen; apps use it extensively for various purposes as they assume the user really likes that color. Personally, I like darker colors with the dark theme on the home screen, as the white text is clear and pleasant. However, apps that use the accent color for text on a black background make the text hard to read sometimes. In these cases I wish I had selected a brighter accent color. With Windows Phone 8.1 we can actually...
no comments

Universal Apps in Windows 8.1 and Windows Phone 8.1

April 20, 2014

Now that the Build 2014 conference is over and the dust begins to settle, it’s time to look at what we’ve got. And there’s plenty to look at. In this post I’d like to take a closer look at Universal apps, their structure and possible future. The before Before these so-called “universal” apps, creating apps for Windows 8.x Store and Windows Phone 8 was mostly a two-app project. Sure, some logic code could be shared via Portable Class Libraries (PCL), but the common surface of PCLs was too small, leading to many #if/#endif statements. Also, sharing XAML was extremely...
one comment

Mandelbrot Set with C++ AMP

March 23, 2014

C++ AMP (Accelerated Massive Parallelism) is a Microsoft C++ library that can be used for General Purpose (GP) computing on Graphic Processing Units (GPU), and theoretically at least, other future devices – all in mostly standard C++. “General Purpose” here means processing that is unrelated to graphic rendering, which is the basic capability of a GPU. AMP certainly has alternatives, such as Microsoft’s own High Level Shader Language (HLSL), used mostly for shader authoring, part of the GPU’s graphic pipeline; but shaders can be used for general purpose computing as well called DirectCompute; DirectCompute seems to no longer being...
2 comments

Debugger Visualizer for Non-Serializable Types

March 19, 2014

A debugger visualizer provides a rich way to “visualize” in some sense a .NET object within Visual Studio while debugging. Writing a basic debugger visualizer is simple enough: create a Class Library project with a class that derives from DialogDebuggerVisualizer and override the Show method. Inside the Show method, a call to IVisualizerObjectProvider.GetObject method (the interface is provided in an argument to Show) retrieves the object in question. The next step would be to create the actual “visualizer”and show it with a call to IDialogVisualizerService.ShowDialog method. To actually advertise the existence of the visualizer, an assembly level attribute...
no comments

Creating an Object Manager Browser Part 3 – Security Dialog

February 26, 2014

In the previous post we’ve managed to get most of WinObj’s functionality – browsing the folders and viewing object information. The last “major” missing piece is the security dialog that shows security related information for certain object types. I’m certainly not a security expert; on top of that the security API in Windows is one of the most dreadful APIs in all Windows. Fortunately, to get the standard security dialog to show we just need to call one function – EditSecurity or CreateSecurityPage. The former shows the basic security dialog box and returns when it’s dismissed, while the latter...
2 comments