Skip to content

Commit 54679bf

Browse files
author
Jeremy Tammik
committed
added code to demonstrate use of LabelUtils.GetLabelFor taking UnitSymbolType argument
1 parent 2574b5d commit 54679bf

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

BuildingCoder/BuildingCoder/CmdDutAbbreviation.cs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -118,8 +118,9 @@ DisplayUnitType n
118118
= DisplayUnitType.DUT_GALLONS_US;
119119

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

125126
string unit_types, valid_unit_symbols;
@@ -141,8 +142,10 @@ DisplayUnitType n
141142

142143
valid_unit_symbols = string.Join( ", ",
143144
FormatOptions.GetValidUnitSymbols( i )
145+
.Where( u => UnitSymbolType.UST_NONE != u )
144146
.Select<UnitSymbolType, string>(
145-
u => Util.UnitSymbolTypeString( u ) ) );
147+
u => LabelUtils.GetLabelFor( u )
148+
+ "/" + Util.UnitSymbolTypeString( u ) ) );
146149

147150
Debug.Print( "{0,6} - {1} - {2}: {3}",
148151
Util.DisplayUnitTypeAbbreviation[(int) i],

BuildingCoder/BuildingCoder/Properties/AssemblyInfo.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,5 +31,5 @@
3131
//
3232
// You can specify all the values or you can default the Revision and Build Numbers
3333
// by using the '*' as shown below:
34-
[assembly: AssemblyVersion( "2014.0.105.1" )]
35-
[assembly: AssemblyFileVersion( "2014.0.105.1" )]
34+
[assembly: AssemblyVersion( "2014.0.105.2" )]
35+
[assembly: AssemblyFileVersion( "2014.0.105.2" )]

0 commit comments

Comments
 (0)