[squeak-dev] The Trunk: Morphic-MAD.204.mcz

commits at source.squeak.org commits at source.squeak.org
Wed Oct 7 04:45:27 UTC 2009


Andreas Raab uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-MAD.204.mcz

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

Name: Morphic-MAD.204
Author: MAD
Time: 6 October 2009, 7:34:02 am
UUID: e9c3ceb8-187e-4073-bc35-3117b0cf281f
Ancestors: Morphic-MAD.203

Selection highlighting in lists is now consistent with that in menus. I've made direct reference to Preferences menuSelectionColor - not sure if this will be seen as reasonable?

You should really tone down the highlight colour after loading these changes:
Preferences setParameter: #menuSelectionColor to: (Color r: 0.4 g: 0.5 b: 0.7)


=============== Diff against Morphic-MAD.203 ===============

Item was changed:
  ----- Method: PluggableListMorph>>textHighlightColor (in category 'initialization') -----
  textHighlightColor
  	"Answer my default text highlight color."
+ 	^self valueOfProperty: #textHighlightColor ifAbsent: [ self textColor negated ].
- 	^self valueOfProperty: #textHighlightColor ifAbsent: [ Color red ].
  !

Item was changed:
  ----- Method: LazyListMorph>>colorForRow: (in category 'drawing') -----
  colorForRow: 	row
  	^(selectedRow notNil and: [ row = selectedRow])
+ 		ifTrue: [ self color negated ]
- 		ifTrue: [ Color red ]
  		ifFalse: [ self color ].!

Item was changed:
  ----- Method: ListItemWrapper>>highlightingColor (in category 'accessing') -----
  highlightingColor
  
+ 	^self preferredColor negated!
- 	^Color red!

Item was changed:
  ----- Method: ListItemWrapper>>preferredColor (in category 'accessing') -----
  preferredColor
  
+ 	^ Color black!
- 	^nil!

Item was changed:
  ----- Method: LazyListMorph>>drawSelectionOn: (in category 'drawing') -----
  drawSelectionOn: aCanvas
  	| selectionDrawBounds |
  	selectedRow ifNil: [ ^self ].
  	selectedRow = 0 ifTrue: [ ^self ].
  	selectionDrawBounds := self drawBoundsForRow: selectedRow.
  	selectionDrawBounds := selectionDrawBounds intersect: self bounds.
+ 	aCanvas fillRectangle: selectionDrawBounds color: (Preferences menuSelectionColor)!
- 	aCanvas fillRectangle: selectionDrawBounds color: (Color lightGray  alpha: 0.3)!

Item was changed:
  ----- Method: SimpleHierarchicalListMorph>>drawOn: (in category 'drawing') -----
  drawOn: aCanvas
  	super drawOn: aCanvas.
  	selectedMorph ifNotNil:
  		[aCanvas fillRectangle:
  			(((scroller transformFrom: self) invertBoundsRect: selectedMorph bounds)
  						intersect: scroller bounds)
+ 				color: Preferences menuSelectionColor ].
- 				color: color blacker].
  	self drawLinesOn: aCanvas.
  	
  
  
  !

Item was added:




More information about the Squeak-dev mailing list