'From Squeak5.3 of 8 February 2022 [latest update: #19471] on 25 February 2022 at 8:08:37 am'!!SmalltalkEditor methodsFor: 'as yet unclassified' stamp: 'marc 2/25/2022 07:38'!emacsFile	^ '/tmp/emacs-squeak.st'! !!SmalltalkEditor methodsFor: 'as yet unclassified' stamp: 'ms 2/24/2022 22:08'!emacsIn	|f|	f := StandardFileStream oldFileNamed: self emacsFile.	self afterSelectionInsertAndSelect: f contents.	Transcript show: '# emacsIn: '; show: self emacsFile; cr.! !!SmalltalkEditor methodsFor: 'as yet unclassified' stamp: 'ms 2/24/2022 21:57'!emacsIn: aKeyboardEvent	self emacsIn.	^ true! !!SmalltalkEditor methodsFor: 'as yet unclassified' stamp: 'ms 2/24/2022 22:08'!emacsOut	|f|	f := StandardFileStream fileNamed: self emacsFile.	f truncate.	f << self selection.	f close.	Transcript show: '# emacsOut: '; show: self emacsFile; cr.! !!SmalltalkEditor methodsFor: 'as yet unclassified' stamp: 'ms 2/24/2022 21:58'!emacsOut: aKeyboardEvent	self emacsOut.	^ true! !!SmalltalkEditor class methodsFor: 'keyboard shortcut tables' stamp: 'ms 2/24/2022 21:57'!initializeCmdKeyShortcuts	"Initialize the (unshifted) command-key (or alt-key) shortcut table."	"NOTE: if you don't know what your keyboard generates, use Sensor kbdTest"	"SmalltalkEditor initialize"	| cmds |	super initializeCmdKeyShortcuts.	cmds := #($b #browseIt: $d #doIt: $e #emacsIn: $i #inspectIt: $l #cancel: $m #implementorsOfIt: $n #sendersOfIt: $o #spawnIt: $p #printIt: $q #querySymbol: $s #save: ).	1 to: cmds size		by: 2		do: [ : i | cmdActions at: (cmds at: i) asciiValue + 1 put: (cmds at: i + 1)].	"Set up type-method argument hot keys, 1-4.."	'1234' do:		[ : eachKeyboardChar |		cmdActions 			at: eachKeyboardChar asciiValue + 1			put: #typeMethodArgument: ]! !!SmalltalkEditor class methodsFor: 'keyboard shortcut tables' stamp: 'ms 2/24/2022 21:58'!initializeShiftCmdKeyShortcuts 	"Initialize the shift-command-key (or control-key) shortcut table."	"NOTE: if you don't know what your keyboard generates, use Sensor kbdTest"	| cmds |	super initializeShiftCmdKeyShortcuts.	cmds := #(		$a	argAdvance:		$b	browseItHere:		$d	debugIt:		"$e	methodStringsContainingIt:"		$e  emacsOut:		$f	displayIfFalse:		$g	fileItIn:		$i	exploreIt:		$n	referencesToIt:		$s	invokePrettyPrint:		$t	displayIfTrue:		$v	pasteInitials:		$w	methodNamesContainingIt:	).	1 to: cmds size by: 2 do: [ :i |		shiftCmdActions at: ((cmds at: i) asciiValue + 1) put: (cmds at: i + 1).			"plain keys"		shiftCmdActions at: ((cmds at: i) asciiValue - 32 + 1) put: (cmds at: i + 1).		"shifted keys"		shiftCmdActions at: ((cmds at: i) asciiValue - 96 + 1) put: (cmds at: i + 1).		"ctrl keys"	].	"shift+cmd _ (underscore)"	shiftCmdActions at: $_ asciiValue+1 put: #flattenSelection:! !