The Trunk: Morphic-cao.522.mcz

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

The Trunk: Morphic-cao.522.mcz

commits-2
Levente Uzonyi uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-cao.522.mcz

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

Name: Morphic-cao.522
Author: cao
Time: 28 February 2011, 6:22:34.55 pm
UUID: 4be5ac71-d5df-4e96-b59c-5065ad7932f9
Ancestors: Morphic-mtf.521

StringMorph>>contents: shouldn't mutate fonts in the
test attributes.

=============== Diff against Morphic-mtf.521 ===============

Item was changed:
  ----- Method: StringMorph>>contents: (in category 'accessing') -----
  contents: newContents
  | scanner |
  contents := newContents isText
  ifTrue: [scanner := StringMorphAttributeScanner new initializeFromStringMorph: self.
  (newContents attributesAt: 1 forStyle: self font textStyle)
  do: [:attr | attr emphasizeScanner: scanner].
  emphasis := scanner emphasis.
+ font := scanner font.
- font := scanner font emphasis: emphasis.
  color := scanner textColor.
  newContents string]
  ifFalse: [contents = newContents
  ifTrue: [^ self].
  "no substantive change"
  newContents].
  self fitContents!