CodeBetter.Com
CodeBetter.Com
RSS 2.0 via Feedburner
           Do you Twitter? Follow us @CodeBetter

Patrick Smacchia [MVP C#]


The Visual Studio Look and Feel

In a previous post this summer I mentioned what has been one of the best advice I got this year (from Bob Powell and Fabrice Marguerie):

When you target .NET developers, the closer to VisualStudio’UI, the better your UI is.

Here is another great advice I got this year from Scott Hanselman when he was playing with VisualNDepend:

I want to live in there (i.e in VisualNDepend), I don't want any additional UI. 

Following these advices, we are now happy to release NDepend v2.6. It comes with a project management and an analysis life cycle similar to the Visual Studio one. Concretely, we added 3 panels to VisualNDepend:

  • Start Page
  • Error List
  • Project Properties

On a side note this new version also comes with a Visual Studio studio addin compatible with VS2008 and support .NET3 \ .NET 3.5 assemblies analysis.

 

Start Page

The Start Page represents a powerful and widely accepted way to show at a glance common beginning tasks, including,

  • Create\Open project,
  • Analyze a set of .NET assemblies,
  • Compare 2 sets of assemblies.
For beginners' users, the Start Page comes with some links to the Getting Started documentation. It is also a convenient place from where to install\uninstall Visual Studio and Reflector addins. Finally, the Start Page can inform user if she's running or not the latest version available.

 

 

My friend Sebastien Andreo often says:

Make the simple things simple and the hard things possible.

Following this tenet, there is a right-click menu on Recent Projects to choose between loading the results of the most recent analysis, the result of an analysis previously done, or just the project properties. By default, left-clicking a recent project opens its most recent analysis or the project itself if the most recent analysis is not available.


 

Of course, the Start Page panel remains active and available at any time, whether the user is sifting the result of an analysis, run an analysis, edit some project properties... 

 

Error List

Beside all the Code Query Language possibilities to analyze a code base, NDepend is able to provide numerous useful information about the health of your build process, including:

  • Assemblies versionning issues such as:
    • AssemblyA references AssemblyB v2.1 but only AssemblyB v2.0 is available.
    • AssemblyA references 2 versions of AssemblyB (which is not necessarily a bad thing, but it's still useful to be aware of such situation).
  • Assembly conflicts such as:
    • The name of me assembly main module file is different from the logical name of my assembly.
    • Several different assemblies with the same name can be found (different = different hash code and/or different version).
  • PDB files issues such as:
    • Missing PDB files.
    • PDB files and code source files not in-sync.
    • PDB files and assemblies are not in-sync.

So far, this precious information emitted during analysis, was kind of buried in a section of the report. It is now available in a Error List panel. The different warnings are visible at any time, both during analysis and also when exploring results of an analysis. There is also the convenient facility to enable\disable warnings.

 

 

Project Properties

Finally, we discarded the NDepend.Project.exe UI. The new Project properties panel makes easier the choice of .NET assemblies to analyze. Also, the list of Tiers Assemblies (i.e the assemblies that we don't develop but that are used by the assemblies of our application) is now automatically inferred from the list of the application assemblies.

 

 

 

Personally, I like to use this Code to Analyze panel to have a thorough view of the set of my assemblies, with information such as:

  • Which assemblies is strong named or not (sn column)?
  • Which assemblies come with a pdb file (pdb column)?
  • Size, Platform and target Runtime of my assemblies.
  • How many assemblies are referenced by a given assembly (+ the list of referenced assemblies in a tool tip).
  • What is the list of Tiers assemblies used by my application?

Of course, you already know about this information thanks to Windows Explorer, Reflector, Ildasm, Visual Studio... The cool thing here is that the Code to Analyze panel centralizes all this.

 

 

Still following the Make the simple things simple and the hard things possible tenet, the editor of folders that contain your assemblies is now hidden by default. It becomes visible thanks to a extender button. The list of folders is populated automatically when you select your application assemblies. This folders tab is useful if you want to tweak the existing set of folders or if you want to switch to Relative path mode. In Relative path mode, folders are relative to the NDepend project file location. It is useful to use the same project on different machines. Also, for a given folder, the Folders tab shows at a glance which assembly is an Application one (green) a Tier one (blue) not used (white) and also which .exe and .dll files are not assemblies.

 

In the tab of Project Properties panel and a bit everywhere in the VisualNDepend UI, we are now using an Office 2007 invention that I don't know the name of. I would call this Info tooltip. It consists in providing a tiny information icon that displays a tooltip. I found it more convenient than classic tool tip on control because:

  • With classic tooltip, when discovering a form the user doesn't know which control has a tooltip or not.
  • The tooltip information is displayed immediately when the mouse hovers the Info tooltip, there is no classic half-second wait.
We use Info tooltip as a consolidation for the classical documentation. We all know that users barely read manual and my opinion is that Info tooltip is a good way to access documentation just-on-time. For example, here, we estimate that if the user is using its own Xsl sheet to build report, she might want to know where she can find information about how she can build a custom Xsl sheet.

 

 




Comments

DVD » Blog Archive » The Visual Studio Look and Feel said:

Pingback from  DVD  » Blog Archive   » The Visual Studio Look and Feel

# December 10, 2007 10:47 AM

Granville Barnett said:

First off, NDepend is becoming very quickly one of my most favourite applications to use when reviewing

# December 10, 2007 11:56 AM

C-J Berg said:

Simply excellent! :-)

# December 10, 2007 7:34 PM

Tales from the SharpSide said:

Links from the Sharpside [12/10/07]

# December 10, 2007 11:57 PM

Maxiname » Blog Archive » The Daily Grind 1292 said:

Pingback from  Maxiname  » Blog Archive   » The Daily Grind 1292

# December 11, 2007 9:12 AM

secretGeek said:

brilliant work Patrick!

and the start page you've created looks more useful than the start page for Visual Studio. The addins and version check panels are a good idea.

Incidentally, the idea of reimplementing the VS look and feel makes me wonder if you've looked into using the VS2008 shell, that is available now. It sounds like a fair match for this kind of problem.

cheers and best of luck

lb

# December 11, 2007 7:33 PM

Patrick Smacchia said:

We are reluctant to integrat all the VisualNDepend panels inside VisualStudio because:

-It could hurt VS perf (the alst thing that developers want),

-It would make a lot of panels,

-The notion of NDepend project is more general than the notion of VS solution, often a NDepend project embed assemblies that come from several VS sln.  

So the integrated mode might not be an option but the isolated mode might represent a great alternative...

# December 12, 2007 3:45 AM

Grant Palin said:

Have downloaded and tried the new version - very nice!  Time to get on learning the ins and outs of the software.  The Visual Studio integration suggestion is an interesting idea, but I think VS is complicated enough as it is!

# December 12, 2007 6:17 PM

links for 2007-12-14 | GrantPalin.com said:

Pingback from  links for 2007-12-14 | GrantPalin.com

# December 14, 2007 11:23 AM

Pages tagged "bob powell" said:

Pingback from  Pages tagged "bob powell"

# January 26, 2008 12:37 AM

Leave a Comment

(required)  
(optional)
(required)  

Enter the numbers above:
Add

About Patrick Smacchia

Patrick Smacchia is a Visual C# MVP involved in software development for over 15 years. After graduating in mathematics and computer science, he has worked on software in a variety of fields including stock exchange, airline ticket reservation system as well as a satellite base station at Alcatel. He's currently a software consultant and trainer on .NET technologies as well as the lead developer of the tool NDepend which provides numerous metrics and caveats on any compiled .NET application. He is the author of Practical .NET2 and C#2, a .NET book conceived from real world experience with 647 compilable code listings. Check out Devlicio.us!

Our Sponsors