The Trunk: Multilingual-nice.128.mcz

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

The Trunk: Multilingual-nice.128.mcz

commits-2
Nicolas Cellier uploaded a new version of Multilingual to project The Trunk:
http://source.squeak.org/trunk/Multilingual-nice.128.mcz

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

Name: Multilingual-nice.128
Author: nice
Time: 2 October 2010, 12:44:31.144 am
UUID: 147821da-4ab2-4b33-a647-b2c1215ba7ec
Ancestors: Multilingual-ar.127

Use #postCopy.
Change the instVar rIndex -> tempVar in StrikeFontSet.
Why did this variable ever became an instance one ?

=============== Diff against Multilingual-ar.127 ===============

Item was changed:
  AbstractFont subclass: #StrikeFontSet
+ instanceVariableNames: 'fontArray emphasis derivativeFonts name'
- instanceVariableNames: 'fontArray emphasis derivativeFonts name rIndex'
  classVariableNames: ''
  poolDictionaries: ''
  category: 'Multilingual-Display'!

Item was removed:
- ----- Method: StrikeFontSet>>copy (in category 'copying') -----
- copy
-
- | s a |
- s := self class new.
- s name: self name.
- s emphasis: self emphasis.
- s reset.
- a := Array new: fontArray size.
- 1 to: a size do: [:i |
- a at: i put: (fontArray at: i) copy.
- ].
- s fontArray: a.
- ^ s.
- !

Item was changed:
  ----- Method: StrikeFontSet>>displayString:on:from:to:at:kern:from:baselineY: (in category 'displaying') -----
  displayString: aString on: aBitBlt from: startIndex to: stopIndex at: aPoint kern: kernDelta from: fromFont baselineY: baselineY
 
+ | destPoint leftX rightX glyphInfo g tag char destY rIndex |
- | destPoint leftX rightX glyphInfo g tag char destY |
  destPoint := aPoint.
  rIndex := startIndex.
  tag := (aString at: rIndex) leadingChar.
  glyphInfo := Array new: 5.
  [rIndex <= stopIndex] whileTrue: [
  char := aString at: rIndex.
  ((fromFont hasGlyphOf: char) or: [char leadingChar ~= tag]) ifTrue: [^destPoint].
  self glyphInfoOf: char into: glyphInfo.
  g := glyphInfo first.
  leftX := glyphInfo second.
  rightX := glyphInfo third.
  (glyphInfo fifth ~= aBitBlt lastFont) ifTrue: [
  glyphInfo fifth installOn: aBitBlt.
  ].
  destY := baselineY - glyphInfo fourth.
  aBitBlt
  sourceForm: g;
  destX: destPoint x;
  destY: destY;
  sourceOrigin: leftX @ 0;
  width: rightX - leftX;
  height: self height;
  copyBits.
  destPoint := destPoint x + (rightX - leftX + kernDelta) @ destPoint y.
  rIndex := rIndex + 1.
  ].
  ^destPoint.
  !

Item was added:
+ ----- Method: StrikeFontSet>>postCopy (in category 'copying') -----
+ postCopy
+ super postCopy.
+ self reset.
+ fontArray := fontArray copy
+ !