(go to: table of contents, index, list of vms_smg, prev: LOAD_VIRTUAL_DISPLAY, next: MOVE_VIRTUAL_DISPLAY)
Format:
None
Arguments:
MOVE_TEXT - Move Text from One Virtual Display to Another
Move a rectangle of text from one virtual display to another virtual display.
None = vms_smg.move_text (display_id, \
top_left_row, top_left_column, \
bottom_right_row, bottom_right_column, \
display_id2, \
[top_left_row2], [top_left_column2], \
[flags])
Returns:
Examples:
(go to: table of contents,
index, list of vms_smg,
prev: LOAD_VIRTUAL_DISPLAY,
next: MOVE_VIRTUAL_DISPLAY)
>>> 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 a virtual display
>>> status, vtdpy1 = vms_smg.create_virtual_display \
... (5, 10, vms_smgdef.SMG_M_BORDER, None, None)
>>>
>>> # paste the virtual display
>>> status = vms_smg.paste_virtual_display \
... (vtdpy1, pasteboard_id, 3, 5, None)
>>>
>>> # put some text in the display
>>> status = vms_smg.put_chars (vtdpy1, 'Line1Line1Line1', 1, 1)
>>> status = vms_smg.put_chars (vtdpy1, 'Line2Line2Line2', 2, 2)
>>> status = vms_smg.put_chars (vtdpy1, 'Line3Line3Line3', 3, 3)
>>>
>>> # create another virtual display
>>> status, vtdpy2 = vms_smg.create_virtual_display \
... (6, 11, vms_smgdef.SMG_M_BORDER, None, None)
>>>
>>> # paste the virtual display
>>> status = vms_smg.paste_virtual_display \
... (vtdpy2, pasteboard_id, 5, 7, None)
>>>
>>> # copy (some) text, but use an offset in the other display
>>> vms_smg.move_text ( \
... vtdpy1, # display_id
... 1, # top_left_row
... 1, # top_left_column
... 3, # bottom_right_row
... 8, # bottom_right_column
... vtdpy2, # display_id2
... 2, # [top_left_row2]
... 2, # [top_left_column2]
... 0) # [flags]
>>>
Notice that the text from the old display was removed.