keyboard.rc
author Claus Gittinger <cg@exept.de>
Wed, 01 Dec 1999 23:17:25 +0100
changeset 399 5a842f5d7196
parent 380 fac7090c0ff7
child 402 f8bad6cf5abc
permissions -rw-r--r--
*** empty log message ***
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     1
"*
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     2
 * $Header$
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     3
 *
399
5a842f5d7196 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 380
diff changeset
     4
 * MIMEType: application/x-smalltalk-source
5a842f5d7196 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 380
diff changeset
     5
 *
209
22793de5d56e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 140
diff changeset
     6
 * ST/X startup configuration file:
22793de5d56e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 140
diff changeset
     7
 *
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     8
 * sample keyboard.rc - file
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     9
 *
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    10
 * this file defines some keyboard macros and adds mappings for
54
802aa9185941 commentary
Claus Gittinger <cg@exept.de>
parents: 41
diff changeset
    11
 * common function keys. These definitions used to be in 'private.rc',
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    12
 * but have been extracted into this separate file to allow easier
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    13
 * sharing of rc files (users having different private files, but want
54
802aa9185941 commentary
Claus Gittinger <cg@exept.de>
parents: 41
diff changeset
    14
 * to use the same keyboard mappings / keyboard macros)
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    15
 *
54
802aa9185941 commentary
Claus Gittinger <cg@exept.de>
parents: 41
diff changeset
    16
 * a copy of this file can reside in $home/.smalltalk/keyboard.rc or
802aa9185941 commentary
Claus Gittinger <cg@exept.de>
parents: 41
diff changeset
    17
 * in the current directory.
802aa9185941 commentary
Claus Gittinger <cg@exept.de>
parents: 41
diff changeset
    18
 *
802aa9185941 commentary
Claus Gittinger <cg@exept.de>
parents: 41
diff changeset
    19
 * these are my personal preferrences which may not be
802aa9185941 commentary
Claus Gittinger <cg@exept.de>
parents: 41
diff changeset
    20
 * correct for your environment
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    21
 *"
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    22
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
    23
|macros|
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    24
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    25
"/
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    26
"/ define some keyboard macros as virtual function-keys:
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    27
"/ Cmd-F99: paste the output of a selected unix command ..
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    28
"/ Cmd-F98: toggle between 4 and 8 col tab setting
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    29
"/ Cmd-F96: pipe text through spelling checker and collect its output
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    30
"/ Cmd-F97: get next entry from spell-list, search and highlight it
370
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
    31
"/ Cmd-F95: indents selection-line by 4
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
    32
"/ Cmd-F94: undents selection-line by 4
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    33
"/
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
    34
374
ed55af1bd548 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 370
diff changeset
    35
macros := UserPreferences current functionKeySequences.
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    36
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
    37
"/
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
    38
"/ macro to replace a text selection by unix commands output
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
    39
"/
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
    40
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    41
macros at:#F99 put:'
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    42
	"replace selection by 
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    43
	 corresponding
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    44
	 unix commands output"
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    45
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    46
	|sel|
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    47
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    48
	sel := self selection.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    49
	sel notNil ifTrue:[
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    50
	    self replace:
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    51
		(PipeStream readingFrom:(sel asString))
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    52
		    contents asString
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    53
	]'.
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    54
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
    55
"/
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    56
"/ macro to toggle tabs
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
    57
"/
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    58
macros at:#F98 put:'
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    59
	"toggle between 4-col 
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    60
	 and 8-col tabs"
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    61
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    62
	(tabPositions == self class tab4Positions)
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    63
	     ifTrue:[self setTab8]
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    64
	     ifFalse:[self setTab4]'.
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    65
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
    66
"/
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    67
"/ macro to get next spelling error, and select it
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
    68
