ArborX


unit

Longname: unit   Open the Documentation Legend
Released: not available 
Created: not available 
See also: saveunits tdpref tdruler

Summary
Adds user-defined units of measurement to the options offerred in 3B2. 3B2's default units of measurement are defined in ssys.3ad as shown below. User-defined units are not stored with a document. If you need to transfer a document that uses user-defined units to another system, you should ensure compatibility by including the appropriate unit macros in the document's autoexec script.
Example extract

To disable the cicero unit of measurement, for example, you could enter:

 unit 1

Syntax (SVNNA)
number:n

A number from 1..12 specifying which of the 12 different unit types you are defining. Units 1..7 are 3B2's default system units.

abb1:s

A two-character string representing the units abbreviation (e.g. "in" for inches). This abbreviation is used when entering unit measurements in 3B2.

An alternative abbreviation for the same measurement. Intended for use on non-English systems where the abbreviations need to be translated.

Long name of the measurement up to 12 characters. Used in the document preferences and ruler dialogue boxes.

The natural 'divisor' for this measurement. This will be used on rulers for tick marks and will also be used to calculate the second part of two-part units.

Links to a 2nd part of a two-part unit (e.g. "pc" would link to "pt" and "cc" would link to "dd").

Do not use this unit in non-strict mode unless the measurement is less than the given minimum size (in millimetres).

A floating point number accurate to many decimal places which specifies the size in millimetres of the unit. Any of 3B2's default units of measurement can be cleared by entering unit followed by the appropriate number and no further parameters. This can make some dialogue boxes less daunting.

abb2:s

An alternative abbreviation for the same measurement. Intended for use on non-English systems where the abbreviations need to be translated.

longname:s

Long name of the measurement up to 12 characters. Used in the document preferences and ruler dialogue boxes.

base:n

The natural 'divisor' for this measurement. This will be used on rulers for tick marks and will also be used to calculate the second part of two-part units.

two_part_link:n

Links to a 2nd part of a two-part unit (e.g. "pc" would link to "pt" and "cc" would link to "dd").

min:f

Do not use this unit in non-strict mode unless the measurement is less than the given minimum size (in millimetres).

unit_size:f

A floating point number accurate to many decimal places which specifies the size in millimetres of the unit. Any of 3B2's default units of measurement can be cleared by entering unit followed by the appropriate number and no further parameters. This can make some dialogue boxes less daunting.

 ' unit definitions 1
 ' unit num(1..13),abb1,abb2,longname,base,two_part_link,min(mm), 3
 unit_size(mm) 4
 unit 1 ,"cc","cc","cicero",12,7,30,4.5134837925 5
 unit 2 ,"mm","mm","mm" ,10,0,0 ,1.0 7
 unit 3 ,"cm","cm","cm" ,10,0,30,10.0 9
 unit 4 ,"in","in","inch" ,10,0,0 ,25.4 11
 unit 5 ,"pt","pt","point" ,12,0,0 ,0.35145980351 13
 unit 6 ,"pc","pc","pica" ,12,5,30,4.2175176422 15
 unit 7 ,"dd","dd","didot" ,12,0,0 ,0.37612364938 17
  19
 ' built-in support for 3B2's internal units, deci-microns 21
 unit 13,"dm","dm","dm" ,10,0,214748.3647,0.0001 23
  25
 ' examples of user-defined units 27
 'unit 8 ,"tn","tn","10ths" ,10,0,0 ,2.54 29
 'unit 9 ,"sx","sx","6ths" , 6,0,0 ,4.23333333333 31
 'unit 10,"tf","tf","24ths" ,24,0,0 ,1.05833333333 33
  35
 'unit 11,"st","st","16ths" ,16,0,0 ,1.5875 37
 'unit 12,"tt","tt","32nds" ,32,0,0 ,0.79375 39
  41
 'unit 8,"ft","ft","feet" ,12,4,0 ,304.8 43

Document created on 08-Feb-2003 (revision 1)