[Fix] Preferences Help not working Squeak 3.8

Tom Phoenix rootbeer at redcat.com
Wed Aug 31 17:59:56 UTC 2005


On 8/31/05, SPINIELLI Enrico <enrico.spinielli at eurocontrol.int> wrote:

> while using Preferences window I found out that clicking on
> Help button was not working due to a missing check on emptyness
> of a string.
> here is the fix for 3.8:

Good catch. You seem to have replaced this line:

    		(aHelpString last == $.)
                    ifFalse: [aStream nextPut: $.].

with this one:

    		(aHelpString isEmpty not and: [aHelpString last == $.])
                    ifFalse: [aStream nextPut: $.].

(I've reformatted these to have the same form and to fit to e-mail
width.) But the original had the intent of putting a period at the end
of the help message, if it didn't end with one. The new line will put
a period at the end of an empty help message. That seems undesirable.
Perhaps this is more like what's intended:

    		(aHelpString notEmpty and: [aHelpString last ~~ $.])
                     ifTrue: [aStream nextPut: $.].

Cheers!

--Tom Phoenix



More information about the Squeak-dev mailing list