home *** CD-ROM | disk | FTP | other *** search
/ Dream 52 / Amiga_Dream_52.iso / Linux / Divers / lynx2.8.1dev.10.tar.gz / lynx2.8.1dev.10.tar / lynx2-8 / samples / lynx-keymaps < prev    next >
Text File  |  1998-05-10  |  2KB  |  83 lines

  1. # This is a sample key sequence definition file.
  2. # Lines that start with a '#' are comment lines.  Blank lines are ignored.
  3.  
  4. # The 'setkey' function may be used in two ways:
  5. #
  6. #   1.  setkey ESC-SEQUENCE  KEYSYM
  7. #   2.  setkey ESC-SEQUENCE  KEYSYM_NAME
  8. #
  9. # where KEYSYM is an integer.  A keysym is essentually with the lynx.rc
  10. # file calls a 'keystroke', but I think that keysym is a more appropriate
  11. # name.  The keysym is an integer and may be expressed in various ways:
  12. #
  13. #       as a decimal integer:  97
  14. #       hexadecimal:           0x61
  15. #       Octal:                 0141
  16. #       as an ASCII character: 'a'
  17. #
  18. # Some keysyms may be expressed symbolically as a keysym name using the
  19. # second form.  The currently recognized symbolic names are:
  20. #
  21. #       UPARROW
  22. #       DNARROW
  23. #       RTARROW
  24. #       LTARROW
  25. #       PGDOWN
  26. #       PGUP
  27. #       HOME
  28. #       END
  29. #       F1
  30. #       DO_KEY
  31. #       FIND_KEY
  32. #       SELECT_KEY
  33. #       INSERT_KEY
  34. #       REMOVE_KEY
  35. #       DO_NOTHING
  36. #
  37. # It does not matter if your keyboard does not have some of the keys
  38. # implied by the above names.  The fact is that lynx uses these keys as an
  39. # an intermediate representation.
  40. #
  41. # The ESC-SEQUENCE should be enclosed in double quotes.  The '^' character
  42. # is special and indicates a control character, e.g., ^K is Ctrl-K.  An ESC
  43. # character (ascii 27) may be represented as ^[.  As an example, many
  44. # terminals have arrow keys that emit 'ESC [ A' for the UP arrow.  This may
  45. # be represented as the escape sequence "^[[A".  The default keymapping is
  46. # given below:
  47. #
  48. setkey "\033[A"        UPARROW
  49. setkey "\033OA"        UPARROW
  50. setkey "\033[B"        DNARROW
  51. setkey "\033OB"        DNARROW
  52. setkey "\033[C"        RTARROW
  53. setkey "\033OC"        RTARROW
  54. setkey "\033[D"        LTARROW
  55. setkey "\033OD"        LTARROW
  56. setkey "\033[1~"    FIND_KEY
  57. setkey "\033[2~"    INSERT_KEY
  58. setkey "\033[3~"    REMOVE_KEY
  59. setkey "\033[4~"    SELECT_KEY
  60. setkey "\033[5~"    PGUP
  61. setkey "\033[6~"    PGDOWN
  62. setkey "\033[8~"    END
  63. setkey "\033[7~"    HOME
  64. setkey "\033[28~"    F1
  65. setkey "\033[29~"    DO_KEY
  66. #
  67. # All other keys map to themselves, e.g,
  68. #
  69. setkey "a"        'a'
  70. #
  71. # Now suppose that your terminal produces different escape sequences for
  72. # HOME and END.  In particular, suppose that the home key produces 'ESC [
  73. # H' and that the end key produces 'ESC [ K'.  Then these may be defined to
  74. # map to lynx HOME and END keys via
  75. #
  76. setkey "^[[H"        HOME
  77. setkey "^[[K"        END
  78. #
  79. # Similarly, we may map emacs-like sequences to these functions:
  80. #
  81. setkey "^[<"        HOME
  82. setkey "^[>"        END
  83.