home *** CD-ROM | disk | FTP | other *** search
/ Vectronix 2 / VECTRONIX2.iso / FILES_09 / NAESUTIL.LZH / UTIL / TW100 / TW100.DOC < prev    next >
Text File  |  1996-02-08  |  8KB  |  182 lines

  1. Toswin TW100 - TOS programs in a window with VT100 emulation
  2.  
  3.   Version 0.9 - 13 October 1995
  4.  
  5. Description
  6.  
  7.   This is an extension to Toswin (see toswin.doc) that recognises vt100 escape
  8.   sequences.  The original Toswin recognised vt52 escapes with some extensions.
  9.   However, vt52 emulation is not really suitable for accessing other systems,
  10.   e.g. various flavours of unix, hence tw100.
  11.  
  12.   An extra menu item (Reset window) has been added to the window menu.  This
  13.   resets the terminal attributes to the initial settings.  This has the same
  14.   effect as the reset escape sequence.
  15.  
  16.  
  17. Known Bugs & Features
  18.  
  19.   There is no alternative vt100 character set.
  20.  
  21.   The font tw100v.fnt uses the vt100 character set.  Thus characters with the
  22.   eighth bit set will not be the 'normal' Atari ones.
  23.  
  24.   ANSI character sizes, graphic modes and key redefinition escapes are not
  25.   implemented.
  26.  
  27.   The clear all tabs escape resets the tabs to be every 8 columns - I'm not
  28.   sure if this standard vt100 behaviour or not.
  29.  
  30.   ANSI and vt100 escapes are recognised and acted upon in vt52 mode.
  31.  
  32.   Changing the number of lines doesn't reset the scrolling region.
  33.  
  34.   Changing to vt52 mode doesn't reset the scrolling region.
  35.  
  36.   Cut and paste doesn't handle end of line.
  37.  
  38.   No way to cycle windows.
  39.  
  40.  
  41. Termcap & terminfo
  42.  
  43.   The termcap is basically a vt100 with a few additions.  The default terminal
  44.   type is tw100.  If TERM is set to vt100, a vt100 termcap or terminfo entry
  45.   will work.  The files tw100.tc and tw100.ti contain termcap and uncompiled
  46.   terminfo entries respectively.
  47.  
  48.  
  49. Escape sequences
  50.  
  51.   These are the sequences recognised and acted upon by tw100.  They are not
  52.   necessarily a concise list of vt52/vt100/ansi codes.  In some cases, a
  53.   sequence will have a different result, depending on the mode the window is
  54.   in.
  55.  
  56.   Code        Mode  Description
  57.   ESC >       tw52    switch to tw100 mode
  58.   ESC 7               save cursor position
  59.   ESC 8               restore cursor position
  60.   ESC A               cursor up
  61.   ESC B               cursor down
  62.   ESC C               cursor right
  63.   ESC D       tw52    cursor left
  64.   ESC D       tw100   carriage return
  65.   ESC E       tw52    clear home
  66.   ESC E       tw100   carriage return & line feed
  67.   ESC H       tw52    cursor home
  68.   ESC H       tw100   set tab at cursor position
  69.   ESC I               cursor up & insert line
  70.   ESC J               clear below cursor
  71.   ESC K               clear remainder of line
  72.   ESC L               insert line
  73.   ESC M       tw52    delete line
  74.   ESC M       tw100   reverse carriage return
  75.   ESC Q               quote next character
  76.   ESC R               set window size
  77.   ESC S               set title bar
  78.   ESC T               send termcap string
  79.   ESC Yrc             move cursor to row r, column c
  80.   ESC Z               return terminal id
  81.   ESC a               delete character
  82.   ESC b               set foreground colour
  83.   ESC c       tw52    set background colour
  84.   ESC c       tw100   reset
  85.   ESC d               clear to cursor
  86.   ESC e               enable cursor
  87.   ESC f               cursor off
  88.   ESC h               enter insert mode
  89.   ESC i               leave insert mode
  90.   ESC j               save cursor position
  91.   ESC k               restore cursor position
  92.   ESC l               clear line
  93.   ESC o               clear from start of line to cursor
  94.   ESC p               reverse video on
  95.   ESC q               reverse video off
  96.   ESC t               set cursor timer
  97.   ESC u               cursor flashing off
  98.   ESC v               wrap on
  99.   ESC w               wrap off
  100.   ESC y               set special effects
  101.   ESC z               clear special effects
  102.   ESC [n@             insert n characters
  103.   ESC [nA             cursor up n
  104.   ESC [nB             cursor down n
  105.   ESC [nC             cursor right n
  106.   ESC [nD             cursor left n
  107.   ESC [y;xH           cursor to x,y
  108.   ESC [nJ             clear screen parts (n = 0 - clear to end,
  109.                                               1 - clear from beginning,
  110.                                               2 - clear all)
  111.   ESC [nK             clear line parts (n = 0 - clear to end,
  112.                                             1 - clear from beginning,
  113.                                             2 - clear all)
  114.   ESC [nL             insert n lines
  115.   ESC [nM             delete n lines
  116.   ESC [nP             delete n characters
  117.   ESC [c              terminal description
  118.   ESC [y;xf           cursor to x,y
  119.   ESC [ng             clear tabs (n = 0 - tab at cursor,
  120.                                       3 - all tabs)
  121.   ESC [nh             keyboard/screen attributes (n = 2 - keyboard locked,
  122.                                                       4 - insert mode)
  123.   ESC [nl             keyboard/screen attributes (n = 2 - keyboard unlocked,
  124.                                                       4 - overwrite mode)
  125.   ESC [nm             character attributes (n = 0 - all attributes off,
  126.                                                 1 - bold on,
  127.                                                 2 - faint on,
  128.                                                 4 - underline on,
  129.                                                 5 - blink on (uses italics),
  130.                                                 7 - reverse video on,
  131.                                                 21 - bold off,
  132.                                                 22 - faint off,
  133.                                                 24 - underline off,
  134.                                                 25 - blink off,
  135.                                                 27 - reverse video off,
  136.                                                 30 - white foreground,
  137.                                                 31 - black foreground,
  138.                                                 32 - red foreground,
  139.                                                 33 - green foreground,
  140.                                                 34 - yellow foreground,
  141.                                                 35 - blue foreground,
  142.                                                 36 - magenta foreground,
  143.                                                 37 - cyan background,
  144.                                                 40 - white background,
  145.                                                 41 - black background,
  146.                                                 42 - red background,
  147.                                                 43 - green background,
  148.                                                 44 - yellow background,
  149.                                                 45 - blue background,
  150.                                                 46 - magenta background,
  151.                                                 47 - cyan background)
  152.   ESC [nn             reports (n = 5 - status report
  153.                                    6 - cursor position
  154.   ESC [!p             soft reset
  155.   ESC [m;nr           set scrollin region to lines m through n
  156.   ESC [?nh            mode set (n = 3 - 132 column mode,
  157.                                     4 - smooth scroll,
  158.                                     5 - inverse video on,
  159.                                     7 - wrap on,
  160.                                     25 - cursor on,
  161.                                     50 - cursor on)
  162.   ESC [?nl            mode reset (n = 2 - switch to tw52 mode,
  163.                                       3 - 80 column mode,
  164.                                       4 - jump scroll,
  165.                                       5 - inverse video off,
  166.                                       7 - wrap off,
  167.                                       25 - cursor off,
  168.                                       50 - cursor off)
  169.  
  170.  
  171. Programs behaving oddly
  172.  
  173.   Elvis (vi clone), at least in the version 1.7 ST port, expects the terminal
  174.   to be in auto-wrap mode.  The vt100 termcap entry sets the terminal to no
  175.   line wrap in the termcap initialisation sequence.  This means that lines
  176.   with length equal to or greater than the window width cause the display to
  177.   be incorrect.  This does not happen with 'real' vi on unix systems.
  178.  
  179.   Lynx (version 2.3.1 ST port) doesn't handle the cursor keys correctly.  The
  180.   emacs cursor movement keys (^B, ^F, ^P, ^N) need to be used instead.
  181.   
  182.