Products, the Universe and Everything

The Riverblade Developer's Blog

Beth demonstrating Visual Lint at the ACCU Conference 2008  Anna taking part in a discussion panel at the European Software Conference 2007 

Welcome to our developer's blog. We hope that this forum provides an insight into us, our products and how we develop them. Please feel free to write to us if you have anything to add to any of the posts here.

Current Entries | Archives |

All Quiet on the ResOrg Front? Not Exactly...
Thursday, December 17, 2009

When I first released ResOrg 1.2 to CodeProject back in 2001, I had no idea how useful (or otherwise) other developers would find it. All I knew was that for me it helped with a real pain point. Quite frankly, I was thoroughly sick of converting resource.h files to spreadsheets and back just to identify conflicts and renumber resource IDs.

The ResOrg 1.x application

The standalone ResOrg application then grew to include a Visual C++ 6.0 add-in and then to support a rudimentary form of multi-file analysis. When Visual Studio .NET 2002 was released, Nick Hodapp (then the Visual C++ Product Manager) contacted a number of other add-in authors and I and offered us all free copies of the new version in exchange for us porting our code to the new version. ResOrg.NET (as it was termed was basically the same as ResOrg, but added a simple toolwindow which allowed you to view and edit the properties of a single resource symbol file:

The ResOrg.NET 1.x toolwindow. With hindsight, this was rather limited in scope - the new Symbol Files Display (keep reading...) is far more capable.

As the automation model of VS2002 was very different (and far more complex) than that of VC6 that port was a little painful, to say the least; ResOrg ended up with two builds and two installers - one for VC6, and one for VS2002 onwards. Although the VC6 version hasn't been updated in ages (v1.6.1 was released in December 2004) various breaking changes in subsequent Visual Studio versions meant minor updates to ResOrg.NET have continued sporadically ever since.

For example, when Visual Studio 2005 was released, it proved to be completely allergic to the MFC ActiveX control used to implement the ResOrg.NET toolwindow, and I was forced to convert it to an ATL only implementation in v1.6.2.2. That then caused yet more issues when Visual Studio 2008 was released, as it proved to be incompatible with ATL windowing code built with versions of Visual Studio prior to Visual Studio 2005*. As the ResOrg.NET code was by then built with Visual Studio .NET 2003, the logical thing to do was port the code to Visual Studio 2008.

* When Visual Studio 2008 came out it was released as a process with Data Execution Prevention (DEP) enabled. In consequence, any add-ins for VS2008 which use ATL for user interface code (which ResOrg 1.x does for its toolwindow) and which were built with ATL 7.1 or earlier will not run in VS2008 since these versions of ATL use a technique for message thunking which triggers DEP and shuts down the process. Although this was corrected in ATL 8, it does mean that add-ins for VS2008 onwards must be built with later versions of Visual Studio (this same issue caused us to shift the builds for Visual Lint from VS2003 to VS2008).

It was at that point that things went quite horribly wrong. ResOrg 1.x is an MFC based codebase, and unfortunately the versions of MFC shipped since Visual Studio 2005 come with extra baggage (specifically SXS activation runtime checks*) not present in previous versions. Murphy's Law being what it is, although the app itself worked OK the new code would crash randomly in the add-in, and we were unable to identify a workaround. As a result the port failed and the build was reverted to VS2003 - but obviously without VS2008 support.

* Look up STATUS_SXS_EARLY_DEACTIVATION and STATUS_SXS_INVALID_DEACTIVATION for details. It's a very poorly documented area, unfortunately.

Although we have since released some minor fixes there it has largely lain since. Almost.

When we discovered the SXS issue and realised that we had hit a brick wall it became obvious that a radical rethink was in order. Several months earlier we had started the process of reimplementing the whole product in ATL/WTL (which Visual Lint uses, so we know it works well with VS2008), and although that process was making steady progress the amount to time we were able to give to it until then had been quite limited. By the time we discovered the SXS issue the core functionality was in place but the new version (by now designated ResOrg 2.0) didn't yet have a usable user interface.

That in itself proved to be a major undertaking, and as we are having to fit in work on it around Visual Lint development (itself quite intensive at the moment as we've a major release for that scheduled for January) it tends to be a bit of a side project. However, it is now sufficiently advanced that it is now about time we started talking about what we've been up to. All being well, we aim to be able to release a public build by the time VS2010 is released in March. We're not at beta yet, but not a huge distance from it.

The first ResOrg 2.0 release will offer an equivalent level of functionality to 1.6, but we are taking the opportunity to refresh the displays a little. The ResOrg 2.0 add-in will include two toolwindows - one a Symbols Display comparable to the previous version (although it is now a docking window rather than a popup frame), and the second a higher level "Symbol Files" display which shows the status of all projects/symbol files at all times. This display is effectively a more usable superset of the ResOrg.NET toolwindow in 1.x, and although it is currently still being developed, the screenshot below should give you a flavour of how it will look:

The ResOrg 2.0 add-in, running within Visual Studio 2008

ResOrg 2.0 also includes the standalone application as previously. At the moment it looks rather like its predecessor, but the intention is to replace the "Workspace" docking view with the contents of the "Symbol Files" toolwindow shown above when it is completed:

The ResOrg 2.0 application as it currently stands. The workspace view on the left will soon be replaced by a docked 'Symbol Files' Display equivalent to that in the add-in.

The ResOrg 2.0 app is itself largely complete (the only major bits missing are multi-file conflict checking and a rework of the "projects" display to match the new "Symbol Files" toolwindow in the add-in), and the add-in itself is about half way done. Support for the new Visual C++ .vcxproj project file format (a major change in itself - .vcxproj files look nothing like their predecessors) is already in place, courtesy of Visual Lint.

The plan is to have a beta of it by the time Visual Studio 2010 is formally launched in March. We hope that the new version will meet the expectations of existing users of ResOrg 2.0. We're working quite hard to make sure we don't lose any functionality in moving the code from MFC to WTL, and we are hopeful that the end result will be well worth waiting for.

Posted by Anna at 12:28 | Get Link


So what's happening with Visual Studio 2010 support, then?
Tuesday, December 15, 2009

Last night we had an enquiry asking whether Visual Lint supports Visual Studio 2010 Beta 2 (a very good question). As we last blogged about this subject back in June (see Visual Studio 2010 Support for Visual Lint and LintProject Professional) and a lot has happened since then I thought it was about time for an update.

The short version is that "They changed too much,* and it doesn't really work very well yet, but we will have something out early next year regardless".

* At least as far as the internal interfaces go - the bugs we tend to find in a new version of Visual Studio are not generally the ones you will encounter if you actually use it to compile code.

The long version is, well, quite long - so please bear with me while I elaborate.

First of all, if you are interested in the sort of issues we face when a new version of Visual Studio is approaching release you could do far worse than to take a look at Carlos Quintero's blog. Carlos is the author of MZ-Tools, and one of the most prolific add-in authors out there when it comes to identifying, reporting (and blogging about) issues in the automation interfaces for new versions of the IDE.

Some time ago I realised that Visual Studio releases broadly come in two flavours - the ones where Microsoft try to change everything (e.g. Visual C++ 5.0, Visual Studio .NET 2002 and Visual Studio 2005) and those where they consolidate the changes in the previous release (e.g Visual C++ 6.0, Visual Studio .NET 2003 and Visual Studio 2008). Visual Studio 2010 - which sports not only a new and vastly more complex C++ project file format (.vcxproj) but also a new intellisense engine and WPF based editing environment - was always destined to be in the former camp.

In short, we were expecting this release to be a bit of a pain from an integrator's perspective, and - although we'd love to have been proved wrong here - we've unfortunately been dead right on that. When Beta 1 landed, it was effectively unusable from an add-in perspective (even Visual Studio 2005 Beta 1 didn't quite manage that feat) and although we were able to do some groundwork towards supporting the new IDE, it wasn't something we were happy to release, even to our beta testers.

Furthermore, because of the volume of changes that were obviously going to be needed to support Visual Studio 2010 we had to take the decision to only implement VS2010 support in our development branch (i.e. in Visual Lint 2.5) and as a result Visual Lint 2.0 does not (and will not) support it (that's the bad news; the good news comes at the end).

What's interesting is that the previous CTPs (none of which had the new editor) worked fine with our development versions, so I'm pretty convinced that the breaks we saw in Beta 2 were entirely down to the new editor implementation. We filed our bug reports, crossed our fingers and hoped Beta 2 would resolve these issues.

For some of them it did - and we now have internal builds of Visual Lint which basically work in VS2010:

Visual Lint 2.5 running in VS2010 Beta 2

The one glaring problem remaining is menu/toolbar interfacing (one of the areas badly affected by the new editor) which is still thoroughly broken in Beta 2. Although we've been experimenting with moving the menu/toolbar interfacing for this IDE from the add-in to an associated VSPackage (the deepest and most complex level of integration available in Visual Studio) that's still not entirely satisfactory - but we are making progress so we may end up going that way anyway, despite the additional complexity it introduces.

The good news bit: Although our beta testers already have builds of Visual Lint 2.5 with VS2010 support, since we are planning to release Visual Lint 2.5 early next year the Visual Studio 2010 integration will become publicly available then. Visual Lint 2.0 will be a free update to existing Visual Lint 2.0 customers as it will accept existing v2.0 licence keys directly.

So, we will certainly have something out well in advance of the Visual Studio 2010 launch in March. How complete the Visual Lint (and ResOrg, but more of that later) integration for Visual Studio 2010 is depends on what Microsoft are able to deliver post-Beta 2, of course.

Posted by Anna at 10:37 | Get Link


ResOrg.NET has been released
Monday, December 14, 2009

The changes in this build include:
  • Added support for Unicode resource (.rc) files.

  • Corrected the line ending for files renumbered via the ResOrg.NET Explorer toolwindow.

  • The Symbols Display now responds to the mouse wheel. Our thanks to Hans Dietrich for submitting this change.

  • Fixed symbols may now be entered with either upper or lower case. Our thanks to Hans Dietrich for submitting this change.

  • Corrected a layout bug in the about box and removed the photo.

Posted by Anna at 14:25 | Get Link


Visual Lint has been released
Friday, December 04, 2009

The following changes are included in this build:
  • Corrected a bug in the parsing of quoted preprocessor symbols within project files.

  • XBox 360 project configurations are now interpreted correctly [VS2002/VS2003/VS2005/VS2008].

  • "Excluded from Build" properties in VC6/eVC4 project files are now read correctly.

  • Corrected a potential crash in the Analysis Status Display. The crash manifested on some installations when a solution was loaded.

  • Visual Studio environment variables in the IntermediateFilesFolder property of a project configuration being analysed will now be expanded correctly.

  • Revised the layout of the Configuration Wizard "Select Files" page to make it more obvious that the filename controls apply to both "Create a new configuration file" and "Use an existing configuration file" options.

  • Updated the version of TeeChart8.ocx packaged within the installer to

  • Corrected a grammatical error in the "Visual Lint Prerequisites" page within the installer.

  • The "Copy -> Issue Item Text Only" command on the Analysis Results Display context menu is now correctly disabled when no issues are selected.

Posted by Anna at 11:00 | Get Link


LintProject Professional has been released
Tuesday, December 01, 2009

The following changes are included in this build:
  • Added a /include switch to the command line. When used, it will analyse only those files matching the specified wildcard.

  • Files which are "excluded from build" in the current configuration will no longer be analysed (to override this behaviour, use "/include=*" on the command line) [VC6/eVC4/VS2002/VS2003/VS2005/VS2008/VS2010].

  • XBox 360 project configurations are now interpreted correctly [VS2002/VS2003/VS2005/VS2008].

  • Visual Studio environment variables in the IntermediateFilesFolder property of a project configuration being analysed will now be expanded correctly.

  • Fixed a bug in the reading of include folders for Borland C++ Builder 5.0/6.0.

  • Fixed a bug in the calculation of the total issue count in a solution.

  • If a configuration is not specified on the command line, the first one found will now be assumed.

  • Added .cc and .cxx to the list of C/C++ implementation file extensions recognised by LintProject Professional.

  • Corrected a minor bug in the handling of project file paths.

  • Updated the version of TeeChart8.ocx packaged within the installer to

Posted by Anna at 11:03 | Get Link