Marcel Taeumel uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-ct.1772.mcz
==================== Summary ====================
Name: Morphic-ct.1772
Author: ct
Time: 11 June 2021, 2:25:02.644041 pm
UUID: d496a0b4-aea8-4543-bb83-5b539cc4dafd
Ancestors: Morphic-mt.1771
Fixes automatic scrolling in multi-column list morphs when the selection is changed.
You can try this out by doing
SoundLibraryTool new openInWorld setExtentFromHalo: 100 asPoint
and using your arrow/Home/End keys to navigate in the sound list.
Reasoning: As per the invariant defined in #setListParameters, listMorphs always includes listMorph. Subsequently, every super send in #selectionIndex: would be without effect because #selectionIndex already has been updated in the child class. Since selection highlighting is also not relevant for multi-column list morphs (this hook is only used by SimpleHierarchicalListMorph), we can refuse this bequest but send #scrollSelectionIntoView manually.
=============== Diff against Morphic-mt.1771 ===============
Item was changed:
----- Method: PluggableMultiColumnListMorph>>selectionIndex: (in category 'selection') -----
selectionIndex: viewIndex
listMorphs do: [:listMorph | listMorph selectedRow: (viewIndex min: self listSize)].
+
+ self scrollSelectionIntoView.!
- super selectionIndex: viewIndex.!
Marcel Taeumel uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-mt.1771.mcz
==================== Summary ====================
Name: Morphic-mt.1771
Author: mt
Time: 11 June 2021, 8:56:28.364233 am
UUID: 0708f93f-e82a-5c4a-bf37-3a0ef7a58587
Ancestors: Morphic-mt.1770
When accessing a text selection, avoid extra check for removal of oblivious text attributes to make those usable outside the context of #interactivePrintIt. Approximate slow-down is still about 2 orders of magnitude away from being noticed during user interactions (e.g. cut, copy). So, we are fine here. Empty selections (i.e. the normal blinking text cursor) are still very fast.
=============== Diff against Morphic-mt.1770 ===============
Item was changed:
----- Method: TextEditor>>selection (in category 'accessing-selection') -----
selection
"Answer the text in the paragraph that is currently selected."
| result |
result := paragraph text copyFrom: self startIndex to: self stopIndex - 1.
+ result ifNotEmpty: [
- self class interactivePrintIt ifTrue: [
result removeAttributesThat: [:attr | attr isOblivious]].
^ result!