The Trunk: Collections-mt.671.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: Collections-mt.671.mcz

commits-2
Marcel Taeumel uploaded a new version of Collections to project The Trunk:
http://source.squeak.org/trunk/Collections-mt.671.mcz

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

Name: Collections-mt.671
Author: mt
Time: 12 November 2015, 10:14:25.954 am
UUID: 54b6a544-b195-4ee2-90d6-6c70d89fdcfb
Ancestors: Collections-mt.670

Just like #emphasisAt: tolerate null-texts when accessing color information.

=============== Diff against Collections-mt.670 ===============

Item was changed:
  ----- Method: Text>>colorAt:ifNone: (in category 'emphasis') -----
  colorAt: characterIndex ifNone: block
 
+ self size = 0 ifTrue: [^ block value]. "null text tolerates access."
+
  ^ (runs at: characterIndex)
  detect: [:attr | attr class == TextColor]
  ifFound: [:attr | attr color]
  ifNone: block!