[Pharo-project] Issue 3281 in pharo: IconicButton graphic not centered

pharo at googlecode.com pharo at googlecode.com
Mon Nov 22 16:20:49 CET 2010

Status: New
Owner: gazzaguru2
Labels: Milestone-1.2

New issue 3281 by gazzaguru2: IconicButton graphic not centered

Quick fix: add the following


extent: newExtent
	"Update the graphic position to keep centered."
	super extent: newExtent.
	graphicalMorph ifNotNil: [graphicalMorph position: self center -  
(graphicalMorph extent // 2)]

Would be nicer to refactor "graphicalMorph" with the superclass "label"...

More information about the Pharo-project mailing list