The Trunk: Morphic-topa.773.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-topa.773.mcz

commits-2
Tobias Pape uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-topa.773.mcz

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

Name: Morphic-topa.773
Author: topa
Time: 6 March 2015, 10:49:31.196 pm
UUID: b8eb96f3-4b2f-4899-9069-2dacb1a8be92
Ancestors: Morphic-mt.772

Adapt ColorMappingCanvas and children to also map fill styles.
Rounded-Corner rects are now correctly handled.

=============== Diff against Morphic-mt.772 ===============

Item was added:
+ ----- Method: AlphaBlendingCanvas>>mapFillStyle: (in category 'private') -----
+ mapFillStyle: aFillStyle
+
+ ^ self alpha = 1.0
+ ifTrue: [aFillStyle]
+ ifFalse: [super mapFillStyle: aFillStyle]
+ !

Item was added:
+ ----- Method: ColorMappingCanvas>>frameAndFillRoundRect:radius:fillStyle:borderWidth:borderColor: (in category 'drawing-rectangles') -----
+ frameAndFillRoundRect: aRectangle radius: cornerRadius fillStyle: fillStyle borderWidth: bw borderColor: bc
+ "Draw the rectangle using the given attributes"
+ myCanvas
+ frameAndFillRoundRect: aRectangle
+ radius: cornerRadius
+ fillStyle: (self mapFillStyle: fillStyle)
+ borderWidth: bw
+ borderColor: (self mapColor: bc)
+ !

Item was added:
+ ----- Method: ColorMappingCanvas>>mapFillStyle: (in category 'private') -----
+ mapFillStyle: aFillStyle
+
+ ^ aFillStyle isGradientFill
+ ifFalse: [self mapColor: aFillStyle asColor]
+ ifTrue: [aFillStyle copy colorRamp: (aFillStyle colorRamp collect: [:assoc | assoc key -> (self mapColor: assoc value)])].
+ !

Item was added:
+ ----- Method: PluggableCanvas>>frameAndFillRoundRect:radius:fillStyle:borderWidth:borderColor: (in category 'drawing-rectangles') -----
+ frameAndFillRoundRect: aRectangle radius: cornerRadius fillStyle: fillStyle borderWidth: bw borderColor: bc
+ self apply: [ :c |
+ c frameAndFillRoundRect: aRectangle radius: cornerRadius fillStyle: fillStyle borderWidth: bw borderColor: bc ]!