[FIX] [BUG] smoothOrSegmentedPhrase-wiz (sm)

Peace Jerome peace_the_dreamer at yahoo.com
Sun Jun 13 14:25:10 UTC 2004


When you keep a Polygon/Curve menu up the menu doesn't
update the smooth of segmented phrase. It is now
factored out and made auto updating."

'From Squeak3.7beta of ''1 April 2004'' [latest
update: #5878] on 6 June 2004 at 10:18:48 pm'!
"Change Set:		smoothOrSegmentedPhrase-wiz
Date:			6 June 2004
Author:			Jerome Peace (wiz)

When you keep a Polygon/Curve menu up the menu doesn't
update the smooth of segmented phrase. It is now
factored out and made auto updating."!


!PolygonMorph methodsFor: 'access' stamp: 'wiz
6/6/2004 21:56'!
smoothOrSegmentedPhrase
				| lineName |
	lineName := (closed
						ifTrue: ['outline']
						ifFalse: ['line']) translated.

			^ self isCurve
				ifTrue: ['make segmented {1}' translated format:
{lineName}]
				ifFalse: ['make smooth {1}' translated format:
{lineName}].! !

!PolygonMorph methodsFor: 'menu' stamp: 'wiz 6/6/2004
21:59'!
addCustomMenuItems: aMenu hand: aHandMorph 
	| |
	super addCustomMenuItems: aMenu hand: aHandMorph.
	aMenu
		addUpdating: #handlesShowingPhrase
		target: self
		action: #showOrHideHandles.
	vertices size > 2
		ifTrue: [aMenu
				addUpdating: #openOrClosePhrase
				target: self
				action: #makeOpenOrClosed.
				aMenu
				addUpdating: #smoothOrSegmentedPhrase
				target: self
				action: #toggleSmoothing.] .
"			lineName := (closed
						ifTrue: ['outline']
						ifFalse: ['line']) translated.

			self isCurve
				ifTrue: [aMenu
						add: ('make segmented {1}' translated format:
{lineName})
						action: #toggleSmoothing]
				ifFalse: [aMenu
						add: ('make smooth {1}' translated format:
{lineName})
						action: #toggleSmoothing]."
	aMenu add: 'specify dashed line' translated action:
#specifyDashedLine.
	aMenu add: 'use debug border' translated action:
#showSegmentsBorderStyle.
	self isOpen
		ifTrue: [aMenu addLine.
			aMenu
				addWithLabel: '---'
				enablement: [self isOpen
						and: [arrows ~~ #none]]
				action: #makeNoArrows.
			aMenu
				addWithLabel: '-->'
				enablement: [self isOpen
						and: [arrows ~~ #forward]]
				action: #makeForwardArrow.
			aMenu
				addWithLabel: '<--'
				enablement: [self isOpen
						and: [arrows ~~ #back]]
				action: #makeBackArrow.
			aMenu
				addWithLabel: '<->'
				enablement: [self isOpen
						and: [arrows ~~ #both]]
				action: #makeBothArrows.
			aMenu add: 'customize arrows' translated action:
#customizeArrows:.
			(self hasProperty: #arrowSpec)
				ifTrue: [aMenu add: 'standard arrows' translated
action: #standardArrows]]
		ifFalse: [aMenu addLine.
			aMenu
				addWithLabel: 'make inscibed diamondOval'
				enablement: [self isClosed]
				action: #diamondOval.
			aMenu
				addWithLabel: 'make enclosing rectangleOval'
				enablement: [self isClosed]
				action: #rectOval].! !

Gzip change set attached.

Yours in service,
Jerome Peace

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smoothPhrase-wiz.1.cs.gz
Type: application/x-gzip
Size: 878 bytes
Desc: smoothPhrase-wiz.1.cs.gz
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20040613/a917b3ca/smoothPhrase-wiz.1.cs.bin


More information about the Squeak-dev mailing list