(go to: table of contents, index, list of vms_smg, prev: KEYCODE_TO_NAME, next: NEXT)
Format:
None
Arguments:
LABEL_BORDER - Label a Virtual Display Border
Supply a label for a virtual display's border.
None = vms_smg.label_border (display_id, \
[text], [position_code], [units], \
[rendition-set], [rendition-complement], \
[character-set])
Returns:
Examples:
(go to: table of contents,
index, list of vms_smg,
prev: KEYCODE_TO_NAME,
next: NEXT)
>>> import vms_smg
>>> import vms_smgdef
>>> # create a new DECwindows terminal using SMG
>>> status, pasteboard_id, number_of_pasteboard_rows, \
... number_of_pasteboard_columns, type_of_terminal, \
... device_name = vms_smg.create_pasteboard \
... (None, vms_smgdef.SMG_M_WORKSTATION)
>>>
>>> # create virtual display 1
>>> status, vtdpy1 = vms_smg.create_virtual_display \
... (5, 10, vms_smgdef.SMG_M_BORDER, None, None)
>>>
>>> # write to virtual display 1
>>> status = vms_smg.put_chars (vtdpy1, 'V1', 0, 0)
>>>
>>> # create virtual display 2
>>> status, vtdpy2 = vms_smg.create_virtual_display \
... (5, 10, vms_smgdef.SMG_M_BORDER, None, None)
>>>
>>> # write to virtual display 2
>>> status = vms_smg.put_chars (vtdpy2, 'V2', 0, 0)
>>>
>>> # paste virtual display 1
>>> status = vms_smg.paste_virtual_display \
... (vtdpy1, pasteboard_id, 3, 5, None)
>>>
>>> # paste virtual display 2
>>> status = vms_smg.paste_virtual_display \
... (vtdpy2, pasteboard_id, 5, 7, None)
>>>
>>> # label virtual display 1
>>> vms_smg.label_border (vtdpy1, 'VTDPY1')
>>>
(Notice that the cursor of this display became visible)
>>> # label virtual display 2
>>> vms_smg.label_border (vtdpy2, 'DPY2', vms_smgdef.SMG_K_RIGHT)
>>>
(Notice that the cursor of this display became visible, again)
Puzzled why display 2 is not labeled 'VTDPY2'?
--> The name is too long for the right border!
>>> vms_smg.label_border (vtdpy2, 'VTDPY2', vms_smgdef.SMG_K_RIGHT)
Traceback (innermost last):
File "<stdin>", line 1, in ?
vms_smg.error: (1212940, '%SMG-F-INVARG, invalid argument')
>>>