[squeak-dev] The Trunk: Morphic-mt.1238.mcz

commits at source.squeak.org commits at source.squeak.org
Sat Aug 6 07:29:44 UTC 2016


Marcel Taeumel uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-mt.1238.mcz

==================== Summary ====================

Name: Morphic-mt.1238
Author: mt
Time: 6 August 2016, 9:29:03.062437 am
UUID: f2447b81-24f0-fa4b-bb72-557b1ae594d3
Ancestors: Morphic-mt.1237

Fixes a regression in "query symbol" autocompletion in text fields, triggered via CMD+Q. It now also cycles through all symbols including message categories again. There will be spaces inserted for messages just like in Squeak 5.0. Still, the text cursor will always remain at the end of the completed symbol due to the mechanis of the text editor command history. Undoing after cycling through many suggestions will revert to the initial input.

=============== Diff against Morphic-mt.1237 ===============

Item was changed:
  ----- Method: TextEditor>>querySymbol: (in category 'typing/selecting keys') -----
  querySymbol: aKeyboardEvent
  	"Invoked by Ctrl-q to query the Symbol table and display alternate symbols."
  
  	| hintText lastOffering offering |
  	self isTypingIn
  		ifFalse: [
  			self selectPrecedingIdentifier.
  			hintText := self selection string]
  		ifTrue: [
  			self history current type = #query
  				ifFalse: [
  					self closeTypeIn.
  					self selectPrecedingIdentifier.
  					hintText := self selection string]
  				ifTrue: [		
  					self history hasPrevious
  						ifFalse: [morph flash. self closeTypeIn. ^ true].
- 					
  					hintText := self history previous contentsAfter string.
  					hintText := hintText copyFrom: (hintText
  						lastIndexOfAnyOf: Character separators, '#'
  						startingAt: hintText size ifAbsent: [0])+1 to: hintText size.
+ 					self selectInvisiblyFrom: self history current intervalBefore first to: self stopIndex-1.
+ 					lastOffering := self selection string.
+ 					lastOffering := (lastOffering copyReplaceAll: ':  ' with: ':') withBlanksTrimmed.]].
+ 		
+ 	offering := (Symbol thatStarts: hintText skipping: lastOffering) ifNil: [hintText].
+ 	offering := offering copyReplaceAll: ':' with: ':  '.
+ 	offering last = Character space ifTrue: [offering := offering allButLast].
- 					
- 					self selectPrecedingIdentifier.
- 					lastOffering := self selection string]].
  	
- 	offering := '-'.
- 	[offering allSatisfy: [:ea | ea tokenish]] whileFalse: [
- 		offering := (Symbol thatStarts: hintText skipping: lastOffering) ifNil: [hintText].
- 		lastOffering := offering].
- 
  	self openTypeInFor: #query.
  	self typeAhead nextPutAll: offering.
  
  	^ false!



More information about the Squeak-dev mailing list