Skip to content

Commit

Permalink
added code to demonstrate use of LabelUtils.GetLabelFor taking UnitSy…
Browse files Browse the repository at this point in the history
…mbolType argument
  • Loading branch information
Jeremy Tammik committed Nov 17, 2013
1 parent 2574b5d commit 54679bf
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
9 changes: 6 additions & 3 deletions BuildingCoder/BuildingCoder/CmdDutAbbreviation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -118,8 +118,9 @@ DisplayUnitType n
= DisplayUnitType.DUT_GALLONS_US;

Debug.Print( "Here is a list of the first {0} "
+ "display unit types with The Building Coder "
+ "abbreviation and the valid unit symbols:\n",
+ "display unit types with official Revit API "
+ "LabelUtils and hard-coded The Building Coder "
+ "abbreviations and the valid unit symbols:\n",
(int) n - 1 );

string unit_types, valid_unit_symbols;
Expand All @@ -141,8 +142,10 @@ DisplayUnitType n

valid_unit_symbols = string.Join( ", ",
FormatOptions.GetValidUnitSymbols( i )
.Where( u => UnitSymbolType.UST_NONE != u )
.Select<UnitSymbolType, string>(
u => Util.UnitSymbolTypeString( u ) ) );
u => LabelUtils.GetLabelFor( u )
+ "/" + Util.UnitSymbolTypeString( u ) ) );

Debug.Print( "{0,6} - {1} - {2}: {3}",
Util.DisplayUnitTypeAbbreviation[(int) i],
Expand Down
4 changes: 2 additions & 2 deletions BuildingCoder/BuildingCoder/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,5 @@
//
// You can specify all the values or you can default the Revision and Build Numbers
// by using the '*' as shown below:
[assembly: AssemblyVersion( "2014.0.105.1" )]
[assembly: AssemblyFileVersion( "2014.0.105.1" )]
[assembly: AssemblyVersion( "2014.0.105.2" )]
[assembly: AssemblyFileVersion( "2014.0.105.2" )]

0 comments on commit 54679bf

Please sign in to comment.