Marcel Taeumel uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-mt.1115.mcz
==================== Summary ====================
Name: System-mt.1115
Author: mt
Time: 11 October 2019, 6:31:06.485593 pm
UUID: 414c0966-8964-aa49-9eb0-a44dd2542d3e
Ancestors: System-mt.1114
Simplify feature-based class search. For example, given the term "LazyMor", find both LazyListMorph and MulticolumnLazyListMorph.
=============== Diff against System-mt.1114 ===============
Item was changed:
----- Method: SystemNavigation>>allClassesAndTraitsMatching: (in category 'query') -----
allClassesAndTraitsMatching: pattern
"Given a pattern and an environment, try to find a class or trait using several strategies:
- EXACT: If there is a class or trait whose name exactly given by pattern, return it.
- UPPER: If the pattern is upper-case only, find camel-case letters with that sequence.
- WILD: Try the pattern as-is for regular wild-card search.
- FEATURE: Split patterns at feature boundaries and insert wild cards between.
- FUZZY: Split patterns at feature boundaries BUT treat each feature as a full class name.
If there is only one class or trait in the given environment whose name matches pattern, return it. Otherwise, put up a menu offering the names of all classes that match pattern, and return the class chosen, else nil if nothing chosen.
!!!! In any case, separator characters in the pattern are ignored."
| toMatch potentialNames names |
"If there's a class or trait named as pattern, then return it."
(environment classOrTraitNamed: pattern) ifNotNil: [:classOrTrait | ^ {classOrTrait}].
"Validate pattern."
toMatch := pattern copyWithoutAll: Character separators.
toMatch := toMatch asLowercase copyWithout: $..
toMatch ifEmpty: [ ^ #() ].
"Fetch search space."
names := OrderedCollection new.
potentialNames := environment classAndTraitNames.
"Try uppercase-only patterns for patterns such as 'WKD' to find 'WeakIdentityKeyDictionary' etc."
(pattern allSatisfy: [:char | char isUppercase]) ifTrue: [
| patternSize |
patternSize := pattern size.
potentialNames do: [ :eachName |
| lookupIndex characterIndex |
lookupIndex := 0.
characterIndex := 1.
[ (lookupIndex := eachName
indexOf: (pattern at: characterIndex)
startingAt: lookupIndex + 1) > 0
and: [ (characterIndex := characterIndex + 1) <= patternSize ] ] whileTrue.
lookupIndex > 0 ifTrue: [ names add: eachName ] ] ].
"Try wildcard search for patterns such as 'Weak*Dict*' to find 'WeakIdentityKeyDictionary' etc."
names ifEmpty: [
potentialNames do: [ :each | (toMatch match: each) ifTrue: [ names add: each ] ].
"Try feature-based search for patterns such as 'WeakDict' to find 'WeakIdentityKeyDictionary' etc."
names ifEmpty: [
+ "Insert wildcards before, between, and after features."
+ toMatch := '*', ((pattern copyWithoutAll: '.*#') findFeatures joinSeparatedBy: '*'), '*'.
+ potentialNames do: [ :each | (toMatch match: each) ifTrue: [ names add: each ] ] ] ].
- "1) Insert wildcards between features and at the end."
- toMatch := ((pattern copyWithoutAll: '.*#') findFeatures joinSeparatedBy: '*'), '*'.
- potentialNames do: [ :each | (toMatch match: each) ifTrue: [ names add: each ] ].
- names ifEmpty: [
- "2) Insert wildcards before, between, and after features."
- toMatch := '*', toMatch.
- potentialNames do: [ :each | (toMatch match: each) ifTrue: [ names add: each ] ] ] ] ].
"Try some fuzzy matching."
pattern suggestedTypeNames do: [ :each |
(potentialNames includes: each) ifTrue: [ names add: each ] ].
"Still no match?"
^ names collect: [ :each | environment classOrTraitNamed: each ]
!
Marcel Taeumel uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-mt.1567.mcz
==================== Summary ====================
Name: Morphic-mt.1567
Author: mt
Time: 11 October 2019, 6:20:59.472593 pm
UUID: 8582d273-b6a7-554a-a5c3-c07c48e5ec3f
Ancestors: Morphic-eem.1566
Fixes the drawing of multi-selection in the alternate-pluggable-list-morph-of-many.
=============== Diff against Morphic-eem.1566 ===============
Item was added:
+ ----- Method: AlternatePluggableListMorphOfMany>>hasMultiSelection (in category 'testing') -----
+ hasMultiSelection
+
+ ^ true!
Eliot Miranda uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-eem.1566.mcz
==================== Summary ====================
Name: Morphic-eem.1566
Author: eem
Time: 10 October 2019, 4:50:30.630581 pm
UUID: f0bc343e-b0ae-492d-a951-6115ab5b834f
Ancestors: Morphic-mt.1565
Fix an MNU in attempting to style the cointents of a Transcript.
=============== Diff against Morphic-mt.1565 ===============
Item was added:
+ ----- Method: PluggableTextMorph>>styler (in category 'accessing') -----
+ styler
+ "The styler responsible for highlighting text in the receiver.
+ Instances of PluggableTextMorph don;t have one."
+ ^nil!