"/
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    69
macros at:#F97 put:'
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    70
	|errs thisErr sl sc|
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    71
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    72
	thisErr := Smalltalk at:#''_thisError''.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    73
	thisErr isNil ifTrue:[
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    74
	    errs := Smalltalk at:#''_spellOutput''.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    75
	    (errs notNil and:[errs notEmpty]) ifTrue:[
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    76
		thisErr := errs removeFirst.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    77
		errs isEmpty ifTrue:[Smalltalk removeKey:''_spellOut'']
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    78
	    ].
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    79
	    Smalltalk at:#''_lastErrLine'' put:1.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    80
	    Smalltalk at:#''_lastErrCol'' put:1.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    81
	].
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    82
	thisErr notNil ifTrue:[
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    83
	    sl := Smalltalk at:#''_lastErrLine''.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    84
	    sc := Smalltalk at:#''_lastErrCol''.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    85
	    self searchForwardFor:thisErr
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    86
		 startingAtLine:sl col:sc 
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    87
		 ifFound:[:fl :fc | self selectWordAtLine:fl col:fc.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    88
				    Smalltalk at:#''_lastErrLine'' put:fl.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    89
				    Smalltalk at:#''_lastErrCol'' put:fc+1]
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    90
		 ifAbsent:[self device beep]
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    91
	]'.
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    92
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
    93
"/
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    94
"/ macro to send contents to spell; remember spelling errors
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    95
"/ does not work on all systems (some do not have spell ...)
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
    96
"/
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    97
macros at:#F96 put:'
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    98
	|p f s|
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    99
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   100
	f := Filename newTemporary. s := f writeStream.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   101
	s nextPutAll:self contents asString.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   102
	s close.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   103
	p := PipeStream readingFrom:''spell '' , f pathName.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   104
	Smalltalk at:#''_spellOutput'' put:p contents asString asCollectionOfLines.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   105
	p close.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   106
	self information:''F7 positions on the next spelling error''.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   107
	'.
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   108
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   109
"/
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   110
"/ macro to indent by 4
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   111
"/
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   112
macros at:#F95 put:'
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   113
	"indent selected line-range 
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   114
	 by 4 spaces (i.e. to the right)"
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   115
370
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   116
	|line1 line2|
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   117
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   118
	line1 := self selectionStartLine.
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   119
	line2 := self selectionEndLine.
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   120
	line1 isNil ifTrue:[
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   121
	    line1 := self perform:#cursorLine ifNotUnderstood:nil.
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   122
	    line1 notNil ifTrue:[
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   123
		line2 := line1+1
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   124
	    ]
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   125
	].
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   126
	line1 notNil ifTrue:[    
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   127
	    line1 to:line2-1 do:[:lineNr |
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   128
		|line|
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   129
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   130
		line := self listAt:lineNr.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   131
		line notNil ifTrue:[
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   132
		    line notEmpty ifTrue:[
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   133
			line := ''    '' , line.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   134
			self withoutRedrawAt:lineNr put:line.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   135
			self invalidateLine:lineNr.
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   136
		    ]
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   137
		]
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   138
	    ].
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   139
	]
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   140
	'.
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   141
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   142
"/
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   143
"/ macro to undent by 4
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   144
"/
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   145
macros at:#F94 put:'
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   146
	"undent selected line-range 
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   147
	 by 4 spaces (i.e. to the left)"
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   148
370
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   149
	|line1 line2|
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   150
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   151
	line1 := self selectionStartLine.
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   152
	line2 := self selectionEndLine.
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   153
	line1 isNil ifTrue:[
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   154
	    line1 := self perform:#cursorLine ifNotUnderstood:nil.
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   155
	    line1 notNil ifTrue:[
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   156
		line2 := line1+1
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   157
	    ]
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   158
	].
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   159
	line1 notNil ifTrue:[    
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   160
	    line1 to:line2-1 do:[:lineNr |
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   161
		|line|
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   162
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   163
		line := self listAt:lineNr.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   164
		line notNil ifTrue:[
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   165
		    line notEmpty ifTrue:[
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   166
			(line startsWith:''    '') ifTrue:[
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   167
			    line := line copyFrom:5.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   168
			    self withoutRedrawAt:lineNr put:line.
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   169
			    self invalidateLine:lineNr.
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   170
			]
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   171
		    ]
288
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   172
		]
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   173
	    ].
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   174
	]
ffd914a69270 better indent/undent behavior (delayed redraw)
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
   175
	'.
292
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   176
"/
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   177
"/ macro to indent by 1
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   178
"/
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   179
macros at:#F93 put:'
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   180
	"indent selected line-range 
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   181
	 by 1 space (i.e. to the right)"
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   182
370
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   183
	|line1 line2|
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   184
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   185
	line1 := self selectionStartLine.
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   186
	line2 := self selectionEndLine.
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   187
	line1 isNil ifTrue:[
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   188
	    line1 := self perform:#cursorLine ifNotUnderstood:nil.
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   189
	    line1 notNil ifTrue:[
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   190
		line2 := line1+1
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   191
	    ]
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   192
	].
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   193
	line1 notNil ifTrue:[    
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   194
	    line1 to:line2-1 do:[:lineNr |
292
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   195
		|line|
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   196
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   197
		line := self listAt:lineNr.
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   198
		line notNil ifTrue:[
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   199
		    line notEmpty ifTrue:[
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   200
			line := '' '' , line.
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   201
			self withoutRedrawAt:lineNr put:line.
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   202
			self invalidateLine:lineNr.
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   203
		    ]
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   204
		]
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   205
	    ].
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   206
	]
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   207
	'.
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   208
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   209
"/
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   210
"/ macro to undent by 1
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   211
"/
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   212
macros at:#F92 put:'
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   213
	"undent selected line-range 
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   214
	 by 1 space (i.e. to the left)"
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   215
370
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   216
	|line1 line2|
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   217
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   218
	line1 := self selectionStartLine.
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   219
	line2 := self selectionEndLine.
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   220
	line1 isNil ifTrue:[
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   221
	    line1 := self perform:#cursorLine ifNotUnderstood:nil.
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   222
	    line1 notNil ifTrue:[
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   223
		line2 := line1+1
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   224
	    ]
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   225
	].
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   226
	line1 notNil ifTrue:[    
9aeb341c2dac if no selection, indent/undent the cursorLine
Claus Gittinger <cg@exept.de>
parents: 356
diff changeset
   227
	    line1 to:line2-1 do:[:lineNr |
292
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   228
		|line|
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   229
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   230
		line := self listAt:lineNr.
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   231
		line notNil ifTrue:[
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   232
		    line notEmpty ifTrue:[
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   233
			(line startsWith:'' '') ifTrue:[
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   234
			    line := line copyFrom:2.
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   235
			    self withoutRedrawAt:lineNr put:line.
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   236
			    self invalidateLine:lineNr.
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   237
			]
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   238
		    ]
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   239
		]
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   240
	    ].
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   241
	]
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   242
	'.
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   243
!
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   244
92
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   245
"*
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   246
 * key bindings common to all display types
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   247
 * use event monitor, to see what the Xserver sends us;
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   248
 * put display-specific stuff into a d_hostName.rc file.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   249
 *"
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   250
|map|
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   251
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   252
map := Display keyboardMap.
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   253
252
5d4a68556e45 ESC & Compose keys on DEC keyboards
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
   254
(Display serverVendor startsWith:'DECWINDOWS') ifTrue:[
5d4a68556e45 ESC & Compose keys on DEC keyboards
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
   255
    "/ DEC has messed up the ESC key completely.
5d4a68556e45 ESC & Compose keys on DEC keyboards
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
   256
    "/ map ALT-` onto ESC for our convenience.
5d4a68556e45 ESC & Compose keys on DEC keyboards
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
   257
    "/
5d4a68556e45 ESC & Compose keys on DEC keyboards
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
   258
    "/ also, the right compose key (comes in as 'AltMulti_key' or
5d4a68556e45 ESC & Compose keys on DEC keyboards
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
   259
    "/ 'CtrlMulti_key' depending on the keyboard) is mapped
5d4a68556e45 ESC & Compose keys on DEC keyboards
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
   260
    "/ to 'Compose'.
5d4a68556e45 ESC & Compose keys on DEC keyboards
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
   261
    map bindValue:#Escape  to:#'Cmd`'.
5d4a68556e45 ESC & Compose keys on DEC keyboards
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
   262
    map bindValue:#Compose to:#'AltMulti_key'.    "/ the right compose key
5d4a68556e45 ESC & Compose keys on DEC keyboards
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
   263
5d4a68556e45 ESC & Compose keys on DEC keyboards
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
   264
    map bindValue:#Return  to:#'KP_Enter'.        "/ the keypads return key
5d4a68556e45 ESC & Compose keys on DEC keyboards
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
   265
].  
5d4a68556e45 ESC & Compose keys on DEC keyboards
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
   266
299
2dbaa24f1a70 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 292
diff changeset
   267
map bindValue:#'Alt'  to:#'Super_L'.  
2dbaa24f1a70 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 292
diff changeset
   268
map bindValue:#'Alt'  to:#'Hyper_R'.  
2dbaa24f1a70 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 292
diff changeset
   269
92
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   270
map bindValue:#UserInterrupt  to:#Ctrlc.    "interrupt window process"
290
611e11479999 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 288
diff changeset
   271
map bindValue:#UserAbort      to:#Ctrly.    "abort window process, but no debugger"
92
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   272
map bindValue:#FlushInput     to:#CtrlX.    "flush typeahead input"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   273
map bindValue:#DestroyView    to:#CmdCtrlX. "to destroy dead views"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   274
map bindValue:#DestroyTopView to:#CmdCtrlx. "to destroy dead views"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   275
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   276
map bindValue:#DoIt       to:#Cmdd.         "i.e. Cmd-d / Alt-d (sometimes Meta-d)"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   277
map bindValue:#InspectIt  to:#Cmdi.         "evaluate & inspect result"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   278
map bindValue:#PrintIt    to:#Cmdp.         "evaluate and paste result"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   279
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   280
map bindValue:#Copy       to:#Cmdc.         "copy selection to buffer"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   281
map bindValue:#Cut        to:#Cmdx.         "cut selection into buffer"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   282
map bindValue:#Paste      to:#Cmdv.         "paste buffer or external selection"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   283
map bindValue:#Replace    to:#Cmdr.         "same as paste"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   284
map bindValue:#Find       to:#Cmds.         "open searchbox"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   285
map bindValue:#FindNext   to:#Cmdf.         "search fwd for last searchpattern or selection"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   286
map bindValue:#FindPrev   to:#Cmdb.         "search bwd for last searchpattern or selection"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   287
map bindValue:#SelectAll  to:#CmdA.         "that is Alt-shift-a"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   288
map bindValue:#GotoLine   to:#Cmdg.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   289
map bindValue:#SelectWord to:#Cmdw.         "select word under cursor"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   290
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   291
map bindValue:#Accept     to:#Cmda.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   292
map bindValue:#Explain    to:#Cmde.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   293
map bindValue:#Explain    to:#Cmdh.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   294
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   295
map bindValue:#DeleteLine to:#Ctrlx.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   296
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   297
map bindValue:#NextPage     to:#Next.    "typically labelled PageDown on keyboard"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   298
map bindValue:#PreviousPage to:#Prior.   "typically labelled PageUp on keyboard"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   299
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   300
map bindValue:#PreviousPage to:#Ctrlb.   "vi behavior"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   301
map bindValue:#NextPage     to:#Ctrlf.   "vi behavior"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   302
map bindValue:#HalfPageUp   to:#Ctrlu.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   303
map bindValue:#HalfPageDown to:#Ctrld.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   304
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   305
map bindValue:#BeginOfText  to:#Home.    "some prefer to bind #BeginOfLine to #Home"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   306
map bindValue:#EndOfText    to:#End.     "some prefer to bind #EndOfLine to #End"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   307
map bindValue:#BeginOfLine  to:#Ctrla.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   308
map bindValue:#EndOfLine    to:#Ctrle.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   309
map bindValue:#NextWord     to:#Ctrlw.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   310
map bindValue:#NextWord     to:#CtrlCursorRight.  
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   311
map bindValue:#PreviousWord to:#CtrlCursorLeft.  
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   312
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   313
map bindValue:#ScrollUp     to:#CtrlCursorUp.    
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   314
map bindValue:#ScrollDown   to:#CtrlCursorDown.    
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   315
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   316
map bindValue:#SearchMatchingParent  to:#Ctrlm.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   317
map bindValue:#SelectMatchingParents to:#Cmdm.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   318
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   319
map bindValue:#SelectToEnd           to:#CtrlE.   "that is ctrl-shift-e"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   320
map bindValue:#SelectFromBeginning   to:#CtrlA.   "that is ctrl-shift-a"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   321
map bindValue:#ExpandSelectionByLine to:#Ctrll.   "try multiple Ctrl-l's ..."
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   322
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   323
"Notice:
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   324
  Cmd-CursorLeft/Right and Alt-CursorLeft/Right
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   325
  are also used by some winmdowmanagers (fvwm)
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   326
  if this is the case on your system, either
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   327
  change the following to use different keys,
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   328
  or change the windowmanagers configuration file
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   329
  (usr/lib/X11/xxxwm/*rc).
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   330
  The above is the reason that the following defines Ctrl-xxx
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   331
  as an alternative (mwm in the INDY also uses the alt-sequences)
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   332
"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   333
map bindValue:#FocusNext     to:#CmdCursorRight.   "experimental"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   334
map bindValue:#FocusPrevious to:#CmdCursorLeft.    "experimental"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   335
map bindValue:#FocusNext     to:#AltCursorRight.   "experimental"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   336
map bindValue:#FocusPrevious to:#AltCursorLeft.    "experimental"
255
ccb6df643f77 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 252
diff changeset
   337
map bindValue:#FocusNext     to:#AltCursorDown.    "experimental"
ccb6df643f77 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 252
diff changeset
   338
map bindValue:#FocusPrevious to:#AltCursorUp.      "experimental"
92
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   339
"/ map bindValue:#FocusNext     to:#CtrlCursorRight.  "experimental"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   340
"/ map bindValue:#FocusPrevious to:#CtrlCursorLeft.   "experimental"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   341
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   342
map bindValue:#FocusNext     to:#CtrlTab.          "experimental"
138
499198c9e957 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 122
diff changeset
   343
map bindValue:#FocusNext     to:#CmdTab.           "experimental"
92
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   344
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   345
map bindValue:#Menu          to:#Cmdz.             
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   346
122
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   347
"*
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   348
 * ISO LATIN 1 symbolic characters - map to iso8859 values
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   349
 * not all Xservers send those correctly.
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   350
 * As a fall back, dieresis mappings using Alt-key sequences are found at
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   351
 * the end.
92
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   352
 *"
122
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   353
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   354
#(
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   355
	"/ dieresis characters
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   356
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   357
	Udiaeresis      16rDC
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   358
	Adiaeresis      16rC4
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   359
	Odiaeresis      16rD6
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   360
	udiaeresis      16rFC
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   361
	adiaeresis      16rE4
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   362
	odiaeresis      16rF6
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   363
	ydiaeresis      16rFF
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   364
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   365
	"/ grave
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   366
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   367
	Agrave          16rC0
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   368
	Egrave          16rC8
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   369
	Igrave          16rCC
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   370
	Ograve          16rCC
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   371
	Ugrave          16rD9
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   372
	agrave          16rE0
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   373
	egrave          16rE8
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   374
	igrave          16rEC
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   375
	ograve          16rF2
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   376
	ugrave          16rF9
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   377
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   378
	"/ acute
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   379
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   380
	Aacute          16rC1
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   381
	Eacute          16rC9
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   382
	Iacute          16rCD
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   383
	Oacute          16rD3
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   384
	Uacute          16rDA
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   385
	Yacute          16rDD
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   386
	aacute          16rE1
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   387
	eacute          16rE9
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   388
	iacute          16rED
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   389
	oacute          16rF3
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   390
	uacute          16rFA
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   391
	yacute          16rFD
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   392
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   393
	"/ circumflex
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   394
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   395
	Acircumflex     16rC2
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   396
	Ecircumflex     16rCA 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   397
	Icircumflex     16rCE 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   398
	Ocircumflex     16rD4 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   399
	Ucircumflex     16rDB 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   400
	acircumflex     16rE2 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   401
	ecircumflex     16rEA 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   402
	icircumflex     16rEE 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   403
	ocircumflex     16rF4 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   404
	ucircumflex     16rFB 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   405
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   406
	"/ tilde
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   407
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   408
	Atilde          16rC3 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   409
	Ntilde          16rD1 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   410
	atilde          16rE3 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   411
	ntilde          16rF1 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   412
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   413
	"/ ring
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   414
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   415
	Aring           16rC4 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   416
	aring           16rE4 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   417
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   418
	"/ ligatures
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   419
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   420
	AE              16rC5 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   421
	ae              16rE5 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   422
	ssharp          16rDF
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   423
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   424
	"/ cedilla
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   425
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   426
	Ccedilla        16rC7 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   427
	ccedilla        16rE7 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   428
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   429
	"/ slashed
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   430
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   431
	Ooblique        16rD8 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   432
	oslash          16rF8 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   433
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   434
	"/ misc (if on your keyboard)
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   435
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   436
	Eth             16rD0     "/ some old servers still use this
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   437
	ETH             16rD0 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   438
	eth             16rF0 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   439
	multiply        16rD7 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   440
	Thorn           16rDE   "/ some old servers still use this
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   441
	THORN           16rDE   "/ some old servers still use this
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   442
	division        16rF7 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   443
	thorn           16rFE 
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   444
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   445
	section         16rA7
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   446
	degree          16rB0
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   447
	twosuperior     16rB2
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   448
	threesuperior   16rB3
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   449
	mu              16rB5
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   450
) pairWiseDo:[:symbolic :numeric |
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   451
	map bindValue:(Character value:numeric) to:symbolic.
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   452
].
92
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   453
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   454
"*
122
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   455
 * need more here (katakana, arabic, cyrillic, greek etc.)
92
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   456
 *"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   457
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   458
"*
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   459
 * numeric keypad - binding to normal numeric keys
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   460
 *"
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   461
"/ map bindValue:$0 to:#'KP_Insert'.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   462
"/ map bindValue:$1 to:#'KP_End'.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   463
"/ map bindValue:$2 to:#'KP_Down'.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   464
"/ map bindValue:$3 to:#'KP_Next'.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   465
"/ map bindValue:$4 to:#'KP_Left'.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   466
"/ map bindValue:$5 to:#'KP_Begin'.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   467
"/ map bindValue:$6 to:#'KP_Right'.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   468
"/ map bindValue:$7 to:#'KP_Home'.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   469
"/ map bindValue:$8 to:#'KP_Up'.
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   470
"/ map bindValue:$9 to:#'KP_Prior'.
380
fac7090c0ff7 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 374
diff changeset
   471
map bindValue:#Return to:#'KP_Enter'.
fac7090c0ff7 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 374
diff changeset
   472
map bindValue:#Delete to:#'KP_Delete'.
92
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   473
dd4108239142 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 89
diff changeset
   474
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   475
"/ remove these lines, if your keyboard has a COMPOSE-key.
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   476
"/ None of our Xdisplays here has one - so we simulate it using CTRL-R ...
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   477
"/ which on some (of our) servers comes pretranslated as Multi_key, 
327
df575037165e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 299
diff changeset
   478
"/ CtrlMulti_key or even Mode_switch.
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   479
327
df575037165e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 299
diff changeset
   480
map bindValue:#Compose     to:#'Control_R'.       "/ the right compose key
df575037165e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 299
diff changeset
   481
map bindValue:#Compose     to:#'Multi_key'.       "/ the right compose key
df575037165e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 299
diff changeset
   482
map bindValue:#Compose     to:#'CtrlMulti_key'.   "/ the right compose key
140
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   483
"/ map bindValue:#Compose     to:#'Mode_switch'.     
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   484
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   485
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   486
"/ a kludge: some Xservers send #Delete for both the backspace
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   487
"/ and the Delete key. In this case, we use the Backspace function
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   488
"/ for both keys. If your Xserver does not do this (it should not)
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   489
"/ remove or comment the following 'bindValue:#BackSpace'-line:
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   490
"/
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   491
356
4275f251cb37 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 347
diff changeset
   492
"/ map bindValue:#BackSpace     to:#Delete.
86
7cb0bbfd6431 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 76
diff changeset
   493
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   494
"/
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   495
"/ my personal preferences - comment it, if you do not like them
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   496
"/ bind function and other keys as:
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   497
"/
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   498
"/ F1            - again
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   499
"/ F3            - comment-it
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   500
"/ F4            - uncomment-it
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   501
"/ F5            - paste shell output
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   502
"/ F9            - undent by 4
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   503
"/ F10           - indent by 4
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   504
"/ Control-R     - Compose key
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   505
"/ Break         - UserInterrupt
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   506
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   507
"/
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   508
"/ convenient functions on the keyboard
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   509
"/
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   510
map bindValue:#Again         to:#F1.
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   511
map bindValue:#UserInterrupt to:#Break.
89
fffab00793be *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 88
diff changeset
   512
"/ map bindValue:#PrintIt       to:#Print.      "/ called PrintScreen on most keyboards
fffab00793be *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 88
diff changeset
   513
"/ map bindValue:#InspectIt     to:#Execute.    "/ called SysReq on most keyboards
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   514
88
95380a1bf862 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   515
map bindValue:#SaveAs        to:#CmdS.
95380a1bf862 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   516
347
7139555dbd69 comment
Claus Gittinger <cg@exept.de>
parents: 327
diff changeset
   517
"/ F5      -> macroF99 (unix command output paste)
292
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   518
"/ CtrlTab -> macroF98 (toggle 4/8 tabs)
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   519
"/ F10     -> macroF95 (indent by 4)
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   520
"/ F9      -> macroF94 (undent by 4)
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   521
"/ F12     -> macroF93 (indent by 1)
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   522
"/ F11     -> macroF92 (undent by 1)
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   523
"/ F3      -> commentSelection
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   524
"/ F4      -> uncommentSelection
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   525
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   526
map bindValue:#CmdF99  to:#F5.
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   527
map bindValue:#CmdF98 to:#CtrlTab.
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   528
"/ map bindValue:#CmdF97 to:#F7.
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   529
"/ map bindValue:#CmdF96 to:#F6.
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   530
map bindValue:#CmdF95 to:#F10.
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   531
map bindValue:#CmdF94 to:#F9.
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   532
292
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   533
map bindValue:#CmdF93 to:#F12.
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   534
map bindValue:#CmdF92 to:#F11.
aab8f8feb824 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 290
diff changeset
   535
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   536
map bindValue:#CommentSelection to:#F3.
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   537
map bindValue:#UncommentSelection to:#F4.
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   538
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   539
"/
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   540
"/ since some of my machines have german keyboards ;-)
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   541
"/ and I like to be able to edit my files on all machines,
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   542
"/ I need a translation in both ways.
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   543
"/ you'd normally not define things in both directions.
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   544
"/
57
3e06b2840c9f structure & commentary
Claus Gittinger <cg@exept.de>
parents: 54
diff changeset
   545
"/ actually, these things belong into the servers modmap or 
3e06b2840c9f structure & commentary
Claus Gittinger <cg@exept.de>
parents: 54
diff changeset
   546
"/ into a display specific d_<displayName>.rc ...
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   547
"/
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   548
"/ german national characters on a US keyboard:
140
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   549
"/ comment this, if you have a german keyboard.
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   550
"/
140
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   551
"/map bindValue:(Character value:16rFC) to:#'Cmd['.   "/ u dieresis
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   552
"/map bindValue:(Character value:16rE4) to:#'Cmd'''.  "/ a dieresis
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   553
"/map bindValue:(Character value:16rF6) to:#'Cmd;'.   "/ o dieresis
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   554
"/map bindValue:(Character value:16rDC) to:#'Cmd{'.   "/ U dieresis
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   555
"/map bindValue:(Character value:16rC4) to:#'Cmd"'.   "/ A dieresis
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   556
"/map bindValue:(Character value:16rD6) to:#'Cmd:'.   "/ O dieresis
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   557
"/map bindValue:(Character value:16rDF) to:#'Cmd-'.   "/ s-sharp
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   558
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   559
"/
122
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   560
"/ US characters on national keyboards:
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   561
"/ (on many national keyboards, the x-server does NOT correctly
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   562
"/  xlate characters .... on others, it does and you may remove/comment
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   563
"/  the following.)
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   564
"/
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   565
map bindValue:$[ to:#'Alt['.
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   566
map bindValue:$] to:#'Alt]'.
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   567
map bindValue:$| to:#'Alt|'.
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   568
map bindValue:${ to:#'Alt{'.
57
3e06b2840c9f structure & commentary
Claus Gittinger <cg@exept.de>
parents: 54
diff changeset
   569
map bindValue:$} to:#'Alt}'.
122
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   570
map bindValue:$\ to:#'Alt\'.
140
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   571
map bindValue:$~ to:#'Alt~'.
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   572
map bindValue:$@ to:#'Alt@'.
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   573
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   574
map bindValue:$[ to:#'Cmd['.      
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   575
map bindValue:$] to:#'Cmd]'.
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   576
map bindValue:$| to:#'Cmd|'.
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   577
map bindValue:${ to:#'Cmd{'.
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   578
map bindValue:$} to:#'Cmd}'.
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   579
map bindValue:$\ to:#'Cmd\'.
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   580
map bindValue:$~ to:#'Cmd~'.
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   581
map bindValue:$@ to:#'Cmd@'.
30920131031d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 138
diff changeset
   582
122
6b06631a4bb0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 92
diff changeset
   583
41
d61cda45c461 separated keyboard macros
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   584
!