[updates] 20 for 3.2alpha

Bruce ONeel beoneel at bluewin.ch
Sat Dec 8 06:52:56 UTC 2001


Hi,
	Thanks to Henrik Gedenryd this is now up on the ftp site
in 3.2alpha.

cheers

bruce

Dan Ingalls <Dan at SqueakLand.org> wrote:
> Folks -
> 
> I've just forwarded 20 new updates to the servers.
> 
> Included are Ted's new SUnit/example work, keyboard control of menus (you can dismiss the 'OK' next time you get updates with a CR), and a number of other fixes and enhancements detailed below.
> 
> Enjoy
> 	- Dan
> ------------------------
> 4567RevertKbdFocus-di -- Dan Ingalls -- 30 November 2001
> Reverts the recent change in keyboard focus due to impact on the handling of command keys."
> 
> 4568ViaSUnit-tk -- Ted Kaehler -- 30 November 2001
> 	SUnits are a style of testing that verify the operation of a list of specific methods.  The structure for SUnits has been in Squeak for a while, but only forty (40) out of 44,000 methods actually have a validating test.    I have embarked on a radical program to improve that.  Here is how I have changed things:
> [ ] To test a method, you needs to make up a receiver, arguments, and a known answer.  Scott Wallace is introducing an 'Instance Browser' to Squeak that shows you an example receiver and arguments for each method.  It lets you run the example.  But, where are we going to get the example receivers and arguments for a method shown in an Instance Browser?  They can be the same as for a test of the method.  I have written code that generates objects that can be used for *either* an SUnit test, or an example method call.
> [ ] Another thing that should be associated with each method is some 'type information'.  This is the protocol that each argument object needs to respond to.  The same mechanism that produces a test case can store this info also.
> [ ] In classic SUnits, there is a separate 'testing class' for each class in Squeak.  This would double the number of classes, and is too much overhead.  I have created a new subclass of TestCase that owns a Verifier.  Verifier is a subclass MessageSend that holds the answer that the method is supposed to produce.
> Object #()
>     MessageSend #('receiver' 'selector' 'arguments')
>         MethodCall #('lastValue' 'methodInterface' 'timeStamp')
>             Verifier #('desiredAnswer' 'passed')
>                  VerifierOfProperty #('theTest')
> I have made a subclass of TestCase that holds a Verifier.  A TestSuite of these behaves like a normal test suite, and does not do too much violence to the careful design of SUnits.
> [ ] A Verifier can only test (a) whether a method returns the correct value and (b) whether it gets an error while running.  A VerifierOfProperty tests for a specific state change after a method has run.  Classic SUnits allow other kinds of assertions and tests.  Except for verifying that a method produces a certain kind of error in a certain case, a series of VerifierOfProperty can test everything that a classic TestCase can.
> [ ] To collect the test cases, I simply enumerate the implementors of #exampleFor:, and call each one with 'all'.  That returns a list of Verifiers, which are run as test cases.
> [ ] The SUnit code comes with a TestRunner user interface.  Say
>      TestRunner open
> and click on Run All.  After you have my update, the TestCase  called TestViaMethodCall collects and runs all tests that are created with #exampleFor:.  (One drawback is that when a method has more than one test, the individual subtests are not named.  We could give them names in the future.)
> 
> 4569WindowDragPatch-di -- Dan Ingalls -- 30 November 2001
> ...until I get this right..."
> 
> 4570activeListPane-sw -- Scott Wallace -- 1 December 2001
> Experimental!  Puts up mild border feedback when a pluggable-list-morph has the keyboard focus.  The color used is the same as the text-highlight color; this establishes a modicum of consistency: when a *text* pane of a window has the keyboard focus, the feedback is the text-highlighting in that same text-highlight color.  This is an experimental add-on to Dan's lazyKeyboardFocus experiment, attempting to work around the problem that whenever the keyboard focus lazily remained in a list pane after the mouse left the pane, there was no user feedback designating which list pane would receive keystrokes -- sometimes a serious problem because the same command-key can mean radically different things depending on which pane gets the command."
> 
> 4571KbdFocusAgain-di -- Dan Ingalls -- 1 December 2001
> [NOTE:  This re-issue after #4567 both covers up a problem where a reversion was posted to the wrong update list, and makes the change to dragging really work (had been issued and rescinded)].
> This changeSet implements a mild form of sticky keyboard focus.  The idea is simply to remove most causes of focus being removed unecessarily, without making any other changes.
> Also included is a small change that makes dragging of system windows by their title bar dependent not on holding down the button for long enough, but by dragging more than 3 pixels.  This in response to a request from Stephen Pair.
> 
> 4572DragVsClick-ar -- Andreas Raab -- 2 December 2001
> A common problem seen with newbies using Squeak is the 'drag vs. click' problem. People tend to click rather than drag and clicking in regions such as supply flaps or viewers may give pretty unexpected results. This change set attempts to fix this problem.
> Note that this is still somewhat experimental. If we don't like it we can easily revert back."
> 
> 4573mailAddrParser-ls -- Lex Spoon -- 2 December 2001
> Fixes the Internet mail address parser.  A couple of character sets were incorrect in the tokenizer, and hopefully they are correct now.  At least 'MailAddressParser example' works now!"
> 
> 4574DragVsClick2-ar -- Andreas Raab -- 3 December 2001
> Fixes the drag vs. click logic for tile scripting elements."
> 
> 4575extImageFix-mir -- Michael Rueger -- 3 December 2001
> Fixes a problem with external images when the resource cache hadn't been initialized yet."
> 
> 4576squeakFlap-sw -- Scott Wallace -- 3 December 2001
> Redefines the default Squeak flap, removing a few items that are now readily available elsewhere.
> NOTE: if you have the #okToReinitializeFlaps preference set to true, then the existing Squeak flap in your image will be replaced in the postscript of the update. "
> 
> 4577aRemoval-sw -- Scott Wallace -- 3 December 2001
> Removes a method in Preferences that was no longer in use but which had attracted undeserved attention, and the class variable that it was the only user of"
> 
> 4578scriptNameType-sw -- Scott Wallace -- 3 December 2001
> Adds a 'ScriptName' data type, to hold script names, and substitutes this for String-type in certain commands in the etoy system, all in the 'scripting' category.
> There are two UIs provided for changing the values on these ScriptName tiles -- you can use the up/down arrows to cycle among the choices, or you can click right on the script-name to get a popup of all known script names, from which you can choose any one directly.
> Also fixes a bug in update 4535 that had blocked out access to the 'scripting' category in viewers."
> 
> 4579kbdFocusPref-sw -- Scott Wallace -- 4 December 2001
> Makes use of the lazy keyboard focus policy instituted in update 4567 depend on a preference, for the temporary rescue of those who rely on use of 'desktop command keys', until a more general solution can be put in place.  To reestablish the former keyboard-focus policy, set the mouseOverForKeyboardFocus preference to true."
> Preferences addPreference: #mouseOverForKeyboardFocus categories: #(morphic) default: false  balloonHelp: 'When true, the mouse must be over a text or list pane in morphic for keystrokes to be felt, and when the mouse is out over the desktop, the so-called desktop-command-keys, such as cmd-b and cmd-R, are honored.  When false, list panes and text panes in morphic remain sensitive to keystrokes even after the mouse is no longer over the pane.'.
> 
> 4580ViaSUnit-2-tk -- Ted Kaehler -- 4 December 2001
> Modified TestRunner to list an entry for each class that implements #exampleFor: (on the class side).  Print with the name of the class.  Mark it as using TestViaMethodCall (which uses Verifier).
> 	TestViaMethodCall does not appear in the list in TestRunner, but instances of it hold the simple style tests for any class that implements #exampleFor:.
> 	Added suites for Collection, OrderedCollection, Number.
> 	Provided hash for ReadWriteStream."
> 
> 4581MorphChangedRevert-mdr -- Mike Rutenberg -- 5 December 2001
> Revert a method to ensure the World is #changed"
> 
> 4582GeeMailFix-raa -- Bob Arning -- 5 December 2001
> Some fixes for GeeMail to cooperate better with the revamped TextMorph. Especially important when using columns."
> 
> 4583Urgent-errorLog-tk -- Ted Kaehler -- 5 December 2001
> Henrik Gedenryd reported a serious problem in error logging. It occurs if:
> 	The preference to write errors to a log file is on.
> 	In a fileList, make a small change to a file and save.
> 	When asked to overwrite, say 'Cancel'.
> 	The system will lock up in WeakRegistry.
> My fix disables #printElementsOn: in WeakRegistry when it is locked.  (#do: tests the lock, and waits on a semaphore.)"
> 
> 4584AndOr4-di -- Dan Ingalls -- 5 December 2001
> Extends non-evaluating ands and ors to up to 4 blocks without extra nesting.
> For example now you can write...
> 	^ self class = aRenameVariableChange class
> 		and: [className = aRenameVariableChange changeClassName]
> 		and: [isMeta = aRenameVariableChange isMeta]
> 		and: [oldName = aRenameVariableChange oldName]
> 		and: [newName = aRenameVariableChange newName]
> Inspired by a (different) suggestion from Andres Valloud on 10/2/2001.
> 
> 4585MenuFromKeyboard-di-sw -- Dan Ingalls and Scott Wallace -- 2 December 2001
> This changeSet introduces keyboard control of menus in morphic.
> First of all, there is now the ability to move the selection up and down using arrow keys in any menu, and to confirm with CR or cancel with ESC, and to pass control into a sub-menu with right- or left- arrow (and to return back with ESC).
> That's not all.  If you type in a menu, it builds a pattern string, which appears at the bottom of the menu.  Whenever the pattern is not empty, only items that match are presented.  If only one item matches the pattern (or in any menu with only one item), the option is given to confirm with CR or cancel with ESC.
> But wait, there's more...  In most contexts, hitting ESC now brings up the world menu, (and, of course, hitting ESC again will make it go away again).  This enables all sorts of TECO-like incantations such as
> 	'<ESC>d q<CR>' which would, of course, invoke 'save and quit', or
> 	'<ESC>he<CR>spa<CR>' to show the amount of free space.
> [A free bottle of Ripple will be awarded to the first Squeaker to successfully perform majorShrink on a computer with no pointing device].
> Finally, two cosmetic tweaks are also included:
> 	1.  The selection in a menu is now shown slightly darker than before, and
> 	2.  Menus indicate keyboard focus with a thin green border (useful with arrow control).
> 
> 4586escInEmptyListPane-sw -- Scott Wallace -- 5 December 2001
> Minor bug fix: makes an esc gesture issued when a list pane has keyboard focus bring up the world menu even if the list pane is empty"




More information about the Squeak-dev mailing list