' Labeling W I T H Variables - HP 7470A Interfacing And Programming Manual

Graphic plotter
Hide thumbs Also See for HP 7470A:
Table of Contents

Advertisement

>
corner of the first character space and the carriage-return point. After
lettering a character, the pen stops at the lower-left corner of the next
character space as shown below. For a further explanation of character
spacing, refer to Spacing Between Characters in this chapter.
)
)
1 }
n
)
. >
'
)
i
!
• )
CHARACTER
STARTING
POINT
When the plotter receives the character, carriage return, while in label
mode, it returns to a defined carriage-return point. The carriage-return
point usually reflects the pen's position when the preceding LB instruc­
tion was executed. The carriage-return point is updated to the current
pen position whenever:
• one of the following instructions is executed: PA, PR, DI, DR, AA,
AR, RO, DF, or IN.
• you use the front-panel CLEAR and RESET function keys or use the
pen controls to move the pen to a new point.
' labeling w i t h Variables
'
)
In some applications, it is desirable to label the plot using variables
- ,
rather than literals to define the label string. Many different conven-
'
tions are used in different computer languages and computers to define
, )
variable length and the character field format in which these variables
will be printed. To avoid unexpected placement of the labels defined by
'
variables, refer to your computer manual for a definition of the conven-
\
tions used to define the output character field.
\
Quotation marks are used by many computers to define the literal char­
acters that are to be sent, but variables are not included within quo-
)
tation marks. The comma is used by some computers as a delimiter
*-8 LABELING
C)
between variables to cause the label string to be right-justified in a
specific character-field width. The unused character positions in this
field are normally sent as leading blank spaces to establish fixed spac­
ing between label strings. For close spacing of label strings, the blank
spaces can normally be suppressed by substituting a semicolon as a
delimiter between variables.
The following example illustrates use of the comma to establish fixed
spacing when using variables for labeling. When the value of X is 50,
the labels shown are produced by the given HP-GL instructions. The
first statement causes the plotter to label the value of X, X+l, and X+2.
Blank spaces between the printed integers normally include space for
the sign which may or may not be printed depending on your computer.
The number of blank character-field spaces may vary with different
computers.
" L B " , X , X + 1 , X + 2 , " V
5 0
51
5 2
I
,
I I
,
I
BLANK CHARACTER FIELD SPACES
The following example illustrates the closer spacing achieved in BASIC
when semicolons separate variables in labeling commands. The semi­
colons between the variables cause suppression of blank spaces. The
space between the printed integers varies with different computers, but
normally includes the sign space.
" L B " ; X ; X + 1 ; X + 2 ; " V
50
51
52
Any spaces required to fit into the context of the item being labeled
must normally be sent enclosed in quotes. The following example labels
the same variables as above, but with four extra spaces between each
of the integers. Note that four spaces enclosed in quotes are sent be­
tween each variable, but the semicolon suppresses unwanted blank
spaces.
" L B " ; X ; "
" ; X + 1 ; "
" ; X + 2 ; " V
50
51
52
LI
LI
1
FOUR EXTRA SPACES
LABELING 5-9

Advertisement

Table of Contents
loading

Table of Contents