From eliot.miranda at gmail.com Wed Apr 1 03:58:07 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Wed Apr 1 03:58:10 2015 Subject: [squeak-dev] The Trunk: Tools-mt.565.mcz In-Reply-To: <5517f3c7.03968c0a.64f7.ffffc791SMTPIN_ADDED_MISSING@mx.google.com> References: <5517f3c7.03968c0a.64f7.ffffc791SMTPIN_ADDED_MISSING@mx.google.com> Message-ID: Hi Marcel, this may have broken the FileList. At least after the latest update the FileList no longer opens up the tree of directories in the left-hand pane to the current directory. On Sun, Mar 29, 2015 at 5:44 AM, wrote: > Marcel Taeumel uploaded a new version of Tools to project The Trunk: > http://source.squeak.org/trunk/Tools-mt.565.mcz > > ==================== Summary ==================== > > Name: Tools-mt.565 > Author: mt > Time: 29 March 2015, 2:44:29.709 pm > UUID: f8216267-8713-0449-bef6-35fecc620960 > Ancestors: Tools-topa.564 > > Refactored toggle/expand code in IndentingListItemMorph. > > =============== Diff against Tools-topa.564 =============== > > Item was changed: > + ----- Method: > IndentingListItemMorph>>addChildrenForList:addingTo:withExpandedItems: (in > category 'container protocol - private') ----- > - ----- Method: > IndentingListItemMorph>>addChildrenForList:addingTo:withExpandedItems: (in > category 'private-container protocol') ----- > addChildrenForList: hostList addingTo: morphList withExpandedItems: > expandedItems > > firstChild ifNotNil: [ > firstChild withSiblingsDo: [ :aNode | aNode delete]. > ]. > firstChild := nil. > complexContents hasContents ifFalse: [^self]. > firstChild := hostList > addMorphsTo: morphList > from: complexContents contents > allowSorting: true > withExpandedItems: expandedItems > atLevel: indentLevel + 1. > ! > > Item was changed: > + ----- Method: IndentingListItemMorph>>canExpand (in category 'testing') > ----- > - ----- Method: IndentingListItemMorph>>canExpand (in category > 'accessing') ----- > canExpand > > ^complexContents hasContents! > > Item was added: > + ----- Method: IndentingListItemMorph>>collapse (in category 'container > protocol') ----- > + collapse > + > + self isExpanded ifFalse: [^ self]. > + > + self isExpanded: false. > + > + firstChild ifNotNil: [:collapsingNode | > + | toDelete | > + toDelete := OrderedCollection new. > + collapsingNode withSiblingsDo: [:aNode | aNode > recursiveAddTo: toDelete]. > + container noteRemovalOfAll: toDelete]. > + > + self changed.! > > Item was changed: > + ----- Method: IndentingListItemMorph>>complexContents (in category > 'accessing') ----- > - ----- Method: IndentingListItemMorph>>complexContents (in category > 'private-container protocol') ----- > complexContents > > ^complexContents! > > Item was added: > + ----- Method: IndentingListItemMorph>>expand (in category 'container > protocol') ----- > + expand > + > + | newChildren c | > + > + (self isExpanded or: [self canExpand not]) > + ifTrue: [^ self]. > + > + (c := self getChildren) ifEmpty: [ > + "Due to the guessing in #canExpand, it may still fail > here." > + ^ self]. > + > + self isExpanded: true. > + > + newChildren := container > + addSubmorphsAfter: self > + fromCollection: c > + allowSorting: true. > + > + firstChild := newChildren first.! > > Item was changed: > + ----- Method: IndentingListItemMorph>>hasIcon (in category 'testing') > ----- > - ----- Method: IndentingListItemMorph>>hasIcon (in category 'accessing') > ----- > hasIcon > "Answer whether the receiver has an icon." > ^ icon notNil! > > Item was changed: > + ----- Method: IndentingListItemMorph>>highlight (in category 'container > protocol - private') ----- > - ----- Method: IndentingListItemMorph>>highlight (in category > 'private-container protocol') ----- > highlight > > (self valueOfProperty: #wasRefreshed ifAbsent: [false]) > ifFalse: [self color: complexContents highlightingColor] > ifTrue: [self color: self color negated]. > > self changed. > > ! > > Item was changed: > + ----- Method: IndentingListItemMorph>>isFirstItem (in category > 'testing') ----- > - ----- Method: IndentingListItemMorph>>isFirstItem (in category > 'accessing') ----- > isFirstItem > ^owner submorphs first == self! > > Item was changed: > + ----- Method: IndentingListItemMorph>>isSoleItem (in category 'testing') > ----- > - ----- Method: IndentingListItemMorph>>isSoleItem (in category > 'accessing') ----- > isSoleItem > ^self isFirstItem and: [ owner submorphs size = 1 ]! > > Item was changed: > + ----- Method: IndentingListItemMorph>>openPath: (in category 'container > protocol - private') ----- > - ----- Method: IndentingListItemMorph>>openPath: (in category > 'private-container protocol') ----- > openPath: anArray > | found | > anArray isEmpty > ifTrue: [^ container setSelectedMorph: nil]. > found := nil. > self > withSiblingsDo: [:each | found > ifNil: [(each complexContents asString = > anArray first > or: [anArray first > isNil]) > ifTrue: [found := each]]]. > found > ifNil: ["try again with no case sensitivity" > self > withSiblingsDo: [:each | found > ifNil: [(each > complexContents asString sameAs: anArray first) > ifTrue: > [found := each]]]]. > found > ifNotNil: [found isExpanded > ifFalse: [found toggleExpandedState. > container adjustSubmorphPositions]. > found changed. > anArray size = 1 > ifTrue: [^ container setSelectedMorph: > found]. > ^ found firstChild > ifNil: [container setSelectedMorph: nil] > ifNotNil: [found firstChild openPath: > anArray allButFirst]]. > ^ container setSelectedMorph: nil! > > Item was changed: > + ----- Method: IndentingListItemMorph>>recursiveAddTo: (in category > 'container protocol - private') ----- > - ----- Method: IndentingListItemMorph>>recursiveAddTo: (in category > 'private-container protocol') ----- > recursiveAddTo: aCollection > > firstChild ifNotNil: [ > firstChild withSiblingsDo: [ :aNode | aNode > recursiveAddTo: aCollection]. > ]. > aCollection add: self > ! > > Item was changed: > + ----- Method: IndentingListItemMorph>>recursiveDelete (in category > 'container protocol - private') ----- > - ----- Method: IndentingListItemMorph>>recursiveDelete (in category > 'private-container protocol') ----- > recursiveDelete > > firstChild ifNotNil: [ > firstChild withSiblingsDo: [ :aNode | aNode > recursiveDelete]. > ]. > self delete > ! > > Item was changed: > + ----- Method: IndentingListItemMorph>>toggleExpandedState (in category > 'container protocol') ----- > - ----- Method: IndentingListItemMorph>>toggleExpandedState (in category > 'private-container protocol') ----- > toggleExpandedState > > + self isExpanded > + ifTrue: [self collapse] > + ifFalse: [self expand].! > - | newChildren toDelete c | > - > - isExpanded := isExpanded not. > - toDelete := OrderedCollection new. > - firstChild ifNotNil: [ > - firstChild withSiblingsDo: [ :aNode | aNode > recursiveAddTo: toDelete]. > - ]. > - container noteRemovalOfAll: toDelete. > - (isExpanded and: [complexContents hasContents]) ifFalse: [ > - ^self changed > - ]. > - (c := self getChildren) isEmpty ifTrue: [^self changed]. > - newChildren := container > - addSubmorphsAfter: self > - fromCollection: c > - allowSorting: true. > - firstChild := newChildren first. > - ! > > > -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150331/43ab307e/attachment.htm From marcel.taeumel at student.hpi.uni-potsdam.de Wed Apr 1 06:35:48 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Wed Apr 1 06:47:28 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.794.mcz In-Reply-To: References: Message-ID: <1427870148845-4816549.post@n4.nabble.com> Yeah, that's how it is implemented in BalloonMorph. Is there some dependency misconfigured? Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-794-mcz-tp4816304p4816549.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Wed Apr 1 06:36:58 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Wed Apr 1 06:48:39 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.794.mcz In-Reply-To: <1427870148845-4816549.post@n4.nabble.com> References: <1427870148845-4816549.post@n4.nabble.com> Message-ID: <1427870218443-4816550.post@n4.nabble.com> Seems like that Morphic should be loaded *before* MorphicExtras anyway. Can we fix that in the update map? Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-794-mcz-tp4816304p4816550.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Wed Apr 1 06:37:40 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Wed Apr 1 06:49:19 2015 Subject: [squeak-dev] Re: The Trunk: Tools-mt.565.mcz In-Reply-To: References: Message-ID: <1427870260787-4816551.post@n4.nabble.com> Thank you, I will take a look at it. Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Tools-mt-565-mcz-tp4815897p4816551.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Wed Apr 1 07:14:15 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 07:14:17 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.109.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.109.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.109 Author: mt Time: 1 April 2015, 9:14:10.308 am UUID: 9505fa1d-c308-cc45-89a2-8b3bab4b07ea Ancestors: ToolBuilder-Morphic-mt.108 Reverted path selection in tree to use #= instead of #==. Fixed the code to indicate the actual selection in the tree (and scroll to it if too large). =============== Diff against ToolBuilder-Morphic-mt.108 =============== Item was changed: ----- Method: PluggableTreeMorph>>selectPath:in: (in category 'selection') ----- selectPath: path in: listItem + path isEmpty ifTrue: [^self selection: nil]. + - path isEmpty ifTrue: [^self setSelectedMorph: nil]. listItem withSiblingsDo: [:each | + (each complexContents item = path first) ifTrue: [ - (each complexContents item == path first) ifTrue: [ each isExpanded ifFalse: [ each toggleExpandedState. self adjustSubmorphPositions. ]. each changed. path size = 1 ifTrue: [ + ^self selection: each complexContents - ^self setSelectedMorph: each ]. + each firstChild ifNil: [^self selection: nil]. - each firstChild ifNil: [^self setSelectedMorph: nil]. ^self selectPath: path allButFirst in: each firstChild ]. ]. + ^self selection: nil + + ! - ^self setSelectedMorph: nil! From commits at source.squeak.org Wed Apr 1 07:16:29 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 07:16:32 2015 Subject: [squeak-dev] The Trunk: Tools-mt.569.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.569.mcz ==================== Summary ==================== Name: Tools-mt.569 Author: mt Time: 1 April 2015, 9:16:07.657 am UUID: 571e1638-a483-0548-90e1-92a3cc15406a Ancestors: Tools-mt.568 Fixed selection in FileList tool. =============== Diff against Tools-mt.568 =============== Item was changed: ----- Method: FileList>>buildDirectoryTreeWith: (in category 'toolbuilder') ----- buildDirectoryTreeWith: builder | treeSpec | treeSpec := builder pluggableTreeSpec new. treeSpec model: self ; roots: #rootDirectoryList ; hasChildren: #hasMoreDirectories: ; getChildren: #subDirectoriesOf: ; getSelectedPath: #selectedPath ; setSelected: #setDirectoryTo: ; + getSelected: #directory; label: #directoryNameOf: ; menu: #volumeMenu: ; autoDeselect: false. SystemBrowser browseWithDragNDrop ifTrue: [ treeSpec dragItem: #dragFromDirectoryList: ; dropItem: #drop:ontoDirectory:shouldCopy: ]. ^ treeSpec! Item was changed: ----- Method: FileList>>directory: (in category 'initialization') ----- directory: aFileDirectory "Set the path of the volume to be displayed." self okToChange ifFalse: [ ^ self ]. self modelSleep. directory := aFileDirectory. self modelWakeUp. sortMode == nil ifTrue: [ sortMode := #date ]. volList := (Array with: '[]') , directory pathParts withIndexCollect: [ : each : i | (String new: i - 1 withAll: Character space) , each ]. volListIndex := volList size. self changed: #relabel. self changed: #volumeList. + self changed: #directory. self pattern: pattern! From marcel.taeumel at student.hpi.uni-potsdam.de Wed Apr 1 07:05:37 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Wed Apr 1 07:17:16 2015 Subject: [squeak-dev] Re: The Trunk: Tools-mt.565.mcz In-Reply-To: <1427870260787-4816551.post@n4.nabble.com> References: <1427870260787-4816551.post@n4.nabble.com> Message-ID: <1427871937054-4816555.post@n4.nabble.com> Should be fixed in: The Trunk: Tools-mt.569.mcz The Trunk: ToolBuilder-Morphic-mt.109.mcz Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Tools-mt-565-mcz-tp4815897p4816555.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Wed Apr 1 08:25:58 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 08:26:00 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.110.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.110.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.110 Author: mt Time: 1 April 2015, 10:25:52.197 am UUID: d7697fb6-b947-8e4a-a6b7-e8a087d2c81f Ancestors: ToolBuilder-Morphic-mt.109 Revert "code to indicate the actual selection" because I confused the view-based API with the model-based API. =============== Diff against ToolBuilder-Morphic-mt.109 =============== Item was changed: ----- Method: PluggableTreeMorph>>selectPath:in: (in category 'selection') ----- selectPath: path in: listItem + path isEmpty ifTrue: [^self setSelectedMorph: nil]. - path isEmpty ifTrue: [^self selection: nil]. - listItem withSiblingsDo: [:each | (each complexContents item = path first) ifTrue: [ each isExpanded ifFalse: [ each toggleExpandedState. self adjustSubmorphPositions. ]. each changed. path size = 1 ifTrue: [ + ^self setSelectedMorph: each - ^self selection: each complexContents ]. + each firstChild ifNil: [^self setSelectedMorph: nil]. - each firstChild ifNil: [^self selection: nil]. ^self selectPath: path allButFirst in: each firstChild ]. ]. + ^self setSelectedMorph: nil - ^self selection: nil ! From commits at source.squeak.org Wed Apr 1 08:35:15 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 08:35:17 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.798.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.798.mcz ==================== Summary ==================== Name: Morphic-mt.798 Author: mt Time: 1 April 2015, 10:34:38.43 am UUID: b8569c16-d9cb-a24e-b4d5-a6b7f6abd7ba Ancestors: Morphic-mt.797 Fixes error that may occur in empty lazy lists when mapping a point to a row index. =============== Diff against Morphic-mt.797 =============== Item was changed: ----- Method: LazyListMorph>>rowAtLocation: (in category 'list management') ----- rowAtLocation: aPoint "return the number of the row at aPoint" | y | y := aPoint y. + y < self top ifTrue: [ ^ 1 min: listItems size ]. - y < self top ifTrue: [ ^ 1 ]. ^((y - self top // (font height)) + 1) min: listItems size max: 0! From commits at source.squeak.org Wed Apr 1 08:49:48 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 08:49:50 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.799.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.799.mcz ==================== Summary ==================== Name: Morphic-mt.799 Author: mt Time: 1 April 2015, 10:48:52.717 am UUID: 8402d670-ebfe-6a4b-9563-16fc41d80d37 Ancestors: Morphic-mt.798 Remove the balloon text when start typing because we assume that the user focuses on the input and not the help anymore. This is similar to balloon help for buttons where the bubble disappears if the user clicks the button. =============== Diff against Morphic-mt.798 =============== Item was changed: ----- Method: TextMorphForEditView>>keyStroke: (in category 'event handling') ----- keyStroke: evt | view | + editView deleteBalloon. (editView scrollByKeyboard: evt) ifTrue: [^self]. self editor model: editView model. "For evaluateSelection" view := editView. "Copy into temp for case of a self-mutating doit" (acceptOnCR and: [evt keyCharacter = Character cr]) ifTrue: [^ self editor accept]. super keyStroke: evt. view scrollSelectionIntoView! From edgardec2005 at gmail.com Wed Apr 1 09:50:13 2015 From: edgardec2005 at gmail.com (Edgar J. De Cleene) Date: Wed Apr 1 09:50:22 2015 Subject: [squeak-dev] build.squeak.org slaves: which are there after all? In-Reply-To: <1FAA43DA-1EEB-4806-8747-F14066B6FCD0@gmx.de> Message-ID: Well, my Mac should be re configured to be a all time server. Now it have a nice 4Tb disc what community could share. Send mail private is needed and I glad setup. Edgar From commits at source.squeak.org Wed Apr 1 11:19:13 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 11:19:15 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.800.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.800.mcz ==================== Summary ==================== Name: Morphic-mt.800 Author: mt Time: 1 April 2015, 1:18:34.183 pm UUID: 348486a9-bf29-0a42-b162-ddb7adaab048 Ancestors: Morphic-mt.799 Elevated #roundedScrollBarLook into a preference (was: just hardcoded to false) and updated affected methods. Added preference to hide even the arrow buttons of all scrollbars. This makes sense for mouse-wheel-driven usage. =============== Diff against Morphic-mt.799 =============== Item was changed: Slider subclass: #ScrollBar instanceVariableNames: 'menuButton upButton downButton pagingArea scrollDelta pageDelta interval menuSelector timeOfMouseDown timeOfLastScroll nextPageDirection currentScrollDelay' + classVariableNames: 'ArrowImagesCache BoxesImagesCache RoundedScrollBarLook ScrollBarsWithoutArrowButtons UpArrow UpArrow8Bit' - classVariableNames: 'ArrowImagesCache BoxesImagesCache UpArrow UpArrow8Bit' poolDictionaries: '' category: 'Morphic-Windows'! !ScrollBar commentStamp: '' prior: 0! Inspired by an oiginal design of Hans-Martin Mosner, this ScrollBar is intended to exercise the handling of input events in Morphic. With sufficient flexibility in this area, all particular behavior can be concentrated in this single class with no need to specialize any other morphs to achieve button, slider and menu-button behavior. Once we have this working, put in logic for horizontal operation as well. CachedImages was added to reduce the number of forms created and thrown away. This will be helpful for Nebraska and others as well.! Item was added: + ----- Method: ScrollBar class>>roundedScrollBarLook (in category 'preferences') ----- + roundedScrollBarLook + + + ^ RoundedScrollBarLook ifNil: [false]! Item was added: + ----- Method: ScrollBar class>>roundedScrollBarLook: (in category 'preferences') ----- + roundedScrollBarLook: aBoolean + + RoundedScrollBarLook := aBoolean.! Item was added: + ----- Method: ScrollBar class>>scrollBarsWithoutArrowButtons (in category 'preferences') ----- + scrollBarsWithoutArrowButtons + + + ^ ScrollBarsWithoutArrowButtons ifNil: [false]! Item was added: + ----- Method: ScrollBar class>>scrollBarsWithoutArrowButtons: (in category 'preferences') ----- + scrollBarsWithoutArrowButtons: aBoolean + + ScrollBarsWithoutArrowButtons := aBoolean.! Item was changed: ----- Method: ScrollBar>>finishedScrolling (in category 'scrolling') ----- finishedScrolling self stopStepping. self scrollBarAction: nil. + self class roundedScrollBarLook ifTrue:[ - self roundedScrollbarLook ifTrue:[ upButton borderStyle: (BorderStyle complexRaised width: upButton borderWidth). downButton borderStyle: (BorderStyle complexRaised width: downButton borderWidth). ] ifFalse:[ downButton borderStyle: BorderStyle thinGray. upButton borderStyle: BorderStyle thinGray. ]. ! Item was added: + ----- Method: ScrollBar>>hasButtons (in category 'testing') ----- + hasButtons + + ^ (menuButton notNil or: [upButton owner notNil]) or: [downButton owner notNil]! Item was changed: ----- Method: ScrollBar>>initialize (in category 'initialize') ----- initialize + super initialize. + scrollDelta := 0.02. pageDelta := 0.2. + + self color: Color transparent. + + self class roundedScrollBarLook + ifFalse: [self borderWidth: 0] + ifTrue:[self borderStyle: ((BorderStyle complexFramed width: 2) "baseColor: Color gray")].! - self roundedScrollbarLook ifTrue:[ - self borderStyle: ((BorderStyle complexFramed width: 2) "baseColor: Color gray")].! Item was changed: ----- Method: ScrollBar>>initializeDownButton (in category 'initialize') ----- initializeDownButton "initialize the receiver's downButton" downButton := RectangleMorph newBounds: (self innerBounds bottomRight - self buttonExtent extent: self buttonExtent) color: self thumbColor. downButton on: #mouseDown send: #scrollDownInit to: self. downButton on: #mouseUp send: #finishedScrolling to: self. self updateDownButtonImage. + self class roundedScrollBarLook - self roundedScrollbarLook ifTrue: [downButton color: Color veryLightGray. downButton borderStyle: (BorderStyle complexRaised width: 3)] ifFalse: [downButton setBorderWidth: 1 borderColor: Color lightGray]. + + self class scrollBarsWithoutArrowButtons + ifFalse: [self addMorph: downButton].! - self addMorph: downButton! Item was changed: ----- Method: ScrollBar>>initializeEmbedded: (in category 'initialize') ----- initializeEmbedded: aBool "aBool == true => inboard scrollbar aBool == false => flop-out scrollbar" + self class roundedScrollBarLook ifFalse:[^self]. - self roundedScrollbarLook ifFalse:[^self]. aBool ifTrue:[ self borderStyle: (BorderStyle inset width: 2). self cornerStyle: #square. ] ifFalse:[ self borderStyle: (BorderStyle width: 1 color: Color black). self cornerStyle: #rounded. ]. self removeAllMorphs. self initializeSlider.! Item was changed: ----- Method: ScrollBar>>initializeMenuButton (in category 'initialize') ----- initializeMenuButton "initialize the receiver's menuButton" "Preferences disable: #scrollBarsWithoutMenuButton" "Preferences enable: #scrollBarsWithoutMenuButton" (Preferences valueOfFlag: #scrollBarsWithoutMenuButton) ifTrue: [menuButton := nil .^ self]. self bounds isWide ifTrue: [menuButton := nil .^ self]. + menuButton := self class roundedScrollBarLook - menuButton := self roundedScrollbarLook ifTrue: [RectangleMorph newBounds: ((bounds isWide ifTrue: [upButton bounds topRight] ifFalse: [upButton bounds bottomLeft]) extent: self buttonExtent)] ifFalse: [RectangleMorph newBounds: (self innerBounds topLeft extent: self buttonExtent) color: self thumbColor]. menuButton on: #mouseEnter send: #menuButtonMouseEnter: to: self. menuButton on: #mouseDown send: #menuButtonMouseDown: to: self. menuButton on: #mouseLeave send: #menuButtonMouseLeave: to: self. "menuButton addMorphCentered: (RectangleMorph newBounds: (0 @ 0 extent: 4 @ 2) color: Color black)." self updateMenuButtonImage. + self class roundedScrollBarLook - self roundedScrollbarLook ifTrue: [menuButton color: Color veryLightGray. menuButton borderStyle: (BorderStyle complexRaised width: 3)] ifFalse: [menuButton setBorderWidth: 1 borderColor: Color lightGray]. self addMorph: menuButton! Item was changed: ----- Method: ScrollBar>>initializePagingArea (in category 'initialize') ----- initializePagingArea + + "Appearance" - "initialize the receiver's pagingArea" pagingArea := RectangleMorph newBounds: self totalSliderArea + color: (self class roundedScrollBarLook + ifTrue: [Color gray: 0.9] + ifFalse: [Color r: 0.6 g: 0.6 b: 0.8]). + pagingArea setBorderWidth: 1 borderColor: (Color lightGray alpha: 0.5). + self addMorphBack: pagingArea. + + "Interactions" - color: (Color - r: 0.6 - g: 0.6 - b: 0.8). - pagingArea setBorderWidth: 1 borderColor: Color lightGray. pagingArea on: #mouseDown send: #scrollPageInit: to: self. pagingArea on: #mouseUp send: #finishedScrolling to: self. + + ! - self addMorphBack: pagingArea. - self roundedScrollbarLook - ifTrue: [pagingArea - color: (Color gray: 0.9)]! Item was changed: ----- Method: ScrollBar>>initializeSlider (in category 'initialize') ----- initializeSlider "initialize the receiver's slider" + self class roundedScrollBarLook - self roundedScrollbarLook ifTrue: [self initializeUpButton; initializeMenuButton; initializeDownButton; initializePagingArea] ifFalse: [self initializeMenuButton; initializeUpButton; initializeDownButton; initializePagingArea]. super initializeSlider. + self class roundedScrollBarLook - self roundedScrollbarLook ifTrue: [slider cornerStyle: #rounded. slider borderStyle: (BorderStyle complexRaised width: 3). sliderShadow cornerStyle: #rounded]. self sliderColor: self sliderColor! Item was changed: ----- Method: ScrollBar>>initializeUpButton (in category 'initialize') ----- initializeUpButton "initialize the receiver's upButton" + upButton := self class roundedScrollBarLook - upButton := self roundedScrollbarLook ifTrue: [RectangleMorph newBounds: (self innerBounds topLeft extent: self buttonExtent)] ifFalse: [RectangleMorph newBounds: ((menuButton ifNil: [self innerBounds topLeft] ifNotNil: [bounds isWide ifTrue: [menuButton bounds topRight - (1@0)] ifFalse: [menuButton bounds bottomLeft - (0@1)]]) extent: self buttonExtent)]. upButton color: self thumbColor. upButton on: #mouseDown send: #scrollUpInit to: self. upButton on: #mouseUp send: #finishedScrolling to: self. self updateUpButtonImage. + self class roundedScrollBarLook - self roundedScrollbarLook ifTrue: [upButton color: Color veryLightGray. upButton borderStyle: (BorderStyle complexRaised width: 3)] ifFalse: [upButton setBorderWidth: 1 borderColor: Color lightGray]. + + self class scrollBarsWithoutArrowButtons + ifFalse: [self addMorph: upButton].! - self addMorph: upButton! Item was removed: - ----- Method: ScrollBar>>roundedScrollbarLook (in category 'access') ----- - roundedScrollbarLook - "Rounded look currently only shows up in flop-out mode" - ^false and: [ - self class alwaysShowFlatScrollbarForAlternativeLook not] - ! Item was changed: ----- Method: ScrollBar>>sliderShadowColor (in category 'access') ----- sliderShadowColor + ^ self class roundedScrollBarLook - ^ self roundedScrollbarLook ifTrue: [self sliderColor darker] ifFalse: [super sliderShadowColor] ! Item was changed: ----- Method: ScrollBar>>totalSliderArea (in category 'geometry') ----- totalSliderArea + | upperReferenceBounds lowerReferenceBounds | + upperReferenceBounds := (upButton owner ifNil: [menuButton] ifNotNil: [upButton]) + ifNil: [self topLeft corner: (bounds isWide ifTrue: [self bottomLeft + (1@0)] ifFalse: [self topRight + (0@1)])] + ifNotNil: [:button | button bounds]. + lowerReferenceBounds := downButton owner + ifNil: [(bounds isWide ifTrue: [self topRight - (1@0)] ifFalse: [self bottomLeft - (0@1)]) corner: self bottomRight] + ifNotNil: [downButton bounds]. + ^ bounds isWide + ifTrue: [upperReferenceBounds topRight - (1@0) corner: lowerReferenceBounds bottomLeft + (1@0)] + ifFalse:[upperReferenceBounds bottomLeft - (0@1) corner: lowerReferenceBounds topRight + (0@1)]. - | upperBoundsButton | - upperBoundsButton := menuButton ifNil: [upButton]. - bounds isWide - ifTrue: [ - upButton right > upperBoundsButton right - ifTrue: [upperBoundsButton := upButton]. - ^upperBoundsButton bounds topRight - (1@0) corner: downButton bounds bottomLeft + (1@0)] - ifFalse:[ - upButton bottom > upperBoundsButton bottom - ifTrue: [upperBoundsButton := upButton]. - ^upperBoundsButton bounds bottomLeft - (0@1) corner: downButton bounds topRight + (0@1)]. ! Item was changed: ----- Method: ScrollBar>>updateSliderColor: (in category 'access') ----- updateSliderColor: aColor | gradient | - slider borderStyle: (BorderStyle width: 1 color: Color lightGray). self borderWidth: 0. Preferences gradientScrollBars ifFalse: [ + slider borderStyle: (BorderStyle width: 1 color: aColor muchDarker). slider color: aColor. + pagingArea color: (aColor darker alpha: 0.45). - pagingArea color: aColor darker darker. ^ self]. + slider borderStyle: (BorderStyle width: 1 color: Color lightGray). + "Fill the slider." gradient := GradientFillStyle ramp: { 0 -> (Color gray: 0.95). 0.49 -> (Color gray: 0.9). 0.5 -> (Color gray: 0.87). 1 -> (Color gray: 0.93). }. gradient origin: slider topLeft. gradient direction: (self bounds isWide ifTrue:[0@slider height] ifFalse:[slider width@0]). slider fillStyle: gradient. "Fill the paging area." gradient := GradientFillStyle ramp: { 0 -> (Color gray: 0.65). 0.6 -> (Color gray: 0.82). 1 -> (Color gray: 0.88). }. gradient origin: self topLeft. gradient direction: (self bounds isWide ifTrue:[0@self height] ifFalse:[self width@0]). pagingArea fillStyle: gradient.! From marcel.taeumel at student.hpi.uni-potsdam.de Wed Apr 1 11:13:04 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Wed Apr 1 11:24:44 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.800.mcz In-Reply-To: References: Message-ID: <1427886784067-4816614.post@n4.nabble.com> In conjuction with narrow scrollbars and no menu button, you can save some space on screen with it. For the sake of comparison, you see the default setting on the right: gradient enabled, menu button visible, arrow buttons visible, normal width. I thought about making the background/paging area transparent but this would affect discoverability of its features. Do you yet try to click on the area besides the draggable thumb? ;-) Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-800-mcz-tp4816610p4816614.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Wed Apr 1 11:36:39 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 11:36:43 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.801.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.801.mcz ==================== Summary ==================== Name: Morphic-mt.801 Author: mt Time: 1 April 2015, 1:36:02.765 pm UUID: 755e5f34-e9d2-a84e-a23e-c33ad43e082e Ancestors: Morphic-mt.800 Scrollbars: Fixed button initialization code for rounded scrollbars. =============== Diff against Morphic-mt.800 =============== Item was changed: ----- Method: ScrollBar>>initializeMenuButton (in category 'initialize') ----- initializeMenuButton "initialize the receiver's menuButton" "Preferences disable: #scrollBarsWithoutMenuButton" "Preferences enable: #scrollBarsWithoutMenuButton" (Preferences valueOfFlag: #scrollBarsWithoutMenuButton) ifTrue: [menuButton := nil .^ self]. self bounds isWide ifTrue: [menuButton := nil .^ self]. + menuButton := RectangleMorph - menuButton := self class roundedScrollBarLook - ifTrue: [RectangleMorph - newBounds: ((bounds isWide - ifTrue: [upButton bounds topRight] - ifFalse: [upButton bounds bottomLeft]) - extent: self buttonExtent)] - ifFalse: [RectangleMorph newBounds: (self innerBounds topLeft extent: self buttonExtent) + color: self thumbColor. - color: self thumbColor]. menuButton on: #mouseEnter send: #menuButtonMouseEnter: to: self. menuButton on: #mouseDown send: #menuButtonMouseDown: to: self. menuButton on: #mouseLeave send: #menuButtonMouseLeave: to: self. "menuButton addMorphCentered: (RectangleMorph newBounds: (0 @ 0 extent: 4 @ 2) color: Color black)." self updateMenuButtonImage. self class roundedScrollBarLook ifTrue: [menuButton color: Color veryLightGray. menuButton borderStyle: (BorderStyle complexRaised width: 3)] ifFalse: [menuButton setBorderWidth: 1 borderColor: Color lightGray]. self addMorph: menuButton! Item was changed: ----- Method: ScrollBar>>initializeSlider (in category 'initialize') ----- initializeSlider + + self + initializeMenuButton; + initializeUpButton; + initializeDownButton; + initializePagingArea. + - "initialize the receiver's slider" - self class roundedScrollBarLook - ifTrue: [self initializeUpButton; initializeMenuButton; initializeDownButton; initializePagingArea] - ifFalse: [self initializeMenuButton; initializeUpButton; initializeDownButton; initializePagingArea]. super initializeSlider. self class roundedScrollBarLook ifTrue: [slider cornerStyle: #rounded. slider borderStyle: (BorderStyle complexRaised width: 3). sliderShadow cornerStyle: #rounded]. self sliderColor: self sliderColor! Item was changed: ----- Method: ScrollBar>>initializeUpButton (in category 'initialize') ----- initializeUpButton "initialize the receiver's upButton" + upButton := RectangleMorph + newBounds: ((menuButton + ifNil: [self innerBounds topLeft] + ifNotNil: [bounds isWide + ifTrue: [menuButton bounds topRight - (1@0)] + ifFalse: [menuButton bounds bottomLeft - (0@1)]]) + extent: self buttonExtent). - upButton := self class roundedScrollBarLook - ifTrue: [RectangleMorph - newBounds: (self innerBounds topLeft extent: self buttonExtent)] - ifFalse: [RectangleMorph - newBounds: ((menuButton - ifNil: [self innerBounds topLeft] - ifNotNil: [bounds isWide - ifTrue: [menuButton bounds topRight - (1@0)] - ifFalse: [menuButton bounds bottomLeft - (0@1)]]) - extent: self buttonExtent)]. upButton color: self thumbColor. upButton on: #mouseDown send: #scrollUpInit to: self. upButton on: #mouseUp send: #finishedScrolling to: self. self updateUpButtonImage. self class roundedScrollBarLook ifTrue: [upButton color: Color veryLightGray. upButton borderStyle: (BorderStyle complexRaised width: 3)] ifFalse: [upButton setBorderWidth: 1 borderColor: Color lightGray]. self class scrollBarsWithoutArrowButtons ifFalse: [self addMorph: upButton].! From commits at source.squeak.org Wed Apr 1 11:50:02 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 11:50:04 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.802.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.802.mcz ==================== Summary ==================== Name: Morphic-mt.802 Author: mt Time: 1 April 2015, 1:49:26.461 pm UUID: 86843cf8-a4d3-104e-baa1-d6004e8e3013 Ancestors: Morphic-mt.801 Fixed layouting bug of horizontal scrollbar if vertical scroll bar is on the left. =============== Diff against Morphic-mt.801 =============== Item was changed: ----- Method: ScrollPane>>hResizeScrollBar (in category 'geometry') ----- hResizeScrollBar + | topLeft h border offset | - | topLeft h border | "TEMPORARY: IF OLD SCROLLPANES LYING AROUND THAT DON'T HAVE A hScrollBar, INIT THEM" hScrollBar ifNil: [ self hInitScrollBarTEMPORARY]. (self valueOfProperty: #noHScrollBarPlease ifAbsent: [false]) ifTrue: [^self]. bounds ifNil: [ self fullBounds ]. h := self scrollBarThickness. border := borderWidth. + offset := scrollBarOnLeft ifTrue: [h] ifFalse: [0]. topLeft := retractableScrollBar + ifTrue: [bounds bottomLeft + (border + offset @ border negated)] + ifFalse: [bounds bottomLeft + (border + offset @ (h + border) negated)]. - ifTrue: [bounds bottomLeft + (border @ border negated)] - ifFalse: [bounds bottomLeft + (border @ (h + border) negated)]. hScrollBar bounds: (topLeft + (-1@1) extent: self hScrollBarWidth@ h) ! From commits at source.squeak.org Wed Apr 1 12:01:16 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 12:01:17 2015 Subject: [squeak-dev] The Trunk: Kernel-topa.916.mcz Message-ID: Tobias Pape uploaded a new version of Kernel to project The Trunk: http://source.squeak.org/trunk/Kernel-topa.916.mcz ==================== Summary ==================== Name: Kernel-topa.916 Author: topa Time: 1 April 2015, 2:00:39.799 pm UUID: 8f05add4-c132-40ad-a4cc-a6131ec098f3 Ancestors: Kernel-topa.915 (same as before) Fix arguments access in WeakMessageSend =============== Diff against Kernel-topa.915 =============== Item was changed: ----- Method: WeakMessageSend>>withEnsuredReceiverAndArgumentsDo:otherwise: (in category 'private') ----- withEnsuredReceiverAndArgumentsDo: aBlock otherwise: altBlock "Grab real references to receiver and arguments. If they still exist, evaluate aBlock." "Return if my receiver has gone away" | r a | r := self receiver. r ifNil: [ ^altBlock value ]. "Make sure that my arguments haven't gone away" + a := Array withAll: self arguments. - a := Array withAll: arguments. a with: shouldBeNil do: [ :arg :flag | arg ifNil: [ flag ifFalse: [ ^altBlock value ]] ]. ^aBlock value: r value: a! From bert at freudenbergs.de Wed Apr 1 13:27:24 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Wed Apr 1 13:27:28 2015 Subject: [squeak-dev] Bug whith contextOn:do: In-Reply-To: References: <85F38DF9-1002-49A4-B11B-0DF96E0A7E76@gmx.de> Message-ID: <1AA83643-080E-4CA3-89ED-3C9F9876AFF1@freudenbergs.de> Skipped content of type multipart/alternative-------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150401/fe28310b/smime.bin From commits at source.squeak.org Wed Apr 1 14:34:53 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 14:34:55 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.111.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.111.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.111 Author: mt Time: 1 April 2015, 4:34:47.411 pm UUID: df7f741e-5af0-c14f-b019-03ed2d822fc9 Ancestors: ToolBuilder-Morphic-mt.110 Fixed should background-styling to update text morph runs only from within the morphic UI process. =============== Diff against ToolBuilder-Morphic-mt.110 =============== Item was changed: ----- Method: PluggableTextMorphPlus>>stylerStyledInBackground: (in category 'styling') ----- stylerStyledInBackground: styledCopyOfText "Sent after the styler completed styling of the text" "It is possible that the text string has changed since the styling began. Disregard the styles if styledCopyOfText's string differs with the current textMorph contents string" + Project current addDeferredUIMessage: [ + textMorph contents string = styledCopyOfText string + ifTrue: [self stylerStyled: styledCopyOfText]].! - textMorph contents string = styledCopyOfText string - ifTrue: [self stylerStyled: styledCopyOfText]! From commits at source.squeak.org Wed Apr 1 14:42:38 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 14:42:40 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.803.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.803.mcz ==================== Summary ==================== Name: Morphic-mt.803 Author: mt Time: 1 April 2015, 4:41:58.498 pm UUID: 2b489690-f83f-5e41-82a7-cfba13ce7e54 Ancestors: Morphic-mt.802 Recompose the paragraph if text or runs changed after keyboard input. We did not notice this bug because Shout/Tools did this in #stylerStyled:. Only some jerky scrolling behavior occured from time to time because the first text morph update (while Shout was background-styling) was without paragraph recomposition. =============== Diff against Morphic-mt.802 =============== Item was changed: ----- Method: TextMorph>>handleInteraction:fromEvent: (in category 'editing') ----- handleInteraction: interactionBlock fromEvent: evt "Perform the changes in interactionBlock, noting any change in selection and possibly a change in the size of the paragraph (ar 9/22/2001 - added for TextPrintIts)" | oldEditor oldParagraph oldText | oldEditor := editor. oldParagraph := paragraph. oldText := oldParagraph text copy. self selectionChanged. "Note old selection" interactionBlock value. (oldParagraph == paragraph) ifTrue:[ "this will not work if the paragraph changed" editor := oldEditor. "since it may have been changed while in block" ]. self selectionChanged. "Note new selection" (oldText = paragraph text and: [ oldText runs = paragraph text runs ]) + ifFalse:[ + self paragraph composeAll. + self updateFromParagraph ]. - ifFalse:[ self updateFromParagraph ]. self setCompositionWindow.! From commits at source.squeak.org Wed Apr 1 14:44:43 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 14:44:44 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.804.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.804.mcz ==================== Summary ==================== Name: Morphic-mt.804 Author: mt Time: 1 April 2015, 4:44:05.045 pm UUID: bbe870c0-cd4a-4f4d-b12a-7da72c2e797e Ancestors: Morphic-mt.803 Another fix for horizontal scroll bars in scroll panes, which affects layouting and scrolling. =============== Diff against Morphic-mt.803 =============== Item was changed: ----- Method: ScrollPane>>hLeftoverScrollRange (in category 'geometry') ----- hLeftoverScrollRange "Return the entire scrolling range minus the currently viewed area." | w | scroller hasSubmorphs ifFalse:[^0]. w := bounds width. self vIsScrollbarShowing ifTrue:[ w := w - self scrollBarThickness ]. + ^ (self hTotalScrollRange - w roundTo: self scrollDeltaWidth) max: 0 - ^ (self hTotalScrollRange - w roundTo: self scrollDeltaHeight) max: 0 ! Item was changed: ----- Method: ScrollPane>>hResizeScrollBar (in category 'geometry') ----- hResizeScrollBar | topLeft h border offset | "TEMPORARY: IF OLD SCROLLPANES LYING AROUND THAT DON'T HAVE A hScrollBar, INIT THEM" hScrollBar ifNil: [ self hInitScrollBarTEMPORARY]. (self valueOfProperty: #noHScrollBarPlease ifAbsent: [false]) ifTrue: [^self]. bounds ifNil: [ self fullBounds ]. h := self scrollBarThickness. border := borderWidth. + offset := (scrollBarOnLeft and: [self vIsScrollbarShowing]) + ifTrue: [h] + ifFalse: [0]. - offset := scrollBarOnLeft ifTrue: [h] ifFalse: [0]. topLeft := retractableScrollBar ifTrue: [bounds bottomLeft + (border + offset @ border negated)] ifFalse: [bounds bottomLeft + (border + offset @ (h + border) negated)]. hScrollBar bounds: (topLeft + (-1@1) extent: self hScrollBarWidth@ h) ! From commits at source.squeak.org Wed Apr 1 16:10:00 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 16:10:02 2015 Subject: [squeak-dev] The Trunk: Tools-cmm.570.mcz Message-ID: Chris Muller uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-cmm.570.mcz ==================== Summary ==================== Name: Tools-cmm.570 Author: cmm Time: 1 April 2015, 11:09:22.929 am UUID: 7827a351-1a4d-4e83-bbef-7e900993ee62 Ancestors: Tools-mt.569 - SimpleHierarchicalListMorph's now honor preferences: mouseOverForKeyboardFocus Vertical Smart Splitters Filterable Lists Clear Automatically - After filtering Tree, refit the column-widths to the filtered results. =============== Diff against Tools-mt.569 =============== Item was added: + ----- Method: IndentingListItemMorph>>charactersOccluded (in category 'private') ----- + charactersOccluded + "Answer the number of characters occluded in my #visibleList by my right edge." + | listIndex leftEdgeOfRightmostColumn eachString indexOfLastVisible iconWidth totalWidth | + listIndex := 0. + leftEdgeOfRightmostColumn := container columns + ifNil: [ 0 ] + ifNotNil: + [ : cols | (1 to: cols size - 1) + inject: 0 + into: + [ : sum : each | sum + (self widthOfColumn: each) ] ]. + eachString := container columns + ifNil: [ self complexContents asString ] + ifNotNil: + [ : cols | self contentsAtColumn: container columns size ]. + iconWidth := self icon + ifNil: [ 0 ] + ifNotNil: + [ : icon | icon width + 2 ]. + totalWidth := self toggleBounds right. + indexOfLastVisible := ((1 to: eachString size) + detect: + [ : stringIndex | (totalWidth:=totalWidth+(self fontToUse widthOf: (eachString at: stringIndex))) > + (container width - + (container scrollBar + ifNil: [ 0 ] + ifNotNil: [ container scrollBar width ]) - iconWidth - leftEdgeOfRightmostColumn) ] + ifNone: [ eachString size + 1 ]) - 1. + ^ eachString size - indexOfLastVisible! Item was changed: ----- Method: IndentingListItemMorph>>drawOn: (in category 'drawing') ----- drawOn: aCanvas | tRect sRect columnScanner columnLeft | self backgroundColor ifNotNil: [:c | aCanvas fillRectangle: self innerBounds color: c]. tRect := self toggleRectangle. self drawToggleOn: aCanvas in: tRect. sRect := bounds withLeft: tRect right + 4. sRect := sRect top: sRect top + sRect bottom - self fontToUse height // 2. (container columns isNil or: [(contents asString indexOf: Character tab) = 0]) ifTrue: [ icon ifNotNil: [ aCanvas translucentImage: icon at: sRect left @ (self top + (self height - icon height // 2)). sRect := sRect left: sRect left + icon width + 2. ]. aCanvas drawString: contents asString in: sRect font: self fontToUse color: color. ] ifFalse: [ columnLeft := sRect left. columnScanner := ReadStream on: contents asString. container columns withIndexDo: [ :widthSpec :column | | columnRect columnData columnWidth | "Draw icon." column = self class iconColumnIndex ifTrue: [ icon ifNotNil: [ aCanvas translucentImage: icon at: columnLeft @ (self top + (self height - icon height // 2)). columnLeft := columnLeft + icon width + 2]]. + columnWidth := self widthOfColumn: column. - columnWidth := widthSpec isNumber - ifTrue: [widthSpec] - ifFalse: [widthSpec isBlock - ifTrue: [widthSpec cull: container cull: self] - ifFalse: [widthSpec ifNil: [self width] ifNotNil: [50 "Fall back"]]]. columnRect := columnLeft @ sRect top extent: columnWidth @ sRect height. columnData := columnScanner upTo: Character tab. "Draw string." columnData ifNotEmpty: [ aCanvas drawString: columnData in: columnRect font: self fontToUse color: color]. "Compute next column offset." columnLeft := columnRect right + 5. column = 1 ifTrue: [columnLeft := columnLeft - tRect right + self left]. ]. ]! Item was added: + ----- Method: IndentingListItemMorph>>widthOfColumn: (in category 'accessing - columns') ----- + widthOfColumn: columnIndex + | widthOrSpec | + container columns ifNil: [ ^ self width ]. + widthOrSpec := container columns at: columnIndex. + ^ widthOrSpec isNumber + ifTrue: [ widthOrSpec ] + ifFalse: + [ widthOrSpec isBlock + ifTrue: + [ widthOrSpec + cull: container + cull: self ] + ifFalse: + [ widthOrSpec + ifNil: [ self width ] + ifNotNil: [ "Fall back" + 50 ] ] ]! Item was changed: ----- Method: ObjectExplorer>>buildWith: (in category 'toolbuilder') ----- buildWith: builder | windowSpec treeSpec textSpec | windowSpec := builder pluggableWindowSpec new. windowSpec model: self; children: OrderedCollection new; label: #label. treeSpec := builder pluggableTreeSpec new. treeSpec model: self; nodeClass: self class nodeClass; roots: #getList; keyPress: #explorerKey:from:event:; getSelected: #currentSelection; setSelected: #currentSelection:; setSelectedParent: #currentParent:; menu: #genericMenu:; autoDeselect: false; columns: (ObjectExplorerWrapper showContentsInColumns ifTrue: [{ + [:listMorph | (listMorph filteredItems collect: [:item | - [:listMorph | (listMorph scroller submorphs collect: [:item | item preferredWidthOfColumn: 1]) max]. + nil "take all the space"}]); - nil "take all the space"}] - ifFalse: []); frame: (0@0 corner: 1@0.85). windowSpec children add: treeSpec. textSpec := builder pluggableTextSpec new. textSpec model: self; menu: #codePaneMenu:shifted:; help: 'Evaluate expressions for the current tree selection...' translated; frame: (0@0.85 corner: 1@1). windowSpec children add: textSpec. ^ builder build: windowSpec! From commits at source.squeak.org Wed Apr 1 16:12:34 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 16:12:36 2015 Subject: [squeak-dev] The Trunk: Morphic-cmm.805.mcz Message-ID: Chris Muller uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-cmm.805.mcz ==================== Summary ==================== Name: Morphic-cmm.805 Author: cmm Time: 1 April 2015, 11:11:23.537 am UUID: 2667ac2e-7e09-4a67-8efe-2da1a499f090 Ancestors: Morphic-mt.804 - SimpleHierarchicalListMorph's now honor preferences: mouseOverForKeyboardFocus Vertical Smart Splitters - Don't let splitter bars be dragged further than their PluggableListMorphs want them to go. - PluggableTextMorph's now honor Vertical Smart Splitters to avoid wrapped lines, if possible. =============== Diff against Morphic-mt.804 =============== Item was added: + ----- Method: MorphicModel>>charactersOccluded (in category 'geometry') ----- + charactersOccluded + "Subclasses override as necessary to keep smart-splitters balanced." + ^ 0! Item was changed: + ----- Method: MorphicModel>>model (in category 'accessing') ----- - ----- Method: MorphicModel>>model (in category 'access') ----- model ^ model! Item was changed: + ----- Method: MorphicModel>>slotName (in category 'accessing') ----- - ----- Method: MorphicModel>>slotName (in category 'access') ----- slotName ^ slotName! Item was changed: + ----- Method: MorphicModel>>wantsSlot (in category 'accessing') ----- - ----- Method: MorphicModel>>wantsSlot (in category 'access') ----- wantsSlot "Override this default for models that want to be installed in theri model" ^ false! Item was changed: + ----- Method: PluggableListMorph>>charactersOccluded (in category 'geometry') ----- - ----- Method: PluggableListMorph>>charactersOccluded (in category 'accessing') ----- charactersOccluded "Answer the number of characters occluded in my #visibleList by my right edge." | listIndex | listIndex:=0. ^ self visibleList inject: 0 into: [ : sum : each | | eachString totalWidth indexOfLastVisible iconWidth | totalWidth:=0. eachString := each asString "withBlanksTrimmed". iconWidth := (self iconAt: (listIndex := listIndex+1)) ifNil:[0] ifNotNil: [ : icon | icon width+2 ]. indexOfLastVisible := ((1 to: eachString size) detect: [ : stringIndex | (totalWidth:=totalWidth+(self font widthOf: (eachString at: stringIndex))) > (self width - (scrollBar ifNil: [ 0 ] ifNotNil: [ scrollBar width ]) - iconWidth) ] ifNone: [ eachString size + 1 ]) - 1. sum + (eachString size - indexOfLastVisible) ]! Item was changed: ----- Method: PluggableListMorph>>iconAt: (in category 'model access') ----- iconAt: anInteger | index | index := (self hasFilter and: [list notNil]) + ifTrue: [self getFullList indexOf: (list at: anInteger ifAbsent: [^nil])] - ifTrue: [self getFullList indexOf: (list at: anInteger)] ifFalse: [anInteger]. ^ getIconSelector ifNotNil: [model perform: getIconSelector with: index]! Item was added: + ----- Method: PluggableListMorph>>initialize (in category 'geometry') ----- + initialize + super initialize. + self minWidth: 38! Item was added: + ----- Method: PluggableTextMorph>>charactersOccluded (in category 'geometry') ----- + charactersOccluded + "Let the receiver suggest to its neighboring vertical Splitter(s) that they try to optimize their position such that none of the receivers lines need to wrap." + | numberOfLogicalLines numberOfPhysicalLines | + numberOfLogicalLines := self text lineCount. + numberOfPhysicalLines:= textMorph paragraph numberOfLines. + ^ numberOfPhysicalLines - numberOfLogicalLines! Item was changed: ----- Method: ProportionalSplitterMorph>>charactersOccludedIn: (in category 'layout') ----- charactersOccludedIn: aCollection ^ aCollection inject: 0 into: [ : max : each | max max: + (each isMorphicModel - (each isPluggableListMorph ifTrue: [ each charactersOccluded ] ifFalse: [ 0 ]) ]! Item was added: + ----- Method: ScrollPane>>scrollBar (in category 'testing') ----- + scrollBar + ^ scrollBar! Item was added: + ----- Method: SimpleHierarchicalListMorph>>mouseLeave: (in category 'event handling') ----- + mouseLeave: aMouseEvent + super mouseLeave: aMouseEvent. + Preferences mouseOverForKeyboardFocus ifTrue: [ aMouseEvent hand releaseKeyboardFocus: self ]! From commits at source.squeak.org Wed Apr 1 16:12:43 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 16:12:46 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-cmm.109.mcz Message-ID: Chris Muller uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-cmm.109.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-cmm.109 Author: cmm Time: 1 April 2015, 11:12:32.023 am UUID: 109fa949-8213-4e07-855c-90ad83b6ab07 Ancestors: ToolBuilder-Morphic-mt.111 - PluggableTreeMorph support for Vertical Smart Splitters. - Let single-level filtering also be a navigation gesture. - After filtering a Tree, refit the column-widths to the filtered results. - SimpleHierarchicalListMorph support mouseOverForKeyboardFocus. - Fix selection rendering in PluggableTreeMorph (FileList and SqueakMap). =============== Diff against ToolBuilder-Morphic-mt.111 =============== Item was added: + ----- Method: PluggableTreeMorph>>bottomVisibleRowIndex (in category 'geometry') ----- + bottomVisibleRowIndex + | itemAtBottom | + itemAtBottom := self itemFromPoint: self bottomLeft + (3 @ -3). + ^ itemAtBottom + ifNil: [ scroller submorphs size ] + ifNotNil: + [ : item | scroller submorphs indexOf: item ]! Item was added: + ----- Method: PluggableTreeMorph>>charactersOccluded (in category 'geometry') ----- + charactersOccluded + ^ self visibleItems + inject: 0 + into: + [ : sum : each | sum + each charactersOccluded ]! Item was changed: ----- Method: PluggableTreeMorph>>filterTree (in category 'filtering') ----- filterTree + self hasFilter ifFalse: + [ self removeFilter. + ^ self ]. - - self hasFilter ifFalse: [ - self removeFilter. - ^ self]. - self indicateFiltered. - "Clean up the tree." (self selectedMorph + ifNil: [ self roots ] + ifNotNil: + [ : m | {m} ]) do: + [ : item | | filteredItems | + item applyFilter: lastKeystrokes. + item visible ifFalse: + [ "Do not hide the item where the filter is based on." + item show. + item isExpanded ifFalse: [ item toggleExpandedState ] ]. + filteredItems := self filteredItems. + "If configured as a navigation tool, advance the selection." + (PluggableTreeMorph maximumSearchDepth = 1 and: [ PluggableTreeMorph filterByLabelsOnly not ]) ifTrue: + [ (filteredItems notEmpty and: [ selectedMorph ~= filteredItems last ]) ifTrue: + [ self setSelectedMorph: (filteredItems after: selectedMorph). + selectedMorph isExpanded ifFalse: [ selectedMorph toggleExpandedState ] ] ] ]. + self adjustSubmorphPositions! - ifNil: [self roots] - ifNotNil: [:m | {m}]) do: [:item | - item applyFilter: lastKeystrokes. - item visible ifFalse: [ - "Do not hide the item where the filter is based on." - item show. - item isExpanded ifTrue: [item toggleExpandedState]]]. - - self adjustSubmorphPositions.! Item was added: + ----- Method: PluggableTreeMorph>>filteredItems (in category 'filtering') ----- + filteredItems + "Answer the items which visible because they matched the current filters." + ^ self items select: [ : each | each visible ]! Item was added: + ----- Method: PluggableTreeMorph>>items (in category 'accessing') ----- + items + ^ scroller submorphs! Item was added: + ----- Method: PluggableTreeMorph>>keyboardFocusChange: (in category 'event handling') ----- + keyboardFocusChange: aBoolean + aBoolean ifFalse: + [ PluggableListMorph clearFilterAutomatically ifTrue: + [ self hasFilter ifTrue: [ self removeFilter ] ] ]! Item was changed: ----- Method: PluggableTreeMorph>>selectPath:in: (in category 'selection') ----- selectPath: path in: listItem path isEmpty ifTrue: [^self setSelectedMorph: nil]. listItem withSiblingsDo: [:each | (each complexContents item = path first) ifTrue: [ each isExpanded ifFalse: [ each toggleExpandedState. self adjustSubmorphPositions. ]. each changed. path size = 1 ifTrue: [ ^self setSelectedMorph: each ]. each firstChild ifNil: [^self setSelectedMorph: nil]. ^self selectPath: path allButFirst in: each firstChild ]. ]. ^self setSelectedMorph: nil ! Item was changed: ----- Method: PluggableTreeMorph>>setSelectedMorph: (in category 'selection') ----- setSelectedMorph: aMorph selectedWrapper := aMorph complexContents. + self selection: selectedWrapper. - "Let the model now about the selected object, not wrapper." setSelectionSelector ifNotNil: [:symbol | model perform: symbol + with: (selectedWrapper ifNotNil: [ selectedWrapper item ])]. - with: (selectedWrapper ifNotNil: [:w | w item])]. "The model may not have access to the parent object in terms of this tree structure." setSelectedParentSelector ifNotNil: [:symbol | model perform: symbol + with: (selectedWrapper ifNotNil: [selectedWrapper parent ifNotNil: [: parentWrapper | parentWrapper item]])].! - with: (selectedWrapper ifNotNil: [:w | w parent ifNotNil: [:pw | pw item]])].! Item was added: + ----- Method: PluggableTreeMorph>>topVisibleRowIndex (in category 'geometry') ----- + topVisibleRowIndex + ^ scroller submorphs indexOf: (self itemFromPoint: self topLeft+(3@3))! Item was added: + ----- Method: PluggableTreeMorph>>visibleItems (in category 'geometry') ----- + visibleItems + ^ self items + copyFrom: self topVisibleRowIndex + to: self bottomVisibleRowIndex! From commits at source.squeak.org Wed Apr 1 16:13:50 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 16:13:52 2015 Subject: [squeak-dev] The Trunk: Tools-cmm.569.mcz Message-ID: Chris Muller uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-cmm.569.mcz ==================== Summary ==================== Name: Tools-cmm.569 Author: cmm Time: 1 April 2015, 11:13:09.646 am UUID: 71088346-ff2c-4086-8042-bf3407e20986 Ancestors: Tools-cmm.570 - SimpleHierarchicalListMorph's now honor preferences: mouseOverForKeyboardFocus Vertical Smart Splitters Filterable Lists Clear Automatically - After filtering Tree, refit the column-widths to the filtered results. =============== Diff against Tools-cmm.570 =============== From commits at source.squeak.org Wed Apr 1 16:13:52 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 16:13:54 2015 Subject: [squeak-dev] The Trunk: Morphic-cmm.798.mcz Message-ID: Chris Muller uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-cmm.798.mcz ==================== Summary ==================== Name: Morphic-cmm.798 Author: cmm Time: 1 April 2015, 11:12:43.922 am UUID: b125e333-58b0-4a00-985f-846891e8e046 Ancestors: Morphic-cmm.805 - SimpleHierarchicalListMorph's now honor preferences: mouseOverForKeyboardFocus Vertical Smart Splitters - Don't let splitter bars be dragged further than their PluggableListMorphs want them to go. - PluggableTextMorph's now honor Vertical Smart Splitters to avoid wrapped lines, if possible. =============== Diff against Morphic-cmm.805 =============== Item was added: + ----- Method: ScrollPane>>hasScrollBar (in category 'testing') ----- + hasScrollBar + ^ scrollBar isInWorld! From leves at elte.hu Wed Apr 1 16:26:23 2015 From: leves at elte.hu (Levente Uzonyi) Date: Wed Apr 1 16:26:27 2015 Subject: ObjectExplorer broken (was: Re: [squeak-dev] The Trunk: Tools-cmm.570.mcz) In-Reply-To: References: Message-ID: ObjectExplorer>>buildWith: sends #filteredItems, but there are no implementors in my Trunk image. It breaks ObjectExplorer. To reproduce it evaluate [1 explore]. Levente On Wed, 1 Apr 2015, commits@source.squeak.org wrote: > Chris Muller uploaded a new version of Tools to project The Trunk: > http://source.squeak.org/trunk/Tools-cmm.570.mcz > > ==================== Summary ==================== > > Name: Tools-cmm.570 > Author: cmm > Time: 1 April 2015, 11:09:22.929 am > UUID: 7827a351-1a4d-4e83-bbef-7e900993ee62 > Ancestors: Tools-mt.569 > > - SimpleHierarchicalListMorph's now honor preferences: > mouseOverForKeyboardFocus > Vertical Smart Splitters > Filterable Lists Clear Automatically > - After filtering Tree, refit the column-widths to the filtered results. > > =============== Diff against Tools-mt.569 =============== > > Item was changed: > ----- Method: ObjectExplorer>>buildWith: (in category 'toolbuilder') ----- > buildWith: builder > > | windowSpec treeSpec textSpec | > windowSpec := builder pluggableWindowSpec new. > windowSpec > model: self; > children: OrderedCollection new; > label: #label. > > treeSpec := builder pluggableTreeSpec new. > treeSpec > model: self; > nodeClass: self class nodeClass; > roots: #getList; > keyPress: #explorerKey:from:event:; > getSelected: #currentSelection; > setSelected: #currentSelection:; > setSelectedParent: #currentParent:; > menu: #genericMenu:; > autoDeselect: false; > columns: (ObjectExplorerWrapper showContentsInColumns > ifTrue: [{ > + [:listMorph | (listMorph filteredItems collect: [:item | > - [:listMorph | (listMorph scroller submorphs collect: [:item | > item preferredWidthOfColumn: 1]) max]. > + nil "take all the space"}]); > - nil "take all the space"}] > - ifFalse: []); > frame: (0@0 corner: 1@0.85). > windowSpec children add: treeSpec. > > textSpec := builder pluggableTextSpec new. > textSpec > model: self; > menu: #codePaneMenu:shifted:; > help: 'Evaluate expressions for the current tree selection...' translated; > frame: (0@0.85 corner: 1@1). > windowSpec children add: textSpec. > > ^ builder build: windowSpec! > > > From leves at elte.hu Wed Apr 1 16:29:13 2015 From: leves at elte.hu (Levente Uzonyi) Date: Wed Apr 1 16:29:16 2015 Subject: [squeak-dev] The Trunk: Morphic-cmm.798.mcz In-Reply-To: References: Message-ID: The version number of this package is less than its ancestor's. The same is true for ToolBuilder-Morphic-cmm.109, and Tools-cmm.569.mcz. I don't think all tools - including the update mechanism - are prepared for this. Is it intentional? Levente On Wed, 1 Apr 2015, commits@source.squeak.org wrote: > Chris Muller uploaded a new version of Morphic to project The Trunk: > http://source.squeak.org/trunk/Morphic-cmm.798.mcz > > ==================== Summary ==================== > > Name: Morphic-cmm.798 > Author: cmm > Time: 1 April 2015, 11:12:43.922 am > UUID: b125e333-58b0-4a00-985f-846891e8e046 > Ancestors: Morphic-cmm.805 > > - SimpleHierarchicalListMorph's now honor preferences: > mouseOverForKeyboardFocus > Vertical Smart Splitters > - Don't let splitter bars be dragged further than their PluggableListMorphs want them to go. > - PluggableTextMorph's now honor Vertical Smart Splitters to avoid wrapped lines, if possible. > > =============== Diff against Morphic-cmm.805 =============== > > Item was added: > + ----- Method: ScrollPane>>hasScrollBar (in category 'testing') ----- > + hasScrollBar > + ^ scrollBar isInWorld! > > > From marcel.taeumel at student.hpi.uni-potsdam.de Wed Apr 1 16:19:47 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Wed Apr 1 16:31:29 2015 Subject: ObjectExplorer broken (was: Re: [squeak-dev] The Trunk: Tools-cmm.570.mcz) In-Reply-To: References: Message-ID: <1427905187920-4816701.post@n4.nabble.com> SimpleHierarchicalListMorph-filteredItems.st Try this until Chris commits a fix. I assume he just forgot but I don't want to create a conflict in case he commits it any second. :) If nothing happens, I will commit that later. Best, Marcel -- View this message in context: http://forum.world.st/ObjectExplorer-broken-was-Re-squeak-dev-The-Trunk-Tools-cmm-570-mcz-tp4816699p4816701.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From leves at elte.hu Wed Apr 1 16:33:46 2015 From: leves at elte.hu (Levente Uzonyi) Date: Wed Apr 1 16:33:51 2015 Subject: ObjectExplorer broken (was: Re: [squeak-dev] The Trunk: Tools-cmm.570.mcz) In-Reply-To: <1427905187920-4816701.post@n4.nabble.com> References: <1427905187920-4816701.post@n4.nabble.com> Message-ID: It's broken, because the update mechanism is not prepared for decreasing version numbers. Manual loading of the latest packages fixes the problem. Levente On Wed, 1 Apr 2015, Marcel Taeumel wrote: > SimpleHierarchicalListMorph-filteredItems.st > > > Try this until Chris commits a fix. I assume he just forgot but I don't want > to create a conflict in case he commits it any second. :) If nothing > happens, I will commit that later. > > Best, > Marcel > > > > -- > View this message in context: http://forum.world.st/ObjectExplorer-broken-was-Re-squeak-dev-The-Trunk-Tools-cmm-570-mcz-tp4816699p4816701.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > From eliot.miranda at gmail.com Wed Apr 1 16:33:59 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Wed Apr 1 16:34:01 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.794.mcz In-Reply-To: <1427870218443-4816550.post@n4.nabble.com> References: <1427870148845-4816549.post@n4.nabble.com> <1427870218443-4816550.post@n4.nabble.com> Message-ID: On Tue, Mar 31, 2015 at 11:36 PM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > Seems like that Morphic should be loaded *before* MorphicExtras anyway. Can > we fix that in the update map? > That's right. Yes. If you construct an image with the state before the updated MorphicExtras is loaded and save that configuration as an update map that will take care of things. > > Best, > Marcel > > > > -- > View this message in context: > http://forum.world.st/The-Trunk-Morphic-mt-794-mcz-tp4816304p4816550.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150401/0334edaf/attachment.htm From eliot.miranda at gmail.com Wed Apr 1 16:37:28 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Wed Apr 1 16:37:30 2015 Subject: [Vm-dev] Re: [squeak-dev] Bug whith contextOn:do: In-Reply-To: <1AA83643-080E-4CA3-89ED-3C9F9876AFF1@freudenbergs.de> References: <85F38DF9-1002-49A4-B11B-0DF96E0A7E76@gmx.de> <1AA83643-080E-4CA3-89ED-3C9F9876AFF1@freudenbergs.de> Message-ID: On Wed, Apr 1, 2015 at 6:27 AM, Bert Freudenberg wrote: > > On 31.03.2015, at 23:10, Eliot Miranda wrote: > > > I'm not sure the other ways are any better. The way to transfer to a > context without disturbing its stack is to do a process switch. > > [...] > > One of the advantages the process switch versions have is in not > updating the receiving context sp there's a chance the context-to-stack > mapping machinery won't flush the context to the heap. In the end it might > actually be faster. > > > I would find it very surprising if #jump would result in the execution > continuing in a different process. > That's not what they do. Instead they spawn another process to position the process in which we want to jump correctly. > > - Bert - > > > -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150401/dbe7fda4/attachment.htm From Das.Linux at gmx.de Wed Apr 1 16:49:57 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Wed Apr 1 16:50:01 2015 Subject: [Vm-dev] Re: [squeak-dev] Bug whith contextOn:do: In-Reply-To: References: <85F38DF9-1002-49A4-B11B-0DF96E0A7E76@gmx.de> <1AA83643-080E-4CA3-89ED-3C9F9876AFF1@freudenbergs.de> Message-ID: <1E90C927-7C12-4E98-9CFB-96C60D491FCD@gmx.de> On 01.04.2015, at 18:37, Eliot Miranda wrote: > On Wed, Apr 1, 2015 at 6:27 AM, Bert Freudenberg wrote: > > On 31.03.2015, at 23:10, Eliot Miranda wrote: >> >> I'm not sure the other ways are any better. The way to transfer to a context without disturbing its stack is to do a process switch. >> [...] >> One of the advantages the process switch versions have is in not updating the receiving context sp there's a chance the context-to-stack mapping machinery won't flush the context to the heap. In the end it might actually be faster. > > I would find it very surprising if #jump would result in the execution continuing in a different process. > > That's not what they do. Instead they spawn another process to position the process in which we want to jump correctly. We don't want to jump to a process but within a process, like a goto? What about thread/process-local variables? Best -Tobias From Das.Linux at gmx.de Wed Apr 1 16:50:11 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Wed Apr 1 16:50:15 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.794.mcz In-Reply-To: References: <1427870148845-4816549.post@n4.nabble.com> <1427870218443-4816550.post@n4.nabble.com> Message-ID: <492844E7-246F-4C3F-9CF4-9918E235C1CC@gmx.de> On 01.04.2015, at 18:33, Eliot Miranda wrote: > On Tue, Mar 31, 2015 at 11:36 PM, Marcel Taeumel wrote: > Seems like that Morphic should be loaded *before* MorphicExtras anyway. Can > we fix that in the update map? > > That's right. Yes. If you construct an image with the state before the updated MorphicExtras is loaded and save that configuration as an update map that will take care of things. I took care of that :) Best -Tobias From marcel.taeumel at student.hpi.uni-potsdam.de Wed Apr 1 16:39:13 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Wed Apr 1 16:50:55 2015 Subject: [squeak-dev] Re: The Trunk: ToolBuilder-Morphic-cmm.109.mcz In-Reply-To: References: Message-ID: <1427906353271-4816713.post@n4.nabble.com> Hey Chris, yay, we need to strive for more consistency in the tools. This is a step in the right direction. :-) Here are some minor remarks: #setSelectedMorph: - Calling #selection: from within that is against the rules. This is only called as a reaction to model change. See #update:. #filterTree - Maybe we should not filter the children of the current selection but start with the siblings? Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-ToolBuilder-Morphic-cmm-109-mcz-tp4816694p4816713.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Wed Apr 1 16:43:53 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Wed Apr 1 16:55:35 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-cmm.798.mcz In-Reply-To: References: Message-ID: <1427906633088-4816715.post@n4.nabble.com> This interface already exists in a more complete way in ScrollPane: #vIsScrollbarShowing #hIsScrollbarShowing Do we need another one? ;-) Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-cmm-798-mcz-tp4816696p4816715.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Wed Apr 1 17:10:36 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 17:10:38 2015 Subject: [squeak-dev] The Trunk: Tools-cmm.571.mcz Message-ID: Chris Muller uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-cmm.571.mcz ==================== Summary ==================== Name: Tools-cmm.571 Author: cmm Time: 1 April 2015, 12:10:04.556 pm UUID: 6d41ac47-656c-4e3c-adab-5df3d7291e5a Ancestors: Tools-cmm.569 Resaving package as highest version number to support proper trunk updating. =============== Diff against Tools-cmm.569 =============== From commits at source.squeak.org Wed Apr 1 17:14:48 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 17:14:50 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-cmm.112.mcz Message-ID: Chris Muller uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-cmm.112.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-cmm.112 Author: cmm Time: 1 April 2015, 12:14:39.892 pm UUID: a11fe5c1-5cbc-4be6-ade1-6f4adb5ff192 Ancestors: ToolBuilder-Morphic-cmm.109 Resaving package with highest version # to support proper trunk update. =============== Diff against ToolBuilder-Morphic-cmm.109 =============== From eliot.miranda at gmail.com Wed Apr 1 18:51:18 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Wed Apr 1 18:51:21 2015 Subject: [Vm-dev] Re: [squeak-dev] Bug whith contextOn:do: In-Reply-To: <1E90C927-7C12-4E98-9CFB-96C60D491FCD@gmx.de> References: <85F38DF9-1002-49A4-B11B-0DF96E0A7E76@gmx.de> <1AA83643-080E-4CA3-89ED-3C9F9876AFF1@freudenbergs.de> <1E90C927-7C12-4E98-9CFB-96C60D491FCD@gmx.de> Message-ID: On Wed, Apr 1, 2015 at 9:49 AM, Tobias Pape wrote: > > On 01.04.2015, at 18:37, Eliot Miranda wrote: > > > On Wed, Apr 1, 2015 at 6:27 AM, Bert Freudenberg > wrote: > > > > On 31.03.2015, at 23:10, Eliot Miranda wrote: > >> > >> I'm not sure the other ways are any better. The way to transfer to a > context without disturbing its stack is to do a process switch. > >> [...] > >> One of the advantages the process switch versions have is in not > updating the receiving context sp there's a chance the context-to-stack > mapping machinery won't flush the context to the heap. In the end it might > actually be faster. > > > > I would find it very surprising if #jump would result in the execution > continuing in a different process. > > > > That's not what they do. Instead they spawn another process to position > the process in which we want to jump correctly. > > We don't want to jump to a process but within a process, like a goto? > Well, jump doesn't do unwinds so the code should be simply: jump "Abandon thisContext and resume self instead (using the same current process)." | process | process := Processor activeProcess. [process suspendedContext: self] fork. Processor yield What about thread/process-local variables? > Happy now? -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150401/c1f21b63/attachment.htm From commits at source.squeak.org Wed Apr 1 19:40:06 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 19:40:09 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-cmm.113.mcz Message-ID: Chris Muller uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-cmm.113.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-cmm.113 Author: cmm Time: 1 April 2015, 2:39:58.323 pm UUID: 85dfc77a-e0ca-47b4-b633-ac05b10332a8 Ancestors: ToolBuilder-Morphic-cmm.112 - Filter-navigation DNU when there is no selection. Filtering still needs to be figured out for the roots of a tree... - Restore Marcel's latest selectPath:in: from today. - Don't rely on #selection: from setSelectedMorph: to fix selection-rendering in UI's, instead we should be sending proper changed notifications from each model. =============== Diff against ToolBuilder-Morphic-cmm.112 =============== Item was changed: ----- Method: PluggableTreeMorph>>filterTree (in category 'filtering') ----- filterTree self hasFilter ifFalse: [ self removeFilter. ^ self ]. self indicateFiltered. "Clean up the tree." (self selectedMorph ifNil: [ self roots ] ifNotNil: [ : m | {m} ]) do: [ : item | | filteredItems | item applyFilter: lastKeystrokes. item visible ifFalse: [ "Do not hide the item where the filter is based on." item show. item isExpanded ifFalse: [ item toggleExpandedState ] ]. filteredItems := self filteredItems. "If configured as a navigation tool, advance the selection." (PluggableTreeMorph maximumSearchDepth = 1 and: [ PluggableTreeMorph filterByLabelsOnly not ]) ifTrue: + [ |toBeExpanded| + (filteredItems notEmpty and: [ selectedMorph ~= filteredItems last ]) ifTrue: + [ self setSelectedMorph: + (toBeExpanded := selectedMorph + ifNil: [ filteredItems first ] + ifNotNil: [ filteredItems after: selectedMorph ]). + toBeExpanded isExpanded ifFalse: [ toBeExpanded toggleExpandedState ] ] ] ]. - [ (filteredItems notEmpty and: [ selectedMorph ~= filteredItems last ]) ifTrue: - [ self setSelectedMorph: (filteredItems after: selectedMorph). - selectedMorph isExpanded ifFalse: [ selectedMorph toggleExpandedState ] ] ] ]. self adjustSubmorphPositions! Item was changed: ----- Method: PluggableTreeMorph>>selectPath:in: (in category 'selection') ----- selectPath: path in: listItem + path isEmpty ifTrue: [^self selection: nil]. + - path isEmpty ifTrue: [^self setSelectedMorph: nil]. listItem withSiblingsDo: [:each | (each complexContents item = path first) ifTrue: [ each isExpanded ifFalse: [ each toggleExpandedState. self adjustSubmorphPositions. ]. each changed. path size = 1 ifTrue: [ + ^self selection: each complexContents - ^self setSelectedMorph: each ]. + each firstChild ifNil: [^self selection: nil]. - each firstChild ifNil: [^self setSelectedMorph: nil]. ^self selectPath: path allButFirst in: each firstChild ]. ]. + ^self selection: nil - ^self setSelectedMorph: nil ! Item was changed: ----- Method: PluggableTreeMorph>>setSelectedMorph: (in category 'selection') ----- setSelectedMorph: aMorph selectedWrapper := aMorph complexContents. - self selection: selectedWrapper. "Let the model now about the selected object, not wrapper." setSelectionSelector ifNotNil: [:symbol | model perform: symbol with: (selectedWrapper ifNotNil: [ selectedWrapper item ])]. - "The model may not have access to the parent object in terms of this tree structure." setSelectedParentSelector ifNotNil: [:symbol | model perform: symbol with: (selectedWrapper ifNotNil: [selectedWrapper parent ifNotNil: [: parentWrapper | parentWrapper item]])].! From commits at source.squeak.org Wed Apr 1 19:44:20 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 19:44:23 2015 Subject: [squeak-dev] The Trunk: Tools-cmm.572.mcz Message-ID: Chris Muller uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-cmm.572.mcz ==================== Summary ==================== Name: Tools-cmm.572 Author: cmm Time: 1 April 2015, 2:43:55.003 pm UUID: cc792d4a-a258-496c-bffe-ad6db90b52b6 Ancestors: Tools-cmm.571 - Fix test for scrollbar presence for Vertical Smart Splitter support. - Fix "Reuse Windows" preference for ObjectExplorers. =============== Diff against Tools-cmm.571 =============== Item was changed: ----- Method: IndentingListItemMorph>>charactersOccluded (in category 'private') ----- charactersOccluded "Answer the number of characters occluded in my #visibleList by my right edge." | listIndex leftEdgeOfRightmostColumn eachString indexOfLastVisible iconWidth totalWidth | listIndex := 0. leftEdgeOfRightmostColumn := container columns ifNil: [ 0 ] ifNotNil: [ : cols | (1 to: cols size - 1) inject: 0 into: [ : sum : each | sum + (self widthOfColumn: each) ] ]. eachString := container columns ifNil: [ self complexContents asString ] ifNotNil: [ : cols | self contentsAtColumn: container columns size ]. iconWidth := self icon ifNil: [ 0 ] ifNotNil: [ : icon | icon width + 2 ]. totalWidth := self toggleBounds right. indexOfLastVisible := ((1 to: eachString size) detect: [ : stringIndex | (totalWidth:=totalWidth+(self fontToUse widthOf: (eachString at: stringIndex))) > (container width - + (container vIsScrollbarShowing + ifTrue: [ container scrollBar width ] + ifFalse: [ 0 ]) - iconWidth - leftEdgeOfRightmostColumn) ] - (container scrollBar - ifNil: [ 0 ] - ifNotNil: [ container scrollBar width ]) - iconWidth - leftEdgeOfRightmostColumn) ] ifNone: [ eachString size + 1 ]) - 1. ^ eachString size - indexOfLastVisible! Item was changed: ----- Method: ObjectExplorer>>openExplorerFor:withLabel: (in category 'user interface') ----- openExplorerFor: anObject withLabel: label + "ObjectExplorer new openExplorerFor: Smalltalk withLabel: 'Smalltalk'" + "Model must be set to support Reuse Windows preference." + self rootObject: anObject. + ToolBuilder + open: self + label: label. + "Set model again to ensure window title updated (hmm, why not the first time?)." + self rootObject: anObject! - "ObjectExplorer new openExplorerFor: Smalltalk withLabel: 'Smalltalk'" - - ToolBuilder open: self label: label. - self rootObject: anObject.! From commits at source.squeak.org Wed Apr 1 20:04:16 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 20:04:17 2015 Subject: [squeak-dev] The Trunk: SMLoader-cmm.81.mcz Message-ID: Chris Muller uploaded a new version of SMLoader to project The Trunk: http://source.squeak.org/trunk/SMLoader-cmm.81.mcz ==================== Summary ==================== Name: SMLoader-cmm.81 Author: cmm Time: 1 April 2015, 3:04:04.314 pm UUID: 5b84720e-18e5-4254-88b5-b58ad5abaa46 Ancestors: SMLoader-bf.80 - Fix selection rendering in SqueakMap. =============== Diff against SMLoader-bf.80 =============== Item was removed: - ----- Method: FileList2 class>>morphicView (in category '*smloader-override') ----- - morphicView - ^ self morphicViewOnDirectory: FileDirectory default! Item was changed: ----- Method: SMLoaderPlus>>selectedCategory: (in category 'accessing') ----- selectedCategory: anSMCategory "Change the selected category." selectedCategory := anSMCategory. + selectedCategory ifNotNil: + [ (selectedCategory objects includes: self selectedItem) ifFalse: [ self selectedItem: nil ] ]. + self + changed: #selectedCategoryPath ; + changed: #packageList! - selectedCategory - ifNotNil: [(selectedCategory objects includes: self selectedItem) - ifFalse: [self selectedItem: nil]]. - self changed: #selectedCategory. - self changed: #packageList! Item was changed: ----- Method: SMLoaderPlus>>selectedCategoryPath (in category 'accessing') ----- selectedCategoryPath "Return selected category's path." | path | path := #(). selectedCategory ifNotNil: [selectedCategory parent ifNotNilDo: [:p | path := path copyWith: p]. path := path copyWith: selectedCategory]. + ^ path! - ^ path - collect: [:cat | self categoryLabel: cat]! From commits at source.squeak.org Wed Apr 1 20:05:51 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 20:05:53 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-cmm.114.mcz Message-ID: Chris Muller uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-cmm.114.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-cmm.114 Author: cmm Time: 1 April 2015, 3:05:39.686 pm UUID: 734dc0ce-3ffa-429c-a740-12d57659e296 Ancestors: ToolBuilder-Morphic-cmm.113 No, you cannot send copyFrom: 0 to: 0 to an empty Array. Must check for emptiness. =============== Diff against ToolBuilder-Morphic-cmm.113 =============== Item was changed: ----- Method: PluggableTreeMorph>>visibleItems (in category 'geometry') ----- visibleItems + ^ self items ifNotEmpty: + [ : items | items + copyFrom: self topVisibleRowIndex + to: self bottomVisibleRowIndex ]! - ^ self items - copyFrom: self topVisibleRowIndex - to: self bottomVisibleRowIndex! From asqueaker at gmail.com Wed Apr 1 20:09:04 2015 From: asqueaker at gmail.com (Chris Muller) Date: Wed Apr 1 20:09:08 2015 Subject: [squeak-dev] The Trunk: Tools-cmm.572.mcz In-Reply-To: <551c4a99.63518c0a.4156.ffff9a65SMTPIN_ADDED_MISSING@mx.google.com> References: <551c4a99.63518c0a.4156.ffff9a65SMTPIN_ADDED_MISSING@mx.google.com> Message-ID: Hi Marcel, I don't care for this code in #openExplorerFor: but I ran out of time to understand why the window title would not update until the model was set only AFTERward, not beforehand.. On Wed, Apr 1, 2015 at 2:44 PM, wrote: > Chris Muller uploaded a new version of Tools to project The Trunk: > http://source.squeak.org/trunk/Tools-cmm.572.mcz > > ==================== Summary ==================== > > Name: Tools-cmm.572 > Author: cmm > Time: 1 April 2015, 2:43:55.003 pm > UUID: cc792d4a-a258-496c-bffe-ad6db90b52b6 > Ancestors: Tools-cmm.571 > > - Fix test for scrollbar presence for Vertical Smart Splitter support. > - Fix "Reuse Windows" preference for ObjectExplorers. > > =============== Diff against Tools-cmm.571 =============== > > Item was changed: > ----- Method: IndentingListItemMorph>>charactersOccluded (in category 'private') ----- > charactersOccluded > "Answer the number of characters occluded in my #visibleList by my right edge." > | listIndex leftEdgeOfRightmostColumn eachString indexOfLastVisible iconWidth totalWidth | > listIndex := 0. > leftEdgeOfRightmostColumn := container columns > ifNil: [ 0 ] > ifNotNil: > [ : cols | (1 to: cols size - 1) > inject: 0 > into: > [ : sum : each | sum + (self widthOfColumn: each) ] ]. > eachString := container columns > ifNil: [ self complexContents asString ] > ifNotNil: > [ : cols | self contentsAtColumn: container columns size ]. > iconWidth := self icon > ifNil: [ 0 ] > ifNotNil: > [ : icon | icon width + 2 ]. > totalWidth := self toggleBounds right. > indexOfLastVisible := ((1 to: eachString size) > detect: > [ : stringIndex | (totalWidth:=totalWidth+(self fontToUse widthOf: (eachString at: stringIndex))) > > (container width - > + (container vIsScrollbarShowing > + ifTrue: [ container scrollBar width ] > + ifFalse: [ 0 ]) - iconWidth - leftEdgeOfRightmostColumn) ] > - (container scrollBar > - ifNil: [ 0 ] > - ifNotNil: [ container scrollBar width ]) - iconWidth - leftEdgeOfRightmostColumn) ] > ifNone: [ eachString size + 1 ]) - 1. > ^ eachString size - indexOfLastVisible! > > Item was changed: > ----- Method: ObjectExplorer>>openExplorerFor:withLabel: (in category 'user interface') ----- > openExplorerFor: anObject withLabel: label > + "ObjectExplorer new openExplorerFor: Smalltalk withLabel: 'Smalltalk'" > + "Model must be set to support Reuse Windows preference." > + self rootObject: anObject. > + ToolBuilder > + open: self > + label: label. > + "Set model again to ensure window title updated (hmm, why not the first time?)." > + self rootObject: anObject! > - "ObjectExplorer new openExplorerFor: Smalltalk withLabel: 'Smalltalk'" > - > - ToolBuilder open: self label: label. > - self rootObject: anObject.! > > From commits at source.squeak.org Wed Apr 1 21:16:23 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 21:16:26 2015 Subject: [squeak-dev] The Trunk: System-ul.713.mcz Message-ID: Levente Uzonyi uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System-ul.713.mcz ==================== Summary ==================== Name: System-ul.713 Author: ul Time: 1 April 2015, 11:14:28.116 pm UUID: 226e90db-d97f-4958-9fa6-97a0b23cfff3 Ancestors: System-eem.712 Use a custom CharacterSet for separators instead of modifying the one in CharacterSet - which may be shared. Cache it for better performance, and get rid of it during cleanUp. =============== Diff against System-eem.712 =============== Item was changed: TextDiffBuilder subclass: #ClassDiffBuilder instanceVariableNames: '' + classVariableNames: 'SeparatorSet' - classVariableNames: '' poolDictionaries: '' category: 'System-FilePackage'! + !ClassDiffBuilder commentStamp: 'ul 4/1/2015 23:10' prior: 0! + I'm like TextDiffBuilder, but I split the input text by my own set of separator characters (see #separatorSet), instead of new lines. I'm meant to create diffs of class definitions.! - !ClassDiffBuilder commentStamp: 'fbs 9/23/2013 08:58' prior: 0! - I'm like TextDiffBuilder, but I split the input text by Character >> #separators, instead of new lines. I'm probably meant to create diffs of class definitions.! Item was added: + ----- Method: ClassDiffBuilder class>>cleanUp: (in category 'as yet unclassified') ----- + cleanUp: aggressive + + SeparatorSet := nil! Item was added: + ----- Method: ClassDiffBuilder class>>separatorSet (in category 'as yet unclassified') ----- + separatorSet + + ^SeparatorSet ifNil: [ + SeparatorSet := CharacterSet separators copy + add: $'; "for variables" + add: $"; "for comments in mc" + yourself ]! Item was changed: ----- Method: ClassDiffBuilder>>split: (in category 'private') ----- split: aString "I return an Array or DiffElements containing aString splitted by whitespace ' and ""." ^Array streamContents: [ :stream | | input separators | input := aString readStream. + separators := self class separatorSet. - separators := CharacterSet separators - add: $'; "for variables" - add: $"; "for comments in mc" - yourself. [ input atEnd ] whileFalse: [ | word separator | word := input upToAnyOf: separators + do: [ :matchingSeparator | separator := matchingSeparator ]. - do: [ :matchingSeparator | - separator := matchingSeparator ]. stream nextPut: (DiffElement string: word). separator ifNotNil: [ stream nextPut: (DiffElement string: separator asString) ] ] ]! From commits at source.squeak.org Wed Apr 1 21:19:47 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 21:19:48 2015 Subject: [squeak-dev] The Trunk: System-ul.714.mcz Message-ID: Levente Uzonyi uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System-ul.714.mcz ==================== Summary ==================== Name: System-ul.714 Author: ul Time: 1 April 2015, 11:19:18.334 pm UUID: 85f78b85-369c-4bd7-8e6d-52c9e63f27c1 Ancestors: System-ul.713 Avoid LargeInteger arithmetic in ThirtyTwoBitRegister>>leftRotateBy:. =============== Diff against System-ul.713 =============== Item was changed: ----- Method: ThirtyTwoBitRegister>>leftRotateBy: (in category 'accumulator ops') ----- leftRotateBy: bits "Rotate my contents left by the given number of bits, retaining exactly 32 bits." + "Details: Perform this operation with no LargeInteger arithmetic." - "Details: Perform this operation with as little LargeInteger arithmetic as possible." + | bitCount newHi | + bitCount := bits. + bitCount >= 32 ifTrue: [ bitCount := bitCount \\ 32 ]. + bitCount >= 16 ifTrue: [ + newHi := low. + low := hi. + hi := newHi. + bitCount := bitCount - 16 ]. + bitCount >= 15 ifTrue: [ + newHi := ((hi bitAnd: 16r1) bitShift: 15) bitOr: (low bitShift: -1). + low := ((low bitAnd: 16r1) bitShift: 15) bitOr: (hi bitShift: -1). + hi := newHi. + ^self ]. + bitCount >= 1 ifTrue: [ + | shift | + shift := bitCount - 16. + newHi := ((hi bitShift: bitCount) bitAnd: 16rFFFF) bitOr: (low bitShift: shift). + low := ((low bitShift: bitCount) bitAnd: 16rFFFF) bitOr: (hi bitShift: shift). + hi := newHi ]! - | bitCount s1 s2 newHi | - "ensure bitCount is in range [0..31]" - bitCount := bits \\ 32. - bitCount > 16 - ifTrue: [ - s1 := bitCount - 16. - s2 := s1 - 16. - newHi := ((low bitShift: s1) bitAnd: 16rFFFF) bitOr: (hi bitShift: s2). - low := ((hi bitShift: s1) bitAnd: 16rFFFF) bitOr: (low bitShift: s2). - hi := newHi] - ifFalse: [ - s1 := bitCount. - s2 := s1 - 16. - newHi := ((hi bitShift: s1) bitAnd: 16rFFFF) bitOr: (low bitShift: s2). - low := ((low bitShift: s1) bitAnd: 16rFFFF) bitOr: (hi bitShift: s2). - hi := newHi] - ! From commits at source.squeak.org Wed Apr 1 21:55:04 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 21:55:05 2015 Subject: [squeak-dev] Daily Commit Log Message-ID: <20150401215504.4141.qmail@box4.squeakfoundation.org> Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours: http://lists.squeakfoundation.org/pipermail/packages/2015-April/007740.html Name: ToolBuilder-Morphic-mt.109 Ancestors: ToolBuilder-Morphic-mt.108 Reverted path selection in tree to use #= instead of #==. Fixed the code to indicate the actual selection in the tree (and scroll to it if too large). ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007741.html Name: Tools-mt.569 Ancestors: Tools-mt.568 Fixed selection in FileList tool. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007742.html Name: ToolBuilder-Morphic-mt.110 Ancestors: ToolBuilder-Morphic-mt.109 Revert "code to indicate the actual selection" because I confused the view-based API with the model-based API. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007743.html Name: Morphic-mt.798 Ancestors: Morphic-mt.797 Fixes error that may occur in empty lazy lists when mapping a point to a row index. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007744.html Name: Morphic-mt.799 Ancestors: Morphic-mt.798 Remove the balloon text when start typing because we assume that the user focuses on the input and not the help anymore. This is similar to balloon help for buttons where the bubble disappears if the user clicks the button. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007745.html Name: Morphic-mt.800 Ancestors: Morphic-mt.799 Elevated #roundedScrollBarLook into a preference (was: just hardcoded to false) and updated affected methods. Added preference to hide even the arrow buttons of all scrollbars. This makes sense for mouse-wheel-driven usage. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007746.html Name: Morphic-mt.801 Ancestors: Morphic-mt.800 Scrollbars: Fixed button initialization code for rounded scrollbars. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007747.html Name: Morphic-mt.802 Ancestors: Morphic-mt.801 Fixed layouting bug of horizontal scrollbar if vertical scroll bar is on the left. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007748.html Name: Kernel-topa.916 Ancestors: Kernel-topa.915 (same as before) Fix arguments access in WeakMessageSend ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007749.html Name: ToolBuilder-Morphic-mt.111 Ancestors: ToolBuilder-Morphic-mt.110 Fixed should background-styling to update text morph runs only from within the morphic UI process. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007750.html Name: Morphic-mt.803 Ancestors: Morphic-mt.802 Recompose the paragraph if text or runs changed after keyboard input. We did not notice this bug because Shout/Tools did this in #stylerStyled:. Only some jerky scrolling behavior occured from time to time because the first text morph update (while Shout was background-styling) was without paragraph recomposition. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007751.html Name: Morphic-mt.804 Ancestors: Morphic-mt.803 Another fix for horizontal scroll bars in scroll panes, which affects layouting and scrolling. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007752.html Name: Tools-cmm.570 Ancestors: Tools-mt.569 - SimpleHierarchicalListMorph's now honor preferences: mouseOverForKeyboardFocus Vertical Smart Splitters Filterable Lists Clear Automatically - After filtering Tree, refit the column-widths to the filtered results. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007753.html Name: Morphic-cmm.805 Ancestors: Morphic-mt.804 - SimpleHierarchicalListMorph's now honor preferences: mouseOverForKeyboardFocus Vertical Smart Splitters - Don't let splitter bars be dragged further than their PluggableListMorphs want them to go. - PluggableTextMorph's now honor Vertical Smart Splitters to avoid wrapped lines, if possible. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007754.html Name: ToolBuilder-Morphic-cmm.109 Ancestors: ToolBuilder-Morphic-mt.111 - PluggableTreeMorph support for Vertical Smart Splitters. - Let single-level filtering also be a navigation gesture. - After filtering a Tree, refit the column-widths to the filtered results. - SimpleHierarchicalListMorph support mouseOverForKeyboardFocus. - Fix selection rendering in PluggableTreeMorph (FileList and SqueakMap). ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007755.html Name: Tools-cmm.569 Ancestors: Tools-cmm.570 - SimpleHierarchicalListMorph's now honor preferences: mouseOverForKeyboardFocus Vertical Smart Splitters Filterable Lists Clear Automatically - After filtering Tree, refit the column-widths to the filtered results. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007756.html Name: Morphic-cmm.798 Ancestors: Morphic-cmm.805 - SimpleHierarchicalListMorph's now honor preferences: mouseOverForKeyboardFocus Vertical Smart Splitters - Don't let splitter bars be dragged further than their PluggableListMorphs want them to go. - PluggableTextMorph's now honor Vertical Smart Splitters to avoid wrapped lines, if possible. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007757.html Name: Tools-cmm.571 Ancestors: Tools-cmm.569 Resaving package as highest version number to support proper trunk updating. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007758.html Name: ToolBuilder-Morphic-cmm.112 Ancestors: ToolBuilder-Morphic-cmm.109 Resaving package with highest version # to support proper trunk update. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007759.html Name: ToolBuilder-Morphic-cmm.113 Ancestors: ToolBuilder-Morphic-cmm.112 - Filter-navigation DNU when there is no selection. Filtering still needs to be figured out for the roots of a tree... - Restore Marcel's latest selectPath:in: from today. - Don't rely on #selection: from setSelectedMorph: to fix selection-rendering in UI's, instead we should be sending proper changed notifications from each model. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007760.html Name: Tools-cmm.572 Ancestors: Tools-cmm.571 - Fix test for scrollbar presence for Vertical Smart Splitter support. - Fix "Reuse Windows" preference for ObjectExplorers. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007761.html Name: SMLoader-cmm.81 Ancestors: SMLoader-bf.80 - Fix selection rendering in SqueakMap. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007762.html Name: ToolBuilder-Morphic-cmm.114 Ancestors: ToolBuilder-Morphic-cmm.113 No, you cannot send copyFrom: 0 to: 0 to an empty Array. Must check for emptiness. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007763.html Name: System-ul.713 Ancestors: System-eem.712 Use a custom CharacterSet for separators instead of modifying the one in CharacterSet - which may be shared. Cache it for better performance, and get rid of it during cleanUp. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007764.html Name: System-ul.714 Ancestors: System-ul.713 Avoid LargeInteger arithmetic in ThirtyTwoBitRegister>>leftRotateBy:. ============================================= From commits at source.squeak.org Wed Apr 1 21:56:07 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 21:56:09 2015 Subject: [squeak-dev] The Trunk: Collections-ul.606.mcz Message-ID: Levente Uzonyi uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections-ul.606.mcz ==================== Summary ==================== Name: Collections-ul.606 Author: ul Time: 1 April 2015, 11:35:01.718 pm UUID: cd3ba2f1-88d3-4f8a-a06b-089509ceccdf Ancestors: Collections-mt.605 Cache and share #separators and #nonSeparators in CharacterSet (just like #crlf). Remove them on #cleanUp. Implemented CharacterSet class >> #withAll:. Removed #noSeparatorMap, #noSeparators, #separatorMap from String class. Also removed the class variables CSNonSeparators, CSSeparators, and CSLineEnders. All users were rewritten to use CharacterSet's version of these sets. =============== Diff against Collections-mt.605 =============== Item was changed: ----- Method: ByteString>>substrings (in category 'converting') ----- substrings "Answer an array of the substrings that compose the receiver." | result end beginning | result := WriteStream on: (Array new: 10). end := 0. "find one substring each time through this loop" [ "find the beginning of the next substring" + beginning := self indexOfAnyOf: CharacterSet nonSeparators - beginning := self indexOfAnyOf: CSNonSeparators startingAt: end+1 ifAbsent: [ nil ]. beginning ~~ nil ] whileTrue: [ "find the end" + end := self indexOfAnyOf: CharacterSet separators - end := self indexOfAnyOf: CSSeparators startingAt: beginning ifAbsent: [ self size + 1 ]. end := end - 1. result nextPut: (self copyFrom: beginning to: end). ]. ^result contents! Item was changed: Collection subclass: #CharacterSet instanceVariableNames: 'map' + classVariableNames: 'CrLf NonSeparators Separators' - classVariableNames: 'CrLf' poolDictionaries: '' category: 'Collections-Support'! !CharacterSet commentStamp: '' prior: 0! A set of characters. Lookups for inclusion are very fast.! Item was added: + ----- Method: CharacterSet class>>cleanUp: (in category 'initialize-release') ----- + cleanUp: aggressive + + CrLf := NonSeparators := Separators := nil! Item was changed: ----- Method: CharacterSet class>>crlf (in category 'accessing') ----- crlf + + ^CrLf ifNil: [ CrLf := self with: Character cr with: Character lf ]! - CrLf ifNil: [CrLf := self with: Character cr with: Character lf]. - ^CrLf! Item was changed: + ----- Method: CharacterSet class>>nonSeparators (in category 'accessing') ----- - ----- Method: CharacterSet class>>nonSeparators (in category 'instance creation') ----- nonSeparators "return a set containing everything but the whitespace characters" + ^NonSeparators ifNil: [ + NonSeparators := self separators complement ]! - ^self separators complement! Item was changed: + ----- Method: CharacterSet class>>separators (in category 'accessing') ----- - ----- Method: CharacterSet class>>separators (in category 'instance creation') ----- separators "return a set containing just the whitespace characters" + ^Separators ifNil: [ + Separators := self new + addAll: Character separators; + yourself ]! - | set | - set := self empty. - set addAll: Character separators. - ^set! Item was added: + ----- Method: CharacterSet class>>withAll: (in category 'instance creation') ----- + withAll: aCollection + "Create a new CharacterSet containing all the characters from aCollection." + + ^self newFrom: aCollection! Item was changed: ----- Method: ReadStream>>nextFloat (in category 'accessing') ----- nextFloat "Read a floating point value from the receiver. This method is highly optimized for cases where many floating point values need to be read subsequently. And if this needs to go even faster, look at the inner loops fetching the characters - moving those into a plugin would speed things up even more." | buffer count sign index cc value digit fraction exp startIndex anyDigit digitNeeded | buffer := collection. count := readLimit. index := position+1. "Skip separators" + index := buffer indexOfAnyOf: CharacterSet nonSeparators startingAt: index. - index := ByteString findFirstInString: buffer inSet: String noSeparatorMap startingAt: index. index = 0 ifTrue:[self setToEnd. ^nil]. "check for sign" digitNeeded := false. sign := 1. cc := buffer byteAt: index. cc = 45 "$- asciiValue" ifTrue:[sign := -1. index := index+1. digitNeeded := true] ifFalse:[cc = 43 "$+ asciiValue" ifTrue:[index := index+1. digitNeeded := true]]. "Read integer part" startIndex := index. value := 0. [index <= count and:[ digit := (buffer byteAt: index) - 48. "$0 asciiValue" digit >= 0 and:[digit <= 9]]] whileTrue:[ value := value * 10 + digit. index := index + 1. ]. anyDigit := index > startIndex. index > count ifTrue:[ (digitNeeded and:[anyDigit not]) ifTrue:[^self error: 'At least one digit expected']. self setToEnd. ^value asFloat * sign]. (buffer byteAt: index) = 46 "$. asciiValue" ifTrue:["." index := index+1. startIndex := index. "NOTE: fraction and exp below can overflow into LargeInteger range. If they do, then things slow down horribly due to the relatively slow LargeInt -> Float conversion. This can be avoided by changing fraction and exp to use floats to begin with (0.0 and 1.0 respectively), however, this will give different results to Float>>readFrom: and it is not clear if that is acceptable here." fraction := 0. exp := 1. [index <= count and:[ digit := (buffer byteAt: index) - 48. "$0 asciiValue" digit >= 0 and:[digit <= 9]]] whileTrue:[ fraction := fraction * 10 + digit. exp := exp * 10. index := index + 1. ]. value := value + (fraction asFloat / exp asFloat). anyDigit := anyDigit or:[index > startIndex]. ]. value := value asFloat * sign. "At this point we require at least one digit to avoid allowing: - . ('0.0' without leading digits) - e32 ('0e32' without leading digits) - .e32 ('0.0e32' without leading digits) but these are currently allowed: - .5 (0.5) - 1. ('1.0') - 1e32 ('1.0e32') - 1.e32 ('1.0e32') - .5e32 ('0.5e32') " anyDigit ifFalse:["Check for NaN/Infinity first" (count - index >= 2 and:[(buffer copyFrom: index to: index+2) = 'NaN']) ifTrue:[position := index+2. ^Float nan * sign]. (count - index >= 7 and:[(buffer copyFrom: index to: index+7) = 'Infinity']) ifTrue:[position := index+7. ^Float infinity * sign]. ^self error: 'At least one digit expected' ]. index > count ifTrue:[self setToEnd. ^value asFloat]. (buffer byteAt: index) = 101 "$e asciiValue" ifTrue:["e[+|-]" index := index+1. "skip e" sign := 1. cc := buffer byteAt: index. cc = 45 "$- asciiValue" ifTrue:[sign := -1. index := index+1] ifFalse:[cc = 43 "$+ asciiValue" ifTrue:[index := index+1]]. startIndex := index. exp := 0. anyDigit := false. [index <= count and:[ digit := (buffer byteAt: index) - 48. "$0 asciiValue" digit >= 0 and:[digit <= 9]]] whileTrue:[ exp := exp * 10 + digit. index := index + 1. ]. index> startIndex ifFalse:[^self error: 'Exponent expected']. value := value * (10.0 raisedToInteger: exp * sign). ]. position := index-1. ^value! Item was changed: ArrayedCollection subclass: #String instanceVariableNames: '' + classVariableNames: 'AsciiOrder CSMacroCharacters CaseInsensitiveOrder CaseSensitiveOrder CrLfExchangeTable HtmlEntities LowercasingTable Tokenish UppercasingTable' - classVariableNames: 'AsciiOrder CSLineEnders CSMacroCharacters CSNonSeparators CSSeparators CaseInsensitiveOrder CaseSensitiveOrder CrLfExchangeTable HtmlEntities LowercasingTable Tokenish UppercasingTable' poolDictionaries: '' category: 'Collections-Strings'! !String commentStamp: '' prior: 0! A String is an indexed collection of Characters. Class String provides the abstract super class for ByteString (that represents an array of 8-bit Characters) and WideString (that represents an array of 32-bit characters). In the similar manner of LargeInteger and SmallInteger, those subclasses are chosen accordingly for a string; namely as long as the system can figure out so, the String is used to represent the given string. Strings support a vast array of useful methods, which can best be learned by browsing and trying out examples as you find them in the code. Here are a few useful methods to look at... String match: String contractTo: String also inherits many useful methods from its hierarchy, such as SequenceableCollection , SequenceableCollection copyReplaceAll:with: ! Item was changed: ----- Method: String class>>initialize (in category 'initialization') ----- initialize "self initialize" | order | AsciiOrder := (0 to: 255) as: ByteArray. CaseInsensitiveOrder := AsciiOrder copy. ($a to: $z) do: [:c | CaseInsensitiveOrder at: c asciiValue + 1 put: (CaseInsensitiveOrder at: c asUppercase asciiValue +1)]. "Case-sensitive compare sorts space, digits, letters, all the rest..." CaseSensitiveOrder := ByteArray new: 256 withAll: 255. order := -1. ' 0123456789' do: "0..10" [:c | CaseSensitiveOrder at: c asciiValue + 1 put: (order := order+1)]. ($a to: $z) do: "11-64" [:c | CaseSensitiveOrder at: c asUppercase asciiValue + 1 put: (order := order+1). CaseSensitiveOrder at: c asciiValue + 1 put: (order := order+1)]. 1 to: CaseSensitiveOrder size do: [:i | (CaseSensitiveOrder at: i) = 255 ifTrue: [CaseSensitiveOrder at: i put: (order := order+1)]]. order = 255 ifFalse: [self error: 'order problem']. "a table for translating to lower case" LowercasingTable := String withAll: (Character allByteCharacters collect: [:c | c asLowercase]). "a table for translating to upper case" UppercasingTable := String withAll: (Character allByteCharacters collect: [:c | c asUppercase]). "a table for testing tokenish (for fast numArgs)" Tokenish := String withAll: (Character allByteCharacters collect: [:c | c tokenish ifTrue: [c] ifFalse: [$~]]). + - - "CR and LF--characters that terminate a line" - CSLineEnders := CharacterSet crlf. - - "separators and non-separators" - CSSeparators := CharacterSet separators. - CSNonSeparators := CSSeparators complement. - "% and < for #expandMacros*" CSMacroCharacters := CharacterSet newFrom: '%<'. "a table for exchanging cr with lf and vica versa" CrLfExchangeTable := Character allByteCharacters collect: [ :each | each caseOf: { [ Character cr ] -> [ Character lf ]. [ Character lf ] -> [ Character cr ] } otherwise: [ each ] ]! Item was removed: - ----- Method: String class>>noSeparatorMap (in category 'accessing') ----- - noSeparatorMap - ^CSNonSeparators byteArrayMap! Item was removed: - ----- Method: String class>>noSeparators (in category 'accessing') ----- - noSeparators - ^ CSNonSeparators! Item was removed: - ----- Method: String class>>separatorMap (in category 'accessing') ----- - separatorMap - ^CSSeparators byteArrayMap! Item was changed: ----- Method: String>>indentationIfBlank: (in category 'paragraph support') ----- indentationIfBlank: aBlock "Answer the number of leading tabs in the receiver. If there are no visible characters, pass the number of tabs to aBlock and return its value." | leadingTabs nonTab nonTabIndex nonSepIndex lineEndIndex | nonTab := (CharacterSet with: Character tab) complement. nonTabIndex := self indexOfAnyOf: nonTab startingAt: 1. nonTabIndex = 0 ifTrue: [ "Only made of tabs or empty" ^aBlock value: self size]. leadingTabs := nonTabIndex - 1. + nonSepIndex := self indexOfAnyOf: CharacterSet nonSeparators startingAt: 1. - nonSepIndex := self indexOfAnyOf: CSNonSeparators startingAt: 1. nonSepIndex = 0 ifTrue: [ "Only made of separators" ^aBlock value: leadingTabs]. + lineEndIndex := self indexOfAnyOf: CharacterSet crlf startingAt: 1. - lineEndIndex := self indexOfAnyOf: CSLineEnders startingAt: 1. (lineEndIndex between: 1 and: nonSepIndex) ifTrue: [ "Only made of separators up to a line end" ^aBlock value: leadingTabs]. ^leadingTabs! Item was changed: ----- Method: String>>withBlanksTrimmed (in category 'converting') ----- withBlanksTrimmed "Return a copy of the receiver from which leading and trailing blanks have been trimmed." | first last | + first := self indexOfAnyOf: CharacterSet nonSeparators startingAt: 1 ifAbsent: [0]. - first := self indexOfAnyOf: CSNonSeparators startingAt: 1 ifAbsent: [0]. first = 0 ifTrue: [ ^'' ]. "no non-separator character" + last := self lastIndexOfAnyOf: CharacterSet nonSeparators startingAt: self size ifAbsent: [self size]. - last := self lastIndexOfAnyOf: CSNonSeparators startingAt: self size ifAbsent: [self size]. (first = 1 and: [ last = self size ]) ifTrue: [ ^self copy ]. ^self copyFrom: first to: last ! Item was changed: ----- Method: String>>withNoLineLongerThan: (in category 'converting') ----- withNoLineLongerThan: aNumber "Answer a string with the same content as receiver, but rewrapped so that no line has more characters than the given number" aNumber isNumber not | (aNumber < 1) ifTrue: [self error: 'too narrow']. ^self class new: self size * (aNumber + 1) // aNumber "provision for supplementary line breaks" streamContents: [ :stream | self lineIndicesDo: [ :start :endWithoutDelimiters :end | | pastEnd lineStart | pastEnd := endWithoutDelimiters + 1. "eliminate spaces at beginning of line" + lineStart := (self indexOfAnyOf: CharacterSet nonSeparators startingAt: start ifAbsent: [pastEnd]) min: pastEnd. - lineStart := (self indexOfAnyOf: CSNonSeparators startingAt: start ifAbsent: [pastEnd]) min: pastEnd. [| lineStop lineEnd spacePosition | lineEnd := lineStop := lineStart + aNumber min: pastEnd.. spacePosition := lineStart. [spacePosition < lineStop] whileTrue: [ + spacePosition := self indexOfAnyOf: CharacterSet separators startingAt: spacePosition + 1 ifAbsent: [pastEnd]. - spacePosition := self indexOfAnyOf: CSSeparators startingAt: spacePosition + 1 ifAbsent: [pastEnd]. spacePosition <= lineStop ifTrue: [lineEnd := spacePosition]. ]. "split before space or before lineStop if no space" stream nextPutAll: (self copyFrom: lineStart to: lineEnd - 1). "eliminate spaces at beginning of next line" + lineStart := self indexOfAnyOf: CharacterSet nonSeparators startingAt: lineEnd ifAbsent: [pastEnd]. - lineStart := self indexOfAnyOf: CSNonSeparators startingAt: lineEnd ifAbsent: [pastEnd]. lineStart <= endWithoutDelimiters ] whileTrue: [stream cr]. stream nextPutAll: (self copyFrom: pastEnd to: end) ] ]! Item was changed: ----- Method: String>>withSeparatorsCompacted (in category 'converting') ----- withSeparatorsCompacted "replace each sequences of whitespace by a single space character" "' test ' withSeparatorsCompacted = ' test '" "' test test' withSeparatorsCompacted = ' test test'" "'test test ' withSeparatorsCompacted = 'test test '" | out in next isSeparator | self isEmpty ifTrue: [^ self]. out := WriteStream on: (String new: self size). in := self readStream. isSeparator := [:char | char asciiValue < 256 + and: [CharacterSet separators includes: char]]. - and: [CSSeparators includes: char]]. [in atEnd] whileFalse: [ next := in next. (isSeparator value: next) ifTrue: [ out nextPut: $ . [in atEnd or: [next := in next. (isSeparator value: next) ifTrue: [false] ifFalse: [out nextPut: next. true]]] whileFalse] ifFalse: [out nextPut: next]]. ^ out contents! Item was changed: ----- Method: Text>>withBlanksTrimmed (in category 'converting') ----- withBlanksTrimmed "Return a copy of the receiver from which leading and trailing blanks have been trimmed." | first last | + first := string indexOfAnyOf: CharacterSet nonSeparators startingAt: 1. - first := string indexOfAnyOf: String noSeparators startingAt: 1 ifAbsent: [0]. first = 0 ifTrue: [ ^'' ]. "no non-separator character" + last := string lastIndexOfAnyOf: CharacterSet nonSeparators startingAt: self size ifAbsent: [self size]. - last := string lastIndexOfAnyOf: String noSeparators startingAt: self size ifAbsent: [self size]. (first = 1 and: [ last = self size ]) ifTrue: [ ^self copy ]. ^self copyFrom: first to: last ! From commits at source.squeak.org Wed Apr 1 21:56:32 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 21:56:34 2015 Subject: [squeak-dev] The Trunk: Network-ul.159.mcz Message-ID: Levente Uzonyi uploaded a new version of Network to project The Trunk: http://source.squeak.org/trunk/Network-ul.159.mcz ==================== Summary ==================== Name: Network-ul.159 Author: ul Time: 1 April 2015, 11:44:21.852 pm UUID: 22d0dece-43ac-4ce7-b81f-9516fccd1843 Ancestors: Network-ul.158 Use CharacterSet's #nonSeparators shared set instead of creating and storing another one in MailAddressTokenizer. Initialize other character sets lazily, and release them during cleanUp. =============== Diff against Network-ul.158 =============== Item was changed: Stream subclass: #MailAddressTokenizer instanceVariableNames: 'cachedToken text pos' + classVariableNames: 'CSNonAtom CSParens CSSpecials' - classVariableNames: 'CSNonAtom CSNonSeparators CSParens CSSpecials' poolDictionaries: '' category: 'Network-RFC822'! !MailAddressTokenizer commentStamp: '' prior: 0! Divides an address into tokens, as specified in RFC 822. Used by MailAddressParser.! Item was added: + ----- Method: MailAddressTokenizer class>>cleanUp: (in category 'class initialization') ----- + cleanUp: aggressive + + CSParens := CSSpecials := CSNonAtom := nil! Item was removed: - ----- Method: MailAddressTokenizer class>>initialize (in category 'class initialization') ----- - initialize - "Initalize class variables using MailAddressTokenizer initialize" - - | atomChars | - - CSParens := CharacterSet empty. - CSParens addAll: '()'. - - CSSpecials := CharacterSet empty. - CSSpecials addAll: '()<>@,;:\".[]'. - - CSNonSeparators := CharacterSet separators complement. - - - "(from RFC 2822)" - atomChars := CharacterSet empty. - atomChars addAll: ($A to: $Z). - atomChars addAll: ($a to: $z). - atomChars addAll: ($0 to: $9). - atomChars addAll: '!!#$%^''*+-/=?^_`{|}~'. - - CSNonAtom := atomChars complement.! Item was added: + ----- Method: MailAddressTokenizer class>>nonAtomSet (in category 'class initialization') ----- + nonAtomSet + "(from RFC 2822)" + + ^CSNonAtom ifNil: [ + CSNonAtom := CharacterSet new + addAll: ($A to: $Z); + addAll: ($a to: $z); + addAll: ($0 to: $9); + addAll: '!!#$%^''*+-/=?^_`{|}~'; + complement ]! Item was added: + ----- Method: MailAddressTokenizer class>>parenthesesSet (in category 'class initialization') ----- + parenthesesSet + + ^CSParens ifNil: [ CSParens:= CharacterSet newFrom: '()' ]! Item was added: + ----- Method: MailAddressTokenizer class>>specialsSet (in category 'class initialization') ----- + specialsSet + + ^CSSpecials ifNil: [ CSSpecials := CharacterSet newFrom: '()<>@,;:\".[]' ]! Item was changed: ----- Method: MailAddressTokenizer>>nextAtom (in category 'tokenizing') ----- nextAtom | start end | start := pos. + pos := text indexOfAnyOf: self class nonAtomSet startingAt: start ifAbsent: [ text size + 1]. - pos := text indexOfAnyOf: CSNonAtom startingAt: start ifAbsent: [ text size + 1]. end := pos - 1. ^MailAddressToken type: #Atom text: (text copyFrom: start to: end)! Item was changed: ----- Method: MailAddressTokenizer>>nextComment (in category 'tokenizing') ----- nextComment | start nestLevel paren | start := pos. pos := pos + 1. nestLevel := 1. [ nestLevel > 0 ] whileTrue: [ + pos := text indexOfAnyOf: self class parenthesesSet startingAt: pos ifAbsent: [ 0 ]. - pos := text indexOfAnyOf: CSParens startingAt: pos ifAbsent: [ 0 ]. pos = 0 ifTrue: [ self error: 'unterminated comment. ie, more (''s than )''s' ]. paren := self nextChar. paren = $( ifTrue: [ nestLevel := nestLevel + 1 ] ifFalse: [ nestLevel := nestLevel - 1 ]]. ^ MailAddressToken type: #Comment text: (text copyFrom: start to: pos - 1)! Item was changed: ----- Method: MailAddressTokenizer>>nextToken (in category 'tokenizing') ----- nextToken | c | self skipSeparators. c := self peekChar. c ifNil: [ ^nil ]. c = $( ifTrue: [ ^self nextComment ]. c = $" ifTrue: [ ^self nextQuotedString ]. c = $[ ifTrue: [ ^self nextDomainLiteral ]. + (self class specialsSet includes: c) ifTrue: [ ^self nextSpecial ]. - (CSSpecials includes: c) ifTrue: [ ^self nextSpecial ]. ^self nextAtom! Item was changed: ----- Method: MailAddressTokenizer>>skipSeparators (in category 'tokenizing') ----- skipSeparators + pos := text indexOfAnyOf: CharacterSet nonSeparators startingAt: pos ifAbsent: [ text size + 1 ].! - pos := text indexOfAnyOf: CSNonSeparators startingAt: pos ifAbsent: [ text size + 1 ].! From commits at source.squeak.org Wed Apr 1 22:08:46 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 1 22:08:48 2015 Subject: [squeak-dev] The Trunk: Collections-ul.607.mcz Message-ID: Levente Uzonyi uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections-ul.607.mcz ==================== Summary ==================== Name: Collections-ul.607 Author: ul Time: 2 April 2015, 12:07:14.622 am UUID: 607c7a3f-c462-454c-8e18-02c49e4ae91a Ancestors: Collections-ul.606 Simplified CharacterSet class>>separators. Fixed ReadStream >> #nextFloat, when collection is not a ByteString. =============== Diff against Collections-ul.606 =============== Item was changed: ----- Method: CharacterSet class>>separators (in category 'accessing') ----- separators "return a set containing just the whitespace characters" + ^Separators ifNil: [ Separators := self newFrom: Character separators ]! - ^Separators ifNil: [ - Separators := self new - addAll: Character separators; - yourself ]! Item was changed: ----- Method: ReadStream>>nextFloat (in category 'accessing') ----- nextFloat "Read a floating point value from the receiver. This method is highly optimized for cases where many floating point values need to be read subsequently. And if this needs to go even faster, look at the inner loops fetching the characters - moving those into a plugin would speed things up even more." | buffer count sign index cc value digit fraction exp startIndex anyDigit digitNeeded | buffer := collection. count := readLimit. index := position+1. "Skip separators" + index := ByteString findFirstInString: buffer inSet: CharacterSet nonSeparators byteArrayMap startingAt: index. - index := buffer indexOfAnyOf: CharacterSet nonSeparators startingAt: index. index = 0 ifTrue:[self setToEnd. ^nil]. "check for sign" digitNeeded := false. sign := 1. cc := buffer byteAt: index. cc = 45 "$- asciiValue" ifTrue:[sign := -1. index := index+1. digitNeeded := true] ifFalse:[cc = 43 "$+ asciiValue" ifTrue:[index := index+1. digitNeeded := true]]. "Read integer part" startIndex := index. value := 0. [index <= count and:[ digit := (buffer byteAt: index) - 48. "$0 asciiValue" digit >= 0 and:[digit <= 9]]] whileTrue:[ value := value * 10 + digit. index := index + 1. ]. anyDigit := index > startIndex. index > count ifTrue:[ (digitNeeded and:[anyDigit not]) ifTrue:[^self error: 'At least one digit expected']. self setToEnd. ^value asFloat * sign]. (buffer byteAt: index) = 46 "$. asciiValue" ifTrue:["." index := index+1. startIndex := index. "NOTE: fraction and exp below can overflow into LargeInteger range. If they do, then things slow down horribly due to the relatively slow LargeInt -> Float conversion. This can be avoided by changing fraction and exp to use floats to begin with (0.0 and 1.0 respectively), however, this will give different results to Float>>readFrom: and it is not clear if that is acceptable here." fraction := 0. exp := 1. [index <= count and:[ digit := (buffer byteAt: index) - 48. "$0 asciiValue" digit >= 0 and:[digit <= 9]]] whileTrue:[ fraction := fraction * 10 + digit. exp := exp * 10. index := index + 1. ]. value := value + (fraction asFloat / exp asFloat). anyDigit := anyDigit or:[index > startIndex]. ]. value := value asFloat * sign. "At this point we require at least one digit to avoid allowing: - . ('0.0' without leading digits) - e32 ('0e32' without leading digits) - .e32 ('0.0e32' without leading digits) but these are currently allowed: - .5 (0.5) - 1. ('1.0') - 1e32 ('1.0e32') - 1.e32 ('1.0e32') - .5e32 ('0.5e32') " anyDigit ifFalse:["Check for NaN/Infinity first" (count - index >= 2 and:[(buffer copyFrom: index to: index+2) = 'NaN']) ifTrue:[position := index+2. ^Float nan * sign]. (count - index >= 7 and:[(buffer copyFrom: index to: index+7) = 'Infinity']) ifTrue:[position := index+7. ^Float infinity * sign]. ^self error: 'At least one digit expected' ]. index > count ifTrue:[self setToEnd. ^value asFloat]. (buffer byteAt: index) = 101 "$e asciiValue" ifTrue:["e[+|-]" index := index+1. "skip e" sign := 1. cc := buffer byteAt: index. cc = 45 "$- asciiValue" ifTrue:[sign := -1. index := index+1] ifFalse:[cc = 43 "$+ asciiValue" ifTrue:[index := index+1]]. startIndex := index. exp := 0. anyDigit := false. [index <= count and:[ digit := (buffer byteAt: index) - 48. "$0 asciiValue" digit >= 0 and:[digit <= 9]]] whileTrue:[ exp := exp * 10 + digit. index := index + 1. ]. index> startIndex ifFalse:[^self error: 'Exponent expected']. value := value * (10.0 raisedToInteger: exp * sign). ]. position := index-1. ^value! From marcel.taeumel at student.hpi.uni-potsdam.de Thu Apr 2 06:36:40 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Thu Apr 2 06:48:30 2015 Subject: [squeak-dev] Re: The Trunk: Tools-cmm.572.mcz In-Reply-To: References: Message-ID: <1427956600746-4816824.post@n4.nabble.com> I will look into it. Sending #rootObject: should always work and update the title. Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Tools-cmm-572-mcz-tp4816755p4816824.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Thu Apr 2 06:54:16 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 06:54:17 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.115.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.115.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.115 Author: mt Time: 2 April 2015, 8:54:11.711 am UUID: 873458fe-19e8-0449-a9d1-c52476bc1077 Ancestors: ToolBuilder-Morphic-cmm.114 Revert something that was re-introduced in cmm.112 but already reverted before. #selectPath:in: must send #setSelectedMorph: because both are callbacks from #update: within the tree morph. #selection only talks to the model. We do not have an equivalent for tree-path selection, which talks to the model, yet. =============== Diff against ToolBuilder-Morphic-cmm.114 =============== Item was changed: ----- Method: PluggableTreeMorph>>selectPath:in: (in category 'selection') ----- selectPath: path in: listItem + path isEmpty ifTrue: [^self setSelectedMorph: nil]. - path isEmpty ifTrue: [^self selection: nil]. - listItem withSiblingsDo: [:each | (each complexContents item = path first) ifTrue: [ each isExpanded ifFalse: [ each toggleExpandedState. self adjustSubmorphPositions. ]. each changed. path size = 1 ifTrue: [ + ^self setSelectedMorph: each - ^self selection: each complexContents ]. + each firstChild ifNil: [^self setSelectedMorph: nil]. - each firstChild ifNil: [^self selection: nil]. ^self selectPath: path allButFirst in: each firstChild ]. ]. + ^self setSelectedMorph: nil - ^self selection: nil ! Item was changed: ----- Method: PluggableTreeMorph>>setSelectedMorph: (in category 'selection') ----- setSelectedMorph: aMorph selectedWrapper := aMorph complexContents. + "Let the model now about the selected object, not wrapper." setSelectionSelector ifNotNil: [:symbol | model perform: symbol + with: (selectedWrapper ifNotNil: [:w | w item])]. + - with: (selectedWrapper ifNotNil: [ selectedWrapper item ])]. "The model may not have access to the parent object in terms of this tree structure." setSelectedParentSelector ifNotNil: [:symbol | model perform: symbol + with: (selectedWrapper ifNotNil: [:w | w parent ifNotNil: [:pw | pw item]])].! - with: (selectedWrapper ifNotNil: [selectedWrapper parent ifNotNil: [: parentWrapper | parentWrapper item]])].! From marcel.taeumel at student.hpi.uni-potsdam.de Thu Apr 2 06:47:44 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Thu Apr 2 06:59:31 2015 Subject: [squeak-dev] Re: The Trunk: Tools-cmm.572.mcz In-Reply-To: References: Message-ID: <1427957264557-4816827.post@n4.nabble.com> I cannot match your commit code + message to this problem? Could you try making smaller commits? You can right-click on a method in the save-dialog and "ignore" particular methods. Anyway: Label update works fine for me with the prior version of "openExplorerFor: anObject withLabel: label" What did you try and when did it not work? This works fine: ObjectExplorer new openExplorerFor: Morph new. Then inspecting it and trying self rootObject: Color yellow. does also work fine. -> I will revert that change until we can reproduce your bug. :) Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Tools-cmm-572-mcz-tp4816755p4816827.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Thu Apr 2 07:02:45 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 07:02:46 2015 Subject: [squeak-dev] The Trunk: Tools-mt.573.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.573.mcz ==================== Summary ==================== Name: Tools-mt.573 Author: mt Time: 2 April 2015, 9:02:26.26 am UUID: 44868c77-bafd-574f-bb56-3eb95728a7ba Ancestors: Tools-cmm.572 Revert last change in opening explorer because additional call to #rootObject: not needed. If there is a bug, which I cannot reproduce in my trunk image, it may lie somewhere else. Anyway, #rootObject: should always update the model correctly. No need to call it twice. =============== Diff against Tools-cmm.572 =============== Item was changed: ----- Method: ObjectExplorer>>openExplorerFor:withLabel: (in category 'user interface') ----- openExplorerFor: anObject withLabel: label + "ObjectExplorer new openExplorerFor: Smalltalk withLabel: 'Smalltalk'" + + ToolBuilder open: self label: label. + self rootObject: anObject.! - "ObjectExplorer new openExplorerFor: Smalltalk withLabel: 'Smalltalk'" - "Model must be set to support Reuse Windows preference." - self rootObject: anObject. - ToolBuilder - open: self - label: label. - "Set model again to ensure window title updated (hmm, why not the first time?)." - self rootObject: anObject! From commits at source.squeak.org Thu Apr 2 07:06:41 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 07:06:42 2015 Subject: [squeak-dev] The Trunk: Tools-mt.574.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.574.mcz ==================== Summary ==================== Name: Tools-mt.574 Author: mt Time: 2 April 2015, 9:06:20.379 am UUID: ccf2eb3b-c755-e342-8611-21ea886d0fe9 Ancestors: Tools-mt.573 Added #hMargin to trees. Feature moved from scroll panes to particular tools. Having this, tree selection will ecompass also this margin and no white pixels will be there. Having this, it is a cosmetic change. =============== Diff against Tools-mt.573 =============== Item was added: + ----- Method: IndentingListItemMorph>>hMargin (in category 'accessing') ----- + hMargin + + ^ 3! Item was changed: ----- Method: IndentingListItemMorph>>toggleRectangle (in category 'private') ----- toggleRectangle | h | h := bounds height. + ^(bounds left + self hMargin + (12 * indentLevel)) @ bounds top extent: 12@h! - ^(bounds left + (12 * indentLevel)) @ bounds top extent: 12@h! From commits at source.squeak.org Thu Apr 2 07:21:30 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 07:21:32 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.806.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.806.mcz ==================== Summary ==================== Name: Morphic-mt.806 Author: mt Time: 2 April 2015, 9:20:54.685 am UUID: 6a7470e3-86ed-7244-958d-35c81e309eff Ancestors: Morphic-cmm.805 Removed hard-coded margins in scroll panes and added them to lists, text fields, and trees. This gives tool-specific widgets more control about how to handle/draw this margins. =============== Diff against Morphic-cmm.805 =============== Item was changed: ----- Method: LazyListMorph>>display:atRow:on: (in category 'drawing') ----- display: item atRow: row on: canvas "display the given item at row row" | drawBounds emphasized rowColor itemAsText | itemAsText := item asStringOrText. emphasized := itemAsText isText ifTrue: [font emphasized: (itemAsText emphasisAt: 1)] ifFalse: [font]. rowColor := self colorForRow: row. + drawBounds := (self drawBoundsForRow: row) translateBy: (self hMargin @ 0). - drawBounds := self drawBoundsForRow: row. drawBounds := drawBounds intersect: self bounds. (self icon: row) ifNotNil: [ :icon || top | top := drawBounds top + ((drawBounds height - icon height) // 2). canvas translucentImage: icon at: drawBounds left @ top. drawBounds := drawBounds left: drawBounds left + icon width + 2 ]. canvas drawString: itemAsText in: drawBounds font: emphasized color: rowColor! Item was added: + ----- Method: LazyListMorph>>hMargin (in category 'accessing') ----- + hMargin + + ^ 3! Item was changed: ----- Method: MulticolumnLazyListMorph>>display:atRow:on: (in category 'drawing') ----- display: items atRow: row on: canvas "display the specified item, which is on the specified row; for Multicolumn lists, items will be a list of strings" | drawBounds | + drawBounds := (self drawBoundsForRow: row) translateBy: (self hMargin @ 0). - drawBounds := self drawBoundsForRow: row. drawBounds := drawBounds intersect: self bounds. items with: (1 to: items size) do: [:item :index | "move the bounds to the right at each step" index > 1 ifTrue: [drawBounds := drawBounds left: drawBounds left + 6 + (columnWidths at: index - 1)]. item isText ifTrue: [canvas drawString: item in: drawBounds font: (font emphasized: (item emphasisAt: 1)) color: (self colorForRow: row)] ifFalse: [canvas drawString: item in: drawBounds font: font color: (self colorForRow: row)]]! Item was changed: ----- Method: PluggableTextMorph>>setText: (in category 'model access') ----- setText: aText textMorph ifNil: [textMorph := self textMorphClass new + contents: aText + wrappedTo: self innerBounds width. + textMorph + margins: (3@0 corner: 0@0); + setEditView: self. - contents: aText wrappedTo: self innerBounds width-6. - textMorph setEditView: self. scroller addMorph: textMorph] ifNotNil: [textMorph newContents: aText]. self hasUnacceptedEdits: false. self setScrollDeltas.! Item was added: + ----- Method: PluggableTextMorph>>wantsBalloon (in category 'as yet unclassified') ----- + wantsBalloon + + ^ self textMorph contents notEmpty and: [super wantsBalloon]! Item was changed: ----- Method: ScrollPane>>hMargin (in category 'access') ----- hMargin "pixels of whitespace at to the left of the scroller when the hScrollBar offset is 0" + ^0 - ^3 ! Item was changed: ----- Method: ScrollPane>>initializeScrollBars (in category 'initialization') ----- initializeScrollBars "initialize the receiver's scrollBar" (scrollBar := ScrollBar new model: self slotName: 'vScrollBar') borderWidth: 1; borderColor: Color black. (hScrollBar := ScrollBar new model: self slotName: 'hScrollBar') borderWidth: 1; borderColor: Color black. "" scroller := TransformMorph new color: Color transparent. + scroller offset: 0 @ 0. - scroller offset: -3 @ 0. self addMorph: scroller. "" scrollBar initializeEmbedded: retractableScrollBar not. hScrollBar initializeEmbedded: retractableScrollBar not. retractableScrollBar ifFalse: [self addMorph: scrollBar; addMorph: hScrollBar]. Preferences alwaysShowVScrollbar ifTrue: [ self alwaysShowVScrollBar: true ]. Preferences alwaysHideHScrollbar ifTrue:[self hideHScrollBarIndefinitely: true ] ifFalse: [Preferences alwaysShowHScrollbar ifTrue: [ self alwaysShowHScrollBar: true ]]. ! Item was changed: ----- Method: ScrollPane>>innerBounds (in category 'geometry') ----- innerBounds | inner | inner := super innerBounds. retractableScrollBar | (submorphs includes: scrollBar) not ifFalse:[ inner := (scrollBarOnLeft ifTrue: [scrollBar right @ inner top corner: inner bottomRight] ifFalse: [inner topLeft corner: scrollBar left @ inner bottom]) ]. (retractableScrollBar | self hIsScrollbarShowing not) ifTrue: [^ inner] + ifFalse: [^ inner topLeft corner: (inner bottomRight - (0@(self scrollBarThickness - 1)))]. - ifFalse: [^ inner topLeft corner: (inner bottomRight - (0@self scrollBarThickness))]. ! From commits at source.squeak.org Thu Apr 2 07:23:28 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 07:23:30 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.807.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.807.mcz ==================== Summary ==================== Name: Morphic-mt.807 Author: mt Time: 2 April 2015, 9:22:53.044 am UUID: bfd9d718-68d4-f749-932e-755c12a3928d Ancestors: Morphic-mt.806 Fixed #scrollToShow:, which needed an additional offset-lock, because scroll bars tend to call back their float values to the pane, which then tries to calculate pixels again. =============== Diff against Morphic-mt.806 =============== Item was changed: MorphicModel subclass: #ScrollPane + instanceVariableNames: 'scrollBar scroller retractableScrollBar scrollBarOnLeft getMenuSelector getMenuTitleSelector scrollBarHidden hasFocus hScrollBar lockOffset' - instanceVariableNames: 'scrollBar scroller retractableScrollBar scrollBarOnLeft getMenuSelector getMenuTitleSelector scrollBarHidden hasFocus hScrollBar' classVariableNames: '' poolDictionaries: '' category: 'Morphic-Windows'! !ScrollPane commentStamp: 'mk 8/9/2005 10:34' prior: 0! The scroller (a transform) of a scrollPane is driven by the scrollBar. The scroll values vary from 0.0, meaning zero offset to 1.0 meaning sufficient offset such that the bottom of the scrollable material appears 3/4 of the way down the pane. The total distance to achieve this range is called the totalScrollRange. Basic clue about utilization of the ScrollPane class is given in: ScrollPane example1. ScrollPane example2.! Item was changed: ----- Method: ScrollPane>>hScrollBarValue: (in category 'scrolling') ----- hScrollBarValue: scrollValue | x | + lockOffset == true ifTrue: [^ self]. + self hIsScrollbarShowing ifFalse: [^scroller offset: (0 - self hMargin)@scroller offset y]. ((x := self hLeftoverScrollRange * scrollValue) <= 0) ifTrue:[x := 0 - self hMargin]. scroller offset: (x@scroller offset y) ! Item was changed: ----- Method: ScrollPane>>scrollToShow: (in category 'scrolling') ----- scrollToShow: aRectangle + "We have to lock the callback into me because rounding errors in scrollbar values would reset the offset to a different value. The given rectangle may not be visible anymore." scroller offset: (self offsetToShow: aRectangle). + lockOffset := true. + self setScrollDeltas. + lockOffset := false.! - self setScrollDeltas.! Item was changed: ----- Method: ScrollPane>>vScrollBarValue: (in category 'scrolling') ----- vScrollBarValue: scrollValue scroller hasSubmorphs ifFalse: [^ self]. + lockOffset == true ifFalse: [ + scroller offset: (scroller offset x @ (self vLeftoverScrollRange * scrollValue) rounded)]. - scroller offset: (scroller offset x @ (self vLeftoverScrollRange * scrollValue) rounded) ! From commits at source.squeak.org Thu Apr 2 07:30:25 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 07:30:27 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.808.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.808.mcz ==================== Summary ==================== Name: Morphic-mt.808 Author: mt Time: 2 April 2015, 9:29:45.666 am UUID: c0476a80-1468-aa46-bd81-9cbfd132266e Ancestors: Morphic-mt.807 Text fields only show balloon if it has no text. The balloon text will be rendered in that case. =============== Diff against Morphic-mt.807 =============== Item was changed: + ----- Method: PluggableTextMorph>>wantsBalloon (in category 'halos and balloon help') ----- - ----- Method: PluggableTextMorph>>wantsBalloon (in category 'as yet unclassified') ----- wantsBalloon ^ self textMorph contents notEmpty and: [super wantsBalloon]! From commits at source.squeak.org Thu Apr 2 07:38:31 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 07:38:32 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.116.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.116.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.116 Author: mt Time: 2 April 2015, 9:38:28.131 am UUID: 7a34bef1-14ce-d64f-bcfe-11020448a33b Ancestors: ToolBuilder-Morphic-mt.115 Fixed resizing of search input and button bar in ListChooser. =============== Diff against ToolBuilder-Morphic-mt.115 =============== Item was changed: ----- Method: ListChooser>>buildWith: (in category 'building') ----- buildWith: aBuilder + | windowSpec searchBarHeight buttonBarHeight | - | windowSpec | builder := aBuilder. + + searchBarHeight := Preferences standardDefaultTextFont height * 2. + buttonBarHeight := Preferences standardButtonFont height * 4. + windowSpec := self buildWindowWith: builder specs: { + (LayoutFrame fractions: (0@0 corner: 1@0) offsets: (0@0 corner: 0@searchBarHeight)) -> [self buildSearchMorphWith: builder]. + (LayoutFrame fractions: (0@0 corner: 1@1) offsets: (0@searchBarHeight corner: 0@buttonBarHeight negated)) -> [self buildListMorphWith: builder]. + (LayoutFrame fractions: (0@1 corner: 1@1) offsets: (0@buttonBarHeight negated corner: 0@0)) -> [self buildButtonBarWith: builder]. - (0@0 corner: 1@0.05) -> [self buildSearchMorphWith: builder]. - (0@0.05 corner: 1@0.9) -> [self buildListMorphWith: builder]. - (0@0.9 corner: 1@1) -> [self buildButtonBarWith: builder]. }. windowSpec closeAction: #closed. windowSpec extent: self initialExtent. window := builder build: windowSpec. searchMorph := window submorphs detect: [ :each | each isKindOf: PluggableTextMorph ]. searchMorph hideScrollBarsIndefinitely; acceptOnCR: true; setBalloonText: 'Type a string to filter down the listed items'; onKeyStrokeSend: #keyStroke: to: self; hasUnacceptedEdits: true "force acceptOnCR to work even with no text entered". listMorph := window submorphs detect: [ :each | each isKindOf: PluggableListMorph ]. ^ window! From bert at freudenbergs.de Thu Apr 2 08:02:23 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Thu Apr 2 08:02:28 2015 Subject: [squeak-dev] Re: Bug whith contextOn:do: In-Reply-To: References: <85F38DF9-1002-49A4-B11B-0DF96E0A7E76@gmx.de> <1AA83643-080E-4CA3-89ED-3C9F9876AFF1@freudenbergs.de> <1E90C927-7C12-4E98-9CFB-96C60D491FCD@gmx.de> Message-ID: <687515E7-90D5-4554-B558-4882B62FB9FA@freudenbergs.de> Skipped content of type multipart/alternative-------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150402/6da88486/smime-0001.bin From commits at source.squeak.org Thu Apr 2 08:20:46 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 08:20:48 2015 Subject: [squeak-dev] The Trunk: ShoutTests-topa.25.mcz Message-ID: Tobias Pape uploaded a new version of ShoutTests to project The Trunk: http://source.squeak.org/trunk/ShoutTests-topa.25.mcz ==================== Summary ==================== Name: ShoutTests-topa.25 Author: topa Time: 2 April 2015, 10:20:38.688 am UUID: 3e48d7b4-05be-4eee-b294-541752c399bd Ancestors: ShoutTests-eem.24 Try to lower testing time by caching source file access. =============== Diff against ShoutTests-eem.24 =============== Item was changed: ----- Method: SHParserST80Test>>testObjectClass (in category 'tests-smoke') ----- testObjectClass + + CurrentReadOnlySourceFiles cacheDuring: [self verifyClass: Object].! - self verifyClass: Object! Item was changed: ----- Method: SHParserST80Test>>verifyHierarchy: (in category 'utilities') ----- verifyHierarchy: aBehavior + + CurrentReadOnlySourceFiles cacheDuring: [ + aBehavior withAllSubclassesDo: [:class | + self verifyClass: class; verifyClass: class class]].! - aBehavior withAllSubclassesDo: [ :class | self verifyClass: class; verifyClass: class class ]! From commits at source.squeak.org Thu Apr 2 08:22:26 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 08:22:28 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.809.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.809.mcz ==================== Summary ==================== Name: Morphic-mt.809 Author: mt Time: 2 April 2015, 10:21:50.789 am UUID: 39d28574-7b19-7a4f-8a50-b8c828f1b5b2 Ancestors: Morphic-mt.808 Fix selection in lists or trees for context menus. By default, models rely on the current selection for the menu. This can be confusing if the user invokes that menu on a different item. =============== Diff against Morphic-mt.808 =============== Item was changed: ----- Method: PluggableListMorph>>mouseDown: (in category 'events') ----- mouseDown: evt | selectors row | - evt yellowButtonPressed "First check for option (menu) click" - ifTrue: [^ self yellowButtonActivity: evt shiftPressed]. row := self rowAtLocation: evt position. + + evt yellowButtonPressed "First check for option (menu) click" + ifTrue: [ + "Models depend on the correct selection:" + self selectionIndex = (self modelIndexFor: row) + ifFalse: [self changeModelSelection: (self modelIndexFor: row)]. + + ^ self yellowButtonActivity: evt shiftPressed]. row = 0 ifTrue: [^super mouseDown: evt]. "self dragEnabled ifTrue: [aMorph highlightForMouseDown]." selectors := Array with: #click: with: (doubleClickSelector ifNotNil:[#doubleClick:]) with: nil with: (self dragEnabled ifTrue:[#startDrag:] ifFalse:[nil]). evt hand waitForClicksOrDrag: self event: evt selectors: selectors threshold: HandMorph dragThreshold "pixels".! Item was changed: ----- Method: SimpleHierarchicalListMorph>>mouseDown: (in category 'event handling') ----- mouseDown: evt | aMorph selectors | aMorph := self itemFromPoint: evt position. + evt yellowButtonPressed "First check for option (menu) click" + ifTrue: [ + aMorph == selectedMorph + ifFalse: [self setSelectedMorph: aMorph]. + ^ self yellowButtonActivity: evt shiftPressed]. (aMorph notNil and:[aMorph inToggleArea: (aMorph point: evt position from: self)]) ifTrue:[^self toggleExpandedState: aMorph event: evt]. - evt yellowButtonPressed "First check for option (menu) click" - ifTrue: [^ self yellowButtonActivity: evt shiftPressed]. aMorph ifNil:[^super mouseDown: evt]. aMorph highlightForMouseDown. selectors := Array with: #click: with: nil with: nil with: (self dragEnabled ifTrue:[#startDrag:] ifFalse:[nil]). evt hand waitForClicksOrDrag: self event: evt selectors: selectors threshold: HandMorph dragThreshold "pixels".! From commits at source.squeak.org Thu Apr 2 08:57:39 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 08:57:41 2015 Subject: [squeak-dev] The Trunk: System-topa.715.mcz Message-ID: Tobias Pape uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System-topa.715.mcz ==================== Summary ==================== Name: System-topa.715 Author: topa Time: 2 April 2015, 10:57:12.703 am UUID: 2a92cef0-6bb4-47b3-994e-994a626d54c8 Ancestors: System-ul.714 Make SoundService registeredClasses class-based. Categorize in AppRegistry =============== Diff against System-ul.714 =============== Item was changed: + ----- Method: AppRegistry class>>appName (in category 'defaults') ----- - ----- Method: AppRegistry class>>appName (in category 'as yet unclassified') ----- appName "Defaults to the class name, which is probably good enough, but you could override this in subclasses if you want to." ^ self name! Item was changed: + ----- Method: AppRegistry class>>askForDefault (in category 'defaults') ----- - ----- Method: AppRegistry class>>askForDefault (in category 'as yet unclassified') ----- askForDefault self registeredClasses isEmpty ifTrue: [self inform: 'There are no ', self appName, ' applications registered.'. ^ default := nil]. self registeredClasses size = 1 ifTrue: [^ default := self registeredClasses anyOne]. default := UIManager default chooseFrom: (self registeredClasses collect: [:ea | ea nameForViewer]) values: self registeredClasses title: 'Which ', self appName, ' would you prefer?'. default ifNil: [default := self registeredClasses first]. ^default.! Item was changed: + ----- Method: AppRegistry class>>default (in category 'accessing') ----- - ----- Method: AppRegistry class>>default (in category 'as yet unclassified') ----- default ^ default ifNil: [self askForDefault]! Item was changed: + ----- Method: AppRegistry class>>default: (in category 'accessing') ----- - ----- Method: AppRegistry class>>default: (in category 'as yet unclassified') ----- default: aClassOrNil "Sets my default to aClassOrNil. Answers the old default." | oldDefault | oldDefault := default. aClassOrNil ifNotNil: [ self register: aClassOrNil ]. default := aClassOrNil. ^ oldDefault! Item was changed: + ----- Method: AppRegistry class>>defaultOrNil (in category 'accessing') ----- - ----- Method: AppRegistry class>>defaultOrNil (in category 'as yet unclassified') ----- defaultOrNil ^ default! Item was changed: + ----- Method: AppRegistry class>>register: (in category 'registration') ----- - ----- Method: AppRegistry class>>register: (in category 'as yet unclassified') ----- register: aProviderClass (self registeredClasses includes: aProviderClass) ifFalse: [default := nil. "so it'll ask for a new default, since if you're registering a new app you probably want to use it" self registeredClasses add: aProviderClass].! Item was changed: + ----- Method: AppRegistry class>>registeredClasses (in category 'registration') ----- - ----- Method: AppRegistry class>>registeredClasses (in category 'as yet unclassified') ----- registeredClasses ^ registeredClasses ifNil: [registeredClasses := OrderedCollection new]! Item was changed: + ----- Method: AppRegistry class>>removeObsolete (in category 'registration') ----- - ----- Method: AppRegistry class>>removeObsolete (in category 'as yet unclassified') ----- removeObsolete "AppRegistry removeObsoleteClasses" self registeredClasses copy do:[:cls| (cls class isObsolete or:[cls isBehavior and:[cls isObsolete]]) ifTrue:[self unregister: cls]]. self subclasses do:[:cls| cls removeObsolete].! Item was changed: + ----- Method: AppRegistry class>>unregister: (in category 'registration') ----- - ----- Method: AppRegistry class>>unregister: (in category 'as yet unclassified') ----- unregister: aProviderClass (default = aProviderClass) ifTrue: [default := nil]. self registeredClasses remove: aProviderClass ifAbsent: [].! Item was changed: ----- Method: DummySoundSystem class>>initialize (in category 'class initialization') ----- initialize + SoundService register: self.! - SoundService register: self new.! Item was changed: ----- Method: DummySoundSystem class>>unload (in category 'class initialization') ----- unload + SoundService unregister: self.! - SoundService registeredClasses do: [:ss | - (ss isKindOf: self) ifTrue: [SoundService unregister: ss]].! Item was added: + ----- Method: SoundService class>>default (in category 'accessing') ----- + default + + | cls | + cls := super default. + ^ cls new! Item was added: + ----- Method: SoundService class>>defaultOrNil (in category 'accessing') ----- + defaultOrNil + + ^ super defaultOrNil ifNotNil: [:default | + default isBehavior ifTrue: [default new] ifFalse: [default]] + ! Item was changed: + (PackageInfo named: 'System') postscript: '" Convert SoundService registeredClasses to classes if necessary " + [ | currentSoundSystem | + currentSoundSystem := SoundService defaultOrNil. + (SoundService registeredClasses copy collect: [:ss | + SoundService unregister: ss. + ss isBehavior + ifTrue: [ss] + ifFalse: [ss class]] + ) do: [:ssClass | + SoundService register: ssClass]. + SoundService default: (currentSoundSystem + ifNotNil: [:css| css isBehavior ifTrue: [css] ifFalse: [css class]]). + ] value'! - (PackageInfo named: 'System') postscript: '"Preferences already removed by hand, but whose state still lingers:" - LocaleID allInstances do: - [ : each | each - isoLanguage: each isoLanguage - isoCountry: (each isoCountry ifNil: [ each isoCountry ]) ]. - LanguageEnvironment knownEnvironments rehash. - Locale resetKnownLocales'! From commits at source.squeak.org Thu Apr 2 09:00:41 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 09:00:43 2015 Subject: [squeak-dev] The Trunk: Sound-topa.43.mcz Message-ID: Tobias Pape uploaded a new version of Sound to project The Trunk: http://source.squeak.org/trunk/Sound-topa.43.mcz ==================== Summary ==================== Name: Sound-topa.43 Author: topa Time: 2 April 2015, 11:00:29.85 am UUID: c1c2b948-6c86-4cf8-877d-1620433f558e Ancestors: Sound-bf.42 Make SoundService registeredClasses class-based. =============== Diff against Sound-bf.42 =============== Item was changed: ----- Method: BaseSoundSystem class>>initialize (in category 'class initialization') ----- initialize + SoundService register: self.! - SoundService register: self new.! Item was changed: ----- Method: BaseSoundSystem class>>unload (in category 'class initialization') ----- unload + SoundService unregister: self! - SoundService registeredClasses do: [:ss | - (ss isKindOf: self) ifTrue: [SoundService unregister: ss]].! From commits at source.squeak.org Thu Apr 2 09:03:51 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 09:03:52 2015 Subject: [squeak-dev] The Trunk: EToys-topa.120.mcz Message-ID: Tobias Pape uploaded a new version of EToys to project The Trunk: http://source.squeak.org/trunk/EToys-topa.120.mcz ==================== Summary ==================== Name: EToys-topa.120 Author: topa Time: 2 April 2015, 11:03:30.931 am UUID: 759ddd88-411c-4504-a67c-89f0fb6f09f9 Ancestors: EToys-bf.119 Make sure we have a SoundSystem when testing sound. (Alas, DummySoundSystem doesn't cut it here) =============== Diff against EToys-bf.119 =============== Item was changed: TestCase subclass: #TileMorphTest + instanceVariableNames: 'soundSystemBackup' - instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'Etoys-Tests'! Item was added: + ----- Method: TileMorphTest>>setUp (in category 'running') ----- + setUp + + self soundSystemBackup: SoundService defaultOrNil. + SoundService default: BaseSoundSystem.! Item was added: + ----- Method: TileMorphTest>>soundSystemBackup (in category 'accessing') ----- + soundSystemBackup + + ^ soundSystemBackup! Item was added: + ----- Method: TileMorphTest>>soundSystemBackup: (in category 'accessing') ----- + soundSystemBackup: anObject + + soundSystemBackup := anObject! Item was added: + ----- Method: TileMorphTest>>tearDown (in category 'running') ----- + tearDown + + SoundService default: self soundSystemBackup.! From commits at source.squeak.org Thu Apr 2 09:16:34 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 09:16:36 2015 Subject: [squeak-dev] The Trunk: Tools-mt.575.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.575.mcz ==================== Summary ==================== Name: Tools-mt.575 Author: mt Time: 2 April 2015, 11:16:13.988 am UUID: 2f55228c-5225-6443-b1fb-183353e1e261 Ancestors: Tools-mt.574 Made interface of object explorer consistent with interface of inspector. =============== Diff against Tools-mt.574 =============== Item was changed: ----- Method: Inspector>>explorePointers (in category 'menu commands') ----- explorePointers self selectionIndex = 0 ifTrue: [^ self changed: #flash]. + PointerExplorer openOn: self selection.! - PointerExplorer new openExplorerFor: self selection! Item was changed: ----- Method: Object>>explorePointers (in category '*Tools-Debugger') ----- explorePointers + PointerExplorer openOn: self.! - PointerExplorer new openExplorerFor: self! Item was changed: ----- Method: Object>>exploreWithLabel: (in category '*Tools-Explorer') ----- exploreWithLabel: label + ^ ObjectExplorer openOn: self withLabel: label! - ^ ObjectExplorer new openExplorerFor: self withLabel: - label! Item was changed: + ----- Method: ObjectExplorer class>>about (in category 'defaults') ----- - ----- Method: ObjectExplorer class>>about (in category 'as yet unclassified') ----- about StringHolder new textContents: self comment; openLabel: 'about ',self asString! Item was added: + ----- Method: ObjectExplorer class>>explore: (in category 'instance creation') ----- + explore: anObject + + ^ self new explore: anObject! Item was changed: + ----- Method: ObjectExplorer class>>nodeClass (in category 'defaults') ----- - ----- Method: ObjectExplorer class>>nodeClass (in category 'as yet unclassified') ----- nodeClass ^ ObjectExplorerWrapper! Item was added: + ----- Method: ObjectExplorer class>>openOn: (in category 'instance creation') ----- + openOn: anObject + + ^ self openOn: anObject withLabel: nil! Item was added: + ----- Method: ObjectExplorer class>>openOn:withLabel: (in category 'instance creation') ----- + openOn: anObject withLabel: label + "ObjectExplorer openOn: Smalltalk withLabel: 'Smalltalk'" + + ^ ToolBuilder open: (self explore: anObject) label: label! Item was changed: ----- Method: ObjectExplorer>>buildWith: (in category 'toolbuilder') ----- buildWith: builder | windowSpec treeSpec textSpec | windowSpec := builder pluggableWindowSpec new. windowSpec model: self; children: OrderedCollection new; label: #label. treeSpec := builder pluggableTreeSpec new. treeSpec model: self; nodeClass: self class nodeClass; roots: #getList; keyPress: #explorerKey:from:event:; getSelected: #currentSelection; setSelected: #currentSelection:; setSelectedParent: #currentParent:; menu: #genericMenu:; autoDeselect: false; columns: (ObjectExplorerWrapper showContentsInColumns ifTrue: [{ [:listMorph | (listMorph filteredItems collect: [:item | item preferredWidthOfColumn: 1]) max]. nil "take all the space"}]); frame: (0@0 corner: 1@0.85). windowSpec children add: treeSpec. textSpec := builder pluggableTextSpec new. textSpec model: self; menu: #codePaneMenu:shifted:; help: 'Evaluate expressions for the current tree selection...' translated; frame: (0@0.85 corner: 1@1). windowSpec children add: textSpec. + [^ builder build: windowSpec] + ensure: [self changed: #expandRootsRequested]! - ^ builder build: windowSpec! Item was added: + ----- Method: ObjectExplorer>>explore: (in category 'user interface') ----- + explore: anObject + + self rootObject: anObject.! Item was removed: - ----- Method: ObjectExplorer>>openExplorerFor: (in category 'user interface') ----- - openExplorerFor: anObject - "ObjectExplorer new openExplorerFor: Smalltalk." - - ^ self openExplorerFor: anObject withLabel: nil! Item was removed: - ----- Method: ObjectExplorer>>openExplorerFor:withLabel: (in category 'user interface') ----- - openExplorerFor: anObject withLabel: label - "ObjectExplorer new openExplorerFor: Smalltalk withLabel: 'Smalltalk'" - - ToolBuilder open: self label: label. - self rootObject: anObject.! Item was changed: + ----- Method: PointerExplorer class>>nodeClass (in category 'defaults') ----- - ----- Method: PointerExplorer class>>nodeClass (in category 'as yet unclassified') ----- nodeClass ^ PointerExplorerWrapper! Item was changed: ----- Method: StandardToolSet class>>explore: (in category 'inspecting') ----- explore: anObject + + ^ ObjectExplorer openOn: anObject! - "Open an explorer on the given object." - ^ObjectExplorer new openExplorerFor: anObject! From commits at source.squeak.org Thu Apr 2 09:18:26 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 09:18:28 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.810.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.810.mcz ==================== Summary ==================== Name: Morphic-mt.810 Author: mt Time: 2 April 2015, 11:17:44.865 am UUID: 644a4b6a-4767-ec45-992c-9ed10ac54871 Ancestors: Morphic-mt.809 Exploring a morph via its halo menu now attaches the explorer also to the hand -- like inspecting does. =============== Diff against Morphic-mt.809 =============== Item was changed: ----- Method: Morph>>buildDebugMenu: (in category 'debug and other') ----- buildDebugMenu: aHand "Answer a debugging menu for the receiver. The hand argument is seemingly historical and plays no role presently" | aMenu aPlayer | aMenu := MenuMorph new defaultTarget: self. aMenu addStayUpItem. (self hasProperty: #errorOnDraw) ifTrue: [aMenu add: 'start drawing again' translated action: #resumeAfterDrawError. aMenu addLine]. (self hasProperty: #errorOnStep) ifTrue: [aMenu add: 'start stepping again' translated action: #resumeAfterStepError. aMenu addLine]. aMenu add: 'inspect morph' translated action: #inspectInMorphic:. aMenu add: 'inspect owner chain' translated action: #inspectOwnerChain. Smalltalk isMorphic ifFalse: [aMenu add: 'inspect morph (in MVC)' translated action: #inspect]. self isMorphicModel ifTrue: [aMenu add: 'inspect model' translated target: self model action: #inspect]. (aPlayer := self player) ifNotNil: [aMenu add: 'inspect player' translated target: aPlayer action: #inspect]. + aMenu add: 'explore morph' translated target: self selector: #exploreInMorphic:. - aMenu add: 'explore morph' translated target: self selector: #explore. aMenu addLine. aPlayer ifNotNil: [ aMenu add: 'viewer for Player' translated target: self player action: #beViewed. aMenu balloonTextForLastItem: 'Opens a viewer on my Player -- this is the same thing you get if you click on the cyan "View" halo handle' translated ]. aMenu add: 'viewer for Morph' translated target: self action: #viewMorphDirectly. aMenu balloonTextForLastItem: 'Opens a Viewer on this Morph, rather than on its Player' translated. aMenu addLine. aPlayer ifNotNil: [aPlayer class isUniClass ifTrue: [ aMenu add: 'browse player class' translated target: aPlayer action: #browseHierarchy]]. aMenu add: 'browse morph class' translated target: self selector: #browseHierarchy. (self isMorphicModel) ifTrue: [aMenu add: 'browse model class' target: self model selector: #browseHierarchy]. aMenu addLine. self addViewingItemsTo: aMenu. aMenu add: 'make own subclass' translated action: #subclassMorph; add: 'save morph in file' translated action: #saveOnFile; addLine; add: 'call #tempCommand' translated action: #tempCommand; add: 'define #tempCommand' translated action: #defineTempCommand; addLine; add: 'control-menu...' translated target: self selector: #invokeMetaMenu:; add: 'edit balloon help' translated action: #editBalloonHelpText. ^ aMenu! Item was added: + ----- Method: Morph>>exploreInMorphic (in category 'menus') ----- + exploreInMorphic + self currentHand attachMorph: (ToolSet explore: self).! Item was added: + ----- Method: Morph>>exploreInMorphic: (in category 'menus') ----- + exploreInMorphic: evt + evt hand attachMorph: (ToolSet explore: self).! From commits at source.squeak.org Thu Apr 2 09:45:06 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 09:45:07 2015 Subject: [squeak-dev] The Trunk: Tools-mt.576.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.576.mcz ==================== Summary ==================== Name: Tools-mt.576 Author: mt Time: 2 April 2015, 11:44:45 am UUID: a36d49ef-4d1f-b644-9acb-abe7a9334b3c Ancestors: Tools-mt.575 Fixes the bug with the wrang label in the system window of object explorers. =============== Diff against Tools-mt.575 =============== Item was changed: ----- Method: ObjectExplorer class>>openOn: (in category 'instance creation') ----- openOn: anObject + ^ ToolBuilder open: (self explore: anObject)! - ^ self openOn: anObject withLabel: nil! From commits at source.squeak.org Thu Apr 2 09:47:04 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 09:47:06 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.811.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.811.mcz ==================== Summary ==================== Name: Morphic-mt.811 Author: mt Time: 2 April 2015, 11:46:28.024 am UUID: 9490b7c4-b15f-6847-a334-637b0543c8dc Ancestors: Morphic-mt.810 Some fixes in system windows regarding labels. =============== Diff against Morphic-mt.810 =============== Item was removed: - ----- Method: SystemWindow>>externalName (in category 'label') ----- - externalName - "Answer the name by which the receiver is known in the UI" - - ^ labelString! Item was added: + ----- Method: SystemWindow>>knownName (in category 'label') ----- + knownName + + ^ self label! Item was changed: ----- Method: SystemWindow>>setLabel: (in category 'label') ----- setLabel: aString | frame | labelString := aString. label ifNil: [^ self]. + label contents: (aString ifNil: ['']). - label contents: aString. self labelWidgetAllowance. "Sets it if not already" self isCollapsed ifTrue: [self extent: (label width + labelWidgetAllowance) @ (self labelHeight + 2)] ifFalse: [label fitContents; setWidth: (label width min: bounds width - labelWidgetAllowance). label align: label bounds topCenter with: bounds topCenter + (0@borderWidth). collapsedFrame ifNotNil: [collapsedFrame := collapsedFrame withWidth: label width + labelWidgetAllowance]]. frame := LayoutFrame new. frame leftFraction: 0.5; topFraction: 0.5; leftOffset: label width negated // 2; topOffset: label height negated // 2. label layoutFrame: frame. ! From nicolas.cellier.aka.nice at gmail.com Thu Apr 2 10:04:40 2015 From: nicolas.cellier.aka.nice at gmail.com (Nicolas Cellier) Date: Thu Apr 2 10:04:42 2015 Subject: [squeak-dev] The Trunk: Collections-ul.607.mcz In-Reply-To: <551c6c75.47cee50a.6183.ffffc131SMTPIN_ADDED_MISSING@mx.google.com> References: <551c6c75.47cee50a.6183.ffffc131SMTPIN_ADDED_MISSING@mx.google.com> Message-ID: Just a side note: nextFloat is broken in the sense that it will fail to answer the nearest floating point value to the specified decimal value. OK, it's reasonably fast, but the comments should mention the trade offs. Also in 32 bits VM, nextFloat might be slower than NumberParser when numbers are specified with many decimal digits. Nicolas 2015-04-02 0:08 GMT+02:00 : > Levente Uzonyi uploaded a new version of Collections to project The Trunk: > http://source.squeak.org/trunk/Collections-ul.607.mcz > > ==================== Summary ==================== > > Name: Collections-ul.607 > Author: ul > Time: 2 April 2015, 12:07:14.622 am > UUID: 607c7a3f-c462-454c-8e18-02c49e4ae91a > Ancestors: Collections-ul.606 > > Simplified CharacterSet class>>separators. > Fixed ReadStream >> #nextFloat, when collection is not a ByteString. > > =============== Diff against Collections-ul.606 =============== > > Item was changed: > ----- Method: CharacterSet class>>separators (in category 'accessing') > ----- > separators > "return a set containing just the whitespace characters" > > + ^Separators ifNil: [ Separators := self newFrom: Character > separators ]! > - ^Separators ifNil: [ > - Separators := self new > - addAll: Character separators; > - yourself ]! > > Item was changed: > ----- Method: ReadStream>>nextFloat (in category 'accessing') ----- > nextFloat > "Read a floating point value from the receiver. This method is > highly optimized for cases > where many floating point values need to be read subsequently. And > if this needs to go > even faster, look at the inner loops fetching the characters - > moving those into a plugin > would speed things up even more." > | buffer count sign index cc value digit fraction exp startIndex > anyDigit digitNeeded | > buffer := collection. > count := readLimit. > index := position+1. > > "Skip separators" > + index := ByteString findFirstInString: buffer inSet: CharacterSet > nonSeparators byteArrayMap startingAt: index. > - index := buffer indexOfAnyOf: CharacterSet nonSeparators > startingAt: index. > index = 0 ifTrue:[self setToEnd. ^nil]. > > "check for sign" > digitNeeded := false. > sign := 1. cc := buffer byteAt: index. > cc = 45 "$- asciiValue" > ifTrue:[sign := -1. index := index+1. digitNeeded := true] > ifFalse:[cc = 43 "$+ asciiValue" ifTrue:[index := > index+1. digitNeeded := true]]. > > "Read integer part" > startIndex := index. > value := 0. > [index <= count and:[ > digit := (buffer byteAt: index) - 48. "$0 asciiValue" > digit >= 0 and:[digit <= 9]]] whileTrue:[ > value := value * 10 + digit. > index := index + 1. > ]. > anyDigit := index > startIndex. > index > count ifTrue:[ > (digitNeeded and:[anyDigit not]) ifTrue:[^self error: 'At > least one digit expected']. > self setToEnd. ^value asFloat * sign]. > > (buffer byteAt: index) = 46 "$. asciiValue" > ifTrue:["." > index := index+1. > startIndex := index. > "NOTE: fraction and exp below can overflow into > LargeInteger range. If they do, then things slow down horribly due to the > relatively slow LargeInt -> Float conversion. This can be avoided by > changing fraction and exp to use floats to begin with (0.0 and 1.0 > respectively), however, this will give different results to > Float>>readFrom: and it is not clear if that is acceptable here." > fraction := 0. exp := 1. > [index <= count and:[ > digit := (buffer byteAt: index) - 48. "$0 > asciiValue" > digit >= 0 and:[digit <= 9]]] whileTrue:[ > fraction := fraction * 10 + digit. > exp := exp * 10. > index := index + 1. > ]. > value := value + (fraction asFloat / exp asFloat). > anyDigit := anyDigit or:[index > startIndex]. > ]. > value := value asFloat * sign. > > "At this point we require at least one digit to avoid allowing: > - . ('0.0' without leading digits) > - e32 ('0e32' without leading digits) > - .e32 ('0.0e32' without leading digits) > but these are currently allowed: > - .5 (0.5) > - 1. ('1.0') > - 1e32 ('1.0e32') > - 1.e32 ('1.0e32') > - .5e32 ('0.5e32') > " > anyDigit ifFalse:["Check for NaN/Infinity first" > (count - index >= 2 and:[(buffer copyFrom: index to: > index+2) = 'NaN']) > ifTrue:[position := index+2. ^Float nan * sign]. > (count - index >= 7 and:[(buffer copyFrom: index to: > index+7) = 'Infinity']) > ifTrue:[position := index+7. ^Float infinity * > sign]. > ^self error: 'At least one digit expected' > ]. > > index > count ifTrue:[self setToEnd. ^value asFloat]. > > (buffer byteAt: index) = 101 "$e asciiValue" > ifTrue:["e[+|-]" > index := index+1. "skip e" > sign := 1. cc := buffer byteAt: index. > cc = 45 "$- asciiValue" > ifTrue:[sign := -1. index := index+1] > ifFalse:[cc = 43 "$+ asciiValue" ifTrue:[index := > index+1]]. > startIndex := index. > exp := 0. anyDigit := false. > [index <= count and:[ > digit := (buffer byteAt: index) - 48. "$0 > asciiValue" > digit >= 0 and:[digit <= 9]]] whileTrue:[ > exp := exp * 10 + digit. > index := index + 1. > ]. > index> startIndex ifFalse:[^self error: 'Exponent > expected']. > value := value * (10.0 raisedToInteger: exp * sign). > ]. > > position := index-1. > ^value! > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150402/74ce9c54/attachment.htm From marcel.taeumel at student.hpi.uni-potsdam.de Thu Apr 2 11:52:11 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Thu Apr 2 12:04:00 2015 Subject: [squeak-dev] Re: The Trunk: Tools-cmm.572.mcz In-Reply-To: References: Message-ID: <1427975531355-4816883.post@n4.nabble.com> I fixed something here: http://forum.world.st/The-Trunk-Tools-mt-576-mcz-td4816865.html Does it now work for you? Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Tools-cmm-572-mcz-tp4816755p4816883.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From frank.shearar at gmail.com Thu Apr 2 12:33:18 2015 From: frank.shearar at gmail.com (Frank Shearar) Date: Thu Apr 2 12:33:21 2015 Subject: [squeak-dev] build.squeak.org slaves: which are there after all? In-Reply-To: <34983.136.2.1.102.1427827494.squirrel@webmail.msen.com> References: <1FAA43DA-1EEB-4806-8747-F14066B6FCD0@gmx.de> <34983.136.2.1.102.1427827494.squirrel@webmail.msen.com> Message-ID: On 31 March 2015 at 19:44, David T. Lewis wrote: >> Hi >> >> I am looking around on our Jenkins CI and was puzzled that >> there are several slave nodes (yay) but none of them >> seem to have been alive for some time (nay?) >> >> >> >> what can we do? >> >> Best >> -Tobias >> > > The first thing we should do: > > Every job on the Jenkins CI should have a clear comment that says what it > is supposed to be doing, and who is responsible for it. Likewise for the > slave servers - if you cannot figure out what they are and who they belong > to, then they should not be there. I mostly agree with the comment about the slaves. Mostly. At any rate, andrad, havnor, norst and way are mine. I'll remove all but norst, because they sadly no longer exist. It's a pity Jenkins doesn't display the "title" of the node, or you'd see that norst is "Frank's OS X box", wihich I consider to be sufficiently informative :) frank > Dave > > > From frank.shearar at gmail.com Thu Apr 2 12:38:18 2015 From: frank.shearar at gmail.com (Frank Shearar) Date: Thu Apr 2 12:38:21 2015 Subject: [squeak-dev] build.squeak.org slaves: which are there after all? In-Reply-To: References: <1FAA43DA-1EEB-4806-8747-F14066B6FCD0@gmx.de> <34983.136.2.1.102.1427827494.squirrel@webmail.msen.com> Message-ID: On 2 April 2015 at 13:33, Frank Shearar wrote: > On 31 March 2015 at 19:44, David T. Lewis wrote: >>> Hi >>> >>> I am looking around on our Jenkins CI and was puzzled that >>> there are several slave nodes (yay) but none of them >>> seem to have been alive for some time (nay?) >>> >>> >>> >>> what can we do? >>> >>> Best >>> -Tobias >>> >> >> The first thing we should do: >> >> Every job on the Jenkins CI should have a clear comment that says what it >> is supposed to be doing, and who is responsible for it. Likewise for the >> slave servers - if you cannot figure out what they are and who they belong >> to, then they should not be there. > > I mostly agree with the comment about the slaves. Mostly. > > At any rate, andrad, havnor, norst and way are mine. I'll remove all > but norst, because they sadly no longer exist. > > It's a pity Jenkins doesn't display the "title" of the node, or you'd > see that norst is "Frank's OS X box", wihich I consider to be > sufficiently informative :) Forgot to add: "lfp" is "least fixed point" is Tony Garnock-Jones. I've pinged him. "jgon" is Jeff Gonis. I've pinged him too. You can find the "titles" of the nodes at URLs like http://build.squeak.org/computer/norst/ frank > frank > > >> Dave >> >> >> From leves at elte.hu Thu Apr 2 13:06:34 2015 From: leves at elte.hu (Levente Uzonyi) Date: Thu Apr 2 13:06:39 2015 Subject: [squeak-dev] The Trunk: Collections-ul.607.mcz In-Reply-To: References: <551c6c75.47cee50a.6183.ffffc131SMTPIN_ADDED_MISSING@mx.google.com> Message-ID: I don't see any senders of #nextFloat in my image, so I think we can safely trade performance for quality here. Levente On Thu, 2 Apr 2015, Nicolas Cellier wrote: > Just a side note: nextFloat is broken in the sense that it will fail to answer the nearest floating point value to the specified decimal value. > > OK, it's reasonably fast, but the comments should mention the trade offs. > > Also in 32 bits VM, nextFloat might be slower than NumberParser when numbers are specified with many decimal digits. > > Nicolas > > 2015-04-02 0:08 GMT+02:00 : > Levente Uzonyi uploaded a new version of Collections to project The Trunk: > http://source.squeak.org/trunk/Collections-ul.607.mcz > > ==================== Summary ==================== > > Name: Collections-ul.607 > Author: ul > Time: 2 April 2015, 12:07:14.622 am > UUID: 607c7a3f-c462-454c-8e18-02c49e4ae91a > Ancestors: Collections-ul.606 > > Simplified CharacterSet class>>separators. > Fixed ReadStream >> #nextFloat, when collection is not a ByteString. > > =============== Diff against Collections-ul.606 =============== > > Item was changed: > ? ----- Method: CharacterSet class>>separators (in category 'accessing') ----- > ? separators > ? ? ? ? "return a set containing just the whitespace characters" > > +? ? ? ?^Separators ifNil: [ Separators := self newFrom: Character separators ]! > -? ? ? ?^Separators ifNil: [ > -? ? ? ? ? ? ? ?Separators := self new > -? ? ? ? ? ? ? ? ? ? ? ?addAll: Character separators; > -? ? ? ? ? ? ? ? ? ? ? ?yourself ]! > > Item was changed: > ? ----- Method: ReadStream>>nextFloat (in category 'accessing') ----- > ? nextFloat > ? ? ? ? "Read a floating point value from the receiver. This method is highly optimized for cases > ? ? ? ? where many floating point values need to be read subsequently. And if this needs to go > ? ? ? ? even faster, look at the inner loops fetching the characters - moving those into a plugin > ? ? ? ? would speed things up even more." > ? ? ? ? | buffer count sign index cc value digit fraction exp startIndex anyDigit digitNeeded | > ? ? ? ? buffer := collection. > ? ? ? ? count := readLimit. > ? ? ? ? index := position+1. > > ? ? ? ? "Skip separators" > +? ? ? ?index := ByteString findFirstInString: buffer inSet: CharacterSet nonSeparators byteArrayMap startingAt: index. > -? ? ? ?index := buffer indexOfAnyOf: CharacterSet nonSeparators startingAt: index. > ? ? ? ? index = 0 ifTrue:[self setToEnd. ^nil]. > > ? ? ? ? "check for sign" > ? ? ? ? digitNeeded := false. > ? ? ? ? sign := 1. cc := buffer byteAt: index. > ? ? ? ? cc = 45 "$- asciiValue" > ? ? ? ? ? ? ? ? ifTrue:[sign := -1. index := index+1. digitNeeded := true] > ? ? ? ? ? ? ? ? ifFalse:[cc =? 43 "$+ asciiValue" ifTrue:[index := index+1. digitNeeded := true]]. > > ? ? ? ? "Read integer part" > ? ? ? ? startIndex := index. > ? ? ? ? value := 0. > ? ? ? ? [index <= count and:[ > ? ? ? ? ? ? ? ? digit := (buffer byteAt: index) - 48. "$0 asciiValue" > ? ? ? ? ? ? ? ? digit >= 0 and:[digit <= 9]]] whileTrue:[ > ? ? ? ? ? ? ? ? ? ? ? ? value := value * 10 + digit. > ? ? ? ? ? ? ? ? ? ? ? ? index := index + 1. > ? ? ? ? ]. > ? ? ? ? anyDigit := index > startIndex. > ? ? ? ? index > count ifTrue:[ > ? ? ? ? ? ? ? ? (digitNeeded and:[anyDigit not]) ifTrue:[^self error: 'At least one digit expected']. > ? ? ? ? ? ? ? ? self setToEnd. ^value asFloat * sign]. > > ? ? ? ? (buffer byteAt: index) = 46 "$. asciiValue" ifTrue:["." > ? ? ? ? ? ? ? ? index := index+1. > ? ? ? ? ? ? ? ? startIndex := index. > ? ? ? ? ? ? ? ? "NOTE: fraction and exp below can overflow into LargeInteger range. If they do, then things slow down horribly due to the relatively slow LargeInt -> Float > conversion. This can be avoided by changing fraction and exp to use floats to begin with (0.0 and 1.0 respectively), however, this will give different results to Float>>readFrom: > and it is not clear if that is acceptable here." > ? ? ? ? ? ? ? ? fraction := 0. exp := 1. > ? ? ? ? ? ? ? ? [index <= count and:[ > ? ? ? ? ? ? ? ? ? ? ? ? digit := (buffer byteAt: index) - 48. "$0 asciiValue" > ? ? ? ? ? ? ? ? ? ? ? ? digit >= 0 and:[digit <= 9]]] whileTrue:[ > ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? fraction := fraction * 10 + digit. > ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? exp := exp * 10. > ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? index := index + 1. > ? ? ? ? ? ? ? ? ]. > ? ? ? ? ? ? ? ? value := value + (fraction asFloat / exp asFloat). > ? ? ? ? ? ? ? ? anyDigit := anyDigit or:[index > startIndex]. > ? ? ? ? ]. > ? ? ? ? value := value asFloat * sign. > > ? ? ? ? "At this point we require at least one digit to avoid allowing: > ? ? ? ? ? ? ? ? - . ('0.0' without leading digits) > ? ? ? ? ? ? ? ? - e32 ('0e32' without leading digits) > ? ? ? ? ? ? ? ? - .e32 ('0.0e32' without leading digits) > ? ? ? ? but these are currently allowed: > ? ? ? ? ? ? ? ? - .5 (0.5) > ? ? ? ? ? ? ? ? - 1. ('1.0') > ? ? ? ? ? ? ? ? - 1e32 ('1.0e32') > ? ? ? ? ? ? ? ? - 1.e32 ('1.0e32') > ? ? ? ? ? ? ? ? - .5e32 ('0.5e32') > ? ? ? ? " > ? ? ? ? anyDigit ifFalse:["Check for NaN/Infinity first" > ? ? ? ? ? ? ? ? (count - index >= 2 and:[(buffer copyFrom: index to: index+2) = 'NaN']) > ? ? ? ? ? ? ? ? ? ? ? ? ifTrue:[position := index+2. ^Float nan * sign]. > ? ? ? ? ? ? ? ? (count - index >= 7 and:[(buffer copyFrom: index to: index+7) = 'Infinity']) > ? ? ? ? ? ? ? ? ? ? ? ? ifTrue:[position := index+7. ^Float infinity * sign]. > ? ? ? ? ? ? ? ? ^self error: 'At least one digit expected' > ? ? ? ? ]. > > ? ? ? ? index > count ifTrue:[self setToEnd. ^value asFloat]. > > ? ? ? ? (buffer byteAt: index) = 101 "$e asciiValue" ifTrue:["e[+|-]" > ? ? ? ? ? ? ? ? index := index+1. "skip e" > ? ? ? ? ? ? ? ? sign := 1. cc := buffer byteAt: index. > ? ? ? ? ? ? ? ? cc = 45 "$- asciiValue" > ? ? ? ? ? ? ? ? ? ? ? ? ifTrue:[sign := -1. index := index+1] > ? ? ? ? ? ? ? ? ? ? ? ? ifFalse:[cc = 43 "$+ asciiValue" ifTrue:[index := index+1]]. > ? ? ? ? ? ? ? ? startIndex := index. > ? ? ? ? ? ? ? ? exp := 0. anyDigit := false. > ? ? ? ? ? ? ? ? [index <= count and:[ > ? ? ? ? ? ? ? ? ? ? ? ? digit := (buffer byteAt: index) - 48. "$0 asciiValue" > ? ? ? ? ? ? ? ? ? ? ? ? digit >= 0 and:[digit <= 9]]] whileTrue:[ > ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? exp := exp * 10 + digit. > ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? index := index + 1. > ? ? ? ? ? ? ? ? ]. > ? ? ? ? ? ? ? ? index> startIndex ifFalse:[^self error: 'Exponent expected']. > ? ? ? ? ? ? ? ? value := value * (10.0 raisedToInteger: exp * sign). > ? ? ? ? ]. > > ? ? ? ? position := index-1. > ? ? ? ? ^value! > > > > > From unoduetre at poczta.onet.pl Thu Apr 2 13:20:41 2015 From: unoduetre at poczta.onet.pl (Mateusz Grotek) Date: Thu Apr 2 13:17:48 2015 Subject: [squeak-dev] A bug with class renaming Message-ID: <1427980841.15762.0@mglap> Is this problem already solved in the forthcoming 2.6 or it's new? To reproduce: 1. Create a class. 2. Rightclick on the class name and choose "Rename class". 3. Enter the new name and accept. From Das.Linux at gmx.de Thu Apr 2 13:19:10 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 2 13:19:13 2015 Subject: [squeak-dev] A bug with class renaming In-Reply-To: <1427980841.15762.0@mglap> References: <1427980841.15762.0@mglap> Message-ID: <672DEA33-FEF0-447B-AA46-BB48C1E91335@gmx.de> Hey On 02.04.2015, at 15:20, Mateusz Grotek wrote: > Is this problem already solved in the forthcoming 2.6 or it's new? > > To reproduce: > 1. Create a class. > 2. Rightclick on the class name and choose "Rename class". > 3. Enter the new name and accept. This is fixed for 4.5 and Trunk (upcoming 4.6). For 4.5 please use the update functionality. Best -Tobias From Das.Linux at gmx.de Thu Apr 2 13:22:10 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 2 13:22:13 2015 Subject: [squeak-dev] Jenkins Message-ID: <87F4E219-FD97-46FF-9A0A-DD96DFD91096@gmx.de> Hi I did an update-dance for Jenkins and also installed the doony theme. Also, I installed the dependency graph plugin, so that we can see what depends on what easily: http://build.squeak.org/depgraph-view Best -Tobias PS: I have still to look at some 'now outdated files' as jenkin reported? From unoduetre at poczta.onet.pl Thu Apr 2 14:06:48 2015 From: unoduetre at poczta.onet.pl (Mateusz Grotek) Date: Thu Apr 2 14:03:44 2015 Subject: [squeak-dev] A bug with class renaming In-Reply-To: <672DEA33-FEF0-447B-AA46-BB48C1E91335@gmx.de> (from Das.Linux@gmx.de on Thu Apr 2 15:19:10 2015) Message-ID: <1427983608.16738.0@mglap> Dnia 02.04.2015 15:19:10, Tobias Pape napisa?(a): > Hey > > On 02.04.2015, at 15:20, Mateusz Grotek > wrote: > > > Is this problem already solved in the forthcoming 2.6 or it's new? > > > > To reproduce: > > 1. Create a class. > > 2. Rightclick on the class name and choose "Rename class". > > 3. Enter the new name and accept. > > > This is fixed for 4.5 and Trunk (upcoming 4.6). > For 4.5 please use the update functionality. > > Best > -Tobias > > > > Hi, (Of course I wanted to say 4.6, not 2.6) Well, it seems the update (click on logo, and then "Update Squeak") does not solve the problem. Can you verify it? Mateusz From frank.shearar at gmail.com Thu Apr 2 14:06:58 2015 From: frank.shearar at gmail.com (Frank Shearar) Date: Thu Apr 2 14:07:01 2015 Subject: [squeak-dev] Jenkins In-Reply-To: <87F4E219-FD97-46FF-9A0A-DD96DFD91096@gmx.de> References: <87F4E219-FD97-46FF-9A0A-DD96DFD91096@gmx.de> Message-ID: On 2 April 2015 at 14:22, Tobias Pape wrote: > Hi > > I did an update-dance for Jenkins and also installed the > doony theme. > > Also, I installed the dependency graph plugin, so that we can see what depends on > what easily: > > http://build.squeak.org/depgraph-view Ooh, I like that! frank > Best > -Tobias > > PS: I have still to look at some 'now outdated files' as jenkin reported? > > > From Das.Linux at gmx.de Thu Apr 2 14:07:54 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 2 14:07:59 2015 Subject: [squeak-dev] A bug with class renaming In-Reply-To: <1427983608.16738.0@mglap> References: <1427983608.16738.0@mglap> Message-ID: Hi Mateusz On 02.04.2015, at 16:06, Mateusz Grotek wrote: > Dnia 02.04.2015 15:19:10, Tobias Pape napisa?(a): >> Hey >> On 02.04.2015, at 15:20, Mateusz Grotek wrote: >> > Is this problem already solved in the forthcoming 2.6 or it's new? >> > >> > To reproduce: >> > 1. Create a class. >> > 2. Rightclick on the class name and choose "Rename class". >> > 3. Enter the new name and accept. >> This is fixed for 4.5 and Trunk (upcoming 4.6). >> For 4.5 please use the update functionality. >> Best >> -Tobias > Hi, > (Of course I wanted to say 4.6, not 2.6) Well, it seems the update (click on logo, and then "Update Squeak") does not solve the problem. Can you verify it? > Mateusz Can you explain what happens after step 3 and what should happen? It might be we are talking about different bugs. Best -Tobias From commits at source.squeak.org Thu Apr 2 14:23:04 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 14:23:08 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.812.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.812.mcz ==================== Summary ==================== Name: Morphic-mt.812 Author: mt Time: 2 April 2015, 4:22:28.115 pm UUID: 9dacc5ba-ac6a-db4f-bf8f-c42885c6642a Ancestors: Morphic-mt.811 Fixed main docking bar to support interaction with outermost pixels. This is especially useful in fullscreen mode where you want to navigate to topLeft and open the Squeak menu or topRight and click to exit fullscreen. Before, there were pixel offsets and thus you had to acquire your target carefully. This fix includes a replacement of the SearchBarMorph with one that uses tool builder and the pluggable text morph. =============== Diff against Morphic-mt.811 =============== Item was changed: ----- Method: DockingBarMorph>>handleListenEvent: (in category 'events-processing') ----- handleListenEvent: anEvent " I am registered as a keyboardListener of the ActiveHand, watching for ctrl- keystrokes, and upon them if I have an nth menu item, I'll activate myself and select it. " (anEvent controlKeyPressed and: [ anEvent keyValue between: 48 " $0 asciiValue " and: 55 " $7 asciiValue " ]) ifTrue: [ | index itemToSelect | index := anEvent keyValue - 48. itemToSelect := (submorphs select: [ :each | each isKindOf: DockingBarItemMorph ]) at: index ifAbsent: [ + ^self searchBarMorph ifNotNil: [ :morph | + morph model activate: anEvent in: morph ] ]. - ^self searchBarMorph ifNotNil: [ :searchBar | - searchBar activate: anEvent ] ]. self activate: anEvent. self selectItem: itemToSelect event: anEvent ]! Item was changed: ----- Method: DockingBarMorph>>searchBarMorph (in category 'events-processing') ----- searchBarMorph + ^self submorphs detect: [ :each | each knownName = #searchBar ] ifNone: [ nil ]! - ^self submorphs detect: [ :each | each class = SearchBarMorph ] ifNone: [ nil ]! Item was added: + Model subclass: #SearchBar + instanceVariableNames: 'searchTerm selection' + classVariableNames: '' + poolDictionaries: '' + category: 'Morphic-Menus-DockingBar'! Item was added: + ----- Method: SearchBar class>>build (in category 'as yet unclassified') ----- + build + + ^ ToolBuilder build: self new! Item was added: + ----- Method: SearchBar>>activate:in: (in category 'accessing') ----- + activate: event in: morph + + self searchTerm: ''. "We cannot select all here, because we only get contents on #accept, which triggers a search. So earse the term." + event hand newKeyboardFocus: morph textMorph.! Item was added: + ----- Method: SearchBar>>buildWith: (in category 'toolbuilder') ----- + buildWith: builder + + ^ (builder build: (builder pluggableInputFieldSpec new + model: self; + getText: #searchTerm; + setText: #smartSearch:in:; + menu: #menu:shifted:; + selection: #selection; + help: 'Search...' translated)) + name: #searchBar; + wantsFrameAdornments: false; + borderWidth: 0; + yourself! Item was added: + ----- Method: SearchBar>>menu:shifted: (in category 'accessing') ----- + menu: aMenu shifted: aBoolean + + ^ StringHolder codePaneMenu: aMenu shifted: aBoolean! Item was added: + ----- Method: SearchBar>>searchTerm (in category 'accessing') ----- + searchTerm + + ^ searchTerm ifNil: ['']! Item was added: + ----- Method: SearchBar>>searchTerm: (in category 'accessing') ----- + searchTerm: aString + + searchTerm := aString. + self changed: #searchTerm.! Item was added: + ----- Method: SearchBar>>selection (in category 'accessing') ----- + selection + + ^ selection ifNil: [1 to: 0]! Item was added: + ----- Method: SearchBar>>selection: (in category 'accessing') ----- + selection: anInterval + + selection := anInterval. + self changed: #selection.! Item was added: + ----- Method: SearchBar>>smartSearch:in: (in category 'searching') ----- + smartSearch: text in: morph + "Take the user input and perform an appropriate search" + | input newContents | + input := text asString ifEmpty:[^self]. + (Smalltalk bindingOf: input) ifNotNil:[:assoc| | global | + "It's a global or a class" + global := assoc value. + ^ToolSet browse: (global isBehavior ifTrue:[global] ifFalse:[global class]) selector: nil. + ]. + (SystemNavigation new allImplementorsOf: input asSymbol) ifNotEmpty:[:list| + ^SystemNavigation new + browseMessageList: list + name: 'Implementors of ' , input + ]. + input first isUppercase ifTrue:[ + (UIManager default classFromPattern: input withCaption: '') ifNotNil:[:aClass| + ^ToolSet browse: aClass selector: nil. + ]. + ] ifFalse:[ + ^ToolSet default browseMessageNames: input + ]. + newContents := input, ' -- not found.'. + + self searchTerm: newContents. + self selection: (input size+1 to: newContents size). + self currentHand newKeyboardFocus: morph textMorph.! Item was changed: Morph subclass: #SketchMorph + instanceVariableNames: 'originalForm rotationStyle scalePoint framesToDwell rotatedForm keepAspectRatio' - instanceVariableNames: 'originalForm rotationStyle scalePoint framesToDwell rotatedForm' classVariableNames: '' poolDictionaries: '' category: 'Morphic-Basic'! !SketchMorph commentStamp: '' prior: 0! The morph that results when the user draws a color bitmap using the PaintBox (SketchEditorMorph and PaintBoxMorph). forwardDirection is the angle at which the object will go forward. When the rotationStyle is not #normal, then forwardDirection is any angle, while the rotation is highly restricted. If flexed, this is remembered by the Transform morph. For non-normal rotationStyle, it is rotationDegrees. setupAngle (a property) is where the user put the green arrow to indicate which direction on the picture is forward. When #normal, draw the morph initially at (0.0 - setupAngle). The enclosing TransformationMorph then rotates it to the true angle. rotationDegrees In a #normal object, rotationDegrees is constant an equal to setupAngle. For non-normal, it is the direction the object is going. When repainting, set it back to its original state. The green arrow is set to setupAngle, and the sketch is shown as drawn originally (rotationDegrees = 0). rotationStyle = normal (turns), leftRight, upDown, fixed. When leftRight upDown or fixed, bit map has severe restrictions. ! Item was changed: ----- Method: SketchMorph>>extent: (in category 'geometry') ----- extent: newExtent "Change my scale to fit myself into the given extent. Avoid extents where X or Y is zero." newExtent isZero ifTrue: [ ^self ]. self extent = newExtent ifTrue:[^self]. + self scalePoint: newExtent asFloatPoint / (originalForm extent max: 1@1). - scalePoint := newExtent asFloatPoint / (originalForm extent max: 1@1). self layoutChanged. ! Item was added: + ----- Method: SketchMorph>>keepAspectRatio (in category 'accessing') ----- + keepAspectRatio + + ^ keepAspectRatio ifNil: [false]! Item was added: + ----- Method: SketchMorph>>keepAspectRatio: (in category 'accessing') ----- + keepAspectRatio: aBoolean + + keepAspectRatio := aBoolean.! Item was changed: ----- Method: SketchMorph>>scalePoint: (in category 'accessing') ----- scalePoint: aPoint + scalePoint := self keepAspectRatio + ifTrue: [aPoint max: aPoint transposed] + ifFalse: [aPoint]. + self layoutChanged.! - scalePoint := aPoint. - self layoutChanged. - ! Item was changed: ----- Method: TheWorldMainDockingBar>>fillDockingBar: (in category 'construction') ----- fillDockingBar: aDockingBar "Private - fill the given docking bar" - aDockingBar addSpace: 6. self menusOn: aDockingBar. aDockingBar addSpacer. self projectNameOn: aDockingBar. aDockingBar addSpacer. self rightSideOn: aDockingBar. aDockingBar setProperty: #mainDockingBarTimeStamp toValue: self class timeStamp.! Item was changed: ----- Method: TheWorldMainDockingBar>>searchBarOn: (in category 'right side') ----- searchBarOn: aDockingBar aDockingBar + addMorphBack: (SearchBar build vResizing: #spaceFill); - addMorphBack: (StringMorph new contents: 'Search: '); - addMorphBack: SearchBarMorph new; addDefaultSpace! Item was changed: ----- Method: TheWorldMainDockingBar>>toggleFullScreenOn: (in category 'right side') ----- toggleFullScreenOn: aDockingBar + + | toggleMorph box | + toggleMorph := (SketchMorph withForm: MenuIcons smallFullscreenOffIcon). + + box := Morph new + color: Color transparent; + vResizing: #spaceFill; + width: toggleMorph width; + balloonText: 'toggle full screen mode' translated; + addMorph: toggleMorph. + + toggleMorph setToAdhereToEdge: #rightCenter. + + box + on: #mouseDown + send: #value + to: + [ Project current toggleFullScreen. + toggleMorph form: MenuIcons smallFullscreenOffIcon ] ; - | toggleMorph | - toggleMorph := (SketchMorph withForm: MenuIcons smallFullscreenOffIcon) setBalloonText: 'toggle full screen mode' translated; - - on: #mouseDown - send: #value - to: - [ Project current toggleFullScreen. - toggleMorph form: MenuIcons smallFullscreenOffIcon ] ; + on: #mouseEnter + send: #value + to: [toggleMorph form: MenuIcons smallFullscreenOnIcon]; + + on: #mouseLeave + send: #value + to: [toggleMorph form: MenuIcons smallFullscreenOffIcon]. - on: #mouseEnter - send: #value - to: [toggleMorph form: MenuIcons smallFullscreenOnIcon]; + aDockingBar addMorphBack: box! - on: #mouseLeave - send: #value - to: [toggleMorph form: MenuIcons smallFullscreenOffIcon]; - yourself. - aDockingBar addMorphBack: toggleMorph! From asqueaker at gmail.com Thu Apr 2 15:05:01 2015 From: asqueaker at gmail.com (Chris Muller) Date: Thu Apr 2 15:05:04 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.115.mcz In-Reply-To: <551ce79d.8d32370a.5f07.fffff3e8SMTPIN_ADDED_MISSING@mx.google.com> References: <551ce79d.8d32370a.5f07.fffff3e8SMTPIN_ADDED_MISSING@mx.google.com> Message-ID: On Thu, Apr 2, 2015 at 1:54 AM, wrote: > Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: > http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.115.mcz > > ==================== Summary ==================== > > Name: ToolBuilder-Morphic-mt.115 > Author: mt > Time: 2 April 2015, 8:54:11.711 am > UUID: 873458fe-19e8-0449-a9d1-c52476bc1077 > Ancestors: ToolBuilder-Morphic-cmm.114 > > Revert something that was re-introduced in cmm.112 but already reverted before. Okay, I thought you wanted your version from April 1st. Thanks for reverting back to Andreas' version instead of making a new copy of it. > #selectPath:in: must send #setSelectedMorph: because both are callbacks from #update: within the tree morph. > > #selection only talks to the model. We do not have an equivalent for tree-path selection, which talks to the model, yet. > > =============== Diff against ToolBuilder-Morphic-cmm.114 =============== > > Item was changed: > ----- Method: PluggableTreeMorph>>selectPath:in: (in category 'selection') ----- > selectPath: path in: listItem > + path isEmpty ifTrue: [^self setSelectedMorph: nil]. > - path isEmpty ifTrue: [^self selection: nil]. > - > listItem withSiblingsDo: [:each | > (each complexContents item = path first) ifTrue: [ > each isExpanded ifFalse: [ > each toggleExpandedState. > self adjustSubmorphPositions. > ]. > each changed. > path size = 1 ifTrue: [ > + ^self setSelectedMorph: each > - ^self selection: each complexContents > ]. > + each firstChild ifNil: [^self setSelectedMorph: nil]. > - each firstChild ifNil: [^self selection: nil]. > ^self selectPath: path allButFirst in: each firstChild > ]. > ]. > + ^self setSelectedMorph: nil > - ^self selection: nil > > ! > > Item was changed: > ----- Method: PluggableTreeMorph>>setSelectedMorph: (in category 'selection') ----- > setSelectedMorph: aMorph > selectedWrapper := aMorph complexContents. > + > "Let the model now about the selected object, not wrapper." > setSelectionSelector ifNotNil: [:symbol | > model > perform: symbol > + with: (selectedWrapper ifNotNil: [:w | w item])]. > + > - with: (selectedWrapper ifNotNil: [ selectedWrapper item ])]. > "The model may not have access to the parent object in terms of this tree structure." > setSelectedParentSelector ifNotNil: [:symbol | > model > perform: symbol > + with: (selectedWrapper ifNotNil: [:w | w parent ifNotNil: [:pw | pw item]])].! > - with: (selectedWrapper ifNotNil: [selectedWrapper parent ifNotNil: [: parentWrapper | parentWrapper item]])].! > I'm not sure why you like that style better but, okay. I found it slightly harder to read due to the unnecessary block args. From unoduetre at poczta.onet.pl Thu Apr 2 15:14:52 2015 From: unoduetre at poczta.onet.pl (Mateusz Grotek) Date: Thu Apr 2 15:11:41 2015 Subject: [squeak-dev] A bug with class renaming In-Reply-To: (from Das.Linux@gmx.de on Thu Apr 2 16:07:54 2015) Message-ID: <1427987692.17089.0@mglap> Dnia 02.04.2015 16:07:54, Tobias Pape napisa?(a): > Hi Mateusz > > On 02.04.2015, at 16:06, Mateusz Grotek > wrote: > > > Dnia 02.04.2015 15:19:10, Tobias Pape napisa?(a): > >> Hey > >> On 02.04.2015, at 15:20, Mateusz Grotek > wrote: > >> > Is this problem already solved in the forthcoming 2.6 or it's > new? > >> > > >> > To reproduce: > >> > 1. Create a class. > >> > 2. Rightclick on the class name and choose "Rename class". > >> > 3. Enter the new name and accept. > >> This is fixed for 4.5 and Trunk (upcoming 4.6). > >> For 4.5 please use the update functionality. > >> Best > >> -Tobias > > Hi, > > (Of course I wanted to say 4.6, not 2.6) Well, it seems the update > (click on logo, and then "Update Squeak") does not solve the problem. > Can you verify it? > > Mateusz > > > Can you explain what happens after step 3 and what should happen? > It might be we are talking about different bugs. > > Best > -Tobias > Sure. After accepting the new name an exception shows up. Its message is: MessageNotUnderstood: PutTheRenamedClassNameHere class>>updateMethodBindingsTo: The exception is called from the following line: aClass updateMethodBindingsTo: newBinding. of: Environment>>renameClass:from:to: After closing the exception window it reopens ad infinitum. It's impossible to work in the image after that, because more and more exceptions show up after doing some trivial things. It's probably related to the new environments functionality. Best wishes, Mateusz From asqueaker at gmail.com Thu Apr 2 15:12:09 2015 From: asqueaker at gmail.com (Chris Muller) Date: Thu Apr 2 15:12:12 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.808.mcz In-Reply-To: <551cf017.4734370a.5af2.2772SMTPIN_ADDED_MISSING@mx.google.com> References: <551cf017.4734370a.5af2.2772SMTPIN_ADDED_MISSING@mx.google.com> Message-ID: Thank you! On Thu, Apr 2, 2015 at 2:29 AM, wrote: > Marcel Taeumel uploaded a new version of Morphic to project The Trunk: > http://source.squeak.org/trunk/Morphic-mt.808.mcz > > ==================== Summary ==================== > > Name: Morphic-mt.808 > Author: mt > Time: 2 April 2015, 9:29:45.666 am > UUID: c0476a80-1468-aa46-bd81-9cbfd132266e > Ancestors: Morphic-mt.807 > > Text fields only show balloon if it has no text. The balloon text will be rendered in that case. > > =============== Diff against Morphic-mt.807 =============== > > Item was changed: > + ----- Method: PluggableTextMorph>>wantsBalloon (in category 'halos and balloon help') ----- > - ----- Method: PluggableTextMorph>>wantsBalloon (in category 'as yet unclassified') ----- > wantsBalloon > > ^ self textMorph contents notEmpty and: [super wantsBalloon]! > > From Das.Linux at gmx.de Thu Apr 2 15:16:11 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 2 15:16:14 2015 Subject: [squeak-dev] A bug with class renaming In-Reply-To: <1427987692.17089.0@mglap> References: <1427987692.17089.0@mglap> Message-ID: <839D9F43-C05C-4009-BCE4-E976E15B0BE2@gmx.de> Hi Mateuz On 02.04.2015, at 17:14, Mateusz Grotek wrote: > Dnia 02.04.2015 16:07:54, Tobias Pape napisa?(a): >> Hi Mateusz >> On 02.04.2015, at 16:06, Mateusz Grotek wrote: >> > Dnia 02.04.2015 15:19:10, Tobias Pape napisa?(a): >> >> Hey >> >> On 02.04.2015, at 15:20, Mateusz Grotek wrote: >> >> > Is this problem already solved in the forthcoming 2.6 or it's new? >> >> > >> >> > To reproduce: >> >> > 1. Create a class. >> >> > 2. Rightclick on the class name and choose "Rename class". >> >> > 3. Enter the new name and accept. >> >> This is fixed for 4.5 and Trunk (upcoming 4.6). >> >> For 4.5 please use the update functionality. >> >> Best >> >> -Tobias >> > Hi, >> > (Of course I wanted to say 4.6, not 2.6) Well, it seems the update (click on logo, and then "Update Squeak") does not solve the problem. Can you verify it? >> > Mateusz >> Can you explain what happens after step 3 and what should happen? >> It might be we are talking about different bugs. >> Best >> -Tobias > Sure. After accepting the new name an exception shows up. > Its message is: MessageNotUnderstood: PutTheRenamedClassNameHere class>>updateMethodBindingsTo: > The exception is called from the following line: > aClass updateMethodBindingsTo: newBinding. > of: Environment>>renameClass:from:to: > > After closing the exception window it reopens ad infinitum. It's impossible to work in the image after that, because more and more exceptions show up after doing some trivial things. > > It's probably related to the new environments functionality. I cannot reproduce this. Class renaming works just fine in trunk and 4.5. What version is Squeak reporting? Best -Tobias From lewis at mail.msen.com Thu Apr 2 15:30:33 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Thu Apr 2 15:30:35 2015 Subject: [squeak-dev] Jenkins In-Reply-To: References: <87F4E219-FD97-46FF-9A0A-DD96DFD91096@gmx.de> Message-ID: <32790.136.2.1.104.1427988633.squirrel@webmail.msen.com> > On 2 April 2015 at 14:22, Tobias Pape wrote: >> Hi >> >> I did an update-dance for Jenkins and also installed the >> doony theme. >> >> Also, I installed the dependency graph plugin, so that we can see what >> depends on >> what easily: >> >> http://build.squeak.org/depgraph-view > > Ooh, I like that! > > frank > Me too! That's really helpful. Dave From asqueaker at gmail.com Thu Apr 2 15:37:33 2015 From: asqueaker at gmail.com (Chris Muller) Date: Thu Apr 2 15:37:36 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.812.mcz In-Reply-To: <551d50cf.97978c0a.761a.fffffcd6SMTPIN_ADDED_MISSING@mx.google.com> References: <551d50cf.97978c0a.761a.fffffcd6SMTPIN_ADDED_MISSING@mx.google.com> Message-ID: Hey Marcel, I'm not sure if this is what broke it but... there is a hot-key Command+0 which is supposed to take the cursor to the search bar (just as hot-keys Command+1 -- Command+7 open those DockingBar menus...). On Thu, Apr 2, 2015 at 9:22 AM, wrote: > Marcel Taeumel uploaded a new version of Morphic to project The Trunk: > http://source.squeak.org/trunk/Morphic-mt.812.mcz > > ==================== Summary ==================== > > Name: Morphic-mt.812 > Author: mt > Time: 2 April 2015, 4:22:28.115 pm > UUID: 9dacc5ba-ac6a-db4f-bf8f-c42885c6642a > Ancestors: Morphic-mt.811 > > Fixed main docking bar to support interaction with outermost pixels. This is especially useful in fullscreen mode where you want to navigate to topLeft and open the Squeak menu or topRight and click to exit fullscreen. Before, there were pixel offsets and thus you had to acquire your target carefully. > > This fix includes a replacement of the SearchBarMorph with one that uses tool builder and the pluggable text morph. > > =============== Diff against Morphic-mt.811 =============== > > Item was changed: > ----- Method: DockingBarMorph>>handleListenEvent: (in category 'events-processing') ----- > handleListenEvent: anEvent > " I am registered as a keyboardListener of the ActiveHand, > watching for ctrl- keystrokes, and upon them if I have > an nth menu item, I'll activate myself and select it. " > > (anEvent controlKeyPressed and: [ > anEvent keyValue > between: 48 " $0 asciiValue " > and: 55 " $7 asciiValue " ]) ifTrue: [ > | index itemToSelect | > index := anEvent keyValue - 48. > itemToSelect := (submorphs select: [ :each | > each isKindOf: DockingBarItemMorph ]) > at: index > ifAbsent: [ > + ^self searchBarMorph ifNotNil: [ :morph | > + morph model activate: anEvent in: morph ] ]. > - ^self searchBarMorph ifNotNil: [ :searchBar | > - searchBar activate: anEvent ] ]. > self activate: anEvent. > self > selectItem: itemToSelect > event: anEvent ]! > > Item was changed: > ----- Method: DockingBarMorph>>searchBarMorph (in category 'events-processing') ----- > searchBarMorph > > + ^self submorphs detect: [ :each | each knownName = #searchBar ] ifNone: [ nil ]! > - ^self submorphs detect: [ :each | each class = SearchBarMorph ] ifNone: [ nil ]! > > Item was added: > + Model subclass: #SearchBar > + instanceVariableNames: 'searchTerm selection' > + classVariableNames: '' > + poolDictionaries: '' > + category: 'Morphic-Menus-DockingBar'! > > Item was added: > + ----- Method: SearchBar class>>build (in category 'as yet unclassified') ----- > + build > + > + ^ ToolBuilder build: self new! > > Item was added: > + ----- Method: SearchBar>>activate:in: (in category 'accessing') ----- > + activate: event in: morph > + > + self searchTerm: ''. "We cannot select all here, because we only get contents on #accept, which triggers a search. So earse the term." > + event hand newKeyboardFocus: morph textMorph.! > > Item was added: > + ----- Method: SearchBar>>buildWith: (in category 'toolbuilder') ----- > + buildWith: builder > + > + ^ (builder build: (builder pluggableInputFieldSpec new > + model: self; > + getText: #searchTerm; > + setText: #smartSearch:in:; > + menu: #menu:shifted:; > + selection: #selection; > + help: 'Search...' translated)) > + name: #searchBar; > + wantsFrameAdornments: false; > + borderWidth: 0; > + yourself! > > Item was added: > + ----- Method: SearchBar>>menu:shifted: (in category 'accessing') ----- > + menu: aMenu shifted: aBoolean > + > + ^ StringHolder codePaneMenu: aMenu shifted: aBoolean! > > Item was added: > + ----- Method: SearchBar>>searchTerm (in category 'accessing') ----- > + searchTerm > + > + ^ searchTerm ifNil: ['']! > > Item was added: > + ----- Method: SearchBar>>searchTerm: (in category 'accessing') ----- > + searchTerm: aString > + > + searchTerm := aString. > + self changed: #searchTerm.! > > Item was added: > + ----- Method: SearchBar>>selection (in category 'accessing') ----- > + selection > + > + ^ selection ifNil: [1 to: 0]! > > Item was added: > + ----- Method: SearchBar>>selection: (in category 'accessing') ----- > + selection: anInterval > + > + selection := anInterval. > + self changed: #selection.! > > Item was added: > + ----- Method: SearchBar>>smartSearch:in: (in category 'searching') ----- > + smartSearch: text in: morph > + "Take the user input and perform an appropriate search" > + | input newContents | > + input := text asString ifEmpty:[^self]. > + (Smalltalk bindingOf: input) ifNotNil:[:assoc| | global | > + "It's a global or a class" > + global := assoc value. > + ^ToolSet browse: (global isBehavior ifTrue:[global] ifFalse:[global class]) selector: nil. > + ]. > + (SystemNavigation new allImplementorsOf: input asSymbol) ifNotEmpty:[:list| > + ^SystemNavigation new > + browseMessageList: list > + name: 'Implementors of ' , input > + ]. > + input first isUppercase ifTrue:[ > + (UIManager default classFromPattern: input withCaption: '') ifNotNil:[:aClass| > + ^ToolSet browse: aClass selector: nil. > + ]. > + ] ifFalse:[ > + ^ToolSet default browseMessageNames: input > + ]. > + newContents := input, ' -- not found.'. > + > + self searchTerm: newContents. > + self selection: (input size+1 to: newContents size). > + self currentHand newKeyboardFocus: morph textMorph.! > > Item was changed: > Morph subclass: #SketchMorph > + instanceVariableNames: 'originalForm rotationStyle scalePoint framesToDwell rotatedForm keepAspectRatio' > - instanceVariableNames: 'originalForm rotationStyle scalePoint framesToDwell rotatedForm' > classVariableNames: '' > poolDictionaries: '' > category: 'Morphic-Basic'! > > !SketchMorph commentStamp: '' prior: 0! > The morph that results when the user draws a color bitmap using the PaintBox (SketchEditorMorph and PaintBoxMorph). > > forwardDirection is the angle at which the object will go forward. When the rotationStyle is not #normal, then forwardDirection is any angle, while the rotation is highly restricted. If flexed, this is remembered by the Transform morph. For non-normal rotationStyle, it is rotationDegrees. > > setupAngle (a property) is where the user put the green arrow to indicate which direction on the picture is forward. When #normal, draw the morph initially at (0.0 - setupAngle). The enclosing TransformationMorph then rotates it to the true angle. > > rotationDegrees In a #normal object, rotationDegrees is constant an equal to setupAngle. > For non-normal, it is the direction the object is going. > > When repainting, set it back to its original state. The green arrow is set to setupAngle, and the sketch is shown as drawn originally (rotationDegrees = 0). > > rotationStyle = normal (turns), leftRight, upDown, fixed. > When leftRight upDown or fixed, bit map has severe restrictions. > ! > > Item was changed: > ----- Method: SketchMorph>>extent: (in category 'geometry') ----- > extent: newExtent > "Change my scale to fit myself into the given extent. > Avoid extents where X or Y is zero." > > newExtent isZero ifTrue: [ ^self ]. > self extent = newExtent ifTrue:[^self]. > + self scalePoint: newExtent asFloatPoint / (originalForm extent max: 1@1). > - scalePoint := newExtent asFloatPoint / (originalForm extent max: 1@1). > self layoutChanged. > ! > > Item was added: > + ----- Method: SketchMorph>>keepAspectRatio (in category 'accessing') ----- > + keepAspectRatio > + > + ^ keepAspectRatio ifNil: [false]! > > Item was added: > + ----- Method: SketchMorph>>keepAspectRatio: (in category 'accessing') ----- > + keepAspectRatio: aBoolean > + > + keepAspectRatio := aBoolean.! > > Item was changed: > ----- Method: SketchMorph>>scalePoint: (in category 'accessing') ----- > scalePoint: aPoint > > + scalePoint := self keepAspectRatio > + ifTrue: [aPoint max: aPoint transposed] > + ifFalse: [aPoint]. > + self layoutChanged.! > - scalePoint := aPoint. > - self layoutChanged. > - ! > > Item was changed: > ----- Method: TheWorldMainDockingBar>>fillDockingBar: (in category 'construction') ----- > fillDockingBar: aDockingBar > "Private - fill the given docking bar" > > - aDockingBar addSpace: 6. > self menusOn: aDockingBar. > aDockingBar addSpacer. > self projectNameOn: aDockingBar. > aDockingBar addSpacer. > self rightSideOn: aDockingBar. > aDockingBar > setProperty: #mainDockingBarTimeStamp > toValue: self class timeStamp.! > > Item was changed: > ----- Method: TheWorldMainDockingBar>>searchBarOn: (in category 'right side') ----- > searchBarOn: aDockingBar > > aDockingBar > + addMorphBack: (SearchBar build vResizing: #spaceFill); > - addMorphBack: (StringMorph new contents: 'Search: '); > - addMorphBack: SearchBarMorph new; > addDefaultSpace! > > Item was changed: > ----- Method: TheWorldMainDockingBar>>toggleFullScreenOn: (in category 'right side') ----- > toggleFullScreenOn: aDockingBar > + > + | toggleMorph box | > + toggleMorph := (SketchMorph withForm: MenuIcons smallFullscreenOffIcon). > + > + box := Morph new > + color: Color transparent; > + vResizing: #spaceFill; > + width: toggleMorph width; > + balloonText: 'toggle full screen mode' translated; > + addMorph: toggleMorph. > + > + toggleMorph setToAdhereToEdge: #rightCenter. > + > + box > + on: #mouseDown > + send: #value > + to: > + [ Project current toggleFullScreen. > + toggleMorph form: MenuIcons smallFullscreenOffIcon ] ; > - | toggleMorph | > - toggleMorph := (SketchMorph withForm: MenuIcons smallFullscreenOffIcon) setBalloonText: 'toggle full screen mode' translated; > - > - on: #mouseDown > - send: #value > - to: > - [ Project current toggleFullScreen. > - toggleMorph form: MenuIcons smallFullscreenOffIcon ] ; > > + on: #mouseEnter > + send: #value > + to: [toggleMorph form: MenuIcons smallFullscreenOnIcon]; > + > + on: #mouseLeave > + send: #value > + to: [toggleMorph form: MenuIcons smallFullscreenOffIcon]. > - on: #mouseEnter > - send: #value > - to: [toggleMorph form: MenuIcons smallFullscreenOnIcon]; > > + aDockingBar addMorphBack: box! > - on: #mouseLeave > - send: #value > - to: [toggleMorph form: MenuIcons smallFullscreenOffIcon]; > - yourself. > - aDockingBar addMorphBack: toggleMorph! > > From unoduetre at poczta.onet.pl Thu Apr 2 15:59:20 2015 From: unoduetre at poczta.onet.pl (Mateusz Grotek) Date: Thu Apr 2 15:56:37 2015 Subject: [squeak-dev] A bug with class renaming In-Reply-To: <839D9F43-C05C-4009-BCE4-E976E15B0BE2@gmx.de> (from Das.Linux@gmx.de on Thu Apr 2 17:16:11 2015) Message-ID: <1427990360.17970.0@mglap> > I cannot reproduce this. > Class renaming works just fine in trunk and 4.5. > What version is Squeak reporting? > > Best > -Tobias > I did exactly the following to verify everything. 1. I downloaded the all-in-one squeak distribution from http://ftp.squeak.org/4.5/Squeak-4.5-All-in-One.zip $ wget 'http://ftp.squeak.org/4.5/Squeak-4.5-All-in-One.zip' $ unzip Squeak-4.5-All-in-One.zip $ cd Squeak-4.5-All-In-One $ ./squeak.sh 2. I clicked on the logo, and then "Update Squeak". A window with progress bars and Transcript showed up. Waiting... 3. A window with the title: "Warning" and the following content showed up: About to serialize an empty package. Select Proceed to continue, or close this window to cancel the operation. 4. I clicked Proceed. The update continued. A window with the title "Note:" and the following content showed up: Update completed. Current update number: 13703 5. I clicked OK and closed Transcript. 6. I clicked Tools->Browser, scrolled down to the end of the leftmost list, rightclicked and chose "add item...". I entered XYZ and clicked Accept. 7. I changed NameOfSubclass to XYZ and CTRL-s 8. I rightclicked on the XYZ class and chose "rename class...". I entered "ABC" and clicked "Accept(s)". 9. An exception message showed up with the title: "MessageNotUnderstood: ABC class>>updateMethodBindingsTo:" The source of the exception is the line: aClass updateMethodBindingsTo: newBinding. of: Environment>>renameClass:from:to: 10. An exception message showed up with the title: "MessageNotUnderstood: UndefinedObject>>superclass". The source of the exception is the line: childs := col select: [:class | class isTrait not and: [class superclass = ea]]. of: Browser>>createHierarchyTreeOf: 11. I clicked on the logo and "About Squeak". The Squeak version is: #13703 That's it. My operating system is Gentoo Linux. Please tell me the first step which is different in your case. Mateusz From asqueaker at gmail.com Thu Apr 2 16:12:05 2015 From: asqueaker at gmail.com (Chris Muller) Date: Thu Apr 2 16:12:08 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.810.mcz In-Reply-To: <551d0968.15c48c0a.45f0.ffffa1c8SMTPIN_ADDED_MISSING@mx.google.com> References: <551d0968.15c48c0a.45f0.ffffa1c8SMTPIN_ADDED_MISSING@mx.google.com> Message-ID: Hi Marcel, is there any way this could honor the Reuse Windows preference? One way of course would be to simply open straight into the world. This would be consistent with how all the other tools work. Nowhere else do we open a SystemWindow into the Hand, do we? On Thu, Apr 2, 2015 at 4:17 AM, wrote: > Marcel Taeumel uploaded a new version of Morphic to project The Trunk: > http://source.squeak.org/trunk/Morphic-mt.810.mcz > > ==================== Summary ==================== > > Name: Morphic-mt.810 > Author: mt > Time: 2 April 2015, 11:17:44.865 am > UUID: 644a4b6a-4767-ec45-992c-9ed10ac54871 > Ancestors: Morphic-mt.809 > > Exploring a morph via its halo menu now attaches the explorer also to the hand -- like inspecting does. > > =============== Diff against Morphic-mt.809 =============== > > Item was changed: > ----- Method: Morph>>buildDebugMenu: (in category 'debug and other') ----- > buildDebugMenu: aHand > "Answer a debugging menu for the receiver. The hand argument is seemingly historical and plays no role presently" > > | aMenu aPlayer | > aMenu := MenuMorph new defaultTarget: self. > aMenu addStayUpItem. > (self hasProperty: #errorOnDraw) ifTrue: > [aMenu add: 'start drawing again' translated action: #resumeAfterDrawError. > aMenu addLine]. > (self hasProperty: #errorOnStep) ifTrue: > [aMenu add: 'start stepping again' translated action: #resumeAfterStepError. > aMenu addLine]. > > aMenu add: 'inspect morph' translated action: #inspectInMorphic:. > aMenu add: 'inspect owner chain' translated action: #inspectOwnerChain. > Smalltalk isMorphic ifFalse: > [aMenu add: 'inspect morph (in MVC)' translated action: #inspect]. > > self isMorphicModel ifTrue: > [aMenu add: 'inspect model' translated target: self model action: #inspect]. > (aPlayer := self player) ifNotNil: > [aMenu add: 'inspect player' translated target: aPlayer action: #inspect]. > > + aMenu add: 'explore morph' translated target: self selector: #exploreInMorphic:. > - aMenu add: 'explore morph' translated target: self selector: #explore. > > aMenu addLine. > aPlayer ifNotNil: > [ aMenu add: 'viewer for Player' translated target: self player action: #beViewed. > aMenu balloonTextForLastItem: 'Opens a viewer on my Player -- this is the same thing you get if you click on the cyan "View" halo handle' translated ]. > > aMenu add: 'viewer for Morph' translated target: self action: #viewMorphDirectly. > aMenu balloonTextForLastItem: 'Opens a Viewer on this Morph, rather than on its Player' translated. > aMenu addLine. > > aPlayer ifNotNil: > [aPlayer class isUniClass ifTrue: [ > aMenu add: 'browse player class' translated target: aPlayer action: #browseHierarchy]]. > aMenu add: 'browse morph class' translated target: self selector: #browseHierarchy. > (self isMorphicModel) > ifTrue: [aMenu > add: 'browse model class' > target: self model > selector: #browseHierarchy]. > aMenu addLine. > > self addViewingItemsTo: aMenu. > aMenu > add: 'make own subclass' translated action: #subclassMorph; > add: 'save morph in file' translated action: #saveOnFile; > addLine; > add: 'call #tempCommand' translated action: #tempCommand; > add: 'define #tempCommand' translated action: #defineTempCommand; > addLine; > > add: 'control-menu...' translated target: self selector: #invokeMetaMenu:; > add: 'edit balloon help' translated action: #editBalloonHelpText. > > ^ aMenu! > > Item was added: > + ----- Method: Morph>>exploreInMorphic (in category 'menus') ----- > + exploreInMorphic > + self currentHand attachMorph: (ToolSet explore: self).! > > Item was added: > + ----- Method: Morph>>exploreInMorphic: (in category 'menus') ----- > + exploreInMorphic: evt > + evt hand attachMorph: (ToolSet explore: self).! > > From herbertkoenig at gmx.net Thu Apr 2 16:31:19 2015 From: herbertkoenig at gmx.net (=?UTF-8?B?SGVyYmVydCBLw7ZuaWc=?=) Date: Thu Apr 2 16:31:23 2015 Subject: [squeak-dev] Benchmarking4.5 Cog vs. 4.6 Spur Message-ID: <551D6ED7.1060701@gmx.net> Hi, I was benchmarking some long running optimization code in an older Cog running a 4.5 image vs. latest Spur running the latest 4.6 image from Eliot's site. While tinyBenchmarks show roughly the same number of sends/sec and twice the number of bytecodes/sec in favour of Spur and 4.6 my benchmark shows the opposite, Spur and 4.6 take twice as long for the optimization as Cog and 4.5. Cog is revision r2776 of Aug 22 2013 and the 4.5 image is update #13680. Don't know what to make of it but I attached the results of TimeProfileBrowser>>Spy on for both. Cheers, Herbert Cog and 4.5: ' - 20148 tallies, 20188 msec.' '' '**Tree**' '--------------------------------' 'Process: (40s) 10653: nil' '--------------------------------' '73.5% {14833ms} ApproximationFunctionOptimizer(GeneticAndGradientOptimizer)>>gradientImproveAll' ' |73.5% {14829ms} ApproximationFunctionOptimizer>>gradientImprove:' ' | 61.0% {12307ms} ApproximationFunctionOptimizer>>evaluateIndividual:' ' | |17.3% {3491ms} Float>>abs' ' | |11.3% {2275ms} OrderedCollection>>at:' ' | |8.8% {1770ms} OrderedCollection(SequenceableCollection)>>withIndexDo:' ' | | |7.6% {1540ms} primitives' ' | | |1.1% {218ms} OrderedCollection>>at:' ' | |6.0% {1208ms} IndividualGenom>>fitnesses:' ' | | |5.9% {1185ms} OrderedCollection(Collection)>>sum' ' | | | 5.0% {1003ms} OrderedCollection(Collection)>>reduce:' ' | | | 2.6% {518ms} OrderedCollection>>do:' ' | | | 2.4% {485ms} primitives' ' | |5.9% {1192ms} SmallInteger>>-' ' | | |4.8% {969ms} primitives' ' | | |1.1% {223ms} SmallInteger(Integer)>>-' ' | |3.7% {749ms} primitives' ' | |2.8% {573ms} OrderedCollection>>add:' ' | | |2.3% {468ms} primitives' ' | |2.8% {573ms} FunctionQuadraticPolynom>>calculate:' ' | | |2.1% {422ms} Float(Number)>>squared' ' | |2.2% {446ms} OrderedCollection class>>new:' ' | | 2.2% {435ms} OrderedCollection>>setCollection:' ' | | 2.1% {420ms} primitives' ' | 6.0% {1210ms} Array(Collection)>>*' ' | |6.0% {1206ms} Fraction(Number)>>adaptToCollection:andSend:' ' | | 3.1% {617ms} primitives' ' | | 2.9% {582ms} Array(SequenceableCollection)>>collect:' ' | 3.7% {741ms} Array(Collection)>>-' ' | |3.5% {710ms} Array(Collection)>>adaptToCollection:andSend:' ' | | 2.7% {546ms} Array(SequenceableCollection)>>with:collect:' ' | 1.2% {232ms} IndividualGenom>>geneValues:' '19.4% {3921ms} TranscriptStream>>show:' ' |19.4% {3920ms} TranscriptStream>>endEntry' ' | 19.4% {3919ms} TranscriptStream(Object)>>changed:' ' | 19.4% {3913ms} PluggableTextMorphPlus>>update:' ' | 19.4% {3913ms} PluggableTextMorphPlus(PluggableTextMorph)>>update:' ' | 19.0% {3831ms} PluggableTextMorphPlus(Morph)>>refreshWorld' ' | 19.0% {3830ms} PasteUpMorph>>displayWorldSafely' ' | 19.0% {3830ms} WorldState>>displayWorldSafely:' ' | 19.0% {3830ms} PasteUpMorph>>displayWorld' ' | 19.0% {3830ms} PasteUpMorph>>privateOuterDisplayWorld' ' | 19.0% {3830ms} WorldState>>displayWorld:submorphs:' ' | 17.9% {3620ms} WorldState>>drawWorld:submorphs:invalidAreasOn:' ' | 17.0% {3426ms} FormCanvas(Canvas)>>fullDrawMorph:' ' | 17.0% {3426ms} FormCanvas(Canvas)>>fullDraw:' ' | 17.0% {3426ms} PluggableSystemWindow(Morph)>>fullDrawOn:' ' | 9.4% {1898ms} PluggableSystemWindow(Morph)>>drawSubmorphsOn:' ' | |9.4% {1894ms} FormCanvas(Canvas)>>fullDrawMorph:' ' | | 9.4% {1894ms} FormCanvas(Canvas)>>fullDraw:' ' | | 9.3% {1881ms} PluggableTextMorphPlus(PluggableTextMorph)>>fullDrawOn:' ' | | 9.3% {1878ms} PluggableTextMorphPlus(Morph)>>fullDrawOn:' ' | | 8.4% {1705ms} PluggableTextMorphPlus(Morph)>>drawSubmorphsOn:' ' | | 8.4% {1705ms} FormCanvas(Canvas)>>fullDrawMorph:' ' | | 8.4% {1705ms} FormCanvas(Canvas)>>fullDraw:' ' | | 8.4% {1705ms} TransformMorph(Morph)>>fullDrawOn:' ' | | 8.0% {1605ms} TransformMorph>>drawSubmorphsOn:' ' | | 7.9% {1603ms} FormCanvas(Canvas)>>fullDrawMorph:' ' | | 7.9% {1603ms} FormCanvas(Canvas)>>fullDraw:' ' | | 7.9% {1603ms} TextMorphForEditView(Morph)>>fullDrawOn:' ' | | 7.9% {1601ms} FormCanvas(Canvas)>>drawMorph:' ' | | 7.9% {1601ms} FormCanvas(Canvas)>>draw:' ' | | 7.9% {1601ms} TextMorphForEditView(TextMorph)>>drawOn:' ' | | 7.9% {1599ms} FormCanvas>>paragraph:bounds:color:' ' | | 7.9% {1598ms} NewParagraph>>displayOn:using:at:' ' | | 7.9% {1591ms} BitBltDisplayScanner(DisplayScanner)>>displayLine:offset:leftInRun:' ' | | 7.7% {1562ms} BitBltDisplayScanner>>displayString:from:to:at:' ' | | 7.7% {1562ms} StrikeFont>>displayString:on:from:to:at:kern:' ' | | 4.6% {919ms} Point>>=' ' | | 3.1% {631ms} GrafPort(BitBlt)>>displayString:from:to:at:strikeFont:kern:' ' | | 3.1% {631ms} GrafPort(BitBlt)>>basicDisplayString:from:to:at:strikeFont:kern:' ' | | 3.1% {630ms} primitives' ' | 5.3% {1075ms} PluggableSystemWindow(Morph)>>hasRolloverBorder' ' | |5.3% {1074ms} primitives' ' | 2.2% {441ms} FormCanvas(Canvas)>>drawMorph:' ' | 2.2% {441ms} FormCanvas(Canvas)>>draw:' ' | 2.2% {441ms} PluggableSystemWindow(Morph)>>drawOn:' ' | 2.2% {440ms} FormCanvas(Canvas)>>fillRectangle:fillStyle:borderStyle:' ' | 2.1% {430ms} FormCanvas>>fillRectangle:fillStyle:' ' | 2.1% {427ms} FormCanvas>>balloonFillRectangle:fillStyle:' ' | 2.1% {426ms} BalloonCanvas>>fillRectangle:fillStyle:' ' | 2.1% {426ms} BalloonCanvas>>drawRectangle:color:borderWidth:borderColor:' ' | 2.1% {415ms} BalloonEngine>>drawRectangle:fill:borderWidth:borderColor:transform:' ' | 2.0% {407ms} BalloonEngine>>postFlushIfNeeded' ' | 2.0% {405ms} BalloonEngine>>copyBits' ' | 2.0% {405ms} BalloonEngine>>copyLoopFaster' '3.9% {792ms} ApproximationFunctionOptimizer(GeneticAndGradientOptimizer)>>evaluateIndividuals' ' |3.9% {789ms} ApproximationFunctionOptimizer>>evaluateIndividual:' '1.5% {295ms} ApproximationFunctionOptimizer(GeneticAndGradientOptimizer)>>makeNextGeneration' ' 1.3% {261ms} ApproximationFunctionOptimizer(GeneticAndGradientOptimizer)>>addRecombinations:to:' ' ' '**Leaves**' '18.2% {3670ms} Float>>abs' '13.2% {2663ms} OrderedCollection>>at:' '8.0% {1615ms} OrderedCollection(SequenceableCollection)>>withIndexDo:' '5.3% {1074ms} PluggableSystemWindow(Morph)>>hasRolloverBorder' '5.1% {1031ms} SmallInteger>>-' '4.6% {920ms} Point>>=' '3.9% {783ms} OrderedCollection>>do:' '3.9% {780ms} ApproximationFunctionOptimizer>>evaluateIndividual:' '3.2% {636ms} Array(SequenceableCollection)>>collect:' '3.1% {630ms} GrafPort(BitBlt)>>basicDisplayString:from:to:at:strikeFont:kern:' '3.1% {620ms} Fraction(Number)>>adaptToCollection:andSend:' '2.9% {593ms} OrderedCollection>>setCollection:' '2.8% {572ms} Array(SequenceableCollection)>>with:collect:' '2.5% {510ms} OrderedCollection(Collection)>>reduce:' '2.5% {503ms} OrderedCollection>>add:' '2.3% {467ms} BalloonEngine>>copyLoopFaster' '2.2% {440ms} Float(Number)>>squared' '1.0% {202ms} Array(SequenceableCollection)>>do:' '' '**Memory**' ' old +8,123,912 bytes' ' young +508,872 bytes' ' used +8,632,784 bytes' ' free -282,140 bytes' '' '**GCs**' ' full 3 totalling 289 ms (1.43% uptime), avg 96.3 ms' ' incr 3279 totalling 4,171 ms (20.7% uptime), avg 1.3 ms' ' tenures 627 (avg 5 GCs/tenure)' ' root table 0 overflows' ======================================================================================================================== Spur and 4.6: ' - 39813 tallies, 40849 msec.' '' '**Tree**' '--------------------------------' 'Process: (40s) 92138: nil' '--------------------------------' '98.4% {40201ms} TimeProfileBrowser class>>onBlock:' ' 98.4% {40201ms} TimeProfileBrowser>>runBlock:' ' 98.4% {40201ms} TimeProfileBrowser>>runBlock:pollingEvery:' ' 98.4% {40201ms} MessageTally>>spyEvery:on:' ' 98.4% {40201ms} BlockClosure>>ensure:' ' 98.4% {40201ms} [] UndefinedObject>>DoIt' ' 98.4% {40188ms} ApproximationFunctionOptimizer(GeneticAndGradientOptimizer)>>optimize:' ' 71.9% {29372ms} ApproximationFunctionOptimizer(GeneticAndGradientOptimizer)>>gradientImproveAll' ' |69.8% {28513ms} OrderedCollection>>do:' ' | |69.8% {28508ms} [] ApproximationFunctionOptimizer(GeneticAndGradientOptimizer)>>gradientImproveAll' ' | | 69.8% {28500ms} ApproximationFunctionOptimizer>>gradientImprove:' ' | | 47.6% {19438ms} ApproximationFunctionOptimizer>>evaluateIndividual:' ' | | |41.7% {17049ms} OrderedCollection(SequenceableCollection)>>withIndexDo:' ' | | | |37.2% {15180ms} [] ApproximationFunctionOptimizer>>evaluateIndividual:' ' | | | | |15.9% {6512ms} BoxedFloat64(Float)>>abs' ' | | | | |9.0% {3669ms} OrderedCollection>>at:' ' | | | | |5.4% {2207ms} SmallInteger>>-' ' | | | | | |4.2% {1720ms} primitives' ' | | | | | |1.2% {487ms} SmallInteger(Integer)>>-' ' | | | | |2.4% {967ms} primitives' ' | | | | |2.3% {938ms} FunctionQuadraticPolynom>>calculate:' ' | | | | | |1.9% {765ms} BoxedFloat64(Number)>>squared' ' | | | | |2.2% {888ms} OrderedCollection>>add:' ' | | | | | 1.7% {711ms} primitives' ' | | | |3.4% {1386ms} primitives' ' | | | |1.2% {470ms} OrderedCollection>>at:' ' | | |5.2% {2108ms} IndividualGenom>>fitnesses:' ' | | | 5.1% {2073ms} OrderedCollection(Collection)>>sum' ' | | | 5.0% {2059ms} OrderedCollection(Collection)>>reduce:' ' | | | 4.8% {1966ms} OrderedCollection>>do:' ' | | | 2.6% {1050ms} [] OrderedCollection(Collection)>>reduce:' ' | | | |1.6% {636ms} primitives' ' | | | |1.0% {413ms} [] OrderedCollection(Collection)>>sum' ' | | | 2.2% {916ms} primitives' ' | | 14.2% {5817ms} Array(SequenceableCollection)>>withIndexCollect:' ' | | |14.0% {5706ms} [] ApproximationFunctionOptimizer>>gradientImprove:' ' | | | 13.9% {5661ms} ApproximationFunctionOptimizer>>evaluateIndividual:' ' | | | 12.3% {5038ms} OrderedCollection(SequenceableCollection)>>withIndexDo:' ' | | | |11.1% {4522ms} [] ApproximationFunctionOptimizer>>evaluateIndividual:' ' | | | | 4.1% {1687ms} BoxedFloat64(Float)>>abs' ' | | | | 3.6% {1471ms} OrderedCollection>>at:' ' | | | | 1.4% {583ms} SmallInteger>>-' ' | | | | 1.2% {473ms} primitives' ' | | | 1.2% {478ms} IndividualGenom>>fitnesses:' ' | | | 1.2% {472ms} OrderedCollection(Collection)>>sum' ' | | | 1.1% {467ms} OrderedCollection(Collection)>>reduce:' ' | | | 1.1% {446ms} OrderedCollection>>do:' ' | | 3.0% {1208ms} Array(Collection)>>*' ' | | |2.9% {1181ms} BoxedFloat64(Number)>>adaptToCollection:andSend:' ' | | | 2.9% {1174ms} Array(SequenceableCollection)>>collect:' ' | | | 2.5% {1001ms} primitives' ' | | 2.9% {1187ms} Array(Collection)>>-' ' | | |2.8% {1157ms} Array(Collection)>>adaptToCollection:andSend:' ' | | | 2.8% {1151ms} Array(SequenceableCollection)>>with:collect:' ' | | | 2.3% {956ms} primitives' ' | | 1.3% {528ms} IndividualGenom>>geneValues:' ' | | 1.1% {465ms} SmallInteger>>/' ' |2.1% {859ms} Array(SequenceableCollection)>>do:' ' | 2.1% {859ms} [] ApproximationFunctionOptimizer(GeneticAndGradientOptimizer)>>gradientImproveAll' ' | 2.1% {858ms} ApproximationFunctionOptimizer>>gradientImprove:' ' | 1.4% {571ms} ApproximationFunctionOptimizer>>evaluateIndividual:' ' | 1.2% {500ms} OrderedCollection(SequenceableCollection)>>withIndexDo:' ' | 1.1% {446ms} [] ApproximationFunctionOptimizer>>evaluateIndividual:' ' 21.8% {8912ms} TranscriptStream>>show:' ' |21.8% {8911ms} TranscriptStream>>endEntry' ' | 21.8% {8911ms} Semaphore>>critical:' ' | 21.8% {8911ms} BlockClosure>>ensure:' ' | 21.8% {8911ms} [] Semaphore>>critical:' ' | 21.8% {8911ms} [] TranscriptStream>>endEntry' ' | 21.8% {8910ms} TranscriptStream(Object)>>changed:' ' | 21.8% {8909ms} DependentsArray>>do:' ' | 21.8% {8907ms} [] TranscriptStream(Object)>>changed:' ' | 21.8% {8907ms} PluggableTextMorphPlus>>update:' ' | 21.8% {8907ms} PluggableTextMorphPlus(PluggableTextMorph)>>update:' ' | 21.2% {8666ms} PluggableTextMorphPlus(Morph)>>refreshWorld' ' | 21.2% {8665ms} PasteUpMorph>>displayWorldSafely' ' | 21.2% {8665ms} WorldState>>displayWorldSafely:' ' | 21.2% {8665ms} BlockClosure>>ifError:' ' | 21.2% {8665ms} BlockClosure>>on:do:' ' | 21.2% {8665ms} [] WorldState>>displayWorldSafely:' ' | 21.2% {8665ms} PasteUpMorph>>displayWorld' ' | 21.2% {8665ms} PasteUpMorph>>privateOuterDisplayWorld' ' | 21.2% {8665ms} WorldState>>displayWorld:submorphs:' ' | 20.4% {8346ms} WorldState>>drawWorld:submorphs:invalidAreasOn:' ' | 20.4% {8341ms} Array(SequenceableCollection)>>do:' ' | 19.4% {7925ms} [] WorldState>>drawWorld:submorphs:invalidAreasOn:' ' | |19.4% {7917ms} Rectangle>>allAreasOutsideList:do:' ' | | 19.4% {7917ms} Rectangle>>allAreasOutsideList:startingAt:do:' ' | | 18.9% {7729ms} [[]] WorldState>>drawWorld:submorphs:invalidAreasOn:' ' | | 18.9% {7711ms} FormCanvas(Canvas)>>fullDrawMorph:' ' | | 18.9% {7711ms} FormCanvas(Canvas)>>fullDraw:' ' | | 18.9% {7711ms} PluggableSystemWindow(Morph)>>fullDrawOn:' ' | | 12.4% {5062ms} PluggableSystemWindow(Morph)>>drawSubmorphsOn:' ' | | |12.4% {5061ms} [] PluggableSystemWindow(Morph)>>drawSubmorphsOn:' ' | | | 12.4% {5061ms} Array(SequenceableCollection)>>reverseDo:' ' | | | 12.4% {5060ms} [[]] PluggableSystemWindow(Morph)>>drawSubmorphsOn:' ' | | | 12.4% {5060ms} FormCanvas(Canvas)>>fullDrawMorph:' ' | | | 12.4% {5060ms} FormCanvas(Canvas)>>fullDraw:' ' | | | 12.3% {5039ms} PluggableTextMorphPlus(PluggableTextMorph)>>fullDrawOn:' ' | | | 12.3% {5025ms} PluggableTextMorphPlus(Morph)>>fullDrawOn:' ' | | | 11.3% {4596ms} PluggableTextMorphPlus(Morph)>>drawSubmorphsOn:' ' | | | |11.2% {4595ms} [] PluggableTextMorphPlus(Morph)>>drawSubmorphsOn:' ' | | | | 11.2% {4595ms} Array(SequenceableCollection)>>reverseDo:' ' | | | | 11.2% {4592ms} [[]] PluggableTextMorphPlus(Morph)>>drawSubmorphsOn:' ' | | | | 11.2% {4592ms} FormCanvas(Canvas)>>fullDrawMorph:' ' | | | | 11.2% {4592ms} FormCanvas(Canvas)>>fullDraw:' ' | | | | 11.2% {4592ms} TransformMorph(Morph)>>fullDrawOn:' ' | | | | 10.9% {4461ms} TransformMorph>>drawSubmorphsOn:' ' | | | | 10.9% {4460ms} FormCanvas>>transformBy:clippingTo:during:smoothing:' ' | | | | 10.9% {4458ms} [] TransformMorph>>drawSubmorphsOn:' ' | | | | 10.9% {4458ms} Array(SequenceableCollection)>>reverseDo:' ' | | | | 10.9% {4458ms} [[]] TransformMorph>>drawSubmorphsOn:' ' | | | | 10.9% {4457ms} FormCanvas(Canvas)>>fullDrawMorph:' ' | | | | 10.9% {4457ms} FormCanvas(Canvas)>>fullDraw:' ' | | | | 10.9% {4457ms} TextMorphForEditView(Morph)>>fullDrawOn:' ' | | | | 10.9% {4453ms} FormCanvas(Canvas)>>drawMorph:' ' | | | | 10.9% {4453ms} FormCanvas(Canvas)>>draw:' ' | | | | 10.9% {4453ms} TextMorphForEditView(TextMorph)>>drawOn:' ' | | | | 10.9% {4447ms} FormCanvas>>paragraph:bounds:color:' ' | | | | 10.9% {4443ms} NewParagraph>>displayOn:using:at:' ' | | | | 10.9% {4433ms} BitBltDisplayScanner(DisplayScanner)>>displayLine:offset:leftInRun:' ' | | | | 10.6% {4326ms} BitBltDisplayScanner>>displayString:from:to:at:' ' | | | | 10.6% {4326ms} StrikeFont>>displayString:on:from:to:at:kern:' ' | | | | 5.8% {2354ms} Point>>=' ' | | | | 4.8% {1972ms} GrafPort(BitBlt)>>displayString:from:to:at:strikeFont:kern:' ' | | | | 4.8% {1966ms} GrafPort(BitBlt)>>basicDisplayString:from:to:at:strikeFont:kern:' ' | | | | 4.8% {1964ms} primitives' ' | | | 1.0% {428ms} FormCanvas(Canvas)>>drawMorph:' ' | | | 1.0% {428ms} FormCanvas(Canvas)>>draw:' ' | | | 1.0% {428ms} PluggableTextMorphPlus(Morph)>>drawOn:' ' | | | 1.0% {424ms} FormCanvas(Canvas)>>fillRectangle:fillStyle:borderStyle:' ' | | | 1.0% {424ms} SimpleBorder>>frameRectangle:on:' ' | | | 1.0% {415ms} primitives' ' | | 4.0% {1652ms} PluggableSystemWindow(Morph)>>hasRolloverBorder' ' | | |4.0% {1651ms} primitives' ' | | 2.4% {984ms} FormCanvas(Canvas)>>drawMorph:' ' | | 2.4% {984ms} FormCanvas(Canvas)>>draw:' ' | | 2.4% {984ms} PluggableSystemWindow(Morph)>>drawOn:' ' | | 2.4% {979ms} FormCanvas(Canvas)>>fillRectangle:fillStyle:borderStyle:' ' | | 2.3% {955ms} FormCanvas>>fillRectangle:fillStyle:' ' | | 2.3% {953ms} FormCanvas>>balloonFillRectangle:fillStyle:' ' | | 2.3% {951ms} BalloonCanvas>>fillRectangle:fillStyle:' ' | | 2.3% {951ms} BalloonCanvas>>drawRectangle:color:borderWidth:borderColor:' ' | | 2.3% {946ms} BalloonEngine>>drawRectangle:fill:borderWidth:borderColor:transform:' ' | | 2.3% {943ms} BalloonEngine>>postFlushIfNeeded' ' | | 2.3% {943ms} BalloonEngine>>copyBits' ' | | 2.3% {943ms} BalloonEngine>>copyLoopFaster' ' | | 2.3% {942ms} primitives' ' | 1.0% {416ms} primitives' ' 3.0% {1225ms} ApproximationFunctionOptimizer(GeneticAndGradientOptimizer)>>evaluateIndividuals' ' |2.9% {1183ms} OrderedCollection>>do:' ' | 2.9% {1180ms} [] ApproximationFunctionOptimizer(GeneticAndGradientOptimizer)>>evaluateIndividuals' ' | 2.9% {1176ms} ApproximationFunctionOptimizer>>evaluateIndividual:' ' | 2.6% {1054ms} OrderedCollection(SequenceableCollection)>>withIndexDo:' ' | 2.3% {939ms} [] ApproximationFunctionOptimizer>>evaluateIndividual:' ' 1.5% {617ms} ApproximationFunctionOptimizer(GeneticAndGradientOptimizer)>>makeNextGeneration' ' 1.4% {557ms} ApproximationFunctionOptimizer(GeneticAndGradientOptimizer)>>addRecombinations:to:' ' ' '**Leaves**' '21.8% {8900ms} BoxedFloat64(Float)>>abs' '15.1% {6179ms} OrderedCollection>>at:' '5.8% {2356ms} Point>>=' '5.7% {2344ms} SmallInteger>>-' '4.8% {1964ms} GrafPort(BitBlt)>>basicDisplayString:from:to:at:strikeFont:kern:' '4.7% {1915ms} OrderedCollection(SequenceableCollection)>>withIndexDo:' '4.1% {1666ms} TransformMorph(Morph)>>hasRolloverBorder' '3.6% {1460ms} [] ApproximationFunctionOptimizer>>evaluateIndividual:' '3.5% {1448ms} OrderedCollection>>do:' '2.7% {1116ms} Array(SequenceableCollection)>>collect:' '2.6% {1062ms} BoxedFloat64(Number)>>squared' '2.6% {1049ms} Array(SequenceableCollection)>>with:collect:' '2.5% {1019ms} BalloonEngine>>copyLoopFaster' '2.4% {996ms} [] OrderedCollection(Collection)>>reduce:' '2.4% {991ms} OrderedCollection>>add:' '1.4% {579ms} [] OrderedCollection(Collection)>>sum' '1.2% {499ms} BoxedFloat64(Float)>>adaptToInteger:andSend:' '1.1% {445ms} Array(SequenceableCollection)>>do:' '1.0% {426ms} SimpleBorder>>frameRectangle:on:' '' '**Memory**' ' old +0 bytes' ' young -98,504 bytes' ' used -98,504 bytes' ' free +98,504 bytes' '' '**GCs**' ' full 4 totalling 973 ms (2.38% uptime), avg 243.3 ms' ' incr 2065 totalling 6,377 ms (15.6% uptime), avg 3.1 ms' ' tenures 2,036,427 (avg 0 GCs/tenure)' ' root table 0 overflows' From asqueaker at gmail.com Thu Apr 2 16:32:35 2015 From: asqueaker at gmail.com (Chris Muller) Date: Thu Apr 2 16:32:38 2015 Subject: [squeak-dev] Re: The Trunk: Tools-cmm.572.mcz In-Reply-To: <1427975531355-4816883.post@n4.nabble.com> References: <1427975531355-4816883.post@n4.nabble.com> Message-ID: On Thu, Apr 2, 2015 at 6:52 AM, Marcel Taeumel wrote: > I fixed something here: > http://forum.world.st/The-Trunk-Tools-mt-576-mcz-td4816865.html > > Does it now work for you? Yes, we now have the correct window label thank you. From Das.Linux at gmx.de Thu Apr 2 17:13:01 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 2 17:13:04 2015 Subject: [squeak-dev] Rescuing OpenQwaq Message-ID: Hi since Google Code is going away in the future, who can take on rescuing OpenQwaq? https://code.google.com/p/openqwaq Best -Tobias From eliot.miranda at gmail.com Thu Apr 2 21:28:23 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Thu Apr 2 21:28:28 2015 Subject: [squeak-dev] New CogVMs available... Message-ID: ... at http://www.mirandabanda.org/files/Cog/VM/VM.r3306. CogVM binaries as per VMMaker.oscog-eem.1155/r3306 Retract the decision to type the results of the bitwise operators as unsigned; it broke at least the BitBlt plugin. Integrate primitiveIsBigEnder & Nicolas' fix for safer primitiveAdoptInstance & primitiveScanCharacters Mark relevant feature test methods in CogAbstractInstruction as . Spur: Make sure that all stacked values are followed in CoInterpreter>> makeBaseFrameFor: for stale self refs in super sends. Make sure the stack is scanned after a pin operation that involves forwarding. Make sure that the unforwarding stack scan post-become (or post-pin) scans all of the stack contents in the CoInterpreter, since super sends have no read barrier. Mark copyToOldSpace:bytes:format: as not to be inlined so as to avoid impacting copyAndForward's icache density. Newspeak: Add Ryan's new self-send bytecodes. Use NSSendCache for IRC representation. -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150402/32464fe9/attachment.htm From commits at source.squeak.org Thu Apr 2 21:34:33 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 21:34:35 2015 Subject: [squeak-dev] The Trunk: Collections.spur-ul.606.mcz Message-ID: Eliot Miranda uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections.spur-ul.606.mcz ==================== Summary ==================== Name: Collections.spur-ul.606 Author: eem Time: 2 April 2015, 2:32:35.446 pm UUID: 6b5b4807-388d-451d-a7bd-40e7845bc5c2 Ancestors: Collections-ul.606, Collections.spur-mt.605 Collections-ul.606 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.256 Cache and share #separators and #nonSeparators in CharacterSet (just like #crlf). Remove them on #cleanUp. Implemented CharacterSet class >> #withAll:. Removed #noSeparatorMap, #noSeparators, #separatorMap from String class. Also removed the class variables CSNonSeparators, CSSeparators, and CSLineEnders. All users were rewritten to use CharacterSet's version of these sets. =============== Diff against Collections-ul.606 =============== Item was changed: ----- Method: Array>>elementsExchangeIdentityWith: (in category 'converting') ----- elementsExchangeIdentityWith: otherArray + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + At the same time, all pointers to the elements of otherArray are replaced by + pointers to the corresponding elements of this array. The identityHashes remain + with the pointers rather than with the objects so that objects in hashed structures + should still be properly indexed after the mutation." - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. At the same time, all pointers to the elements of otherArray are replaced by pointers to the corresponding elements of this array. The identityHashes remain with the pointers rather than with the objects so that objects in hashed structures should still be properly indexed after the mutation." + + ec == #'bad receiver' ifTrue: + [^self error: 'receiver must be of class Array']. + ec == #'bad argument' ifTrue: + [^self error: (otherArray class == Array + ifTrue: ['arg must be of class Array'] + ifFalse: ['receiver and argument must have the same size'])]. + ec == #'inappropriate operation' ifTrue: + [^self error: 'can''t become immediates such as SmallIntegers or Characters']. + ec == #'no modification' ifTrue: + [^self error: 'can''t become immutable objects']. + ec == #'object is pinned' ifTrue: + [^self error: 'can''t become pinned objects']. + ec == #'insufficient object memory' ifTrue: + [Smalltalk garbageCollect < 1048576 ifTrue: + [Smalltalk growMemoryByAtLeast: 1048576]. + ^self elementsExchangeIdentityWith: otherArray]. + self primitiveFailed! - - otherArray class == Array ifFalse: [^ self error: 'arg must be array']. - self size = otherArray size ifFalse: [^ self error: 'arrays must be same size']. - (self anySatisfy: [:obj | obj class == SmallInteger]) ifTrue: [^ self error: 'can''t become SmallIntegers']. - (otherArray anySatisfy: [:obj | obj class == SmallInteger]) ifTrue: [^ self error: 'can''t become SmallIntegers']. - self with: otherArray do:[:a :b| a == b ifTrue:[^self error:'can''t become yourself']]. - - "Must have failed because not enough space in forwarding table (see ObjectMemory-prepareForwardingTableForBecoming:with:twoWay:). Do GC and try again only once" - (Smalltalk bytesLeft: true) = Smalltalk primitiveGarbageCollect - ifTrue: [^ self primitiveFailed]. - ^ self elementsExchangeIdentityWith: otherArray! Item was changed: ----- Method: Array>>elementsForwardIdentityTo: (in category 'converting') ----- elementsForwardIdentityTo: otherArray + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + The identityHashes remain with the pointers rather than with the objects so that + the objects in this array should still be properly indexed in any existing hashed + structures after the mutation." + - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. The identityHashes remain with the pointers rather than with the objects so that the objects in this array should still be properly indexed in any existing hashed structures after the mutation." - self primitiveFailed! Item was changed: ----- Method: Array>>elementsForwardIdentityTo:copyHash: (in category 'converting') ----- elementsForwardIdentityTo: otherArray copyHash: copyHash + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + If copyHash is true, the identityHashes remain with the pointers rather than with the + objects so that the objects in the receiver should still be properly indexed in any + existing hashed structures after the mutation. If copyHash is false, then the hashes + of the objects in otherArray remain unchanged. If you know what you're doing this + may indeed be what you want." + - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. The identityHashes remain with the pointers rather than with the objects so that the objects in this array should still be properly indexed in any existing hashed structures after the mutation." - self primitiveFailed! Item was changed: ==== ERROR === Error: Unrecognized class type 2 April 2015 9:34:06.275 pm VM: unix - a SmalltalkImage Image: Squeak3.11alpha [latest update: #8824] SecurityManager state: Restricted: false FileAccess: true SocketAccess: true Working Dir /home/squeaksource Trusted Dir /home/squeaksource/secure Untrusted Dir /home/squeaksource/My Squeak MCClassDefinition(Object)>>error: Receiver: a MCClassDefinition(Character) Arguments and temporary variables: aString: 'Unrecognized class type' Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil MCClassDefinition>>kindOfSubclass Receiver: a MCClassDefinition(Character) Arguments and temporary variables: Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil MCClassDefinition>>printDefinitionOn: Receiver: a MCClassDefinition(Character) Arguments and temporary variables: stream: a WriteStream Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil [] in MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: Receiver: a MCDiffyTextWriter Arguments and temporary variables: definition: a WriteStream s: a MCClassDefinition(Character) Receiver's instance variables: stream: a WriteStream initStream: nil --- The full stack --- MCClassDefinition(Object)>>error: MCClassDefinition>>kindOfSubclass MCClassDefinition>>printDefinitionOn: [] in MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - String class(SequenceableCollection class)>>new:streamContents: String class(SequenceableCollection class)>>streamContents: MCDiffyTextWriter(MCTextWriter)>>chunkContents: MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: MCDiffyTextWriter(MCStWriter)>>visitClassDefinition: MCClassDefinition>>accept: [] in MCDiffyTextWriter(MCTextWriter)>>visitInFork: String class(SequenceableCollection class)>>new:streamContents: String class(SequenceableCollection class)>>streamContents: MCDiffyTextWriter(MCTextWriter)>>visitInFork: MCDiffyTextWriter>>writePatchFrom:to: MCDiffyTextWriter>>writeModification: [] in MCDiffyTextWriter>>writePatch: SortedCollection(OrderedCollection)>>do: MCDiffyTextWriter>>writePatch: SSDiffyTextWriter>>writePatch: [] in SSDiffyTextWriter>>writeVersion:for: BlockClosure>>on:do: SSDiffyTextWriter>>writeVersion:for: [] in SSEMailSubscription>>versionAdded:to: BlockClosure>>on:do: SSEMailSubscription>>versionAdded:to: [] in [] in SSProject>>versionAdded: [] in BlockClosure>>newProcess From commits at source.squeak.org Thu Apr 2 21:34:50 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 21:34:54 2015 Subject: [squeak-dev] The Trunk: Collections.spur-ul.607.mcz Message-ID: Eliot Miranda uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections.spur-ul.607.mcz ==================== Summary ==================== Name: Collections.spur-ul.607 Author: eem Time: 2 April 2015, 2:32:39.807 pm UUID: 4588f8d9-2590-4cd0-818b-5b15e84170c9 Ancestors: Collections-ul.607, Collections.spur-ul.606 Collections-ul.607 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.256 Simplified CharacterSet class>>separators. Fixed ReadStream >> #nextFloat, when collection is not a ByteString. =============== Diff against Collections-ul.607 =============== Item was changed: ----- Method: Array>>elementsExchangeIdentityWith: (in category 'converting') ----- elementsExchangeIdentityWith: otherArray + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + At the same time, all pointers to the elements of otherArray are replaced by + pointers to the corresponding elements of this array. The identityHashes remain + with the pointers rather than with the objects so that objects in hashed structures + should still be properly indexed after the mutation." - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. At the same time, all pointers to the elements of otherArray are replaced by pointers to the corresponding elements of this array. The identityHashes remain with the pointers rather than with the objects so that objects in hashed structures should still be properly indexed after the mutation." + + ec == #'bad receiver' ifTrue: + [^self error: 'receiver must be of class Array']. + ec == #'bad argument' ifTrue: + [^self error: (otherArray class == Array + ifTrue: ['arg must be of class Array'] + ifFalse: ['receiver and argument must have the same size'])]. + ec == #'inappropriate operation' ifTrue: + [^self error: 'can''t become immediates such as SmallIntegers or Characters']. + ec == #'no modification' ifTrue: + [^self error: 'can''t become immutable objects']. + ec == #'object is pinned' ifTrue: + [^self error: 'can''t become pinned objects']. + ec == #'insufficient object memory' ifTrue: + [Smalltalk garbageCollect < 1048576 ifTrue: + [Smalltalk growMemoryByAtLeast: 1048576]. + ^self elementsExchangeIdentityWith: otherArray]. + self primitiveFailed! - - otherArray class == Array ifFalse: [^ self error: 'arg must be array']. - self size = otherArray size ifFalse: [^ self error: 'arrays must be same size']. - (self anySatisfy: [:obj | obj class == SmallInteger]) ifTrue: [^ self error: 'can''t become SmallIntegers']. - (otherArray anySatisfy: [:obj | obj class == SmallInteger]) ifTrue: [^ self error: 'can''t become SmallIntegers']. - self with: otherArray do:[:a :b| a == b ifTrue:[^self error:'can''t become yourself']]. - - "Must have failed because not enough space in forwarding table (see ObjectMemory-prepareForwardingTableForBecoming:with:twoWay:). Do GC and try again only once" - (Smalltalk bytesLeft: true) = Smalltalk primitiveGarbageCollect - ifTrue: [^ self primitiveFailed]. - ^ self elementsExchangeIdentityWith: otherArray! Item was changed: ----- Method: Array>>elementsForwardIdentityTo: (in category 'converting') ----- elementsForwardIdentityTo: otherArray + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + The identityHashes remain with the pointers rather than with the objects so that + the objects in this array should still be properly indexed in any existing hashed + structures after the mutation." + - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. The identityHashes remain with the pointers rather than with the objects so that the objects in this array should still be properly indexed in any existing hashed structures after the mutation." - self primitiveFailed! Item was changed: ----- Method: Array>>elementsForwardIdentityTo:copyHash: (in category 'converting') ----- elementsForwardIdentityTo: otherArray copyHash: copyHash + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + If copyHash is true, the identityHashes remain with the pointers rather than with the + objects so that the objects in the receiver should still be properly indexed in any + existing hashed structures after the mutation. If copyHash is false, then the hashes + of the objects in otherArray remain unchanged. If you know what you're doing this + may indeed be what you want." + - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. The identityHashes remain with the pointers rather than with the objects so that the objects in this array should still be properly indexed in any existing hashed structures after the mutation." - self primitiveFailed! Item was changed: ==== ERROR === Error: Unrecognized class type 2 April 2015 9:34:24.725 pm VM: unix - a SmalltalkImage Image: Squeak3.11alpha [latest update: #8824] SecurityManager state: Restricted: false FileAccess: true SocketAccess: true Working Dir /home/squeaksource Trusted Dir /home/squeaksource/secure Untrusted Dir /home/squeaksource/My Squeak MCClassDefinition(Object)>>error: Receiver: a MCClassDefinition(Character) Arguments and temporary variables: aString: 'Unrecognized class type' Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil MCClassDefinition>>kindOfSubclass Receiver: a MCClassDefinition(Character) Arguments and temporary variables: Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil MCClassDefinition>>printDefinitionOn: Receiver: a MCClassDefinition(Character) Arguments and temporary variables: stream: a WriteStream Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil [] in MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: Receiver: a MCDiffyTextWriter Arguments and temporary variables: definition: a WriteStream s: a MCClassDefinition(Character) Receiver's instance variables: stream: a WriteStream initStream: nil --- The full stack --- MCClassDefinition(Object)>>error: MCClassDefinition>>kindOfSubclass MCClassDefinition>>printDefinitionOn: [] in MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - String class(SequenceableCollection class)>>new:streamContents: String class(SequenceableCollection class)>>streamContents: MCDiffyTextWriter(MCTextWriter)>>chunkContents: MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: MCDiffyTextWriter(MCStWriter)>>visitClassDefinition: MCClassDefinition>>accept: [] in MCDiffyTextWriter(MCTextWriter)>>visitInFork: String class(SequenceableCollection class)>>new:streamContents: String class(SequenceableCollection class)>>streamContents: MCDiffyTextWriter(MCTextWriter)>>visitInFork: MCDiffyTextWriter>>writePatchFrom:to: MCDiffyTextWriter>>writeModification: [] in MCDiffyTextWriter>>writePatch: SortedCollection(OrderedCollection)>>do: MCDiffyTextWriter>>writePatch: SSDiffyTextWriter>>writePatch: [] in SSDiffyTextWriter>>writeVersion:for: BlockClosure>>on:do: SSDiffyTextWriter>>writeVersion:for: [] in SSEMailSubscription>>versionAdded:to: BlockClosure>>on:do: SSEMailSubscription>>versionAdded:to: [] in [] in SSProject>>versionAdded: [] in BlockClosure>>newProcess From commits at source.squeak.org Thu Apr 2 21:35:39 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 21:35:41 2015 Subject: [squeak-dev] The Trunk: System.spur-ul.713.mcz Message-ID: Eliot Miranda uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System.spur-ul.713.mcz ==================== Summary ==================== Name: System.spur-ul.713 Author: eem Time: 2 April 2015, 2:33:05.894 pm UUID: 4c09caa9-887f-4382-bedf-62b07dff280f Ancestors: System-ul.713, System.spur-eem.712 System-ul.713 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.256 Use a custom CharacterSet for separators instead of modifying the one in CharacterSet - which may be shared. Cache it for better performance, and get rid of it during cleanUp. =============== Diff against System-ul.713 =============== Item was removed: - Object subclass: #ObjectHistory - instanceVariableNames: 'marks markProcess' - classVariableNames: 'Current' - poolDictionaries: '' - category: 'System-Support'! - - !ObjectHistory commentStamp: 'bf 11/16/2012 12:19' prior: 0! - ObjectHistory holds ObjectHistoryMark objects which are placed in the object memory at regular intervals by its markProcess in the background. Adjacent marks (with no remaining objects inbetween) are coalesced so over time the collection does not grow unnecessarily large. - - Using these markers it is possible to determine the age of objects in memory from the time the ObjectHistory was initialized. Try e.g.: - self oopTimestamp. - self oopAge. - ObjectHistory current oopClassesByDate. - - Instance Variables - marks: SortedCollection of ObjectHistoryMark objects - markProcess: a Process running our markLoop - ! Item was removed: - ----- Method: ObjectHistory class>>current (in category 'accessing') ----- - current - ^ Current ifNil: [Current := self new]! Item was removed: - ----- Method: ObjectHistory class>>initialize (in category 'class initialization') ----- - initialize - self current. - ! Item was removed: - ----- Method: ObjectHistory class>>obsolete (in category 'class initialization') ----- - obsolete - "Kill the mark process before removing the class." - Current ifNotNil: - [:objectHistory| - objectHistory terminate]. - super obsolete! Item was removed: - ----- Method: ObjectHistory>>ageOf: (in category 'queries') ----- - ageOf: anObject - "Age of anObject in seconds" - | timestamp | - timestamp := self timestampOf: anObject. - timestamp ifNil: [^0]. - ^(DateAndTime now - timestamp) asSeconds roundTo: self markRate! Item was removed: - ----- Method: ObjectHistory>>initialize (in category 'initializing') ----- - initialize - self restartMarkProcess. - - ! Item was removed: - ----- Method: ObjectHistory>>markLoop (in category 'marking') ----- - markLoop - [true] whileTrue: [ - self markUpdate. - (Delay forSeconds: self markRate) wait]! Item was removed: - ----- Method: ObjectHistory>>markRate (in category 'marking') ----- - markRate - "rate of creating ObjectHistoryMarks" - ^60! Item was removed: - ----- Method: ObjectHistory>>markUpdate (in category 'marking') ----- - markUpdate - "Add a new mark and compact the marks collection" - | mark prev | - "lazy init so this happens in the background process" - marks ifNil: [self reinitMarks]. - "add new mark to object memory" - mark := self newMark. - mark timestamp <= marks last timestamp ifTrue: [^self "could happen if clock is wrong"]. - marks addLast: mark. - "compact the table by removing adjacent marks" - prev := marks first. - marks removeAllSuchThat: [:each | | doDelete | - doDelete := prev objectAfter == each. - prev := each. - doDelete]. - "The loop above is O(n) in number of marks, but that number should never become so large to be an issue. Even if the number was large, this is running at system background priority so should not interfere with any user process, not even user background processes. The symptom should only be that the system is less idle. - - If we ever get to a point where the number of marks is an issue then the compacting here could be made partial: since old marks rarely get coalesced it would make sense to only check the newer ones often, and the old ones perhaps only at the system startup."! Item was removed: - ----- Method: ObjectHistory>>newMark (in category 'private') ----- - newMark - ^ ObjectHistoryMark new! Item was removed: - ----- Method: ObjectHistory>>oopClassesByAge (in category 'stats') ----- - oopClassesByAge - "Answer collection of (oopAge in seconds -> sorted counts of object classes) sorted from lowest age" - "ObjectHistory current oopClassesByAge" - - | stats prev endOfMemory now bag age obj | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - now := self newMark timestamp. - marks do: [:mark | - prev ifNotNil: [ - bag := Bag new. - obj := prev objectAfter. - [obj == mark] whileFalse: [ - bag add: obj class. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - age := (now - mark timestamp) asSeconds roundTo: self markRate. - stats addFirst: age -> bag sortedCounts]. - prev := mark]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>oopClassesByDate (in category 'stats') ----- - oopClassesByDate - "Answer collection of (Date -> sorted counts of object classes) sorted from newest date" - "ObjectHistory current oopClassesByDate" - - | stats prev endOfMemory bag date obj thisDate | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - thisDate := nil. - bag := Bag new. - marks do: [:mark | - prev ifNotNil: [ - obj := prev objectAfter. - [obj == mark] whileFalse: [ - bag add: obj class. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - date := mark timestamp asDate. - thisDate = date ifFalse: [ - stats addFirst: date -> bag sortedCounts. - bag := Bag new. - thisDate := date]]. - prev := mark]. - thisDate = date ifFalse: [ - stats addLast: date -> bag sortedCounts]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>oopCountsByAge (in category 'stats') ----- - oopCountsByAge - "Answer collection of (oopAge in seconds -> number of objects) sorted from lowest age" - "ObjectHistory current oopCountsByAge" - - | stats prev endOfMemory now n age obj | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - now := self newMark timestamp. - marks do: [:mark | - prev ifNotNil: [ - n := 0. - obj := prev objectAfter. - [obj == mark] whileFalse: [ - n := n + 1. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - age := (now - mark timestamp) asSeconds roundTo: self markRate. - stats addFirst: age -> n]. - prev := mark]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>reinitMarks (in category 'private') ----- - reinitMarks - marks := ObjectHistoryMark allInstances asOrderedCollection. - marks - ifEmpty: [marks add: self newMark] - ifNotEmpty: [ | prev | - prev := nil. - marks removeAllSuchThat: [:obj | - prev notNil and: [prev timestamp >= obj timestamp]]]. - ! Item was removed: - ----- Method: ObjectHistory>>restartMarkProcess (in category 'marking') ----- - restartMarkProcess - markProcess ifNotNil: [markProcess terminate]. - markProcess := [self markLoop] - forkAt: Processor systemBackgroundPriority - named: 'ObjectHistory''s markProcess'. - ! Item was removed: - ----- Method: ObjectHistory>>terminate (in category 'private') ----- - terminate - markProcess ifNotNil: - [markProcess terminate]! Item was removed: - ----- Method: ObjectHistory>>timestampOf: (in category 'queries') ----- - timestampOf: anObject - "Timestamp of anObject, or nil if too new" - | endOfMemory mark | - anObject class == SmallInteger ifTrue: [^nil]. - mark := anObject. - endOfMemory := Object new. - [mark class == ObjectHistoryMark] whileFalse: [ - mark := mark nextObject. - mark == endOfMemory ifTrue: [^nil]]. - ^mark timestamp! Item was removed: - Object subclass: #ObjectHistoryMark - instanceVariableNames: 'timestamp' - classVariableNames: '' - poolDictionaries: '' - category: 'System-Support'! - - !ObjectHistoryMark commentStamp: 'bf 11/7/2012 00:12' prior: 0! - An ObjectHistoryMark is a permanent mark in the object memory. It holds a timestamp. - - While the timestamp could be used directly as mark by ObjectHistory, it's conceivable that its format might change in the future, and we do not want the mark's relative position in memory to change (which would be the case if it was migrated to a new format). So we use a distinct object instead (and we protect it against accidental become-ing by overriding those methods).! Item was removed: - ----- Method: ObjectHistoryMark>>become: (in category 'mutating') ----- - become: otherObject - ^self error: 'marks need to stay fixed in the object memory'! Item was removed: - ----- Method: ObjectHistoryMark>>becomeForward: (in category 'mutating') ----- - becomeForward: otherObject - ^self error: 'marks need to stay fixed in the object memory'! Item was removed: - ----- Method: ObjectHistoryMark>>initialize (in category 'initialization') ----- - initialize - timestamp := DateAndTime now floor. - ! Item was removed: - ----- Method: ObjectHistoryMark>>objectAfter (in category 'accessing') ----- - objectAfter - "Answer the next object in memory after me and my timestamp" - | successor | - successor := self nextObject. - successor == timestamp - ifTrue: [successor := successor nextObject]. - ^ successor! Item was removed: - ----- Method: ObjectHistoryMark>>printOn: (in category 'printing') ----- - printOn: aStream - aStream - nextPutAll: self class name; - nextPut: $(; - print: timestamp; - nextPut: $)! Item was removed: - ----- Method: ObjectHistoryMark>>timestamp (in category 'accessing') ----- - timestamp - ^timestamp - ! Item was changed: ----- Method: SmalltalkImage>>compactClassesArray (in category 'special objects') ----- compactClassesArray "Smalltalk compactClassesArray" + "Backward-compatibility support. Spur does not have compact classes." + ^{}! - "Return the array of 31 classes whose instances may be - represented compactly" - ^ self specialObjectsArray at: 29! Item was added: + ----- Method: SmalltalkImage>>growMemoryByAtLeast: (in category 'memory space') ----- + growMemoryByAtLeast: numBytes + "Grow memory by at least the requested number of bytes. + Primitive. Essential. Fail if no memory is available." + + (numBytes isInteger and: [numBytes > 0]) ifTrue: + [OutOfMemory signal]. + ^self primitiveFailed! Item was added: + ----- Method: SmalltalkImage>>maxIdentityHash (in category 'system attributes') ----- + maxIdentityHash + "Answer the maximum identityHash value supported by the VM." + + ^self primitiveFailed! Item was changed: ----- Method: SmalltalkImage>>primBytesLeft (in category 'memory space') ----- primBytesLeft + "Primitive. Answer the number of free bytes available in old space. + Not accurate unless preceded by - "Primitive. Answer the number of bytes available for new object data. - Not accurate unless preceded by Smalltalk garbageCollectMost (for reasonable accuracy), or Smalltalk garbageCollect (for real accuracy). + See Object documentation whatIsAPrimitive." - See Object documentation whatIsAPrimitive." + ^0! - ^ 0! Item was changed: ----- Method: SmalltalkImage>>primitiveGarbageCollect (in category 'memory space') ----- primitiveGarbageCollect + "Primitive. Reclaims all garbage and answers the size of the largest free chunk in old space.." - "Primitive. Reclaims all garbage and answers the number of bytes of available space." + ^self primitiveFailed! - ^ self primBytesLeft! Item was changed: ----- Method: SmalltalkImage>>recreateSpecialObjectsArray (in category 'special objects') ----- recreateSpecialObjectsArray "Smalltalk recreateSpecialObjectsArray" "To external package developers: **** DO NOT OVERRIDE THIS METHOD. ***** If you are writing a plugin and need additional special object(s) for your own use, use addGCRoot() function and use own, separate special objects registry " "The Special Objects Array is an array of objects used by the Squeak virtual machine. Its contents are critical and accesses to it by the VM are unchecked, so don't even think of playing here unless you know what you are doing." | newArray | + newArray := Array new: 60. - newArray := Array new: 58. "Nil false and true get used throughout the interpreter" newArray at: 1 put: nil. newArray at: 2 put: false. newArray at: 3 put: true. "This association holds the active process (a ProcessScheduler)" newArray at: 4 put: (self specialObjectsArray at: 4) "(self bindingOf: #Processor) but it answers an Alias". "Numerous classes below used for type checking and instantiation" newArray at: 5 put: Bitmap. newArray at: 6 put: SmallInteger. newArray at: 7 put: ByteString. newArray at: 8 put: Array. newArray at: 9 put: Smalltalk. + newArray at: 10 put: BoxedFloat64. + newArray at: 11 put: (self globals at: #MethodContext ifAbsent: [self globals at: #Context]). + newArray at: 12 put: nil. "was BlockContext." - newArray at: 10 put: Float. - newArray at: 11 put: MethodContext. - newArray at: 12 put: BlockContext. newArray at: 13 put: Point. newArray at: 14 put: LargePositiveInteger. newArray at: 15 put: Display. newArray at: 16 put: Message. newArray at: 17 put: CompiledMethod. + newArray at: 18 put: ((self specialObjectsArray at: 18) ifNil: [Semaphore new]). "low space Semaphore" - newArray at: 18 put: (self specialObjectsArray at: 18). - "(low space Semaphore)" newArray at: 19 put: Semaphore. newArray at: 20 put: Character. newArray at: 21 put: #doesNotUnderstand:. newArray at: 22 put: #cannotReturn:. newArray at: 23 put: nil. "This is the process signalling low space." "An array of the 32 selectors that are compiled as special bytecodes, paired alternately with the number of arguments each takes." newArray at: 24 put: #( #+ 1 #- 1 #< 1 #> 1 #<= 1 #>= 1 #= 1 #~= 1 #* 1 #/ 1 #\\ 1 #@ 1 #bitShift: 1 #// 1 #bitAnd: 1 #bitOr: 1 #at: 1 #at:put: 2 #size 0 #next 0 #nextPut: 1 #atEnd 0 #== 1 #class 0 #blockCopy: 1 #value 0 #value: 1 #do: 1 #new 0 #new: 1 #x 0 #y 0 ). "An array of the 255 Characters in ascii order. + Cog inlines table into machine code at: prim so do not regenerate it. + This is nil in Spur, which has immediate Characters." - Cog inlines table into machine code at: prim so do not regenerate it." newArray at: 25 put: (self specialObjectsArray at: 25). newArray at: 26 put: #mustBeBoolean. newArray at: 27 put: ByteArray. newArray at: 28 put: Process. + "An array of up to 31 classes whose instances will have compact headers; an empty array in Spur" - "An array of up to 31 classes whose instances will have compact headers" newArray at: 29 put: self compactClassesArray. + newArray at: 30 put: ((self specialObjectsArray at: 30) ifNil: [Semaphore new]). "delay Semaphore" + newArray at: 31 put: ((self specialObjectsArray at: 31) ifNil: [Semaphore new]). "user interrupt Semaphore" - newArray at: 30 put: (self specialObjectsArray at: 30). "(delay Semaphore)" - newArray at: 31 put: (self specialObjectsArray at: 31). "(user interrupt Semaphore)" "Entries 32 - 34 unreferenced. Previously these contained prototype instances to be copied for fast initialization" + newArray at: 32 put: nil. "was the prototype Float" + newArray at: 33 put: nil. "was the prototype 4-byte LargePositiveInteger" + newArray at: 34 put: nil. "was the prototype Point" - newArray at: 32 put: nil. "was (Float new: 2)" - newArray at: 33 put: nil. "was (LargePositiveInteger new: 4)" - newArray at: 34 put: nil. "was Point new" newArray at: 35 put: #cannotInterpret:. + newArray at: 36 put: nil. "was the prototype MethodContext" - "Note: This must be fixed once we start using context prototypes (yeah, right)" - "(MethodContext new: CompiledMethod fullFrameSize)." - newArray at: 36 put: (self specialObjectsArray at: 36). "Is the prototype MethodContext (unused by the VM)" newArray at: 37 put: BlockClosure. + newArray at: 38 put: nil. "was the prototype BlockContext" - "(BlockContext new: CompiledMethod fullFrameSize)." - newArray at: 38 put: (self specialObjectsArray at: 38). "Is the prototype BlockContext (unused by the VM)" "array of objects referred to by external code" + newArray at: 39 put: (self specialObjectsArray at: 39). "external semaphores" - newArray at: 39 put: (self specialObjectsArray at: 39). "preserve external semaphores" newArray at: 40 put: nil. "Reserved for Mutex in Cog VMs" + newArray at: 41 put: ((self specialObjectsArray at: 41) ifNil: [LinkedList new]). "Reserved for a LinkedList instance for overlapped calls in CogMT" + newArray at: 42 put: ((self specialObjectsArray at: 42) ifNil: [Semaphore new]). "finalization Semaphore" - newArray at: 41 put: nil. "Reserved for a LinkedList instance for overlapped calls in CogMT" - "finalization Semaphore" - newArray at: 42 put: ((self specialObjectsArray at: 42) ifNil: [Semaphore new]). newArray at: 43 put: LargeNegativeInteger. "External objects for callout. Note: Written so that one can actually completely remove the FFI." newArray at: 44 put: (self at: #ExternalAddress ifAbsent: []). newArray at: 45 put: (self at: #ExternalStructure ifAbsent: []). newArray at: 46 put: (self at: #ExternalData ifAbsent: []). newArray at: 47 put: (self at: #ExternalFunction ifAbsent: []). newArray at: 48 put: (self at: #ExternalLibrary ifAbsent: []). newArray at: 49 put: #aboutToReturn:through:. newArray at: 50 put: #run:with:in:. "51 reserved for immutability message" + newArray at: 51 put: #attemptToAssign:withIndex:. - "newArray at: 51 put: #attemptToAssign:withIndex:." - newArray at: 51 put: (self specialObjectsArray at: 51 ifAbsent: []). newArray at: 52 put: #(nil "nil => generic error" #'bad receiver' #'bad argument' #'bad index' #'bad number of arguments' #'inappropriate operation' #'unsupported operation' #'no modification' #'insufficient object memory' #'insufficient C memory' #'not found' #'bad method' #'internal error in named primitive machinery' #'object may move' #'resource limit exceeded' + #'object is pinned' #'primitive write beyond end of object'). - #'object is pinned'). "53 to 55 are for Alien" newArray at: 53 put: (self at: #Alien ifAbsent: []). + newArray at: 54 put: #invokeCallbackContext:. "use invokeCallback:stack:registers:jmpbuf: for old Alien callbacks." - newArray at: 54 put: #invokeCallbackContext::. "use invokeCallback:stack:registers:jmpbuf: for old Alien callbacks." newArray at: 55 put: (self at: #UnsafeAlien ifAbsent: []). + "Used to be WeakFinalizationList for WeakFinalizationList hasNewFinalization, obsoleted by ephemeron support." + newArray at: 56 put: nil. - "Weak reference finalization" - newArray at: 56 put: (self at: #WeakFinalizationList ifAbsent: []). "reserved for foreign callback process" newArray at: 57 put: (self specialObjectsArray at: 57 ifAbsent: []). newArray at: 58 put: #unusedBytecode. + "59 reserved for Sista counter tripped message" + newArray at: 59 put: #conditionalBranchCounterTrippedOn:. + "60 reserved for Sista class trap message" + newArray at: 60 put: #classTrapFor:. "Now replace the interpreter's reference in one atomic operation" + self specialObjectsArray becomeForward: newArray! - self specialObjectsArray becomeForward: newArray - ! Item was changed: ----- Method: SmalltalkImage>>setGCParameters (in category 'snapshot and quit') ----- setGCParameters + "Adjust the VM's default GC parameters to avoid too much tenuring. + Maybe this should be left to the VM?" - "Adjust the VM's default GC parameters to avoid premature tenuring." + | proportion edenSize survivorSize averageObjectSize numObjects | + proportion := 0.9. "tenure when 90% of pastSpace is full" + edenSize := SmalltalkImage current vmParameterAt: 44. + survivorSize := edenSize / 5.0. "David's paper uses 140Kb eden + 2 x 28kb survivor spaces; Spur uses the same ratios :-)" + averageObjectSize := 8 * self wordSize. "a good approximation" + numObjects := (proportion * survivorSize / averageObjectSize) rounded. + SmalltalkImage current vmParameterAt: 6 put: numObjects "tenure when more than this many objects survive the GC"! - self vmParameterAt: 5 put: 4000. "do an incremental GC after this many allocations" - self vmParameterAt: 6 put: 2000. "tenure when more than this many objects survive the GC" - ! Item was changed: ----- Method: SpaceTally>>spaceForInstancesOf: (in category 'instance size') ----- spaceForInstancesOf: aClass + "Answer a pair of the number of bytes consumed by all instances of the + given class, including their object headers, and the number of instances." - "Answer the number of bytes consumed by all instances of the given class, including their object headers and the number of instances." + | instances total | + instances := aClass allInstances. + instances isEmpty ifTrue: [^#(0 0)]. - | smallHeaderSize instVarBytes isVariable bytesPerElement total lastInstance instance instanceCount | - instance := aClass someInstance ifNil: [ ^#(0 0) ]. - smallHeaderSize := aClass isCompact ifTrue: [ 4 ] ifFalse: [ 8 ]. - instVarBytes := aClass instSize * 4. - isVariable := aClass isVariable. - bytesPerElement := isVariable - ifFalse: [ 0 ] - ifTrue: [ aClass isBytes ifTrue: [ 1 ] ifFalse: [ 4 ] ]. total := 0. + aClass isVariable + ifTrue: + [instances do: + [:i| total := total + (aClass byteSizeOfInstanceOfSize: i basicSize)]] + ifFalse: + [total := instances size * aClass byteSizeOfInstance]. + ^{ total. instances size }! - instanceCount := 0. - "A modified version of #allInstancesDo: is inlined here. It avoids an infinite loop when another process is creating new instances of aClass." - self flag: #allInstancesDo:. - lastInstance := - aClass == CompiledMethod "CompiledMethod has special format, see its class comment" - ifTrue: [aClass new] - ifFalse: [aClass basicNew]. - [ instance == lastInstance ] whileFalse: [ - | contentBytes headerBytes | - contentBytes := instVarBytes + (isVariable - ifFalse: [ 0 ] - ifTrue: [ instance basicSize * bytesPerElement ]). - headerBytes := contentBytes > 255 - ifTrue: [ 12 ] - ifFalse: [ smallHeaderSize ]. - total := total + headerBytes + (contentBytes roundUpTo: 4). - instanceCount := instanceCount + 1. - instance := instance nextInstance ]. - ^{ total. instanceCount }! Item was added: + ----- Method: SystemDictionary>>growMemoryByAtLeast: (in category 'memory space') ----- + growMemoryByAtLeast: numBytes + "Grow memory by at least the requested number of bytes. + Primitive. Fail if no memory is available. Essential." + + ^(numBytes isInteger and: [numBytes > 0]) + ifTrue: [OutOfMemory signal] + ifFalse: [self primitiveFailed]! Item was added: + ----- Method: SystemDictionary>>maxIdentityHash (in category 'system attributes') ----- + maxIdentityHash + "Answer the maximum identityHash value supported by the VM." + + ^self primitiveFailed! Item was added: + ----- Method: SystemDictionary>>setGCParameters (in category 'snapshot and quit') ----- + setGCParameters + "Adjust the VM's default GC parameters to avoid too much tenuring. + Maybe this should be left to the VM?" + + | proportion edenSize survivorSize averageObjectSize numObjects | + proportion := 0.9. "tenure when 90% of pastSpace is full" + edenSize := SmalltalkImage current vmParameterAt: 44. + survivorSize := edenSize / 5.0. "David's paper uses 140Kb eden + 2 x 28kb survivor spaces; Spur uses the same ratios :-)" + averageObjectSize := 8 * self wordSize. "a good approximation" + numObjects := (proportion * survivorSize / averageObjectSize) rounded. + SmalltalkImage current vmParameterAt: 6 put: numObjects "tenure when more than this many objects survive the GC"! Item was added: + ----- Method: SystemNavigation>>allObjects (in category 'query') ----- + allObjects + "Answer an Array of all objects in the system. Fail if + there isn't enough memory to instantiate the result." + + ^self primitiveFailed! Item was changed: ----- Method: SystemNavigation>>allObjectsDo: (in category 'query') ----- allObjectsDo: aBlock + "Evaluate the argument, aBlock, for each object in the system, excluding immediates + such as SmallInteger and Character." + self allObjectsOrNil + ifNotNil: [:allObjects| allObjects do: aBlock] + ifNil: + ["Fall back on the old single object primitive code. With closures, this needs + to use an end marker (lastObject) since activation of the block will create + new contexts and cause an infinite loop. The lastObject must be created + before calling someObject, so that the VM can settle the enumeration (e.g. + by flushing new space) as a side effect of someObject" + | object lastObject | + lastObject := Object new. + object := self someObject. + [lastObject == object or: [0 == object]] whileFalse: + [aBlock value: object. + object := object nextObject]]! - "Evaluate the argument, aBlock, for each object in the system - excluding SmallIntegers. With closures, this needs to use an end - marker (lastObject) since activation of the block will create new - contexts and cause an infinite loop." - | object lastObject | - object := self someObject. - lastObject := Object new. - [lastObject == object or: [0 == object]] - whileFalse: [aBlock value: object. - object := object nextObject]! Item was added: + ----- Method: SystemNavigation>>allObjectsOrNil (in category 'query') ----- + allObjectsOrNil + "Answer an Array of all objects in the system. Fail if there isn't + enough memory to instantiate the result and answer nil." + + ^nil! From commits at source.squeak.org Thu Apr 2 21:36:28 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 21:36:32 2015 Subject: [squeak-dev] The Trunk: System.spur-ul.714.mcz Message-ID: Eliot Miranda uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System.spur-ul.714.mcz ==================== Summary ==================== Name: System.spur-ul.714 Author: eem Time: 2 April 2015, 2:33:11.407 pm UUID: ceed85b0-f5f5-461a-9755-4ff3829d769b Ancestors: System-ul.714, System.spur-ul.713 System-ul.714 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.256 Avoid LargeInteger arithmetic in ThirtyTwoBitRegister>>leftRotateBy:. =============== Diff against System-ul.714 =============== Item was removed: - Object subclass: #ObjectHistory - instanceVariableNames: 'marks markProcess' - classVariableNames: 'Current' - poolDictionaries: '' - category: 'System-Support'! - - !ObjectHistory commentStamp: 'bf 11/16/2012 12:19' prior: 0! - ObjectHistory holds ObjectHistoryMark objects which are placed in the object memory at regular intervals by its markProcess in the background. Adjacent marks (with no remaining objects inbetween) are coalesced so over time the collection does not grow unnecessarily large. - - Using these markers it is possible to determine the age of objects in memory from the time the ObjectHistory was initialized. Try e.g.: - self oopTimestamp. - self oopAge. - ObjectHistory current oopClassesByDate. - - Instance Variables - marks: SortedCollection of ObjectHistoryMark objects - markProcess: a Process running our markLoop - ! Item was removed: - ----- Method: ObjectHistory class>>current (in category 'accessing') ----- - current - ^ Current ifNil: [Current := self new]! Item was removed: - ----- Method: ObjectHistory class>>initialize (in category 'class initialization') ----- - initialize - self current. - ! Item was removed: - ----- Method: ObjectHistory class>>obsolete (in category 'class initialization') ----- - obsolete - "Kill the mark process before removing the class." - Current ifNotNil: - [:objectHistory| - objectHistory terminate]. - super obsolete! Item was removed: - ----- Method: ObjectHistory>>ageOf: (in category 'queries') ----- - ageOf: anObject - "Age of anObject in seconds" - | timestamp | - timestamp := self timestampOf: anObject. - timestamp ifNil: [^0]. - ^(DateAndTime now - timestamp) asSeconds roundTo: self markRate! Item was removed: - ----- Method: ObjectHistory>>initialize (in category 'initializing') ----- - initialize - self restartMarkProcess. - - ! Item was removed: - ----- Method: ObjectHistory>>markLoop (in category 'marking') ----- - markLoop - [true] whileTrue: [ - self markUpdate. - (Delay forSeconds: self markRate) wait]! Item was removed: - ----- Method: ObjectHistory>>markRate (in category 'marking') ----- - markRate - "rate of creating ObjectHistoryMarks" - ^60! Item was removed: - ----- Method: ObjectHistory>>markUpdate (in category 'marking') ----- - markUpdate - "Add a new mark and compact the marks collection" - | mark prev | - "lazy init so this happens in the background process" - marks ifNil: [self reinitMarks]. - "add new mark to object memory" - mark := self newMark. - mark timestamp <= marks last timestamp ifTrue: [^self "could happen if clock is wrong"]. - marks addLast: mark. - "compact the table by removing adjacent marks" - prev := marks first. - marks removeAllSuchThat: [:each | | doDelete | - doDelete := prev objectAfter == each. - prev := each. - doDelete]. - "The loop above is O(n) in number of marks, but that number should never become so large to be an issue. Even if the number was large, this is running at system background priority so should not interfere with any user process, not even user background processes. The symptom should only be that the system is less idle. - - If we ever get to a point where the number of marks is an issue then the compacting here could be made partial: since old marks rarely get coalesced it would make sense to only check the newer ones often, and the old ones perhaps only at the system startup."! Item was removed: - ----- Method: ObjectHistory>>newMark (in category 'private') ----- - newMark - ^ ObjectHistoryMark new! Item was removed: - ----- Method: ObjectHistory>>oopClassesByAge (in category 'stats') ----- - oopClassesByAge - "Answer collection of (oopAge in seconds -> sorted counts of object classes) sorted from lowest age" - "ObjectHistory current oopClassesByAge" - - | stats prev endOfMemory now bag age obj | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - now := self newMark timestamp. - marks do: [:mark | - prev ifNotNil: [ - bag := Bag new. - obj := prev objectAfter. - [obj == mark] whileFalse: [ - bag add: obj class. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - age := (now - mark timestamp) asSeconds roundTo: self markRate. - stats addFirst: age -> bag sortedCounts]. - prev := mark]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>oopClassesByDate (in category 'stats') ----- - oopClassesByDate - "Answer collection of (Date -> sorted counts of object classes) sorted from newest date" - "ObjectHistory current oopClassesByDate" - - | stats prev endOfMemory bag date obj thisDate | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - thisDate := nil. - bag := Bag new. - marks do: [:mark | - prev ifNotNil: [ - obj := prev objectAfter. - [obj == mark] whileFalse: [ - bag add: obj class. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - date := mark timestamp asDate. - thisDate = date ifFalse: [ - stats addFirst: date -> bag sortedCounts. - bag := Bag new. - thisDate := date]]. - prev := mark]. - thisDate = date ifFalse: [ - stats addLast: date -> bag sortedCounts]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>oopCountsByAge (in category 'stats') ----- - oopCountsByAge - "Answer collection of (oopAge in seconds -> number of objects) sorted from lowest age" - "ObjectHistory current oopCountsByAge" - - | stats prev endOfMemory now n age obj | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - now := self newMark timestamp. - marks do: [:mark | - prev ifNotNil: [ - n := 0. - obj := prev objectAfter. - [obj == mark] whileFalse: [ - n := n + 1. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - age := (now - mark timestamp) asSeconds roundTo: self markRate. - stats addFirst: age -> n]. - prev := mark]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>reinitMarks (in category 'private') ----- - reinitMarks - marks := ObjectHistoryMark allInstances asOrderedCollection. - marks - ifEmpty: [marks add: self newMark] - ifNotEmpty: [ | prev | - prev := nil. - marks removeAllSuchThat: [:obj | - prev notNil and: [prev timestamp >= obj timestamp]]]. - ! Item was removed: - ----- Method: ObjectHistory>>restartMarkProcess (in category 'marking') ----- - restartMarkProcess - markProcess ifNotNil: [markProcess terminate]. - markProcess := [self markLoop] - forkAt: Processor systemBackgroundPriority - named: 'ObjectHistory''s markProcess'. - ! Item was removed: - ----- Method: ObjectHistory>>terminate (in category 'private') ----- - terminate - markProcess ifNotNil: - [markProcess terminate]! Item was removed: - ----- Method: ObjectHistory>>timestampOf: (in category 'queries') ----- - timestampOf: anObject - "Timestamp of anObject, or nil if too new" - | endOfMemory mark | - anObject class == SmallInteger ifTrue: [^nil]. - mark := anObject. - endOfMemory := Object new. - [mark class == ObjectHistoryMark] whileFalse: [ - mark := mark nextObject. - mark == endOfMemory ifTrue: [^nil]]. - ^mark timestamp! Item was removed: - Object subclass: #ObjectHistoryMark - instanceVariableNames: 'timestamp' - classVariableNames: '' - poolDictionaries: '' - category: 'System-Support'! - - !ObjectHistoryMark commentStamp: 'bf 11/7/2012 00:12' prior: 0! - An ObjectHistoryMark is a permanent mark in the object memory. It holds a timestamp. - - While the timestamp could be used directly as mark by ObjectHistory, it's conceivable that its format might change in the future, and we do not want the mark's relative position in memory to change (which would be the case if it was migrated to a new format). So we use a distinct object instead (and we protect it against accidental become-ing by overriding those methods).! Item was removed: - ----- Method: ObjectHistoryMark>>become: (in category 'mutating') ----- - become: otherObject - ^self error: 'marks need to stay fixed in the object memory'! Item was removed: - ----- Method: ObjectHistoryMark>>becomeForward: (in category 'mutating') ----- - becomeForward: otherObject - ^self error: 'marks need to stay fixed in the object memory'! Item was removed: - ----- Method: ObjectHistoryMark>>initialize (in category 'initialization') ----- - initialize - timestamp := DateAndTime now floor. - ! Item was removed: - ----- Method: ObjectHistoryMark>>objectAfter (in category 'accessing') ----- - objectAfter - "Answer the next object in memory after me and my timestamp" - | successor | - successor := self nextObject. - successor == timestamp - ifTrue: [successor := successor nextObject]. - ^ successor! Item was removed: - ----- Method: ObjectHistoryMark>>printOn: (in category 'printing') ----- - printOn: aStream - aStream - nextPutAll: self class name; - nextPut: $(; - print: timestamp; - nextPut: $)! Item was removed: - ----- Method: ObjectHistoryMark>>timestamp (in category 'accessing') ----- - timestamp - ^timestamp - ! Item was changed: ----- Method: SmalltalkImage>>compactClassesArray (in category 'special objects') ----- compactClassesArray "Smalltalk compactClassesArray" + "Backward-compatibility support. Spur does not have compact classes." + ^{}! - "Return the array of 31 classes whose instances may be - represented compactly" - ^ self specialObjectsArray at: 29! Item was added: + ----- Method: SmalltalkImage>>growMemoryByAtLeast: (in category 'memory space') ----- + growMemoryByAtLeast: numBytes + "Grow memory by at least the requested number of bytes. + Primitive. Essential. Fail if no memory is available." + + (numBytes isInteger and: [numBytes > 0]) ifTrue: + [OutOfMemory signal]. + ^self primitiveFailed! Item was added: + ----- Method: SmalltalkImage>>maxIdentityHash (in category 'system attributes') ----- + maxIdentityHash + "Answer the maximum identityHash value supported by the VM." + + ^self primitiveFailed! Item was changed: ----- Method: SmalltalkImage>>primBytesLeft (in category 'memory space') ----- primBytesLeft + "Primitive. Answer the number of free bytes available in old space. + Not accurate unless preceded by - "Primitive. Answer the number of bytes available for new object data. - Not accurate unless preceded by Smalltalk garbageCollectMost (for reasonable accuracy), or Smalltalk garbageCollect (for real accuracy). + See Object documentation whatIsAPrimitive." - See Object documentation whatIsAPrimitive." + ^0! - ^ 0! Item was changed: ----- Method: SmalltalkImage>>primitiveGarbageCollect (in category 'memory space') ----- primitiveGarbageCollect + "Primitive. Reclaims all garbage and answers the size of the largest free chunk in old space.." - "Primitive. Reclaims all garbage and answers the number of bytes of available space." + ^self primitiveFailed! - ^ self primBytesLeft! Item was changed: ----- Method: SmalltalkImage>>recreateSpecialObjectsArray (in category 'special objects') ----- recreateSpecialObjectsArray "Smalltalk recreateSpecialObjectsArray" "To external package developers: **** DO NOT OVERRIDE THIS METHOD. ***** If you are writing a plugin and need additional special object(s) for your own use, use addGCRoot() function and use own, separate special objects registry " "The Special Objects Array is an array of objects used by the Squeak virtual machine. Its contents are critical and accesses to it by the VM are unchecked, so don't even think of playing here unless you know what you are doing." | newArray | + newArray := Array new: 60. - newArray := Array new: 58. "Nil false and true get used throughout the interpreter" newArray at: 1 put: nil. newArray at: 2 put: false. newArray at: 3 put: true. "This association holds the active process (a ProcessScheduler)" newArray at: 4 put: (self specialObjectsArray at: 4) "(self bindingOf: #Processor) but it answers an Alias". "Numerous classes below used for type checking and instantiation" newArray at: 5 put: Bitmap. newArray at: 6 put: SmallInteger. newArray at: 7 put: ByteString. newArray at: 8 put: Array. newArray at: 9 put: Smalltalk. + newArray at: 10 put: BoxedFloat64. + newArray at: 11 put: (self globals at: #MethodContext ifAbsent: [self globals at: #Context]). + newArray at: 12 put: nil. "was BlockContext." - newArray at: 10 put: Float. - newArray at: 11 put: MethodContext. - newArray at: 12 put: BlockContext. newArray at: 13 put: Point. newArray at: 14 put: LargePositiveInteger. newArray at: 15 put: Display. newArray at: 16 put: Message. newArray at: 17 put: CompiledMethod. + newArray at: 18 put: ((self specialObjectsArray at: 18) ifNil: [Semaphore new]). "low space Semaphore" - newArray at: 18 put: (self specialObjectsArray at: 18). - "(low space Semaphore)" newArray at: 19 put: Semaphore. newArray at: 20 put: Character. newArray at: 21 put: #doesNotUnderstand:. newArray at: 22 put: #cannotReturn:. newArray at: 23 put: nil. "This is the process signalling low space." "An array of the 32 selectors that are compiled as special bytecodes, paired alternately with the number of arguments each takes." newArray at: 24 put: #( #+ 1 #- 1 #< 1 #> 1 #<= 1 #>= 1 #= 1 #~= 1 #* 1 #/ 1 #\\ 1 #@ 1 #bitShift: 1 #// 1 #bitAnd: 1 #bitOr: 1 #at: 1 #at:put: 2 #size 0 #next 0 #nextPut: 1 #atEnd 0 #== 1 #class 0 #blockCopy: 1 #value 0 #value: 1 #do: 1 #new 0 #new: 1 #x 0 #y 0 ). "An array of the 255 Characters in ascii order. + Cog inlines table into machine code at: prim so do not regenerate it. + This is nil in Spur, which has immediate Characters." - Cog inlines table into machine code at: prim so do not regenerate it." newArray at: 25 put: (self specialObjectsArray at: 25). newArray at: 26 put: #mustBeBoolean. newArray at: 27 put: ByteArray. newArray at: 28 put: Process. + "An array of up to 31 classes whose instances will have compact headers; an empty array in Spur" - "An array of up to 31 classes whose instances will have compact headers" newArray at: 29 put: self compactClassesArray. + newArray at: 30 put: ((self specialObjectsArray at: 30) ifNil: [Semaphore new]). "delay Semaphore" + newArray at: 31 put: ((self specialObjectsArray at: 31) ifNil: [Semaphore new]). "user interrupt Semaphore" - newArray at: 30 put: (self specialObjectsArray at: 30). "(delay Semaphore)" - newArray at: 31 put: (self specialObjectsArray at: 31). "(user interrupt Semaphore)" "Entries 32 - 34 unreferenced. Previously these contained prototype instances to be copied for fast initialization" + newArray at: 32 put: nil. "was the prototype Float" + newArray at: 33 put: nil. "was the prototype 4-byte LargePositiveInteger" + newArray at: 34 put: nil. "was the prototype Point" - newArray at: 32 put: nil. "was (Float new: 2)" - newArray at: 33 put: nil. "was (LargePositiveInteger new: 4)" - newArray at: 34 put: nil. "was Point new" newArray at: 35 put: #cannotInterpret:. + newArray at: 36 put: nil. "was the prototype MethodContext" - "Note: This must be fixed once we start using context prototypes (yeah, right)" - "(MethodContext new: CompiledMethod fullFrameSize)." - newArray at: 36 put: (self specialObjectsArray at: 36). "Is the prototype MethodContext (unused by the VM)" newArray at: 37 put: BlockClosure. + newArray at: 38 put: nil. "was the prototype BlockContext" - "(BlockContext new: CompiledMethod fullFrameSize)." - newArray at: 38 put: (self specialObjectsArray at: 38). "Is the prototype BlockContext (unused by the VM)" "array of objects referred to by external code" + newArray at: 39 put: (self specialObjectsArray at: 39). "external semaphores" - newArray at: 39 put: (self specialObjectsArray at: 39). "preserve external semaphores" newArray at: 40 put: nil. "Reserved for Mutex in Cog VMs" + newArray at: 41 put: ((self specialObjectsArray at: 41) ifNil: [LinkedList new]). "Reserved for a LinkedList instance for overlapped calls in CogMT" + newArray at: 42 put: ((self specialObjectsArray at: 42) ifNil: [Semaphore new]). "finalization Semaphore" - newArray at: 41 put: nil. "Reserved for a LinkedList instance for overlapped calls in CogMT" - "finalization Semaphore" - newArray at: 42 put: ((self specialObjectsArray at: 42) ifNil: [Semaphore new]). newArray at: 43 put: LargeNegativeInteger. "External objects for callout. Note: Written so that one can actually completely remove the FFI." newArray at: 44 put: (self at: #ExternalAddress ifAbsent: []). newArray at: 45 put: (self at: #ExternalStructure ifAbsent: []). newArray at: 46 put: (self at: #ExternalData ifAbsent: []). newArray at: 47 put: (self at: #ExternalFunction ifAbsent: []). newArray at: 48 put: (self at: #ExternalLibrary ifAbsent: []). newArray at: 49 put: #aboutToReturn:through:. newArray at: 50 put: #run:with:in:. "51 reserved for immutability message" + newArray at: 51 put: #attemptToAssign:withIndex:. - "newArray at: 51 put: #attemptToAssign:withIndex:." - newArray at: 51 put: (self specialObjectsArray at: 51 ifAbsent: []). newArray at: 52 put: #(nil "nil => generic error" #'bad receiver' #'bad argument' #'bad index' #'bad number of arguments' #'inappropriate operation' #'unsupported operation' #'no modification' #'insufficient object memory' #'insufficient C memory' #'not found' #'bad method' #'internal error in named primitive machinery' #'object may move' #'resource limit exceeded' + #'object is pinned' #'primitive write beyond end of object'). - #'object is pinned'). "53 to 55 are for Alien" newArray at: 53 put: (self at: #Alien ifAbsent: []). + newArray at: 54 put: #invokeCallbackContext:. "use invokeCallback:stack:registers:jmpbuf: for old Alien callbacks." - newArray at: 54 put: #invokeCallbackContext::. "use invokeCallback:stack:registers:jmpbuf: for old Alien callbacks." newArray at: 55 put: (self at: #UnsafeAlien ifAbsent: []). + "Used to be WeakFinalizationList for WeakFinalizationList hasNewFinalization, obsoleted by ephemeron support." + newArray at: 56 put: nil. - "Weak reference finalization" - newArray at: 56 put: (self at: #WeakFinalizationList ifAbsent: []). "reserved for foreign callback process" newArray at: 57 put: (self specialObjectsArray at: 57 ifAbsent: []). newArray at: 58 put: #unusedBytecode. + "59 reserved for Sista counter tripped message" + newArray at: 59 put: #conditionalBranchCounterTrippedOn:. + "60 reserved for Sista class trap message" + newArray at: 60 put: #classTrapFor:. "Now replace the interpreter's reference in one atomic operation" + self specialObjectsArray becomeForward: newArray! - self specialObjectsArray becomeForward: newArray - ! Item was changed: ----- Method: SmalltalkImage>>setGCParameters (in category 'snapshot and quit') ----- setGCParameters + "Adjust the VM's default GC parameters to avoid too much tenuring. + Maybe this should be left to the VM?" - "Adjust the VM's default GC parameters to avoid premature tenuring." + | proportion edenSize survivorSize averageObjectSize numObjects | + proportion := 0.9. "tenure when 90% of pastSpace is full" + edenSize := SmalltalkImage current vmParameterAt: 44. + survivorSize := edenSize / 5.0. "David's paper uses 140Kb eden + 2 x 28kb survivor spaces; Spur uses the same ratios :-)" + averageObjectSize := 8 * self wordSize. "a good approximation" + numObjects := (proportion * survivorSize / averageObjectSize) rounded. + SmalltalkImage current vmParameterAt: 6 put: numObjects "tenure when more than this many objects survive the GC"! - self vmParameterAt: 5 put: 4000. "do an incremental GC after this many allocations" - self vmParameterAt: 6 put: 2000. "tenure when more than this many objects survive the GC" - ! Item was changed: ----- Method: SpaceTally>>spaceForInstancesOf: (in category 'instance size') ----- spaceForInstancesOf: aClass + "Answer a pair of the number of bytes consumed by all instances of the + given class, including their object headers, and the number of instances." - "Answer the number of bytes consumed by all instances of the given class, including their object headers and the number of instances." + | instances total | + instances := aClass allInstances. + instances isEmpty ifTrue: [^#(0 0)]. - | smallHeaderSize instVarBytes isVariable bytesPerElement total lastInstance instance instanceCount | - instance := aClass someInstance ifNil: [ ^#(0 0) ]. - smallHeaderSize := aClass isCompact ifTrue: [ 4 ] ifFalse: [ 8 ]. - instVarBytes := aClass instSize * 4. - isVariable := aClass isVariable. - bytesPerElement := isVariable - ifFalse: [ 0 ] - ifTrue: [ aClass isBytes ifTrue: [ 1 ] ifFalse: [ 4 ] ]. total := 0. + aClass isVariable + ifTrue: + [instances do: + [:i| total := total + (aClass byteSizeOfInstanceOfSize: i basicSize)]] + ifFalse: + [total := instances size * aClass byteSizeOfInstance]. + ^{ total. instances size }! - instanceCount := 0. - "A modified version of #allInstancesDo: is inlined here. It avoids an infinite loop when another process is creating new instances of aClass." - self flag: #allInstancesDo:. - lastInstance := - aClass == CompiledMethod "CompiledMethod has special format, see its class comment" - ifTrue: [aClass new] - ifFalse: [aClass basicNew]. - [ instance == lastInstance ] whileFalse: [ - | contentBytes headerBytes | - contentBytes := instVarBytes + (isVariable - ifFalse: [ 0 ] - ifTrue: [ instance basicSize * bytesPerElement ]). - headerBytes := contentBytes > 255 - ifTrue: [ 12 ] - ifFalse: [ smallHeaderSize ]. - total := total + headerBytes + (contentBytes roundUpTo: 4). - instanceCount := instanceCount + 1. - instance := instance nextInstance ]. - ^{ total. instanceCount }! Item was added: + ----- Method: SystemDictionary>>growMemoryByAtLeast: (in category 'memory space') ----- + growMemoryByAtLeast: numBytes + "Grow memory by at least the requested number of bytes. + Primitive. Fail if no memory is available. Essential." + + ^(numBytes isInteger and: [numBytes > 0]) + ifTrue: [OutOfMemory signal] + ifFalse: [self primitiveFailed]! Item was added: + ----- Method: SystemDictionary>>maxIdentityHash (in category 'system attributes') ----- + maxIdentityHash + "Answer the maximum identityHash value supported by the VM." + + ^self primitiveFailed! Item was added: + ----- Method: SystemDictionary>>setGCParameters (in category 'snapshot and quit') ----- + setGCParameters + "Adjust the VM's default GC parameters to avoid too much tenuring. + Maybe this should be left to the VM?" + + | proportion edenSize survivorSize averageObjectSize numObjects | + proportion := 0.9. "tenure when 90% of pastSpace is full" + edenSize := SmalltalkImage current vmParameterAt: 44. + survivorSize := edenSize / 5.0. "David's paper uses 140Kb eden + 2 x 28kb survivor spaces; Spur uses the same ratios :-)" + averageObjectSize := 8 * self wordSize. "a good approximation" + numObjects := (proportion * survivorSize / averageObjectSize) rounded. + SmalltalkImage current vmParameterAt: 6 put: numObjects "tenure when more than this many objects survive the GC"! Item was added: + ----- Method: SystemNavigation>>allObjects (in category 'query') ----- + allObjects + "Answer an Array of all objects in the system. Fail if + there isn't enough memory to instantiate the result." + + ^self primitiveFailed! Item was changed: ----- Method: SystemNavigation>>allObjectsDo: (in category 'query') ----- allObjectsDo: aBlock + "Evaluate the argument, aBlock, for each object in the system, excluding immediates + such as SmallInteger and Character." + self allObjectsOrNil + ifNotNil: [:allObjects| allObjects do: aBlock] + ifNil: + ["Fall back on the old single object primitive code. With closures, this needs + to use an end marker (lastObject) since activation of the block will create + new contexts and cause an infinite loop. The lastObject must be created + before calling someObject, so that the VM can settle the enumeration (e.g. + by flushing new space) as a side effect of someObject" + | object lastObject | + lastObject := Object new. + object := self someObject. + [lastObject == object or: [0 == object]] whileFalse: + [aBlock value: object. + object := object nextObject]]! - "Evaluate the argument, aBlock, for each object in the system - excluding SmallIntegers. With closures, this needs to use an end - marker (lastObject) since activation of the block will create new - contexts and cause an infinite loop." - | object lastObject | - object := self someObject. - lastObject := Object new. - [lastObject == object or: [0 == object]] - whileFalse: [aBlock value: object. - object := object nextObject]! Item was added: + ----- Method: SystemNavigation>>allObjectsOrNil (in category 'query') ----- + allObjectsOrNil + "Answer an Array of all objects in the system. Fail if there isn't + enough memory to instantiate the result and answer nil." + + ^nil! From commits at source.squeak.org Thu Apr 2 21:36:48 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 21:36:51 2015 Subject: [squeak-dev] The Trunk: System.spur-topa.715.mcz Message-ID: Eliot Miranda uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System.spur-topa.715.mcz ==================== Summary ==================== Name: System.spur-topa.715 Author: eem Time: 2 April 2015, 2:32:57.548 pm UUID: ed6b2198-6259-4adc-a599-701c5a2e18a3 Ancestors: System-topa.715 System-topa.715 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.256 Make SoundService registeredClasses class-based. Categorize in AppRegistry =============== Diff against System-topa.715 =============== Item was removed: - Object subclass: #ObjectHistory - instanceVariableNames: 'marks markProcess' - classVariableNames: 'Current' - poolDictionaries: '' - category: 'System-Support'! - - !ObjectHistory commentStamp: 'bf 11/16/2012 12:19' prior: 0! - ObjectHistory holds ObjectHistoryMark objects which are placed in the object memory at regular intervals by its markProcess in the background. Adjacent marks (with no remaining objects inbetween) are coalesced so over time the collection does not grow unnecessarily large. - - Using these markers it is possible to determine the age of objects in memory from the time the ObjectHistory was initialized. Try e.g.: - self oopTimestamp. - self oopAge. - ObjectHistory current oopClassesByDate. - - Instance Variables - marks: SortedCollection of ObjectHistoryMark objects - markProcess: a Process running our markLoop - ! Item was removed: - ----- Method: ObjectHistory class>>current (in category 'accessing') ----- - current - ^ Current ifNil: [Current := self new]! Item was removed: - ----- Method: ObjectHistory class>>initialize (in category 'class initialization') ----- - initialize - self current. - ! Item was removed: - ----- Method: ObjectHistory class>>obsolete (in category 'class initialization') ----- - obsolete - "Kill the mark process before removing the class." - Current ifNotNil: - [:objectHistory| - objectHistory terminate]. - super obsolete! Item was removed: - ----- Method: ObjectHistory>>ageOf: (in category 'queries') ----- - ageOf: anObject - "Age of anObject in seconds" - | timestamp | - timestamp := self timestampOf: anObject. - timestamp ifNil: [^0]. - ^(DateAndTime now - timestamp) asSeconds roundTo: self markRate! Item was removed: - ----- Method: ObjectHistory>>initialize (in category 'initializing') ----- - initialize - self restartMarkProcess. - - ! Item was removed: - ----- Method: ObjectHistory>>markLoop (in category 'marking') ----- - markLoop - [true] whileTrue: [ - self markUpdate. - (Delay forSeconds: self markRate) wait]! Item was removed: - ----- Method: ObjectHistory>>markRate (in category 'marking') ----- - markRate - "rate of creating ObjectHistoryMarks" - ^60! Item was removed: - ----- Method: ObjectHistory>>markUpdate (in category 'marking') ----- - markUpdate - "Add a new mark and compact the marks collection" - | mark prev | - "lazy init so this happens in the background process" - marks ifNil: [self reinitMarks]. - "add new mark to object memory" - mark := self newMark. - mark timestamp <= marks last timestamp ifTrue: [^self "could happen if clock is wrong"]. - marks addLast: mark. - "compact the table by removing adjacent marks" - prev := marks first. - marks removeAllSuchThat: [:each | | doDelete | - doDelete := prev objectAfter == each. - prev := each. - doDelete]. - "The loop above is O(n) in number of marks, but that number should never become so large to be an issue. Even if the number was large, this is running at system background priority so should not interfere with any user process, not even user background processes. The symptom should only be that the system is less idle. - - If we ever get to a point where the number of marks is an issue then the compacting here could be made partial: since old marks rarely get coalesced it would make sense to only check the newer ones often, and the old ones perhaps only at the system startup."! Item was removed: - ----- Method: ObjectHistory>>newMark (in category 'private') ----- - newMark - ^ ObjectHistoryMark new! Item was removed: - ----- Method: ObjectHistory>>oopClassesByAge (in category 'stats') ----- - oopClassesByAge - "Answer collection of (oopAge in seconds -> sorted counts of object classes) sorted from lowest age" - "ObjectHistory current oopClassesByAge" - - | stats prev endOfMemory now bag age obj | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - now := self newMark timestamp. - marks do: [:mark | - prev ifNotNil: [ - bag := Bag new. - obj := prev objectAfter. - [obj == mark] whileFalse: [ - bag add: obj class. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - age := (now - mark timestamp) asSeconds roundTo: self markRate. - stats addFirst: age -> bag sortedCounts]. - prev := mark]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>oopClassesByDate (in category 'stats') ----- - oopClassesByDate - "Answer collection of (Date -> sorted counts of object classes) sorted from newest date" - "ObjectHistory current oopClassesByDate" - - | stats prev endOfMemory bag date obj thisDate | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - thisDate := nil. - bag := Bag new. - marks do: [:mark | - prev ifNotNil: [ - obj := prev objectAfter. - [obj == mark] whileFalse: [ - bag add: obj class. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - date := mark timestamp asDate. - thisDate = date ifFalse: [ - stats addFirst: date -> bag sortedCounts. - bag := Bag new. - thisDate := date]]. - prev := mark]. - thisDate = date ifFalse: [ - stats addLast: date -> bag sortedCounts]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>oopCountsByAge (in category 'stats') ----- - oopCountsByAge - "Answer collection of (oopAge in seconds -> number of objects) sorted from lowest age" - "ObjectHistory current oopCountsByAge" - - | stats prev endOfMemory now n age obj | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - now := self newMark timestamp. - marks do: [:mark | - prev ifNotNil: [ - n := 0. - obj := prev objectAfter. - [obj == mark] whileFalse: [ - n := n + 1. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - age := (now - mark timestamp) asSeconds roundTo: self markRate. - stats addFirst: age -> n]. - prev := mark]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>reinitMarks (in category 'private') ----- - reinitMarks - marks := ObjectHistoryMark allInstances asOrderedCollection. - marks - ifEmpty: [marks add: self newMark] - ifNotEmpty: [ | prev | - prev := nil. - marks removeAllSuchThat: [:obj | - prev notNil and: [prev timestamp >= obj timestamp]]]. - ! Item was removed: - ----- Method: ObjectHistory>>restartMarkProcess (in category 'marking') ----- - restartMarkProcess - markProcess ifNotNil: [markProcess terminate]. - markProcess := [self markLoop] - forkAt: Processor systemBackgroundPriority - named: 'ObjectHistory''s markProcess'. - ! Item was removed: - ----- Method: ObjectHistory>>terminate (in category 'private') ----- - terminate - markProcess ifNotNil: - [markProcess terminate]! Item was removed: - ----- Method: ObjectHistory>>timestampOf: (in category 'queries') ----- - timestampOf: anObject - "Timestamp of anObject, or nil if too new" - | endOfMemory mark | - anObject class == SmallInteger ifTrue: [^nil]. - mark := anObject. - endOfMemory := Object new. - [mark class == ObjectHistoryMark] whileFalse: [ - mark := mark nextObject. - mark == endOfMemory ifTrue: [^nil]]. - ^mark timestamp! Item was removed: - Object subclass: #ObjectHistoryMark - instanceVariableNames: 'timestamp' - classVariableNames: '' - poolDictionaries: '' - category: 'System-Support'! - - !ObjectHistoryMark commentStamp: 'bf 11/7/2012 00:12' prior: 0! - An ObjectHistoryMark is a permanent mark in the object memory. It holds a timestamp. - - While the timestamp could be used directly as mark by ObjectHistory, it's conceivable that its format might change in the future, and we do not want the mark's relative position in memory to change (which would be the case if it was migrated to a new format). So we use a distinct object instead (and we protect it against accidental become-ing by overriding those methods).! Item was removed: - ----- Method: ObjectHistoryMark>>become: (in category 'mutating') ----- - become: otherObject - ^self error: 'marks need to stay fixed in the object memory'! Item was removed: - ----- Method: ObjectHistoryMark>>becomeForward: (in category 'mutating') ----- - becomeForward: otherObject - ^self error: 'marks need to stay fixed in the object memory'! Item was removed: - ----- Method: ObjectHistoryMark>>initialize (in category 'initialization') ----- - initialize - timestamp := DateAndTime now floor. - ! Item was removed: - ----- Method: ObjectHistoryMark>>objectAfter (in category 'accessing') ----- - objectAfter - "Answer the next object in memory after me and my timestamp" - | successor | - successor := self nextObject. - successor == timestamp - ifTrue: [successor := successor nextObject]. - ^ successor! Item was removed: - ----- Method: ObjectHistoryMark>>printOn: (in category 'printing') ----- - printOn: aStream - aStream - nextPutAll: self class name; - nextPut: $(; - print: timestamp; - nextPut: $)! Item was removed: - ----- Method: ObjectHistoryMark>>timestamp (in category 'accessing') ----- - timestamp - ^timestamp - ! Item was changed: ----- Method: SmalltalkImage>>compactClassesArray (in category 'special objects') ----- compactClassesArray "Smalltalk compactClassesArray" + "Backward-compatibility support. Spur does not have compact classes." + ^{}! - "Return the array of 31 classes whose instances may be - represented compactly" - ^ self specialObjectsArray at: 29! Item was added: + ----- Method: SmalltalkImage>>growMemoryByAtLeast: (in category 'memory space') ----- + growMemoryByAtLeast: numBytes + "Grow memory by at least the requested number of bytes. + Primitive. Essential. Fail if no memory is available." + + (numBytes isInteger and: [numBytes > 0]) ifTrue: + [OutOfMemory signal]. + ^self primitiveFailed! Item was added: + ----- Method: SmalltalkImage>>maxIdentityHash (in category 'system attributes') ----- + maxIdentityHash + "Answer the maximum identityHash value supported by the VM." + + ^self primitiveFailed! Item was changed: ----- Method: SmalltalkImage>>primBytesLeft (in category 'memory space') ----- primBytesLeft + "Primitive. Answer the number of free bytes available in old space. + Not accurate unless preceded by - "Primitive. Answer the number of bytes available for new object data. - Not accurate unless preceded by Smalltalk garbageCollectMost (for reasonable accuracy), or Smalltalk garbageCollect (for real accuracy). + See Object documentation whatIsAPrimitive." - See Object documentation whatIsAPrimitive." + ^0! - ^ 0! Item was changed: ----- Method: SmalltalkImage>>primitiveGarbageCollect (in category 'memory space') ----- primitiveGarbageCollect + "Primitive. Reclaims all garbage and answers the size of the largest free chunk in old space.." - "Primitive. Reclaims all garbage and answers the number of bytes of available space." + ^self primitiveFailed! - ^ self primBytesLeft! Item was changed: ----- Method: SmalltalkImage>>recreateSpecialObjectsArray (in category 'special objects') ----- recreateSpecialObjectsArray "Smalltalk recreateSpecialObjectsArray" "To external package developers: **** DO NOT OVERRIDE THIS METHOD. ***** If you are writing a plugin and need additional special object(s) for your own use, use addGCRoot() function and use own, separate special objects registry " "The Special Objects Array is an array of objects used by the Squeak virtual machine. Its contents are critical and accesses to it by the VM are unchecked, so don't even think of playing here unless you know what you are doing." | newArray | + newArray := Array new: 60. - newArray := Array new: 58. "Nil false and true get used throughout the interpreter" newArray at: 1 put: nil. newArray at: 2 put: false. newArray at: 3 put: true. "This association holds the active process (a ProcessScheduler)" newArray at: 4 put: (self specialObjectsArray at: 4) "(self bindingOf: #Processor) but it answers an Alias". "Numerous classes below used for type checking and instantiation" newArray at: 5 put: Bitmap. newArray at: 6 put: SmallInteger. newArray at: 7 put: ByteString. newArray at: 8 put: Array. newArray at: 9 put: Smalltalk. + newArray at: 10 put: BoxedFloat64. + newArray at: 11 put: (self globals at: #MethodContext ifAbsent: [self globals at: #Context]). + newArray at: 12 put: nil. "was BlockContext." - newArray at: 10 put: Float. - newArray at: 11 put: MethodContext. - newArray at: 12 put: BlockContext. newArray at: 13 put: Point. newArray at: 14 put: LargePositiveInteger. newArray at: 15 put: Display. newArray at: 16 put: Message. newArray at: 17 put: CompiledMethod. + newArray at: 18 put: ((self specialObjectsArray at: 18) ifNil: [Semaphore new]). "low space Semaphore" - newArray at: 18 put: (self specialObjectsArray at: 18). - "(low space Semaphore)" newArray at: 19 put: Semaphore. newArray at: 20 put: Character. newArray at: 21 put: #doesNotUnderstand:. newArray at: 22 put: #cannotReturn:. newArray at: 23 put: nil. "This is the process signalling low space." "An array of the 32 selectors that are compiled as special bytecodes, paired alternately with the number of arguments each takes." newArray at: 24 put: #( #+ 1 #- 1 #< 1 #> 1 #<= 1 #>= 1 #= 1 #~= 1 #* 1 #/ 1 #\\ 1 #@ 1 #bitShift: 1 #// 1 #bitAnd: 1 #bitOr: 1 #at: 1 #at:put: 2 #size 0 #next 0 #nextPut: 1 #atEnd 0 #== 1 #class 0 #blockCopy: 1 #value 0 #value: 1 #do: 1 #new 0 #new: 1 #x 0 #y 0 ). "An array of the 255 Characters in ascii order. + Cog inlines table into machine code at: prim so do not regenerate it. + This is nil in Spur, which has immediate Characters." - Cog inlines table into machine code at: prim so do not regenerate it." newArray at: 25 put: (self specialObjectsArray at: 25). newArray at: 26 put: #mustBeBoolean. newArray at: 27 put: ByteArray. newArray at: 28 put: Process. + "An array of up to 31 classes whose instances will have compact headers; an empty array in Spur" - "An array of up to 31 classes whose instances will have compact headers" newArray at: 29 put: self compactClassesArray. + newArray at: 30 put: ((self specialObjectsArray at: 30) ifNil: [Semaphore new]). "delay Semaphore" + newArray at: 31 put: ((self specialObjectsArray at: 31) ifNil: [Semaphore new]). "user interrupt Semaphore" - newArray at: 30 put: (self specialObjectsArray at: 30). "(delay Semaphore)" - newArray at: 31 put: (self specialObjectsArray at: 31). "(user interrupt Semaphore)" "Entries 32 - 34 unreferenced. Previously these contained prototype instances to be copied for fast initialization" + newArray at: 32 put: nil. "was the prototype Float" + newArray at: 33 put: nil. "was the prototype 4-byte LargePositiveInteger" + newArray at: 34 put: nil. "was the prototype Point" - newArray at: 32 put: nil. "was (Float new: 2)" - newArray at: 33 put: nil. "was (LargePositiveInteger new: 4)" - newArray at: 34 put: nil. "was Point new" newArray at: 35 put: #cannotInterpret:. + newArray at: 36 put: nil. "was the prototype MethodContext" - "Note: This must be fixed once we start using context prototypes (yeah, right)" - "(MethodContext new: CompiledMethod fullFrameSize)." - newArray at: 36 put: (self specialObjectsArray at: 36). "Is the prototype MethodContext (unused by the VM)" newArray at: 37 put: BlockClosure. + newArray at: 38 put: nil. "was the prototype BlockContext" - "(BlockContext new: CompiledMethod fullFrameSize)." - newArray at: 38 put: (self specialObjectsArray at: 38). "Is the prototype BlockContext (unused by the VM)" "array of objects referred to by external code" + newArray at: 39 put: (self specialObjectsArray at: 39). "external semaphores" - newArray at: 39 put: (self specialObjectsArray at: 39). "preserve external semaphores" newArray at: 40 put: nil. "Reserved for Mutex in Cog VMs" + newArray at: 41 put: ((self specialObjectsArray at: 41) ifNil: [LinkedList new]). "Reserved for a LinkedList instance for overlapped calls in CogMT" + newArray at: 42 put: ((self specialObjectsArray at: 42) ifNil: [Semaphore new]). "finalization Semaphore" - newArray at: 41 put: nil. "Reserved for a LinkedList instance for overlapped calls in CogMT" - "finalization Semaphore" - newArray at: 42 put: ((self specialObjectsArray at: 42) ifNil: [Semaphore new]). newArray at: 43 put: LargeNegativeInteger. "External objects for callout. Note: Written so that one can actually completely remove the FFI." newArray at: 44 put: (self at: #ExternalAddress ifAbsent: []). newArray at: 45 put: (self at: #ExternalStructure ifAbsent: []). newArray at: 46 put: (self at: #ExternalData ifAbsent: []). newArray at: 47 put: (self at: #ExternalFunction ifAbsent: []). newArray at: 48 put: (self at: #ExternalLibrary ifAbsent: []). newArray at: 49 put: #aboutToReturn:through:. newArray at: 50 put: #run:with:in:. "51 reserved for immutability message" + newArray at: 51 put: #attemptToAssign:withIndex:. - "newArray at: 51 put: #attemptToAssign:withIndex:." - newArray at: 51 put: (self specialObjectsArray at: 51 ifAbsent: []). newArray at: 52 put: #(nil "nil => generic error" #'bad receiver' #'bad argument' #'bad index' #'bad number of arguments' #'inappropriate operation' #'unsupported operation' #'no modification' #'insufficient object memory' #'insufficient C memory' #'not found' #'bad method' #'internal error in named primitive machinery' #'object may move' #'resource limit exceeded' + #'object is pinned' #'primitive write beyond end of object'). - #'object is pinned'). "53 to 55 are for Alien" newArray at: 53 put: (self at: #Alien ifAbsent: []). + newArray at: 54 put: #invokeCallbackContext:. "use invokeCallback:stack:registers:jmpbuf: for old Alien callbacks." - newArray at: 54 put: #invokeCallbackContext::. "use invokeCallback:stack:registers:jmpbuf: for old Alien callbacks." newArray at: 55 put: (self at: #UnsafeAlien ifAbsent: []). + "Used to be WeakFinalizationList for WeakFinalizationList hasNewFinalization, obsoleted by ephemeron support." + newArray at: 56 put: nil. - "Weak reference finalization" - newArray at: 56 put: (self at: #WeakFinalizationList ifAbsent: []). "reserved for foreign callback process" newArray at: 57 put: (self specialObjectsArray at: 57 ifAbsent: []). newArray at: 58 put: #unusedBytecode. + "59 reserved for Sista counter tripped message" + newArray at: 59 put: #conditionalBranchCounterTrippedOn:. + "60 reserved for Sista class trap message" + newArray at: 60 put: #classTrapFor:. "Now replace the interpreter's reference in one atomic operation" + self specialObjectsArray becomeForward: newArray! - self specialObjectsArray becomeForward: newArray - ! Item was changed: ----- Method: SmalltalkImage>>setGCParameters (in category 'snapshot and quit') ----- setGCParameters + "Adjust the VM's default GC parameters to avoid too much tenuring. + Maybe this should be left to the VM?" - "Adjust the VM's default GC parameters to avoid premature tenuring." + | proportion edenSize survivorSize averageObjectSize numObjects | + proportion := 0.9. "tenure when 90% of pastSpace is full" + edenSize := SmalltalkImage current vmParameterAt: 44. + survivorSize := edenSize / 5.0. "David's paper uses 140Kb eden + 2 x 28kb survivor spaces; Spur uses the same ratios :-)" + averageObjectSize := 8 * self wordSize. "a good approximation" + numObjects := (proportion * survivorSize / averageObjectSize) rounded. + SmalltalkImage current vmParameterAt: 6 put: numObjects "tenure when more than this many objects survive the GC"! - self vmParameterAt: 5 put: 4000. "do an incremental GC after this many allocations" - self vmParameterAt: 6 put: 2000. "tenure when more than this many objects survive the GC" - ! Item was changed: ----- Method: SpaceTally>>spaceForInstancesOf: (in category 'instance size') ----- spaceForInstancesOf: aClass + "Answer a pair of the number of bytes consumed by all instances of the + given class, including their object headers, and the number of instances." - "Answer the number of bytes consumed by all instances of the given class, including their object headers and the number of instances." + | instances total | + instances := aClass allInstances. + instances isEmpty ifTrue: [^#(0 0)]. - | smallHeaderSize instVarBytes isVariable bytesPerElement total lastInstance instance instanceCount | - instance := aClass someInstance ifNil: [ ^#(0 0) ]. - smallHeaderSize := aClass isCompact ifTrue: [ 4 ] ifFalse: [ 8 ]. - instVarBytes := aClass instSize * 4. - isVariable := aClass isVariable. - bytesPerElement := isVariable - ifFalse: [ 0 ] - ifTrue: [ aClass isBytes ifTrue: [ 1 ] ifFalse: [ 4 ] ]. total := 0. + aClass isVariable + ifTrue: + [instances do: + [:i| total := total + (aClass byteSizeOfInstanceOfSize: i basicSize)]] + ifFalse: + [total := instances size * aClass byteSizeOfInstance]. + ^{ total. instances size }! - instanceCount := 0. - "A modified version of #allInstancesDo: is inlined here. It avoids an infinite loop when another process is creating new instances of aClass." - self flag: #allInstancesDo:. - lastInstance := - aClass == CompiledMethod "CompiledMethod has special format, see its class comment" - ifTrue: [aClass new] - ifFalse: [aClass basicNew]. - [ instance == lastInstance ] whileFalse: [ - | contentBytes headerBytes | - contentBytes := instVarBytes + (isVariable - ifFalse: [ 0 ] - ifTrue: [ instance basicSize * bytesPerElement ]). - headerBytes := contentBytes > 255 - ifTrue: [ 12 ] - ifFalse: [ smallHeaderSize ]. - total := total + headerBytes + (contentBytes roundUpTo: 4). - instanceCount := instanceCount + 1. - instance := instance nextInstance ]. - ^{ total. instanceCount }! Item was added: + ----- Method: SystemDictionary>>growMemoryByAtLeast: (in category 'memory space') ----- + growMemoryByAtLeast: numBytes + "Grow memory by at least the requested number of bytes. + Primitive. Fail if no memory is available. Essential." + + ^(numBytes isInteger and: [numBytes > 0]) + ifTrue: [OutOfMemory signal] + ifFalse: [self primitiveFailed]! Item was added: + ----- Method: SystemDictionary>>maxIdentityHash (in category 'system attributes') ----- + maxIdentityHash + "Answer the maximum identityHash value supported by the VM." + + ^self primitiveFailed! Item was added: + ----- Method: SystemDictionary>>setGCParameters (in category 'snapshot and quit') ----- + setGCParameters + "Adjust the VM's default GC parameters to avoid too much tenuring. + Maybe this should be left to the VM?" + + | proportion edenSize survivorSize averageObjectSize numObjects | + proportion := 0.9. "tenure when 90% of pastSpace is full" + edenSize := SmalltalkImage current vmParameterAt: 44. + survivorSize := edenSize / 5.0. "David's paper uses 140Kb eden + 2 x 28kb survivor spaces; Spur uses the same ratios :-)" + averageObjectSize := 8 * self wordSize. "a good approximation" + numObjects := (proportion * survivorSize / averageObjectSize) rounded. + SmalltalkImage current vmParameterAt: 6 put: numObjects "tenure when more than this many objects survive the GC"! Item was added: + ----- Method: SystemNavigation>>allObjects (in category 'query') ----- + allObjects + "Answer an Array of all objects in the system. Fail if + there isn't enough memory to instantiate the result." + + ^self primitiveFailed! Item was changed: ----- Method: SystemNavigation>>allObjectsDo: (in category 'query') ----- allObjectsDo: aBlock + "Evaluate the argument, aBlock, for each object in the system, excluding immediates + such as SmallInteger and Character." + self allObjectsOrNil + ifNotNil: [:allObjects| allObjects do: aBlock] + ifNil: + ["Fall back on the old single object primitive code. With closures, this needs + to use an end marker (lastObject) since activation of the block will create + new contexts and cause an infinite loop. The lastObject must be created + before calling someObject, so that the VM can settle the enumeration (e.g. + by flushing new space) as a side effect of someObject" + | object lastObject | + lastObject := Object new. + object := self someObject. + [lastObject == object or: [0 == object]] whileFalse: + [aBlock value: object. + object := object nextObject]]! - "Evaluate the argument, aBlock, for each object in the system - excluding SmallIntegers. With closures, this needs to use an end - marker (lastObject) since activation of the block will create new - contexts and cause an infinite loop." - | object lastObject | - object := self someObject. - lastObject := Object new. - [lastObject == object or: [0 == object]] - whileFalse: [aBlock value: object. - object := object nextObject]! Item was added: + ----- Method: SystemNavigation>>allObjectsOrNil (in category 'query') ----- + allObjectsOrNil + "Answer an Array of all objects in the system. Fail if there isn't + enough memory to instantiate the result and answer nil." + + ^nil! From commits at source.squeak.org Thu Apr 2 21:55:03 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 21:55:05 2015 Subject: [squeak-dev] Daily Commit Log Message-ID: <20150402215503.4225.qmail@box4.squeakfoundation.org> Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours: http://lists.squeakfoundation.org/pipermail/packages/2015-April/007765.html Name: Collections-ul.606 Ancestors: Collections-mt.605 Cache and share #separators and #nonSeparators in CharacterSet (just like #crlf). Remove them on #cleanUp. Implemented CharacterSet class >> #withAll:. Removed #noSeparatorMap, #noSeparators, #separatorMap from String class. Also removed the class variables CSNonSeparators, CSSeparators, and CSLineEnders. All users were rewritten to use CharacterSet's version of these sets. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007766.html Name: Network-ul.159 Ancestors: Network-ul.158 Use CharacterSet's #nonSeparators shared set instead of creating and storing another one in MailAddressTokenizer. Initialize other character sets lazily, and release them during cleanUp. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007767.html Name: Collections-ul.607 Ancestors: Collections-ul.606 Simplified CharacterSet class>>separators. Fixed ReadStream >> #nextFloat, when collection is not a ByteString. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007768.html Name: ToolBuilder-Morphic-mt.115 Ancestors: ToolBuilder-Morphic-cmm.114 Revert something that was re-introduced in cmm.112 but already reverted before. #selectPath:in: must send #setSelectedMorph: because both are callbacks from #update: within the tree morph. #selection only talks to the model. We do not have an equivalent for tree-path selection, which talks to the model, yet. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007769.html Name: Tools-mt.573 Ancestors: Tools-cmm.572 Revert last change in opening explorer because additional call to #rootObject: not needed. If there is a bug, which I cannot reproduce in my trunk image, it may lie somewhere else. Anyway, #rootObject: should always update the model correctly. No need to call it twice. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007770.html Name: Tools-mt.574 Ancestors: Tools-mt.573 Added #hMargin to trees. Feature moved from scroll panes to particular tools. Having this, tree selection will ecompass also this margin and no white pixels will be there. Having this, it is a cosmetic change. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007771.html Name: Morphic-mt.806 Ancestors: Morphic-cmm.805 Removed hard-coded margins in scroll panes and added them to lists, text fields, and trees. This gives tool-specific widgets more control about how to handle/draw this margins. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007772.html Name: Morphic-mt.807 Ancestors: Morphic-mt.806 Fixed #scrollToShow:, which needed an additional offset-lock, because scroll bars tend to call back their float values to the pane, which then tries to calculate pixels again. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007773.html Name: Morphic-mt.808 Ancestors: Morphic-mt.807 Text fields only show balloon if it has no text. The balloon text will be rendered in that case. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007774.html Name: ToolBuilder-Morphic-mt.116 Ancestors: ToolBuilder-Morphic-mt.115 Fixed resizing of search input and button bar in ListChooser. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007775.html Name: ShoutTests-topa.25 Ancestors: ShoutTests-eem.24 Try to lower testing time by caching source file access. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007776.html Name: Morphic-mt.809 Ancestors: Morphic-mt.808 Fix selection in lists or trees for context menus. By default, models rely on the current selection for the menu. This can be confusing if the user invokes that menu on a different item. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007777.html Name: System-topa.715 Ancestors: System-ul.714 Make SoundService registeredClasses class-based. Categorize in AppRegistry ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007778.html Name: Sound-topa.43 Ancestors: Sound-bf.42 Make SoundService registeredClasses class-based. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007779.html Name: EToys-topa.120 Ancestors: EToys-bf.119 Make sure we have a SoundSystem when testing sound. (Alas, DummySoundSystem doesn't cut it here) ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007780.html Name: Tools-mt.575 Ancestors: Tools-mt.574 Made interface of object explorer consistent with interface of inspector. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007781.html Name: Morphic-mt.810 Ancestors: Morphic-mt.809 Exploring a morph via its halo menu now attaches the explorer also to the hand -- like inspecting does. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007782.html Name: Tools-mt.576 Ancestors: Tools-mt.575 Fixes the bug with the wrang label in the system window of object explorers. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007783.html Name: Morphic-mt.811 Ancestors: Morphic-mt.810 Some fixes in system windows regarding labels. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007784.html Name: Morphic-mt.812 Ancestors: Morphic-mt.811 Fixed main docking bar to support interaction with outermost pixels. This is especially useful in fullscreen mode where you want to navigate to topLeft and open the Squeak menu or topRight and click to exit fullscreen. Before, there were pixel offsets and thus you had to acquire your target carefully. This fix includes a replacement of the SearchBarMorph with one that uses tool builder and the pluggable text morph. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007785.html Name: Collections.spur-ul.606 Ancestors: Collections-ul.606, Collections.spur-mt.605 Collections-ul.606 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.256 Cache and share #separators and #nonSeparators in CharacterSet (just like #crlf). Remove them on #cleanUp. Implemented CharacterSet class >> #withAll:. Removed #noSeparatorMap, #noSeparators, #separatorMap from String class. Also removed the class variables CSNonSeparators, CSSeparators, and CSLineEnders. All users were rewritten to use CharacterSet's version of these sets. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007786.html Name: Collections.spur-ul.607 Ancestors: Collections-ul.607, Collections.spur-ul.606 Collections-ul.607 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.256 Simplified CharacterSet class>>separators. Fixed ReadStream >> #nextFloat, when collection is not a ByteString. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007787.html Name: Kernel.spur-topa.915 Ancestors: Kernel-topa.915, Kernel.spur-cmm.914 Kernel-topa.915 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.256 Fix arguments access in WeakMessageSend comparison. They may be nil; but the accessor guards that already. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007788.html Name: Kernel.spur-topa.916 Ancestors: Kernel-topa.916, Kernel.spur-topa.915 Kernel-topa.916 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.256 (same as before) Fix arguments access in WeakMessageSend ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007789.html Name: System.spur-ul.713 Ancestors: System-ul.713, System.spur-eem.712 System-ul.713 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.256 Use a custom CharacterSet for separators instead of modifying the one in CharacterSet - which may be shared. Cache it for better performance, and get rid of it during cleanUp. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007790.html Name: System.spur-ul.714 Ancestors: System-ul.714, System.spur-ul.713 System-ul.714 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.256 Avoid LargeInteger arithmetic in ThirtyTwoBitRegister>>leftRotateBy:. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007791.html Name: System.spur-topa.715 Ancestors: System-topa.715 System-topa.715 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.256 Make SoundService registeredClasses class-based. Categorize in AppRegistry ============================================= From commits at source.squeak.org Thu Apr 2 22:20:57 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 2 22:20:58 2015 Subject: [squeak-dev] The Trunk: EToys-topa.121.mcz Message-ID: Tobias Pape uploaded a new version of EToys to project The Trunk: http://source.squeak.org/trunk/EToys-topa.121.mcz ==================== Summary ==================== Name: EToys-topa.121 Author: topa Time: 3 April 2015, 12:20:38.114 am UUID: d3f4e3f2-9ef0-4138-89d2-a88d122f9bc6 Ancestors: EToys-topa.120 As Etoys is not _per se_ dependent on Sound, be graceful about its presence in Etoys' tests. =============== Diff against EToys-topa.120 =============== Item was added: + ----- Method: TileMorphTest>>expectedFailures (in category 'testing') ----- + expectedFailures + + ^ super expectedFailures, + ((Smalltalk hasClassNamed: 'BaseSoundSystem') + ifTrue: [#()] + ifFalse: [#(testSoundTile) "Only this test depends on Sound"])! Item was changed: ----- Method: TileMorphTest>>setUp (in category 'running') ----- setUp self soundSystemBackup: SoundService defaultOrNil. + SoundService default: (Smalltalk classNamed: 'BaseSoundSystem').! - SoundService default: BaseSoundSystem.! From leves at elte.hu Thu Apr 2 22:32:59 2015 From: leves at elte.hu (Levente Uzonyi) Date: Thu Apr 2 22:33:03 2015 Subject: [squeak-dev] The Trunk: EToys-topa.121.mcz In-Reply-To: References: Message-ID: I prefer to use Symbols instead of Strings for class names, because they make it easier to find potential users of the class. Levente On Thu, 2 Apr 2015, commits@source.squeak.org wrote: > Tobias Pape uploaded a new version of EToys to project The Trunk: > http://source.squeak.org/trunk/EToys-topa.121.mcz > > ==================== Summary ==================== > > Name: EToys-topa.121 > Author: topa > Time: 3 April 2015, 12:20:38.114 am > UUID: d3f4e3f2-9ef0-4138-89d2-a88d122f9bc6 > Ancestors: EToys-topa.120 > > As Etoys is not _per se_ dependent on Sound, be graceful about its presence in Etoys' tests. > > =============== Diff against EToys-topa.120 =============== > > Item was added: > + ----- Method: TileMorphTest>>expectedFailures (in category 'testing') ----- > + expectedFailures > + > + ^ super expectedFailures, > + ((Smalltalk hasClassNamed: 'BaseSoundSystem') > + ifTrue: [#()] > + ifFalse: [#(testSoundTile) "Only this test depends on Sound"])! > > Item was changed: > ----- Method: TileMorphTest>>setUp (in category 'running') ----- > setUp > > self soundSystemBackup: SoundService defaultOrNil. > + SoundService default: (Smalltalk classNamed: 'BaseSoundSystem').! > - SoundService default: BaseSoundSystem.! > > > From frank.shearar at gmail.com Thu Apr 2 22:34:04 2015 From: frank.shearar at gmail.com (Frank Shearar) Date: Thu Apr 2 22:34:08 2015 Subject: [squeak-dev] Rescuing OpenQwaq In-Reply-To: References: Message-ID: On 2 April 2015 at 18:13, Tobias Pape wrote: > Hi > > since Google Code is going away in the future, > who can take on rescuing OpenQwaq? > https://code.google.com/p/openqwaq Shall we export it to https://github.com/squeak-smalltalk/ ? Any one of the owners - Bert, Colin, David or I - could do it. If it's appropriate, etc. frank > Best > -Tobias > From eliot.miranda at gmail.com Thu Apr 2 22:43:30 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Thu Apr 2 22:43:32 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. Message-ID: Hi All, since the hover highlight changes, where the list element under the mouse that would be selected if one clicks is highlighted in light blue appears to have caused a bad bug. If one does a right-button clock to bring up a menu the system can end up selecting the item under the mouse before putting up the menu. This is *wrong*. The mouse click to bring up a menu should /not/ change the selection. -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150402/e32c50f3/attachment.htm From Das.Linux at gmx.de Thu Apr 2 22:52:43 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 2 22:52:47 2015 Subject: [squeak-dev] The Trunk: EToys-topa.121.mcz In-Reply-To: References: Message-ID: Hi, On 03.04.2015, at 00:32, Levente Uzonyi wrote: > I prefer to use Symbols instead of Strings for class names, because they make it easier to find potential users of the class. > yes, but #hasClassNamed: is a String protocol. What do you suggest? Smalltalk>>#at: ? > Levente > > On Thu, 2 Apr 2015, commits@source.squeak.org wrote: > >> Tobias Pape uploaded a new version of EToys to project The Trunk: >> http://source.squeak.org/trunk/EToys-topa.121.mcz >> >> ==================== Summary ==================== >> >> Name: EToys-topa.121 >> Author: topa >> Time: 3 April 2015, 12:20:38.114 am >> UUID: d3f4e3f2-9ef0-4138-89d2-a88d122f9bc6 >> Ancestors: EToys-topa.120 >> >> As Etoys is not _per se_ dependent on Sound, be graceful about its presence in Etoys' tests. >> >> =============== Diff against EToys-topa.120 =============== >> >> Item was added: >> + ----- Method: TileMorphTest>>expectedFailures (in category 'testing') ----- >> + expectedFailures >> + >> + ^ super expectedFailures, >> + ((Smalltalk hasClassNamed: 'BaseSoundSystem') >> + ifTrue: [#()] >> + ifFalse: [#(testSoundTile) "Only this test depends on Sound"])! >> >> Item was changed: >> ----- Method: TileMorphTest>>setUp (in category 'running') ----- >> setUp >> >> self soundSystemBackup: SoundService defaultOrNil. >> + SoundService default: (Smalltalk classNamed: 'BaseSoundSystem').! >> - SoundService default: BaseSoundSystem.! From Das.Linux at gmx.de Thu Apr 2 22:56:08 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 2 22:56:11 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: Message-ID: On 03.04.2015, at 00:43, Eliot Miranda wrote: > Hi All, > > since the hover highlight changes, where the list element under the mouse that would be selected if one clicks is highlighted in light blue appears to have caused a bad bug. If one does a right-button clock to bring up a menu the system can end up selecting the item under the mouse before putting up the menu. This is *wrong*. The mouse click to bring up a menu should /not/ change the selection. The rightclick must change the selection, at least _temporarily_ to highlight for what item the menu is constructed. Else, we need a kind-of ?second selection? Best -Tobias From tim at rowledge.org Thu Apr 2 22:58:49 2015 From: tim at rowledge.org (tim Rowledge) Date: Thu Apr 2 22:58:55 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: Message-ID: <57DCF8B9-C8C7-40F0-948F-7C4B290F5502@rowledge.org> On 02-04-2015, at 3:56 PM, Tobias Pape wrote: > > On 03.04.2015, at 00:43, Eliot Miranda wrote: > >> Hi All, >> >> since the hover highlight changes, where the list element under the mouse that would be selected if one clicks is highlighted in light blue appears to have caused a bad bug. If one does a right-button clock to bring up a menu the system can end up selecting the item under the mouse before putting up the menu. This is *wrong*. The mouse click to bring up a menu should /not/ change the selection. > > The rightclick must change the selection, at > least _temporarily_ to highlight for what item the menu is constructed. err, run that one by me again? That sounds awfully, terribly, wrong. tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim Manual Writer's Creed: Garbage in, gospel out. From asqueaker at gmail.com Thu Apr 2 23:00:41 2015 From: asqueaker at gmail.com (Chris Muller) Date: Thu Apr 2 23:00:44 2015 Subject: [squeak-dev] The Trunk: EToys-topa.121.mcz In-Reply-To: References: Message-ID: On Thu, Apr 2, 2015 at 5:52 PM, Tobias Pape wrote: > Hi, > > On 03.04.2015, at 00:32, Levente Uzonyi wrote: > >> I prefer to use Symbols instead of Strings for class names, because they make it easier to find potential users of the class. +1 > yes, but #hasClassNamed: is a String protocol. A Symbol is a String. Many (if not all) existing users of hasClassNamed: pass Symbols (a special kind of String). From Das.Linux at gmx.de Thu Apr 2 23:29:56 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 2 23:29:59 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: <57DCF8B9-C8C7-40F0-948F-7C4B290F5502@rowledge.org> References: <57DCF8B9-C8C7-40F0-948F-7C4B290F5502@rowledge.org> Message-ID: On 03.04.2015, at 00:58, tim Rowledge wrote: > On 02-04-2015, at 3:56 PM, Tobias Pape wrote: > >> >> On 03.04.2015, at 00:43, Eliot Miranda wrote: >> >>> Hi All, >>> >>> since the hover highlight changes, where the list element under the mouse that would be selected if one clicks is highlighted in light blue appears to have caused a bad bug. If one does a right-button clock to bring up a menu the system can end up selecting the item under the mouse before putting up the menu. This is *wrong*. The mouse click to bring up a menu should /not/ change the selection. >> >> The rightclick must change the selection, at >> least _temporarily_ to highlight for what item the menu is constructed. > > err, run that one by me again? That sounds awfully, terribly, wrong. > So when you rightclick on something you need some feedback on what you rightclick to assure you you clicked on the right thing, right? In osx this is done by a kind-of secondary selection (a border instead of a full color highlight) that leaves the primary selection untouched. Since this is afaik only available in one of our widgets that support selection AND context menus, I think changing the selection is fine. Best -Tobias From asqueaker at gmail.com Thu Apr 2 23:31:54 2015 From: asqueaker at gmail.com (Chris Muller) Date: Thu Apr 2 23:31:58 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.806.mcz In-Reply-To: <551cedff.875ae50a.7bb8.1bafSMTPIN_ADDED_MISSING@mx.google.com> References: <551cedff.875ae50a.7bb8.1bafSMTPIN_ADDED_MISSING@mx.google.com> Message-ID: Thanks for all of the wonderful improvements you've been making. I know this seems picky, but I seem to keep noticing the unevenness of the new margins throughout my workday. IMO, the list margin is too wide and the text margin too narrow. I know everyone has different tastes, but if you need custom margins for your app, may we keep the original margins for the default tools in the image? -------------- next part -------------- A non-text attachment was scrubbed... Name: uneven-margins.png Type: image/png Size: 34525 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150402/a51bebc0/uneven-margins.png From Das.Linux at gmx.de Thu Apr 2 23:32:40 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 2 23:32:44 2015 Subject: [squeak-dev] The Trunk: EToys-topa.121.mcz In-Reply-To: References: Message-ID: On 03.04.2015, at 01:00, Chris Muller wrote: > On Thu, Apr 2, 2015 at 5:52 PM, Tobias Pape wrote: >> Hi, >> >> On 03.04.2015, at 00:32, Levente Uzonyi wrote: >> >>> I prefer to use Symbols instead of Strings for class names, because they make it easier to find potential users of the class. > > +1 > >> yes, but #hasClassNamed: is a String protocol. > > A Symbol is a String. Many (if not all) existing users of > hasClassNamed: pass Symbols (a special kind of String). I don't want to rely on that. Symbols being Strings is an implementation detail. Looking at the broader picture, in GemStone, in fact a Symbol is not a String. Best -Tobias From eliot.miranda at gmail.com Thu Apr 2 23:36:27 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Thu Apr 2 23:36:30 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: Message-ID: On Thu, Apr 2, 2015 at 3:56 PM, Tobias Pape wrote: > > On 03.04.2015, at 00:43, Eliot Miranda wrote: > > > Hi All, > > > > since the hover highlight changes, where the list element under the > mouse that would be selected if one clicks is highlighted in light blue > appears to have caused a bad bug. If one does a right-button clock to > bring up a menu the system can end up selecting the item under the mouse > before putting up the menu. This is *wrong*. The mouse click to bring up > a menu should /not/ change the selection. > > The rightclick must change the selection, at > least _temporarily_ to highlight for what item the menu is constructed. > The menu is constructed for *the selected item*, not for the item under the mouse click. Try this. Run the debugger on a large class. In the instance variables list type some chaacter to select inst vars beginning with that name, then select one, then try and issue a right-click to explore the selected inst var. Poof, the filtered inst vars disappear, to be replaced by all inst vars, and then explore applies to some completely unintended selection that isn't even in the list one thought one was selecting from. Please, please, please fix this quickly. The system is /very/ difficult for me to use right now. > Else, we need a kind-of ?second selection? > No we don't. Issuing a red button/left button click changes selections. Issuing *other* mouse button clicks *should not*. Right? It's simple. Right? > > Best > -Tobias > > > -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150402/1978a11d/attachment.htm From nicolas.cellier.aka.nice at gmail.com Thu Apr 2 23:39:47 2015 From: nicolas.cellier.aka.nice at gmail.com (Nicolas Cellier) Date: Thu Apr 2 23:39:50 2015 Subject: [squeak-dev] The Trunk: EToys-topa.121.mcz In-Reply-To: References: Message-ID: 2015-04-03 1:32 GMT+02:00 Tobias Pape : > > On 03.04.2015, at 01:00, Chris Muller wrote: > > > On Thu, Apr 2, 2015 at 5:52 PM, Tobias Pape wrote: > >> Hi, > >> > >> On 03.04.2015, at 00:32, Levente Uzonyi wrote: > >> > >>> I prefer to use Symbols instead of Strings for class names, because > they make it easier to find potential users of the class. > > > > +1 > > > >> yes, but #hasClassNamed: is a String protocol. > > > > A Symbol is a String. Many (if not all) existing users of > > hasClassNamed: pass Symbols (a special kind of String). > > I don't want to rely on that. > Symbols being Strings is an implementation detail. > Looking at the broader picture, in GemStone, in fact > a Symbol is not a String. > > Best > -Tobias > Yes, but String/Symbol equality is an implementation detail. In Visualworks 'foo' ~= #foo. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150403/2167c147/attachment.htm From tim at rowledge.org Thu Apr 2 23:42:55 2015 From: tim at rowledge.org (tim Rowledge) Date: Thu Apr 2 23:43:00 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: Message-ID: <23CBDEE4-1837-4BF3-88D3-FF4A720F2D68@rowledge.org> Gonna have to agree with Eliot on this. This is a big departure from long established UI rules. We have menus that apply to the selected item and the list they?re in. Changing to item-under-the-pointer even when not selected is going to be very confusing. tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim A computer's attention span is only as long as its extension cord. From asqueaker at gmail.com Thu Apr 2 23:44:59 2015 From: asqueaker at gmail.com (Chris Muller) Date: Thu Apr 2 23:45:03 2015 Subject: [squeak-dev] The Trunk: EToys-topa.121.mcz In-Reply-To: References: Message-ID: On Thu, Apr 2, 2015 at 6:32 PM, Tobias Pape wrote: > > On 03.04.2015, at 01:00, Chris Muller wrote: > >> On Thu, Apr 2, 2015 at 5:52 PM, Tobias Pape wrote: >>> Hi, >>> >>> On 03.04.2015, at 00:32, Levente Uzonyi wrote: >>> >>>> I prefer to use Symbols instead of Strings for class names, because they make it easier to find potential users of the class. >> >> +1 >> >>> yes, but #hasClassNamed: is a String protocol. >> >> A Symbol is a String. Many (if not all) existing users of >> hasClassNamed: pass Symbols (a special kind of String). > > I don't want to rely on that. > Symbols being Strings is an implementation detail. Symbols logically ARE Strings, regardless of implementation. They're a series of characters just canonicalized. Its only the canonicalization that's implementation-specific, not equality or type testing.. > Looking at the broader picture, in GemStone, in fact > a Symbol is not a String. Object name "#Object" <---- a Symbol. So why do you say #hasClassNamed: a "String protocol" instead of a "Symbol protocol"? From Das.Linux at gmx.de Thu Apr 2 23:52:57 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 2 23:53:04 2015 Subject: [squeak-dev] The Trunk: EToys-topa.121.mcz In-Reply-To: References: Message-ID: <9A063FEB-616A-4158-8FBD-C1EDB524ECA2@gmx.de> On 03.04.2015, at 01:44, Chris Muller wrote: > On Thu, Apr 2, 2015 at 6:32 PM, Tobias Pape wrote: >> >> On 03.04.2015, at 01:00, Chris Muller wrote: >> >>> On Thu, Apr 2, 2015 at 5:52 PM, Tobias Pape wrote: >>>> Hi, >>>> >>>> On 03.04.2015, at 00:32, Levente Uzonyi wrote: >>>> >>>>> I prefer to use Symbols instead of Strings for class names, because they make it easier to find potential users of the class. >>> >>> +1 >>> >>>> yes, but #hasClassNamed: is a String protocol. >>> >>> A Symbol is a String. Many (if not all) existing users of >>> hasClassNamed: pass Symbols (a special kind of String). >> >> I don't want to rely on that. >> Symbols being Strings is an implementation detail. > > Symbols logically ARE Strings, regardless of implementation. They're > a series of characters just canonicalized. Its only the > canonicalization that's implementation-specific, not equality or type > testing.. Nope. The idea of a symbol is (IMHO, admittedly) broader than just canonicalized Strings. If it where, I would call it InternedString or CanonicalizedString. Symbols are unique human readable identifiers. See Prolog, where the concept is called Atoms. There is no conceptual differences. Yet, Prolog atoms do not remotely compare to interned strings. > >> Looking at the broader picture, in GemStone, in fact >> a Symbol is not a String. > > Object name "#Object" <---- a Symbol. > > So why do you say #hasClassNamed: a "String protocol" instead of a > "Symbol protocol"? See #classOrTraitNamed: (which is called by #classNamed:) classOrTraitNamed: aString "aString is either a class or trait name or a class or trait name followed by ' class' or 'classTrait' respectively. Answer the class or metaclass it names." and hasClassNamed: aString "Answer whether there is a class of the given name, but don't intern aString if it's not alrady interned. 4/29/96 sw" Best -Tobias From Das.Linux at gmx.de Thu Apr 2 23:55:31 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 2 23:55:35 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: Message-ID: <5BFFD39D-C169-4017-B23C-D5EAF9D56B04@gmx.de> On 03.04.2015, at 01:36, Eliot Miranda wrote: > On Thu, Apr 2, 2015 at 3:56 PM, Tobias Pape wrote: > > On 03.04.2015, at 00:43, Eliot Miranda wrote: > >> Hi All, >> >> since the hover highlight changes, where the list element under the mouse that would be selected if one clicks is highlighted in light blue appears to have caused a bad bug. If one does a right-button clock to bring up a menu the system can end up selecting the item under the mouse before putting up the menu. This is *wrong*. The mouse click to bring up a menu should /not/ change the selection. > > The rightclick must change the selection, at > least _temporarily_ to highlight for what item the menu is constructed. > > The menu is constructed for *the selected item*, not for the item under the mouse click. I disagree. I really want the menu for the thing *I am pointing to*. See attached OSX Finder picture. gemstone is selected but I right-clicked on X11, so I want a menu for X11, not for gemstone. > Try this. Run the debugger on a large class. In the instance variables list type some chaacter to select inst vars beginning with that name, then select one, then try and issue a right-click to explore the selected inst var. Poof, the filtered inst vars disappear, to be replaced by all inst vars, and then explore applies to some completely unintended selection that isn't even in the list one thought one was selecting from. The thing in this scenario is that the filtering should not reset before the rightclick is recognized for the intended element, right? > > Please, please, please fix this quickly. The system is /very/ difficult for me to use right now. > > > Else, we need a kind-of ?second selection? > > No we don't. Issuing a red button/left button click changes selections. Issuing *other* mouse button clicks *should not*. Right? It's simple. Right? > > Best > -Tobias -------------- next part -------------- A non-text attachment was scrubbed... Name: Bildschirmfoto 2015-04-03 um 01.41.23.PNG Type: image/png Size: 42524 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150403/966e8025/Bildschirmfoto2015-04-03um01.41.23-0001.png From nicolas.cellier.aka.nice at gmail.com Thu Apr 2 23:56:47 2015 From: nicolas.cellier.aka.nice at gmail.com (Nicolas Cellier) Date: Thu Apr 2 23:56:49 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: <23CBDEE4-1837-4BF3-88D3-FF4A720F2D68@rowledge.org> References: <23CBDEE4-1837-4BF3-88D3-FF4A720F2D68@rowledge.org> Message-ID: 2015-04-03 1:42 GMT+02:00 tim Rowledge : > Gonna have to agree with Eliot on this. This is a big departure from long > established UI rules. We have menus that apply to the selected item and the > list they?re in. Changing to item-under-the-pointer even when not selected > is going to be very confusing. > > tim > Hello Tobias, I agree with Eliot and Tim. Windows UI did force selection under the pop-up and I never liked it. For example, when we want to fileout all the methods, it's mandatory to select none. This is now impossible. I note that the change list which is capable of multiple selections does not have this auto-select annoyance. For windows-addict make it a preference, but be sure old guys like us will never highlight it ;) Nicolas > -- > tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim > A computer's attention span is only as long as its extension cord. > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150403/1c6c8443/attachment.htm From Das.Linux at gmx.de Thu Apr 2 23:58:20 2015 From: Das.Linux at gmx.de (Das.Linux@gmx.de) Date: Thu Apr 2 23:58:24 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: <5BFFD39D-C169-4017-B23C-D5EAF9D56B04@gmx.de> References: <5BFFD39D-C169-4017-B23C-D5EAF9D56B04@gmx.de> Message-ID: On 03.04.2015, at 01:55, Tobias Pape wrote: > > On 03.04.2015, at 01:36, Eliot Miranda wrote: > >> On Thu, Apr 2, 2015 at 3:56 PM, Tobias Pape wrote: >> >> On 03.04.2015, at 00:43, Eliot Miranda wrote: >> >>> Hi All, >>> >>> since the hover highlight changes, where the list element under the mouse that would be selected if one clicks is highlighted in light blue appears to have caused a bad bug. If one does a right-button clock to bring up a menu the system can end up selecting the item under the mouse before putting up the menu. This is *wrong*. The mouse click to bring up a menu should /not/ change the selection. >> >> The rightclick must change the selection, at >> least _temporarily_ to highlight for what item the menu is constructed. >> >> The menu is constructed for *the selected item*, not for the item under the mouse click. > > I disagree. I really want the menu for the thing *I am pointing to*. > > See attached OSX Finder picture. gemstone is selected but I right-clicked on X11, so I > want a menu for X11, not for gemstone. > Another example. There's a text and I have a selection on a word. When I rightclick on another word, I want a context menu for the latter, not the former (that is how it works on OSX and Windows, AFAIK) [snip] Best -Tobias From eliot.miranda at gmail.com Fri Apr 3 00:00:16 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Fri Apr 3 00:00:18 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: <5BFFD39D-C169-4017-B23C-D5EAF9D56B04@gmx.de> References: <5BFFD39D-C169-4017-B23C-D5EAF9D56B04@gmx.de> Message-ID: On Thu, Apr 2, 2015 at 4:55 PM, Tobias Pape wrote: > > On 03.04.2015, at 01:36, Eliot Miranda wrote: > > > On Thu, Apr 2, 2015 at 3:56 PM, Tobias Pape wrote: > > > > On 03.04.2015, at 00:43, Eliot Miranda wrote: > > > >> Hi All, > >> > >> since the hover highlight changes, where the list element under the > mouse that would be selected if one clicks is highlighted in light blue > appears to have caused a bad bug. If one does a right-button clock to > bring up a menu the system can end up selecting the item under the mouse > before putting up the menu. This is *wrong*. The mouse click to bring up > a menu should /not/ change the selection. > > > > The rightclick must change the selection, at > > least _temporarily_ to highlight for what item the menu is constructed. > > > > The menu is constructed for *the selected item*, not for the item under > the mouse click. > > I disagree. I really want the menu for the thing *I am pointing to*. > *NO*. I don't want to have to reposition my bloody mouse pointer every time I want to select from a menu. If *you* want this, make it a preference that is *off* by default. > > See attached OSX Finder picture. gemstone is selected but I right-clicked > on X11, so I > want a menu for X11, not for gemstone. > > > > Try this. Run the debugger on a large class. In the instance > variables list type some chaacter to select inst vars beginning with that > name, then select one, then try and issue a right-click to explore the > selected inst var. Poof, the filtered inst vars disappear, to be replaced > by all inst vars, and then explore applies to some completely unintended > selection that isn't even in the list one thought one was selecting from. > > The thing in this scenario is that the filtering should not reset before > the rightclick > is recognized for the intended element, right? > Whether filtering stays on or not seems independent of whether I've issued a menu clock. But it's bloody confusing when the list changes under the menu when I issue the menu click. > > > > > Please, please, please fix this quickly. The system is /very/ difficult > for me to use right now. > > > > > > Else, we need a kind-of ?second selection? > > > > No we don't. Issuing a red button/left button click changes > selections. Issuing *other* mouse button clicks *should not*. Right? > It's simple. Right? > > > > Best > > -Tobias > > > > > > -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150402/8f84d0aa/attachment.htm From eliot.miranda at gmail.com Fri Apr 3 00:05:06 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Fri Apr 3 00:05:08 2015 Subject: [squeak-dev] Re: bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: Message-ID: You know, we're supposed to be trying to get Squeak 4.5 and Squeak 5 released and instead there's a sudden slew of major UI changes. This really doesn't help. How long are these UI changes going to continue? Surely the right time for this kind of innovation is early in the release cycle. On Thu, Apr 2, 2015 at 3:43 PM, Eliot Miranda wrote: > Hi All, > > since the hover highlight changes, where the list element under the > mouse that would be selected if one clicks is highlighted in light blue > appears to have caused a bad bug. If one does a right-button clock to > bring up a menu the system can end up selecting the item under the mouse > before putting up the menu. This is *wrong*. The mouse click to bring up > a menu should /not/ change the selection. > > -- > best, > Eliot > -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150402/a77a0cd1/attachment.htm From Das.Linux at gmx.de Fri Apr 3 00:36:16 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Fri Apr 3 00:36:22 2015 Subject: [squeak-dev] Re: bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: Message-ID: On 03.04.2015, at 02:05, Eliot Miranda wrote: > You know, we're supposed to be trying to get Squeak 4.5 and Squeak 5 released and instead there's a sudden slew of major UI changes. This really doesn't help. How long are these UI changes going to continue? Surely the right time for this kind of innovation is early in the release cycle. Sorry, I didn't do a thing here; I just said that it matches my experience and is current UI lingua franca? Heck, I just took on some tests nobody cares about? Best -Tobias From nicolas.cellier.aka.nice at gmail.com Fri Apr 3 00:39:45 2015 From: nicolas.cellier.aka.nice at gmail.com (Nicolas Cellier) Date: Fri Apr 3 00:39:46 2015 Subject: [squeak-dev] The Trunk: EToys-topa.121.mcz In-Reply-To: <9A063FEB-616A-4158-8FBD-C1EDB524ECA2@gmx.de> References: <9A063FEB-616A-4158-8FBD-C1EDB524ECA2@gmx.de> Message-ID: 2015-04-03 1:52 GMT+02:00 Tobias Pape : > > On 03.04.2015, at 01:44, Chris Muller wrote: > > > On Thu, Apr 2, 2015 at 6:32 PM, Tobias Pape wrote: > >> > >> On 03.04.2015, at 01:00, Chris Muller wrote: > >> > >>> On Thu, Apr 2, 2015 at 5:52 PM, Tobias Pape wrote: > >>>> Hi, > >>>> > >>>> On 03.04.2015, at 00:32, Levente Uzonyi wrote: > >>>> > >>>>> I prefer to use Symbols instead of Strings for class names, because > they make it easier to find potential users of the class. > >>> > >>> +1 > >>> > >>>> yes, but #hasClassNamed: is a String protocol. > >>> > >>> A Symbol is a String. Many (if not all) existing users of > >>> hasClassNamed: pass Symbols (a special kind of String). > >> > >> I don't want to rely on that. > >> Symbols being Strings is an implementation detail. > > > > Symbols logically ARE Strings, regardless of implementation. They're > > a series of characters just canonicalized. Its only the > > canonicalization that's implementation-specific, not equality or type > > testing.. > > Nope. The idea of a symbol is (IMHO, admittedly) broader than > just canonicalized Strings. If it where, I would call it InternedString > or CanonicalizedString. Symbols are unique human readable identifiers. > > See Prolog, where the concept is called Atoms. There is no conceptual > differences. Yet, Prolog atoms do not remotely compare to interned strings. > > > > >> Looking at the broader picture, in GemStone, in fact > >> a Symbol is not a String. > > > > Object name "#Object" <---- a Symbol. > > > > So why do you say #hasClassNamed: a "String protocol" instead of a > > "Symbol protocol"? > > See #classOrTraitNamed: (which is called by #classNamed:) > > classOrTraitNamed: aString > "aString is either a class or trait name or a class or trait name > followed by ' class' or 'classTrait' respectively. > Answer the class or metaclass it names." > > and > > hasClassNamed: aString > "Answer whether there is a class of the given name, but don't > intern aString if it's not alrady interned. 4/29/96 sw" > > > Best > -Tobias > > > To me, the idea to not intern 'BaseSoundSystem' is moot. We blatantly have a reference to #BaseSoundSystem that we try to hide. Why? Nicolas -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150403/ca1abb6d/attachment.htm From Das.Linux at gmx.de Fri Apr 3 00:41:44 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Fri Apr 3 00:41:49 2015 Subject: [squeak-dev] The Trunk: EToys-topa.121.mcz In-Reply-To: References: <9A063FEB-616A-4158-8FBD-C1EDB524ECA2@gmx.de> Message-ID: On 03.04.2015, at 02:39, Nicolas Cellier wrote: > > > 2015-04-03 1:52 GMT+02:00 Tobias Pape : > > On 03.04.2015, at 01:44, Chris Muller wrote: > > > On Thu, Apr 2, 2015 at 6:32 PM, Tobias Pape wrote: > >> > >> On 03.04.2015, at 01:00, Chris Muller wrote: > >> > >>> On Thu, Apr 2, 2015 at 5:52 PM, Tobias Pape wrote: > >>>> Hi, > >>>> > >>>> On 03.04.2015, at 00:32, Levente Uzonyi wrote: > >>>> > >>>>> I prefer to use Symbols instead of Strings for class names, because they make it easier to find potential users of the class. > >>> > >>> +1 > >>> > >>>> yes, but #hasClassNamed: is a String protocol. > >>> > >>> A Symbol is a String. Many (if not all) existing users of > >>> hasClassNamed: pass Symbols (a special kind of String). > >> > >> I don't want to rely on that. > >> Symbols being Strings is an implementation detail. > > > > Symbols logically ARE Strings, regardless of implementation. They're > > a series of characters just canonicalized. Its only the > > canonicalization that's implementation-specific, not equality or type > > testing.. > > Nope. The idea of a symbol is (IMHO, admittedly) broader than > just canonicalized Strings. If it where, I would call it InternedString > or CanonicalizedString. Symbols are unique human readable identifiers. > > See Prolog, where the concept is called Atoms. There is no conceptual > differences. Yet, Prolog atoms do not remotely compare to interned strings. > > > > >> Looking at the broader picture, in GemStone, in fact > >> a Symbol is not a String. > > > > Object name "#Object" <---- a Symbol. > > > > So why do you say #hasClassNamed: a "String protocol" instead of a > > "Symbol protocol"? > > See #classOrTraitNamed: (which is called by #classNamed:) > > classOrTraitNamed: aString > "aString is either a class or trait name or a class or trait name followed by ' class' or 'classTrait' respectively. > Answer the class or metaclass it names." > > and > > hasClassNamed: aString > "Answer whether there is a class of the given name, but don't intern aString if it's not alrady interned. 4/29/96 sw" > > > Best > -Tobias > > > > To me, the idea to not intern 'BaseSoundSystem' is moot. > We blatantly have a reference to #BaseSoundSystem that we try to hide. Why? Nothing in particular. How would you write that? Best -Tobias From asqueaker at gmail.com Fri Apr 3 01:44:05 2015 From: asqueaker at gmail.com (Chris Muller) Date: Fri Apr 3 01:44:08 2015 Subject: [squeak-dev] The Trunk: EToys-topa.121.mcz In-Reply-To: <9A063FEB-616A-4158-8FBD-C1EDB524ECA2@gmx.de> References: <9A063FEB-616A-4158-8FBD-C1EDB524ECA2@gmx.de> Message-ID: >>>>>> I prefer to use Symbols instead of Strings for class names, because they make it easier to find potential users of the class. >>>> >>>> +1 >>>> >>>>> yes, but #hasClassNamed: is a String protocol. >>>> >>>> A Symbol is a String. Many (if not all) existing users of >>>> hasClassNamed: pass Symbols (a special kind of String). >>> >>> I don't want to rely on that. >>> Symbols being Strings is an implementation detail. >> >> Symbols logically ARE Strings, regardless of implementation. They're >> a series of characters just canonicalized. Its only the >> canonicalization that's implementation-specific, not equality or type >> testing.. > > Nope. The idea of a symbol is (IMHO, admittedly) broader than > just canonicalized Strings. If it where, I would call it InternedString > or CanonicalizedString. Symbols are unique human readable identifiers. > > See Prolog, where the concept is called Atoms. There is no conceptual > differences. Yet, Prolog atoms do not remotely compare to interned strings. I may be missing your point -- Prolog and Gemstone and Ruby and Lisp all have different semantics for many types not just Symbols. If you want to try to match an ethereal notion of some Squeak types to other languages, TileMorphTest is not quite the best place to start is it? ;-) Such a daunting mission would need to be thought out and planned at a system-wide level.. In the meantime, what about consistency of the code within the image? And about Levente's point about tool support? >>> Looking at the broader picture, in GemStone, in fact >>> a Symbol is not a String. >> >> Object name "#Object" <---- a Symbol. >> >> So why do you say #hasClassNamed: a "String protocol" instead of a >> "Symbol protocol"? > > See #classOrTraitNamed: (which is called by #classNamed:) > > classOrTraitNamed: aString > "aString is either a class or trait name or a class or trait name followed by ' class' or 'classTrait' respectively. > Answer the class or metaclass it names." > > and > > hasClassNamed: aString > "Answer whether there is a class of the given name, but don't intern aString if it's not alrady interned. 4/29/96 sw" Class #name's are Squeak Symbol's, which are just as capable of (and, responsible for) naming something as a String is. The API's above support Strings for *convenience* (in case you got it from a file or something, so you don't have to send #asSymbol first). When you create a new class, you use a Symbol to define the #name, don't you? Object subclass: #MyObject instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'MyApp' Why would Smalltalk be designed to use Symbols for the class 'creating' API and Strings for its accessing API? It makes no sense and renders the tools impotent. You are brilliant Tobias but I think we don't understand your reasoning this time.. From asqueaker at gmail.com Fri Apr 3 02:40:07 2015 From: asqueaker at gmail.com (Chris Muller) Date: Fri Apr 3 02:40:09 2015 Subject: [squeak-dev] Re: bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: Message-ID: On Thu, Apr 2, 2015 at 7:05 PM, Eliot Miranda wrote: > You know, we're supposed to be trying to get Squeak 4.5 and Squeak 5 > released and instead there's a sudden slew of major UI changes. This really > doesn't help. How long are these UI changes going to continue? Surely the > right time for this kind of innovation is early in the release cycle. Yes, earlier is always better for everything. Don't worry, we can resolve this with a preference if we need to. However we have a wave of exquisite-talent energy flowing in at the moment. Can we keep going just bit longer? With the exception of my own few commit bungles, the quality of the contributions has, IMO, been very good. This wave coincided with the 4/30 release target date announcement. These are image-level things that will set 4.6 apart from 4.5, so we can think of it as "release work". At this point in the release cycle trying our best with quality is paramount. When this wave dies down, we'll know we're ready. Then we'll all hammer on a release-candidate, figure out our look and preferences, strip and clean (including changes file this time) and then All-In-One it. From tim at rowledge.org Fri Apr 3 02:51:05 2015 From: tim at rowledge.org (tim Rowledge) Date: Fri Apr 3 02:51:11 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: Message-ID: I notice that - at least on my iMac, in Mail - using a right-click in the list of messages opens a menu that treats the item under the pointer as the selected item. And after making any choice from the menu it appears to actually change the selection, whether the choice refers specifically to an item or just the list. Indeed, it changes the selection if you move away from the menu to make no choice. I think that?s rather annoying now that I?ve noticed it. It?s treating the right click as a select-then-menu but presenting it visually inconsistent with that action. Not smart. tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim dilate - live long From marcel.taeumel at student.hpi.uni-potsdam.de Fri Apr 3 06:34:27 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Fri Apr 3 06:46:19 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.806.mcz In-Reply-To: References: Message-ID: <1428042867211-4817126.post@n4.nabble.com> This should not happen. Let me try... Looks fine in my image. Is this an *old* tool? Try open a new Monticello browser. Do we want a migration script for this change? Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-806-mcz-tp4816830p4817126.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Fri Apr 3 06:37:00 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Fri Apr 3 06:48:53 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.806.mcz In-Reply-To: <1428042867211-4817126.post@n4.nabble.com> References: <1428042867211-4817126.post@n4.nabble.com> Message-ID: <1428043020040-4817127.post@n4.nabble.com> Let me clarify: This change affects initialization code in ScrollPane and PluggableTextMorph. Only in LazyListMorph, this is lazy in its drawing routine. This explains your observation. Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-806-mcz-tp4816830p4817127.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Fri Apr 3 06:39:41 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Fri Apr 3 06:51:34 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.810.mcz In-Reply-To: References: Message-ID: <1428043181035-4817128.post@n4.nabble.com> Well, it is now consistent with how inspectors are openend via the halo. ;) I find this quite convenient because the RealEstateManager places new windows in a strange way and I always have to look for them on my 27" monitor. :D I guess, we can have both reuse-windows and open-in-hand. Let me look into it. Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-810-mcz-tp4816858p4817128.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Fri Apr 3 06:44:48 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Fri Apr 3 06:56:41 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.810.mcz In-Reply-To: <1428043181035-4817128.post@n4.nabble.com> References: <1428043181035-4817128.post@n4.nabble.com> Message-ID: <1428043488973-4817129.post@n4.nabble.com> I double-checked and "Reuse windows" is - at the moment - broken for: - the main search bar - inspecting a morph via its halo - exploring a morph via its halo Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-810-mcz-tp4816858p4817129.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Fri Apr 3 06:53:25 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Fri Apr 3 07:05:18 2015 Subject: [squeak-dev] Re: bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: Message-ID: <1428044005053-4817131.post@n4.nabble.com> I guess that I changed that because it started to annoy me recently as I highlighted the hovered item in lists and played around with providing item-specific balloon texts. No additional click needed there. Providing a context menu for the current selection without honoring the mouse position poses kind of a gap and -- imho -- makes an interface harder to use. But for the sake of backwards compatibility, I will make it a preference. We should also think about letting the model decide and giving it the clicked item instead of just requesting a menu for some click. Best, Marcel -- View this message in context: http://forum.world.st/bad-UI-bug-introduced-with-recent-list-highlightiong-changes-tp4817074p4817131.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Fri Apr 3 07:12:58 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 07:13:00 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.813.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.813.mcz ==================== Summary ==================== Name: Morphic-mt.813 Author: mt Time: 3 April 2015, 9:12:20.355 am UUID: 539e0985-e659-1743-b998-928c707d759d Ancestors: Morphic-mt.812 Added preference for updating the current selection on option/menu click to compensate misplaced mouse cursors. =============== Diff against Morphic-mt.812 =============== Item was changed: ScrollPane subclass: #PluggableListMorph instanceVariableNames: 'list getListSelector getListSizeSelector getListElementSelector getIndexSelector setIndexSelector keystrokeActionSelector autoDeselect lastKeystrokeTime lastKeystrokes lastClickTime doubleClickSelector handlesBasicKeys potentialDropRow hoverRow listMorph hScrollRangeCache keystrokePreviewSelector priorSelection getIconSelector' + classVariableNames: 'ClearFilterAutomatically FilterableLists HighlightHoveredRow MenuRequestUpdatesSelection' - classVariableNames: 'ClearFilterAutomatically FilterableLists HighlightHoveredRow' poolDictionaries: '' category: 'Morphic-Pluggable Widgets'! !PluggableListMorph commentStamp: 'cmm 8/21/2011 23:37' prior: 0! When a PluggableListMorph is in focus, type in a letter (or several letters quickly) to go to the next item that begins with that letter (if FilterableLists is false). Special keys (up, down, home, etc.) are also supported.! Item was added: + ----- Method: PluggableListMorph class>>menuRequestUpdatesSelection (in category 'preferences') ----- + menuRequestUpdatesSelection + + + ^ MenuRequestUpdatesSelection ifNil: [ false ]! Item was added: + ----- Method: PluggableListMorph class>>menuRequestUpdatesSelection: (in category 'preferences') ----- + menuRequestUpdatesSelection: aBoolean + + MenuRequestUpdatesSelection := aBoolean.! Item was changed: ----- Method: PluggableListMorph>>mouseDown: (in category 'events') ----- mouseDown: evt | selectors row | row := self rowAtLocation: evt position. evt yellowButtonPressed "First check for option (menu) click" ifTrue: [ + self class menuRequestUpdatesSelection ifTrue: [ + "Models depend on the correct selection:" + self selectionIndex = (self modelIndexFor: row) + ifFalse: [self changeModelSelection: (self modelIndexFor: row)]]. + - "Models depend on the correct selection:" - self selectionIndex = (self modelIndexFor: row) - ifFalse: [self changeModelSelection: (self modelIndexFor: row)]. - ^ self yellowButtonActivity: evt shiftPressed]. row = 0 ifTrue: [^super mouseDown: evt]. "self dragEnabled ifTrue: [aMorph highlightForMouseDown]." selectors := Array with: #click: with: (doubleClickSelector ifNotNil:[#doubleClick:]) with: nil with: (self dragEnabled ifTrue:[#startDrag:] ifFalse:[nil]). evt hand waitForClicksOrDrag: self event: evt selectors: selectors threshold: HandMorph dragThreshold "pixels".! Item was changed: ----- Method: SimpleHierarchicalListMorph>>mouseDown: (in category 'event handling') ----- mouseDown: evt | aMorph selectors | aMorph := self itemFromPoint: evt position. evt yellowButtonPressed "First check for option (menu) click" ifTrue: [ + PluggableListMorph menuRequestUpdatesSelection ifTrue: [ + aMorph == selectedMorph + ifFalse: [self setSelectedMorph: aMorph]]. - aMorph == selectedMorph - ifFalse: [self setSelectedMorph: aMorph]. ^ self yellowButtonActivity: evt shiftPressed]. (aMorph notNil and:[aMorph inToggleArea: (aMorph point: evt position from: self)]) ifTrue:[^self toggleExpandedState: aMorph event: evt]. aMorph ifNil:[^super mouseDown: evt]. aMorph highlightForMouseDown. selectors := Array with: #click: with: nil with: nil with: (self dragEnabled ifTrue:[#startDrag:] ifFalse:[nil]). evt hand waitForClicksOrDrag: self event: evt selectors: selectors threshold: HandMorph dragThreshold "pixels".! From commits at source.squeak.org Fri Apr 3 07:17:57 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 07:17:58 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.814.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.814.mcz ==================== Summary ==================== Name: Morphic-mt.814 Author: mt Time: 3 April 2015, 9:17:18.474 am UUID: 51d4bcce-e73b-174d-a661-68f0d73c6183 Ancestors: Morphic-mt.813 Fixed hovered-row state in lists when losing keyboard focus, e.g., when invoking a context menu. Otherwise this may be confusing if the current selection is not updated but the hovered row still indicated. =============== Diff against Morphic-mt.813 =============== Item was changed: ----- Method: PluggableListMorph>>keyboardFocusChange: (in category 'event handling') ----- keyboardFocusChange: aBoolean "The message is sent to a morph when its keyboard focus changes. The given argument indicates that the receiver is gaining (versus losing) the keyboard focus. In this case, all we need to do is to redraw border feedback" + aBoolean ifFalse: [ + self hoverRow: nil. + self class clearFilterAutomatically ifTrue: - aBoolean ifFalse: - [ self class clearFilterAutomatically ifTrue: [ self hasFilter ifTrue: [ self removeFilter ; updateList ] ] ]. (self innerBounds areasOutside: (self innerBounds insetBy: 1)) do: [ : rect | self invalidRect: rect ]! From marcel.taeumel at student.hpi.uni-potsdam.de Fri Apr 3 07:06:59 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Fri Apr 3 07:18:51 2015 Subject: [squeak-dev] Re: bad UI bug introduced with recent list highlightiong changes. In-Reply-To: <1428044005053-4817131.post@n4.nabble.com> References: <1428044005053-4817131.post@n4.nabble.com> Message-ID: <1428044819316-4817135.post@n4.nabble.com> Preference added: http://forum.world.st/The-Trunk-Morphic-mt-813-mcz-td4817132.html It's disabled by default. ;-) Best, Marcel -- View this message in context: http://forum.world.st/bad-UI-bug-introduced-with-recent-list-highlightiong-changes-tp4817074p4817135.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Fri Apr 3 07:58:37 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 07:58:40 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.815.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.815.mcz ==================== Summary ==================== Name: Morphic-mt.815 Author: mt Time: 3 April 2015, 9:58:00.396 am UUID: 61ffa1cf-734e-2a40-a419-6cbd4e4bfefe Ancestors: Morphic-mt.814 Fixed open-in-world behavior for system windows to return the opened window if the reuse-windows preference changed that. =============== Diff against Morphic-mt.814 =============== Item was changed: ----- Method: SystemWindow>>openInWorld: (in category 'open/close') ----- openInWorld: aWorld "This msg and its callees result in the window being activeOnlyOnTop" + [^ self anyOpenWindowLikeMe - self anyOpenWindowLikeMe ifEmpty: [ self bounds: (RealEstateAgent initialFrameFor: self world: aWorld) ; openAsIsIn: aWorld ] ifNotEmptyDo: [ : windows | windows anyOne expand ; activate ; postAcceptBrowseFor: self ]. + ] ensure: [ self activeHand releaseAllFoci ]! - self activeHand releaseAllFoci! Item was changed: ----- Method: SystemWindow>>openInWorld:extent: (in category 'open/close') ----- openInWorld: aWorld extent: extent "This msg and its callees result in the window being activeOnlyOnTop" + [^ self anyOpenWindowLikeMe - ^ self anyOpenWindowLikeMe ifEmpty: [ self position: (RealEstateAgent initialFrameFor: self initialExtent: extent world: aWorld) topLeft ; extent: extent. self openAsIsIn: aWorld ] ifNotEmptyDo: [ : windows | windows anyOne expand ; activate ; + postAcceptBrowseFor: self ]. + ] ensure: [ self activeHand releaseAllFoci ]! - postAcceptBrowseFor: self ]! Item was changed: ----- Method: SystemWindow>>openInWorldExtent: (in category 'open/close') ----- openInWorldExtent: extent "This msg and its callees result in the window being activeOnlyOnTop" + ^ self openInWorld: self currentWorld extent: extent! - self openInWorld: self currentWorld extent: extent! From marcel.taeumel at student.hpi.uni-potsdam.de Fri Apr 3 07:48:47 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Fri Apr 3 08:00:42 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.810.mcz In-Reply-To: <1428043488973-4817129.post@n4.nabble.com> References: <1428043181035-4817128.post@n4.nabble.com> <1428043488973-4817129.post@n4.nabble.com> Message-ID: <1428047327670-4817142.post@n4.nabble.com> Fixed something here: http://forum.world.st/The-Trunk-Morphic-mt-815-mcz-td4817141.html Now, we should think about letting Browser honor this preference, too. The Search Bar opens regular browsers, not hierarchy browsers. Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-810-mcz-tp4816858p4817142.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From nicolas.cellier.aka.nice at gmail.com Fri Apr 3 09:32:40 2015 From: nicolas.cellier.aka.nice at gmail.com (Nicolas Cellier) Date: Fri Apr 3 09:32:44 2015 Subject: [squeak-dev] Re: bad UI bug introduced with recent list highlightiong changes. In-Reply-To: <1428044819316-4817135.post@n4.nabble.com> References: <1428044005053-4817131.post@n4.nabble.com> <1428044819316-4817135.post@n4.nabble.com> Message-ID: 2015-04-03 9:06 GMT+02:00 Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de>: > Preference added: > http://forum.world.st/The-Trunk-Morphic-mt-813-mcz-td4817132.html > > It's disabled by default. ;-) > > Best, > Marcel > > > You rock :) > > -- > View this message in context: > http://forum.world.st/bad-UI-bug-introduced-with-recent-list-highlightiong-changes-tp4817074p4817135.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150403/e494f33d/attachment.htm From Das.Linux at gmx.de Fri Apr 3 11:20:19 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Fri Apr 3 11:20:29 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: Message-ID: <935E815A-2D71-4488-85E8-34DB6BCA2049@gmx.de> Hi Eliot On 03.04.2015, at 01:36, Eliot Miranda wrote: > On Thu, Apr 2, 2015 at 3:56 PM, Tobias Pape wrote: > > On 03.04.2015, at 00:43, Eliot Miranda wrote: > > > Hi All, > > > > since the hover highlight changes, where the list element under the mouse that would be selected if one clicks is highlighted in light blue appears to have caused a bad bug. If one does a right-button clock to bring up a menu the system can end up selecting the item under the mouse before putting up the menu. This is *wrong*. The mouse click to bring up a menu should /not/ change the selection. > > The rightclick must change the selection, at > least _temporarily_ to highlight for what item the menu is constructed. > > The menu is constructed for *the selected item*, not for the item under the mouse click. Try this. Run the debugger on a large class. In the instance variables list type some chaacter to select inst vars beginning with that name, then select one, then try and issue a right-click to explore the selected inst var. Poof, the filtered inst vars disappear, to be replaced by all inst vars, and then explore applies to some completely unintended selection that isn't even in the list one thought one was selecting from. > I thought about what you described there once again, and just to report my experience, this scenario is the exact time I use the #menuButtonInToolPane preference. When I have an out-of-sight element I want a menu for (or no selection at all), I find it really convenient to have this little button above the scroll bar. Also, it is explicit: when I click on this menu thing, I don't point at something else but the "I want a menu now" button. HTH Best -Tobias > Please, please, please fix this quickly. The system is /very/ difficult for me to use right now. > > > Else, we need a kind-of ?second selection? > > No we don't. Issuing a red button/left button click changes selections. Issuing *other* mouse button clicks *should not*. Right? It's simple. Right? > > Best > -Tobias -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 1625 bytes Desc: Message signed with OpenPGP using GPGMail Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150403/c16ae88e/signature.pgp From commits at source.squeak.org Fri Apr 3 15:02:13 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 15:02:17 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.117.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.117.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.117 Author: mt Time: 3 April 2015, 5:02:08.392 pm UUID: 8f97b85b-0612-5e45-96e8-a98064d77946 Ancestors: ToolBuilder-Morphic-mt.116 The morphic tool builder now honors the reuse-windows preference because #open: will now return the actually opened window. =============== Diff against ToolBuilder-Morphic-mt.116 =============== Item was changed: ----- Method: MorphicToolBuilder>>open: (in category 'opening') ----- open: anObject "Build and open the object. Answer the widget opened." | morph | anObject isMorph ifTrue:[morph := anObject] ifFalse:[morph := self build: anObject]. (morph isKindOf: MenuMorph) ifTrue:[morph popUpInWorld: World]. (morph isKindOf: SystemWindow) + ifTrue:[morph := morph openInWorldExtent: morph extent] - ifTrue:[morph openInWorldExtent: morph extent] ifFalse:[morph openInWorld]. ^morph! From marcel.taeumel at student.hpi.uni-potsdam.de Fri Apr 3 14:51:31 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Fri Apr 3 15:03:26 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.810.mcz In-Reply-To: <1428047327670-4817142.post@n4.nabble.com> References: <1428043181035-4817128.post@n4.nabble.com> <1428043488973-4817129.post@n4.nabble.com> <1428047327670-4817142.post@n4.nabble.com> Message-ID: <1428072691040-4817329.post@n4.nabble.com> Oh my.... I forgot to commit this: http://forum.world.st/The-Trunk-ToolBuilder-Morphic-mt-117-mcz-td4817328.html Now it should work. :-) Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-810-mcz-tp4816858p4817329.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Fri Apr 3 15:08:17 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 15:08:19 2015 Subject: [squeak-dev] The Trunk: System-mt.716.mcz Message-ID: Marcel Taeumel uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System-mt.716.mcz ==================== Summary ==================== Name: System-mt.716 Author: mt Time: 3 April 2015, 5:07:50.544 pm UUID: 5739fe6f-df77-bb41-8dcc-1ff566ff6848 Ancestors: System-topa.715 Refactored window color handling. Added a #normalColor to the specs because I will remove the #duller-hack from SystemWindow and this ensures that users will not be overwhelmed by bright colors. =============== Diff against System-topa.715 =============== Item was changed: ----- Method: Object class>>windowColorSpecification (in category '*System-Support-window color') ----- windowColorSpecification "Answer a WindowColorSpec object that declares my preference. This is a backstop for classes that don't otherwise define a preference." ^ WindowColorSpec classSymbol: self name + wording: 'Default' brightColor: #veryVeryLightGray + pastelColor: #veryVeryLightGray + normalColor: #veryVeryLightGray - wording: 'Default' brightColor: #white - pastelColor: #white helpMessage: 'Other windows without color preferences.'! Item was removed: - ----- Method: Preferences class>>installMissingWindowColors (in category 'window colors') ----- - installMissingWindowColors - "Install the factory-provided bright window colors -- a one-time bootstrap" - "Preferences installMissingWindowColors" - - self windowColorTable do: - [:aColorSpec | | color | - color := (Color colorFrom: aColorSpec brightColor). - self setWindowColorFor: aColorSpec classSymbol to: color]! Item was added: + ----- Method: Preferences class>>installNormalWindowColors (in category 'window colors') ----- + installNormalWindowColors + "Install the factory-provided default window colors for all tools" + + "Preferences installNormalWindowColors" + + self installWindowColorsVia: [:aSpec | aSpec normalColor]! Item was changed: ----- Method: Preferences class>>windowColorFor: (in category 'window colors') ----- windowColorFor: aModelClassName | classToCheck prefSymbol | self checkForWindowColors. classToCheck := Smalltalk at: aModelClassName. prefSymbol := self windowColorPreferenceForClassNamed: classToCheck name. [(classToCheck ~~ Object) and: [(self preferenceAt: prefSymbol) isNil]] whileTrue: [classToCheck := classToCheck superclass. prefSymbol := self windowColorPreferenceForClassNamed: classToCheck name]. + ^self valueOfPreference: prefSymbol ifAbsent: [self uniformWindowColor].! - ^self valueOfPreference: prefSymbol ifAbsent: [Color white].! Item was changed: Object subclass: #WindowColorSpec + instanceVariableNames: 'classSymbol wording brightColor pastelColor normalColor helpMessage' - instanceVariableNames: 'classSymbol wording brightColor pastelColor helpMessage' classVariableNames: '' poolDictionaries: '' category: 'System-Support'! Item was added: + ----- Method: WindowColorSpec class>>classSymbol:wording:brightColor:pastelColor:normalColor:helpMessage: (in category 'instance creation') ----- + classSymbol: sym wording: wrd brightColor: brCol pastelColor: paCol normalColor: noCol helpMessage: hlpMsg + + ^ self new classSymbol: sym wording: wrd brightColor: brCol pastelColor: paCol normalColor: noCol helpMessage: hlpMsg! Item was changed: ----- Method: WindowColorSpec>>classSymbol:wording:brightColor:pastelColor:helpMessage: (in category 'initialization') ----- classSymbol: sym wording: wrd brightColor: brCol pastelColor: paCol helpMessage: hlpMsg "Initialize the receiver's instance variables" + self + classSymbol: sym + wording: wrd + brightColor: brCol + pastelColor: paCol + normalColor: (Color colorFrom: brCol) duller + helpMessage: hlpMsg! - classSymbol := sym. - wording := wrd. - brightColor := brCol. - pastelColor := paCol. - helpMessage := hlpMsg! Item was added: + ----- Method: WindowColorSpec>>classSymbol:wording:brightColor:pastelColor:normalColor:helpMessage: (in category 'initialization') ----- + classSymbol: sym wording: wrd brightColor: brCol pastelColor: paCol normalColor: noCol helpMessage: hlpMsg + "Initialize the receiver's instance variables" + + classSymbol := sym. + wording := wrd. + brightColor := brCol. + pastelColor := paCol. + normalColor := noCol. + helpMessage := hlpMsg! Item was added: + ----- Method: WindowColorSpec>>normalColor (in category 'access') ----- + normalColor + + ^ normalColor! Item was changed: ----- Method: WindowColorSpec>>printOn: (in category 'printing') ----- printOn: aStream "Print the receiver on a stream" super printOn: aStream. classSymbol printOn: aStream. + aStream nextPutAll: ' bright: ', brightColor printString, ' pastel: ', pastelColor printString, ' normal: ', normalColor printString! - aStream nextPutAll: ' bright: ', brightColor printString, ' pastel: ', pastelColor printString! From eliot.miranda at gmail.com Fri Apr 3 15:09:34 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Fri Apr 3 15:09:39 2015 Subject: [squeak-dev] Re: bad UI bug introduced with recent list highlightiong changes. In-Reply-To: <1428044005053-4817131.post@n4.nabble.com> References: <1428044005053-4817131.post@n4.nabble.com> Message-ID: <0625119E-551D-411A-BBF5-4FD492D3E982@gmail.com> Hi Marcel, thank you!! It is very Turing to reposition the mouse to get it over the right selection when one has learned the other stile over the last 8 years. It bring a preference is the only way I can see of making the system usable for existing users. I guess my insistence on the preference to default to the old behaviour is too strong. I'd be happy if I could set the preference. So ignore that part. I was annoyed and frustrated when I wrote that ;-) Eliot (phone) On Apr 2, 2015, at 11:53 PM, Marcel Taeumel wrote: > I guess that I changed that because it started to annoy me recently as I > highlighted the hovered item in lists and played around with providing > item-specific balloon texts. No additional click needed there. > > Providing a context menu for the current selection without honoring the > mouse position poses kind of a gap and -- imho -- makes an interface harder > to use. > > But for the sake of backwards compatibility, I will make it a preference. We > should also think about letting the model decide and giving it the clicked > item instead of just requesting a menu for some click. > > Best, > Marcel > > > > -- > View this message in context: http://forum.world.st/bad-UI-bug-introduced-with-recent-list-highlightiong-changes-tp4817074p4817131.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > From commits at source.squeak.org Fri Apr 3 15:10:45 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 15:10:47 2015 Subject: [squeak-dev] The Trunk: Tools-mt.577.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.577.mcz ==================== Summary ==================== Name: Tools-mt.577 Author: mt Time: 3 April 2015, 5:10:17.726 pm UUID: 5d064a68-b9b6-4d42-b50b-fe1f677c6ba5 Ancestors: Tools-mt.576 Updated to load normal window colors for new tool sets as introduced by System-mt.716 =============== Diff against Tools-mt.576 =============== Item was changed: ----- Method: StandardToolSet class>>initialize (in category 'class initialization') ----- initialize ToolSet register: self. + Preferences installNormalWindowColors.! - Preferences installMissingWindowColors.! From eliot.miranda at gmail.com Fri Apr 3 15:12:13 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Fri Apr 3 15:12:53 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: <935E815A-2D71-4488-85E8-34DB6BCA2049@gmx.de> References: <935E815A-2D71-4488-85E8-34DB6BCA2049@gmx.de> Message-ID: <4D9C813F-68C5-43D4-9444-319D3A465C40@gmail.com> Hi Tobias, On Apr 3, 2015, at 4:20 AM, Tobias Pape wrote: > Hi Eliot > > On 03.04.2015, at 01:36, Eliot Miranda wrote: > >> On Thu, Apr 2, 2015 at 3:56 PM, Tobias Pape wrote: >> >> On 03.04.2015, at 00:43, Eliot Miranda wrote: >> >>> Hi All, >>> >>> since the hover highlight changes, where the list element under the mouse that would be selected if one clicks is highlighted in light blue appears to have caused a bad bug. If one does a right-button clock to bring up a menu the system can end up selecting the item under the mouse before putting up the menu. This is *wrong*. The mouse click to bring up a menu should /not/ change the selection. >> >> The rightclick must change the selection, at >> least _temporarily_ to highlight for what item the menu is constructed. >> >> The menu is constructed for *the selected item*, not for the item under the mouse click. Try this. Run the debugger on a large class. In the instance variables list type some chaacter to select inst vars beginning with that name, then select one, then try and issue a right-click to explore the selected inst var. Poof, the filtered inst vars disappear, to be replaced by all inst vars, and then explore applies to some completely unintended selection that isn't even in the list one thought one was selecting from. > > I thought about what you described there once again, and just to report my experience, > this scenario is the exact time I use the #menuButtonInToolPane preference. When I have > an out-of-sight element I want a menu for (or no selection at all), I find it really convenient > to have this little button above the scroll bar. Also, it is explicit: when I click on > this menu thing, I don't point at something else but the "I want a menu now" button. That makes sense and one could soon learn to use that effectively. But if still means a mouse move before issuing the menu click, and I suspect I'll still find that tiring. Sorry for shouting when I raised this thread. > > HTH > Best > -Tobias > >> Please, please, please fix this quickly. The system is /very/ difficult for me to use right now. >> >> >> Else, we need a kind-of ?second selection? >> >> No we don't. Issuing a red button/left button click changes selections. Issuing *other* mouse button clicks *should not*. Right? It's simple. Right? >> >> Best >> -Tobias > > > > From commits at source.squeak.org Fri Apr 3 15:15:24 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 15:15:25 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.816.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.816.mcz ==================== Summary ==================== Name: Morphic-mt.816 Author: mt Time: 3 April 2015, 5:14:40.868 pm UUID: c018e1dd-f91a-be40-b8ec-79da02e93bb2 Ancestors: Morphic-mt.815 Removed #duller-hack from SystemWindow and thus extended main docking bar to offer "normal window colors", which are the old bright ones but duller. Please use the "Extras -> Window Colors"-menu if this update messes up your colors, i.e., makes them too bright. Note: The small icons in the Tools menu may now also appear darker than usual, which is correct, because they represent the actual window color. =============== Diff against Morphic-mt.815 =============== Item was changed: + ----- Method: SystemWindow>>paneColor (in category 'colors') ----- - ----- Method: SystemWindow>>paneColor (in category 'panes') ----- paneColor | cc | (cc := self valueOfProperty: #paneColor) ifNotNil: [^cc]. Display depth > 2 ifTrue: [model ifNotNil: [model isInMemory ifTrue: + [cc := Color colorFrom: model defaultBackgroundColor]]. - [cc := Color colorFrom: model defaultBackgroundColor. - cc := (cc = Color lightYellow or: [cc = Color white]) - ifTrue: [Color gray: 0.67] - ifFalse: [cc duller]]]. cc ifNil: [cc := paneMorphs isEmptyOrNil ifFalse: [paneMorphs first color]]]. cc ifNil: [cc := self defaultBackgroundColor]. self paneColor: cc. ^cc! Item was changed: ----- Method: TheWorldMainDockingBar>>windowColorsOn: (in category 'construction') ----- windowColorsOn: menu menu addItem:[:item| item + contents: 'Gray Windows' translated; - contents: 'Uniform Windows' translated; help: 'Use uniform window colors' translated; target: Preferences; selector: #installUniformWindowColors]. menu addItem:[:item| item contents: 'Colorful Windows' translated; + help: 'Use normal window colors' translated; + target: Preferences; + selector: #installNormalWindowColors]. + + menu addLine. + + menu addItem:[:item| + item + contents: 'Bright-colored Windows' translated; help: 'Use bright window colors' translated; target: Preferences; selector: #installBrightWindowColors]. + + menu addItem:[:item| + item + contents: 'Pastel-colored Windows' translated; + help: 'Use pastel window colors' translated; + target: Preferences; + selector: #installPastelWindowColors]. ! From Das.Linux at gmx.de Fri Apr 3 15:24:31 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Fri Apr 3 15:24:36 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: <4D9C813F-68C5-43D4-9444-319D3A465C40@gmail.com> References: <935E815A-2D71-4488-85E8-34DB6BCA2049@gmx.de> <4D9C813F-68C5-43D4-9444-319D3A465C40@gmail.com> Message-ID: <49A1BF8B-B2BA-4BD9-9AE2-4E1C9B88366C@gmx.de> On 03.04.2015, at 17:12, Eliot Miranda wrote: > Hi Tobias, > > > On Apr 3, 2015, at 4:20 AM, Tobias Pape wrote: > >> Hi Eliot >> >> On 03.04.2015, at 01:36, Eliot Miranda wrote: >> >>> On Thu, Apr 2, 2015 at 3:56 PM, Tobias Pape wrote: >>> >>> On 03.04.2015, at 00:43, Eliot Miranda wrote: >>> >>>> Hi All, >>>> >>>> since the hover highlight changes, where the list element under the mouse that would be selected if one clicks is highlighted in light blue appears to have caused a bad bug. If one does a right-button clock to bring up a menu the system can end up selecting the item under the mouse before putting up the menu. This is *wrong*. The mouse click to bring up a menu should /not/ change the selection. >>> >>> The rightclick must change the selection, at >>> least _temporarily_ to highlight for what item the menu is constructed. >>> >>> The menu is constructed for *the selected item*, not for the item under the mouse click. Try this. Run the debugger on a large class. In the instance variables list type some chaacter to select inst vars beginning with that name, then select one, then try and issue a right-click to explore the selected inst var. Poof, the filtered inst vars disappear, to be replaced by all inst vars, and then explore applies to some completely unintended selection that isn't even in the list one thought one was selecting from. >> >> I thought about what you described there once again, and just to report my experience, >> this scenario is the exact time I use the #menuButtonInToolPane preference. When I have >> an out-of-sight element I want a menu for (or no selection at all), I find it really convenient >> to have this little button above the scroll bar. Also, it is explicit: when I click on >> this menu thing, I don't point at something else but the "I want a menu now" button. > > That makes sense and one could soon learn to use that effectively. But if still means a mouse move before issuing the menu click, and I suspect I'll still find that tiring. > > Sorry for shouting when I raised this thread. > Emotions are fine sometimes :) Best -Tobias >> >> HTH >> Best >> -Tobias >> >>> Please, please, please fix this quickly. The system is /very/ difficult for me to use right now. >>> >>> >>> Else, we need a kind-of ?second selection? >>> >>> No we don't. Issuing a red button/left button click changes selections. Issuing *other* mouse button clicks *should not*. Right? It's simple. Right? >>> >>> Best >>> -Tobias From leves at elte.hu Fri Apr 3 15:25:45 2015 From: leves at elte.hu (Levente Uzonyi) Date: Fri Apr 3 15:25:51 2015 Subject: [squeak-dev] The Trunk: EToys-topa.121.mcz In-Reply-To: References: Message-ID: On Fri, 3 Apr 2015, Tobias Pape wrote: > > On 03.04.2015, at 01:00, Chris Muller wrote: > >> On Thu, Apr 2, 2015 at 5:52 PM, Tobias Pape wrote: >>> Hi, >>> >>> On 03.04.2015, at 00:32, Levente Uzonyi wrote: >>> >>>> I prefer to use Symbols instead of Strings for class names, because they make it easier to find potential users of the class. >> >> +1 >> >>> yes, but #hasClassNamed: is a String protocol. >> >> A Symbol is a String. Many (if not all) existing users of >> hasClassNamed: pass Symbols (a special kind of String). > > I don't want to rely on that. > Symbols being Strings is an implementation detail. > Looking at the broader picture, in GemStone, in fact > a Symbol is not a String. This code is not intended to be portable to other dialects, so IMHO it's fine to use Symbols as Strings. If we ever decide to make Symbols to not be Strings anymore, then we'll have to scan the image (and external packages) anyway. Levente > > Best > -Tobias > From Das.Linux at gmx.de Fri Apr 3 15:27:24 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Fri Apr 3 15:27:28 2015 Subject: [squeak-dev] Can we get Squeak green for the release? Message-ID: Hey I am watching the CI doing its work as changes and fixes chime in. I noticed that there are still 13 test failing[1] and I'm not sure how all of them should be fixed :) Let's make it green! Best -Tobias [1] http://build.squeak.org/job/SqueakTrunk/lastCompletedBuild/testReport/ From eliot.miranda at gmail.com Fri Apr 3 15:31:15 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Fri Apr 3 15:36:28 2015 Subject: [squeak-dev] A plan for the release Message-ID: Hi Tobias, Hi Marcel, I want to each Chris' praise. I'm loving the energy you're putting in right now. But we do want to release soon. Can you both talk about when you are going to stabilize? Do you have specific features in mind, in which case what are they and what's a time estimate for their completion? Otherwise can you suggest a date? Eliot (phone) From marcel.taeumel at student.hpi.uni-potsdam.de Fri Apr 3 15:34:30 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Fri Apr 3 15:46:26 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: References: Message-ID: <1428075270847-4817347.post@n4.nabble.com> Hi Eliot, right now, I am working only on the HelpBrowser (~1-2 weeks left), doing some code clean-up and also some bug fixing -- including ui bugs. ;-) No bigger change (major changes to standard tools or new tools) planned from my side. As for the stability, my observation is that we are getting more stable with every update. But what about new packages for this release: - SqueakSSL - WebClient Any ideas on that? Best, Marcel -- View this message in context: http://forum.world.st/A-plan-for-the-release-tp4817346p4817347.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Fri Apr 3 16:32:13 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 16:32:15 2015 Subject: [squeak-dev] The Trunk: System.spur-mt.716.mcz Message-ID: Eliot Miranda uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System.spur-mt.716.mcz ==================== Summary ==================== Name: System.spur-mt.716 Author: eem Time: 3 April 2015, 9:31:22.836 am UUID: 03874c0e-4393-4296-8153-fa0508d95d10 Ancestors: System-mt.716, System.spur-topa.715 System-mt.716 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.256 Refactored window color handling. Added a #normalColor to the specs because I will remove the #duller-hack from SystemWindow and this ensures that users will not be overwhelmed by bright colors. =============== Diff against System-mt.716 =============== Item was removed: - ----- Method: Object>>oopAge (in category '*system-support') ----- - oopAge - ^ ObjectHistory current ageOf: self! Item was removed: - ----- Method: Object>>oopTimestamp (in category '*system-support') ----- - oopTimestamp - ^ ObjectHistory current timestampOf: self! Item was removed: - Object subclass: #ObjectHistory - instanceVariableNames: 'marks markProcess' - classVariableNames: 'Current' - poolDictionaries: '' - category: 'System-Support'! - - !ObjectHistory commentStamp: 'bf 11/16/2012 12:19' prior: 0! - ObjectHistory holds ObjectHistoryMark objects which are placed in the object memory at regular intervals by its markProcess in the background. Adjacent marks (with no remaining objects inbetween) are coalesced so over time the collection does not grow unnecessarily large. - - Using these markers it is possible to determine the age of objects in memory from the time the ObjectHistory was initialized. Try e.g.: - self oopTimestamp. - self oopAge. - ObjectHistory current oopClassesByDate. - - Instance Variables - marks: SortedCollection of ObjectHistoryMark objects - markProcess: a Process running our markLoop - ! Item was removed: - ----- Method: ObjectHistory class>>current (in category 'accessing') ----- - current - ^ Current ifNil: [Current := self new]! Item was removed: - ----- Method: ObjectHistory class>>initialize (in category 'class initialization') ----- - initialize - self current. - ! Item was removed: - ----- Method: ObjectHistory class>>obsolete (in category 'class initialization') ----- - obsolete - "Kill the mark process before removing the class." - Current ifNotNil: - [:objectHistory| - objectHistory terminate]. - super obsolete! Item was removed: - ----- Method: ObjectHistory>>ageOf: (in category 'queries') ----- - ageOf: anObject - "Age of anObject in seconds" - | timestamp | - timestamp := self timestampOf: anObject. - timestamp ifNil: [^0]. - ^(DateAndTime now - timestamp) asSeconds roundTo: self markRate! Item was removed: - ----- Method: ObjectHistory>>initialize (in category 'initializing') ----- - initialize - self restartMarkProcess. - - ! Item was removed: - ----- Method: ObjectHistory>>markLoop (in category 'marking') ----- - markLoop - [true] whileTrue: [ - self markUpdate. - (Delay forSeconds: self markRate) wait]! Item was removed: - ----- Method: ObjectHistory>>markRate (in category 'marking') ----- - markRate - "rate of creating ObjectHistoryMarks" - ^60! Item was removed: - ----- Method: ObjectHistory>>markUpdate (in category 'marking') ----- - markUpdate - "Add a new mark and compact the marks collection" - | mark prev | - "lazy init so this happens in the background process" - marks ifNil: [self reinitMarks]. - "add new mark to object memory" - mark := self newMark. - mark timestamp <= marks last timestamp ifTrue: [^self "could happen if clock is wrong"]. - marks addLast: mark. - "compact the table by removing adjacent marks" - prev := marks first. - marks removeAllSuchThat: [:each | | doDelete | - doDelete := prev objectAfter == each. - prev := each. - doDelete]. - "The loop above is O(n) in number of marks, but that number should never become so large to be an issue. Even if the number was large, this is running at system background priority so should not interfere with any user process, not even user background processes. The symptom should only be that the system is less idle. - - If we ever get to a point where the number of marks is an issue then the compacting here could be made partial: since old marks rarely get coalesced it would make sense to only check the newer ones often, and the old ones perhaps only at the system startup."! Item was removed: - ----- Method: ObjectHistory>>newMark (in category 'private') ----- - newMark - ^ ObjectHistoryMark new! Item was removed: - ----- Method: ObjectHistory>>oopClassesByAge (in category 'stats') ----- - oopClassesByAge - "Answer collection of (oopAge in seconds -> sorted counts of object classes) sorted from lowest age" - "ObjectHistory current oopClassesByAge" - - | stats prev endOfMemory now bag age obj | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - now := self newMark timestamp. - marks do: [:mark | - prev ifNotNil: [ - bag := Bag new. - obj := prev objectAfter. - [obj == mark] whileFalse: [ - bag add: obj class. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - age := (now - mark timestamp) asSeconds roundTo: self markRate. - stats addFirst: age -> bag sortedCounts]. - prev := mark]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>oopClassesByDate (in category 'stats') ----- - oopClassesByDate - "Answer collection of (Date -> sorted counts of object classes) sorted from newest date" - "ObjectHistory current oopClassesByDate" - - | stats prev endOfMemory bag date obj thisDate | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - thisDate := nil. - bag := Bag new. - marks do: [:mark | - prev ifNotNil: [ - obj := prev objectAfter. - [obj == mark] whileFalse: [ - bag add: obj class. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - date := mark timestamp asDate. - thisDate = date ifFalse: [ - stats addFirst: date -> bag sortedCounts. - bag := Bag new. - thisDate := date]]. - prev := mark]. - thisDate = date ifFalse: [ - stats addLast: date -> bag sortedCounts]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>oopCountsByAge (in category 'stats') ----- - oopCountsByAge - "Answer collection of (oopAge in seconds -> number of objects) sorted from lowest age" - "ObjectHistory current oopCountsByAge" - - | stats prev endOfMemory now n age obj | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - now := self newMark timestamp. - marks do: [:mark | - prev ifNotNil: [ - n := 0. - obj := prev objectAfter. - [obj == mark] whileFalse: [ - n := n + 1. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - age := (now - mark timestamp) asSeconds roundTo: self markRate. - stats addFirst: age -> n]. - prev := mark]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>reinitMarks (in category 'private') ----- - reinitMarks - marks := ObjectHistoryMark allInstances asOrderedCollection. - marks - ifEmpty: [marks add: self newMark] - ifNotEmpty: [ | prev | - prev := nil. - marks removeAllSuchThat: [:obj | - prev notNil and: [prev timestamp >= obj timestamp]]]. - ! Item was removed: - ----- Method: ObjectHistory>>restartMarkProcess (in category 'marking') ----- - restartMarkProcess - markProcess ifNotNil: [markProcess terminate]. - markProcess := [self markLoop] - forkAt: Processor systemBackgroundPriority - named: 'ObjectHistory''s markProcess'. - ! Item was removed: - ----- Method: ObjectHistory>>terminate (in category 'private') ----- - terminate - markProcess ifNotNil: - [markProcess terminate]! Item was removed: - ----- Method: ObjectHistory>>timestampOf: (in category 'queries') ----- - timestampOf: anObject - "Timestamp of anObject, or nil if too new" - | endOfMemory mark | - anObject class == SmallInteger ifTrue: [^nil]. - mark := anObject. - endOfMemory := Object new. - [mark class == ObjectHistoryMark] whileFalse: [ - mark := mark nextObject. - mark == endOfMemory ifTrue: [^nil]]. - ^mark timestamp! Item was removed: - Object subclass: #ObjectHistoryMark - instanceVariableNames: 'timestamp' - classVariableNames: '' - poolDictionaries: '' - category: 'System-Support'! - - !ObjectHistoryMark commentStamp: 'bf 11/7/2012 00:12' prior: 0! - An ObjectHistoryMark is a permanent mark in the object memory. It holds a timestamp. - - While the timestamp could be used directly as mark by ObjectHistory, it's conceivable that its format might change in the future, and we do not want the mark's relative position in memory to change (which would be the case if it was migrated to a new format). So we use a distinct object instead (and we protect it against accidental become-ing by overriding those methods).! Item was removed: - ----- Method: ObjectHistoryMark>>become: (in category 'mutating') ----- - become: otherObject - ^self error: 'marks need to stay fixed in the object memory'! Item was removed: - ----- Method: ObjectHistoryMark>>becomeForward: (in category 'mutating') ----- - becomeForward: otherObject - ^self error: 'marks need to stay fixed in the object memory'! Item was removed: - ----- Method: ObjectHistoryMark>>initialize (in category 'initialization') ----- - initialize - timestamp := DateAndTime now floor. - ! Item was removed: - ----- Method: ObjectHistoryMark>>objectAfter (in category 'accessing') ----- - objectAfter - "Answer the next object in memory after me and my timestamp" - | successor | - successor := self nextObject. - successor == timestamp - ifTrue: [successor := successor nextObject]. - ^ successor! Item was removed: - ----- Method: ObjectHistoryMark>>printOn: (in category 'printing') ----- - printOn: aStream - aStream - nextPutAll: self class name; - nextPut: $(; - print: timestamp; - nextPut: $)! Item was removed: - ----- Method: ObjectHistoryMark>>timestamp (in category 'accessing') ----- - timestamp - ^timestamp - ! Item was changed: ----- Method: SmalltalkImage>>compactClassesArray (in category 'special objects') ----- compactClassesArray "Smalltalk compactClassesArray" + "Backward-compatibility support. Spur does not have compact classes." + ^{}! - "Return the array of 31 classes whose instances may be - represented compactly" - ^ self specialObjectsArray at: 29! Item was added: + ----- Method: SmalltalkImage>>growMemoryByAtLeast: (in category 'memory space') ----- + growMemoryByAtLeast: numBytes + "Grow memory by at least the requested number of bytes. + Primitive. Essential. Fail if no memory is available." + + (numBytes isInteger and: [numBytes > 0]) ifTrue: + [OutOfMemory signal]. + ^self primitiveFailed! Item was added: + ----- Method: SmalltalkImage>>maxIdentityHash (in category 'system attributes') ----- + maxIdentityHash + "Answer the maximum identityHash value supported by the VM." + + ^self primitiveFailed! Item was changed: ----- Method: SmalltalkImage>>primBytesLeft (in category 'memory space') ----- primBytesLeft + "Primitive. Answer the number of free bytes available in old space. + Not accurate unless preceded by - "Primitive. Answer the number of bytes available for new object data. - Not accurate unless preceded by Smalltalk garbageCollectMost (for reasonable accuracy), or Smalltalk garbageCollect (for real accuracy). + See Object documentation whatIsAPrimitive." - See Object documentation whatIsAPrimitive." + ^0! - ^ 0! Item was changed: ----- Method: SmalltalkImage>>primitiveGarbageCollect (in category 'memory space') ----- primitiveGarbageCollect + "Primitive. Reclaims all garbage and answers the size of the largest free chunk in old space.." - "Primitive. Reclaims all garbage and answers the number of bytes of available space." + ^self primitiveFailed! - ^ self primBytesLeft! Item was changed: ----- Method: SmalltalkImage>>recreateSpecialObjectsArray (in category 'special objects') ----- recreateSpecialObjectsArray "Smalltalk recreateSpecialObjectsArray" "To external package developers: **** DO NOT OVERRIDE THIS METHOD. ***** If you are writing a plugin and need additional special object(s) for your own use, use addGCRoot() function and use own, separate special objects registry " "The Special Objects Array is an array of objects used by the Squeak virtual machine. Its contents are critical and accesses to it by the VM are unchecked, so don't even think of playing here unless you know what you are doing." | newArray | + newArray := Array new: 60. - newArray := Array new: 58. "Nil false and true get used throughout the interpreter" newArray at: 1 put: nil. newArray at: 2 put: false. newArray at: 3 put: true. "This association holds the active process (a ProcessScheduler)" newArray at: 4 put: (self specialObjectsArray at: 4) "(self bindingOf: #Processor) but it answers an Alias". "Numerous classes below used for type checking and instantiation" newArray at: 5 put: Bitmap. newArray at: 6 put: SmallInteger. newArray at: 7 put: ByteString. newArray at: 8 put: Array. newArray at: 9 put: Smalltalk. + newArray at: 10 put: BoxedFloat64. + newArray at: 11 put: (self globals at: #MethodContext ifAbsent: [self globals at: #Context]). + newArray at: 12 put: nil. "was BlockContext." - newArray at: 10 put: Float. - newArray at: 11 put: MethodContext. - newArray at: 12 put: BlockContext. newArray at: 13 put: Point. newArray at: 14 put: LargePositiveInteger. newArray at: 15 put: Display. newArray at: 16 put: Message. newArray at: 17 put: CompiledMethod. + newArray at: 18 put: ((self specialObjectsArray at: 18) ifNil: [Semaphore new]). "low space Semaphore" - newArray at: 18 put: (self specialObjectsArray at: 18). - "(low space Semaphore)" newArray at: 19 put: Semaphore. newArray at: 20 put: Character. newArray at: 21 put: #doesNotUnderstand:. newArray at: 22 put: #cannotReturn:. newArray at: 23 put: nil. "This is the process signalling low space." "An array of the 32 selectors that are compiled as special bytecodes, paired alternately with the number of arguments each takes." newArray at: 24 put: #( #+ 1 #- 1 #< 1 #> 1 #<= 1 #>= 1 #= 1 #~= 1 #* 1 #/ 1 #\\ 1 #@ 1 #bitShift: 1 #// 1 #bitAnd: 1 #bitOr: 1 #at: 1 #at:put: 2 #size 0 #next 0 #nextPut: 1 #atEnd 0 #== 1 #class 0 #blockCopy: 1 #value 0 #value: 1 #do: 1 #new 0 #new: 1 #x 0 #y 0 ). "An array of the 255 Characters in ascii order. + Cog inlines table into machine code at: prim so do not regenerate it. + This is nil in Spur, which has immediate Characters." - Cog inlines table into machine code at: prim so do not regenerate it." newArray at: 25 put: (self specialObjectsArray at: 25). newArray at: 26 put: #mustBeBoolean. newArray at: 27 put: ByteArray. newArray at: 28 put: Process. + "An array of up to 31 classes whose instances will have compact headers; an empty array in Spur" - "An array of up to 31 classes whose instances will have compact headers" newArray at: 29 put: self compactClassesArray. + newArray at: 30 put: ((self specialObjectsArray at: 30) ifNil: [Semaphore new]). "delay Semaphore" + newArray at: 31 put: ((self specialObjectsArray at: 31) ifNil: [Semaphore new]). "user interrupt Semaphore" - newArray at: 30 put: (self specialObjectsArray at: 30). "(delay Semaphore)" - newArray at: 31 put: (self specialObjectsArray at: 31). "(user interrupt Semaphore)" "Entries 32 - 34 unreferenced. Previously these contained prototype instances to be copied for fast initialization" + newArray at: 32 put: nil. "was the prototype Float" + newArray at: 33 put: nil. "was the prototype 4-byte LargePositiveInteger" + newArray at: 34 put: nil. "was the prototype Point" - newArray at: 32 put: nil. "was (Float new: 2)" - newArray at: 33 put: nil. "was (LargePositiveInteger new: 4)" - newArray at: 34 put: nil. "was Point new" newArray at: 35 put: #cannotInterpret:. + newArray at: 36 put: nil. "was the prototype MethodContext" - "Note: This must be fixed once we start using context prototypes (yeah, right)" - "(MethodContext new: CompiledMethod fullFrameSize)." - newArray at: 36 put: (self specialObjectsArray at: 36). "Is the prototype MethodContext (unused by the VM)" newArray at: 37 put: BlockClosure. + newArray at: 38 put: nil. "was the prototype BlockContext" - "(BlockContext new: CompiledMethod fullFrameSize)." - newArray at: 38 put: (self specialObjectsArray at: 38). "Is the prototype BlockContext (unused by the VM)" "array of objects referred to by external code" + newArray at: 39 put: (self specialObjectsArray at: 39). "external semaphores" - newArray at: 39 put: (self specialObjectsArray at: 39). "preserve external semaphores" newArray at: 40 put: nil. "Reserved for Mutex in Cog VMs" + newArray at: 41 put: ((self specialObjectsArray at: 41) ifNil: [LinkedList new]). "Reserved for a LinkedList instance for overlapped calls in CogMT" + newArray at: 42 put: ((self specialObjectsArray at: 42) ifNil: [Semaphore new]). "finalization Semaphore" - newArray at: 41 put: nil. "Reserved for a LinkedList instance for overlapped calls in CogMT" - "finalization Semaphore" - newArray at: 42 put: ((self specialObjectsArray at: 42) ifNil: [Semaphore new]). newArray at: 43 put: LargeNegativeInteger. "External objects for callout. Note: Written so that one can actually completely remove the FFI." newArray at: 44 put: (self at: #ExternalAddress ifAbsent: []). newArray at: 45 put: (self at: #ExternalStructure ifAbsent: []). newArray at: 46 put: (self at: #ExternalData ifAbsent: []). newArray at: 47 put: (self at: #ExternalFunction ifAbsent: []). newArray at: 48 put: (self at: #ExternalLibrary ifAbsent: []). newArray at: 49 put: #aboutToReturn:through:. newArray at: 50 put: #run:with:in:. "51 reserved for immutability message" + newArray at: 51 put: #attemptToAssign:withIndex:. - "newArray at: 51 put: #attemptToAssign:withIndex:." - newArray at: 51 put: (self specialObjectsArray at: 51 ifAbsent: []). newArray at: 52 put: #(nil "nil => generic error" #'bad receiver' #'bad argument' #'bad index' #'bad number of arguments' #'inappropriate operation' #'unsupported operation' #'no modification' #'insufficient object memory' #'insufficient C memory' #'not found' #'bad method' #'internal error in named primitive machinery' #'object may move' #'resource limit exceeded' + #'object is pinned' #'primitive write beyond end of object'). - #'object is pinned'). "53 to 55 are for Alien" newArray at: 53 put: (self at: #Alien ifAbsent: []). + newArray at: 54 put: #invokeCallbackContext:. "use invokeCallback:stack:registers:jmpbuf: for old Alien callbacks." - newArray at: 54 put: #invokeCallbackContext::. "use invokeCallback:stack:registers:jmpbuf: for old Alien callbacks." newArray at: 55 put: (self at: #UnsafeAlien ifAbsent: []). + "Used to be WeakFinalizationList for WeakFinalizationList hasNewFinalization, obsoleted by ephemeron support." + newArray at: 56 put: nil. - "Weak reference finalization" - newArray at: 56 put: (self at: #WeakFinalizationList ifAbsent: []). "reserved for foreign callback process" newArray at: 57 put: (self specialObjectsArray at: 57 ifAbsent: []). newArray at: 58 put: #unusedBytecode. + "59 reserved for Sista counter tripped message" + newArray at: 59 put: #conditionalBranchCounterTrippedOn:. + "60 reserved for Sista class trap message" + newArray at: 60 put: #classTrapFor:. "Now replace the interpreter's reference in one atomic operation" + self specialObjectsArray becomeForward: newArray! - self specialObjectsArray becomeForward: newArray - ! Item was changed: ----- Method: SmalltalkImage>>setGCParameters (in category 'snapshot and quit') ----- setGCParameters + "Adjust the VM's default GC parameters to avoid too much tenuring. + Maybe this should be left to the VM?" - "Adjust the VM's default GC parameters to avoid premature tenuring." + | proportion edenSize survivorSize averageObjectSize numObjects | + proportion := 0.9. "tenure when 90% of pastSpace is full" + edenSize := SmalltalkImage current vmParameterAt: 44. + survivorSize := edenSize / 5.0. "David's paper uses 140Kb eden + 2 x 28kb survivor spaces; Spur uses the same ratios :-)" + averageObjectSize := 8 * self wordSize. "a good approximation" + numObjects := (proportion * survivorSize / averageObjectSize) rounded. + SmalltalkImage current vmParameterAt: 6 put: numObjects "tenure when more than this many objects survive the GC"! - self vmParameterAt: 5 put: 4000. "do an incremental GC after this many allocations" - self vmParameterAt: 6 put: 2000. "tenure when more than this many objects survive the GC" - ! Item was changed: ----- Method: SpaceTally>>spaceForInstancesOf: (in category 'instance size') ----- spaceForInstancesOf: aClass + "Answer a pair of the number of bytes consumed by all instances of the + given class, including their object headers, and the number of instances." - "Answer the number of bytes consumed by all instances of the given class, including their object headers and the number of instances." + | instances total | + instances := aClass allInstances. + instances isEmpty ifTrue: [^#(0 0)]. - | smallHeaderSize instVarBytes isVariable bytesPerElement total lastInstance instance instanceCount | - instance := aClass someInstance ifNil: [ ^#(0 0) ]. - smallHeaderSize := aClass isCompact ifTrue: [ 4 ] ifFalse: [ 8 ]. - instVarBytes := aClass instSize * 4. - isVariable := aClass isVariable. - bytesPerElement := isVariable - ifFalse: [ 0 ] - ifTrue: [ aClass isBytes ifTrue: [ 1 ] ifFalse: [ 4 ] ]. total := 0. + aClass isVariable + ifTrue: + [instances do: + [:i| total := total + (aClass byteSizeOfInstanceOfSize: i basicSize)]] + ifFalse: + [total := instances size * aClass byteSizeOfInstance]. + ^{ total. instances size }! - instanceCount := 0. - "A modified version of #allInstancesDo: is inlined here. It avoids an infinite loop when another process is creating new instances of aClass." - self flag: #allInstancesDo:. - lastInstance := - aClass == CompiledMethod "CompiledMethod has special format, see its class comment" - ifTrue: [aClass new] - ifFalse: [aClass basicNew]. - [ instance == lastInstance ] whileFalse: [ - | contentBytes headerBytes | - contentBytes := instVarBytes + (isVariable - ifFalse: [ 0 ] - ifTrue: [ instance basicSize * bytesPerElement ]). - headerBytes := contentBytes > 255 - ifTrue: [ 12 ] - ifFalse: [ smallHeaderSize ]. - total := total + headerBytes + (contentBytes roundUpTo: 4). - instanceCount := instanceCount + 1. - instance := instance nextInstance ]. - ^{ total. instanceCount }! Item was added: + ----- Method: SystemDictionary>>growMemoryByAtLeast: (in category 'memory space') ----- + growMemoryByAtLeast: numBytes + "Grow memory by at least the requested number of bytes. + Primitive. Fail if no memory is available. Essential." + + ^(numBytes isInteger and: [numBytes > 0]) + ifTrue: [OutOfMemory signal] + ifFalse: [self primitiveFailed]! Item was added: + ----- Method: SystemDictionary>>maxIdentityHash (in category 'system attributes') ----- + maxIdentityHash + "Answer the maximum identityHash value supported by the VM." + + ^self primitiveFailed! Item was added: + ----- Method: SystemDictionary>>setGCParameters (in category 'snapshot and quit') ----- + setGCParameters + "Adjust the VM's default GC parameters to avoid too much tenuring. + Maybe this should be left to the VM?" + + | proportion edenSize survivorSize averageObjectSize numObjects | + proportion := 0.9. "tenure when 90% of pastSpace is full" + edenSize := SmalltalkImage current vmParameterAt: 44. + survivorSize := edenSize / 5.0. "David's paper uses 140Kb eden + 2 x 28kb survivor spaces; Spur uses the same ratios :-)" + averageObjectSize := 8 * self wordSize. "a good approximation" + numObjects := (proportion * survivorSize / averageObjectSize) rounded. + SmalltalkImage current vmParameterAt: 6 put: numObjects "tenure when more than this many objects survive the GC"! Item was added: + ----- Method: SystemNavigation>>allObjects (in category 'query') ----- + allObjects + "Answer an Array of all objects in the system. Fail if + there isn't enough memory to instantiate the result." + + ^self primitiveFailed! Item was changed: ----- Method: SystemNavigation>>allObjectsDo: (in category 'query') ----- allObjectsDo: aBlock + "Evaluate the argument, aBlock, for each object in the system, excluding immediates + such as SmallInteger and Character." + self allObjectsOrNil + ifNotNil: [:allObjects| allObjects do: aBlock] + ifNil: + ["Fall back on the old single object primitive code. With closures, this needs + to use an end marker (lastObject) since activation of the block will create + new contexts and cause an infinite loop. The lastObject must be created + before calling someObject, so that the VM can settle the enumeration (e.g. + by flushing new space) as a side effect of someObject" + | object lastObject | + lastObject := Object new. + object := self someObject. + [lastObject == object or: [0 == object]] whileFalse: + [aBlock value: object. + object := object nextObject]]! - "Evaluate the argument, aBlock, for each object in the system - excluding SmallIntegers. With closures, this needs to use an end - marker (lastObject) since activation of the block will create new - contexts and cause an infinite loop." - | object lastObject | - object := self someObject. - lastObject := Object new. - [lastObject == object or: [0 == object]] - whileFalse: [aBlock value: object. - object := object nextObject]! Item was added: + ----- Method: SystemNavigation>>allObjectsOrNil (in category 'query') ----- + allObjectsOrNil + "Answer an Array of all objects in the system. Fail if there isn't + enough memory to instantiate the result and answer nil." + + ^nil! From commits at source.squeak.org Fri Apr 3 16:38:37 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 16:38:38 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.817.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.817.mcz ==================== Summary ==================== Name: Morphic-mt.817 Author: mt Time: 3 April 2015, 6:38:01.265 pm UUID: c2a1e4c5-1ee5-0445-956f-8951e2fbb8fa Ancestors: Morphic-mt.816 Color handling in system windows cleaned-up and fixed. #adoptPaneColor: will now be sent to all panes on activate/passivate to give them a chance to also "look inactive". =============== Diff against Morphic-mt.816 =============== Item was changed: ----- Method: SystemWindow class>>labelled: (in category 'instance creation') ----- labelled: labelString + + ^ self basicNew + initializeWithLabel: labelString; + yourself! - ^ (self basicNew setLabel: labelString) initialize! Item was changed: ----- Method: SystemWindow>>activateWindow (in category 'top window') ----- activateWindow "Bring me to the front and make me able to respond to mouse and keyboard. Was #activate (sw 5/18/2001 23:20)" | oldTop outerMorph sketchEditor pal | outerMorph := self topRendererOrSelf. outerMorph owner ifNil: [^ self "avoid spurious activate when drop in trash"]. oldTop := TopWindow. oldTop = self ifTrue: [^self]. TopWindow := self. oldTop ifNotNil: [oldTop passivate]. outerMorph owner firstSubmorph == outerMorph ifFalse: ["Bring me (with any flex) to the top if not already" outerMorph owner addMorphFront: outerMorph]. self submorphsDo: [:m | m unlock]. label ifNotNil: [label color: Color black]. self undimWindowButtons. + labelArea ifNotNil: [labelArea submorphsDo: [:m | m unlock; show]]. + self + setStripeColorsFrom: self paneColorToUse; + adoptPaneColor: self paneColorToUse. + - labelArea ifNotNil: - [labelArea submorphsDo: [:m | m unlock; show]. - self setStripeColorsFrom: self paneColorToUse]. self isCollapsed ifFalse: [model modelWakeUpIn: self. self positionSubmorphs. labelArea ifNil: [self adjustBorderUponActivationWhenLabeless]]. (sketchEditor := self extantSketchEditor) ifNotNil: [sketchEditor comeToFront. (pal := self world findA: PaintBoxMorph) ifNotNil: [pal comeToFront]]. + + self updatePaneColors.! - ! Item was changed: ----- Method: SystemWindow>>defaultBorderColor (in category 'initialization') ----- defaultBorderColor "answer the default border color/fill style for the receiver" + ^ self defaultColor muchDarker! - ^ #raised.! Item was changed: ----- Method: SystemWindow>>defaultBorderWidth (in category 'initialization') ----- defaultBorderWidth "answer the default border width for the receiver" + ^ 1! - ^ 2.! Item was added: + ----- Method: SystemWindow>>defaultBounds (in category 'initialization') ----- + defaultBounds + + ^ 0@0 corner: 300@200! Item was changed: ----- Method: SystemWindow>>defaultColor (in category 'initialization') ----- defaultColor "answer the default color/fill style for the receiver" + ^ Preferences uniformWindowColor! - ^ Color white.! Item was changed: + ----- Method: SystemWindow>>existingPaneColor (in category 'colors handling') ----- - ----- Method: SystemWindow>>existingPaneColor (in category 'panes') ----- existingPaneColor "Answer the existing pane color for the window, obtaining it from the first paneMorph if any, and fall back on using the second stripe color if necessary." | aColor | aColor := self valueOfProperty: #paneColor. aColor ifNil: [self setProperty: #paneColor toValue: (aColor := self paneColor)]. ^aColor.! Item was changed: + ----- Method: SystemWindow>>gradientWithColor: (in category 'colors handling') ----- - ----- Method: SystemWindow>>gradientWithColor: (in category 'initialization') ----- gradientWithColor: aColor | gradient | gradient := GradientFillStyle ramp: { 0.0 -> Color white. 0.2 -> (aColor mixed: 0.5 with: (Color gray: 0.9)) lighter. 1.0 -> aColor. }. gradient origin: self topLeft. gradient direction: 0 @ self labelHeight. ^gradient! Item was changed: ----- Method: SystemWindow>>initialize (in category 'initialization') ----- initialize "Initialize a system window. Add label, stripes, etc., if desired" + super initialize. + + self layoutPolicy: ProportionalLayout new. + + self initializeLabelArea. + self addCornerGrips. + + Preferences menuAppearance3d ifTrue: [ + self + addDropShadow; + shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.333); + shadowOffset: 1@1]. + allowReframeHandles := true. - labelString ifNil: [labelString := 'Untitled Window']. isCollapsed := false. activeOnlyOnTop := true. paneMorphs := Array new. - borderColor := Color lightGray. - borderWidth := 1. - self color: Color veryVeryLightGray muchLighter. - self layoutPolicy: ProportionalLayout new. - - self initializeLabelArea. - - self addCornerGrips. - - self extent: 300 @ 200. mustNotClose := false. + updatablePanes := Array new.! - updatablePanes := Array new. - - Preferences menuAppearance3d - ifTrue: [ - self - addDropShadow; - shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.333); - shadowOffset: 1@1. - ]. - ! Item was changed: ----- Method: SystemWindow>>initializeLabelArea (in category 'initialization') ----- initializeLabelArea "Initialize the label area (titlebar) for the window." + + labelString ifNil: [labelString := 'Untitled Window']. label := StringMorph new contents: labelString; font: Preferences windowTitleFont emphasis: 0. "Add collapse box so #labelHeight will work" collapseBox := self createCollapseBox. stripes := Array with: (RectangleMorph newBounds: bounds) with: (RectangleMorph newBounds: bounds). "see extent:" self addLabelArea. self setLabelWidgetAllowance. self addCloseBox. self class moveMenuButtonRight ifTrue: [self addLabel. self addMenuControl] ifFalse: [self addMenuControl. self addLabel]. self addExpandBox. labelArea addMorphBack: collapseBox. self setFramesForLabelArea. Preferences noviceMode ifTrue: [closeBox ifNotNil: [closeBox setBalloonText: 'close window']. menuBox ifNotNil: [menuBox setBalloonText: 'window menu']. collapseBox ifNotNil: [collapseBox setBalloonText: 'collapse/expand window']]. ! Item was added: + ----- Method: SystemWindow>>initializeWithLabel: (in category 'initialization') ----- + initializeWithLabel: aString + + labelString := aString. + self initialize.! Item was changed: + ----- Method: SystemWindow>>paneColor (in category 'colors handling') ----- - ----- Method: SystemWindow>>paneColor (in category 'colors') ----- paneColor | cc | (cc := self valueOfProperty: #paneColor) ifNotNil: [^cc]. Display depth > 2 ifTrue: [model ifNotNil: [model isInMemory ifTrue: [cc := Color colorFrom: model defaultBackgroundColor]]. cc ifNil: [cc := paneMorphs isEmptyOrNil ifFalse: [paneMorphs first color]]]. cc ifNil: [cc := self defaultBackgroundColor]. self paneColor: cc. ^cc! Item was changed: + ----- Method: SystemWindow>>paneColor: (in category 'colors handling') ----- - ----- Method: SystemWindow>>paneColor: (in category 'panes') ----- paneColor: aColor self setProperty: #paneColor toValue: aColor. self adoptPaneColor: aColor.! Item was changed: + ----- Method: SystemWindow>>paneColorToUse (in category 'colors handling') ----- - ----- Method: SystemWindow>>paneColorToUse (in category 'panes') ----- paneColorToUse ^ Display depth <= 2 ifTrue: [Color white] ifFalse: [self paneColor]! Item was changed: ----- Method: SystemWindow>>passivate (in category 'top window') ----- passivate "Make me unable to respond to mouse and keyboard" label ifNotNil: [label color: Color darkGray]. + + (SystemWindow gradientWindow + ifTrue: [self paneColorToUse duller darker] + ifFalse: [self paneColorToUse darker]) in: [:c | + self + setStripeColorsFrom: c; + adoptPaneColor: c]. + - self setStripeColorsFrom: self paneColorToUse. model modelSleep. self lockInactivePortions ! Item was changed: + ----- Method: SystemWindow>>raisedColor (in category 'colors handling') ----- - ----- Method: SystemWindow>>raisedColor (in category 'drawing') ----- raisedColor ^self paneColor raisedColor! Item was changed: + ----- Method: SystemWindow>>refreshWindowColor (in category 'colors handling') ----- - ----- Method: SystemWindow>>refreshWindowColor (in category 'initialization') ----- refreshWindowColor "For changing the underlying model's default window color" self paneColor: nil. self setWindowColor: self paneColor.! Item was changed: + ----- Method: SystemWindow>>restoreDefaultPaneColor (in category 'colors handling') ----- - ----- Method: SystemWindow>>restoreDefaultPaneColor (in category 'panes') ----- restoreDefaultPaneColor "Useful when changing from monochrome to color display" self setStripeColorsFrom: self paneColor.! Item was removed: - ----- Method: SystemWindow>>scrollBarColor (in category 'drawing') ----- - scrollBarColor - ^self paneColor! Item was changed: + ----- Method: SystemWindow>>setStripeColorsFrom: (in category 'colors handling') ----- - ----- Method: SystemWindow>>setStripeColorsFrom: (in category 'label') ----- setStripeColorsFrom: paneColor "Set the stripe color based on the given paneColor" labelArea ifNotNil: [labelArea color: Color transparent]. + self updateBoxesColor: paneColor. - self updateBoxesColor: (self isActive - ifTrue: [paneColor] - ifFalse: [paneColor muchDarker]). stripes ifNil: [^self]. + self borderColor: paneColor muchDarker. + SystemWindow gradientWindow + ifTrue: [self fillStyle: (self gradientWithColor: paneColor)] + ifFalse: [self color: paneColor].! - ifTrue: [ - self fillStyle: (self isActive - ifTrue: [self gradientWithColor: paneColor duller "lighter lighter lighter"] - ifFalse: [self gradientWithColor: paneColor duller darker])] - ifFalse: [ - self color: (self isActive - ifTrue: [paneColor] - ifFalse: [paneColor duller])].! Item was changed: + ----- Method: SystemWindow>>setWindowColor: (in category 'colors handling') ----- - ----- Method: SystemWindow>>setWindowColor: (in category 'menu') ----- setWindowColor: incomingColor | existingColor aColor | incomingColor ifNil: [^ self]. "it happens" aColor := incomingColor asNontranslucentColor. (aColor = ColorPickerMorph perniciousBorderColor or: [aColor = Color black]) ifTrue: [^ self]. existingColor := self paneColorToUse. existingColor ifNil: [^ Beeper beep]. self paneColor: aColor. self setStripeColorsFrom: aColor. self changed.! Item was changed: + ----- Method: SystemWindow>>updatePaneColors (in category 'colors handling') ----- - ----- Method: SystemWindow>>updatePaneColors (in category 'panes') ----- updatePaneColors "Useful when changing from monochrome to color display" self setStripeColorsFrom: self paneColorToUse.! From commits at source.squeak.org Fri Apr 3 16:40:50 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 16:40:52 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.818.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.818.mcz ==================== Summary ==================== Name: Morphic-mt.818 Author: mt Time: 3 April 2015, 6:40:20.491 pm UUID: 755f0532-7105-9245-abc7-3bc72388d83f Ancestors: Morphic-mt.817 Scroll bars and scroll panes now update their border colors when asked for adopting a system window's pane color. =============== Diff against Morphic-mt.817 =============== Item was changed: ----- Method: ScrollBar>>updateSliderColor: (in category 'access') ----- updateSliderColor: aColor | gradient | self borderWidth: 0. Preferences gradientScrollBars ifFalse: [ + slider + borderColor: aColor muchDarker; + color: aColor. + pagingArea + borderColor: (aColor muchDarker alpha: pagingArea borderStyle color alpha); + color: (aColor darker alpha: 0.45). - slider borderStyle: (BorderStyle width: 1 color: aColor muchDarker). - slider color: aColor. - pagingArea color: (aColor darker alpha: 0.45). ^ self]. slider borderStyle: (BorderStyle width: 1 color: Color lightGray). "Fill the slider." gradient := GradientFillStyle ramp: { 0 -> (Color gray: 0.95). 0.49 -> (Color gray: 0.9). 0.5 -> (Color gray: 0.87). 1 -> (Color gray: 0.93). }. gradient origin: slider topLeft. gradient direction: (self bounds isWide ifTrue:[0@slider height] ifFalse:[slider width@0]). slider fillStyle: gradient. "Fill the paging area." gradient := GradientFillStyle ramp: { 0 -> (Color gray: 0.65). 0.6 -> (Color gray: 0.82). 1 -> (Color gray: 0.88). }. gradient origin: self topLeft. gradient direction: (self bounds isWide ifTrue:[0@self height] ifFalse:[self width@0]). pagingArea fillStyle: gradient.! Item was changed: ----- Method: ScrollPane>>adoptPaneColor: (in category 'access') ----- adoptPaneColor: paneColor super adoptPaneColor: paneColor. + + "May not be in the hierarchy at the moment." scrollBar adoptPaneColor: paneColor. hScrollBar adoptPaneColor: paneColor. + + paneColor ifNotNil: [:c | self borderColor: c muchDarker].! - ! From commits at source.squeak.org Fri Apr 3 17:06:17 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 17:06:19 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.819.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.819.mcz ==================== Summary ==================== Name: Morphic-mt.819 Author: mt Time: 3 April 2015, 7:05:40.09 pm UUID: 5298c5d0-b476-0d41-8bad-74bfe2bfd5dc Ancestors: Morphic-mt.818 Fixed window color refreshing when changing the global color scheme. Now, it honors the #isActive state of all open windows. Additionally, we do not send #adoptPaneColor: with nil anymore to all our submorphs... =============== Diff against Morphic-mt.818 =============== Item was added: + ----- Method: SystemWindow>>paneColorToUseWhenNotActive (in category 'colors handling') ----- + paneColorToUseWhenNotActive + + ^ (SystemWindow gradientWindow + ifTrue: [self paneColorToUse duller darker] + ifFalse: [self paneColorToUse darker])! Item was changed: ----- Method: SystemWindow>>passivate (in category 'top window') ----- passivate "Make me unable to respond to mouse and keyboard" label ifNotNil: [label color: Color darkGray]. + self paneColorToUseWhenNotActive in: [:c | - (SystemWindow gradientWindow - ifTrue: [self paneColorToUse duller darker] - ifFalse: [self paneColorToUse darker]) in: [:c | self setStripeColorsFrom: c; adoptPaneColor: c]. model modelSleep. self lockInactivePortions ! Item was changed: ----- Method: SystemWindow>>refreshWindowColor (in category 'colors handling') ----- refreshWindowColor "For changing the underlying model's default window color" + self setProperty: #paneColor toValue: nil. + self setWindowColor: self paneColor. + + "Reset colors if we are not active." + self isActive ifFalse: [ + self paneColorToUseWhenNotActive in: [:c | + self + setStripeColorsFrom: c; + adoptPaneColor: c]].! - self paneColor: nil. - self setWindowColor: self paneColor.! From marcel.taeumel at student.hpi.uni-potsdam.de Fri Apr 3 16:56:18 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Fri Apr 3 17:08:18 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: <1428075270847-4817347.post@n4.nabble.com> References: <1428075270847-4817347.post@n4.nabble.com> Message-ID: <1428080178583-4817382.post@n4.nabble.com> And could we turn of the seconds of the clock in the main docking bar?^^ Best, Marcel -- View this message in context: http://forum.world.st/A-plan-for-the-release-tp4817346p4817382.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Fri Apr 3 17:12:36 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 17:12:37 2015 Subject: [squeak-dev] The Trunk: MorphicExtras-mt.159.mcz Message-ID: Marcel Taeumel uploaded a new version of MorphicExtras to project The Trunk: http://source.squeak.org/trunk/MorphicExtras-mt.159.mcz ==================== Summary ==================== Name: MorphicExtras-mt.159 Author: mt Time: 3 April 2015, 7:12:23.045 pm UUID: 3620bcc0-0f03-e244-b044-bd85d1e9f3d0 Ancestors: MorphicExtras-mt.158 Clock morph now shows the current date in the balloon text. =============== Diff against MorphicExtras-mt.158 =============== Item was added: + ----- Method: ClockMorph>>balloonText (in category 'accessing') ----- + balloonText + + ^ Date current weekday, ', ', Date current printString! From asqueaker at gmail.com Fri Apr 3 17:23:18 2015 From: asqueaker at gmail.com (Chris Muller) Date: Fri Apr 3 17:23:22 2015 Subject: [squeak-dev] Re: bad UI bug introduced with recent list highlightiong changes. In-Reply-To: <1428044005053-4817131.post@n4.nabble.com> References: <1428044005053-4817131.post@n4.nabble.com> Message-ID: On Fri, Apr 3, 2015 at 1:53 AM, Marcel Taeumel wrote: > I guess that I changed that because it started to annoy me recently as I > highlighted the hovered item in lists and played around with providing > item-specific balloon texts. No additional click needed there. The "power of pointing" is a wonderful UI gesture. It's so energy efficient for the user. A simple nudge of the mouse can spawn a lot of output and, then, simply moving away (one more nudge) reclaims all the screen space. Sometimes I like to pop up even /interactive/ panels my Maui apps by merely pointing. What is remarkable to me is how underrated it is. I guess Windows' click-for-focus pretty much blew it out of the water.. From tim at rowledge.org Fri Apr 3 17:26:48 2015 From: tim at rowledge.org (tim Rowledge) Date: Fri Apr 3 17:26:53 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: <1428080178583-4817382.post@n4.nabble.com> References: <1428075270847-4817347.post@n4.nabble.com> <1428080178583-4817382.post@n4.nabble.com> Message-ID: On 03-04-2015, at 9:56 AM, Marcel Taeumel wrote: > And could we turn of the seconds of the clock in the main docking bar? That option is in an easily reachable morph menu (for certain definitions of ?easily reachable?), so in principle it could be defaulted to off as part of the release, or a preference might be warranted. tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim Science is imagination equipped with grappling hooks. From kbrown at mac.com Fri Apr 3 17:41:20 2015 From: kbrown at mac.com (Ken G. Brown) Date: Fri Apr 3 17:42:09 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: Message-ID: I think what Mail is doing is honoring any previous selection and treating a cntl-click menu selection as a separate operation, then puts you back to the state you were in before you initiated the action. You get to operate either on the single message under the pointer at the time you cntl-click if it isn?t the current selection, or else the current selection if the pointer is over any part of the current selection, which may be more than one message. To me this seems a bit better than losing the current selection when doing the cntl-click menu operation. Ken G. Brown > On Apr 2, 2015, at 20:51, tim Rowledge wrote: > > I notice that - at least on my iMac, in Mail - using a right-click in the list of messages opens a menu that treats the item under the pointer as the selected item. And after making any choice from the menu it appears to actually change the selection, whether the choice refers specifically to an item or just the list. Indeed, it changes the selection if you move away from the menu to make no choice. > I think that?s rather annoying now that I?ve noticed it. It?s treating the right click as a select-then-menu but presenting it visually inconsistent with that action. Not smart. > > > tim > -- > tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim > dilate - live long > > > From commits at source.squeak.org Fri Apr 3 17:50:20 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 17:50:22 2015 Subject: [squeak-dev] The Trunk: TrueType-topa.36.mcz Message-ID: Tobias Pape uploaded a new version of TrueType to project The Trunk: http://source.squeak.org/trunk/TrueType-topa.36.mcz ==================== Summary ==================== Name: TrueType-topa.36 Author: topa Time: 3 April 2015, 7:50:06.323 pm UUID: 9b5c4259-1944-4ee9-8ea0-0196c85240f4 Ancestors: TrueType-cmm.35 cope for the fact that typographicAscender and typographicDescender may not be available and 0-height fonts are a bit useless =============== Diff against TrueType-cmm.35 =============== Item was changed: ----- Method: TTCFont>>lineGap (in category 'accessing') ----- lineGap "Answer the line gap from the ttf description" + ^self pixelSize * ttcDescription typographicLineGap // ttcDescription typographicFontHeight! - ^self pixelSize * ttcDescription typographicLineGap // - (ttcDescription typographicAscender - ttcDescription typographicDescender)! Item was added: + ----- Method: TTFileDescription>>typographicFontHeight (in category 'accessing') ----- + typographicFontHeight + "cope for the fact that typographicAscender and + typographicDescender may not be available and + 0-height fonts are a bit useless" + | tfh | + tfh := self typographicAscender - self typographicDescender. + ^ tfh = 0 ifTrue: [self fontHeight] ifFalse: [tfh]! From tim at rowledge.org Fri Apr 3 18:00:14 2015 From: tim at rowledge.org (tim Rowledge) Date: Fri Apr 3 18:00:19 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: Message-ID: On 03-04-2015, at 10:41 AM, Ken G. Brown wrote: > I think what Mail is doing is honoring any previous selection and treating a cntl-click menu selection as a separate operation, then puts you back to the state you were in before you initiated the action. > You get to operate either on the single message under the pointer at the time you cntl-click if it isn?t the current selection, or else the current selection if the pointer is over any part of the current selection, which may be more than one message. > > To me this seems a bit better than losing the current selection when doing the cntl-click menu operation. I?d agree with that last part if it were what appears to actually happen. But on my iMac it just isn?t the sequence. A B C-selected D right-click over A and the outline box appears around A, the menu appears. Make any choice - even no-choice - and A becomes the selected item and C is deselected. One of the problem with discussing these things is that they often seem quite different in different contexts and what looks a great idea in one situation is a disaster in another. I one doesn?t use the case where it looks good you?re not going to be much in favour of the idea. Where I *can* see this working well is in cases where there is a list that does not produce a selection affecting some content view. Imagine a list of items where you are able to choose from a few menu options relating to each one ( err, maybe delete/save/pass-to-supervisor) - then, right-click to open a menu specifically referring to the item under the pointer seems like it might make sense. Further out, I can imagine that we could make the concept work within the normal tools after some fairly major rejigging of how they work. Right now the whole usage pattern in the lists used in Browsers etc is that the menu acts on the list itself or *the selection previously set*. That, by the way, results in some bugs in places where the code doesn?t bother to check for a selection - try fileout in a browser message list where there is no selection. tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim Oxymorons: Good grief From commits at source.squeak.org Fri Apr 3 18:06:01 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 18:06:02 2015 Subject: [squeak-dev] The Trunk: TrueType-topa.37.mcz Message-ID: Tobias Pape uploaded a new version of TrueType to project The Trunk: http://source.squeak.org/trunk/TrueType-topa.37.mcz ==================== Summary ==================== Name: TrueType-topa.37 Author: topa Time: 3 April 2015, 8:05:53.829 pm UUID: 7e0500fb-7d43-4b5f-ab4e-2b965e3af3f8 Ancestors: TrueType-topa.36 React to dpi changes =============== Diff against TrueType-topa.36 =============== Item was added: + ----- Method: TTCFont>>pixelsPerInchChanged (in category 'as yet unclassified') ----- + pixelsPerInchChanged + "The definition of TextStyle class>>pixelsPerInch has changed. Do whatever is necessary." + self recreateCache! From karlramberg at gmail.com Fri Apr 3 18:25:22 2015 From: karlramberg at gmail.com (Karl Ramberg) Date: Fri Apr 3 18:37:18 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: References: Message-ID: <1428085522795-4817399.post@n4.nabble.com> Hi, May I suggest removing Universes ? Universes seem totally defunct Karl -- View this message in context: http://forum.world.st/A-plan-for-the-release-tp4817346p4817399.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From eliot.miranda at gmail.com Fri Apr 3 18:45:50 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Fri Apr 3 18:45:53 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: <1428080178583-4817382.post@n4.nabble.com> References: <1428075270847-4817347.post@n4.nabble.com> <1428080178583-4817382.post@n4.nabble.com> Message-ID: On Fri, Apr 3, 2015 at 9:56 AM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > And could we turn of the seconds of the clock in the main docking bar?^^ > Yes please :) > > Best, > Marcel > > > > -- > View this message in context: > http://forum.world.st/A-plan-for-the-release-tp4817346p4817382.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150403/ce713e9d/attachment.htm From eliot.miranda at gmail.com Fri Apr 3 18:48:06 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Fri Apr 3 18:48:09 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: <1428075270847-4817347.post@n4.nabble.com> References: <1428075270847-4817347.post@n4.nabble.com> Message-ID: On Fri, Apr 3, 2015 at 8:34 AM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > Hi Eliot, > > right now, I am working only on the HelpBrowser (~1-2 weeks left), doing > some code clean-up and also some bug fixing -- including ui bugs. ;-) > > No bigger change (major changes to standard tools or new tools) planned > from > my side. As for the stability, my observation is that we are getting more > stable with every update. > > But what about new packages for this release: > - SqueakSSL > - WebClient > > Any ideas on that? > It's not my call. My concern here is VM impact. Only SqueakSSL has implications for the VM right? I would have to make sure that SqueakSSL builds correctly and the tests pass for all platforms. With help from those that have compiled and used SqueakSSL I think I could manage that. > > Best, > Marcel > > > > -- > View this message in context: > http://forum.world.st/A-plan-for-the-release-tp4817346p4817347.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150403/c9075863/attachment.htm From marcel.taeumel at student.hpi.uni-potsdam.de Fri Apr 3 18:42:22 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Fri Apr 3 18:54:19 2015 Subject: [squeak-dev] Hi-DPI Check Message-ID: <1428086542429-4817402.post@n4.nabble.com> Besides fonts and some generic abstraction in the image, I wanted to find out to which degree Squeak and its tools can cope with many pixels. This is what I adapted to trunk: high-dpi.cs You see, many hard-coded pixel-assumptions to fix. This is what I got: hidpi-test-1.png Looks promising. Monticello is broken. :-D Best, Marcel -- View this message in context: http://forum.world.st/Hi-DPI-Check-tp4817402.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From tim at rowledge.org Fri Apr 3 18:59:27 2015 From: tim at rowledge.org (tim Rowledge) Date: Fri Apr 3 18:59:32 2015 Subject: [squeak-dev] Hi-DPI Check In-Reply-To: <1428086542429-4817402.post@n4.nabble.com> References: <1428086542429-4817402.post@n4.nabble.com> Message-ID: On 03-04-2015, at 11:42 AM, Marcel Taeumel wrote: > > You see, many hard-coded pixel-assumptions to fix. This is what I got: > > hidpi-test-1.png > > Looks promising. It does. Not quite so keen on the sorta-kinda shadow effects on the window frames though. I?ve never seen the point - a window desktop is *not* a 3D world. Unless of course it actually is, with all the extra excitement that brings. tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim Strange OpCodes: RBT: Rewind and Break Tape From kbrown at mac.com Fri Apr 3 19:04:58 2015 From: kbrown at mac.com (Ken G. Brown) Date: Fri Apr 3 19:05:10 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: Message-ID: Hmmm, when I tried, it happens as you say except C would stay selected afterwards. And It could be C+D+... initially selected. I'm on OS X 10.10.2 Ken, from my iPhone > On Apr 3, 2015, at 12:00, tim Rowledge wrote: > > >> On 03-04-2015, at 10:41 AM, Ken G. Brown wrote: >> >> I think what Mail is doing is honoring any previous selection and treating a cntl-click menu selection as a separate operation, then puts you back to the state you were in before you initiated the action. >> You get to operate either on the single message under the pointer at the time you cntl-click if it isn?t the current selection, or else the current selection if the pointer is over any part of the current selection, which may be more than one message. >> >> To me this seems a bit better than losing the current selection when doing the cntl-click menu operation. > > I?d agree with that last part if it were what appears to actually happen. But on my iMac it just isn?t the sequence. > > A > B > C-selected > D > > right-click over A and the outline box appears around A, the menu appears. Make any choice - even no-choice - and A becomes the selected item and C is deselected. > > One of the problem with discussing these things is that they often seem quite different in different contexts and what looks a great idea in one situation is a disaster in another. I one doesn?t use the case where it looks good you?re not going to be much in favour of the idea. > > Where I *can* see this working well is in cases where there is a list that does not produce a selection affecting some content view. Imagine a list of items where you are able to choose from a few menu options relating to each one ( err, maybe delete/save/pass-to-supervisor) - then, right-click to open a menu specifically referring to the item under the pointer seems like it might make sense. > > Further out, I can imagine that we could make the concept work within the normal tools after some fairly major rejigging of how they work. Right now the whole usage pattern in the lists used in Browsers etc is that the menu acts on the list itself or *the selection previously set*. That, by the way, results in some bugs in places where the code doesn?t bother to check for a selection - try fileout in a browser message list where there is no selection. > > tim > -- > tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim > Oxymorons: Good grief > > > From tim at rowledge.org Fri Apr 3 19:13:05 2015 From: tim at rowledge.org (tim Rowledge) Date: Fri Apr 3 19:13:10 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: Message-ID: <6A27527A-A7ED-40C5-ADDB-60FB7B75516D@rowledge.org> On 03-04-2015, at 12:04 PM, Ken G. Brown wrote: > Hmmm, when I tried, it happens as you say except C would stay selected afterwards. And It could be C+D+... initially selected. > I'm on OS X 10.10.2 Ah; 10.9.5 here tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim Cap'n! The spellchecker kinna take this abuse! From commits at source.squeak.org Fri Apr 3 19:58:18 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 19:58:19 2015 Subject: [squeak-dev] The Trunk: TrueType-topa.38.mcz Message-ID: Tobias Pape uploaded a new version of TrueType to project The Trunk: http://source.squeak.org/trunk/TrueType-topa.38.mcz ==================== Summary ==================== Name: TrueType-topa.38 Author: topa Time: 3 April 2015, 9:58:09.898 pm UUID: 3f329d76-72af-4f7c-99f7-aea1641f3d91 Ancestors: TrueType-topa.37 As TTFileDescription as TTFontDescription =============== Diff against TrueType-topa.37 =============== Item was added: + ----- Method: TTFontDescription>>typographicFontHeight (in category 'accessing') ----- + typographicFontHeight + "cope for the fact that typographicAscender and + typographicDescender may not be available and + 0-height fonts are a bit useless" + | tfh | + tfh := self typographicAscender - self typographicDescender. + ^ tfh = 0 ifTrue: [self fontHeight] ifFalse: [tfh]! From marcel.taeumel at student.hpi.uni-potsdam.de Fri Apr 3 19:59:58 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Fri Apr 3 20:11:54 2015 Subject: [squeak-dev] Re: Hi-DPI Check In-Reply-To: References: <1428086542429-4817402.post@n4.nabble.com> Message-ID: <1428091198075-4817422.post@n4.nabble.com> Yeah, maybe only for the active windows, which is still hard to distinguish on a 27-inch screen with many open windows. :) We need *real* shadow. :D Best, Marcel -- View this message in context: http://forum.world.st/Hi-DPI-Check-tp4817402p4817422.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Fri Apr 3 20:21:50 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 20:21:52 2015 Subject: [squeak-dev] The Trunk: ToolsTests-mt.71.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolsTests to project The Trunk: http://source.squeak.org/trunk/ToolsTests-mt.71.mcz ==================== Summary ==================== Name: ToolsTests-mt.71 Author: mt Time: 3 April 2015, 10:21:47.942 pm UUID: 10c332fa-df6f-9940-83f5-23269774866e Ancestors: ToolsTests-bf.70 Fixed #tearDown in MessageNamesTest because it will only work if tests did not close the topView already. This happes, for example, if reuse-windows preference is enabled. =============== Diff against ToolsTests-bf.70 =============== Item was changed: ----- Method: MessageNamesTest>>tearDown (in category 'as yet unclassified') ----- tearDown + browser topView ifNotNil: [:v | + ToolBuilder default close: v].! - ToolBuilder default close: browser topView.! From commits at source.squeak.org Fri Apr 3 20:25:39 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 20:25:42 2015 Subject: [squeak-dev] The Trunk: Collections-cmm.603.mcz Message-ID: Chris Muller uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections-cmm.603.mcz ==================== Summary ==================== Name: Collections-cmm.603 Author: cmm Time: 11 February 2015, 2:38:57.218 pm UUID: 48d4fe0c-cde3-4244-b87f-2d44e3214240 Ancestors: Collections-mt.602 - Collection>>#groupBy:having: is already being used for non-Integer groups, and integerDictionary is now slower than a regular Dictionary in Spur. - PositionableStream>>#nextInto:, #next:into:, #nextInto:startingAt:, #next:into:startingAt:, and #readInto:startingAt:count require no services specific to PositionableStream. Move them up to Stream and remove the redundant implementations from various subclasses. - Let WeakArray>>#species be a regular Array instead of its own class, so that WeakArray's can be successfully compared to Arrays with equivalent contents. =============== Diff against Collections-mt.602 =============== Item was changed: ----- Method: Collection>>groupBy:having: (in category 'enumerating') ----- groupBy: keyBlock having: selectBlock + "Like in SQL operation - Split the recievers contents into collections of elements for which keyBlock returns the same results, and return those collections allowed by selectBlock." - "Like in SQL operation - Split the recievers contents into collections of - elements for which keyBlock returns the same results, and return those - collections allowed by selectBlock. keyBlock should return an Integer." | result | + result := Dictionary new. + self do: + [ : each | | key | + key := keyBlock value: each. + (result + at: key + ifAbsentPut: [ OrderedCollection new ]) add: each ]. + ^ result select: selectBlock! - result := PluggableDictionary integerDictionary. - self do: - [:e | - | key | - key := keyBlock value: e. - (result includesKey: key) - ifFalse: [result at: key put: OrderedCollection new]. - (result at: key) - add: e]. - ^result select: selectBlock! Item was removed: - ----- Method: NullStream>>next:into: (in category 'reading') ----- - next: n into: aCollection - "Read n objects into the given collection. - Return aCollection or a partial copy if less than - n elements have been read." - - ^self next: n into: aCollection startingAt: 1! Item was removed: - ----- Method: NullStream>>nextInto:startingAt: (in category 'reading') ----- - nextInto: aCollection startingAt: startIndex - "Read the next elements of the receiver into aCollection. - Return aCollection or a partial copy if less than aCollection - size elements have been read." - - ^self next: (aCollection size - startIndex+1) into: aCollection startingAt: startIndex.! Item was removed: - ----- Method: PositionableStream>>next:into: (in category 'accessing') ----- - next: n into: aCollection - "Read n objects into the given collection. - Return aCollection or a partial copy if less than - n elements have been read." - ^self next: n into: aCollection startingAt: 1! Item was removed: - ----- Method: PositionableStream>>next:into:startingAt: (in category 'accessing') ----- - next: n into: aCollection startingAt: startIndex - "Read n objects into the given collection. - Return aCollection or a partial copy if less than n elements have been read." - - | count | - count := self readInto: aCollection startingAt: startIndex count: n. - count = n - ifTrue:[ ^aCollection ] - ifFalse:[ ^aCollection copyFrom: 1 to: startIndex + count - 1 ]! Item was removed: - ----- Method: PositionableStream>>nextInto: (in category 'accessing') ----- - nextInto: aCollection - "Read the next elements of the receiver into aCollection. - Return aCollection or a partial copy if less than aCollection - size elements have been read." - ^self next: aCollection size into: aCollection startingAt: 1.! Item was removed: - ----- Method: PositionableStream>>nextInto:startingAt: (in category 'accessing') ----- - nextInto: aCollection startingAt: startIndex - "Read the next elements of the receiver into aCollection. - Return aCollection or a partial copy if less than aCollection - size elements have been read." - ^self next: (aCollection size - startIndex+1) into: aCollection startingAt: startIndex.! Item was removed: - ----- Method: PositionableStream>>readInto:startingAt:count: (in category 'accessing') ----- - readInto: aCollection startingAt: startIndex count: n - "Read n objects into the given collection. - Return number of elements that have been read." - | obj | - 0 to: n - 1 do: [:i | - (obj := self next) == nil ifTrue: [^i]. - aCollection at: startIndex + i put: obj]. - ^n! Item was added: + ----- Method: Stream>>next:into: (in category 'accessing') ----- + next: n into: aCollection + "Read n objects into the given collection. + Return aCollection or a partial copy if less than + n elements have been read." + ^self next: n into: aCollection startingAt: 1! Item was added: + ----- Method: Stream>>next:into:startingAt: (in category 'accessing') ----- + next: n into: aCollection startingAt: startIndex + "Read n objects into the given collection. + Return aCollection or a partial copy if less than n elements have been read." + + | count | + count := self readInto: aCollection startingAt: startIndex count: n. + count = n + ifTrue:[ ^aCollection ] + ifFalse:[ ^aCollection copyFrom: 1 to: startIndex + count - 1 ]! Item was added: + ----- Method: Stream>>nextInto: (in category 'accessing') ----- + nextInto: aCollection + "Read the next elements of the receiver into aCollection. + Return aCollection or a partial copy if less than aCollection + size elements have been read." + ^self next: aCollection size into: aCollection startingAt: 1.! Item was added: + ----- Method: Stream>>nextInto:startingAt: (in category 'accessing') ----- + nextInto: aCollection startingAt: startIndex + "Read the next elements of the receiver into aCollection. + Return aCollection or a partial copy if less than aCollection + size elements have been read." + ^self next: (aCollection size - startIndex+1) into: aCollection startingAt: startIndex.! Item was added: + ----- Method: Stream>>readInto:startingAt:count: (in category 'accessing') ----- + readInto: aCollection startingAt: startIndex count: n + "Read n objects into the given collection. + Return number of elements that have been read." + | obj | + 0 to: n - 1 do: [:i | + (obj := self next) == nil ifTrue: [^i]. + aCollection at: startIndex + i put: obj]. + ^n! Item was added: + ----- Method: WeakArray>>species (in category 'as yet unclassified') ----- + species + "More useful to have strongly-referenced results of #select: and #collect:." + ^ Array! From commits at source.squeak.org Fri Apr 3 20:26:36 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 20:26:39 2015 Subject: [squeak-dev] The Trunk: Collections-cmm.608.mcz Message-ID: Chris Muller uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections-cmm.608.mcz ==================== Summary ==================== Name: Collections-cmm.608 Author: cmm Time: 3 April 2015, 3:26:16.674 pm UUID: ff08c5f7-9d9e-4d4f-99e1-b5e52118e9fb Ancestors: Collections-ul.607, Collections-cmm.603 Merged cmm.603. =============== Diff against Collections-ul.607 =============== Item was changed: ----- Method: Collection>>groupBy:having: (in category 'enumerating') ----- groupBy: keyBlock having: selectBlock + "Like in SQL operation - Split the recievers contents into collections of elements for which keyBlock returns the same results, and return those collections allowed by selectBlock." - "Like in SQL operation - Split the recievers contents into collections of - elements for which keyBlock returns the same results, and return those - collections allowed by selectBlock. keyBlock should return an Integer." | result | + result := Dictionary new. + self do: + [ : each | | key | + key := keyBlock value: each. + (result + at: key + ifAbsentPut: [ OrderedCollection new ]) add: each ]. + ^ result select: selectBlock! - result := PluggableDictionary integerDictionary. - self do: - [:e | - | key | - key := keyBlock value: e. - (result includesKey: key) - ifFalse: [result at: key put: OrderedCollection new]. - (result at: key) - add: e]. - ^result select: selectBlock! Item was removed: - ----- Method: NullStream>>next:into: (in category 'reading') ----- - next: n into: aCollection - "Read n objects into the given collection. - Return aCollection or a partial copy if less than - n elements have been read." - - ^self next: n into: aCollection startingAt: 1! Item was removed: - ----- Method: NullStream>>nextInto:startingAt: (in category 'reading') ----- - nextInto: aCollection startingAt: startIndex - "Read the next elements of the receiver into aCollection. - Return aCollection or a partial copy if less than aCollection - size elements have been read." - - ^self next: (aCollection size - startIndex+1) into: aCollection startingAt: startIndex.! Item was removed: - ----- Method: PositionableStream>>next:into: (in category 'accessing') ----- - next: n into: aCollection - "Read n objects into the given collection. - Return aCollection or a partial copy if less than - n elements have been read." - ^self next: n into: aCollection startingAt: 1! Item was removed: - ----- Method: PositionableStream>>next:into:startingAt: (in category 'accessing') ----- - next: n into: aCollection startingAt: startIndex - "Read n objects into the given collection. - Return aCollection or a partial copy if less than n elements have been read." - - | count | - count := self readInto: aCollection startingAt: startIndex count: n. - count = n - ifTrue:[ ^aCollection ] - ifFalse:[ ^aCollection copyFrom: 1 to: startIndex + count - 1 ]! Item was removed: - ----- Method: PositionableStream>>nextInto: (in category 'accessing') ----- - nextInto: aCollection - "Read the next elements of the receiver into aCollection. - Return aCollection or a partial copy if less than aCollection - size elements have been read." - ^self next: aCollection size into: aCollection startingAt: 1.! Item was removed: - ----- Method: PositionableStream>>nextInto:startingAt: (in category 'accessing') ----- - nextInto: aCollection startingAt: startIndex - "Read the next elements of the receiver into aCollection. - Return aCollection or a partial copy if less than aCollection - size elements have been read." - ^self next: (aCollection size - startIndex+1) into: aCollection startingAt: startIndex.! Item was removed: - ----- Method: PositionableStream>>readInto:startingAt:count: (in category 'accessing') ----- - readInto: aCollection startingAt: startIndex count: n - "Read n objects into the given collection. - Return number of elements that have been read." - | obj | - 0 to: n - 1 do: [:i | - (obj := self next) == nil ifTrue: [^i]. - aCollection at: startIndex + i put: obj]. - ^n! Item was added: + ----- Method: Stream>>next:into: (in category 'accessing') ----- + next: n into: aCollection + "Read n objects into the given collection. + Return aCollection or a partial copy if less than + n elements have been read." + ^self next: n into: aCollection startingAt: 1! Item was added: + ----- Method: Stream>>next:into:startingAt: (in category 'accessing') ----- + next: n into: aCollection startingAt: startIndex + "Read n objects into the given collection. + Return aCollection or a partial copy if less than n elements have been read." + + | count | + count := self readInto: aCollection startingAt: startIndex count: n. + count = n + ifTrue:[ ^aCollection ] + ifFalse:[ ^aCollection copyFrom: 1 to: startIndex + count - 1 ]! Item was added: + ----- Method: Stream>>nextInto: (in category 'accessing') ----- + nextInto: aCollection + "Read the next elements of the receiver into aCollection. + Return aCollection or a partial copy if less than aCollection + size elements have been read." + ^self next: aCollection size into: aCollection startingAt: 1.! Item was added: + ----- Method: Stream>>nextInto:startingAt: (in category 'accessing') ----- + nextInto: aCollection startingAt: startIndex + "Read the next elements of the receiver into aCollection. + Return aCollection or a partial copy if less than aCollection + size elements have been read." + ^self next: (aCollection size - startIndex+1) into: aCollection startingAt: startIndex.! Item was added: + ----- Method: Stream>>readInto:startingAt:count: (in category 'accessing') ----- + readInto: aCollection startingAt: startIndex count: n + "Read n objects into the given collection. + Return number of elements that have been read." + | obj | + 0 to: n - 1 do: [:i | + (obj := self next) == nil ifTrue: [^i]. + aCollection at: startIndex + i put: obj]. + ^n! Item was added: + ----- Method: WeakArray>>species (in category 'as yet unclassified') ----- + species + "More useful to have strongly-referenced results of #select: and #collect:." + ^ Array! Item was removed: - ----- Method: WeakKeyDictionary>>finalizeValues: (in category 'finalization') ----- - finalizeValues: finiObjects - "Remove all associations with key == nil and value is in finiObjects. - This method is folded with #rehash for efficiency." - - | oldArray | - self deprecated: 'The finalization logic changed, this method shouldn''t be called anymore.'. - oldArray := array. - array := Array new: oldArray size. - tally := 0. - 1 to: array size do: [ :index | - (oldArray at: index) ifNotNil: [ :association | - association key ifNotNil: [ :key | "Don't let the key go away" - (finiObjects includes: association value) ifFalse: [ - array - at: (self scanForEmptySlotFor: key) - put: association. - tally := tally + 1 ] ] ] ]! From karlramberg at gmail.com Fri Apr 3 20:42:03 2015 From: karlramberg at gmail.com (karl ramberg) Date: Fri Apr 3 20:42:07 2015 Subject: [squeak-dev] Two bugs with SystemWindow Message-ID: Skipped content of type multipart/alternative-------------- next part -------------- A non-text attachment was scrubbed... Name: splitterBug.jpg Type: image/jpeg Size: 15001 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150403/7ca6b5e7/splitterBug.jpg From asqueaker at gmail.com Fri Apr 3 21:21:03 2015 From: asqueaker at gmail.com (Chris Muller) Date: Fri Apr 3 21:21:05 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.810.mcz In-Reply-To: <1428043181035-4817128.post@n4.nabble.com> References: <1428043181035-4817128.post@n4.nabble.com> Message-ID: On Fri, Apr 3, 2015 at 1:39 AM, Marcel Taeumel wrote: > Well, it is now consistent with how inspectors are openend via the halo. ;) I > find this quite convenient because the RealEstateManager places new windows > in a strange way and I always have to look for them on my 27" monitor. :D Well, that is a problem you already have -- it is not the fault of Reuse Windows. :) Opening windows in the hand is the wrong solution. There should be a hot-key which will emphasize the window with focus on the desktop. Either #flash it or darken all the other windows briefly.. We had a discussion about this a while back (search archives for "Morphic-cmm.728"). I submitted a Inbox proposal to #flash a window after it was topped by the Reuse Windows preference but failed to convince this community to adopt it. :( PS -- I just saw your fix. That is much better thanks but I still think opening in the hand is wrong. Someday we should make this consistent and fix your big monitor problem a different way. :) From asqueaker at gmail.com Fri Apr 3 21:32:42 2015 From: asqueaker at gmail.com (Chris Muller) Date: Fri Apr 3 21:32:45 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: <1428080178583-4817382.post@n4.nabble.com> References: <1428075270847-4817347.post@n4.nabble.com> <1428080178583-4817382.post@n4.nabble.com> Message-ID: On Fri, Apr 3, 2015 at 11:56 AM, Marcel Taeumel wrote: > And could we turn of the seconds of the clock in the main docking bar?^^ Please no! They are very useful for 1) knowing at a glance when the system is done with a computatoin and 2) crude eye-ball timing. Those seconds are waaaaay up there in the corner of your massive, 27" monitor, if you can't even find ObjectExplorers opening up on your desktop then those seconds moving is not going to bother you.. :-) From commits at source.squeak.org Fri Apr 3 21:55:03 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 21:55:04 2015 Subject: [squeak-dev] Daily Commit Log Message-ID: <20150403215503.31297.qmail@box4.squeakfoundation.org> Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours: http://lists.squeakfoundation.org/pipermail/packages/2015-April/007792.html Name: EToys-topa.121 Ancestors: EToys-topa.120 As Etoys is not _per se_ dependent on Sound, be graceful about its presence in Etoys' tests. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007793.html Name: Morphic-mt.813 Ancestors: Morphic-mt.812 Added preference for updating the current selection on option/menu click to compensate misplaced mouse cursors. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007794.html Name: Morphic-mt.814 Ancestors: Morphic-mt.813 Fixed hovered-row state in lists when losing keyboard focus, e.g., when invoking a context menu. Otherwise this may be confusing if the current selection is not updated but the hovered row still indicated. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007795.html Name: Morphic-mt.815 Ancestors: Morphic-mt.814 Fixed open-in-world behavior for system windows to return the opened window if the reuse-windows preference changed that. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007796.html Name: ToolBuilder-Morphic-mt.117 Ancestors: ToolBuilder-Morphic-mt.116 The morphic tool builder now honors the reuse-windows preference because #open: will now return the actually opened window. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007797.html Name: System-mt.716 Ancestors: System-topa.715 Refactored window color handling. Added a #normalColor to the specs because I will remove the #duller-hack from SystemWindow and this ensures that users will not be overwhelmed by bright colors. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007798.html Name: Tools-mt.577 Ancestors: Tools-mt.576 Updated to load normal window colors for new tool sets as introduced by System-mt.716 ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007799.html Name: Morphic-mt.816 Ancestors: Morphic-mt.815 Removed #duller-hack from SystemWindow and thus extended main docking bar to offer "normal window colors", which are the old bright ones but duller. Please use the "Extras -> Window Colors"-menu if this update messes up your colors, i.e., makes them too bright. Note: The small icons in the Tools menu may now also appear darker than usual, which is correct, because they represent the actual window color. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007800.html Name: System.spur-mt.716 Ancestors: System-mt.716, System.spur-topa.715 System-mt.716 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.256 Refactored window color handling. Added a #normalColor to the specs because I will remove the #duller-hack from SystemWindow and this ensures that users will not be overwhelmed by bright colors. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007801.html Name: Morphic-mt.817 Ancestors: Morphic-mt.816 Color handling in system windows cleaned-up and fixed. #adoptPaneColor: will now be sent to all panes on activate/passivate to give them a chance to also "look inactive". ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007802.html Name: Morphic-mt.818 Ancestors: Morphic-mt.817 Scroll bars and scroll panes now update their border colors when asked for adopting a system window's pane color. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007803.html Name: Morphic-mt.819 Ancestors: Morphic-mt.818 Fixed window color refreshing when changing the global color scheme. Now, it honors the #isActive state of all open windows. Additionally, we do not send #adoptPaneColor: with nil anymore to all our submorphs... ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007804.html Name: MorphicExtras-mt.159 Ancestors: MorphicExtras-mt.158 Clock morph now shows the current date in the balloon text. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007805.html Name: TrueType-topa.36 Ancestors: TrueType-cmm.35 cope for the fact that typographicAscender and typographicDescender may not be available and 0-height fonts are a bit useless ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007806.html Name: TrueType-topa.37 Ancestors: TrueType-topa.36 React to dpi changes ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007807.html Name: TrueType-topa.38 Ancestors: TrueType-topa.37 As TTFileDescription as TTFontDescription ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007808.html Name: ToolsTests-mt.71 Ancestors: ToolsTests-bf.70 Fixed #tearDown in MessageNamesTest because it will only work if tests did not close the topView already. This happes, for example, if reuse-windows preference is enabled. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007809.html Name: Collections-cmm.603 Ancestors: Collections-mt.602 - Collection>>#groupBy:having: is already being used for non-Integer groups, and integerDictionary is now slower than a regular Dictionary in Spur. - PositionableStream>>#nextInto:, #next:into:, #nextInto:startingAt:, #next:into:startingAt:, and #readInto:startingAt:count require no services specific to PositionableStream. Move them up to Stream and remove the redundant implementations from various subclasses. - Let WeakArray>>#species be a regular Array instead of its own class, so that WeakArray's can be successfully compared to Arrays with equivalent contents. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007810.html Name: Collections-cmm.608 Ancestors: Collections-ul.607, Collections-cmm.603 Merged cmm.603. ============================================= From commits at source.squeak.org Fri Apr 3 22:08:10 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 22:08:11 2015 Subject: [squeak-dev] The Inbox: Tools-kfr.578.mcz Message-ID: A new version of Tools was added to project The Inbox: http://source.squeak.org/inbox/Tools-kfr.578.mcz ==================== Summary ==================== Name: Tools-kfr.578 Author: kfr Time: 4 April 2015, 12:05:38.061 am UUID: 35e26aef-3dbf-a64a-9c66-374aa0f16491 Ancestors: Tools-mt.577 Search field need menu for basic mouse actions. Maybe overkill with the full code pane menu =============== Diff against Tools-mt.577 =============== Item was changed: ----- Method: MessageNames>>buildSearchPaneWith: (in category 'toolbuilder') ----- buildSearchPaneWith: builder | textSpec | textSpec := builder pluggableInputFieldSpec new. textSpec model: self; name: #search; getText: #searchString; + setText: #searchString:notifying:; + menu: #codePaneMenu:shifted:. + ^textSpec! - setText: #searchString:notifying:. - ^textSpec! From commits at source.squeak.org Fri Apr 3 22:49:34 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 3 22:49:37 2015 Subject: [squeak-dev] The Inbox: ShoutCore-cmm.44.mcz Message-ID: A new version of ShoutCore was added to project The Inbox: http://source.squeak.org/inbox/ShoutCore-cmm.44.mcz ==================== Summary ==================== Name: ShoutCore-cmm.44 Author: cmm Time: 3 April 2015, 5:49:33.369 pm UUID: 333bfec3-3a83-4de7-ae92-1ab3592f67a6 Ancestors: ShoutCore-eem.43 Proposal for update of the default Shout colors. - Bold black for Atomics (true, false, nil, self, super) Rationale: Bedrock. Plus, easy to tell if a method is a "utility method" at a glance. - Regular black for Globals; the next level above the bedrock (where all coding starts from). - Green for Messages, because messages make the system go and green means go. (Exception: binary messages are black for aesthetics and to visually isolate the expressions either side of it). - Light gray for comments so they are unobtrusive to the code, yet still very present like the "help text" we're now seeing in the Search bar and ObjectExplorer. - Red for Literals, because hard-coding things is "bad" and red means stop. :) But red actually makes it easy to spot literals in any method. - Brick (brown) for Method and block arguments because they cannot be stored into and bricks are solid and hard. - Aqua blue for temp vars because they're malleable like water; e.g., they CAN be stored into. - Gold for inst vars. Gold because they are the "resources" the object has available send messages to. - Magenta for undefined's and bad syntax because such a thing should be bright and noticeable. It's also ugly therefore the most appropriate color to represent problems. :) =============== Diff against ShoutCore-eem.43 =============== Item was changed: ----- Method: SHTextStylerST80 class>>defaultStyleTable (in category 'style table') ----- defaultStyleTable "color can be a valid argument to Color class>>colorFrom: , or nil to use the editor text color. Multiple emphases can be specified using an array e.g. #(bold italic). If emphasis is not specified, #normal will be used. if pixel height is not specified , then the editor font size will be used. " ^#( "(symbol color [emphasisSymbolOrArray [textStyleName [pixelHeight]]])" (default black ) + (invalid (magenta twiceDarker) ) + (excessCode (magenta twiceDarker) ) + (comment (gray) italic) + (unfinishedComment (gray) italic) + (#'$' (black) ) + (character (red twiceDarker ) ) + (integer (red twiceDarker ) ) + (number (red twiceDarker ) ) + (#- (black) ) + (symbol (black ) ) + (stringSymbol (black ) ) + (literalArray (black ) ) + (string (red twiceDarker) normal ) - (invalid red ) - (excessCode red ) - (comment (green muchDarker) italic) - (unfinishedComment (red muchDarker) italic) - (#'$' (red muchDarker) ) - (character (red muchDarker) ) - (integer (red muchDarker) ) - (number (red muchDarker) ) - (#- (red muchDarker) ) - (symbol (blue muchDarker) bold) - (stringSymbol (blue muchDarker) bold) - (literalArray (blue muchDarker) bold) - (string (magenta muchDarker) normal) (unfinishedString red normal ) + (assignment black bold ) + (ansiAssignment black bold) + (literal (red twiceDarker) italic) + (keyword (green muchDarker) ) + (binary (black ) (bold)) + (unary (green muchDarker ) ) + (incompleteKeyword (green darker) underlined) + (incompleteBinary (green darker) underlined) + (incompleteUnary (green darker) underlined) + (undefinedKeyword (magenta twiceDarker) ) + (undefinedBinary (magenta twiceDarker) ) + (undefinedUnary (magenta twiceDarker) ) + (patternKeyword (green muchDarker) (underlined bold)) + (patternBinary (green muchDarker) (bold)) + (patternUnary (green muchDarker) (underlined bold)) + (#self (black) bold) + (#super (black) bold) + (#true (black) bold) + (#false (black) bold) + (#nil (black) bold) + (#thisContext (black) bold) + (#return (black) bold) + (patternArg (orange muchDarker) ) + (methodArg (orange muchDarker) ) + (blockPatternArg (orange muchDarker) ) + (blockArg (orange muchDarker) ) + (argument (orange muchDarker) ) - (assignment nil bold ) - (ansiAssignment nil bold) - (literal nil italic) - (keyword (blue muchDarker) ) - (binary (blue muchDarker) ) - (unary (blue muchDarker) ) - (incompleteKeyword (gray muchDarker) underlined) - (incompleteBinary (gray muchDarker) underlined) - (incompleteUnary (gray muchDarker) underlined) - (undefinedKeyword red ) - (undefinedBinary red ) - (undefinedUnary red ) - (patternKeyword nil bold) - (patternBinary nil bold) - (patternUnary nil bold) - (#self (red muchDarker) bold) - (#super (red muchDarker) bold) - (#true (red muchDarker) bold) - (#false (red muchDarker) bold) - (#nil (red muchDarker) bold) - (#thisContext (red muchDarker) bold) - (#return (red muchDarker) bold) - (patternArg (blue muchDarker) italic) - (methodArg (blue muchDarker) italic) - (blockPatternArg (blue muchDarker) italic) - (blockArg (blue muchDarker) italic) - (argument (blue muchDarker) italic) (blockArgColon black ) (leftParenthesis black ) (rightParenthesis black ) + (leftParenthesis1 (black) ) + (rightParenthesis1 (black) ) + (leftParenthesis2 (gray twiceDarker) ) + (rightParenthesis2 (gray twiceDarker) ) + (leftParenthesis3 (blue twiceDarker) ) + (rightParenthesis3 (blue twiceDarker) ) + (leftParenthesis4 (green twiceDarker) ) + (rightParenthesis4 (green twiceDarker) ) + (leftParenthesis5 (orange twiceDarker) ) + (rightParenthesis5 (orange twiceDarker) ) + (leftParenthesis6 (red twiceDarker) ) + (rightParenthesis6 (red twiceDarker) ) + (leftParenthesis7 brown ) + (rightParenthesis7 brown ) - (leftParenthesis1 (green muchDarker) ) - (rightParenthesis1 (green muchDarker) ) - (leftParenthesis2 (magenta muchDarker) ) - (rightParenthesis2 (magenta muchDarker) ) - (leftParenthesis3 (red muchDarker) ) - (rightParenthesis3 (red muchDarker) ) - (leftParenthesis4 (green darker) ) - (rightParenthesis4 (green darker) ) - (leftParenthesis5 (orange darker) ) - (rightParenthesis5 (orange darker) ) - (leftParenthesis6 (magenta darker) ) - (rightParenthesis6 (magenta darker) ) - (leftParenthesis7 blue ) - (rightParenthesis7 blue ) (blockStart black ) (blockEnd black ) + (blockStart1 (black) ) + (blockEnd1 (black) ) + (blockStart2 (gray twiceDarker) ) + (blockEnd2 (gray twiceDarker) ) + (blockStart3 (blue twiceDarker) ) + (blockEnd3 (blue twiceDarker) ) + (blockStart4 (green twiceDarker) ) + (blockEnd4 (green twiceDarker) ) + (blockStart5 (orange twiceDarker) ) + (blockEnd5 (orange twiceDarker) ) + (blockStart6 (red twiceDarker) ) + (blockEnd6 (red twiceDarker) ) + (blockStart7 (brown) ) + (blockEnd7 (brown) ) - (blockStart1 (green muchDarker) ) - (blockEnd1 (green muchDarker) ) - (blockStart2 (magenta muchDarker) ) - (blockEnd2 (magenta muchDarker) ) - (blockStart3 (red muchDarker) ) - (blockEnd3 (red muchDarker) ) - (blockStart4 (green darker) ) - (blockEnd4 (green darker) ) - (blockStart5 (orange darker) ) - (blockEnd5 (orange darker) ) - (blockStart6 (magenta darker) ) - (blockEnd6 (magenta darker) ) - (blockStart7 blue ) - (blockEnd7 blue ) (arrayStart black ) (arrayEnd black ) (arrayStart1 black ) (arrayEnd1 black ) + (byteArrayStart black ) + (byteArrayEnd black ) + (byteArrayStart1 black ) + (byteArrayEnd1 black ) - (byteArrayStart black ) - (byteArrayEnd black ) - (byteArrayStart1 black ) - (byteArrayEnd1 black ) (leftBrace black ) (rightBrace black ) (cascadeSeparator black ) (statementSeparator black ) (externalCallType black ) (externalCallTypePointerIndicator black ) + (primitiveOrExternalCallStart black ) + (primitiveOrExternalCallEnd black ) + (methodTempBar black ) + (blockTempBar black ) + (blockArgsBar black ) - (primitiveOrExternalCallStart black bold ) - (primitiveOrExternalCallEnd black bold ) - (methodTempBar gray ) - (blockTempBar gray ) - (blockArgsBar gray ) (primitive (green muchDarker) bold) - (pragmaKeyword (green muchDarker) bold) - (pragmaUnary (green muchDarker) bold) - (pragmaBinary (green muchDarker) bold) (externalFunctionCallingConvention (green muchDarker) bold) (module (green muchDarker) bold) + (blockTempVar (cyan muchDarker ) italic) + (blockPatternTempVar (cyan muchDarker ) italic) + (instVar (yellow twiceDarker darker) bold) - (blockTempVar gray italic) - (blockPatternTempVar gray italic) - (instVar black bold) (workspaceVar black bold) + (undefinedIdentifier (magenta twiceDarker) normal) + (incompleteIdentifier (gray darker) (italic underlined)) + (tempVar (cyan muchDarker) italic) + (patternTempVar (cyan muchDarker) italic) + (poolConstant (blue lighter) italic) + (classVar (blue twiceLighter) italic) + (globalVar black normal) ) + ! - (undefinedIdentifier red bold) - (incompleteIdentifier (gray darker) (italic underlined)) - (tempVar (gray darker) italic) - (patternTempVar (gray darker) italic) - (poolConstant (gray darker) italic) - (classVar (gray darker) bold) - (globalVar black bold) ) - ! From Das.Linux at gmx.de Sat Apr 4 06:39:56 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Sat Apr 4 06:40:02 2015 Subject: [squeak-dev] The Inbox: Tools-kfr.578.mcz Message-ID: <07D6EECE-2B7B-4093-90BE-61E20909C1D1@gmx.de> +1 On 03.04.2015, at 22:08, commits@source.squeak.org wrote: > A new version of Tools was added to project The Inbox: > http://source.squeak.org/inbox/Tools-kfr.578.mcz > > ==================== Summary ==================== > > Name: Tools-kfr.578 > Author: kfr > Time: 4 April 2015, 12:05:38.061 am > UUID: 35e26aef-3dbf-a64a-9c66-374aa0f16491 > Ancestors: Tools-mt.577 > > Search field need menu for basic mouse actions. Maybe overkill with the full code pane menu > > =============== Diff against Tools-mt.577 =============== > > Item was changed: From marcel.taeumel at student.hpi.uni-potsdam.de Sat Apr 4 07:38:07 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sat Apr 4 07:50:08 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.810.mcz In-Reply-To: References: <1428043181035-4817128.post@n4.nabble.com> Message-ID: <1428133087994-4817464.post@n4.nabble.com> Hey Chris, opening the window in the hand is really nice if it already was a mouse interaction. That reuse-windows preference is younger -- I guess -- and now we need some trade-off here. In my opinion, all moues-based tool-openers should be attached to the hand because that is were the user looks at the moment anyway. However, the window positioning needs some kind of re-design anyway. :) Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-810-mcz-tp4816858p4817464.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sat Apr 4 07:38:56 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sat Apr 4 07:50:58 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.810.mcz In-Reply-To: <1428133087994-4817464.post@n4.nabble.com> References: <1428043181035-4817128.post@n4.nabble.com> <1428133087994-4817464.post@n4.nabble.com> Message-ID: <1428133136253-4817465.post@n4.nabble.com> I guess your #flash implementation included a Delay?^^ Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-810-mcz-tp4816858p4817465.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sat Apr 4 07:40:09 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sat Apr 4 07:52:10 2015 Subject: [squeak-dev] Re: The Inbox: ShoutCore-cmm.44.mcz In-Reply-To: References: Message-ID: <1428133209157-4817466.post@n4.nabble.com> We could add it to preferences (maybe similar to window color specs) and make if configurable and not hidden at the code level. Best, Marcel -- View this message in context: http://forum.world.st/The-Inbox-ShoutCore-cmm-44-mcz-tp4817440p4817466.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sat Apr 4 07:40:58 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sat Apr 4 07:52:58 2015 Subject: [squeak-dev] Re: The Inbox: Tools-kfr.578.mcz In-Reply-To: References: Message-ID: <1428133258272-4817467.post@n4.nabble.com> +1 Best, Marcel -- View this message in context: http://forum.world.st/The-Inbox-Tools-kfr-578-mcz-tp4817438p4817467.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sat Apr 4 07:45:58 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sat Apr 4 07:57:57 2015 Subject: [squeak-dev] Re: Two bugs with SystemWindow In-Reply-To: References: Message-ID: <1428133558074-4817468.post@n4.nabble.com> Hey Karl, 1. Vertical Splitter too height -> Confirmed. 2. Window move/resize inconsistency -> Not confirmed here. As soon as the cursor changes, you can resize the window along the top edge. This is only a few pixels. The whole label (text) lets you drag/move the window. Maybe this is more extreme in your image configuration. As you are right: top grip overlaps with the label area. Hmmm.... Best, Marcel -- View this message in context: http://forum.world.st/Two-bugs-with-SystemWindow-tp4817430p4817468.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sat Apr 4 07:49:58 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sat Apr 4 08:01:58 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.810.mcz In-Reply-To: <1428133087994-4817464.post@n4.nabble.com> References: <1428043181035-4817128.post@n4.nabble.com> <1428133087994-4817464.post@n4.nabble.com> Message-ID: <1428133798021-4817469.post@n4.nabble.com> We could check for mouse interaction with "self activeEvent isMouse ifTrue: []" :) maybe in ToolSet or the open-methods of SystemWindow/Morph. ...we could make it a preference. ;) Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-810-mcz-tp4816858p4817469.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From herbertkoenig at gmx.net Sat Apr 4 08:29:53 2015 From: herbertkoenig at gmx.net (=?UTF-8?B?SGVyYmVydCBLw7ZuaWc=?=) Date: Sat Apr 4 08:29:55 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: References: <1428075270847-4817347.post@n4.nabble.com> <1428080178583-4817382.post@n4.nabble.com> Message-ID: <551FA101.10608@gmx.net> Hi, >> And could we turn of the seconds of the clock in the main docking bar?^^ > Please no! They are very useful for 1) knowing at a glance when the > system is done with a computatoin and 2) crude eye-ball timing. same here. Herbert From marcel.taeumel at student.hpi.uni-potsdam.de Sat Apr 4 09:41:41 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sat Apr 4 09:53:42 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: References: <1428075270847-4817347.post@n4.nabble.com> <1428080178583-4817382.post@n4.nabble.com> Message-ID: <1428140501554-4817477.post@n4.nabble.com> Ah, nice scenario! Didn't think of that one. ...hey! Buy youself a bigger monitor! :P Speaking of that: For which resolution do we want to optimize Squeak? 800x600? 1024x768? :) Best, Marcel -- View this message in context: http://forum.world.st/A-plan-for-the-release-tp4817346p4817477.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Sat Apr 4 10:45:19 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 4 10:45:23 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.820.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.820.mcz ==================== Summary ==================== Name: Morphic-mt.820 Author: mt Time: 4 April 2015, 12:44:21.429 pm UUID: abb68373-3e37-734f-a528-ed654f66943a Ancestors: Morphic-mt.819 Added missing #duller to system window colors if there are gradients used. Looks not so bright anymore as the gradient itself starts with white. =============== Diff against Morphic-mt.819 =============== Item was added: + ----- Method: SystemWindow>>adoptPaneColor: (in category 'colors handling') ----- + adoptPaneColor: aPaneColor + + super adoptPaneColor: (self class gradientWindow + ifTrue: [aPaneColor duller] + ifFalse: [aPaneColor]).! Item was changed: ----- Method: SystemWindow>>gradientWithColor: (in category 'colors handling') ----- gradientWithColor: aColor | gradient | gradient := GradientFillStyle ramp: { 0.0 -> Color white. + 0.2 -> (aColor duller mixed: 0.5 with: (Color gray: 0.9)) lighter. + 1.0 -> aColor duller. - 0.2 -> (aColor mixed: 0.5 with: (Color gray: 0.9)) lighter. - 1.0 -> aColor. }. gradient origin: self topLeft. gradient direction: 0 @ self labelHeight. ^gradient! Item was changed: ----- Method: SystemWindow>>paneColorToUseWhenNotActive (in category 'colors handling') ----- paneColorToUseWhenNotActive + ^ self paneColorToUse darker! - ^ (SystemWindow gradientWindow - ifTrue: [self paneColorToUse duller darker] - ifFalse: [self paneColorToUse darker])! Item was changed: ----- Method: SystemWindow>>setStripeColorsFrom: (in category 'colors handling') ----- setStripeColorsFrom: paneColor "Set the stripe color based on the given paneColor" labelArea ifNotNil: [labelArea color: Color transparent]. self updateBoxesColor: paneColor. stripes ifNil: [^self]. self borderColor: paneColor muchDarker. + self class gradientWindow - SystemWindow gradientWindow ifTrue: [self fillStyle: (self gradientWithColor: paneColor)] ifFalse: [self color: paneColor].! From commits at source.squeak.org Sat Apr 4 10:48:35 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 4 10:48:36 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.821.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.821.mcz ==================== Summary ==================== Name: Morphic-mt.821 Author: mt Time: 4 April 2015, 12:46:52.633 pm UUID: cd5ac07c-7925-904f-ae85-07acb41cf7a3 Ancestors: Morphic-mt.820 Added nil-check to color adoption in system window. (Note: We have to get rid of those color-to-nil settings...) =============== Diff against Morphic-mt.820 =============== Item was changed: ----- Method: SystemWindow>>adoptPaneColor: (in category 'colors handling') ----- adoptPaneColor: aPaneColor super adoptPaneColor: (self class gradientWindow + ifTrue: [aPaneColor ifNotNil: [:c | c duller]] + ifFalse: [aPaneColor ifNotNil: [:c | c duller]]).! - ifTrue: [aPaneColor duller] - ifFalse: [aPaneColor]).! From commits at source.squeak.org Sat Apr 4 10:58:34 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 4 10:58:36 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.822.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.822.mcz ==================== Summary ==================== Name: Morphic-mt.822 Author: mt Time: 4 April 2015, 12:58:00.349 pm UUID: c387b3d5-2f71-704a-817e-0d8e4b59c609 Ancestors: Morphic-mt.821 ...non-gradient windows do not get the #duller-Adaptation for their sub-panes... =============== Diff against Morphic-mt.821 =============== Item was changed: ----- Method: SystemWindow>>adoptPaneColor: (in category 'colors handling') ----- adoptPaneColor: aPaneColor super adoptPaneColor: (self class gradientWindow ifTrue: [aPaneColor ifNotNil: [:c | c duller]] + ifFalse: [aPaneColor]).! - ifFalse: [aPaneColor ifNotNil: [:c | c duller]]).! From commits at source.squeak.org Sat Apr 4 11:07:23 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 4 11:07:24 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.823.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.823.mcz ==================== Summary ==================== Name: Morphic-mt.823 Author: mt Time: 4 April 2015, 1:06:28.001 pm UUID: 2a9f2a6f-7774-8a46-9344-1d390155d562 Ancestors: Morphic-mt.822 Update all open windows' colors if the prefrence "gradient windows" is changed. =============== Diff against Morphic-mt.822 =============== Item was changed: ----- Method: SystemWindow class>>gradientWindow: (in category 'preferences') ----- gradientWindow: aBoolean + aBoolean = GradientWindow ifTrue: [^ self]. + GradientWindow := aBoolean. + self refreshAllWindows.! - GradientWindow := aBoolean.! Item was added: + ----- Method: SystemWindow class>>refreshAllWindows (in category 'initializing') ----- + refreshAllWindows + "If there is some prominent UI change, use this method to update all open windows." + + SystemWindow allSubInstances do: [:w | w refreshWindowColor].! From commits at source.squeak.org Sat Apr 4 11:09:49 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 4 11:09:50 2015 Subject: [squeak-dev] The Trunk: System-mt.717.mcz Message-ID: Marcel Taeumel uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System-mt.717.mcz ==================== Summary ==================== Name: System-mt.717 Author: mt Time: 4 April 2015, 1:09:08.74 pm UUID: 36f8a140-a98f-a94a-9d2c-fd0851828baf Ancestors: System-mt.716 Use general window-update function when changing window colors. =============== Diff against System-mt.716 =============== Item was changed: ----- Method: Preferences class>>installWindowColorsVia: (in category 'window colors') ----- installWindowColorsVia: colorSpecBlock "Install windows colors using colorSpecBlock to deliver the color source for each element; the block is handed a WindowColorSpec object" "Preferences installBrightWindowColors" WindowColorRegistry refresh. self windowColorTable do: [:aColorSpec | | color | color := (Color colorFrom: (colorSpecBlock value: aColorSpec)). self setWindowColorFor: aColorSpec classSymbol to: color]. + SystemWindow refreshAllWindows. + TheWorldMainDockingBar updateInstances.! - SystemWindow withAllSubclasses do: [:c | - c allInstances do: [:w | w refreshWindowColor]]. - TheWorldMainDockingBar updateInstances - ! From marcel.taeumel at student.hpi.uni-potsdam.de Sat Apr 4 11:13:59 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sat Apr 4 11:26:03 2015 Subject: [squeak-dev] A note on current window colors in Trunk Message-ID: <1428146039598-4817485.post@n4.nabble.com> Hi, there! If you are experience too-bright window colors, please fiddle around with "Extras -> Window Colors" menu in the main docking bar. There, you should find 4 entries: gray, colorful, bright, pastel. I cannot give you migration code as I cannot know, which color scheme you are currently using. But there has to be a rebuild of some internal caches... *sigh* Sorry, for being so inconvenient... ;-) Best, Marcel -- View this message in context: http://forum.world.st/A-note-on-current-window-colors-in-Trunk-tp4817485.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sat Apr 4 11:43:41 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sat Apr 4 11:55:44 2015 Subject: [squeak-dev] How to draw nice and fast window shadows? Message-ID: <1428147821624-4817491.post@n4.nabble.com> Hey, there! ...coming from here: http://forum.world.st/Hi-DPI-Check-tp4817402.html Is there some algorithmic guru out there, who knows or could imagine how to draw nice-looking window shadows in Squeak? My two cents: Shadow drawing is expensive... caching is inevitable... window resizing would slow down anyway... Why am I asking this? We should/could get rid of all system windows having this small shadow but think about how to highlight the currently active window better with a nice shadow like this: http://www.creativetechs.com/iq/clean_up_shadows_in_leopard_screenshots.html http://www.howtogeek.com/121834/how-to-re-enable-the-mouse-pointer-drop-shadow-in-windows-8/ ..hmmm... would this be a "killer application" for thinking about HW graphics acceleration in Squeak? :-D Best, Marcel -- View this message in context: http://forum.world.st/How-to-draw-nice-and-fast-window-shadows-tp4817491.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sat Apr 4 12:29:23 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sat Apr 4 12:41:25 2015 Subject: [squeak-dev] Re: How to draw nice and fast window shadows? In-Reply-To: <1428147821624-4817491.post@n4.nabble.com> References: <1428147821624-4817491.post@n4.nabble.com> Message-ID: <1428150563164-4817499.post@n4.nabble.com> I did a quick spike to give a better idea of what I am talking about. 1) Here is the code: better-shadow.cs 2) Here are some pictures: new-shadows-1.png new-shadows-2.png I decided to always have rounded shadows -- even for rectangular windows/menus. Do we want to have this with a preference in trunk? Best, Marcel P.S.: Yes, resizing large (> 1000 pixels) windows gets slow on my Core i7. :-D -- View this message in context: http://forum.world.st/How-to-draw-nice-and-fast-window-shadows-tp4817491p4817499.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sat Apr 4 12:35:26 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sat Apr 4 12:47:27 2015 Subject: [squeak-dev] Re: How to draw nice and fast window shadows? In-Reply-To: <1428150563164-4817499.post@n4.nabble.com> References: <1428147821624-4817491.post@n4.nabble.com> <1428150563164-4817499.post@n4.nabble.com> Message-ID: <1428150926793-4817504.post@n4.nabble.com> Just to get an overall impression of your opinion: http://vote.pollcode.com/21247558 Best, Marcel -- View this message in context: http://forum.world.st/How-to-draw-nice-and-fast-window-shadows-tp4817491p4817504.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From unoduetre at poczta.onet.pl Sat Apr 4 13:47:08 2015 From: unoduetre at poczta.onet.pl (Mateusz Grotek) Date: Sat Apr 4 13:42:58 2015 Subject: [squeak-dev] A bug with class renaming In-Reply-To: <1427990360.17970.0@mglap> (from unoduetre@poczta.onet.pl on Thu Apr 2 17:59:20 2015) References: <839D9F43-C05C-4009-BCE4-E976E15B0BE2@gmx.de> <1427990360.17970.0@mglap> Message-ID: <1428155228.3951.0@mglap> I've opened a ticket for it: #0007827 From frank.shearar at gmail.com Sat Apr 4 14:59:23 2015 From: frank.shearar at gmail.com (Frank Shearar) Date: Sat Apr 4 14:59:26 2015 Subject: [squeak-dev] Can we get Squeak green for the release? In-Reply-To: References: Message-ID: On 3 April 2015 at 16:27, Tobias Pape wrote: > Hey > > I am watching the CI doing its work as changes and fixes > chime in. > I noticed that there are still 13 test failing[1] and I'm > not sure how all of them should be fixed :) > Let's make it green! I am _very very happy_ to see someone other than me harping on about tests! Please carry on! This one ought to be easy to fix: it's a small breakage in the modularity of the image; some methods need to be recategorised as not being System: http://build.squeak.org/job/SqueakTrunk/1207/testReport/Tests.Dependencies/PackageDependencyTest/testSystem/ This one too: http://build.squeak.org/job/SqueakTrunk/1207/testReport/Tests.Dependencies/PackageDependencyTest/testTools/ (Tools shouldn't depend on _ToolBuilder-Morphic_, even though it would be OK to depend on ToolBuilder.) And I love that this one fails - http://build.squeak.org/job/SqueakTrunk/1207/testReport/Tests.Dependencies/PackageDependencyTest/testMultilingual/ - Multilingual no longer depends on TrueType, and our system just got one dependency cleaner. frank > Best > -Tobias > > > [1] http://build.squeak.org/job/SqueakTrunk/lastCompletedBuild/testReport/ > From karlramberg at gmail.com Sat Apr 4 15:04:40 2015 From: karlramberg at gmail.com (karl ramberg) Date: Sat Apr 4 15:04:44 2015 Subject: [squeak-dev] Re: Two bugs with SystemWindow In-Reply-To: <1428133558074-4817468.post@n4.nabble.com> References: <1428133558074-4817468.post@n4.nabble.com> Message-ID: Skipped content of type multipart/alternative-------------- next part -------------- A non-text attachment was scrubbed... Name: outline.jpg Type: image/jpeg Size: 34459 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150404/fc52258a/outline-0001.jpg -------------- next part -------------- A non-text attachment was scrubbed... Name: moveWholeWindow.jpg Type: image/jpeg Size: 26260 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150404/fc52258a/moveWholeWindow-0001.jpg From karlramberg at gmail.com Sat Apr 4 15:17:31 2015 From: karlramberg at gmail.com (karl ramberg) Date: Sat Apr 4 15:17:34 2015 Subject: [squeak-dev] A note on current window colors in Trunk In-Reply-To: <1428146039598-4817485.post@n4.nabble.com> References: <1428146039598-4817485.post@n4.nabble.com> Message-ID: Hi, It seems text selection color in code panes/text panes has become almost invisible with the latest updates. Even if I change the color to black it's hardly visible... Karl On Sat, Apr 4, 2015 at 1:13 PM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > Hi, there! > > If you are experience too-bright window colors, please fiddle around with > "Extras -> Window Colors" menu in the main docking bar. There, you should > find 4 entries: gray, colorful, bright, pastel. > > I cannot give you migration code as I cannot know, which color scheme you > are currently using. But there has to be a rebuild of some internal > caches... *sigh* > > Sorry, for being so inconvenient... ;-) > > Best, > Marcel > > > > -- > View this message in context: > http://forum.world.st/A-note-on-current-window-colors-in-Trunk-tp4817485.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150404/5743d56f/attachment.htm From tim at rowledge.org Sat Apr 4 17:17:59 2015 From: tim at rowledge.org (tim Rowledge) Date: Sat Apr 4 17:18:05 2015 Subject: [squeak-dev] Re: How to draw nice and fast window shadows? In-Reply-To: <1428150563164-4817499.post@n4.nabble.com> References: <1428147821624-4817491.post@n4.nabble.com> <1428150563164-4817499.post@n4.nabble.com> Message-ID: I?m really not a fan of fake shadows around windows and *really* not for menus. I don?t much like menus having icons either; they don?t add anything except space and time-to-open. It seems to me to be a relic of an attempt to make computer screens look like paper-based desks in order to convince people that these new-fangled computy-thingies are useful. Well, we all know that now. This degree of fake-realism skeuomorphism simply isn?t needed here. What *is* important is minimal clutter, maximum speed (anything that slows down a modern desktop machine is decidedly overdoing it!) and appropriate affordances to make discovering (and recalling) function reasonably easy. tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim Oxymorons: Same difference From asqueaker at gmail.com Sat Apr 4 17:52:17 2015 From: asqueaker at gmail.com (Chris Muller) Date: Sat Apr 4 17:52:20 2015 Subject: [squeak-dev] Re: The Inbox: ShoutCore-cmm.44.mcz In-Reply-To: <1428133209157-4817466.post@n4.nabble.com> References: <1428133209157-4817466.post@n4.nabble.com> Message-ID: That would be nice but still independent of the default presentation we want for the release. We've had these same colors for years this is a great release to update them. IMHO the most important thing is to *get the purple out* and replace it with more primary color(s). On Sat, Apr 4, 2015 at 2:40 AM, Marcel Taeumel wrote: > We could add it to preferences (maybe similar to window color specs) and make > if configurable and not hidden at the code level. > > Best, > Marcel > > > > -- > View this message in context: http://forum.world.st/The-Inbox-ShoutCore-cmm-44-mcz-tp4817440p4817466.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > From Das.Linux at gmx.de Sat Apr 4 17:53:33 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Sat Apr 4 17:53:38 2015 Subject: [squeak-dev] Re: The Inbox: ShoutCore-cmm.44.mcz In-Reply-To: References: <1428133209157-4817466.post@n4.nabble.com> Message-ID: On 04.04.2015, at 19:52, Chris Muller wrote: > That would be nice but still independent of the default presentation > we want for the release. We've had these same colors for years this > is a great release to update them. > > IMHO the most important thing is to *get the purple out* and replace > it with more primary color(s). Why? > > On Sat, Apr 4, 2015 at 2:40 AM, Marcel Taeumel > wrote: >> We could add it to preferences (maybe similar to window color specs) and make >> if configurable and not hidden at the code level. >> >> Best, >> Marcel >> >> >> >> -- >> View this message in context: http://forum.world.st/The-Inbox-ShoutCore-cmm-44-mcz-tp4817440p4817466.html >> Sent from the Squeak - Dev mailing list archive at Nabble.com. From lewis at mail.msen.com Sat Apr 4 18:30:57 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Sat Apr 4 18:30:59 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: References: <1428075270847-4817347.post@n4.nabble.com> Message-ID: <20150404183057.GA76705@shell.msen.com> On Fri, Apr 03, 2015 at 11:48:06AM -0700, Eliot Miranda wrote: > On Fri, Apr 3, 2015 at 8:34 AM, Marcel Taeumel < > marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > > > Hi Eliot, > > > > right now, I am working only on the HelpBrowser (~1-2 weeks left), doing > > some code clean-up and also some bug fixing -- including ui bugs. ;-) > > > > No bigger change (major changes to standard tools or new tools) planned > > from > > my side. As for the stability, my observation is that we are getting more > > stable with every update. > > > > But what about new packages for this release: > > - SqueakSSL > > - WebClient > > > > Any ideas on that? > > > > It's not my call. My concern here is VM impact. Only SqueakSSL has > implications for the VM right? I would have to make sure that SqueakSSL > builds correctly and the tests pass for all platforms. With help from > those that have compiled and used SqueakSSL I think I could manage that. IIRC, the SSLPlugin does not work when compiled for 64-bits, but it is probably OK for Cog/Spur compiled for 32-bits. Dave From Das.Linux at gmx.de Sat Apr 4 19:00:57 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Sat Apr 4 19:01:04 2015 Subject: [squeak-dev] more Jenkins: irc Message-ID: Dear all to make it easier for some of us to control and monitor the CI server, I installed an IRC notification and controller plugin for Jenkins. on freenode#squeak, there's now a user squeak-ci that will tell about the status of the jobs just issue !ci help and it will respond. Best -Tobias From leves at elte.hu Sat Apr 4 19:33:20 2015 From: leves at elte.hu (Levente Uzonyi) Date: Sat Apr 4 19:33:24 2015 Subject: [squeak-dev] The Inbox: ShoutCore-cmm.44.mcz In-Reply-To: References: Message-ID: Your explanation sounds great, but I don't like the result. I find most colors to be bright and intense. IMHO they don't fit well together, and some of them blend into the white background. Starting with Squeak 4.1 all releases were shipped with the subdued style table as default, which intentionally avoids bright colors, and strong emphasis. Instead of replacing the default table - which is not really default anymore - you should add your own table (and make a preference to let users choose between them, but this is not as easy as it sounds). Levente On Fri, 3 Apr 2015, commits@source.squeak.org wrote: > A new version of ShoutCore was added to project The Inbox: > http://source.squeak.org/inbox/ShoutCore-cmm.44.mcz > > ==================== Summary ==================== > > Name: ShoutCore-cmm.44 > Author: cmm > Time: 3 April 2015, 5:49:33.369 pm > UUID: 333bfec3-3a83-4de7-ae92-1ab3592f67a6 > Ancestors: ShoutCore-eem.43 > > Proposal for update of the default Shout colors. > > - Bold black for Atomics (true, false, nil, self, super) > Rationale: Bedrock. Plus, easy to tell if a method is a "utility method" at a glance. > > - Regular black for Globals; the next level above the bedrock (where all coding starts from). > > - Green for Messages, because messages make the system go and green means go. (Exception: binary messages are black for aesthetics and to visually isolate the expressions either side of it). > > - Light gray for comments so they are unobtrusive to the code, yet still very present like the "help text" we're now seeing in the Search bar and ObjectExplorer. > > - Red for Literals, because hard-coding things is "bad" and red means stop. :) But red actually makes it easy to spot literals in any method. > > - Brick (brown) for Method and block arguments because they cannot be stored into and bricks are solid and hard. > > - Aqua blue for temp vars because they're malleable like water; e.g., they CAN be stored into. > > - Gold for inst vars. Gold because they are the "resources" the object has available send messages to. > > - Magenta for undefined's and bad syntax because such a thing should be bright and noticeable. It's also ugly therefore the most appropriate color to represent problems. :) > > =============== Diff against ShoutCore-eem.43 =============== > > Item was changed: > ----- Method: SHTextStylerST80 class>>defaultStyleTable (in category 'style table') ----- > defaultStyleTable > "color can be a valid argument to Color class>>colorFrom: , or nil to > use the editor text color. > Multiple emphases can be specified using an array e.g. #(bold italic). > If emphasis is not specified, #normal will be used. > if pixel height is not specified , then the editor font size will be used. > " > > ^#( > "(symbol color [emphasisSymbolOrArray [textStyleName [pixelHeight]]])" > (default black ) > + (invalid (magenta twiceDarker) ) > + (excessCode (magenta twiceDarker) ) > + (comment (gray) italic) > + (unfinishedComment (gray) italic) > + (#'$' (black) ) > + (character (red twiceDarker ) ) > + (integer (red twiceDarker ) ) > + (number (red twiceDarker ) ) > + (#- (black) ) > + (symbol (black ) ) > + (stringSymbol (black ) ) > + (literalArray (black ) ) > + (string (red twiceDarker) normal ) > - (invalid red ) > - (excessCode red ) > - (comment (green muchDarker) italic) > - (unfinishedComment (red muchDarker) italic) > - (#'$' (red muchDarker) ) > - (character (red muchDarker) ) > - (integer (red muchDarker) ) > - (number (red muchDarker) ) > - (#- (red muchDarker) ) > - (symbol (blue muchDarker) bold) > - (stringSymbol (blue muchDarker) bold) > - (literalArray (blue muchDarker) bold) > - (string (magenta muchDarker) normal) > (unfinishedString red normal ) > + (assignment black bold ) > + (ansiAssignment black bold) > + (literal (red twiceDarker) italic) > + (keyword (green muchDarker) ) > + (binary (black ) (bold)) > + (unary (green muchDarker ) ) > + (incompleteKeyword (green darker) underlined) > + (incompleteBinary (green darker) underlined) > + (incompleteUnary (green darker) underlined) > + (undefinedKeyword (magenta twiceDarker) ) > + (undefinedBinary (magenta twiceDarker) ) > + (undefinedUnary (magenta twiceDarker) ) > + (patternKeyword (green muchDarker) (underlined bold)) > + (patternBinary (green muchDarker) (bold)) > + (patternUnary (green muchDarker) (underlined bold)) > + (#self (black) bold) > + (#super (black) bold) > + (#true (black) bold) > + (#false (black) bold) > + (#nil (black) bold) > + (#thisContext (black) bold) > + (#return (black) bold) > + (patternArg (orange muchDarker) ) > + (methodArg (orange muchDarker) ) > + (blockPatternArg (orange muchDarker) ) > + (blockArg (orange muchDarker) ) > + (argument (orange muchDarker) ) > - (assignment nil bold ) > - (ansiAssignment nil bold) > - (literal nil italic) > - (keyword (blue muchDarker) ) > - (binary (blue muchDarker) ) > - (unary (blue muchDarker) ) > - (incompleteKeyword (gray muchDarker) underlined) > - (incompleteBinary (gray muchDarker) underlined) > - (incompleteUnary (gray muchDarker) underlined) > - (undefinedKeyword red ) > - (undefinedBinary red ) > - (undefinedUnary red ) > - (patternKeyword nil bold) > - (patternBinary nil bold) > - (patternUnary nil bold) > - (#self (red muchDarker) bold) > - (#super (red muchDarker) bold) > - (#true (red muchDarker) bold) > - (#false (red muchDarker) bold) > - (#nil (red muchDarker) bold) > - (#thisContext (red muchDarker) bold) > - (#return (red muchDarker) bold) > - (patternArg (blue muchDarker) italic) > - (methodArg (blue muchDarker) italic) > - (blockPatternArg (blue muchDarker) italic) > - (blockArg (blue muchDarker) italic) > - (argument (blue muchDarker) italic) > (blockArgColon black ) > (leftParenthesis black ) > (rightParenthesis black ) > + (leftParenthesis1 (black) ) > + (rightParenthesis1 (black) ) > + (leftParenthesis2 (gray twiceDarker) ) > + (rightParenthesis2 (gray twiceDarker) ) > + (leftParenthesis3 (blue twiceDarker) ) > + (rightParenthesis3 (blue twiceDarker) ) > + (leftParenthesis4 (green twiceDarker) ) > + (rightParenthesis4 (green twiceDarker) ) > + (leftParenthesis5 (orange twiceDarker) ) > + (rightParenthesis5 (orange twiceDarker) ) > + (leftParenthesis6 (red twiceDarker) ) > + (rightParenthesis6 (red twiceDarker) ) > + (leftParenthesis7 brown ) > + (rightParenthesis7 brown ) > - (leftParenthesis1 (green muchDarker) ) > - (rightParenthesis1 (green muchDarker) ) > - (leftParenthesis2 (magenta muchDarker) ) > - (rightParenthesis2 (magenta muchDarker) ) > - (leftParenthesis3 (red muchDarker) ) > - (rightParenthesis3 (red muchDarker) ) > - (leftParenthesis4 (green darker) ) > - (rightParenthesis4 (green darker) ) > - (leftParenthesis5 (orange darker) ) > - (rightParenthesis5 (orange darker) ) > - (leftParenthesis6 (magenta darker) ) > - (rightParenthesis6 (magenta darker) ) > - (leftParenthesis7 blue ) > - (rightParenthesis7 blue ) > (blockStart black ) > (blockEnd black ) > + (blockStart1 (black) ) > + (blockEnd1 (black) ) > + (blockStart2 (gray twiceDarker) ) > + (blockEnd2 (gray twiceDarker) ) > + (blockStart3 (blue twiceDarker) ) > + (blockEnd3 (blue twiceDarker) ) > + (blockStart4 (green twiceDarker) ) > + (blockEnd4 (green twiceDarker) ) > + (blockStart5 (orange twiceDarker) ) > + (blockEnd5 (orange twiceDarker) ) > + (blockStart6 (red twiceDarker) ) > + (blockEnd6 (red twiceDarker) ) > + (blockStart7 (brown) ) > + (blockEnd7 (brown) ) > - (blockStart1 (green muchDarker) ) > - (blockEnd1 (green muchDarker) ) > - (blockStart2 (magenta muchDarker) ) > - (blockEnd2 (magenta muchDarker) ) > - (blockStart3 (red muchDarker) ) > - (blockEnd3 (red muchDarker) ) > - (blockStart4 (green darker) ) > - (blockEnd4 (green darker) ) > - (blockStart5 (orange darker) ) > - (blockEnd5 (orange darker) ) > - (blockStart6 (magenta darker) ) > - (blockEnd6 (magenta darker) ) > - (blockStart7 blue ) > - (blockEnd7 blue ) > (arrayStart black ) > (arrayEnd black ) > (arrayStart1 black ) > (arrayEnd1 black ) > + (byteArrayStart black ) > + (byteArrayEnd black ) > + (byteArrayStart1 black ) > + (byteArrayEnd1 black ) > - (byteArrayStart black ) > - (byteArrayEnd black ) > - (byteArrayStart1 black ) > - (byteArrayEnd1 black ) > (leftBrace black ) > (rightBrace black ) > (cascadeSeparator black ) > (statementSeparator black ) > (externalCallType black ) > (externalCallTypePointerIndicator black ) > + (primitiveOrExternalCallStart black ) > + (primitiveOrExternalCallEnd black ) > + (methodTempBar black ) > + (blockTempBar black ) > + (blockArgsBar black ) > - (primitiveOrExternalCallStart black bold ) > - (primitiveOrExternalCallEnd black bold ) > - (methodTempBar gray ) > - (blockTempBar gray ) > - (blockArgsBar gray ) > (primitive (green muchDarker) bold) > - (pragmaKeyword (green muchDarker) bold) > - (pragmaUnary (green muchDarker) bold) > - (pragmaBinary (green muchDarker) bold) > (externalFunctionCallingConvention (green muchDarker) bold) > (module (green muchDarker) bold) > + (blockTempVar (cyan muchDarker ) italic) > + (blockPatternTempVar (cyan muchDarker ) italic) > + (instVar (yellow twiceDarker darker) bold) > - (blockTempVar gray italic) > - (blockPatternTempVar gray italic) > - (instVar black bold) > (workspaceVar black bold) > + (undefinedIdentifier (magenta twiceDarker) normal) > + (incompleteIdentifier (gray darker) (italic underlined)) > + (tempVar (cyan muchDarker) italic) > + (patternTempVar (cyan muchDarker) italic) > + (poolConstant (blue lighter) italic) > + (classVar (blue twiceLighter) italic) > + (globalVar black normal) ) > + ! > - (undefinedIdentifier red bold) > - (incompleteIdentifier (gray darker) (italic underlined)) > - (tempVar (gray darker) italic) > - (patternTempVar (gray darker) italic) > - (poolConstant (gray darker) italic) > - (classVar (gray darker) bold) > - (globalVar black bold) ) > - ! > > > From commits at source.squeak.org Sat Apr 4 19:40:15 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 4 19:40:17 2015 Subject: [squeak-dev] The Trunk: Files-dtl.143.mcz Message-ID: David T. Lewis uploaded a new version of Files to project The Trunk: http://source.squeak.org/trunk/Files-dtl.143.mcz ==================== Summary ==================== Name: Files-dtl.143 Author: dtl Time: 4 April 2015, 3:39:20.951 pm UUID: a4f41bf8-a31f-47d4-a259-0c2f07e16beb Ancestors: Files-bf.142 A CrLfFileStream is expected to be ascii mode =============== Diff against Files-bf.142 =============== Item was changed: ----- Method: CrLfFileStream class>>new (in category 'class initialization') ----- new self deprecated: 'This class is now obsolete, use MultiByteFileStream instead.'. + ^ (MultiByteFileStream new ascii) wantsLineEndConversion: true; yourself. - ^ (MultiByteFileStream new) wantsLineEndConversion: true; yourself. ! From karlramberg at gmail.com Sat Apr 4 21:08:12 2015 From: karlramberg at gmail.com (karl ramberg) Date: Sat Apr 4 21:08:16 2015 Subject: [squeak-dev] Re: Two bugs with SystemWindow In-Reply-To: <1428133558074-4817468.post@n4.nabble.com> References: <1428133558074-4817468.post@n4.nabble.com> Message-ID: Skipped content of type multipart/alternative-------------- next part -------------- A non-text attachment was scrubbed... Name: moveWholeWindow.jpg Type: image/jpeg Size: 29978 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150404/a1fb7e3a/moveWholeWindow.jpg From commits at source.squeak.org Sat Apr 4 21:39:49 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 4 21:39:51 2015 Subject: [squeak-dev] The Trunk: Monticello-cmm.608.mcz Message-ID: Chris Muller uploaded a new version of Monticello to project The Trunk: http://source.squeak.org/trunk/Monticello-cmm.608.mcz ==================== Summary ==================== Name: Monticello-cmm.608 Author: cmm Time: 4 April 2015, 4:39:33.607 pm UUID: fe662a05-cd5a-4264-95aa-4ff408797ae1 Ancestors: Monticello-bf.607, Monticello-cmm.601 Updates to the Save Dialog: - Honors Reuse Windows. - Upon opening, selects the first change automatically. This will help folks avoid entering version notes into the code pane. - Includes the important change annotation pane unconditionally, regardless of the annotationPanes preference. IMO, we should get rid of defaultAnnotationPaneHeight. - Added refresh (R) the changes list. - ignore (I) and refresh (R) moved to the bottom of the menu to restore the easier keyboard access to 'install' and 'revert'. - #flushCachedVersions to no longer rely on Smalltalk garbageCollect to calculate the bytes saved. Still not sure if its working though. =============== Diff against Monticello-bf.607 =============== Item was changed: ----- Method: MCChangeSelector>>widgetSpecs (in category 'as yet unclassified') ----- widgetSpecs Preferences annotationPanes ifFalse: [ ^#( ((buttonRow) (0 0 1 0) (0 0 0 30)) ((multiListMorph:selection:listSelection:menu: list selection listSelectionAt: methodListMenu:) (0 0 1 0.4) (0 30 0 0)) ((innerButtonRow) (0 0.4 1 0.4) (0 0 0 30)) ((textMorph: text) (0 0.4 1 1) (0 30 0 0)) )]. ^ #( ((buttonRow) (0 0 1 0) (0 0 0 30)) ((multiListMorph:selection:listSelection:menu: list selection listSelectionAt: methodListMenu:) (0 0 1 0.4) (0 30 0 0)) ((innerButtonRow) (0 0.4 1 0.4) (0 0 0 30)) + ((textMorph: annotations) (0 0.4 1 0.4) (0 30 0 88)) + ((textMorph: text) (0 0.4 1 1) (0 88 0 0)) - ((textMorph: annotations) (0 0.4 1 0.4) (0 30 0 60)) - ((textMorph: text) (0 0.4 1 1) (0 60 0 0)) )! Item was changed: ----- Method: MCOperationsBrowser>>selection: (in category 'selecting') ----- + selection: aNumber + selection := self items + at: aNumber + ifAbsent: [ ]. + self + changed: #selection ; + changed: #text ; + changed: #annotations! - selection: aNumber - selection := aNumber = 0 ifFalse: [self items at: aNumber]. - self changed: #selection; changed: #text; changed: #annotations! Item was added: + ----- Method: MCPatchBrowser>>representsSameBrowseeAs: (in category 'ui') ----- + representsSameBrowseeAs: anotherModel + ^ self class = anotherModel class + and: [ items = anotherModel items ]! Item was changed: + ----- Method: MCSaveVersionDialog>>accept (in category 'actions') ----- - ----- Method: MCSaveVersionDialog>>accept (in category 'as yet unclassified') ----- accept self updateItems. self answer: (Array with: (self findTextMorph: #versionName) text asString with: (self findTextMorph: #logMessage) text asString with: ignore) ! Item was changed: + ----- Method: MCSaveVersionDialog>>cancel (in category 'actions') ----- - ----- Method: MCSaveVersionDialog>>cancel (in category 'as yet unclassified') ----- cancel self answer: nil! Item was changed: + ----- Method: MCSaveVersionDialog>>ignore (in category 'actions') ----- - ----- Method: MCSaveVersionDialog>>ignore (in category 'as yet unclassified') ----- ignore ^ ignore ifNil: [ignore := Set new]! Item was changed: + ----- Method: MCSaveVersionDialog>>ignoreSelection (in category 'actions') ----- - ----- Method: MCSaveVersionDialog>>ignoreSelection (in category 'as yet unclassified') ----- ignoreSelection selection ifNil: [ignore size = items size ifFalse: [ignore addAll: items] ifTrue: [ignore removeAll]] ifNotNil: [ ignore remove: selection ifAbsent: [ ignore add: selection]. self selection < items size ifTrue: [self selection: self selection + 1]]. self changed: #list ! Item was changed: + ----- Method: MCSaveVersionDialog>>installSelection (in category 'actions') ----- - ----- Method: MCSaveVersionDialog>>installSelection (in category 'as yet unclassified') ----- installSelection super installSelection. selection ifNotNil: [ ignore remove: selection ifAbsent: []. self changed: #list]. ! Item was changed: ----- Method: MCSaveVersionDialog>>methodListKey:from: (in category 'menus') ----- methodListKey: aKeystroke from: aListMorph aKeystroke caseOf: { [$I] -> [self ignoreSelection]. + [$R] -> [self refresh]. } otherwise: [super methodListKey: aKeystroke from: aListMorph ]! Item was changed: + ----- Method: MCSaveVersionDialog>>methodListMenu: (in category 'menus') ----- - ----- Method: MCSaveVersionDialog>>methodListMenu: (in category 'accessing') ----- methodListMenu: aMenu - aMenu addList:#( - ('ignore (I)' ignoreSelection 'Do not include this change when saving') - -). super methodListMenu: aMenu. + aMenu addList:#(- + ('ignore (I)' ignoreSelection 'Toggle inclusion of this change when saving.') + ('refresh (R)' refresh 'Refresh the list of changes to this package.')). ^aMenu! Item was added: + ----- Method: MCSaveVersionDialog>>refresh (in category 'actions') ----- + refresh + self + updateItems ; + changed: #list! Item was changed: + ----- Method: MCSaveVersionDialog>>revertSelection (in category 'actions') ----- - ----- Method: MCSaveVersionDialog>>revertSelection (in category 'as yet unclassified') ----- revertSelection super revertSelection. selection ifNotNil: [ ignore add: selection. self changed: #list]. ! Item was changed: ----- Method: MCSaveVersionDialog>>widgetSpecs (in category 'ui') ----- widgetSpecs ^ #( + ((listMorph:selection:menu:keystroke: list selection methodListMenu: methodListKey:from:) (0 0 0.5 0.6) (0 0 0 -47) ) - ((listMorph:selection:menu:keystroke: list selection methodListMenu: methodListKey:from:) (0 0 0.5 0.6) ) ((textMorph: versionName) (0.5 0 1 0) (0 0 0 30)) + ((textMorph: logMessage) (0.5 0 1 0.6) (0 30 0 -47)) + ((buttonRow) (0.5 0.6 1 0.6) (0 -47 0 0)) + ((textMorph: annotations) (0 0.6 0.5 0.6) (0 -47 0 0)) - ((textMorph: logMessage) (0.5 0 1 0.6) (0 30 0 -30)) - ((buttonRow) (0.5 0.6 1 0.6) (0 -30 0 0)) ((textMorph: text) (0 0.6 1 1) (0 0 0 0)) )! Item was changed: ----- Method: MCVersionNameAndMessageRequest>>defaultAction (in category 'handling') ----- defaultAction ^ MCSaveVersionDialog new versionName: suggestion; logMessage: initialMessage; patchBlock: patchBlock; + selection: 1; showModally! Item was changed: ----- Method: MCWorkingCopyBrowser>>flushCachedVersions (in category 'actions') ----- flushCachedVersions | beforeBytes afterBytes beforeVersions afterVersions | Cursor wait showWhile: [ + Smalltalk garbageCollect. + beforeBytes := Smalltalk bytesLeft: true. - beforeBytes := Smalltalk garbageCollect. beforeVersions := MCVersion allSubInstances size. MCFileBasedRepository flushAllCaches. + afterBytes := Smalltalk bytesLeft: true. - afterBytes := Smalltalk garbageCollect. afterVersions := MCVersion allSubInstances size. ]. ^self inform: (beforeVersions - afterVersions) asString, ' versions flushed', String cr, + (beforeBytes - afterBytes) asBytesDescription, ' bytes reclaimed'! - (afterBytes - beforeBytes) asStringWithCommas, ' bytes reclaimed'! From karlramberg at gmail.com Sat Apr 4 21:41:07 2015 From: karlramberg at gmail.com (karl ramberg) Date: Sat Apr 4 21:41:10 2015 Subject: [squeak-dev] Re: How to draw nice and fast window shadows? In-Reply-To: References: <1428147821624-4817491.post@n4.nabble.com> <1428150563164-4817499.post@n4.nabble.com> Message-ID: Hi, Good looks, some eye candy and visual cues makes a more enjoyable work environment. It's hard to design and keep workflow working for multiple different work styles, screen sizes and computer speeds. I personally do not have a strong opinion on window shadow, but I like the GUI to be fast and responsive. So therefor I will probably turn off the shadow drawing. Karl On Sat, Apr 4, 2015 at 7:17 PM, tim Rowledge wrote: > I?m really not a fan of fake shadows around windows and *really* not for > menus. I don?t much like menus having icons either; they don?t add anything > except space and time-to-open. > > It seems to me to be a relic of an attempt to make computer screens look > like paper-based desks in order to convince people that these new-fangled > computy-thingies are useful. Well, we all know that now. This degree of > fake-realism skeuomorphism simply isn?t needed here. > > What *is* important is minimal clutter, maximum speed (anything that slows > down a modern desktop machine is decidedly overdoing it!) and appropriate > affordances to make discovering (and recalling) function reasonably easy. > > tim > -- > tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim > Oxymorons: Same difference > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150404/ce593c37/attachment.htm From commits at source.squeak.org Sat Apr 4 21:55:03 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 4 21:55:05 2015 Subject: [squeak-dev] Daily Commit Log Message-ID: <20150404215503.9346.qmail@box4.squeakfoundation.org> Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours: http://lists.squeakfoundation.org/pipermail/packages/2015-April/007811.html Name: Morphic-mt.820 Ancestors: Morphic-mt.819 Added missing #duller to system window colors if there are gradients used. Looks not so bright anymore as the gradient itself starts with white. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007812.html Name: Morphic-mt.821 Ancestors: Morphic-mt.820 Added nil-check to color adoption in system window. (Note: We have to get rid of those color-to-nil settings...) ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007813.html Name: Morphic-mt.822 Ancestors: Morphic-mt.821 ...non-gradient windows do not get the #duller-Adaptation for their sub-panes... ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007814.html Name: Morphic-mt.823 Ancestors: Morphic-mt.822 Update all open windows' colors if the prefrence "gradient windows" is changed. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007815.html Name: System-mt.717 Ancestors: System-mt.716 Use general window-update function when changing window colors. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007816.html Name: Files-dtl.143 Ancestors: Files-bf.142 A CrLfFileStream is expected to be ascii mode ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007817.html Name: Monticello-cmm.608 Ancestors: Monticello-bf.607, Monticello-cmm.601 Updates to the Save Dialog: - Honors Reuse Windows. - Upon opening, selects the first change automatically. This will help folks avoid entering version notes into the code pane. - Includes the important change annotation pane unconditionally, regardless of the annotationPanes preference. IMO, we should get rid of defaultAnnotationPaneHeight. - Added refresh (R) the changes list. - ignore (I) and refresh (R) moved to the bottom of the menu to restore the easier keyboard access to 'install' and 'revert'. - #flushCachedVersions to no longer rely on Smalltalk garbageCollect to calculate the bytes saved. Still not sure if its working though. ============================================= From asqueaker at gmail.com Sat Apr 4 22:26:54 2015 From: asqueaker at gmail.com (Chris Muller) Date: Sat Apr 4 22:26:56 2015 Subject: [squeak-dev] The Inbox: ShoutCore-cmm.44.mcz In-Reply-To: References: Message-ID: > Your explanation sounds great, but I don't like the result. I find most > colors to be bright and intense. All except inst-vars have a luminance below 0.5. How about a darker and/or less-saturated set of colors? > IMHO they don't fit well together, and some I'd be open to just about any set of default colors besides the ones we have now. > of them blend into the white background. It's the inst-vars isn't it? Okay, I agree. How about something darker? Comments are intentionally at luminance 0.5. > Starting with Squeak 4.1 all releases were shipped with the subdued style > table as default, which intentionally avoids bright colors, and strong > emphasis. How about a set of dull, earthy, colors? I actually think the subdued style table does not seem subdued due to the purple.. > Instead of replacing the default table - which is not really default anymore > - you should add your own table (and make a preference to let users choose > between them, but this is not as easy as it sounds). At this time I just advocate 4.6 to having a new default look somewhat set apart from 4.5 and 4.4. Not only the background but some of the great work Marcel did and, hopefully some better code colors. If someone would like to submit their favorite palette, I'd vote for anything (within reason, of course) which helps us evict the purple from what have now with something more neutral or earthy.. From asqueaker at gmail.com Sat Apr 4 22:36:05 2015 From: asqueaker at gmail.com (Chris Muller) Date: Sat Apr 4 22:36:08 2015 Subject: [squeak-dev] Re: Two bugs with SystemWindow In-Reply-To: <1428133558074-4817468.post@n4.nabble.com> References: <1428133558074-4817468.post@n4.nabble.com> Message-ID: On Sat, Apr 4, 2015 at 2:45 AM, Marcel Taeumel wrote: > Hey Karl, > > 1. Vertical Splitter too height > -> Confirmed. > > 2. Window move/resize inconsistency > -> Not confirmed here. As soon as the cursor changes, you can resize the > window along the top edge. This is only a few pixels. The whole label (text) > lets you drag/move the window. Maybe this is more extreme in your image > configuration. As you are right: top grip overlaps with the label area. > Hmmm.... I believe Karl is referring to the violation of the #fastDragWindowForMorphic preference depending on where in the title bar one clicks. If one clicks close to the bottom, #fastDragWindowForMorphic is not honored.. > > Best, > Marcel > > > > -- > View this message in context: http://forum.world.st/Two-bugs-with-SystemWindow-tp4817430p4817468.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > From asqueaker at gmail.com Sat Apr 4 22:41:55 2015 From: asqueaker at gmail.com (Chris Muller) Date: Sat Apr 4 22:41:58 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: <1428140501554-4817477.post@n4.nabble.com> References: <1428075270847-4817347.post@n4.nabble.com> <1428080178583-4817382.post@n4.nabble.com> <1428140501554-4817477.post@n4.nabble.com> Message-ID: On Sat, Apr 4, 2015 at 4:41 AM, Marcel Taeumel wrote: > Ah, nice scenario! Didn't think of that one. > > ...hey! Buy youself a bigger monitor! :P Speaking of that: > > For which resolution do we want to optimize Squeak? 800x600? 1024x768? :) 800x600. From tim at rowledge.org Sun Apr 5 00:09:18 2015 From: tim at rowledge.org (tim Rowledge) Date: Sun Apr 5 00:09:28 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: References: <1428075270847-4817347.post@n4.nabble.com> <1428080178583-4817382.post@n4.nabble.com> <1428140501554-4817477.post@n4.nabble.com> Message-ID: <3C16CB19-9ABA-46F0-BE1B-CC8ABA86E1A8@rowledge.org> On 04-04-2015, at 3:41 PM, Chris Muller wrote: > On Sat, Apr 4, 2015 at 4:41 AM, Marcel Taeumel > wrote: >> Ah, nice scenario! Didn't think of that one. >> >> ...hey! Buy youself a bigger monitor! :P Speaking of that: >> >> For which resolution do we want to optimize Squeak? 800x600? 1024x768? :) > > 800x600. > Really, that small? Are there any devices with screens that small any more? Surely the minimum likely limit is HD tv size, implying to me that a default around 1024x900 would be plausible. What reason do you have for going for smaller? tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim If you don't pay the exorcist do you get repossessed? From mbaehr at email.archlab.tuwien.ac.at Sun Apr 5 03:34:26 2015 From: mbaehr at email.archlab.tuwien.ac.at (=?utf-8?q?Martin_B=C3=A4hr?=) Date: Sun Apr 5 03:34:31 2015 Subject: [squeak-dev] more Jenkins: irc In-Reply-To: References: Message-ID: <1428204459-sup-1776@email.archlab.tuwien.ac.at> Excerpts from Tobias Pape's message of 2015-04-04 21:00:57 +0200: > on freenode#squeak, there's now a user squeak-ci that will tell > about the status of the jobs > > just issue > !ci help > and it will respond. nice. could the help message (or any lengthy output) be sent back as private message? and to the channel maybe just a list of commands names: commands are: abort alias botsnack build cb comment currentlyBuilding h health jobs q queue s schedule status testresult userstat. details sent in private. greetings, martin. -- eKita - the online platform for your entire academic life -- chief engineer eKita.co pike programmer pike.lysator.liu.se caudium.net societyserver.org secretary beijinglug.org mentor fossasia.org foresight developer foresightlinux.org realss.com unix sysadmin Martin B?hr working in china http://societyserver.org/mbaehr/ From herbertkoenig at gmx.net Sun Apr 5 07:21:20 2015 From: herbertkoenig at gmx.net (=?windows-1252?Q?Herbert_K=F6nig?=) Date: Sun Apr 5 07:21:23 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: <3C16CB19-9ABA-46F0-BE1B-CC8ABA86E1A8@rowledge.org> References: <1428075270847-4817347.post@n4.nabble.com> <1428080178583-4817382.post@n4.nabble.com> <1428140501554-4817477.post@n4.nabble.com> <3C16CB19-9ABA-46F0-BE1B-CC8ABA86E1A8@rowledge.org> Message-ID: <5520E270.1080009@gmx.net> Am 05.04.2015 um 02:09 schrieb tim Rowledge: > On 04-04-2015, at 3:41 PM, Chris Muller wrote: > >> On Sat, Apr 4, 2015 at 4:41 AM, Marcel Taeumel >> wrote: >>> Ah, nice scenario! Didn't think of that one. >>> >>> ...hey! Buy youself a bigger monitor! :P Speaking of that: >>> >>> For which resolution do we want to optimize Squeak? 800x600? 1024x768? :) >> 800x600. >> > Really, that small? Are there any devices with screens that small any more? Surely the minimum likely limit is HD tv size, implying to me that a default around 1024x900 would be plausible. > > What reason do you have for going for smaller? > In my household: Two Laptops with 1280 x 800, one with 1600x900 my mobile with 1280x720. All having Squeak installed. We host foreign students and most of them have older Laptops. I think (correct me) that three years ago a common Laptop would have less than HD resolution. So yes 800x600 because expanding to fullscreen is one click while sizing down on a screen which doesn't show the whole window is much more hassle. I wouldn't mind the 1024 horizontal but the 900. And what should be displayed on the additional pixels? Cheers, Herbert From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 5 08:16:42 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 5 08:28:53 2015 Subject: [squeak-dev] Re: Two bugs with SystemWindow In-Reply-To: References: <1428133558074-4817468.post@n4.nabble.com> Message-ID: <1428221802951-4817639.post@n4.nabble.com> Ahhh, right. I have a hunch on where to look for this... :) Best, Marcel -- View this message in context: http://forum.world.st/Two-bugs-with-SystemWindow-tp4817430p4817639.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 5 08:19:03 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 5 08:31:11 2015 Subject: [squeak-dev] Re: A note on current window colors in Trunk In-Reply-To: References: <1428146039598-4817485.post@n4.nabble.com> Message-ID: <1428221943587-4817640.post@n4.nabble.com> Can you provide a small screenshot? I did not touch that color... :-) Best, Marcel -- View this message in context: http://forum.world.st/A-note-on-current-window-colors-in-Trunk-tp4817485p4817640.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 5 08:25:44 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 5 08:37:51 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: <5520E270.1080009@gmx.net> References: <1428075270847-4817347.post@n4.nabble.com> <1428080178583-4817382.post@n4.nabble.com> <1428140501554-4817477.post@n4.nabble.com> <3C16CB19-9ABA-46F0-BE1B-CC8ABA86E1A8@rowledge.org> <5520E270.1080009@gmx.net> Message-ID: <1428222344972-4817641.post@n4.nabble.com> http://vote.pollcode.com/32499929 Best, Marcel -- View this message in context: http://forum.world.st/A-plan-for-the-release-tp4817346p4817641.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 5 08:33:46 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 5 08:45:54 2015 Subject: [squeak-dev] Re: How to draw nice and fast window shadows? In-Reply-To: References: <1428147821624-4817491.post@n4.nabble.com> <1428150563164-4817499.post@n4.nabble.com> Message-ID: <1428222826703-4817642.post@n4.nabble.com> Considering menu icons, you must not overdo it and provide an icon for each and every item. Having this, icons can speed up item localization in larger (>5) lists. However, icons should still be somewhat useful and appropriate --- and not using an icon for the sake of itself. For the shadow: Discovering the currently active window (and keyboard focus) at a glance should be a must-have in such a working environment. Still, there are so many different working styles out there. And people got used to so many stuff... ;-) Best, Marcel -- View this message in context: http://forum.world.st/How-to-draw-nice-and-fast-window-shadows-tp4817491p4817642.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From frank.shearar at gmail.com Sun Apr 5 09:54:35 2015 From: frank.shearar at gmail.com (Frank Shearar) Date: Sun Apr 5 09:54:38 2015 Subject: [squeak-dev] Re: [Box-Admins] FIY: box3 library hack for SqueakSSL In-Reply-To: References: Message-ID: On 4 April 2015 at 20:23, Tobias Pape wrote: > Dear Box-Admins, > > There's a problem on the CI Server regarding libraries. > > Some Jobs need SqueakSSL, which is downloaded from google code > and made accessible. I freely admit I just hacked something together that didn't immediately explode. The code in question downloads https://squeakssl.googlecode.com/files/SqueakSSL-bin-0.1.5.zip Since googlecode.com is going, I guess we should be porting squeakssl to github as well, right? Ron? frank From frank.shearar at gmail.com Sun Apr 5 09:57:53 2015 From: frank.shearar at gmail.com (Frank Shearar) Date: Sun Apr 5 09:57:57 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: <1428222344972-4817641.post@n4.nabble.com> References: <1428075270847-4817347.post@n4.nabble.com> <1428080178583-4817382.post@n4.nabble.com> <1428140501554-4817477.post@n4.nabble.com> <3C16CB19-9ABA-46F0-BE1B-CC8ABA86E1A8@rowledge.org> <5520E270.1080009@gmx.net> <1428222344972-4817641.post@n4.nabble.com> Message-ID: Pity that doesn't show _who_ voted. So: I voted for 800x600, because it's much easier/ess annoying to increase the window size yourself than to reduce the window size. frank On 5 April 2015 at 09:25, Marcel Taeumel wrote: > http://vote.pollcode.com/32499929 > > Best, > Marcel > > > > -- > View this message in context: http://forum.world.st/A-plan-for-the-release-tp4817346p4817641.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > From commits at source.squeak.org Sun Apr 5 10:09:54 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 5 10:09:55 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.824.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.824.mcz ==================== Summary ==================== Name: Morphic-mt.824 Author: mt Time: 5 April 2015, 12:09:24.055 pm UUID: 7cb162d6-d4cc-7e44-803a-6f3a771bb701 Ancestors: Morphic-mt.823 Honor fast-dragging when the user does not hit the label but something from the system-windows's background. =============== Diff against Morphic-mt.823 =============== Item was changed: ----- Method: SystemWindow>>handlesMouseDown: (in category 'events') ----- handlesMouseDown: evt - "If I am not the topWindow, then I will only respond to dragging by the title bar. - Any other click will only bring me to the top" + ^ true! - ^ self activeOnlyOnTop and: [self ~~ TopWindow]! Item was changed: ----- Method: SystemWindow>>mouseDown: (in category 'events') ----- mouseDown: evt + | wasActive | + (wasActive := self isActive) ifFalse: [ + evt hand releaseKeyboardFocus. - TopWindow == self ifFalse: - [evt hand releaseKeyboardFocus. self activate]. + + wasActive + ifFalse: [ + "the window was locked, thus we got the event. + re-send it now that the window is unlocked again" + evt wasHandled: false. + model windowActiveOnFirstClick + ifTrue: [self processEvent: evt] "re-dispatch to any submorphs" + ifFalse: [label processEvent: evt]. "dispatch to label so dragging works" + ] + ifTrue: [ + evt hand + waitForClicksOrDrag: self + event: evt + selectors: { nil. nil. nil. #startDragFromLabel: } + threshold: HandMorph dragThreshold. + ]. + evt wasHandled: true.! - - "the window was locked, thus we got the event. re-send it now that the window is unlocked again" - evt wasHandled: false. - model windowActiveOnFirstClick - ifTrue: [self processEvent: evt] "re-dispatch to any submorphs" - ifFalse: [label processEvent: evt]. "dispatch to label so dragging works" - evt wasHandled: true. - ! From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 5 09:58:58 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 5 10:11:06 2015 Subject: [squeak-dev] Re: Two bugs with SystemWindow In-Reply-To: References: <1428133558074-4817468.post@n4.nabble.com> Message-ID: <1428227938015-4817651.post@n4.nabble.com> I think I fixed that problem: http://forum.world.st/The-Trunk-Morphic-mt-824-mcz-td4817650.html Best, Marcel -- View this message in context: http://forum.world.st/Two-bugs-with-SystemWindow-tp4817430p4817651.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Sun Apr 5 11:03:48 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 5 11:03:49 2015 Subject: [squeak-dev] The Trunk: Network-ul.160.mcz Message-ID: Levente Uzonyi uploaded a new version of Network to project The Trunk: http://source.squeak.org/trunk/Network-ul.160.mcz ==================== Summary ==================== Name: Network-ul.160 Author: ul Time: 5 April 2015, 12:58:49.025 pm UUID: feb58a8e-551d-4e5b-9725-d6e26b5c7ddc Ancestors: Network-ul.159 Updated HTTPSocket class >> #httpRequest:url:headers:content:response: - added support for gzip encoding - the last response header is not ignored anymore - avoid some unnecessary copying of the response =============== Diff against Network-ul.159 =============== Item was changed: ----- Method: HTTPSocket class>>httpRequest:url:headers:content:response: (in category 'get the page') ----- httpRequest: method url: urlString headers: hdrs content: contentOrNil response: responseBlock "Sends an HTTP request to the server. Returns a MIMEDocument if successful, a string indicating the error otherwise. If a response block is provided, the response is fed into into so that the sender can see all the headers. The url string is assumed to be properly escaped by the sender." | index serverAndPort server port rawUrl stream resp code headers + contentLength contentType content | - contentLength contentType contentStream | (urlString beginsWith: 'http://') ifFalse:[self error: 'Not a http url']. "Extract server, port, and url" index := urlString indexOf: $/ startingAt: 8 ifAbsent:[urlString size+1]. "past http://" serverAndPort := urlString copyFrom: 8 to: index-1. server := serverAndPort copyUpTo: $:. port := ((serverAndPort copyAfter: $:) ifEmpty:['80']) asNumber. "Prepare the request URI" rawUrl := urlString copyFrom: index to: urlString size. (rawUrl beginsWith: '/') ifFalse:[rawUrl := '/', rawUrl]. "Check for proxy" (self shouldUseProxy: server) ifTrue:[ self httpProxyServer ifNotEmpty:[ rawUrl := 'http://', serverAndPort, rawUrl. "per RFC 2616" server := self httpProxyServer. port := self httpProxyPort. ]. ]. "Fire off the request" stream := SocketStream openConnectionToHostNamed: server port: port. stream nextPutAll: method; space; nextPutAll: rawUrl; space; nextPutAll: 'HTTP/1.0'; crlf. stream nextPutAll: 'Host: ', serverAndPort; crlf. stream nextPutAll: 'Connection: close'; crlf. stream nextPutAll: 'User-Agent: ', self userAgentString; crlf. + stream nextPutAll: 'Accept-Encoding: gzip'; crlf. stream nextPutAll: hdrs. stream crlf. contentOrNil ifNotNil:[ + | contentStream | "Upload request content" contentStream := contentOrNil readStream. [contentStream atEnd] whileFalse:[ (HTTPProgress new) total: contentOrNil size; amount: contentStream position; signal: 'Uploading...'. stream nextPutAll: (contentStream next: 4096). stream flush. ]. ]. stream flush. "Read the response" resp := stream upToAll: String crlfcrlf. "Extract the response code" code := ((resp copyUpTo: String cr) findTokens: ' ') second asNumber. "And the response headers" headers := Dictionary new. + resp lines allButFirstDo: [ :nextLine | - resp lines allButFirst allButLast do:[:nextLine| headers at: (nextLine copyUpTo: $:) asLowercase + put: (nextLine copyAfter: $:) withBlanksTrimmed ]. - put: (nextLine copyAfter: $:) withBlanksTrimmed. - ]. (code between: 301 and: 303) ifTrue:[ headers at: 'location' ifPresent: [:location | stream close. ^ self httpRequest: method url: location headers: hdrs content: contentOrNil response: responseBlock]]. "Read response content" contentLength := headers at: 'content-length' ifAbsent:[nil]. contentType := headers at: 'content-type' ifAbsent:['application/octet-stream']. + "Fixme - Provide HTTProgress" contentLength + ifNil: [ content := stream upToEnd ] + ifNotNil: [ + contentLength := contentLength asInteger. + content := String new: contentLength. + index := 1. + [ index <= contentLength ] whileTrue: [ + | bytesRead | + bytesRead := stream readInto: content startingAt: index count: ((contentLength - index + 1) min: 8192). + index := index + bytesRead. + HTTPProgress new + total: contentLength; + amount: index; + signal: 'Downloading...' ] ]. - ifNil:[contentStream := WriteStream with: stream upToEnd] - ifNotNil:[ - contentLength := contentLength asNumber. - contentStream := (String new: contentLength) writeStream. - [contentStream position < contentLength] whileTrue:[ - contentStream nextPutAll: - (stream next: (contentLength - contentStream position min: 4096)). - (HTTPProgress new) total: contentLength; - amount: contentStream position; signal: 'Downloading...'. - ]. - ]. - stream close. responseBlock ifNotNil:[responseBlock value: resp]. + (headers at: 'content-encoding' ifAbsent: [ nil ]) = 'gzip' ifTrue: [ + content := (GZipReadStream on: content) upToEnd ]. + ^(code between: 200 and: 299) ifTrue:[MIMEDocument contentType: contentType + content: content url: urlString] + ifFalse:[resp asString, content]. - content: contentStream contents url: urlString] - ifFalse:[resp asString, contentStream contents]. ! From commits at source.squeak.org Sun Apr 5 13:05:46 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 5 13:05:48 2015 Subject: [squeak-dev] The Trunk: Collections-ul.610.mcz Message-ID: Levente Uzonyi uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections-ul.610.mcz ==================== Summary ==================== Name: Collections-ul.610 Author: ul Time: 5 April 2015, 3:01:45.533 pm UUID: 66e95716-d97a-425e-b14c-4c8825bdde8d Ancestors: Collections-cmm.608 - Slightly faster SequenceableCollection >> #copyUpT* (for ByteString receivers). - SequenceableCollection >> #shuffled belongs to the shuffling category. - Added FormatCharacterSet to String, which will be used by the new implementation of #format: - Removed an unused temporary from String >> #expandMacrosWithArguments: =============== Diff against Collections-cmm.608 =============== Item was changed: ----- Method: SequenceableCollection>>copyUpThrough: (in category 'copying') ----- copyUpThrough: anElement "Answer all elements up to and including anObject. If there is no such object, answer a copy of the receiver." + | index | + index := self indexOf: anElement. + index = 0 ifTrue: [ ^self copy ]. + ^self first: index! - ^self first: (self indexOf: anElement ifAbsent: [^ self copy])! Item was changed: ----- Method: SequenceableCollection>>copyUpTo: (in category 'copying') ----- copyUpTo: anElement "Answer all elements up to but not including anObject. If there is no such object, answer a copy of the receiver." + | index | + index := self indexOf: anElement. + index = 0 ifTrue: [ ^self copy ]. + ^self first: index - 1! - ^ self first: (self indexOf: anElement ifAbsent: [^ self copy]) - 1! Item was changed: ----- Method: SequenceableCollection>>copyUpToLast: (in category 'copying') ----- copyUpToLast: anElement "Answer a copy of the receiver from index 1 to the last occurrence of anElement, not including anElement." + | index | + index := self lastIndexOf: anElement. + index = 0 ifTrue: [ ^self copy ]. + ^self first: index - 1! - ^ self first: (self lastIndexOf: anElement ifAbsent: [^ self copy]) - 1! Item was changed: + ----- Method: SequenceableCollection>>shuffled (in category 'shuffling') ----- - ----- Method: SequenceableCollection>>shuffled (in category 'copying') ----- shuffled - ^ self shuffledBy: ThreadSafeRandom value + ^self shuffledBy: ThreadSafeRandom value + "Examples: ($A to: $Z) shuffled "! Item was changed: ArrayedCollection subclass: #String instanceVariableNames: '' + classVariableNames: 'AsciiOrder CSMacroCharacters CaseInsensitiveOrder CaseSensitiveOrder CrLfExchangeTable FormatCharacterSet HtmlEntities LowercasingTable Tokenish UppercasingTable' - classVariableNames: 'AsciiOrder CSMacroCharacters CaseInsensitiveOrder CaseSensitiveOrder CrLfExchangeTable HtmlEntities LowercasingTable Tokenish UppercasingTable' poolDictionaries: '' category: 'Collections-Strings'! !String commentStamp: '' prior: 0! A String is an indexed collection of Characters. Class String provides the abstract super class for ByteString (that represents an array of 8-bit Characters) and WideString (that represents an array of 32-bit characters). In the similar manner of LargeInteger and SmallInteger, those subclasses are chosen accordingly for a string; namely as long as the system can figure out so, the String is used to represent the given string. Strings support a vast array of useful methods, which can best be learned by browsing and trying out examples as you find them in the code. Here are a few useful methods to look at... String match: String contractTo: String also inherits many useful methods from its hierarchy, such as SequenceableCollection , SequenceableCollection copyReplaceAll:with: ! Item was changed: ----- Method: String class>>initialize (in category 'initialization') ----- initialize "self initialize" | order | AsciiOrder := (0 to: 255) as: ByteArray. CaseInsensitiveOrder := AsciiOrder copy. ($a to: $z) do: [:c | CaseInsensitiveOrder at: c asciiValue + 1 put: (CaseInsensitiveOrder at: c asUppercase asciiValue +1)]. "Case-sensitive compare sorts space, digits, letters, all the rest..." CaseSensitiveOrder := ByteArray new: 256 withAll: 255. order := -1. ' 0123456789' do: "0..10" [:c | CaseSensitiveOrder at: c asciiValue + 1 put: (order := order+1)]. ($a to: $z) do: "11-64" [:c | CaseSensitiveOrder at: c asUppercase asciiValue + 1 put: (order := order+1). CaseSensitiveOrder at: c asciiValue + 1 put: (order := order+1)]. 1 to: CaseSensitiveOrder size do: [:i | (CaseSensitiveOrder at: i) = 255 ifTrue: [CaseSensitiveOrder at: i put: (order := order+1)]]. order = 255 ifFalse: [self error: 'order problem']. "a table for translating to lower case" LowercasingTable := String withAll: (Character allByteCharacters collect: [:c | c asLowercase]). "a table for translating to upper case" UppercasingTable := String withAll: (Character allByteCharacters collect: [:c | c asUppercase]). "a table for testing tokenish (for fast numArgs)" Tokenish := String withAll: (Character allByteCharacters collect: [:c | c tokenish ifTrue: [c] ifFalse: [$~]]). "% and < for #expandMacros*" CSMacroCharacters := CharacterSet newFrom: '%<'. + + "{\ used by #format:" + FormatCharacterSet := CharacterSet newFrom: '{\'. "a table for exchanging cr with lf and vica versa" CrLfExchangeTable := Character allByteCharacters collect: [ :each | each caseOf: { [ Character cr ] -> [ Character lf ]. [ Character lf ] -> [ Character cr ] } otherwise: [ each ] ]! Item was changed: ----- Method: String>>expandMacrosWithArguments: (in category 'formatting') ----- expandMacrosWithArguments: anArray ^self class new: self size streamContents: [ :output | + | lastIndex nextIndex | - | lastIndex nextIndex characterSet | lastIndex := 1. [ (nextIndex := self indexOfAnyOf: CSMacroCharacters startingAt: lastIndex) = 0 ] whileFalse: [ nextIndex = lastIndex ifFalse: [ output next: nextIndex - lastIndex putAll: self startingAt: lastIndex ]. (self at: nextIndex) == $% ifTrue: [ output nextPut: (self at: (nextIndex := nextIndex + 1)) ] ifFalse: [ | nextCharacter argumentIndex | nextCharacter := (self at: (nextIndex := nextIndex + 1)) asUppercase. nextCharacter == $N ifTrue: [ output cr ]. nextCharacter == $T ifTrue: [ output tab ]. (nextCharacter between: $0 and: $9) ifTrue: [ argumentIndex := nextCharacter digitValue. [ (nextIndex := nextIndex + 1) <= self size and: [ (nextCharacter := self at: nextIndex) between: $0 and: $9 ] ] whileTrue: [ argumentIndex := argumentIndex * 10 + nextCharacter digitValue ]. nextCharacter := nextCharacter asUppercase ]. nextCharacter == $P ifTrue: [ output print: (anArray at: argumentIndex) ]. nextCharacter == $S ifTrue: [ output nextPutAll: (anArray at: argumentIndex) ]. nextCharacter == $? ifTrue: [ | trueEnd falseEnd | trueEnd := self indexOf: $: startingAt: nextIndex + 1. falseEnd := self indexOf: $> startingAt: trueEnd + 1. (anArray at: argumentIndex) ifTrue: [ output next: trueEnd - nextIndex - 1 putAll: self startingAt: nextIndex + 1 ] ifFalse: [ output next: falseEnd - trueEnd - 1 putAll: self startingAt: trueEnd + 1 ]. nextIndex := falseEnd - 1 ]. (self at: (nextIndex := nextIndex + 1)) == $> ifFalse: [ self error: '> expected' ] ]. lastIndex := nextIndex + 1 ]. lastIndex <= self size ifTrue: [ output next: self size - lastIndex + 1 putAll: self startingAt: lastIndex ] ]! From commits at source.squeak.org Sun Apr 5 13:10:43 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 5 13:10:46 2015 Subject: [squeak-dev] The Trunk: Collections-ul.611.mcz Message-ID: Levente Uzonyi uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections-ul.611.mcz ==================== Summary ==================== Name: Collections-ul.611 Author: ul Time: 5 April 2015, 3:02:11.144 pm UUID: 8b7bf86a-b335-47a9-9c3b-c87148584c44 Ancestors: Collections-ul.610 - Stricter and faster implementation of String >> #format:. =============== Diff against Collections-ul.610 =============== Item was removed: - ----- Method: String>>evaluateExpression:parameters: (in category 'private') ----- - evaluateExpression: aString parameters: aCollection - "private - evaluate the expression aString with - aCollection as the parameters and answer the - evaluation result as an string" - | index | - index := Integer readFrom: aString readStream base: 10. - - index isZero - ifTrue: [^ '[invalid subscript: {1}]' format: {aString}]. - - index > aCollection size - ifTrue: [^ '[subscript is out of bounds: {1}]' format: {aString}]. - - ^ (aCollection at: index) asString! Item was changed: ----- Method: String>>format: (in category 'formatting') ----- format: aCollection "format the receiver with aCollection simplest example: 'foo {1} bar' format: {Date today}. complete example: '\{ \} \\ foo {1} bar {2}' format: {12. 'string'}. " + ^self class new: self size * 11 // 10 "+10%" streamContents: [ :output | + | lastIndex nextIndex | + lastIndex := 1. + [ (nextIndex := self indexOfAnyOf: FormatCharacterSet startingAt: lastIndex) = 0 ] whileFalse: [ + nextIndex = lastIndex ifFalse: [ + output next: nextIndex - lastIndex putAll: self startingAt: lastIndex ]. + (self at: nextIndex) == $\ + ifTrue: [ output nextPut: (self at: (nextIndex := nextIndex + 1)) ] + ifFalse: [ "${" + "Parse the index - a positive integer in base 10." + | digitValue collectionIndex | + collectionIndex := 0. + [ (digitValue := self basicAt: (nextIndex := nextIndex + 1)) between: 48 "$0 asciiValue" and: 57 "$9 asciiValue" ] whileTrue: [ + collectionIndex := collectionIndex * 10 + digitValue - 48. "$0 asciiValue" ]. + digitValue = 125 "$} asciiValue" ifFalse: [ self error: '$} expected' ]. + output nextPutAll: (aCollection at: collectionIndex) asString ]. + lastIndex := nextIndex + 1 ]. + lastIndex <= self size ifTrue: [ + output next: self size - lastIndex + 1 putAll: self startingAt: lastIndex ] ]! - ^String new: self size streamContents: [ :result | - | stream currentChar | - stream := self readStream. - [ (currentChar := stream next) == nil ] whileFalse: [ - currentChar == ${ - ifTrue: [ - result nextPutAll: ( - self - evaluateExpression: (stream upTo: $}) withBlanksTrimmed - parameters: aCollection) ] - ifFalse: [ - currentChar == $\ - ifFalse: [ result nextPut: currentChar ] - ifTrue: [ - (currentChar := stream next) ifNotNil: [ - result nextPut: currentChar ] ] ] ] ]! From asqueaker at gmail.com Sun Apr 5 14:56:42 2015 From: asqueaker at gmail.com (Chris Muller) Date: Sun Apr 5 14:56:45 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: <3C16CB19-9ABA-46F0-BE1B-CC8ABA86E1A8@rowledge.org> References: <1428075270847-4817347.post@n4.nabble.com> <1428080178583-4817382.post@n4.nabble.com> <1428140501554-4817477.post@n4.nabble.com> <3C16CB19-9ABA-46F0-BE1B-CC8ABA86E1A8@rowledge.org> Message-ID: > Really, that small? Are there any devices with screens that small any more? http://www.samsung.com/global/microsite/gears/ I thought you of all people would be pushing for even smaller than 800x600 to hook up an R-pi to a tiny screen... > Surely the minimum likely limit is HD tv size, implying to me that a default around 1024x900 would be plausible. HDTV size is for the application of watching TV. Squeak is for developing apps. :) > What reason do you have for going for smaller? 800x600 is the same size we've deployed. We are not "going smaller" and we're not "going bigger." Because of the reasons Herbert and Frank gave, 800x600 is a good choice. From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 5 15:21:11 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 5 15:33:22 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: References: <1428075270847-4817347.post@n4.nabble.com> <1428080178583-4817382.post@n4.nabble.com> <1428140501554-4817477.post@n4.nabble.com> <3C16CB19-9ABA-46F0-BE1B-CC8ABA86E1A8@rowledge.org> Message-ID: <1428247271169-4817689.post@n4.nabble.com> Then we should double-check the default window sizes *and* add a factor for larger resolutions. I thought about making it dependent from the font size but we may not use a smaller font for 800x600 this time ... should we? Well, we could... what is the opinion on the default font size for 800x600? If the font size is affected, "go full screen" is not enough anymore... but I am not a 800x600-user. :) Best, Marcel -- View this message in context: http://forum.world.st/A-plan-for-the-release-tp4817346p4817689.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 5 15:22:29 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 5 15:34:41 2015 Subject: [squeak-dev] Re: The Trunk: Collections-ul.611.mcz In-Reply-To: References: Message-ID: <1428247349765-4817690.post@n4.nabble.com> What means "stricter"? Can you elaborate on what is not possible anymore but was? Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Collections-ul-611-mcz-tp4817669p4817690.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 5 15:23:07 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 5 15:35:17 2015 Subject: [squeak-dev] Re: [Box-Admins] FIY: box3 library hack for SqueakSSL In-Reply-To: References: Message-ID: <1428247387941-4817691.post@n4.nabble.com> +1 -- View this message in context: http://forum.world.st/Re-Box-Admins-FIY-box3-library-hack-for-SqueakSSL-tp4817646p4817691.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 5 15:26:13 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 5 15:38:23 2015 Subject: [squeak-dev] Adding WebClient and SqueakSSL to Trunk? Message-ID: <1428247573797-4817693.post@n4.nabble.com> Hey! :) Can we add both to the update map (somehow?) and see if it works out during the following days/weeks until the release? (Btw: How does "Adding some external project to trunk" work anyway?) Best, Marcel -- View this message in context: http://forum.world.st/Adding-WebClient-and-SqueakSSL-to-Trunk-tp4817693.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 5 15:28:10 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 5 15:40:21 2015 Subject: [squeak-dev] Re: The Inbox: ShoutCore-cmm.44.mcz In-Reply-To: References: <1428133209157-4817466.post@n4.nabble.com> Message-ID: <1428247690960-4817696.post@n4.nabble.com> Please do not overwrite an existing color template for styling. Add a new one and we can discuss about using this as new default. :) You may re-name the "current default" to a more appropriate name. :D Best, Marcel -- View this message in context: http://forum.world.st/The-Inbox-ShoutCore-cmm-44-mcz-tp4817440p4817696.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 5 15:30:50 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 5 15:42:59 2015 Subject: [squeak-dev] Re: The Inbox: ShoutCore-cmm.44.mcz In-Reply-To: References: Message-ID: <1428247850894-4817699.post@n4.nabble.com> Here is my wish for an additional color template for styling: ViTextStyler_class-defaultStyleTable.st We do not have to use it as default but we could include it in the release. :) Best, Marcel -- View this message in context: http://forum.world.st/The-Inbox-ShoutCore-cmm-44-mcz-tp4817440p4817699.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From Das.Linux at gmx.de Sun Apr 5 18:37:12 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Sun Apr 5 18:37:16 2015 Subject: [squeak-dev] [Box-Admins] FIY: box3 library hack for SqueakSSL In-Reply-To: References: Message-ID: On 05.04.2015, at 11:54, Frank Shearar wrote: > On 4 April 2015 at 20:23, Tobias Pape wrote: >> Dear Box-Admins, >> >> There's a problem on the CI Server regarding libraries. >> >> Some Jobs need SqueakSSL, which is downloaded from google code >> and made accessible. > > I freely admit I just hacked something together that didn't > immediately explode. The code in question downloads > https://squeakssl.googlecode.com/files/SqueakSSL-bin-0.1.5.zip > > Since googlecode.com is going, I guess we should be porting squeakssl > to github as well, right? > > Ron? please do From commits at source.squeak.org Sun Apr 5 20:26:23 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 5 20:26:26 2015 Subject: [squeak-dev] The Trunk: CollectionsTests-ul.235.mcz Message-ID: Levente Uzonyi uploaded a new version of CollectionsTests to project The Trunk: http://source.squeak.org/trunk/CollectionsTests-ul.235.mcz ==================== Summary ==================== Name: CollectionsTests-ul.235 Author: ul Time: 19 January 2015, 10:51:37.525 pm UUID: 4e40f650-e20c-4e52-88f1-6b72e04f9a3a Ancestors: CollectionsTests-mt.234 Don't reference the lastIndex variable, because it's gone. Use exact values instead. =============== Diff against CollectionsTests-mt.234 =============== Item was changed: ----- Method: OrderedDictionaryTest>>testCompact (in category 'tests') ----- testCompact | oldCapacity | 1 to: 3 do: [:ea | sut at: ea put: nil]. + self assert: 3 equals: sut size. - self assert: sut size equals: (sut instVarNamed: #lastIndex). sut removeKey: 2. + self assert: 2 equals: sut size. - self assert: sut size equals: (sut instVarNamed: #lastIndex) - 1. oldCapacity := sut capacity. 4 to: 20 do: [:ea | sut at: ea put: nil]. self assert: sut capacity > oldCapacity; + assert: 19 equals: sut size - assert: sut size equals: (sut instVarNamed: #lastIndex). ! From leves at elte.hu Sun Apr 5 20:26:56 2015 From: leves at elte.hu (Levente Uzonyi) Date: Sun Apr 5 20:27:01 2015 Subject: [squeak-dev] Re: The Trunk: Collections-ul.611.mcz In-Reply-To: <1428247349765-4817690.post@n4.nabble.com> References: <1428247349765-4817690.post@n4.nabble.com> Message-ID: Input that one would normally consider invalid is not accepted anymore. The following expressions raise an error instead of returning 'x': '{1 }' format: { 'x' }. '{1abc}' format: { 'x' }. '{ 1}' format: { 'x' }. '{ 1.0 }' format: { 'x' }. '{1' format: { 'x' }. '{1 foo' format: { 'x' }. The following expressions raise an error, instead of writing an error message into the return value: 'foo {2} bar {1}' format: { 'x' }. "instead of 'foo [subscript is out of bounds: 2] bar x'" 'foo {0} bar {1}' format: { 'x' }. "instead of 'foo [invalid subscript: 0] bar x'" '{-0}' format: { 'x' }. "instead of '[invalid subscript: -0]'" Levente On Sun, 5 Apr 2015, Marcel Taeumel wrote: > What means "stricter"? Can you elaborate on what is not possible anymore but > was? > > Best, > Marcel > > > > -- > View this message in context: http://forum.world.st/The-Trunk-Collections-ul-611-mcz-tp4817669p4817690.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > From commits at source.squeak.org Sun Apr 5 20:30:10 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 5 20:30:11 2015 Subject: [squeak-dev] The Trunk: CollectionsTests-ul.236.mcz Message-ID: Levente Uzonyi uploaded a new version of CollectionsTests to project The Trunk: http://source.squeak.org/trunk/CollectionsTests-ul.236.mcz ==================== Summary ==================== Name: CollectionsTests-ul.236 Author: ul Time: 5 April 2015, 10:25:52.113 pm UUID: 4fea2b80-99a8-41c5-9475-ff40295127f0 Ancestors: CollectionsTests-mt.235 Added more tests for String >> #format:. =============== Diff against CollectionsTests-mt.235 =============== Item was changed: ----- Method: StringTest>>testFormat (in category 'tests - formatting') ----- testFormat + #( + '\{ \} \\ foo {1} bar {2}' #(12 'string') '{ } \ foo 12 bar string' + '\{ \} \\ foo {2} bar {1}' #('string' 12) '{ } \ foo 12 bar string' + '\{1}' #() '{1}' + '\{1}{1}' #($a) '{1}a' + 'foo' #() 'foo' + ) groupsDo: [ :receiver :argument :expectedResult | + self assert: expectedResult equals: (receiver format: argument) ]. + #( + '{1 }' + '{1abc}' + '{ 1}' + '{ 1.0 }' + '{1' + '{1 foo' + '{2}' + '{0}' + '{-0}' + '{-1}' + ) do: [ :each | + self should: [ each format: { 'x' } ] raise: Error ]! - { - [ '\{ \} \\ foo {1} bar {2}' format: { 12. 'string' } ] -> '{ } \ foo 12 bar string'. - [ '\{ \} \\ foo {2} bar {1}' format: { 'string'. 12 } ] -> '{ } \ foo 12 bar string'. - [ '\{1}' format: {} ] -> '{1}'. - [ '\{1}{1}' format: { $a } ] -> '{1}a'. - } do: [ :each | - self assert: each key value = each value ]! From leves at elte.hu Sun Apr 5 20:43:29 2015 From: leves at elte.hu (Levente Uzonyi) Date: Sun Apr 5 20:43:34 2015 Subject: [squeak-dev] The Trunk: CollectionsTests-ul.235.mcz In-Reply-To: References: Message-ID: This is an unintended commit of an old version of this package. I'd delete/move it, but only admins can do that. So Board members, please delete it, or move it to the Treated Inbox. TIA, Levente On Sun, 5 Apr 2015, commits@source.squeak.org wrote: > Levente Uzonyi uploaded a new version of CollectionsTests to project The Trunk: > http://source.squeak.org/trunk/CollectionsTests-ul.235.mcz > > ==================== Summary ==================== > > Name: CollectionsTests-ul.235 > Author: ul > Time: 19 January 2015, 10:51:37.525 pm > UUID: 4e40f650-e20c-4e52-88f1-6b72e04f9a3a > Ancestors: CollectionsTests-mt.234 > > Don't reference the lastIndex variable, because it's gone. Use exact values instead. > > =============== Diff against CollectionsTests-mt.234 =============== > > Item was changed: > ----- Method: OrderedDictionaryTest>>testCompact (in category 'tests') ----- > testCompact > > | oldCapacity | > 1 to: 3 do: [:ea | > sut at: ea put: nil]. > + self assert: 3 equals: sut size. > - self assert: sut size equals: (sut instVarNamed: #lastIndex). > > sut removeKey: 2. > + self assert: 2 equals: sut size. > - self assert: sut size equals: (sut instVarNamed: #lastIndex) - 1. > > oldCapacity := sut capacity. > 4 to: 20 do: [:ea | > sut at: ea put: nil]. > self > assert: sut capacity > oldCapacity; > + assert: 19 equals: sut size > - assert: sut size equals: (sut instVarNamed: #lastIndex). > ! > > > From commits at source.squeak.org Sun Apr 5 21:14:19 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 5 21:14:19 2015 Subject: [squeak-dev] The Trunk: ShoutCore-ul.44.mcz Message-ID: Levente Uzonyi uploaded a new version of ShoutCore to project The Trunk: http://source.squeak.org/trunk/ShoutCore-ul.44.mcz ==================== Summary ==================== Name: ShoutCore-ul.44 Author: ul Time: 5 April 2015, 4:22:05.742 pm UUID: 28aa2d92-85a0-44e3-ab2e-d865bf2c8807 Ancestors: ShoutCore-eem.43 - various speed improvements =============== Diff against ShoutCore-eem.43 =============== Item was changed: ----- Method: SHParserST80>>parsingBlockArguments (in category 'token testing') ----- parsingBlockArguments + ^ranges notEmpty and: [ranges last type == #blockPatternArg]! - ^ranges notEmpty and: [ranges last type = #blockPatternArg]! Item was changed: ----- Method: SHParserST80>>scanNumber (in category 'scan') ----- scanNumber | start c nc base | start := sourcePosition. self skipDigits. c := self currentChar. c == $r ifTrue: [ base := Integer readFrom: (ReadStream on: (source copyFrom: start to: sourcePosition - 1)). self peekChar == $- ifTrue:[self nextChar]. self skipBigDigits: base. c := self currentChar. c == $. ifTrue: [ (self isBigDigit: self nextChar base: base) ifFalse: [sourcePosition := sourcePosition - 1] ifTrue: [self skipBigDigits: base]]. c := self currentChar. ('deq'includes: c) ifTrue: [ ((encodedCharSet isDigit: (nc := self nextChar)) or: [nc == $- and:[(encodedCharSet isDigit: self peekChar)]]) ifFalse: [sourcePosition := sourcePosition - 1] ifTrue: [self skipDigits]]. + c == $s ifTrue: [ + (encodedCharSet isDigit: (nc := self nextChar)) + ifTrue: [ self skipDigits ] + ifFalse: [ + (encodedCharSet isLetter: nc) ifTrue: [ + sourcePosition := sourcePosition - 1 ] ] ]. - c == $s - ifTrue: [ - (encodedCharSet isDigit: (nc := self nextChar)) - ifFalse: [nc isLetter ifTrue: [sourcePosition := sourcePosition - 1]] - ifTrue: [self skipDigits]]. currentToken := source copyFrom: start to: sourcePosition - 1. ^currentTokenSourcePosition := start]. c == $s ifTrue: [ (encodedCharSet isDigit: (nc := self nextChar)) ifFalse: [nc isLetter ifTrue: [sourcePosition := sourcePosition - 1]] ifTrue: [self skipDigits.]. currentToken := source copyFrom: start to: sourcePosition - 1. ^currentTokenSourcePosition := start]. c == $. ifTrue: [ (encodedCharSet isDigit: self nextChar) ifFalse: [ sourcePosition := sourcePosition - 1. currentToken := source copyFrom: start to: sourcePosition - 1. ^currentTokenSourcePosition := start] ifTrue: [self skipDigits]]. c := self currentChar. ('deq' includes: c) ifTrue: [ ((encodedCharSet isDigit: (nc := self nextChar)) or: [nc == $- and:[(encodedCharSet isDigit: self peekChar)]]) ifFalse: [sourcePosition := sourcePosition - 1] ifTrue: [self skipDigits]]. c == $s ifTrue: [ (encodedCharSet isDigit: (nc := self nextChar)) ifFalse: [nc isLetter ifTrue: [sourcePosition := sourcePosition - 1]] ifTrue: [self skipDigits]]. currentToken := source copyFrom: start to: sourcePosition - 1. ^currentTokenSourcePosition := start! Item was changed: ----- Method: SHParserST80>>scanWhitespace (in category 'scan') ----- scanWhitespace - | c | + (self currentChar ifNil: [ ^self ]) isSeparator ifTrue: [ + sourcePosition := source + indexOfAnyOf: CharacterSet nonSeparators + startingAt: sourcePosition + 1 + ifAbsent: [ source size + 1 ] ]. + self currentChar == $" ifTrue: [ self scanComment ]! - [c := self currentChar. - c notNil and: [c isSeparator]] - whileTrue: [sourcePosition := sourcePosition + 1]. - c == $" ifTrue: [self scanComment]! Item was added: + ----- Method: SHRange>>printOn: (in category 'accessing') ----- + printOn: stream + + super printOn: stream. + stream + nextPut: $(; + print: type; + nextPutAll: ', '; + print: start; + nextPutAll: ', '; + print: end; + nextPut: $)! Item was changed: SHTextStyler subclass: #SHTextStylerST80 + instanceVariableNames: 'classOrMetaClass workspace font parser formatAssignments environment sourceMap processedSourceMap pixelHeight attributesByPixelHeight' - instanceVariableNames: 'classOrMetaClass workspace font parser formatAssignments environment sourceMap processedSourceMap pixelHeight' classVariableNames: 'SubduedSyntaxHighlights SyntaxHighlightingAsYouType SyntaxHighlightingAsYouTypeAnsiAssignment SyntaxHighlightingAsYouTypeLeftArrowAssignment' poolDictionaries: '' category: 'ShoutCore-Styling'! SHTextStylerST80 class instanceVariableNames: 'styleTable textAttributesByPixelHeight'! !SHTextStylerST80 commentStamp: 'tween 8/27/2004 10:55' prior: 0! I style Smalltalk methods and expressions. My 'styleTable' class instance var holds an array ofArrays which control how each token is styled/coloured. See my defaultStyleTable class method for its structure. My styleTable can be changed by either modifying the defaultStyleTable class method and then executing SHTextStylerST80 initialize ; or by giving me a new styleTable through my #styleTable: class method. My 'textAttributesByPixelSize' class instance var contains a dictionary of dictionaries. The key is a pixelSize and the value a Dictionary from token type Symbol to TextAttribute array. It is created/maintained automatically. I also install these 3 preferences when my class initialize method is executed.... #syntaxHighlightingAsYouType - controls whether methods are styled in browsers #syntaxHighlightingAsYouTypeAnsiAssignment - controls whether assignments are formatted to be := #syntaxHighlightingAsYouTypeLeftArrowAssignment - controls whether assignments are formatted to be _ I reimplement #unstyledTextFrom: so that TextActions are preserved in the unstyled text ! SHTextStylerST80 class instanceVariableNames: 'styleTable textAttributesByPixelHeight'! Item was added: + ----- Method: SHTextStylerST80 class>>attributesByPixelHeight: (in category 'style table') ----- + attributesByPixelHeight: aNumber + + ^self textAttributesByPixelHeight + at: aNumber + ifAbsent: [ + | result | + result := self initialTextAttributesForPixelHeight: aNumber. + " thread safety first " + textAttributesByPixelHeight := textAttributesByPixelHeight copy + at: aNumber put: result; + yourself. + result ]! Item was changed: ----- Method: SHTextStylerST80>>attributesFor: (in category 'private') ----- + attributesFor: aSymbol + + ^(attributesByPixelHeight ifNil: [ + attributesByPixelHeight := self class attributesByPixelHeight: self pixelHeight ]) + at: aSymbol + ifAbsent: nil! - attributesFor: aSymbol - ^self class attributesFor: aSymbol pixelHeight: self pixelHeight - ! Item was changed: ----- Method: SHTextStylerST80>>shouldPreserveAttribute: (in category 'private') ----- shouldPreserveAttribute: aTextAttribute "Answer true if Shout should preserve ALL the attributes in the same run as the argument, false otherwise" + ^aTextAttribute shoutShouldPreserve! - (aTextAttribute respondsTo: #shoutShouldPreserve) - ifTrue:[^ aTextAttribute shoutShouldPreserve]. - ^aTextAttribute isMemberOf: TextAction! Item was added: + ----- Method: TextAction>>shoutShouldPreserve (in category '*ShoutCore') ----- + shoutShouldPreserve + + ^self class == TextAction! Item was added: + ----- Method: TextAttribute>>shoutShouldPreserve (in category '*ShoutCore') ----- + shoutShouldPreserve + + ^false! From commits at source.squeak.org Sun Apr 5 21:14:30 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 5 21:14:32 2015 Subject: [squeak-dev] The Trunk: ShoutCore-ul.45.mcz Message-ID: Levente Uzonyi uploaded a new version of ShoutCore to project The Trunk: http://source.squeak.org/trunk/ShoutCore-ul.45.mcz ==================== Summary ==================== Name: ShoutCore-ul.45 Author: ul Time: 5 April 2015, 11:12:34.743 pm UUID: 782f17b3-a996-4680-bf4a-d112fc6f7882 Ancestors: ShoutCore-ul.44 - Avoid block creation in SHParserST80 >> #scanWhitespace. =============== Diff against ShoutCore-ul.44 =============== Item was changed: ----- Method: SHParserST80>>scanWhitespace (in category 'scan') ----- scanWhitespace (self currentChar ifNil: [ ^self ]) isSeparator ifTrue: [ sourcePosition := source indexOfAnyOf: CharacterSet nonSeparators + startingAt: sourcePosition + 1. + sourcePosition = 0 ifTrue: [ "Not found" + sourcePosition := source size + 1 ] ]. - startingAt: sourcePosition + 1 - ifAbsent: [ source size + 1 ] ]. self currentChar == $" ifTrue: [ self scanComment ]! From commits at source.squeak.org Sun Apr 5 21:55:03 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 5 21:55:04 2015 Subject: [squeak-dev] Daily Commit Log Message-ID: <20150405215503.20276.qmail@box4.squeakfoundation.org> Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours: http://lists.squeakfoundation.org/pipermail/packages/2015-April/007818.html Name: Morphic-mt.824 Ancestors: Morphic-mt.823 Honor fast-dragging when the user does not hit the label but something from the system-windows's background. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007819.html Name: Network-ul.160 Ancestors: Network-ul.159 Updated HTTPSocket class >> #httpRequest:url:headers:content:response: - added support for gzip encoding - the last response header is not ignored anymore - avoid some unnecessary copying of the response ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007820.html Name: Collections-ul.610 Ancestors: Collections-cmm.608 - Slightly faster SequenceableCollection >> #copyUpT* (for ByteString receivers). - SequenceableCollection >> #shuffled belongs to the shuffling category. - Added FormatCharacterSet to String, which will be used by the new implementation of #format: - Removed an unused temporary from String >> #expandMacrosWithArguments: ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007821.html Name: Collections-ul.611 Ancestors: Collections-ul.610 - Stricter and faster implementation of String >> #format:. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007822.html Name: CollectionsTests-ul.235 Ancestors: CollectionsTests-mt.234 Don't reference the lastIndex variable, because it's gone. Use exact values instead. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007823.html Name: CollectionsTests-ul.236 Ancestors: CollectionsTests-mt.235 Added more tests for String >> #format:. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007824.html Name: ShoutCore-ul.44 Ancestors: ShoutCore-eem.43 - various speed improvements ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007825.html Name: ShoutCore-ul.45 Ancestors: ShoutCore-ul.44 - Avoid block creation in SHParserST80 >> #scanWhitespace. ============================================= From lewis at mail.msen.com Mon Apr 6 03:44:26 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Mon Apr 6 03:44:28 2015 Subject: [squeak-dev] The Trunk: CollectionsTests-ul.235.mcz In-Reply-To: References: Message-ID: <20150406034426.GA5059@shell.msen.com> Version CollectionsTests-ul.235.mcz is deleted from trunk. Dave On Sun, Apr 05, 2015 at 10:43:29PM +0200, Levente Uzonyi wrote: > This is an unintended commit of an old version of this package. > I'd delete/move it, but only admins can do that. So Board members, > please delete it, or move it to the Treated Inbox. > > TIA, > Levente > > On Sun, 5 Apr 2015, commits@source.squeak.org wrote: > > >Levente Uzonyi uploaded a new version of CollectionsTests to project The > >Trunk: > >http://source.squeak.org/trunk/CollectionsTests-ul.235.mcz > > > >==================== Summary ==================== > > > >Name: CollectionsTests-ul.235 > >Author: ul > >Time: 19 January 2015, 10:51:37.525 pm > >UUID: 4e40f650-e20c-4e52-88f1-6b72e04f9a3a > >Ancestors: CollectionsTests-mt.234 > > > >Don't reference the lastIndex variable, because it's gone. Use exact > >values instead. > > > >=============== Diff against CollectionsTests-mt.234 =============== > > > >Item was changed: > > ----- Method: OrderedDictionaryTest>>testCompact (in category 'tests') > > ----- > > testCompact > > > > | oldCapacity | > > 1 to: 3 do: [:ea | > > sut at: ea put: nil]. > >+ self assert: 3 equals: sut size. > >- self assert: sut size equals: (sut instVarNamed: #lastIndex). > > > > sut removeKey: 2. > >+ self assert: 2 equals: sut size. > >- self assert: sut size equals: (sut instVarNamed: #lastIndex) - 1. > > > > oldCapacity := sut capacity. > > 4 to: 20 do: [:ea | > > sut at: ea put: nil]. > > self > > assert: sut capacity > oldCapacity; > >+ assert: 19 equals: sut size > >- assert: sut size equals: (sut instVarNamed: #lastIndex). > > ! > > > > > > From commits at source.squeak.org Mon Apr 6 12:24:11 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Mon Apr 6 12:24:12 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.825.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.825.mcz ==================== Summary ==================== Name: Morphic-mt.825 Author: mt Time: 6 April 2015, 2:23:39.657 pm UUID: 689afaee-4732-ab48-8ab8-f950131ccb24 Ancestors: Morphic-mt.824 Soft drop shadows introduced and *disabled* by default. Cache added to shadow drawing (including regular/sharp shadows), which will be updated on extent updates. This commit also cleans-up some shadow-related code. Note: This does not change the way hand morphs compute their drop shadows when dragging morphs around! There always have been two seprate concepts for drop shadows. =============== Diff against Morphic-mt.824 =============== Item was changed: ----- Method: FillInTheBlankMorph>>setDefaultParameters (in category 'initialization') ----- setDefaultParameters "change the receiver's appareance parameters" | colorFromMenu worldColor menuColor | colorFromMenu := Preferences menuColorFromWorld and: [Display depth > 4 and: [(worldColor := self currentWorld color) isColor]]. menuColor := colorFromMenu ifTrue: [worldColor luminance > 0.7 ifTrue: [worldColor mixed: 0.85 with: Color black] ifFalse: [worldColor mixed: 0.4 with: Color white]] ifFalse: [Preferences menuColor]. self color: menuColor. self borderWidth: Preferences menuBorderWidth. Preferences menuAppearance3d ifTrue: [ self borderStyle: BorderStyle thinGray. + self hasDropShadow: true. + + self useSoftDropShadow + ifFalse: [ + self + shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.666); + shadowOffset: 1 @ 1] + ifTrue: [ + self + shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.01); + shadowOffset: (10@8 corner: 10@12) ] - self - addDropShadow; - shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.666); - shadowOffset: 1 @ 1 ] ifFalse: [ | menuBorderColor | menuBorderColor := colorFromMenu ifTrue: [worldColor muchDarker] ifFalse: [Preferences menuBorderColor]. self borderColor: menuBorderColor. ]. self layoutInset: 3. ! Item was changed: ----- Method: MenuMorph>>setDefaultParameters (in category 'initialization') ----- setDefaultParameters "change the receiver's appareance parameters" | colorFromMenu worldColor menuColor | colorFromMenu := Preferences menuColorFromWorld and: [Display depth > 4 and: [(worldColor := self currentWorld color) isColor]]. menuColor := colorFromMenu ifTrue: [worldColor luminance > 0.7 ifTrue: [worldColor mixed: 0.85 with: Color black] ifFalse: [worldColor mixed: 0.4 with: Color white]] ifFalse: [Preferences menuColor]. self color: menuColor. self borderWidth: Preferences menuBorderWidth. Preferences menuAppearance3d ifTrue: [ self borderStyle: BorderStyle thinGray. + self hasDropShadow: true. + + self useSoftDropShadow + ifFalse: [ + self + shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.666); + shadowOffset: 1 @ 1] + ifTrue: [ + self + shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.01); + shadowOffset: (10@8 corner: 10@12) ] - self - addDropShadow; - shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.666); - shadowOffset: 1 @ 1 ] ifFalse: [ | menuBorderColor | menuBorderColor := colorFromMenu ifTrue: [worldColor muchDarker] ifFalse: [Preferences menuBorderColor]. self borderColor: menuBorderColor. ]. self layoutInset: 3. ! Item was changed: Object subclass: #Morph instanceVariableNames: 'bounds owner submorphs fullBounds color extension' + classVariableNames: 'PreferredCornerRadius UseSoftDropShadow' - classVariableNames: 'PreferredCornerRadius' poolDictionaries: '' category: 'Morphic-Kernel'! !Morph commentStamp: 'efc 2/26/2003 20:01' prior: 0! A Morph (from the Greek "shape" or "form") is an interactive graphical object. General information on the Morphic system can be found at http://minnow.cc.gatech.edu/squeak/30. Morphs exist in a tree, rooted at a World (generally a PasteUpMorph). The morphs owned by a morph are its submorphs. Morphs are drawn recursively; if a Morph has no owner it never gets drawn. To hide a Morph and its submorphs, set its #visible property to false using the #visible: method. The World (screen) coordinate system is used for most coordinates, but can be changed if there is a TransformMorph somewhere in the owner chain. My instance variables have accessor methods (e.g., #bounds, #bounds:). Most users should use the accessor methods instead of using the instance variables directly. Structure: instance var Type Description bounds Rectangle A Rectangle indicating my position and a size that will enclose me. owner Morph My parent Morph, or nil for the top-level Morph, which is a or nil world, typically a PasteUpMorph. submorphs Array My child Morphs. fullBounds Rectangle A Rectangle minimally enclosing me and my submorphs. color Color My primary color. Subclasses can use this in different ways. extension MorphExtension Allows extra properties to be stored without adding a or nil storage burden to all morphs. By default, Morphs do not position their submorphs. Morphs may position their submorphs directly or use a LayoutPolicy to automatically control their submorph positioning. Although Morph has some support for BorderStyle, most users should use BorderedMorph if they want borders.! Item was added: + ----- Method: Morph class>>useSoftDropShadow (in category 'preferences') ----- + useSoftDropShadow + + + ^ UseSoftDropShadow ifNil: [ false ]! Item was added: + ----- Method: Morph class>>useSoftDropShadow: (in category 'preferences') ----- + useSoftDropShadow: aBoolean + + UseSoftDropShadow = aBoolean ifTrue: [^ self]. + UseSoftDropShadow := aBoolean. + + SystemWindow refreshAllWindows. + SystemProgressMorph reset. + TheWorldMainDockingBar updateInstances.! Item was changed: ----- Method: Morph>>addDropShadow (in category 'drop shadows') ----- addDropShadow - self hasDropShadow ifTrue:[^self]. - self changed. self hasDropShadow: true. + + self useSoftDropShadow + ifFalse: [ + self + shadowOffset: 3@3; + shadowColor: (Color black alpha: 0.5)] + ifTrue: [ + self + shadowOffset: (10@8 corner: 10@12); + shadowColor: (Color black alpha: 0.01)].! - self shadowOffset: 3@3. - self layoutChanged. - self changed.! Item was changed: ----- Method: Morph>>drawDropShadowOn: (in category 'drawing') ----- drawDropShadowOn: aCanvas + "Rectangular shadow with support for rounded corners." + + | shadowBounds | + shadowBounds := self shadowOffset isRectangle + ifTrue: [self bounds outsetBy: self shadowOffset] + ifFalse: [self bounds translateBy: (self shadowOffset negated max: 0@0)]. + + "Only redraw the shadow if the shadow area is affected." + ((aCanvas clipRect intersects: shadowBounds) and: [((self bounds insetBy: (self wantsRoundedCorners ifFalse: [0] ifTrue: [self class preferredCornerRadius])) containsRect: aCanvas clipRect) not]) + ifTrue: [ + (self hasProperty: #dropShadow) + ifFalse: [self updateDropShadowCache]. + aCanvas + translucentImage: (self valueOfProperty: #dropShadow) + at: shadowBounds topLeft].! - - aCanvas - translateBy: self shadowOffset - during: [ :shadowCanvas | - (shadowCanvas isVisible: self bounds) ifTrue: [ - self wantsRoundedCorners - ifTrue: [shadowCanvas fillRoundRect: self bounds radius: self class preferredCornerRadius fillStyle: self shadowColor] - ifFalse: [shadowCanvas fillRectangle: self bounds fillStyle: self shadowColor]]]. - ! Item was changed: ----- Method: Morph>>expandFullBoundsForDropShadow: (in category 'drawing') ----- expandFullBoundsForDropShadow: aRectangle "Return an expanded rectangle for an eventual drop shadow" | delta box | + self shadowOffset isRectangle + ifTrue: [^ aRectangle outsetBy: self shadowOffset]. + box := aRectangle. delta := self shadowOffset. box := delta x >= 0 ifTrue:[box right: aRectangle right + delta x] ifFalse:[box left: aRectangle left + delta x]. box := delta y >= 0 ifTrue:[box bottom: aRectangle bottom + delta y] ifFalse:[box top: aRectangle top + delta y]. ^box! Item was changed: ----- Method: Morph>>extent: (in category 'geometry') ----- extent: aPoint (bounds extent closeTo: aPoint) ifTrue: [^ self]. self changed. bounds := (bounds topLeft extent: aPoint) rounded. + self removeProperty: #dropShadow. self layoutChanged. self changed. ! Item was changed: ----- Method: Morph>>hasDropShadow: (in category 'drop shadows') ----- hasDropShadow: aBool + + self hasDropShadow = aBool ifTrue: [^ self]. + self changed. aBool ifTrue:[self setProperty: #hasDropShadow toValue: true] + ifFalse:[self removeProperty: #hasDropShadow]. + + self layoutChanged. + self changed.! - ifFalse:[self removeProperty: #hasDropShadow]! Item was changed: ----- Method: Morph>>shadowColor: (in category 'drop shadows') ----- shadowColor: aColor + self shadowColor = aColor ifTrue: [^ self]. + self setProperty: #shadowColor toValue: aColor. + self removeProperty: #dropShadow. + self changed.! - self shadowColor = aColor ifFalse:[self changed]. - self setProperty: #shadowColor toValue: aColor.! Item was changed: ----- Method: Morph>>shadowOffset: (in category 'drop shadows') ----- shadowOffset: aPoint "Set the current shadow offset" + self shadowOffset = aPoint ifTrue: [^ self]. + self changed. + (aPoint isNil or: [ aPoint isZero ]) ifTrue:[self removeProperty: #shadowOffset] + ifFalse:[self setProperty: #shadowOffset toValue: aPoint]. + + self layoutChanged. + self changed.! - ifFalse:[self setProperty: #shadowOffset toValue: aPoint].! Item was added: + ----- Method: Morph>>updateDropShadowCache (in category 'drawing') ----- + updateDropShadowCache + + | shadowBounds offset form canvas drawBlock localBounds mask maskCanvas | + shadowBounds := self shadowOffset isRectangle + ifTrue: [0@0 corner: (self bounds outsetBy: self shadowOffset) extent] + ifFalse: [0@0 corner: self extent + self shadowOffset abs]. + offset := self shadowOffset isRectangle + ifTrue: [0@0] + ifFalse: [self shadowOffset max: 0@0]. + localBounds := self shadowOffset isRectangle + ifTrue: [self shadowOffset topLeft extent: self extent] + ifFalse: [(self shadowOffset negated max: 0@0) extent: self extent]. + + form := Form extent: shadowBounds extent depth: Display depth. + canvas := form getCanvas. + + drawBlock := self useSoftDropShadow + ifFalse: [ + [:c | self wantsRoundedCorners + ifTrue: [c fillRoundRect: localBounds radius: self class preferredCornerRadius fillStyle: self shadowColor] + ifFalse: [c fillRectangle: localBounds fillStyle: self shadowColor]]] + ifTrue: [ + [:c | self wantsRoundedCorners + ifTrue: [0 to: 9 do: [:i | + c + fillRoundRect: (shadowBounds insetBy: i) + radius: (self class preferredCornerRadius max: 20) -i + fillStyle: (self shadowColor alpha: self shadowColor alpha * (i+1))]] + ifFalse: [0 to: 9 do: [:i | + c + fillRoundRect: (shadowBounds insetBy: i) radius: 20-i + fillStyle: (self shadowColor alpha: self shadowColor alpha * (i+1))]]]]. + + canvas + translateBy: offset + during: [ :shadowCanvas | drawBlock value: shadowCanvas]. + + "Support transparent morph colors without having the shadow to shine through.." + mask := Form extent: shadowBounds extent depth: Display depth. + maskCanvas := mask getCanvas. + self wantsRoundedCorners + ifTrue: [maskCanvas fillRoundRect: (localBounds insetBy: self borderWidth) radius: self class preferredCornerRadius fillStyle: Color black] + ifFalse: [maskCanvas fillRectangle: (localBounds insetBy: self borderWidth) fillStyle: Color black]. + mask + displayOn: form + at: 0@0 + rule: Form erase. + + self setProperty: #dropShadow toValue: form.! Item was added: + ----- Method: Morph>>useSoftDropShadow (in category 'drop shadows') ----- + useSoftDropShadow + + ^ self + valueOfProperty: #useSoftDropShadow + ifAbsent: [self class useSoftDropShadow]! Item was added: + ----- Method: Morph>>useSoftDropShadow: (in category 'drop shadows') ----- + useSoftDropShadow: aBooleanOrNil + + aBooleanOrNil + ifNil: [self removeProperty: #useSoftDropShadow] + ifNotNil: [self setProperty: #useSoftDropShadow toValue: aBooleanOrNil].! Item was changed: ----- Method: SystemProgressMorph>>setDefaultParameters (in category 'initialization') ----- setDefaultParameters "change the receiver's appareance parameters" | colorFromMenu worldColor menuColor | colorFromMenu := Preferences menuColorFromWorld and: [Display depth > 4 and: [(worldColor := self currentWorld color) isColor]]. menuColor := colorFromMenu ifTrue: [worldColor luminance > 0.7 ifTrue: [worldColor mixed: 0.85 with: Color black] ifFalse: [worldColor mixed: 0.4 with: Color white]] ifFalse: [Preferences menuColor]. self color: menuColor. MenuMorph roundedMenuCorners ifTrue: [self useRoundedCorners]. self borderWidth: Preferences menuBorderWidth. Preferences menuAppearance3d ifTrue: [ self borderStyle: BorderStyle thinGray. + self hasDropShadow: true. + + self useSoftDropShadow + ifFalse: [ + self + shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.666); + shadowOffset: 1 @ 1] + ifTrue: [ + self + shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.01); + shadowOffset: (10@8 corner: 10@12) ] - self - addDropShadow; - shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.666); - shadowOffset: 1 @ 1 ] ifFalse: [ | menuBorderColor | menuBorderColor := colorFromMenu ifTrue: [worldColor muchDarker] ifFalse: [Preferences menuBorderColor]. self borderColor: menuBorderColor. ]. self updateColor: self color: self color intensity: 1.! Item was changed: ----- Method: SystemWindow class>>refreshAllWindows (in category 'initializing') ----- refreshAllWindows "If there is some prominent UI change, use this method to update all open windows." + SystemWindow allSubInstances do: [:w | + w + setDefaultParameters; + refreshWindowColor].! - SystemWindow allSubInstances do: [:w | w refreshWindowColor].! Item was changed: ----- Method: SystemWindow class>>updatePreferences (in category 'initializing') ----- updatePreferences "Temporary method to update system-wide preferences" + Preferences installNormalWindowColors. - Preferences setPreference: #defaultWindowColor toValue: (Color veryVeryLightGray muchLighter). - (Preferences preferenceAt: #defaultWindowColor) defaultValue: (Color veryVeryLightGray muchLighter). Preferences setPreference: #menuAppearance3d toValue: true. (Preferences preferenceAt: #menuAppearance3d) defaultValue: true. Preferences setPreference: #menuColorFromWorld toValue: false. (Preferences preferenceAt: #menuColorFromWorld) defaultValue: false. MenuMorph roundedMenuCorners: false. Preferences setParameter: #menuColor to: (Color gray: 0.9). Preferences setParameter: #menuTitleColor to: (Color transparent). Preferences setParameter: #menuTitleBorderWidth to: 0. Preferences setParameter: #defaultWorldColor to: (Color gray: 0.25). Preferences setPreference: #showSplitterHandles toValue: false. (Preferences preferenceAt: #showSplitterHandles) defaultValue: true. Preferences setPreference: #showSharedFlaps toValue: false. (Preferences preferenceAt: #showSharedFlaps) defaultValue: false. - Preferences installBrightWindowColors. - CornerGripMorph drawCornerResizeHandles: false. FillInTheBlankMorph roundedDialogCorners: true. LazyListMorph listSelectionColor: LazyListMorph listSelectionColor; listSelectionTextColor: Color black. PluggableButtonMorph roundedButtonCorners: true. SystemWindow clickOnLabelToEdit: false; doubleClickOnLabelToExpand: true; moveMenuButtonRight: true; + hideExpandButton: false.! - hideExpandButton: false. - ! Item was changed: ----- Method: SystemWindow>>activateWindow (in category 'top window') ----- activateWindow "Bring me to the front and make me able to respond to mouse and keyboard. Was #activate (sw 5/18/2001 23:20)" | oldTop outerMorph sketchEditor pal | + self hasDropShadow: Preferences menuAppearance3d. + outerMorph := self topRendererOrSelf. outerMorph owner ifNil: [^ self "avoid spurious activate when drop in trash"]. oldTop := TopWindow. oldTop = self ifTrue: [^self]. TopWindow := self. oldTop ifNotNil: [oldTop passivate]. outerMorph owner firstSubmorph == outerMorph ifFalse: ["Bring me (with any flex) to the top if not already" outerMorph owner addMorphFront: outerMorph]. self submorphsDo: [:m | m unlock]. label ifNotNil: [label color: Color black]. self undimWindowButtons. labelArea ifNotNil: [labelArea submorphsDo: [:m | m unlock; show]]. self setStripeColorsFrom: self paneColorToUse; adoptPaneColor: self paneColorToUse. self isCollapsed ifFalse: [model modelWakeUpIn: self. self positionSubmorphs. labelArea ifNil: [self adjustBorderUponActivationWhenLabeless]]. (sketchEditor := self extantSketchEditor) ifNotNil: [sketchEditor comeToFront. (pal := self world findA: PaintBoxMorph) ifNotNil: [pal comeToFront]]. self updatePaneColors.! Item was changed: ----- Method: SystemWindow>>initialize (in category 'initialization') ----- initialize "Initialize a system window. Add label, stripes, etc., if desired" super initialize. self layoutPolicy: ProportionalLayout new. self initializeLabelArea. self addCornerGrips. + self setDefaultParameters. - Preferences menuAppearance3d ifTrue: [ - self - addDropShadow; - shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.333); - shadowOffset: 1@1]. - allowReframeHandles := true. isCollapsed := false. activeOnlyOnTop := true. paneMorphs := Array new. mustNotClose := false. updatablePanes := Array new.! Item was changed: ----- Method: SystemWindow>>justDroppedInto:event: (in category 'geometry') ----- justDroppedInto: aMorph event: anEvent + + self hasDropShadow: (self isActive and: [Preferences menuAppearance3d]). + isCollapsed ifTrue: [self position: ((self position max: 0@0) grid: 8@8). collapsedFrame := self bounds] ifFalse: [fullFrame := self bounds. TopWindow ~~ self ifTrue: [self activate]]. ^super justDroppedInto: aMorph event: anEvent! Item was changed: ----- Method: SystemWindow>>passivate (in category 'top window') ----- passivate "Make me unable to respond to mouse and keyboard" label ifNotNil: [label color: Color darkGray]. + self hasDropShadow: false. self paneColorToUseWhenNotActive in: [:c | self setStripeColorsFrom: c; adoptPaneColor: c]. model modelSleep. self lockInactivePortions ! Item was added: + ----- Method: SystemWindow>>setDefaultParameters (in category 'initialization') ----- + setDefaultParameters + + Preferences menuAppearance3d ifTrue: [ + self hasDropShadow: self isActive. + + self useSoftDropShadow + ifTrue: [ + self + shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.01); + shadowOffset: (10@8 corner: 10@12)] + ifFalse: [ + self + shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.333); + shadowOffset: 1@1] ]. + self changed.! Item was changed: ----- Method: SystemWindow>>setWindowColor: (in category 'colors handling') ----- setWindowColor: incomingColor | existingColor aColor | incomingColor ifNil: [^ self]. "it happens" + aColor := incomingColor. - aColor := incomingColor asNontranslucentColor. (aColor = ColorPickerMorph perniciousBorderColor or: [aColor = Color black]) ifTrue: [^ self]. existingColor := self paneColorToUse. existingColor ifNil: [^ Beeper beep]. self paneColor: aColor. self setStripeColorsFrom: aColor. self changed.! Item was changed: ----- Method: SystemWindow>>startDragFromLabel: (in category 'events') ----- startDragFromLabel: evt "When label events are active, we need to pass dragging to the window explicitely The window only recognizes a drag with an offset of more than 3 pixels" self isSticky ifTrue: [^ self]. self fastFramingOn ifTrue: [self doFastFrameDrag: evt cursorPoint] + ifFalse: [ + self hasDropShadow: false. + evt hand grabMorph: self topRendererOrSelf] - ifFalse: [evt hand grabMorph: self topRendererOrSelf] ! Item was changed: ----- Method: UserDialogBoxMorph>>initialize (in category 'initialization') ----- initialize | titleRow cc | super initialize. self color: Color white. self listDirection: #topToBottom; wrapCentering: #center; hResizing: #shrinkWrap; vResizing: #shrinkWrap. self layoutInset: -1 @ -1; cellInset: 5@5. self borderStyle: BorderStyle thinGray. + self useRoundedCorners. + self hasDropShadow: true. + self useSoftDropShadow + ifFalse: [ + self + shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.666); + shadowOffset: 1 @ 1] + ifTrue: [ + self + shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.01); + shadowOffset: (10@8 corner: 10@12)]. - self - useRoundedCorners; - addDropShadow; - shadowColor: (TranslucentColor r: 0.0 g: 0.0 b: 0.0 alpha: 0.666); - shadowOffset: 1 @ 1. cc := Color gray: 0.8. titleRow := AlignmentMorph newRow. titleRow hResizing: #spaceFill; vResizing: #shrinkWrap. titleRow useRoundedCorners. titleRow borderStyle: BorderStyle thinGray. titleRow layoutInset: (2@5 corner: (2@ (5 + Morph preferredCornerRadius))). titleRow color: cc. titleRow fillStyle: self titleGradient. titleMorph := StringMorph new. titleMorph emphasis: 1. titleRow addMorph: titleMorph. labelMorph := TextMorph new. labelMorph margins: 5@5. labelMorph lock. buttonRow := AlignmentMorph newRow vResizing: #shrinkWrap. buttonRow hResizing: #shrinkWrap; layoutInset: 5@5; cellInset: 5@5. buttonRow color: Color transparent. self addMorphBack: titleRow ; addMorphBack: labelMorph ; + addMorphBack: buttonRow. - addMorphBack: buttonRow ; - addDropShadow. keyMap := Dictionary new! From commits at source.squeak.org Mon Apr 6 12:37:38 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Mon Apr 6 12:37:39 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.826.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.826.mcz ==================== Summary ==================== Name: Morphic-mt.826 Author: mt Time: 6 April 2015, 2:37:06.62 pm UUID: 0a932bc9-fd3a-9a4e-8f62-cf07d7d3cc5d Ancestors: Morphic-mt.825 Added drop-shadow-cache invalidation to layout-specific call back where bounds are directly written. *sigh* =============== Diff against Morphic-mt.825 =============== Item was changed: ----- Method: Morph>>layoutBounds: (in category 'layout') ----- layoutBounds: aRectangle "Set the bounds for laying out children of the receiver. Note: written so that #layoutBounds can be changed without touching this method" | priorBounds outer inner box | priorBounds := self outerBounds. outer := self bounds. inner := self layoutBounds. bounds := aRectangle origin + (outer origin - inner origin) corner: aRectangle corner + (outer corner - inner corner). + self removeProperty: #dropShadow. box := self outerBounds. box = priorBounds ifFalse: [self invalidRect: (priorBounds quickMerge: box)]! From commits at source.squeak.org Mon Apr 6 13:03:18 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Mon Apr 6 13:03:19 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.827.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.827.mcz ==================== Summary ==================== Name: Morphic-mt.827 Author: mt Time: 6 April 2015, 3:02:38.867 pm UUID: f431d9b2-5786-5d4e-94ae-88f16b811845 Ancestors: Morphic-mt.826 Fixed menu positioning bug (which occured in the Squeak-menu with soft shadows enabled). Always do layout using your bounds or innerBounds (or even outerBounds) but never fullBounds, which is only an internal layout cache. =============== Diff against Morphic-mt.826 =============== Item was changed: ----- Method: MenuMorph>>popUpAdjacentTo:forHand:from: (in category 'control') ----- popUpAdjacentTo: rightOrLeftPoint forHand: hand from: sourceItem "Present this menu at the given point under control of the given hand." | tryToPlace selectedOffset rightPoint leftPoint | hand world startSteppingSubmorphsOf: self. popUpOwner := sourceItem. self fullBounds. self updateColor. + - "ensure layout is current" selectedOffset := (selectedItem ifNil: [self items first]) position - self position. tryToPlace := [:where :mustFit | | delta | self position: where - selectedOffset. + delta := self boundsInWorld amountToTranslateWithin: sourceItem worldBounds. - delta := self fullBoundsInWorld amountToTranslateWithin: sourceItem worldBounds. (delta x = 0 or: [mustFit]) ifTrue: [delta = (0 @ 0) ifFalse: [self position: self position + delta]. sourceItem owner owner addMorphFront: self. ^ self]]. rightPoint := rightOrLeftPoint first + ((self layoutInset + self borderWidth) @ 0). leftPoint := rightOrLeftPoint last - ((self layoutInset + self borderWidth + self width) @ 0). tryToPlace value: rightPoint value: false; value: leftPoint value: false; value: rightPoint value: true.! From btc at openinworld.com Mon Apr 6 13:32:11 2015 From: btc at openinworld.com (Ben Coman) Date: Mon Apr 6 13:32:35 2015 Subject: [squeak-dev] Canadian Smalltalk Competition Message-ID: Richard Eng visited the Pharo community a while ago being very enthusiastic about his Smalltalk Renaissance project. His strategy didn't end up fitting the community, but I find his kickstarter to run a Smalltalk coding competition for secondary students interesting. Apart from straight altruism to support it, providing a wide exposure of students to the concept of Smalltalk just before they enter university should generate some spillover to our communities. A rising tide lifts all ships. And community networking is a funny thing, some of those students will have parents in strategic positions who would never otherwise be exposed to Smalltalk. Its worth considering.... https://www.kickstarter.com/projects/1520902870/canadian-smalltalk-competition cheers -ben -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150406/18e040f4/attachment.htm From asqueaker at gmail.com Mon Apr 6 16:02:22 2015 From: asqueaker at gmail.com (Chris Muller) Date: Mon Apr 6 16:02:27 2015 Subject: [squeak-dev] Adding WebClient and SqueakSSL to Trunk? In-Reply-To: <1428247573797-4817693.post@n4.nabble.com> References: <1428247573797-4817693.post@n4.nabble.com> Message-ID: On Sun, Apr 5, 2015 at 10:26 AM, Marcel Taeumel wrote: > Hey! :) > > Can we add both to the update map (somehow?) and see if it works out during > the following days/weeks until the release? +1 From lewis at mail.msen.com Mon Apr 6 16:59:00 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Mon Apr 6 16:59:03 2015 Subject: [squeak-dev] Adding WebClient and SqueakSSL to Trunk? In-Reply-To: References: <1428247573797-4817693.post@n4.nabble.com> Message-ID: <56781.136.2.1.105.1428339540.squirrel@webmail.msen.com> > On Sun, Apr 5, 2015 at 10:26 AM, Marcel Taeumel > wrote: >> Hey! :) >> >> Can we add both to the update map (somehow?) and see if it works out >> during >> the following days/weeks until the release? > > +1 > What is the point of moving these into the base image? Aren't these exactly the kinds of things that you would want to have maintained as independent packages that can be easily loaded from SqueakMap? Dave From Das.Linux at gmx.de Mon Apr 6 17:01:55 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Mon Apr 6 17:01:59 2015 Subject: [squeak-dev] Who's #squeak's op? Message-ID: Hey who is the channel operator for Squeak's channel on Freenode? I'd like to request to include a link to the logs into the Topic: Logs: http://tunes.org/~nef/logs/squeak/ Best -Tobias From Das.Linux at gmx.de Mon Apr 6 17:05:04 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Mon Apr 6 17:05:09 2015 Subject: [squeak-dev] Adding WebClient and SqueakSSL to Trunk? In-Reply-To: <56781.136.2.1.105.1428339540.squirrel@webmail.msen.com> References: <1428247573797-4817693.post@n4.nabble.com> <56781.136.2.1.105.1428339540.squirrel@webmail.msen.com> Message-ID: On 06.04.2015, at 18:59, David T. Lewis wrote: >> On Sun, Apr 5, 2015 at 10:26 AM, Marcel Taeumel >> wrote: >>> Hey! :) >>> >>> Can we add both to the update map (somehow?) and see if it works out >>> during >>> the following days/weeks until the release? >> >> +1 >> > > What is the point of moving these into the base image? Aren't these > exactly the kinds of things that you would want to have maintained as > independent packages that can be easily loaded from SqueakMap? I think both these are Extremely Important (capital). WebClient as replacement for HTTPSocket (it already provides a compatibility layer; Andreas seemed to always considered WebClient to replace HTTPSocket), and SqueakSSL because you can't load anything meaningful on the web without SSL; github, twitter, most sites. And that's good. Plus we _finally_ could put the Plain Text Passwords for Monticello behind SSL? Best -Tobias From marcel.taeumel at student.hpi.uni-potsdam.de Mon Apr 6 17:47:48 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Mon Apr 6 18:00:07 2015 Subject: [squeak-dev] Re: Adding WebClient and SqueakSSL to Trunk? In-Reply-To: <56781.136.2.1.105.1428339540.squirrel@webmail.msen.com> References: <1428247573797-4817693.post@n4.nabble.com> <56781.136.2.1.105.1428339540.squirrel@webmail.msen.com> Message-ID: <1428342468782-4817864.post@n4.nabble.com> Squeak should be able to retrieve content from an HTTPS-Url out-of-the-box. :) Best, Marcel -- View this message in context: http://forum.world.st/Adding-WebClient-and-SqueakSSL-to-Trunk-tp4817693p4817864.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From lewis at mail.msen.com Mon Apr 6 18:02:12 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Mon Apr 6 18:02:15 2015 Subject: [squeak-dev] Adding WebClient and SqueakSSL to Trunk? In-Reply-To: References: <1428247573797-4817693.post@n4.nabble.com> <56781.136.2.1.105.1428339540.squirrel@webmail.msen.com> Message-ID: <2239.136.2.1.105.1428343332.squirrel@webmail.msen.com> > > On 06.04.2015, at 18:59, David T. Lewis wrote: > >>> On Sun, Apr 5, 2015 at 10:26 AM, Marcel Taeumel >>> wrote: >>>> Hey! :) >>>> >>>> Can we add both to the update map (somehow?) and see if it works out >>>> during >>>> the following days/weeks until the release? >>> >>> +1 >>> >> >> What is the point of moving these into the base image? Aren't these >> exactly the kinds of things that you would want to have maintained as >> independent packages that can be easily loaded from SqueakMap? > > I think both these are Extremely Important (capital). > WebClient as replacement for HTTPSocket (it already provides a > compatibility > layer; Andreas seemed to always considered WebClient to replace > HTTPSocket), > and SqueakSSL because you can't load anything meaningful on the web > without > SSL; github, twitter, most sites. And that's good. > Plus we _finally_ could put the Plain Text Passwords for Monticello behind > SSL > OK that makes sense :-) Dave From leves at elte.hu Mon Apr 6 18:43:12 2015 From: leves at elte.hu (Levente Uzonyi) Date: Mon Apr 6 18:43:18 2015 Subject: [squeak-dev] Adding WebClient and SqueakSSL to Trunk? In-Reply-To: References: <1428247573797-4817693.post@n4.nabble.com> <56781.136.2.1.105.1428339540.squirrel@webmail.msen.com> Message-ID: It would be better for these packages too, because they would get more attention. The SqueakSSL/WebClient changes I made in October[1] are still missing from the official repositories. Levente [1] http://lists.squeakfoundation.org/pipermail/squeak-dev/2014-October/180251.html On Mon, 6 Apr 2015, Tobias Pape wrote: > > On 06.04.2015, at 18:59, David T. Lewis wrote: > >>> On Sun, Apr 5, 2015 at 10:26 AM, Marcel Taeumel >>> wrote: >>>> Hey! :) >>>> >>>> Can we add both to the update map (somehow?) and see if it works out >>>> during >>>> the following days/weeks until the release? >>> >>> +1 >>> >> >> What is the point of moving these into the base image? Aren't these >> exactly the kinds of things that you would want to have maintained as >> independent packages that can be easily loaded from SqueakMap? > > I think both these are Extremely Important (capital). > WebClient as replacement for HTTPSocket (it already provides a compatibility > layer; Andreas seemed to always considered WebClient to replace HTTPSocket), > and SqueakSSL because you can't load anything meaningful on the web without > SSL; github, twitter, most sites. And that's good. > Plus we _finally_ could put the Plain Text Passwords for Monticello behind > SSL? > > Best > -Tobias > From leves at elte.hu Mon Apr 6 19:22:45 2015 From: leves at elte.hu (Levente Uzonyi) Date: Mon Apr 6 19:22:50 2015 Subject: [squeak-dev] The Trunk: CollectionsTests-ul.235.mcz In-Reply-To: <20150406034426.GA5059@shell.msen.com> References: <20150406034426.GA5059@shell.msen.com> Message-ID: Thanks Dave! Levente On Sun, 5 Apr 2015, David T. Lewis wrote: > Version CollectionsTests-ul.235.mcz is deleted from trunk. > > Dave > > > On Sun, Apr 05, 2015 at 10:43:29PM +0200, Levente Uzonyi wrote: >> This is an unintended commit of an old version of this package. >> I'd delete/move it, but only admins can do that. So Board members, >> please delete it, or move it to the Treated Inbox. >> >> TIA, >> Levente >> >> On Sun, 5 Apr 2015, commits@source.squeak.org wrote: >> >>> Levente Uzonyi uploaded a new version of CollectionsTests to project The >>> Trunk: >>> http://source.squeak.org/trunk/CollectionsTests-ul.235.mcz >>> >>> ==================== Summary ==================== >>> >>> Name: CollectionsTests-ul.235 >>> Author: ul >>> Time: 19 January 2015, 10:51:37.525 pm >>> UUID: 4e40f650-e20c-4e52-88f1-6b72e04f9a3a >>> Ancestors: CollectionsTests-mt.234 >>> >>> Don't reference the lastIndex variable, because it's gone. Use exact >>> values instead. >>> >>> =============== Diff against CollectionsTests-mt.234 =============== >>> >>> Item was changed: >>> ----- Method: OrderedDictionaryTest>>testCompact (in category 'tests') >>> ----- >>> testCompact >>> >>> | oldCapacity | >>> 1 to: 3 do: [:ea | >>> sut at: ea put: nil]. >>> + self assert: 3 equals: sut size. >>> - self assert: sut size equals: (sut instVarNamed: #lastIndex). >>> >>> sut removeKey: 2. >>> + self assert: 2 equals: sut size. >>> - self assert: sut size equals: (sut instVarNamed: #lastIndex) - 1. >>> >>> oldCapacity := sut capacity. >>> 4 to: 20 do: [:ea | >>> sut at: ea put: nil]. >>> self >>> assert: sut capacity > oldCapacity; >>> + assert: 19 equals: sut size >>> - assert: sut size equals: (sut instVarNamed: #lastIndex). >>> ! >>> >>> >>> > > From Das.Linux at gmx.de Mon Apr 6 19:22:48 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Mon Apr 6 19:22:53 2015 Subject: [squeak-dev] Adding WebClient and SqueakSSL to Trunk? In-Reply-To: References: <1428247573797-4817693.post@n4.nabble.com> <56781.136.2.1.105.1428339540.squirrel@webmail.msen.com> Message-ID: <7D10A95B-7E3C-43A2-9308-1237B30480DC@gmx.de> Hi Levente On 06.04.2015, at 20:43, Levente Uzonyi wrote: > It would be better for these packages too, because they would get more > attention. > The SqueakSSL/WebClient changes I made in October[1] are still missing from the official repositories. > > Levente > > [1] http://lists.squeakfoundation.org/pipermail/squeak-dev/2014-October/180251.html > I just now saw that there is more than just vm stuff. The problem with WebClient and SqueakSSL as of now is, that its maintenance-ship is, well, complicated. I went forth and pushed tiny changes to WebClient by just being somewhat on my own initiative[1]. =========== Dear Squeak Community as a whole and dear Ron as person possibly best fit to make a decision on this: Should we put the maintainer-ship of WebClient and SqueakSSL into the hands of the Squeak Core Team? =========== Best -Tobias [1]: There's a saying, initiative is discipline-lessness with positive outcome > On Mon, 6 Apr 2015, Tobias Pape wrote: > >> >> On 06.04.2015, at 18:59, David T. Lewis wrote: >> >>>> On Sun, Apr 5, 2015 at 10:26 AM, Marcel Taeumel >>>> wrote: >>>>> Hey! :) >>>>> >>>>> Can we add both to the update map (somehow?) and see if it works out >>>>> during >>>>> the following days/weeks until the release? >>>> >>>> +1 >>>> >>> >>> What is the point of moving these into the base image? Aren't these >>> exactly the kinds of things that you would want to have maintained as >>> independent packages that can be easily loaded from SqueakMap? >> >> I think both these are Extremely Important (capital). >> WebClient as replacement for HTTPSocket (it already provides a compatibility >> layer; Andreas seemed to always considered WebClient to replace HTTPSocket), >> and SqueakSSL because you can't load anything meaningful on the web without >> SSL; github, twitter, most sites. And that's good. >> Plus we _finally_ could put the Plain Text Passwords for Monticello behind >> SSL? >> >> Best >> -Tobias From commits at source.squeak.org Mon Apr 6 21:55:02 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Mon Apr 6 21:55:03 2015 Subject: [squeak-dev] Daily Commit Log Message-ID: <20150406215502.10267.qmail@box4.squeakfoundation.org> Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours: http://lists.squeakfoundation.org/pipermail/packages/2015-April/007826.html Name: Morphic-mt.825 Ancestors: Morphic-mt.824 Soft drop shadows introduced and *disabled* by default. Cache added to shadow drawing (including regular/sharp shadows), which will be updated on extent updates. This commit also cleans-up some shadow-related code. Note: This does not change the way hand morphs compute their drop shadows when dragging morphs around! There always have been two seprate concepts for drop shadows. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007827.html Name: Morphic-mt.826 Ancestors: Morphic-mt.825 Added drop-shadow-cache invalidation to layout-specific call back where bounds are directly written. *sigh* ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007828.html Name: Morphic-mt.827 Ancestors: Morphic-mt.826 Fixed menu positioning bug (which occured in the Squeak-menu with soft shadows enabled). Always do layout using your bounds or innerBounds (or even outerBounds) but never fullBounds, which is only an internal layout cache. ============================================= From commits at source.squeak.org Mon Apr 6 22:52:23 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Mon Apr 6 22:52:24 2015 Subject: [squeak-dev] The Inbox: ShoutCore-cmm.45.mcz Message-ID: A new version of ShoutCore was added to project The Inbox: http://source.squeak.org/inbox/ShoutCore-cmm.45.mcz ==================== Summary ==================== Name: ShoutCore-cmm.45 Author: cmm Time: 6 April 2015, 5:52:19.582 pm UUID: 7f2c4864-c8d9-4f51-8553-23db02266ad0 Ancestors: ShoutCore-cmm.44 - Added subdued version of Shout colors proposed in cmm.44. - #defaultStyleTable is misnamed because it was was not the default. Renamed it to #brightStyleTable. - Simplify help text for #subduedSyntaxHighlights. =============== Diff against ShoutCore-cmm.44 =============== Item was added: + ----- Method: SHTextStylerST80 class>>brightStyleTable (in category 'style table') ----- + brightStyleTable + "color can be a valid argument to Color class>>colorFrom: , or nil to + use the editor text color. + Multiple emphases can be specified using an array e.g. #(bold italic). + If emphasis is not specified, #normal will be used. + if pixel height is not specified , then the editor font size will be used. + " + + ^#( + "(symbol color [emphasisSymbolOrArray [textStyleName [pixelHeight]]])" + (default black ) + (invalid (magenta twiceDarker) ) + (excessCode (magenta twiceDarker) ) + (comment (gray) italic) + (unfinishedComment (gray) italic) + (#'$' (black) ) + (character (red twiceDarker ) ) + (integer (red twiceDarker ) ) + (number (red twiceDarker ) ) + (#- (black) ) + (symbol (black ) ) + (stringSymbol (black ) ) + (literalArray (black ) ) + (string (red twiceDarker) normal ) + (unfinishedString red normal ) + (assignment black bold ) + (ansiAssignment black bold) + (literal (red twiceDarker) italic) + (keyword (green muchDarker) ) + (binary (black ) (bold)) + (unary (green muchDarker ) ) + (incompleteKeyword (green darker) underlined) + (incompleteBinary (green darker) underlined) + (incompleteUnary (green darker) underlined) + (undefinedKeyword (magenta twiceDarker) ) + (undefinedBinary (magenta twiceDarker) ) + (undefinedUnary (magenta twiceDarker) ) + (patternKeyword (green muchDarker) (underlined bold)) + (patternBinary (green muchDarker) (bold)) + (patternUnary (green muchDarker) (underlined bold)) + (#self (black) bold) + (#super (black) bold) + (#true (black) bold) + (#false (black) bold) + (#nil (black) bold) + (#thisContext (black) bold) + (#return (black) bold) + (patternArg (orange muchDarker) ) + (methodArg (orange muchDarker) ) + (blockPatternArg (orange muchDarker) ) + (blockArg (orange muchDarker) ) + (argument (orange muchDarker) ) + (blockArgColon black ) + (leftParenthesis black ) + (rightParenthesis black ) + (leftParenthesis1 (black) ) + (rightParenthesis1 (black) ) + (leftParenthesis2 (gray twiceDarker) ) + (rightParenthesis2 (gray twiceDarker) ) + (leftParenthesis3 (blue twiceDarker) ) + (rightParenthesis3 (blue twiceDarker) ) + (leftParenthesis4 (green twiceDarker) ) + (rightParenthesis4 (green twiceDarker) ) + (leftParenthesis5 (orange twiceDarker) ) + (rightParenthesis5 (orange twiceDarker) ) + (leftParenthesis6 (red twiceDarker) ) + (rightParenthesis6 (red twiceDarker) ) + (leftParenthesis7 brown ) + (rightParenthesis7 brown ) + (blockStart black ) + (blockEnd black ) + (blockStart1 (black) ) + (blockEnd1 (black) ) + (blockStart2 (gray twiceDarker) ) + (blockEnd2 (gray twiceDarker) ) + (blockStart3 (blue twiceDarker) ) + (blockEnd3 (blue twiceDarker) ) + (blockStart4 (green twiceDarker) ) + (blockEnd4 (green twiceDarker) ) + (blockStart5 (orange twiceDarker) ) + (blockEnd5 (orange twiceDarker) ) + (blockStart6 (red twiceDarker) ) + (blockEnd6 (red twiceDarker) ) + (blockStart7 (brown) ) + (blockEnd7 (brown) ) + (arrayStart black ) + (arrayEnd black ) + (arrayStart1 black ) + (arrayEnd1 black ) + (byteArrayStart black ) + (byteArrayEnd black ) + (byteArrayStart1 black ) + (byteArrayEnd1 black ) + (leftBrace black ) + (rightBrace black ) + (cascadeSeparator black ) + (statementSeparator black ) + (externalCallType black ) + (externalCallTypePointerIndicator black ) + (primitiveOrExternalCallStart black ) + (primitiveOrExternalCallEnd black ) + (methodTempBar black ) + (blockTempBar black ) + (blockArgsBar black ) + (primitive (green muchDarker) bold) + (externalFunctionCallingConvention (green muchDarker) bold) + (module (green muchDarker) bold) + (blockTempVar (cyan muchDarker ) italic) + (blockPatternTempVar (cyan muchDarker ) italic) + (instVar (yellow twiceDarker darker) bold) + (workspaceVar black bold) + (undefinedIdentifier (magenta twiceDarker) normal) + (incompleteIdentifier (gray darker) (italic underlined)) + (tempVar (cyan muchDarker) italic) + (patternTempVar (cyan muchDarker) italic) + (poolConstant (blue lighter) italic) + (classVar (blue twiceLighter) italic) + (globalVar black normal) ) + ! Item was changed: ----- Method: SHTextStylerST80 class>>chooseDefaultStyleTable (in category 'style table') ----- chooseDefaultStyleTable "Choose the default style table" ^self subduedSyntaxHighlights ifTrue:[self subduedStyleTable] + ifFalse:[self brightStyleTable]! - ifFalse:[self defaultStyleTable]! Item was changed: ----- Method: SHTextStylerST80 class>>subduedStyleTable (in category 'style table') ----- subduedStyleTable "color can be a valid argument to Color class>>colorFrom: , or nil to use the editor text color. Multiple emphases can be specified using an array e.g. #(bold italic). If emphasis is not specified, #normal will be used. if pixel height is not specified , then the editor font size will be used. " ^#( "(symbol color [emphasisSymbolOrArray [textStyleName [pixelHeight]]])" (default black ) + (invalid (magenta duller duller muchDarker) ) + (excessCode (magenta duller duller muchDarker) ) + (comment (darkGray) italic) + (unfinishedComment (darkGray) italic) + (#'$' (black) ) + (character (red duller duller duller twiceDarker ) ) + (integer (red duller duller duller twiceDarker ) ) + (number (red duller duller duller twiceDarker ) ) + (#- (black) ) + (symbol (black ) ) + (stringSymbol (black ) ) + (literalArray (black ) ) + (string (red duller duller duller twiceDarker) normal ) + (unfinishedString (red duller duller duller twiceDarker) normal ) + (assignment black bold ) + (ansiAssignment black bold) + (literal (red duller duller duller twiceDarker) italic) + (keyword (green duller duller muchDarker) normal) + (binary (black ) (bold)) + (unary (green duller duller muchDarker ) ) + (incompleteKeyword (green duller duller darker) underlined) + (incompleteBinary (green duller duller darker) underlined) + (incompleteUnary (green duller duller darker) underlined) + (undefinedKeyword (magenta duller duller twiceDarker) ) + (undefinedBinary (magenta duller duller twiceDarker) ) + (undefinedUnary (magenta duller duller twiceDarker) ) + (patternKeyword (green duller duller muchDarker) (underlined bold)) + (patternBinary (green duller duller muchDarker) (bold)) + (patternUnary (green duller duller muchDarker) (underlined bold)) + (#self (black) normal) + (#super (black) normal) + (#true (black) normal) + (#false (black) normal) + (#nil (black) normal) + (#thisContext (black) normal) + (#return (black) bold) + (patternArg (orange duller duller duller muchDarker) ) + (methodArg (orange duller duller duller muchDarker) ) + (blockPatternArg (orange duller duller duller muchDarker) ) + (blockArg (orange duller duller duller muchDarker) ) + (argument (orange duller duller duller muchDarker) ) - (invalid red ) - (excessCode red ) - (comment (cyan muchDarker) ) - (unfinishedComment (red muchDarker) italic) - (#'$' (red muchDarker) ) - (character (red muchDarker) ) - (integer (red muchDarker) ) - (number (red muchDarker) ) - (#- (red muchDarker) ) - (symbol (blue muchDarker) ) - (stringSymbol (blue muchDarker) ) - (literalArray (blue muchDarker) ) - (string (magenta muchDarker) normal ) - (unfinishedString red normal ) - (assignment nil bold ) - (ansiAssignment nil bold) - (literal nil italic) - (keyword (blue muchDarker) ) - (binary (blue muchDarker) ) - (unary (blue muchDarker) ) - (incompleteKeyword (gray muchDarker) underlined) - (incompleteBinary (gray muchDarker) underlined) - (incompleteUnary (gray muchDarker) underlined) - (undefinedKeyword red ) - (undefinedBinary red ) - (undefinedUnary red ) - (patternKeyword nil bold) - (patternBinary nil bold) - (patternUnary nil bold) - (#self (red muchDarker) ) - (#super (red muchDarker) ) - (#true (red muchDarker) ) - (#false (red muchDarker) ) - (#nil (red muchDarker) ) - (#thisContext (red muchDarker) ) - (#return (red muchDarker) ) - (patternArg (blue muchDarker) ) - (methodArg (blue muchDarker) ) - (blockPatternArg (blue muchDarker) ) - (blockArg (blue muchDarker) ) - (argument (blue muchDarker) ) (blockArgColon black ) + (leftParenthesis black ) - (leftParenthesis black ) (rightParenthesis black ) + (leftParenthesis1 (black) ) + (rightParenthesis1 (black) ) + (leftParenthesis2 (black) ) + (rightParenthesis2 (black) ) + (leftParenthesis3 (black) ) + (rightParenthesis3 (black) ) + (leftParenthesis4 (black) ) + (rightParenthesis4 (black) ) + (leftParenthesis5 (black) ) + (rightParenthesis5 (black) ) + (leftParenthesis6 (black) ) + (rightParenthesis6 (black) ) + (leftParenthesis7 brown ) + (rightParenthesis7 brown ) - (leftParenthesis1 (green muchDarker) ) - (rightParenthesis1 (green muchDarker) ) - (leftParenthesis2 (magenta muchDarker) ) - (rightParenthesis2 (magenta muchDarker) ) - (leftParenthesis3 (red muchDarker) ) - (rightParenthesis3 (red muchDarker) ) - (leftParenthesis4 (green darker) ) - (rightParenthesis4 (green darker) ) - (leftParenthesis5 (orange darker) ) - (rightParenthesis5 (orange darker) ) - (leftParenthesis6 (magenta darker) ) - (rightParenthesis6 (magenta darker) ) - (leftParenthesis7 blue ) - (rightParenthesis7 blue ) (blockStart black ) (blockEnd black ) + (blockStart1 (black) ) + (blockEnd1 (black) ) + (blockStart2 (black) ) + (blockEnd2 (black) ) + (blockStart3 (black) ) + (blockEnd3 (black) ) + (blockStart4 (black) ) + (blockEnd4 (black) ) + (blockStart5 (black) ) + (blockEnd5 (black) ) + (blockStart6 (black) ) + (blockEnd6 (black) ) + (blockStart7 (black) ) + (blockEnd7 (black) ) - (blockStart1 (green muchDarker) ) - (blockEnd1 (green muchDarker) ) - (blockStart2 (magenta muchDarker) ) - (blockEnd2 (magenta muchDarker) ) - (blockStart3 (red muchDarker) ) - (blockEnd3 (red muchDarker) ) - (blockStart4 (green darker) ) - (blockEnd4 (green darker) ) - (blockStart5 (orange darker) ) - (blockEnd5 (orange darker) ) - (blockStart6 (magenta darker) ) - (blockEnd6 (magenta darker) ) - (blockStart7 blue ) - (blockEnd7 blue ) (arrayStart black ) (arrayEnd black ) (arrayStart1 black ) (arrayEnd1 black ) + (byteArrayStart black ) + (byteArrayEnd black ) + (byteArrayStart1 black ) + (byteArrayEnd1 black ) - (byteArrayStart black ) - (byteArrayEnd black ) - (byteArrayStart1 black ) - (byteArrayEnd1 black ) (leftBrace black ) (rightBrace black ) + (cascadeSeparator black ) + (statementSeparator black ) - (cascadeSeparator black ) - (statementSeparator black ) (externalCallType black ) (externalCallTypePointerIndicator black ) (primitiveOrExternalCallStart black ) (primitiveOrExternalCallEnd black ) + (methodTempBar black ) + (blockTempBar black ) + (blockArgsBar black ) + (primitive (green duller duller muchDarker) bold) + (externalFunctionCallingConvention (green duller duller muchDarker) bold) + (module (green duller duller muchDarker) bold) + (blockTempVar (cyan duller duller duller muchDarker ) italic) + (blockPatternTempVar (cyan duller duller duller muchDarker ) italic) + (instVar (blue duller duller duller darker) normal) + (workspaceVar black bold) + (undefinedIdentifier (magenta duller duller twiceDarker) normal) - (methodTempBar gray ) - (blockTempBar gray ) - (blockArgsBar gray ) - (primitive (green muchDarker) bold) - (pragmaKeyword (green muchDarker) bold) - (pragmaUnary (green muchDarker) bold) - (pragmaBinary (green muchDarker) bold) - (externalFunctionCallingConvention (green muchDarker) bold) - (module (green muchDarker) bold) - (blockTempVar gray ) - (blockPatternTempVar gray ) - (instVar black ) - (workspaceVar black ) - (undefinedIdentifier red ) (incompleteIdentifier (gray darker) (italic underlined)) + (tempVar (cyan duller duller duller muchDarker) italic) + (patternTempVar (cyan duller duller duller muchDarker) italic) + (poolConstant (blue lighter) italic) + (classVar (blue duller duller duller darker) italic) + (globalVar black normal) ) + ! - (tempVar (gray darker) ) - (patternTempVar (gray darker) ) - (poolConstant (gray muchDarker) ) - (classVar (gray muchDarker) ) - (globalVar black ) )! Item was changed: ----- Method: SHTextStylerST80 class>>subduedSyntaxHighlights (in category 'preferences') ----- subduedSyntaxHighlights + ^SubduedSyntaxHighlights ifNil: [ true ]! - ^SubduedSyntaxHighlights ifNil:[true]! From ma.chris.m at gmail.com Mon Apr 6 23:38:26 2015 From: ma.chris.m at gmail.com (Chris Muller) Date: Mon Apr 6 23:38:29 2015 Subject: [squeak-dev] search bar problems Message-ID: The search bar has developed a couple of issues that has rendered it a lot less useful than before: - It now only supports input instead both input and output. e.g., it no longer expands when its capacity is exceeded, so not only can I not see the expression I'm typing, I can't see any reasonable output in there because its stuck to be so tiny. - When I press Control+0, my prior contents are deleted! This is a real pain because I use a quick gesture to retop the window I last accessed (which since got buried by other windows) by simply pressing Command+0+b (for example). Now since my contents are erased I cannot do that unless I remember and retype it what I had before.. I see SearchBar>>#activate:in: says "we cannot select all here". Really? All the power of ToolBuilder and MVC cannot do that? This is frustrating because as a user I don't care if the code is "cleaner" if it causes usability to suffer this much. I really just want a plain ol'e TextMorph up there. I never found the search functionality useful because it never opens the kind of browser I want.. From tim at rowledge.org Tue Apr 7 00:18:42 2015 From: tim at rowledge.org (tim Rowledge) Date: Tue Apr 7 00:18:51 2015 Subject: [squeak-dev] search bar problems In-Reply-To: References: Message-ID: <213BDBD4-F744-49DE-9897-E01944F79C67@rowledge.org> On 06-04-2015, at 4:38 PM, Chris Muller wrote: > > I really just want a plain ol'e TextMorph up there. I never found the > search functionality useful because it never opens the kind of browser > I want.. > A related complaint - when you enter a message that completely matches you don?t get a MessageNames window you get only the implementors of that message. So you end up having to enter ?siz? in order to get all messages containing size, for example. I?m sure somebody thought it was a good idea but all in all I?m going to have to demur. tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim Manual Writer's Creed: Garbage in, gospel out. From marcel.taeumel at student.hpi.uni-potsdam.de Tue Apr 7 06:37:19 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Tue Apr 7 06:49:44 2015 Subject: [squeak-dev] Re: search bar problems In-Reply-To: References: Message-ID: <1428388639553-4817932.post@n4.nabble.com> https://xkcd.com/1172/ :) I will look into it. Btw: No, we don't want the primitive TextMorph there. We want something that scrolls to the side instead of "destroying" the docking bar layout. ;-) Best, Marcel -- View this message in context: http://forum.world.st/search-bar-problems-tp4817914p4817932.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Tue Apr 7 06:38:34 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Tue Apr 7 06:50:55 2015 Subject: [squeak-dev] Re: search bar problems In-Reply-To: <213BDBD4-F744-49DE-9897-E01944F79C67@rowledge.org> References: <213BDBD4-F744-49DE-9897-E01944F79C67@rowledge.org> Message-ID: <1428388714268-4817933.post@n4.nabble.com> Yeah, there has been always to much magic in the search bar that keeps on surprising me. Best, Marcel -- View this message in context: http://forum.world.st/search-bar-problems-tp4817914p4817933.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From leves at elte.hu Tue Apr 7 07:11:30 2015 From: leves at elte.hu (Levente Uzonyi) Date: Tue Apr 7 07:11:35 2015 Subject: [squeak-dev] Re: search bar problems In-Reply-To: <1428388639553-4817932.post@n4.nabble.com> References: <1428388639553-4817932.post@n4.nabble.com> Message-ID: The original plan was to let the search bar grow vertically, but keep the docking bar's height intact[1]. Levente [1] http://lists.squeakfoundation.org/pipermail/squeak-dev/2010-April/149517.html On Mon, 6 Apr 2015, Marcel Taeumel wrote: > https://xkcd.com/1172/ :) > > I will look into it. > > Btw: No, we don't want the primitive TextMorph there. We want something that > scrolls to the side instead of "destroying" the docking bar layout. ;-) > > Best, > Marcel > > > > -- > View this message in context: http://forum.world.st/search-bar-problems-tp4817914p4817932.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > From commits at source.squeak.org Tue Apr 7 07:12:35 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 07:12:37 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Kernel-mt.73.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Kernel to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Kernel-mt.73.mcz ==================== Summary ==================== Name: ToolBuilder-Kernel-mt.73 Author: mt Time: 7 April 2015, 9:12:27.853 am UUID: 57fb3dea-b8ef-3944-abe9-7dbde14bac8e Ancestors: ToolBuilder-Kernel-mt.72 Pluggable text spec extended to provide an edit-selector, which gives the model a chance to be notified about *any* edits (not only accepts): =============== Diff against ToolBuilder-Kernel-mt.72 =============== Item was changed: PluggableWidgetSpec subclass: #PluggableTextSpec + instanceVariableNames: 'getText setText selection menu askBeforeDiscardingEdits editText' - instanceVariableNames: 'getText setText selection menu askBeforeDiscardingEdits' classVariableNames: '' poolDictionaries: '' category: 'ToolBuilder-Kernel'! !PluggableTextSpec commentStamp: 'ar 2/11/2005 21:58' prior: 0! A text editor. Instance variables: getText The selector to retrieve the text. setText The selector to set the text. selection The selector to retrieve the text selection. menu The selector to offer (to retrieve?) the context menu. color The selector to retrieve the background color. ! Item was added: + ----- Method: PluggableTextSpec>>editText (in category 'accessing') ----- + editText + ^ editText! Item was added: + ----- Method: PluggableTextSpec>>editText: (in category 'accessing') ----- + editText: aSymbol + "Answer the selector for getting informed about any modifications of the text." + editText := aSymbol! From commits at source.squeak.org Tue Apr 7 07:13:31 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 07:13:33 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.118.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.118.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.118 Author: mt Time: 7 April 2015, 9:13:24.124 am UUID: 1c78f2a5-f862-1742-aa5d-c860ebcf0cf7 Ancestors: ToolBuilder-Morphic-mt.117 Pluggable text spec now passes edit-selector to pluggable text morph. =============== Diff against ToolBuilder-Morphic-mt.117 =============== Item was changed: ----- Method: MorphicToolBuilder>>buildPluggableText: (in category 'pluggable widgets') ----- buildPluggableText: aSpec | widget | widget := self textPaneClass on: aSpec model text: aSpec getText accept: aSpec setText readSelection: aSpec selection menu: aSpec menu. + widget editTextSelector: aSpec editText. widget askBeforeDiscardingEdits: aSpec askBeforeDiscardingEdits. widget font: Preferences standardCodeFont. self register: widget id: aSpec name. widget getColorSelector: aSpec color. self buildHelpFor: widget spec: aSpec. self setFrame: aSpec frame in: widget. parent ifNotNil:[self add: widget to: parent]. widget borderColor: Color lightGray. widget color: Color white. ^widget! From commits at source.squeak.org Tue Apr 7 07:16:17 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 07:16:20 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.828.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.828.mcz ==================== Summary ==================== Name: Morphic-mt.828 Author: mt Time: 7 April 2015, 9:15:30.956 am UUID: 2e54911e-bc9b-9a45-9ff7-cc94cbc373f7 Ancestors: Morphic-mt.827 Pluggable text morph can now notify about any text modification to the model -- not only accepts. =============== Diff against Morphic-mt.827 =============== Item was changed: ScrollPane subclass: #PluggableTextMorph + instanceVariableNames: 'textMorph getTextSelector setTextSelector getSelectionSelector hasUnacceptedEdits askBeforeDiscardingEdits selectionInterval hasEditingConflicts editTextSelector' - instanceVariableNames: 'textMorph getTextSelector setTextSelector getSelectionSelector hasUnacceptedEdits askBeforeDiscardingEdits selectionInterval hasEditingConflicts' classVariableNames: 'AdornmentCache SimpleFrameAdornments' poolDictionaries: '' category: 'Morphic-Pluggable Widgets'! Item was added: + ----- Method: PluggableTextMorph>>editTextSelector (in category 'accessing') ----- + editTextSelector + + ^ editTextSelector! Item was added: + ----- Method: PluggableTextMorph>>editTextSelector: (in category 'accessing') ----- + editTextSelector: aSymbol + + editTextSelector := aSymbol.! Item was added: + ----- Method: PluggableTextMorph>>textEdited: (in category 'editor access') ----- + textEdited: someText + "Tell the model about some edits in the text if interested. This is not #accept, which means that it will be send on every keystroke." + + self editTextSelector ifNotNil: [:selector | + model perform: selector with: someText].! Item was changed: ----- Method: TextMorphForEditView>>keyStroke: (in category 'event handling') ----- keyStroke: evt | view | editView deleteBalloon. (editView scrollByKeyboard: evt) ifTrue: [^self]. self editor model: editView model. "For evaluateSelection" view := editView. "Copy into temp for case of a self-mutating doit" (acceptOnCR and: [evt keyCharacter = Character cr]) ifTrue: [^ self editor accept]. super keyStroke: evt. + view scrollSelectionIntoView. + + "Make a cheap check and guess editing. (Alternative would be to copy the old contents and then compare them against the new ones. Maybe add a better hook in the TextEditor." + (evt keyCharacter isAlphaNumeric or: [evt keyCharacter isSeparator]) + ifTrue: [view textEdited: self contents].! - view scrollSelectionIntoView! From commits at source.squeak.org Tue Apr 7 07:17:28 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 07:17:30 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.829.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.829.mcz ==================== Summary ==================== Name: Morphic-mt.829 Author: mt Time: 7 April 2015, 9:16:41.005 am UUID: b0d0bfd8-0f93-8646-a532-dbceaa818990 Ancestors: Morphic-mt.828 Fixed the search bar to select all of its current contents on activation again (instead of deleting them).. =============== Diff against Morphic-mt.828 =============== Item was changed: ----- Method: SearchBar>>activate:in: (in category 'accessing') ----- activate: event in: morph + self selection: (1 to: self searchTerm size). - self searchTerm: ''. "We cannot select all here, because we only get contents on #accept, which triggers a search. So earse the term." event hand newKeyboardFocus: morph textMorph.! Item was changed: ----- Method: SearchBar>>buildWith: (in category 'toolbuilder') ----- buildWith: builder ^ (builder build: (builder pluggableInputFieldSpec new model: self; getText: #searchTerm; setText: #smartSearch:in:; + editText: #searchTermSilently:; menu: #menu:shifted:; selection: #selection; help: 'Search...' translated)) name: #searchBar; wantsFrameAdornments: false; borderWidth: 0; yourself! Item was added: + ----- Method: SearchBar>>searchTermSilently: (in category 'accessing') ----- + searchTermSilently: aString. + "Do not signal it to the model." + + searchTerm := aString.! From marcel.taeumel at student.hpi.uni-potsdam.de Tue Apr 7 07:06:11 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Tue Apr 7 07:18:33 2015 Subject: [squeak-dev] Re: search bar problems In-Reply-To: References: <1428388639553-4817932.post@n4.nabble.com> Message-ID: <1428390371332-4817940.post@n4.nabble.com> You mean that a search "bar" could become a full-fledged "workspace"? What about spawning a workspace with those contents from the search bar. :) Best, Marcel -- View this message in context: http://forum.world.st/search-bar-problems-tp4817914p4817940.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Tue Apr 7 07:07:12 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Tue Apr 7 07:19:34 2015 Subject: [squeak-dev] Re: search bar problems In-Reply-To: <1428390371332-4817940.post@n4.nabble.com> References: <1428388639553-4817932.post@n4.nabble.com> <1428390371332-4817940.post@n4.nabble.com> Message-ID: <1428390432919-4817941.post@n4.nabble.com> This content-destruction-bug should be fixed: http://forum.world.st/The-Trunk-Morphic-mt-829-mcz-td4817939.html Best, Marcel -- View this message in context: http://forum.world.st/search-bar-problems-tp4817914p4817941.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From leves at elte.hu Tue Apr 7 07:20:12 2015 From: leves at elte.hu (Levente Uzonyi) Date: Tue Apr 7 07:20:16 2015 Subject: [squeak-dev] search bar problems In-Reply-To: <213BDBD4-F744-49DE-9897-E01944F79C67@rowledge.org> References: <213BDBD4-F744-49DE-9897-E01944F79C67@rowledge.org> Message-ID: On Mon, 6 Apr 2015, tim Rowledge wrote: > > On 06-04-2015, at 4:38 PM, Chris Muller wrote: >> >> I really just want a plain ol'e TextMorph up there. I never found the >> search functionality useful because it never opens the kind of browser >> I want.. >> > > A related complaint - when you enter a message that completely matches you don?t get a MessageNames window you get only the implementors of that message. So you end up having to enter ?siz? in order to get all messages containing size, for example. I?m sure somebody thought it was a good idea but all in all I?m going to have to demur. You can always type "*size*" to get a MessageNames browser. I wouldn't mind always getting that browser, if the exact match were selected automatically when it exists. Levente > > tim > -- > tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim > Manual Writer's Creed: Garbage in, gospel out. > > > > From leves at elte.hu Tue Apr 7 07:23:06 2015 From: leves at elte.hu (Levente Uzonyi) Date: Tue Apr 7 07:23:08 2015 Subject: [squeak-dev] Re: search bar problems In-Reply-To: <1428390371332-4817940.post@n4.nabble.com> References: <1428388639553-4817932.post@n4.nabble.com> <1428390371332-4817940.post@n4.nabble.com> Message-ID: One of the goals of the search bar is to avoid opening workspaces. And no, it's not a workspace, because it doesn't (and shouldn't) have any variables. The name "SearchBar" is a bit misleading. It's intended to be a place where you can evaluate expressions, and see the results, or you can type something and search for it. Levente On Tue, 7 Apr 2015, Marcel Taeumel wrote: > You mean that a search "bar" could become a full-fledged "workspace"? > > What about spawning a workspace with those contents from the search bar. :) > > Best, > Marcel > > > > -- > View this message in context: http://forum.world.st/search-bar-problems-tp4817914p4817940.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > From commits at source.squeak.org Tue Apr 7 07:35:44 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 07:35:46 2015 Subject: [squeak-dev] The Trunk: Monticello-tfel.609.mcz Message-ID: Tim Felgentreff uploaded a new version of Monticello to project The Trunk: http://source.squeak.org/trunk/Monticello-tfel.609.mcz ==================== Summary ==================== Name: Monticello-tfel.609 Author: tfel Time: 7 April 2015, 9:35:13.09 am UUID: fe332c1c-12f4-9e48-8b93-b4edb44a9519 Ancestors: Monticello-tfel.608, Monticello-cmm.608 add an option to open changes between two different versions in the repository in a patch browser (what the Changes button does, but instead of against the image, do it against another package from the repo) =============== Diff against Monticello-cmm.608 =============== Item was changed: ----- Method: MCRepositoryInspector>>versionListMenu: (in category 'morphic ui') ----- versionListMenu: aMenu 1 to: self orderSpecs size do: [ :index | aMenu addUpdating: #orderString: target: self selector: #order: argumentList: { index } ]. + aMenu addLine. + aMenu add: 'Changes against ...' action: [| ri | + ri := aMenu defaultTarget. + (UIManager default + chooseFrom: ri allVersionNames + values: ri allVersionNames + title: 'Select version to show patch against ...') ifNotNilDo: [:name | + | versionName target base | + versionName := MCVersionName on: name. + target := ri repository versionNamed: ri versionInfo name. + base := aMenu defaultTarget repository versionNamed: versionName. + (MCPatchBrowser + forPatch: (target snapshot patchRelativeToBase: base snapshot)) + showLabelled: 'Changes from ', versionName, ' to ', ri versionInfo name]]. ^aMenu! From commits at source.squeak.org Tue Apr 7 07:46:24 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 07:46:26 2015 Subject: [squeak-dev] The Trunk: Morphic-tfel.830.mcz Message-ID: Tim Felgentreff uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-tfel.830.mcz ==================== Summary ==================== Name: Morphic-tfel.830 Author: tfel Time: 7 April 2015, 9:45:48.692 am UUID: 4aae75f5-9ea4-8c4c-875d-8cb60e19fa5c Ancestors: Morphic-mt.829 add messages to spy on a selection =============== Diff against Morphic-mt.829 =============== Item was added: + ----- Method: PluggableTextMorph>>spyOnIt (in category 'menu commands') ----- + spyOnIt + self handleEdit: [textMorph editor spyOnIt]! Item was added: + ----- Method: SmalltalkEditor>>spyOnIt (in category 'do-its') ----- + spyOnIt + + ^ MessageTally spyOn: [self evaluateSelection]! From commits at source.squeak.org Tue Apr 7 07:50:02 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 07:50:03 2015 Subject: [squeak-dev] The Trunk: Tools-tfel.578.mcz Message-ID: Tim Felgentreff uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-tfel.578.mcz ==================== Summary ==================== Name: Tools-tfel.578 Author: tfel Time: 7 April 2015, 9:49:41.232 am UUID: 53d2b12e-5f33-6543-bc50-9ecfb3ec6cd9 Ancestors: Tools-mt.577 add yellow-button menu entry to spy on selection. needs Morphic-tfel.830 =============== Diff against Tools-mt.577 =============== Item was changed: ----- Method: StringHolder class>>yellowButtonMenuItems (in category '*Tools-yellow button menu') ----- yellowButtonMenuItems "Returns the standard yellow button menu items" ^{ {'set font... (k)' translated. #offerFontMenu}. {'set style... (K)' translated. #changeStyle}. {'set alignment... (u)' translated. #chooseAlignment}. #-. {'make project link (P)' translated. #makeProjectLink}. #-. {'find...(f)' translated. #find}. {'find again (g)' translated. #findAgain}. {'set search string (h)' translated. #setSearchString}. #-. {'do again (j)' translated. #again}. {'undo (z)' translated. #undo}. #-. {'copy (c)' translated. #copySelection}. {'cut (x)' translated. #cut}. {'paste (v)' translated. #paste}. {'paste...' translated. #pasteRecent}. #-. {'do it (d)' translated. #doIt}. {'print it (p)' translated. #printIt}. {'inspect it (i)' translated. #inspectIt}. {'explore it (I)' translated. #exploreIt}. {'debug it' translated. #debugIt}. {'button for it' translated. #buttonForIt}. {'tally it' translated. #tallyIt}. + {'spy on it' translated. #spyOnIt}. #-. {'accept (s)' translated. #accept}. {'cancel (l)' translated. #cancel}. #-. {'show bytecodes' translated. #showBytecodes}. #-. {'copy html' translated. #copyHtml}. #-. {'more...' translated. #shiftedTextPaneMenuRequest}. }! From Das.Linux at gmx.de Tue Apr 7 09:15:26 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Tue Apr 7 09:15:31 2015 Subject: [squeak-dev] The Inbox: ShoutCore-cmm.45.mcz Message-ID: On 06.04.2015, at 22:52, commits@source.squeak.org wrote: > A new version of ShoutCore was added to project The Inbox: > http://source.squeak.org/inbox/ShoutCore-cmm.45.mcz > > ==================== Summary ==================== > > Name: ShoutCore-cmm.45 > Author: cmm > Time: 6 April 2015, 5:52:19.582 pm > UUID: 7f2c4864-c8d9-4f51-8553-23db02266ad0 > Ancestors: ShoutCore-cmm.44 > > - Added subdued version of Shout colors proposed in cmm.44. > - #defaultStyleTable is misnamed because it was was not the default. Renamed it to #brightStyleTable. > - Simplify help text for #subduedSyntaxHighlights. > Did you integrate you changes into the subdued style now? Please leave the subdued style. Maybe we should allow for several styles? Personally, I don't like the color choice yo are proposing, too much green, too hard to figure out at a glance the proportions of the following concepts: "direct access" (instvars, classes, formerly black) vs "messages" (formerly blueish), "self/supers" (formerly reddish) The proportions of the three rather distinct colors gave me a subconscious hint, whether the method was idiomatic or not? Also, please be very careful with underlining. The once only bolded message name is now bold AND green AND underlined. Thats a tad too much attention. Moreover, UML uses underlining for 'static methods' aka class methods. this could be confusing. Don't get me wrong, I _like_ a variety of syntax highlighting styles, we should support that better. I, however, don't think it is a good idea to override a relatively accustomed style just because "it's time for a change". :) Best -Tobias > =============== Diff against ShoutCore-cmm.44 =============== > > Item was added: From Das.Linux at gmx.de Tue Apr 7 09:25:36 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Tue Apr 7 09:25:39 2015 Subject: [squeak-dev] The Trunk: EToys-topa.121.mcz In-Reply-To: References: Message-ID: Hey On 03.04.2015, at 17:25, Levente Uzonyi wrote: > On Fri, 3 Apr 2015, Tobias Pape wrote: > >> >> On 03.04.2015, at 01:00, Chris Muller wrote: >> >>> On Thu, Apr 2, 2015 at 5:52 PM, Tobias Pape wrote: >>>> Hi, >>>> >>>> On 03.04.2015, at 00:32, Levente Uzonyi wrote: >>>> >>>>> I prefer to use Symbols instead of Strings for class names, because they make it easier to find potential users of the class. >>> >>> +1 >>> >>>> yes, but #hasClassNamed: is a String protocol. >>> >>> A Symbol is a String. Many (if not all) existing users of >>> hasClassNamed: pass Symbols (a special kind of String). >> >> I don't want to rely on that. >> Symbols being Strings is an implementation detail. >> Looking at the broader picture, in GemStone, in fact >> a Symbol is not a String. > > This code is not intended to be portable to other dialects, so IMHO it's fine to use Symbols as Strings. If we ever decide to make Symbols to not be Strings anymore, then we'll have to scan the image (and external packages) anyway. We have several things here: 1. Symbols vs. Strings 2. How to reference a class indirectly 3. Consistent idiomatic code My code was because of a mixture of all three. I started with 2, thought about 3 and ended up with #hasClassNamed:, and due to 1 I used the code as is. Yes, I'll change it. But let me explain. I try write code that should be read. So, #hasClassNamed:/#classNamed: is undoubtedly more intention-revealing than the pseudo-Dictionary API. Now I saw that #hasClassNamed is a String API (it really is) and remembered that, while I can treat strings and symbols as same in Squeak, it is unportable[1] and I don't want to write unportable code unless I have to or it is reallly convenient. Yes, it is actually fine to write the convenient code in this place. (I'll change it :) But probably we have to think about the String/Symbol thing once again. If we perpetuate this implicit assumption throughout the core, I think we only encourage people to write unportable code, which I think would be really sad. [1]: ANSIs only requirement to both String and Symbol is that they conform to the protocol, ie, they both answer correctly to #asString and #asSymbol. Really, I looked it up. From commits at source.squeak.org Tue Apr 7 09:31:19 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 09:31:21 2015 Subject: [squeak-dev] The Trunk: EToys-topa.122.mcz Message-ID: Tobias Pape uploaded a new version of EToys to project The Trunk: http://source.squeak.org/trunk/EToys-topa.122.mcz ==================== Summary ==================== Name: EToys-topa.122 Author: topa Time: 7 April 2015, 11:31:00.268 am UUID: c7d71d46-2ce6-481f-874b-57cd91914d23 Ancestors: EToys-topa.121 Style =============== Diff against EToys-topa.121 =============== Item was changed: ----- Method: TileMorphTest>>expectedFailures (in category 'testing') ----- expectedFailures ^ super expectedFailures, + (self class environment + at: #BaseSoundSystem + ifPresent: [#()] + ifAbsent: [#(testSoundTile) "Only this test depends on Sound"])! - ((Smalltalk hasClassNamed: 'BaseSoundSystem') - ifTrue: [#()] - ifFalse: [#(testSoundTile) "Only this test depends on Sound"])! Item was changed: ----- Method: TileMorphTest>>setUp (in category 'running') ----- setUp self soundSystemBackup: SoundService defaultOrNil. + SoundService default: (self class environment at: #BaseSoundSystem ifAbsent: [nil]).! - SoundService default: (Smalltalk classNamed: 'BaseSoundSystem').! From commits at source.squeak.org Tue Apr 7 09:41:59 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 09:42:01 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.119.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.119.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.119 Author: mt Time: 7 April 2015, 11:41:52.882 am UUID: 9288dea7-6cfc-2d4e-b9fa-b9d0ad9d65f8 Ancestors: ToolBuilder-Morphic-mt.118 Made pluggable input fields into real one-liners that scroll horizontally w/o having a scroll bar. =============== Diff against ToolBuilder-Morphic-mt.118 =============== Item was changed: ----- Method: MorphicToolBuilder>>buildPluggableInputField: (in category 'pluggable widgets') ----- buildPluggableInputField: aSpec | widget | widget := self buildPluggableText: aSpec. widget acceptOnCR: true. widget hideScrollBarsIndefinitely. + widget textMorph + autoFit: false; + wrapFlag: true; + width: 999999. ^widget! From commits at source.squeak.org Tue Apr 7 09:44:22 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 09:44:23 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.831.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.831.mcz ==================== Summary ==================== Name: Morphic-mt.831 Author: mt Time: 7 April 2015, 11:43:46.915 am UUID: 4bf38111-efd1-d34d-80e3-a438dcbd0d0d Ancestors: Morphic-tfel.830 Fix scroll pane hack so that it does not reset h-offset when hiding the h-scrollbar. Not even the v-scrollbar does this... =============== Diff against Morphic-tfel.830 =============== Item was changed: ----- Method: ScrollPane>>hHideScrollBar (in category 'scrolling') ----- hHideScrollBar + + self hIsScrollbarShowing ifFalse: [^self]. - self hIsScrollbarShowing ifFalse: [^scroller offset: (self hMargin negated@scroller offset y)]. self removeMorph: hScrollBar. - scroller offset: (self hMargin negated@scroller offset y). retractableScrollBar ifFalse: [self resetExtent]. ! From commits at source.squeak.org Tue Apr 7 09:47:21 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 09:47:23 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.832.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.832.mcz ==================== Summary ==================== Name: Morphic-mt.832 Author: mt Time: 7 April 2015, 11:46:43.031 am UUID: becc62cc-9fc5-5347-b467-aacee456748d Ancestors: Morphic-mt.831 Fixed pluggable text morphs to not scroll more than just its text morphs. =============== Diff against Morphic-mt.831 =============== Item was added: + ----- Method: PluggableTextMorph>>hExtraScrollRange (in category 'scrolling') ----- + hExtraScrollRange + + ^ 0! Item was removed: - ----- Method: PluggableTextMorph>>hUnadjustedScrollRange (in category 'scrolling') ----- - hUnadjustedScrollRange - "Return the width of the widest item in the list" - - textMorph ifNil: [ ^0 ]. - textMorph isWrapped ifTrue:[ ^0 ]. - - ^super hUnadjustedScrollRange - ! Item was added: + ----- Method: PluggableTextMorph>>vExtraScrollRange (in category 'scrolling') ----- + vExtraScrollRange + + ^ 0! From commits at source.squeak.org Tue Apr 7 09:50:31 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 09:50:34 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.833.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.833.mcz ==================== Summary ==================== Name: Morphic-mt.833 Author: mt Time: 7 April 2015, 11:49:47.002 am UUID: 3226d2d9-f66c-d64a-a086-8184a81b09bc Ancestors: Morphic-mt.832 Let the pluggable text morph *only* resize its text morph if autoFit is enabled. This supports real input fields. =============== Diff against Morphic-mt.832 =============== Item was changed: ----- Method: PluggableTextMorph>>resizeScroller (in category 'geometry') ----- resizeScroller "Also needs to resize the text morph" super resizeScroller. + + textMorph ifNotNil: [:tm | + tm isAutoFit ifTrue: [textMorph extent: self scroller extent]].! - textMorph ifNotNil: - [textMorph extent: (self innerBounds width-6)@self height]. - ! From commits at source.squeak.org Tue Apr 7 09:52:32 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 09:52:33 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.834.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.834.mcz ==================== Summary ==================== Name: Morphic-mt.834 Author: mt Time: 7 April 2015, 11:51:20.173 am UUID: 3017c4e8-a569-ad45-b02b-20da1bc3b5a1 Ancestors: Morphic-mt.833 Fix scrolling bug in text boxes when the selection was bigger than the text box --- honors the actual text cursor/caret now. =============== Diff against Morphic-mt.833 =============== Item was changed: ----- Method: PluggableTextMorph>>scrollSelectionIntoView: (in category 'editor access') ----- scrollSelectionIntoView: event "Scroll my text into view if necessary and return true, else return false" + | selRects rectToTest transform cpHere | - | selRects delta selRect rectToTest transform cpHere | selectionInterval := textMorph editor selectionInterval. selRects := textMorph paragraph selectionRects. selRects isEmpty ifTrue: [^ false]. + rectToTest := selRects reduce: [:r1 :r2 | r1 quickMerge: r2]. - rectToTest := selRects first merge: selRects last. transform := scroller transformFrom: self. (event notNil and: [event anyButtonPressed]) ifTrue: "Check for autoscroll" [cpHere := transform localPointToGlobal: event cursorPoint. cpHere y <= self top ifTrue: [rectToTest := selRects first topLeft extent: 2@2] ifFalse: [cpHere y >= self bottom ifTrue: [rectToTest := selRects last bottomRight extent: 2@2] ifFalse: [^ false]]]. + self scrollToShow: rectToTest. + self scrollToShow: textMorph editor pointBlock. "Ensure text cursor visibility." + ^ true! - selRect := transform localBoundsToGlobal: rectToTest. - selRect height > bounds height - ifTrue: [^ false]. "Would not fit, even if we tried to scroll" - (delta := selRect amountToTranslateWithin: self innerBounds) y ~= 0 ifTrue: - ["Scroll end of selection into view if necessary" - self scrollBy: 0@delta y. - ^ true]. - ^ false! Item was added: + ----- Method: TextEditor>>pointBlock (in category 'accessing-selection') ----- + pointBlock + ^ pointBlock! From commits at source.squeak.org Tue Apr 7 09:54:37 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 09:54:39 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.835.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.835.mcz ==================== Summary ==================== Name: Morphic-mt.835 Author: mt Time: 7 April 2015, 11:54:01.456 am UUID: 178521f6-057f-fa40-b4e6-8463970180de Ancestors: Morphic-mt.834 Default search bar width increased to 200 pixel. =============== Diff against Morphic-mt.834 =============== Item was changed: ----- Method: TheWorldMainDockingBar>>searchBarOn: (in category 'right side') ----- searchBarOn: aDockingBar aDockingBar + addMorphBack: (SearchBar build vResizing: #spaceFill; width: 200); - addMorphBack: (SearchBar build vResizing: #spaceFill); addDefaultSpace! From marcel.taeumel at student.hpi.uni-potsdam.de Tue Apr 7 09:51:14 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Tue Apr 7 10:03:39 2015 Subject: [squeak-dev] Re: search bar problems In-Reply-To: References: <1428388639553-4817932.post@n4.nabble.com> <1428390371332-4817940.post@n4.nabble.com> Message-ID: <1428400274715-4817982.post@n4.nabble.com> So, I made the search bar more accessible but still not growing but scrolling to honor the surrounding UI. Still, there is the problem of bigger print-its that cannot be viewed at a glance up there... Best, Marcel -- View this message in context: http://forum.world.st/search-bar-problems-tp4817914p4817982.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Tue Apr 7 10:06:26 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 10:06:27 2015 Subject: [squeak-dev] The Trunk: Help-Squeak-Project-topa.22.mcz Message-ID: Tobias Pape uploaded a new version of Help-Squeak-Project to project The Trunk: http://source.squeak.org/trunk/Help-Squeak-Project-topa.22.mcz ==================== Summary ==================== Name: Help-Squeak-Project-topa.22 Author: topa Time: 7 April 2015, 12:06:17.426 pm UUID: bc30874c-0d15-4cb3-b40e-be224b29f619 Ancestors: Help-Squeak-Project-cmm.21 Take responsibility =============== Diff against Help-Squeak-Project-cmm.21 =============== Item was added: + ----- Method: Utilities class>>openCommandKeyHelp (in category '*Help-Squeak-Project-support windows') ----- + openCommandKeyHelp + "Open a window giving command key help." + "Utilities openCommandKeyHelp" + + HelpBrowser openOn: SqueakTutorialsCommandKey! From commits at source.squeak.org Tue Apr 7 10:09:07 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 10:09:08 2015 Subject: [squeak-dev] The Trunk: System-topa.718.mcz Message-ID: Tobias Pape uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System-topa.718.mcz ==================== Summary ==================== Name: System-topa.718 Author: topa Time: 7 April 2015, 12:08:44.019 pm UUID: 623c867d-9da8-4d94-bcd5-31487b8d9571 Ancestors: System-mt.717 Drop dependencies. For Preferences class>>#restorePreferencesFromDisk, we restore the old version, since right away there is no good way to allow old behavior (loading 'my.prefs'), selecting a custom prefs file, AND not depending on tools. =============== Diff against System-mt.717 =============== Item was changed: ----- Method: Preferences class>>restorePreferencesFromDisk (in category 'personalization') ----- restorePreferencesFromDisk + (FileDirectory default fileExists: 'my.prefs') + ifTrue: [ Cursor wait showWhile: [ + [ self loadPreferencesFrom: 'my.prefs' ] on: Error do: [ :ex | self inform: 'there was an error restoring the preferences' ] + ] ] + ifFalse: [ self inform: 'you haven''t saved your preferences yet!!' ]. - | result | - result := (FileList2 modalFileSelectorForSuffixes: #('prefs')) . - result ifNil: [^ self]. - self restorePreferencesFromDisk: result - ! Item was removed: - ----- Method: Utilities class>>openCommandKeyHelp (in category 'support windows') ----- - openCommandKeyHelp - "Open a window giving command key help." - "Utilities openCommandKeyHelp" - - HelpBrowser openOn: SqueakTutorialsCommandKey! Item was changed: ----- Method: WrappedBreakpoint>>run:with:in: (in category 'evaluation') ----- run: aSelector with: anArray in: aReceiver | process | process := Process forContext: (MethodContext sender: thisContext sender receiver: aReceiver method: method arguments: anArray) priority: Processor activeProcess priority. + ToolSet + debug: process context: process suspendedContext - Debugger - openOn: process context: process suspendedContext label: 'Breakpoint in ' , method methodClass name , '>>#' , method selector contents: nil fullView: true. Project spawnNewProcessIfThisIsUI: Processor activeProcess. thisContext swapSender: nil. Processor activeProcess terminate.! From commits at source.squeak.org Tue Apr 7 11:46:08 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 11:46:10 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.120.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.120.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.120 Author: mt Time: 7 April 2015, 1:46:00.827 pm UUID: 22727c96-903c-b94c-969a-688fcbc16105 Ancestors: ToolBuilder-Morphic-mt.119 Remove adornment from one-line inputs. =============== Diff against ToolBuilder-Morphic-mt.119 =============== Item was changed: ----- Method: MorphicToolBuilder>>buildPluggableInputField: (in category 'pluggable widgets') ----- buildPluggableInputField: aSpec | widget | widget := self buildPluggableText: aSpec. widget acceptOnCR: true. widget hideScrollBarsIndefinitely. + widget wantsFrameAdornments: false. widget textMorph autoFit: false; wrapFlag: true; width: 999999. ^widget! From commits at source.squeak.org Tue Apr 7 11:52:26 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 11:52:27 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.836.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.836.mcz ==================== Summary ==================== Name: Morphic-mt.836 Author: mt Time: 7 April 2015, 1:51:48.705 pm UUID: 6d241e35-c6ce-6849-a4cf-c607cdeccd3f Ancestors: Morphic-mt.835 As a temporary workaround, give text boxes some extra v-range. We will fix that later... =============== Diff against Morphic-mt.835 =============== Item was changed: ----- Method: PluggableTextMorph>>vExtraScrollRange (in category 'scrolling') ----- vExtraScrollRange + ^ 10! - ^ 0! From commits at source.squeak.org Tue Apr 7 11:55:11 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 11:55:11 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.837.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.837.mcz ==================== Summary ==================== Name: Morphic-mt.837 Author: mt Time: 7 April 2015, 1:54:28.194 pm UUID: 643d7c4c-9cee-8840-bf11-96d16932b68b Ancestors: Morphic-mt.836 Hooks added to text editors to send evaluation results to the model instead of invoking some default/hard-coded action. =============== Diff against Morphic-mt.836 =============== Item was changed: ----- Method: TextEditor>>evaluateSelectionAndDo: (in category 'do-its') ----- evaluateSelectionAndDo: aBlock "Treat the current selection as an expression; evaluate it and invoke aBlock with the result." | result rcvr ctxt | self lineSelectAndEmptyCheck: [^ nil]. (model respondsTo: #doItReceiver) ifTrue: [ rcvr := model doItReceiver. ctxt := model doItContext] ifFalse: [rcvr := ctxt := nil]. result := [ rcvr class evaluatorClass new evaluate: self selectionAsStream in: ctxt to: rcvr notifying: self ifFail: [morph flash. ^ nil] logged: true. ] on: OutOfScopeNotification do: [ :ex | ex resume: true]. + + (model respondsTo: #evaluated:result:) ifTrue: [ + model perform: #evaluated:result: with: self selection with: result]. + ^aBlock value: result! Item was changed: ----- Method: TextEditor>>printIt (in category 'do-its') ----- printIt + + self evaluateSelectionAndDo: [:result | + (model respondsTo: #printIt:result:) + ifTrue: [model + perform: #printIt:result: + with: self selection + with: result] + ifFalse: [self afterSelectionInsertAndSelect: result printString]]! - self evaluateSelectionAndDo: - [:result | self afterSelectionInsertAndSelect: result printString]! From commits at source.squeak.org Tue Apr 7 11:55:50 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 11:56:45 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.838.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.838.mcz ==================== Summary ==================== Name: Morphic-mt.838 Author: mt Time: 7 April 2015, 1:55:40.414 pm UUID: a40ffb0d-4521-5748-a42a-777eb94323c7 Ancestors: Morphic-mt.837 Search bar now spawns a new (transient) text box (like a balloon morph) to show print-it results, which can be selected and copied and ... =============== Diff against Morphic-mt.837 =============== Item was changed: Model subclass: #SearchBar + instanceVariableNames: 'searchTerm selection resultsWidget' - instanceVariableNames: 'searchTerm selection' classVariableNames: '' poolDictionaries: '' category: 'Morphic-Menus-DockingBar'! Item was added: + ----- Method: SearchBar>>printIt:result: (in category 'do-its') ----- + printIt: code result: object + + | focusedWidget | + focusedWidget := self currentHand keyboardFocus. + + self removeResultsWidget. + + ToolBuilder default in: [:builder | + resultsWidget := (builder build: (StringHolder new + contents: object asString; + buildCodePaneWith: builder)). + resultsWidget textMorph + on: #mouseLeave send: #delete to: resultsWidget. + resultsWidget + extent: 250@150; + fullBounds; + height: (resultsWidget textMorph height min: 300); + position: (focusedWidget + ifNotNil: [:w | w owner boundsInWorld bottomLeft] + ifNil: [self currentHand position]); + color: (BalloonMorph balloonColor alpha: 1.0). + + Preferences menuAppearance3d + ifTrue: [resultsWidget addDropShadow]. + + resultsWidget openInWorld].! Item was added: + ----- Method: SearchBar>>removeResultsWidget (in category 'accessing') ----- + removeResultsWidget + + resultsWidget ifNotNil: [:w | w delete]. + resultsWidget := nil.! Item was changed: ----- Method: SearchBar>>searchTerm: (in category 'accessing') ----- searchTerm: aString searchTerm := aString. self changed: #searchTerm.! Item was changed: ----- Method: SearchBar>>smartSearch:in: (in category 'searching') ----- smartSearch: text in: morph "Take the user input and perform an appropriate search" | input newContents | + self removeResultsWidget. input := text asString ifEmpty:[^self]. (Smalltalk bindingOf: input) ifNotNil:[:assoc| | global | "It's a global or a class" global := assoc value. ^ToolSet browse: (global isBehavior ifTrue:[global] ifFalse:[global class]) selector: nil. ]. (SystemNavigation new allImplementorsOf: input asSymbol) ifNotEmpty:[:list| ^SystemNavigation new browseMessageList: list name: 'Implementors of ' , input ]. input first isUppercase ifTrue:[ (UIManager default classFromPattern: input withCaption: '') ifNotNil:[:aClass| ^ToolSet browse: aClass selector: nil. ]. ] ifFalse:[ ^ToolSet default browseMessageNames: input ]. newContents := input, ' -- not found.'. self searchTerm: newContents. self selection: (input size+1 to: newContents size). self currentHand newKeyboardFocus: morph textMorph.! From marcel.taeumel at student.hpi.uni-potsdam.de Tue Apr 7 11:47:03 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Tue Apr 7 11:59:29 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.838.mcz In-Reply-To: References: Message-ID: <1428407223771-4818009.post@n4.nabble.com> Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-838-mcz-tp4818005p4818009.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Tue Apr 7 11:47:58 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Tue Apr 7 12:00:21 2015 Subject: [squeak-dev] Re: search bar problems In-Reply-To: References: <1428388639553-4817932.post@n4.nabble.com> <1428390371332-4817940.post@n4.nabble.com> Message-ID: <1428407278284-4818010.post@n4.nabble.com> Does this come close to the intended scenario? --> http://forum.world.st/The-Trunk-Morphic-mt-838-mcz-td4818005.html Best, Marcel -- View this message in context: http://forum.world.st/search-bar-problems-tp4817914p4818010.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Tue Apr 7 12:04:32 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 12:04:34 2015 Subject: [squeak-dev] The Trunk: Collections-bf.612.mcz Message-ID: Tobias Pape uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections-bf.612.mcz ==================== Summary ==================== Name: Collections-bf.612 Author: bf Time: 7 April 2015, 2:04:06.99 pm UUID: 1b9e2fc6-03fb-41c2-a3e8-197fa24c108a Ancestors: Collections-ul.611 Ensure that copyWith/out retains the weak-ness of a weak array. =============== Diff against Collections-ul.611 =============== Item was added: + ----- Method: WeakArray>>copyWith: (in category 'copying') ----- + copyWith: newElement + "Re-implemented to not return a strong copy." + ^ (super copyWith: newElement) as: self class! Item was added: + ----- Method: WeakArray>>copyWithout: (in category 'copying') ----- + copyWithout: oldElement + "Re-implemented to not return a strong copy." + ^ (super copyWithout: oldElement) as: self class! Item was changed: + ----- Method: WeakArray>>species (in category 'private') ----- - ----- Method: WeakArray>>species (in category 'as yet unclassified') ----- species "More useful to have strongly-referenced results of #select: and #collect:." ^ Array! From commits at source.squeak.org Tue Apr 7 12:06:41 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 12:06:43 2015 Subject: [squeak-dev] The Trunk: Kernel-bf.917.mcz Message-ID: Tobias Pape uploaded a new version of Kernel to project The Trunk: http://source.squeak.org/trunk/Kernel-bf.917.mcz ==================== Summary ==================== Name: Kernel-bf.917 Author: bf Time: 7 April 2015, 2:06:18.845 pm UUID: 48b96a41-4966-4f92-a52c-2df737fb2cbb Ancestors: Kernel-topa.916 Fix accidental non-weak arrays in ObsoleteSubclasses values =============== Diff against Kernel-topa.916 =============== Item was changed: + (PackageInfo named: 'Kernel') postscript: '"Fix accidental non-weak arrays in ObsoleteSubclasses values" + Behavior classPool at: #ObsoleteSubclasses ifPresent: [:os | + os keysAndValuesDo: [:superclass :obsoletes | + obsoletes class isWeak ifFalse: [ + os at: superclass put: (obsoletes as: WeakArray)]]].'! - (PackageInfo named: 'Kernel') postscript: 'HashedCollection rehashAll.'! From commits at source.squeak.org Tue Apr 7 12:26:34 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 12:26:38 2015 Subject: [squeak-dev] The Trunk: Morphic-topa.839.mcz Message-ID: Tobias Pape uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-topa.839.mcz ==================== Summary ==================== Name: Morphic-topa.839 Author: topa Time: 7 April 2015, 2:25:52.418 pm UUID: 888ee095-d37d-4f2d-a438-c83aeb211772 Ancestors: Morphic-mt.838 IndentingListItemMorph belongs to Morphic =============== Diff against Morphic-mt.838 =============== Item was added: + StringMorph subclass: #IndentingListItemMorph + instanceVariableNames: 'indentLevel isExpanded complexContents firstChild container nextSibling icon backgroundColor' + classVariableNames: '' + poolDictionaries: '' + category: 'Morphic-Explorer'! + + !IndentingListItemMorph commentStamp: '' prior: 0! + An IndentingListItemMorph is a StringMorph that draws itself with an optional toggle at its left, as part of the display of the SimpleHierarchicalListMorph. + + It will also display lines around the toggle if the #showLinesInHierarchyViews Preference is set. + + Instance variables: + + indentLevel the indent level, from 0 at the root and increasing by 1 at each level of the hierarchy. + + isExpanded true if this item is expanded (showing its children) + + complexContents an adapter wrapping my represented item that can answer its children, etc. + + firstChild my first child, or nil if none + + container my container + + nextSibling the next item in the linked list of siblings, or nil if none. + + Contributed by Bob Arning as part of the ObjectExplorer package. + Don't blame him if it's not perfect. We wanted to get it out for people to play with.! Item was added: + ----- Method: IndentingListItemMorph class>>iconColumnIndex (in category 'defaults') ----- + iconColumnIndex + "Hack. For now, say who gets the icon here. We need a generic solution for icons in multi-column trees. PluggableTreeMorph does something in that direction." + ^ 2! Item was added: + ----- Method: IndentingListItemMorph>>acceptDroppingMorph:event: (in category 'drag and drop') ----- + acceptDroppingMorph: toDrop event: evt + complexContents acceptDroppingObject: toDrop complexContents. + toDrop delete. + self highlightForDrop: false.! Item was added: + ----- Method: IndentingListItemMorph>>addChildrenForList:addingTo:withExpandedItems: (in category 'container protocol - private') ----- + addChildrenForList: hostList addingTo: morphList withExpandedItems: expandedItems + + firstChild ifNotNil: [ + firstChild withSiblingsDo: [ :aNode | aNode delete]. + ]. + firstChild := nil. + complexContents hasContents ifFalse: [^self]. + firstChild := hostList + addMorphsTo: morphList + from: complexContents contents + allowSorting: true + withExpandedItems: expandedItems + atLevel: indentLevel + 1. + ! Item was added: + ----- Method: IndentingListItemMorph>>applyFilter: (in category 'filtering') ----- + applyFilter: filter + + self + applyFilter: filter + depthOffset: self indentLevel.! Item was added: + ----- Method: IndentingListItemMorph>>applyFilter:depthOffset: (in category 'filtering') ----- + applyFilter: filter depthOffset: offset + + | selfMatch childMatch | + self isExpanded ifTrue: [self toggleExpandedState]. + + selfMatch := self matches: filter. + childMatch := self matchesAnyChild: filter depthOffset: offset. + + selfMatch | childMatch ifFalse: [^ self hide]. + + selfMatch ifTrue: [ + self backgroundColor: ((Color gray: 0.85) alpha: 0.5)]. + childMatch ifTrue: [ + self toggleExpandedState. + self childrenDo: [:child | child applyFilter: filter depthOffset: offset]].! Item was added: + ----- Method: IndentingListItemMorph>>backgroundColor (in category 'accessing') ----- + backgroundColor + ^ backgroundColor! Item was added: + ----- Method: IndentingListItemMorph>>backgroundColor: (in category 'accessing') ----- + backgroundColor: aColor + backgroundColor := aColor. + self changed.! Item was added: + ----- Method: IndentingListItemMorph>>balloonText (in category 'accessing') ----- + balloonText + + ^complexContents balloonText ifNil: [super balloonText]! Item was added: + ----- Method: IndentingListItemMorph>>boundsForBalloon (in category 'halos and balloon help') ----- + boundsForBalloon + + "some morphs have bounds that are way too big" + container ifNil: [^super boundsForBalloon]. + ^self boundsInWorld intersect: container boundsInWorld! Item was added: + ----- Method: IndentingListItemMorph>>canExpand (in category 'testing') ----- + canExpand + + ^complexContents hasContents! Item was added: + ----- Method: IndentingListItemMorph>>charactersOccluded (in category 'private') ----- + charactersOccluded + "Answer the number of characters occluded in my #visibleList by my right edge." + | listIndex leftEdgeOfRightmostColumn eachString indexOfLastVisible iconWidth totalWidth | + listIndex := 0. + leftEdgeOfRightmostColumn := container columns + ifNil: [ 0 ] + ifNotNil: + [ : cols | (1 to: cols size - 1) + inject: 0 + into: + [ : sum : each | sum + (self widthOfColumn: each) ] ]. + eachString := container columns + ifNil: [ self complexContents asString ] + ifNotNil: + [ : cols | self contentsAtColumn: container columns size ]. + iconWidth := self icon + ifNil: [ 0 ] + ifNotNil: + [ : icon | icon width + 2 ]. + totalWidth := self toggleBounds right. + indexOfLastVisible := ((1 to: eachString size) + detect: + [ : stringIndex | (totalWidth:=totalWidth+(self fontToUse widthOf: (eachString at: stringIndex))) > + (container width - + (container vIsScrollbarShowing + ifTrue: [ container scrollBar width ] + ifFalse: [ 0 ]) - iconWidth - leftEdgeOfRightmostColumn) ] + ifNone: [ eachString size + 1 ]) - 1. + ^ eachString size - indexOfLastVisible! Item was added: + ----- Method: IndentingListItemMorph>>children (in category 'accessing') ----- + children + | children | + children := OrderedCollection new. + self childrenDo: [:each | children add: each]. + ^children! Item was added: + ----- Method: IndentingListItemMorph>>childrenDo: (in category 'enumeration') ----- + childrenDo: aBlock + + firstChild ifNotNil: [ + firstChild withSiblingsDo: aBlock ]! Item was added: + ----- Method: IndentingListItemMorph>>collapse (in category 'container protocol') ----- + collapse + + self isExpanded ifFalse: [^ self]. + + self isExpanded: false. + + firstChild ifNotNil: [:collapsingNode | + | toDelete | + toDelete := OrderedCollection new. + collapsingNode withSiblingsDo: [:aNode | aNode recursiveAddTo: toDelete]. + container noteRemovalOfAll: toDelete]. + + self changed.! Item was added: + ----- Method: IndentingListItemMorph>>complexContents (in category 'accessing') ----- + complexContents + + ^complexContents! Item was added: + ----- Method: IndentingListItemMorph>>contentsAtColumn: (in category 'accessing - columns') ----- + contentsAtColumn: index + "Split string contents at character." + + | column scanner cell | + column := 0. + scanner := ReadStream on: contents asString. + [(cell := scanner upTo: Character tab) notEmpty] + whileTrue: [column := column + 1. column = index ifTrue: [^ cell]]. + ^ ''! Item was added: + ----- Method: IndentingListItemMorph>>contentsSplitByColumns (in category 'accessing - columns') ----- + contentsSplitByColumns + "Split string contents at character." + + | result scanner cell | + result := OrderedCollection new. + scanner := ReadStream on: contents asString. + [(cell := scanner upTo: Character tab) notEmpty] + whileTrue: [result add: cell]. + ^ result! Item was added: + ----- Method: IndentingListItemMorph>>defaultColor (in category 'initialization') ----- + defaultColor + + ^complexContents + ifNil: [ super defaultColor ] + ifNotNil: [ complexContents preferredColor ]! Item was added: + ----- Method: IndentingListItemMorph>>drawLineToggleToTextOn:lineColor:hasToggle: (in category 'drawing') ----- + drawLineToggleToTextOn: aCanvas lineColor: lineColor hasToggle: hasToggle + "If I am not the only item in my container, draw the line between: + - my toggle (if any) or my left edge (if no toggle) + - and my text left edge" + + | myBounds myCenter hLineY hLineLeft | + self isSoleItem ifTrue: [ ^self ]. + myBounds := self toggleBounds. + myCenter := myBounds center. + hLineY := myCenter y. + hLineLeft := myCenter x - 1. + "Draw line from toggle to text" + aCanvas + line: hLineLeft @ hLineY + to: myBounds right + 0 @ hLineY + width: 1 + color: lineColor! Item was added: + ----- Method: IndentingListItemMorph>>drawLinesOn:lineColor: (in category 'drawing') ----- + drawLinesOn: aCanvas lineColor: lineColor + | hasToggle | + hasToggle := self hasToggle. + "Draw line from toggle to text" + self drawLineToggleToTextOn: aCanvas lineColor: lineColor hasToggle: hasToggle. + + "Draw the line from my toggle to the nextSibling's toggle" + self nextVisibleSibling ifNotNil: [ self drawLinesToNextSiblingOn: aCanvas lineColor: lineColor hasToggle: hasToggle ]. + + "If I have children and am expanded, draw a line to my first child" + (self firstVisibleChild notNil and: [ self isExpanded ]) + ifTrue: [ self drawLinesToFirstChildOn: aCanvas lineColor: lineColor]! Item was added: + ----- Method: IndentingListItemMorph>>drawLinesToFirstChildOn:lineColor: (in category 'drawing') ----- + drawLinesToFirstChildOn: aCanvas lineColor: lineColor + "Draw line from me to next sibling" + + | child vLineX vLineTop vLineBottom childBounds childCenter | + child := self firstVisibleChild. + childBounds := child toggleBounds. + childCenter := childBounds center. + vLineX := childCenter x - 1. + vLineTop := bounds bottom. + child hasToggle + ifTrue: [vLineBottom := childCenter y - 7] + ifFalse: [vLineBottom := childCenter y]. + aCanvas + line: vLineX @ vLineTop + to: vLineX @ vLineBottom + width: 1 + color: lineColor! Item was added: + ----- Method: IndentingListItemMorph>>drawLinesToNextSiblingOn:lineColor:hasToggle: (in category 'drawing') ----- + drawLinesToNextSiblingOn: aCanvas lineColor: lineColor hasToggle: hasToggle + | myBounds nextSibBounds vLineX myCenter vLineTop vLineBottom | + myBounds := self toggleBounds. + nextSibBounds := self nextVisibleSibling toggleBounds. + myCenter := myBounds center. + vLineX := myCenter x - 1. + vLineTop := myCenter y. + vLineBottom := nextSibBounds center y. + "Draw line from me to next sibling" + aCanvas + line: vLineX @ vLineTop + to: vLineX @ vLineBottom + width: 1 + color: lineColor! Item was added: + ----- Method: IndentingListItemMorph>>drawOn: (in category 'drawing') ----- + drawOn: aCanvas + + | tRect sRect columnScanner columnLeft | + self backgroundColor ifNotNil: [:c | + aCanvas fillRectangle: self innerBounds color: c]. + + tRect := self toggleRectangle. + self drawToggleOn: aCanvas in: tRect. + + sRect := bounds withLeft: tRect right + 4. + sRect := sRect top: sRect top + sRect bottom - self fontToUse height // 2. + + (container columns isNil or: [(contents asString indexOf: Character tab) = 0]) ifTrue: [ + icon ifNotNil: [ + aCanvas + translucentImage: icon + at: sRect left @ (self top + (self height - icon height // 2)). + sRect := sRect left: sRect left + icon width + 2. + ]. + + aCanvas drawString: contents asString in: sRect font: self fontToUse color: color. + + ] ifFalse: [ + columnLeft := sRect left. + columnScanner := ReadStream on: contents asString. + container columns withIndexDo: [ :widthSpec :column | | columnRect columnData columnWidth | + "Draw icon." + column = self class iconColumnIndex ifTrue: [ + icon ifNotNil: [ + aCanvas + translucentImage: icon + at: columnLeft @ (self top + (self height - icon height // 2)). + columnLeft := columnLeft + icon width + 2]]. + + columnWidth := self widthOfColumn: column. + columnRect := columnLeft @ sRect top extent: columnWidth @ sRect height. + columnData := columnScanner upTo: Character tab. + + "Draw string." + columnData ifNotEmpty: [ + aCanvas drawString: columnData in: columnRect font: self fontToUse color: color]. + + "Compute next column offset." + columnLeft := columnRect right + 5. + column = 1 ifTrue: [columnLeft := columnLeft - tRect right + self left]. + + ]. + ]! Item was added: + ----- Method: IndentingListItemMorph>>drawToggleOn:in: (in category 'drawing') ----- + drawToggleOn: aCanvas in: aRectangle + + | aForm centeringOffset | + complexContents hasContents ifFalse: [^self]. + aForm := isExpanded + ifTrue: [container expandedForm] + ifFalse: [container notExpandedForm]. + centeringOffset := ((aRectangle height - aForm extent y) / 2.0) rounded. + ^aCanvas + paintImage: aForm + at: (aRectangle topLeft translateBy: 0 @ centeringOffset). + ! Item was added: + ----- Method: IndentingListItemMorph>>expand (in category 'container protocol') ----- + expand + + | newChildren c | + + (self isExpanded or: [self canExpand not]) + ifTrue: [^ self]. + + (c := self getChildren) ifEmpty: [ + "Due to the guessing in #canExpand, it may still fail here." + ^ self]. + + self isExpanded: true. + + newChildren := container + addSubmorphsAfter: self + fromCollection: c + allowSorting: true. + + firstChild := newChildren first.! Item was added: + ----- Method: IndentingListItemMorph>>firstChild (in category 'accessing') ----- + firstChild + + ^firstChild! Item was added: + ----- Method: IndentingListItemMorph>>firstVisibleChild (in category 'accessing') ----- + firstVisibleChild + + ^ self firstChild ifNotNil: [:c | + c visible ifTrue: [c] ifFalse: [c nextVisibleSibling]]! Item was added: + ----- Method: IndentingListItemMorph>>getChildren (in category 'model access') ----- + getChildren + + ^ self getChildrenFor: complexContents! Item was added: + ----- Method: IndentingListItemMorph>>getChildrenFor: (in category 'model access') ----- + getChildrenFor: model + + ^ model contents! Item was added: + ----- Method: IndentingListItemMorph>>getIcon (in category 'model access') ----- + getIcon + + ^ complexContents icon! Item was added: + ----- Method: IndentingListItemMorph>>getLabel (in category 'model access') ----- + getLabel + + ^ self getLabelFor: complexContents! Item was added: + ----- Method: IndentingListItemMorph>>getLabelFor: (in category 'model access') ----- + getLabelFor: model + + ^ model asString! Item was added: + ----- Method: IndentingListItemMorph>>hMargin (in category 'accessing') ----- + hMargin + + ^ 3! Item was added: + ----- Method: IndentingListItemMorph>>hasIcon (in category 'testing') ----- + hasIcon + "Answer whether the receiver has an icon." + ^ icon notNil! Item was added: + ----- Method: IndentingListItemMorph>>hasToggle (in category 'private') ----- + hasToggle + ^ complexContents hasContents! Item was added: + ----- Method: IndentingListItemMorph>>highlight (in category 'container protocol - private') ----- + highlight + + (self valueOfProperty: #wasRefreshed ifAbsent: [false]) + ifFalse: [self color: complexContents highlightingColor] + ifTrue: [self color: self color negated]. + + self changed. + + ! Item was added: + ----- Method: IndentingListItemMorph>>icon (in category 'accessing') ----- + icon + "answer the receiver's icon" + ^ icon! Item was added: + ----- Method: IndentingListItemMorph>>inToggleArea: (in category 'mouse events') ----- + inToggleArea: aPoint + + ^self toggleRectangle containsPoint: aPoint! Item was added: + ----- Method: IndentingListItemMorph>>indentLevel (in category 'accessing') ----- + indentLevel + + ^indentLevel! Item was added: + ----- Method: IndentingListItemMorph>>initWithContents:prior:forList:indentLevel: (in category 'initialization') ----- + initWithContents: anObject prior: priorMorph forList: hostList indentLevel: newLevel + + container := hostList. + + complexContents := anObject. + anObject addDependent: self. + + self initWithContents: self getLabel font: Preferences standardListFont emphasis: nil. + indentLevel := 0. + isExpanded := false. + nextSibling := firstChild := nil. + priorMorph ifNotNil: [ + priorMorph nextSibling: self. + ]. + indentLevel := newLevel. + icon := self getIcon. + self extent: self minWidth @ self minHeight! Item was added: + ----- Method: IndentingListItemMorph>>initialize (in category 'initialization') ----- + initialize + "initialize the state of the receiver" + super initialize. + "" + indentLevel := 0. + isExpanded := false! Item was added: + ----- Method: IndentingListItemMorph>>isExpanded (in category 'accessing') ----- + isExpanded + + ^isExpanded! Item was added: + ----- Method: IndentingListItemMorph>>isExpanded: (in category 'accessing') ----- + isExpanded: aBoolean + + isExpanded := aBoolean! Item was added: + ----- Method: IndentingListItemMorph>>isFirstItem (in category 'testing') ----- + isFirstItem + ^owner submorphs first == self! Item was added: + ----- Method: IndentingListItemMorph>>isSoleItem (in category 'testing') ----- + isSoleItem + ^self isFirstItem and: [ owner submorphs size = 1 ]! Item was added: + ----- Method: IndentingListItemMorph>>matches: (in category 'filtering') ----- + matches: pattern + + ^ self matches: pattern in: complexContents! Item was added: + ----- Method: IndentingListItemMorph>>matches:in: (in category 'filtering') ----- + matches: pattern in: model + ^ ((PluggableTreeMorph filterByLabelsOnly + ifTrue: [ model itemName ] + ifFalse: [ self getLabelFor: model ]) + findString: pattern + startingAt: 1 + caseSensitive: false) > 0! Item was added: + ----- Method: IndentingListItemMorph>>matchesAnyChild:depthOffset: (in category 'filtering') ----- + matchesAnyChild: pattern depthOffset: offset + + | maxDepth next current | + maxDepth := PluggableTreeMorph maximumSearchDepth - self indentLevel + offset. + maxDepth <= 0 ifTrue: [^ false]. + + next := (self getChildren collect: [:obj | 1 -> obj]) asOrderedCollection. + [next notEmpty] whileTrue: [ + current := next removeFirst. + + (self matches: pattern in: current value) + ifTrue: [^ true]. + + current key < maxDepth ifTrue: [ + next addAll: ((self getChildrenFor: current value) collect: [:obj | (current key + 1) -> obj])]. + ]. + + ^ false! Item was added: + ----- Method: IndentingListItemMorph>>minHeight (in category 'layout') ----- + minHeight + | iconHeight | + iconHeight := self hasIcon + ifTrue: [self icon height + 2] + ifFalse: [0]. + ^ self fontToUse height max: iconHeight ! Item was added: + ----- Method: IndentingListItemMorph>>minWidth (in category 'layout') ----- + minWidth + | iconWidth | + iconWidth := self hasIcon + ifTrue: [self icon width + 2] + ifFalse: [0]. + ^ (self fontToUse widthOfString: contents) + + iconWidth ! Item was added: + ----- Method: IndentingListItemMorph>>nextSibling (in category 'accessing') ----- + nextSibling + + ^nextSibling! Item was added: + ----- Method: IndentingListItemMorph>>nextSibling: (in category 'accessing') ----- + nextSibling: anotherMorph + + nextSibling := anotherMorph! Item was added: + ----- Method: IndentingListItemMorph>>nextVisibleSibling (in category 'accessing') ----- + nextVisibleSibling + + | m | + m := self nextSibling. + [m isNil or: [m visible]] whileFalse: [ + m := m nextSibling]. + ^ m! Item was added: + ----- Method: IndentingListItemMorph>>openPath: (in category 'container protocol - private') ----- + openPath: anArray + | found | + anArray isEmpty + ifTrue: [^ container setSelectedMorph: nil]. + found := nil. + self + withSiblingsDo: [:each | found + ifNil: [(each complexContents asString = anArray first + or: [anArray first isNil]) + ifTrue: [found := each]]]. + found + ifNil: ["try again with no case sensitivity" + self + withSiblingsDo: [:each | found + ifNil: [(each complexContents asString sameAs: anArray first) + ifTrue: [found := each]]]]. + found + ifNotNil: [found isExpanded + ifFalse: [found toggleExpandedState. + container adjustSubmorphPositions]. + found changed. + anArray size = 1 + ifTrue: [^ container setSelectedMorph: found]. + ^ found firstChild + ifNil: [container setSelectedMorph: nil] + ifNotNil: [found firstChild openPath: anArray allButFirst]]. + ^ container setSelectedMorph: nil! Item was added: + ----- Method: IndentingListItemMorph>>preferredColumnCount (in category 'accessing - columns') ----- + preferredColumnCount + + ^ self contentsSplitByColumns size! Item was added: + ----- Method: IndentingListItemMorph>>preferredWidthOfColumn: (in category 'accessing - columns') ----- + preferredWidthOfColumn: index + + ^ (self fontToUse widthOfString: (self contentsAtColumn: index)) + + (index = 1 ifTrue: [self toggleRectangle right - self left] ifFalse: [0])! Item was added: + ----- Method: IndentingListItemMorph>>recursiveAddTo: (in category 'container protocol - private') ----- + recursiveAddTo: aCollection + + firstChild ifNotNil: [ + firstChild withSiblingsDo: [ :aNode | aNode recursiveAddTo: aCollection]. + ]. + aCollection add: self + ! Item was added: + ----- Method: IndentingListItemMorph>>recursiveDelete (in category 'container protocol - private') ----- + recursiveDelete + + firstChild ifNotNil: [ + firstChild withSiblingsDo: [ :aNode | aNode recursiveDelete]. + ]. + self delete + ! Item was added: + ----- Method: IndentingListItemMorph>>refresh (in category 'initialization') ----- + refresh + + self contents: self getLabel. + icon := self getIcon. + + (self valueOfProperty: #wasRefreshed ifAbsent: [false]) ifFalse: [ + self setProperty: #wasRefreshed toValue: true. + self color: Color yellow. "Indicate refresh operation."].! Item was added: + ----- Method: IndentingListItemMorph>>toggleBounds (in category 'private') ----- + toggleBounds + ^self toggleRectangle! Item was added: + ----- Method: IndentingListItemMorph>>toggleExpandedState (in category 'container protocol') ----- + toggleExpandedState + + self isExpanded + ifTrue: [self collapse] + ifFalse: [self expand].! Item was added: + ----- Method: IndentingListItemMorph>>toggleRectangle (in category 'private') ----- + toggleRectangle + + | h | + h := bounds height. + ^(bounds left + self hMargin + (12 * indentLevel)) @ bounds top extent: 12@h! Item was added: + ----- Method: IndentingListItemMorph>>unhighlight (in category 'drawing') ----- + unhighlight + + (self valueOfProperty: #wasRefreshed ifAbsent: [false]) + ifFalse: [self color: complexContents preferredColor] + ifTrue: [self color: self color negated]. + + self changed. + + + ! Item was added: + ----- Method: IndentingListItemMorph>>update: (in category 'updating') ----- + update: aspect + "See ListItemWrapper and subclasses for possible change aspects." + + aspect = #contents ifTrue: [ + self isExpanded ifTrue: [ + self toggleExpandedState]. + self canExpand ifTrue: [self toggleExpandedState]]. + + super update: aspect.! Item was added: + ----- Method: IndentingListItemMorph>>userString (in category 'accessing') ----- + userString + "Add leading tabs to my userString" + ^ (String new: indentLevel withAll: Character tab), super userString + ! Item was added: + ----- Method: IndentingListItemMorph>>widthOfColumn: (in category 'accessing - columns') ----- + widthOfColumn: columnIndex + | widthOrSpec | + container columns ifNil: [ ^ self width ]. + widthOrSpec := container columns at: columnIndex. + ^ widthOrSpec isNumber + ifTrue: [ widthOrSpec ] + ifFalse: + [ widthOrSpec isBlock + ifTrue: + [ widthOrSpec + cull: container + cull: self ] + ifFalse: + [ widthOrSpec + ifNil: [ self width ] + ifNotNil: [ "Fall back" + 50 ] ] ]! Item was added: + ----- Method: IndentingListItemMorph>>withSiblingsDo: (in category 'private') ----- + withSiblingsDo: aBlock + + | node | + node := self. + [node isNil] whileFalse: [ + aBlock value: node. + node := node nextSibling + ].! Item was added: + ----- Method: IndentingListItemMorph>>withoutListWrapper (in category 'converting') ----- + withoutListWrapper + + ^complexContents withoutListWrapper! From commits at source.squeak.org Tue Apr 7 12:28:01 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 12:28:02 2015 Subject: [squeak-dev] The Trunk: Tools-topa.579.mcz Message-ID: Tobias Pape uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-topa.579.mcz ==================== Summary ==================== Name: Tools-topa.579 Author: topa Time: 7 April 2015, 2:27:40.196 pm UUID: c9f6d7a8-8a37-43ea-aff6-d0f8f19ed815 Ancestors: Tools-tfel.578 IndentingListItemMorph belongs to Morphic =============== Diff against Tools-tfel.578 =============== Item was removed: - StringMorph subclass: #IndentingListItemMorph - instanceVariableNames: 'indentLevel isExpanded complexContents firstChild container nextSibling icon backgroundColor' - classVariableNames: '' - poolDictionaries: '' - category: 'Tools-Explorer'! - - !IndentingListItemMorph commentStamp: '' prior: 0! - An IndentingListItemMorph is a StringMorph that draws itself with an optional toggle at its left, as part of the display of the SimpleHierarchicalListMorph. - - It will also display lines around the toggle if the #showLinesInHierarchyViews Preference is set. - - Instance variables: - - indentLevel the indent level, from 0 at the root and increasing by 1 at each level of the hierarchy. - - isExpanded true if this item is expanded (showing its children) - - complexContents an adapter wrapping my represented item that can answer its children, etc. - - firstChild my first child, or nil if none - - container my container - - nextSibling the next item in the linked list of siblings, or nil if none. - - Contributed by Bob Arning as part of the ObjectExplorer package. - Don't blame him if it's not perfect. We wanted to get it out for people to play with.! Item was removed: - ----- Method: IndentingListItemMorph class>>iconColumnIndex (in category 'defaults') ----- - iconColumnIndex - "Hack. For now, say who gets the icon here. We need a generic solution for icons in multi-column trees. PluggableTreeMorph does something in that direction." - ^ 2! Item was removed: - ----- Method: IndentingListItemMorph>>acceptDroppingMorph:event: (in category 'drag and drop') ----- - acceptDroppingMorph: toDrop event: evt - complexContents acceptDroppingObject: toDrop complexContents. - toDrop delete. - self highlightForDrop: false.! Item was removed: - ----- Method: IndentingListItemMorph>>addChildrenForList:addingTo:withExpandedItems: (in category 'container protocol - private') ----- - addChildrenForList: hostList addingTo: morphList withExpandedItems: expandedItems - - firstChild ifNotNil: [ - firstChild withSiblingsDo: [ :aNode | aNode delete]. - ]. - firstChild := nil. - complexContents hasContents ifFalse: [^self]. - firstChild := hostList - addMorphsTo: morphList - from: complexContents contents - allowSorting: true - withExpandedItems: expandedItems - atLevel: indentLevel + 1. - ! Item was removed: - ----- Method: IndentingListItemMorph>>applyFilter: (in category 'filtering') ----- - applyFilter: filter - - self - applyFilter: filter - depthOffset: self indentLevel.! Item was removed: - ----- Method: IndentingListItemMorph>>applyFilter:depthOffset: (in category 'filtering') ----- - applyFilter: filter depthOffset: offset - - | selfMatch childMatch | - self isExpanded ifTrue: [self toggleExpandedState]. - - selfMatch := self matches: filter. - childMatch := self matchesAnyChild: filter depthOffset: offset. - - selfMatch | childMatch ifFalse: [^ self hide]. - - selfMatch ifTrue: [ - self backgroundColor: ((Color gray: 0.85) alpha: 0.5)]. - childMatch ifTrue: [ - self toggleExpandedState. - self childrenDo: [:child | child applyFilter: filter depthOffset: offset]].! Item was removed: - ----- Method: IndentingListItemMorph>>backgroundColor (in category 'accessing') ----- - backgroundColor - ^ backgroundColor! Item was removed: - ----- Method: IndentingListItemMorph>>backgroundColor: (in category 'accessing') ----- - backgroundColor: aColor - backgroundColor := aColor. - self changed.! Item was removed: - ----- Method: IndentingListItemMorph>>balloonText (in category 'accessing') ----- - balloonText - - ^complexContents balloonText ifNil: [super balloonText]! Item was removed: - ----- Method: IndentingListItemMorph>>boundsForBalloon (in category 'halos and balloon help') ----- - boundsForBalloon - - "some morphs have bounds that are way too big" - container ifNil: [^super boundsForBalloon]. - ^self boundsInWorld intersect: container boundsInWorld! Item was removed: - ----- Method: IndentingListItemMorph>>canExpand (in category 'testing') ----- - canExpand - - ^complexContents hasContents! Item was removed: - ----- Method: IndentingListItemMorph>>charactersOccluded (in category 'private') ----- - charactersOccluded - "Answer the number of characters occluded in my #visibleList by my right edge." - | listIndex leftEdgeOfRightmostColumn eachString indexOfLastVisible iconWidth totalWidth | - listIndex := 0. - leftEdgeOfRightmostColumn := container columns - ifNil: [ 0 ] - ifNotNil: - [ : cols | (1 to: cols size - 1) - inject: 0 - into: - [ : sum : each | sum + (self widthOfColumn: each) ] ]. - eachString := container columns - ifNil: [ self complexContents asString ] - ifNotNil: - [ : cols | self contentsAtColumn: container columns size ]. - iconWidth := self icon - ifNil: [ 0 ] - ifNotNil: - [ : icon | icon width + 2 ]. - totalWidth := self toggleBounds right. - indexOfLastVisible := ((1 to: eachString size) - detect: - [ : stringIndex | (totalWidth:=totalWidth+(self fontToUse widthOf: (eachString at: stringIndex))) > - (container width - - (container vIsScrollbarShowing - ifTrue: [ container scrollBar width ] - ifFalse: [ 0 ]) - iconWidth - leftEdgeOfRightmostColumn) ] - ifNone: [ eachString size + 1 ]) - 1. - ^ eachString size - indexOfLastVisible! Item was removed: - ----- Method: IndentingListItemMorph>>children (in category 'accessing') ----- - children - | children | - children := OrderedCollection new. - self childrenDo: [:each | children add: each]. - ^children! Item was removed: - ----- Method: IndentingListItemMorph>>childrenDo: (in category 'enumeration') ----- - childrenDo: aBlock - - firstChild ifNotNil: [ - firstChild withSiblingsDo: aBlock ]! Item was removed: - ----- Method: IndentingListItemMorph>>collapse (in category 'container protocol') ----- - collapse - - self isExpanded ifFalse: [^ self]. - - self isExpanded: false. - - firstChild ifNotNil: [:collapsingNode | - | toDelete | - toDelete := OrderedCollection new. - collapsingNode withSiblingsDo: [:aNode | aNode recursiveAddTo: toDelete]. - container noteRemovalOfAll: toDelete]. - - self changed.! Item was removed: - ----- Method: IndentingListItemMorph>>complexContents (in category 'accessing') ----- - complexContents - - ^complexContents! Item was removed: - ----- Method: IndentingListItemMorph>>contentsAtColumn: (in category 'accessing - columns') ----- - contentsAtColumn: index - "Split string contents at character." - - | column scanner cell | - column := 0. - scanner := ReadStream on: contents asString. - [(cell := scanner upTo: Character tab) notEmpty] - whileTrue: [column := column + 1. column = index ifTrue: [^ cell]]. - ^ ''! Item was removed: - ----- Method: IndentingListItemMorph>>contentsSplitByColumns (in category 'accessing - columns') ----- - contentsSplitByColumns - "Split string contents at character." - - | result scanner cell | - result := OrderedCollection new. - scanner := ReadStream on: contents asString. - [(cell := scanner upTo: Character tab) notEmpty] - whileTrue: [result add: cell]. - ^ result! Item was removed: - ----- Method: IndentingListItemMorph>>defaultColor (in category 'initialization') ----- - defaultColor - - ^complexContents - ifNil: [ super defaultColor ] - ifNotNil: [ complexContents preferredColor ]! Item was removed: - ----- Method: IndentingListItemMorph>>drawLineToggleToTextOn:lineColor:hasToggle: (in category 'drawing') ----- - drawLineToggleToTextOn: aCanvas lineColor: lineColor hasToggle: hasToggle - "If I am not the only item in my container, draw the line between: - - my toggle (if any) or my left edge (if no toggle) - - and my text left edge" - - | myBounds myCenter hLineY hLineLeft | - self isSoleItem ifTrue: [ ^self ]. - myBounds := self toggleBounds. - myCenter := myBounds center. - hLineY := myCenter y. - hLineLeft := myCenter x - 1. - "Draw line from toggle to text" - aCanvas - line: hLineLeft @ hLineY - to: myBounds right + 0 @ hLineY - width: 1 - color: lineColor! Item was removed: - ----- Method: IndentingListItemMorph>>drawLinesOn:lineColor: (in category 'drawing') ----- - drawLinesOn: aCanvas lineColor: lineColor - | hasToggle | - hasToggle := self hasToggle. - "Draw line from toggle to text" - self drawLineToggleToTextOn: aCanvas lineColor: lineColor hasToggle: hasToggle. - - "Draw the line from my toggle to the nextSibling's toggle" - self nextVisibleSibling ifNotNil: [ self drawLinesToNextSiblingOn: aCanvas lineColor: lineColor hasToggle: hasToggle ]. - - "If I have children and am expanded, draw a line to my first child" - (self firstVisibleChild notNil and: [ self isExpanded ]) - ifTrue: [ self drawLinesToFirstChildOn: aCanvas lineColor: lineColor]! Item was removed: - ----- Method: IndentingListItemMorph>>drawLinesToFirstChildOn:lineColor: (in category 'drawing') ----- - drawLinesToFirstChildOn: aCanvas lineColor: lineColor - "Draw line from me to next sibling" - - | child vLineX vLineTop vLineBottom childBounds childCenter | - child := self firstVisibleChild. - childBounds := child toggleBounds. - childCenter := childBounds center. - vLineX := childCenter x - 1. - vLineTop := bounds bottom. - child hasToggle - ifTrue: [vLineBottom := childCenter y - 7] - ifFalse: [vLineBottom := childCenter y]. - aCanvas - line: vLineX @ vLineTop - to: vLineX @ vLineBottom - width: 1 - color: lineColor! Item was removed: - ----- Method: IndentingListItemMorph>>drawLinesToNextSiblingOn:lineColor:hasToggle: (in category 'drawing') ----- - drawLinesToNextSiblingOn: aCanvas lineColor: lineColor hasToggle: hasToggle - | myBounds nextSibBounds vLineX myCenter vLineTop vLineBottom | - myBounds := self toggleBounds. - nextSibBounds := self nextVisibleSibling toggleBounds. - myCenter := myBounds center. - vLineX := myCenter x - 1. - vLineTop := myCenter y. - vLineBottom := nextSibBounds center y. - "Draw line from me to next sibling" - aCanvas - line: vLineX @ vLineTop - to: vLineX @ vLineBottom - width: 1 - color: lineColor! Item was removed: - ----- Method: IndentingListItemMorph>>drawOn: (in category 'drawing') ----- - drawOn: aCanvas - - | tRect sRect columnScanner columnLeft | - self backgroundColor ifNotNil: [:c | - aCanvas fillRectangle: self innerBounds color: c]. - - tRect := self toggleRectangle. - self drawToggleOn: aCanvas in: tRect. - - sRect := bounds withLeft: tRect right + 4. - sRect := sRect top: sRect top + sRect bottom - self fontToUse height // 2. - - (container columns isNil or: [(contents asString indexOf: Character tab) = 0]) ifTrue: [ - icon ifNotNil: [ - aCanvas - translucentImage: icon - at: sRect left @ (self top + (self height - icon height // 2)). - sRect := sRect left: sRect left + icon width + 2. - ]. - - aCanvas drawString: contents asString in: sRect font: self fontToUse color: color. - - ] ifFalse: [ - columnLeft := sRect left. - columnScanner := ReadStream on: contents asString. - container columns withIndexDo: [ :widthSpec :column | | columnRect columnData columnWidth | - "Draw icon." - column = self class iconColumnIndex ifTrue: [ - icon ifNotNil: [ - aCanvas - translucentImage: icon - at: columnLeft @ (self top + (self height - icon height // 2)). - columnLeft := columnLeft + icon width + 2]]. - - columnWidth := self widthOfColumn: column. - columnRect := columnLeft @ sRect top extent: columnWidth @ sRect height. - columnData := columnScanner upTo: Character tab. - - "Draw string." - columnData ifNotEmpty: [ - aCanvas drawString: columnData in: columnRect font: self fontToUse color: color]. - - "Compute next column offset." - columnLeft := columnRect right + 5. - column = 1 ifTrue: [columnLeft := columnLeft - tRect right + self left]. - - ]. - ]! Item was removed: - ----- Method: IndentingListItemMorph>>drawToggleOn:in: (in category 'drawing') ----- - drawToggleOn: aCanvas in: aRectangle - - | aForm centeringOffset | - complexContents hasContents ifFalse: [^self]. - aForm := isExpanded - ifTrue: [container expandedForm] - ifFalse: [container notExpandedForm]. - centeringOffset := ((aRectangle height - aForm extent y) / 2.0) rounded. - ^aCanvas - paintImage: aForm - at: (aRectangle topLeft translateBy: 0 @ centeringOffset). - ! Item was removed: - ----- Method: IndentingListItemMorph>>expand (in category 'container protocol') ----- - expand - - | newChildren c | - - (self isExpanded or: [self canExpand not]) - ifTrue: [^ self]. - - (c := self getChildren) ifEmpty: [ - "Due to the guessing in #canExpand, it may still fail here." - ^ self]. - - self isExpanded: true. - - newChildren := container - addSubmorphsAfter: self - fromCollection: c - allowSorting: true. - - firstChild := newChildren first.! Item was removed: - ----- Method: IndentingListItemMorph>>firstChild (in category 'accessing') ----- - firstChild - - ^firstChild! Item was removed: - ----- Method: IndentingListItemMorph>>firstVisibleChild (in category 'accessing') ----- - firstVisibleChild - - ^ self firstChild ifNotNil: [:c | - c visible ifTrue: [c] ifFalse: [c nextVisibleSibling]]! Item was removed: - ----- Method: IndentingListItemMorph>>getChildren (in category 'model access') ----- - getChildren - - ^ self getChildrenFor: complexContents! Item was removed: - ----- Method: IndentingListItemMorph>>getChildrenFor: (in category 'model access') ----- - getChildrenFor: model - - ^ model contents! Item was removed: - ----- Method: IndentingListItemMorph>>getIcon (in category 'model access') ----- - getIcon - - ^ complexContents icon! Item was removed: - ----- Method: IndentingListItemMorph>>getLabel (in category 'model access') ----- - getLabel - - ^ self getLabelFor: complexContents! Item was removed: - ----- Method: IndentingListItemMorph>>getLabelFor: (in category 'model access') ----- - getLabelFor: model - - ^ model asString! Item was removed: - ----- Method: IndentingListItemMorph>>hMargin (in category 'accessing') ----- - hMargin - - ^ 3! Item was removed: - ----- Method: IndentingListItemMorph>>hasIcon (in category 'testing') ----- - hasIcon - "Answer whether the receiver has an icon." - ^ icon notNil! Item was removed: - ----- Method: IndentingListItemMorph>>hasToggle (in category 'private') ----- - hasToggle - ^ complexContents hasContents! Item was removed: - ----- Method: IndentingListItemMorph>>highlight (in category 'container protocol - private') ----- - highlight - - (self valueOfProperty: #wasRefreshed ifAbsent: [false]) - ifFalse: [self color: complexContents highlightingColor] - ifTrue: [self color: self color negated]. - - self changed. - - ! Item was removed: - ----- Method: IndentingListItemMorph>>icon (in category 'accessing') ----- - icon - "answer the receiver's icon" - ^ icon! Item was removed: - ----- Method: IndentingListItemMorph>>inToggleArea: (in category 'mouse events') ----- - inToggleArea: aPoint - - ^self toggleRectangle containsPoint: aPoint! Item was removed: - ----- Method: IndentingListItemMorph>>indentLevel (in category 'accessing') ----- - indentLevel - - ^indentLevel! Item was removed: - ----- Method: IndentingListItemMorph>>initWithContents:prior:forList:indentLevel: (in category 'initialization') ----- - initWithContents: anObject prior: priorMorph forList: hostList indentLevel: newLevel - - container := hostList. - - complexContents := anObject. - anObject addDependent: self. - - self initWithContents: self getLabel font: Preferences standardListFont emphasis: nil. - indentLevel := 0. - isExpanded := false. - nextSibling := firstChild := nil. - priorMorph ifNotNil: [ - priorMorph nextSibling: self. - ]. - indentLevel := newLevel. - icon := self getIcon. - self extent: self minWidth @ self minHeight! Item was removed: - ----- Method: IndentingListItemMorph>>initialize (in category 'initialization') ----- - initialize - "initialize the state of the receiver" - super initialize. - "" - indentLevel := 0. - isExpanded := false! Item was removed: - ----- Method: IndentingListItemMorph>>isExpanded (in category 'accessing') ----- - isExpanded - - ^isExpanded! Item was removed: - ----- Method: IndentingListItemMorph>>isExpanded: (in category 'accessing') ----- - isExpanded: aBoolean - - isExpanded := aBoolean! Item was removed: - ----- Method: IndentingListItemMorph>>isFirstItem (in category 'testing') ----- - isFirstItem - ^owner submorphs first == self! Item was removed: - ----- Method: IndentingListItemMorph>>isSoleItem (in category 'testing') ----- - isSoleItem - ^self isFirstItem and: [ owner submorphs size = 1 ]! Item was removed: - ----- Method: IndentingListItemMorph>>matches: (in category 'filtering') ----- - matches: pattern - - ^ self matches: pattern in: complexContents! Item was removed: - ----- Method: IndentingListItemMorph>>matches:in: (in category 'filtering') ----- - matches: pattern in: model - ^ ((PluggableTreeMorph filterByLabelsOnly - ifTrue: [ model itemName ] - ifFalse: [ self getLabelFor: model ]) - findString: pattern - startingAt: 1 - caseSensitive: false) > 0! Item was removed: - ----- Method: IndentingListItemMorph>>matchesAnyChild:depthOffset: (in category 'filtering') ----- - matchesAnyChild: pattern depthOffset: offset - - | maxDepth next current | - maxDepth := PluggableTreeMorph maximumSearchDepth - self indentLevel + offset. - maxDepth <= 0 ifTrue: [^ false]. - - next := (self getChildren collect: [:obj | 1 -> obj]) asOrderedCollection. - [next notEmpty] whileTrue: [ - current := next removeFirst. - - (self matches: pattern in: current value) - ifTrue: [^ true]. - - current key < maxDepth ifTrue: [ - next addAll: ((self getChildrenFor: current value) collect: [:obj | (current key + 1) -> obj])]. - ]. - - ^ false! Item was removed: - ----- Method: IndentingListItemMorph>>minHeight (in category 'layout') ----- - minHeight - | iconHeight | - iconHeight := self hasIcon - ifTrue: [self icon height + 2] - ifFalse: [0]. - ^ self fontToUse height max: iconHeight ! Item was removed: - ----- Method: IndentingListItemMorph>>minWidth (in category 'layout') ----- - minWidth - | iconWidth | - iconWidth := self hasIcon - ifTrue: [self icon width + 2] - ifFalse: [0]. - ^ (self fontToUse widthOfString: contents) - + iconWidth ! Item was removed: - ----- Method: IndentingListItemMorph>>nextSibling (in category 'accessing') ----- - nextSibling - - ^nextSibling! Item was removed: - ----- Method: IndentingListItemMorph>>nextSibling: (in category 'accessing') ----- - nextSibling: anotherMorph - - nextSibling := anotherMorph! Item was removed: - ----- Method: IndentingListItemMorph>>nextVisibleSibling (in category 'accessing') ----- - nextVisibleSibling - - | m | - m := self nextSibling. - [m isNil or: [m visible]] whileFalse: [ - m := m nextSibling]. - ^ m! Item was removed: - ----- Method: IndentingListItemMorph>>openPath: (in category 'container protocol - private') ----- - openPath: anArray - | found | - anArray isEmpty - ifTrue: [^ container setSelectedMorph: nil]. - found := nil. - self - withSiblingsDo: [:each | found - ifNil: [(each complexContents asString = anArray first - or: [anArray first isNil]) - ifTrue: [found := each]]]. - found - ifNil: ["try again with no case sensitivity" - self - withSiblingsDo: [:each | found - ifNil: [(each complexContents asString sameAs: anArray first) - ifTrue: [found := each]]]]. - found - ifNotNil: [found isExpanded - ifFalse: [found toggleExpandedState. - container adjustSubmorphPositions]. - found changed. - anArray size = 1 - ifTrue: [^ container setSelectedMorph: found]. - ^ found firstChild - ifNil: [container setSelectedMorph: nil] - ifNotNil: [found firstChild openPath: anArray allButFirst]]. - ^ container setSelectedMorph: nil! Item was removed: - ----- Method: IndentingListItemMorph>>preferredColumnCount (in category 'accessing - columns') ----- - preferredColumnCount - - ^ self contentsSplitByColumns size! Item was removed: - ----- Method: IndentingListItemMorph>>preferredWidthOfColumn: (in category 'accessing - columns') ----- - preferredWidthOfColumn: index - - ^ (self fontToUse widthOfString: (self contentsAtColumn: index)) + - (index = 1 ifTrue: [self toggleRectangle right - self left] ifFalse: [0])! Item was removed: - ----- Method: IndentingListItemMorph>>recursiveAddTo: (in category 'container protocol - private') ----- - recursiveAddTo: aCollection - - firstChild ifNotNil: [ - firstChild withSiblingsDo: [ :aNode | aNode recursiveAddTo: aCollection]. - ]. - aCollection add: self - ! Item was removed: - ----- Method: IndentingListItemMorph>>recursiveDelete (in category 'container protocol - private') ----- - recursiveDelete - - firstChild ifNotNil: [ - firstChild withSiblingsDo: [ :aNode | aNode recursiveDelete]. - ]. - self delete - ! Item was removed: - ----- Method: IndentingListItemMorph>>refresh (in category 'initialization') ----- - refresh - - self contents: self getLabel. - icon := self getIcon. - - (self valueOfProperty: #wasRefreshed ifAbsent: [false]) ifFalse: [ - self setProperty: #wasRefreshed toValue: true. - self color: Color yellow. "Indicate refresh operation."].! Item was removed: - ----- Method: IndentingListItemMorph>>toggleBounds (in category 'private') ----- - toggleBounds - ^self toggleRectangle! Item was removed: - ----- Method: IndentingListItemMorph>>toggleExpandedState (in category 'container protocol') ----- - toggleExpandedState - - self isExpanded - ifTrue: [self collapse] - ifFalse: [self expand].! Item was removed: - ----- Method: IndentingListItemMorph>>toggleRectangle (in category 'private') ----- - toggleRectangle - - | h | - h := bounds height. - ^(bounds left + self hMargin + (12 * indentLevel)) @ bounds top extent: 12@h! Item was removed: - ----- Method: IndentingListItemMorph>>unhighlight (in category 'drawing') ----- - unhighlight - - (self valueOfProperty: #wasRefreshed ifAbsent: [false]) - ifFalse: [self color: complexContents preferredColor] - ifTrue: [self color: self color negated]. - - self changed. - - - ! Item was removed: - ----- Method: IndentingListItemMorph>>update: (in category 'updating') ----- - update: aspect - "See ListItemWrapper and subclasses for possible change aspects." - - aspect = #contents ifTrue: [ - self isExpanded ifTrue: [ - self toggleExpandedState]. - self canExpand ifTrue: [self toggleExpandedState]]. - - super update: aspect.! Item was removed: - ----- Method: IndentingListItemMorph>>userString (in category 'accessing') ----- - userString - "Add leading tabs to my userString" - ^ (String new: indentLevel withAll: Character tab), super userString - ! Item was removed: - ----- Method: IndentingListItemMorph>>widthOfColumn: (in category 'accessing - columns') ----- - widthOfColumn: columnIndex - | widthOrSpec | - container columns ifNil: [ ^ self width ]. - widthOrSpec := container columns at: columnIndex. - ^ widthOrSpec isNumber - ifTrue: [ widthOrSpec ] - ifFalse: - [ widthOrSpec isBlock - ifTrue: - [ widthOrSpec - cull: container - cull: self ] - ifFalse: - [ widthOrSpec - ifNil: [ self width ] - ifNotNil: [ "Fall back" - 50 ] ] ]! Item was removed: - ----- Method: IndentingListItemMorph>>withSiblingsDo: (in category 'private') ----- - withSiblingsDo: aBlock - - | node | - node := self. - [node isNil] whileFalse: [ - aBlock value: node. - node := node nextSibling - ].! Item was removed: - ----- Method: IndentingListItemMorph>>withoutListWrapper (in category 'converting') ----- - withoutListWrapper - - ^complexContents withoutListWrapper! From commits at source.squeak.org Tue Apr 7 12:29:08 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 12:29:09 2015 Subject: [squeak-dev] The Trunk: Tests-topa.315.mcz Message-ID: Tobias Pape uploaded a new version of Tests to project The Trunk: http://source.squeak.org/trunk/Tests-topa.315.mcz ==================== Summary ==================== Name: Tests-topa.315 Author: topa Time: 7 April 2015, 2:28:55.49 pm UUID: 52e4ae00-184c-4738-a800-9761a3d681ae Ancestors: Tests-eem.314 Multilingual no longer depends on TrueType, yay =============== Diff against Tests-eem.314 =============== Item was changed: ----- Method: PackageDependencyTest>>testMultilingual (in category 'tests') ----- testMultilingual self testPackage: 'Multilingual' dependsExactlyOn: #( Collections Files Graphics Kernel Network System 'ToolBuilder-Kernel' - TrueType ).! From Das.Linux at gmx.de Tue Apr 7 12:30:49 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Tue Apr 7 12:30:53 2015 Subject: [squeak-dev] Can we get Squeak green for the release? In-Reply-To: References: Message-ID: <54C3EEC4-FA57-4D37-954C-D5B6F98A2393@gmx.de> Hi On 04.04.2015, at 16:59, Frank Shearar wrote: > On 3 April 2015 at 16:27, Tobias Pape wrote: >> Hey >> >> I am watching the CI doing its work as changes and fixes >> chime in. >> I noticed that there are still 13 test failing[1] and I'm >> not sure how all of them should be fixed :) >> Let's make it green! > > I am _very very happy_ to see someone other than me harping on about > tests! Please carry on! > > This one ought to be easy to fix: it's a small breakage in the > modularity of the image; some methods need to be recategorised as not > being System: http://build.squeak.org/job/SqueakTrunk/1207/testReport/Tests.Dependencies/PackageDependencyTest/testSystem/ > > This one too: http://build.squeak.org/job/SqueakTrunk/1207/testReport/Tests.Dependencies/PackageDependencyTest/testTools/ > (Tools shouldn't depend on _ToolBuilder-Morphic_, even though it would > be OK to depend on ToolBuilder.) > > And I love that this one fails - > http://build.squeak.org/job/SqueakTrunk/1207/testReport/Tests.Dependencies/PackageDependencyTest/testMultilingual/ > - Multilingual no longer depends on TrueType, and our system just got > one dependency cleaner. I did some things :) But I need help: There's a strange thing in the decompiler/compiler: http://build.squeak.org/job/SqueakTrunk/lastCompletedBuild/testReport/Tests.Compiler/DecompilerTests/testDecompilerInClassesBAtoBM/ Somewhere in Behavior>>#toolIconSelector:, a sequence of 'push nil. pop' is generated that is decompiled as 'nil.'. This does not match the source and I don't know whether it's a bug in the Compiler emitting this or the Decompiler not recognizing the emitted pattern. Best -Tobias From commits at source.squeak.org Tue Apr 7 12:37:53 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 12:37:55 2015 Subject: [squeak-dev] The Trunk: EToys-topa.123.mcz Message-ID: Tobias Pape uploaded a new version of EToys to project The Trunk: http://source.squeak.org/trunk/EToys-topa.123.mcz ==================== Summary ==================== Name: EToys-topa.123 Author: topa Time: 7 April 2015, 2:37:32.593 pm UUID: 71b565ae-57ad-4d33-91d2-d6bfeec75490 Ancestors: EToys-topa.122 the ifPresent: part needs a block argument =============== Diff against EToys-topa.122 =============== Item was changed: ----- Method: TileMorphTest>>expectedFailures (in category 'testing') ----- expectedFailures ^ super expectedFailures, (self class environment at: #BaseSoundSystem + ifPresent: [:e| #()] - ifPresent: [#()] ifAbsent: [#(testSoundTile) "Only this test depends on Sound"])! From commits at source.squeak.org Tue Apr 7 12:47:33 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 12:47:34 2015 Subject: [squeak-dev] The Trunk: CollectionsTests-topa.237.mcz Message-ID: Tobias Pape uploaded a new version of CollectionsTests to project The Trunk: http://source.squeak.org/trunk/CollectionsTests-topa.237.mcz ==================== Summary ==================== Name: CollectionsTests-topa.237 Author: topa Time: 7 April 2015, 2:47:22.322 pm UUID: 94d6ec6a-25dd-4b46-bf3d-a46427de7aef Ancestors: CollectionsTests-ul.236 HackFix: choose a font that actually can be found via a text font reference.. *sigh* =============== Diff against CollectionsTests-ul.236 =============== Item was changed: ----- Method: TextAttributesScanningTest>>testTextFontReferenceTTC (in category 'testing') ----- testTextFontReferenceTTC "n.b. A TextFontReference specifies font height only, which is not sufficient to identify a unique TTCFont. Here we test only that the font height of the selected font matches the TextFontReference specification." "(self selector: #testTextFontReferenceTTC) debug" "Test TextFontReference with a TTCFont" | font att att3 stream fontReferenceString | + font := TTCFont someInstance textStyle fonts first. - font := TTCFont someInstance. att := TextFontReference toFont: font. stream := self streamWithAttribute: att. fontReferenceString := self testScanAttribute: att fromStream: stream encodedWithCharacter: $F decodedWithBlock: [:strm | strm upToEnd]. self assert: font familyName, '#', font height equals: fontReferenceString. stream reset. att3 := TextAttribute newFrom: stream. "test font height only, see comment above" self assert: att font height equals: att3 font height. "we really want an exact match, which probably requires different implentation of TextFontReference" self assert: att equals: att3. ! From commits at source.squeak.org Tue Apr 7 13:07:48 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 13:07:51 2015 Subject: [squeak-dev] The Trunk: Tests-topa.316.mcz Message-ID: Tobias Pape uploaded a new version of Tests to project The Trunk: http://source.squeak.org/trunk/Tests-topa.316.mcz ==================== Summary ==================== Name: Tests-topa.316 Author: topa Time: 7 April 2015, 3:07:34.151 pm UUID: 8ed25f75-e171-4dd1-8039-72d65297ce6d Ancestors: Tests-topa.315 If we have nothing to switch to this test must fail =============== Diff against Tests-topa.315 =============== Item was added: + ----- Method: LocaleTest>>expectedFailures (in category 'testing') ----- + expectedFailures + + ^ super expectedFailures, + (NaturalLanguageTranslator translators + ifEmpty: [#(testLocaleChanged) "no locale available to switch to"] + ifNotEmpty: [#()]) + ! From commits at source.squeak.org Tue Apr 7 13:09:05 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 13:09:06 2015 Subject: [squeak-dev] The Trunk: Multilingual-topa.203.mcz Message-ID: Tobias Pape uploaded a new version of Multilingual to project The Trunk: http://source.squeak.org/trunk/Multilingual-topa.203.mcz ==================== Summary ==================== Name: Multilingual-topa.203 Author: topa Time: 7 April 2015, 3:08:53.179 pm UUID: 5ba4e9e8-5227-4e90-bab5-373808a32e1c Ancestors: Multilingual-topa.202 Restore an old expected behavior without introducing a dependency =============== Diff against Multilingual-topa.202 =============== Item was changed: ----- Method: LanguageEnvironment class>>startUp (in category 'class initialization') ----- startUp self clearDefault. + self environment at: #HandMorph ifPresent: [:hm| hm startUp]. + self environment at: #Clipboard ifPresent: [:cp| cp startUp]. ! From commits at source.squeak.org Tue Apr 7 14:07:46 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 14:07:49 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.840.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.840.mcz ==================== Summary ==================== Name: Morphic-mt.840 Author: mt Time: 7 April 2015, 4:07:11.316 pm UUID: 10096b48-db09-584e-a4d4-bb2000e87db2 Ancestors: Morphic-topa.839 Changed postscript to force world main docking bar update. Some other preferences might reset. =============== Diff against Morphic-topa.839 =============== Item was changed: (PackageInfo named: 'Morphic') postscript: '(Preferences dictionaryOfPreferences at: #alternativeWindowBoxesLook) defaultValue: false. "Force SystemProgressMorph to be reset" SystemProgressMorph initialize; reset. "Initialize the key bindings and menus" Editor initialize. "Retain scrollBar look now that the pref actually does something" Preferences enable: #gradientScrollBars. "apply the new icons" MenuIcons initializeIcons. TheWorldMainDockingBar updateInstances. + "Cleanup old-style preferences here. Remove before new release." Preferences removePreference: #gradientMenu. "Now in MenuMorph." Preferences removePreference: #roundedMenuCorners. "Now in MenuMorph." "Fix clipping bug of open windows. New ones are not affected." TransformMorph allInstances do: [:ea | ea clipSubmorphs: true].'! From leves at elte.hu Tue Apr 7 14:36:05 2015 From: leves at elte.hu (Levente Uzonyi) Date: Tue Apr 7 14:36:14 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.840.mcz In-Reply-To: References: Message-ID: I guess there's a bit of misunderstanding about the scripts. They should contain only the code that you want to run after loading versions defined by the current Monticello Configuration (.mcm file). So if you just want to update the docking bar, then remove everything else (e.g. you don't want to initialize and reset SystemProgressMorph). So it should be: TheWorldMainDockingBar updateInstances. Levente On Tue, 7 Apr 2015, commits@source.squeak.org wrote: > Marcel Taeumel uploaded a new version of Morphic to project The Trunk: > http://source.squeak.org/trunk/Morphic-mt.840.mcz > > ==================== Summary ==================== > > Name: Morphic-mt.840 > Author: mt > Time: 7 April 2015, 4:07:11.316 pm > UUID: 10096b48-db09-584e-a4d4-bb2000e87db2 > Ancestors: Morphic-topa.839 > > Changed postscript to force world main docking bar update. > > Some other preferences might reset. > > =============== Diff against Morphic-topa.839 =============== > > Item was changed: > (PackageInfo named: 'Morphic') postscript: '(Preferences dictionaryOfPreferences at: #alternativeWindowBoxesLook) defaultValue: false. > "Force SystemProgressMorph to be reset" > SystemProgressMorph initialize; reset. > > "Initialize the key bindings and menus" > Editor initialize. > > "Retain scrollBar look now that the pref actually does something" > Preferences enable: #gradientScrollBars. > > "apply the new icons" > MenuIcons initializeIcons. > TheWorldMainDockingBar updateInstances. > > + > "Cleanup old-style preferences here. Remove before new release." > Preferences removePreference: #gradientMenu. "Now in MenuMorph." > Preferences removePreference: #roundedMenuCorners. "Now in MenuMorph." > > "Fix clipping bug of open windows. New ones are not affected." > TransformMorph allInstances do: [:ea | ea clipSubmorphs: true].'! > > > From leves at elte.hu Tue Apr 7 14:39:41 2015 From: leves at elte.hu (Levente Uzonyi) Date: Tue Apr 7 14:39:46 2015 Subject: [squeak-dev] Can we get Squeak green for the release? In-Reply-To: <54C3EEC4-FA57-4D37-954C-D5B6F98A2393@gmx.de> References: <54C3EEC4-FA57-4D37-954C-D5B6F98A2393@gmx.de> Message-ID: The decompiler is not perfect, and IIRC someone stated that it will never be. Most of these errors are "handled" by adding them as exceptions, so they are not tested. Some of these issues are probably fixable, but not many people are familiar with the decompiler. See DecompilerTests >> #decompilerFailures for the list of currently ignored methods. Levente On Tue, 7 Apr 2015, Tobias Pape wrote: > Hi > > > On 04.04.2015, at 16:59, Frank Shearar wrote: > >> On 3 April 2015 at 16:27, Tobias Pape wrote: >>> Hey >>> >>> I am watching the CI doing its work as changes and fixes >>> chime in. >>> I noticed that there are still 13 test failing[1] and I'm >>> not sure how all of them should be fixed :) >>> Let's make it green! >> >> I am _very very happy_ to see someone other than me harping on about >> tests! Please carry on! >> >> This one ought to be easy to fix: it's a small breakage in the >> modularity of the image; some methods need to be recategorised as not >> being System: http://build.squeak.org/job/SqueakTrunk/1207/testReport/Tests.Dependencies/PackageDependencyTest/testSystem/ >> >> This one too: http://build.squeak.org/job/SqueakTrunk/1207/testReport/Tests.Dependencies/PackageDependencyTest/testTools/ >> (Tools shouldn't depend on _ToolBuilder-Morphic_, even though it would >> be OK to depend on ToolBuilder.) >> >> And I love that this one fails - >> http://build.squeak.org/job/SqueakTrunk/1207/testReport/Tests.Dependencies/PackageDependencyTest/testMultilingual/ >> - Multilingual no longer depends on TrueType, and our system just got >> one dependency cleaner. > > I did some things :) > > But I need help: > There's a strange thing in the decompiler/compiler: > > http://build.squeak.org/job/SqueakTrunk/lastCompletedBuild/testReport/Tests.Compiler/DecompilerTests/testDecompilerInClassesBAtoBM/ > > Somewhere in Behavior>>#toolIconSelector:, > a sequence of 'push nil. pop' is generated that is decompiled as 'nil.'. > This does not match the source and I don't know whether it's a bug in > the Compiler emitting this or the Decompiler not recognizing the emitted > pattern. > > Best > -Tobias > > > From leves at elte.hu Tue Apr 7 14:43:25 2015 From: leves at elte.hu (Levente Uzonyi) Date: Tue Apr 7 14:43:28 2015 Subject: [squeak-dev] The Inbox: ShoutCore-cmm.45.mcz In-Reply-To: References: Message-ID: +1 Also, my intention was to suggest to add new, separate style tables, not to overwrite the existing (widely used) ones. I've already expressed that I don't like these colors, but I'm sure some people do. That's why there should be a preference (with a chooser like the haloTheme preference) to choose a style table. Levente On Tue, 7 Apr 2015, Tobias Pape wrote: > > On 06.04.2015, at 22:52, commits@source.squeak.org wrote: > >> A new version of ShoutCore was added to project The Inbox: >> http://source.squeak.org/inbox/ShoutCore-cmm.45.mcz >> >> ==================== Summary ==================== >> >> Name: ShoutCore-cmm.45 >> Author: cmm >> Time: 6 April 2015, 5:52:19.582 pm >> UUID: 7f2c4864-c8d9-4f51-8553-23db02266ad0 >> Ancestors: ShoutCore-cmm.44 >> >> - Added subdued version of Shout colors proposed in cmm.44. >> - #defaultStyleTable is misnamed because it was was not the default. Renamed it to #brightStyleTable. >> - Simplify help text for #subduedSyntaxHighlights. >> > > Did you integrate you changes into the subdued style now? > Please leave the subdued style. > Maybe we should allow for several styles? > > > > Personally, I don't like the color choice yo are proposing, too much green, > too hard to figure out at a glance the proportions of the following concepts: > > "direct access" (instvars, classes, formerly black) vs > "messages" (formerly blueish), > "self/supers" (formerly reddish) > > The proportions of the three rather distinct colors gave me a subconscious hint, > whether the method was idiomatic or not? > > Also, please be very careful with underlining. The once only bolded message name > is now bold AND green AND underlined. Thats a tad too much attention. Moreover, > UML uses underlining for 'static methods' aka class methods. this could be confusing. > > Don't get me wrong, I _like_ a variety of syntax highlighting styles, we > should support that better. I, however, don't think it is a good idea to > override a relatively accustomed style just because "it's time for a change". > > :) > > Best > -Tobias > > >> =============== Diff against ShoutCore-cmm.44 =============== >> >> Item was added: > > > > > From commits at source.squeak.org Tue Apr 7 14:49:01 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 14:49:03 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.841.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.841.mcz ==================== Summary ==================== Name: Morphic-mt.841 Author: mt Time: 7 April 2015, 4:48:29.949 pm UUID: 9d290349-e1cd-9341-819f-520e8330bc05 Ancestors: Morphic-mt.840 Fixed preference "menu request updates selection" to honor model's #okToChange. =============== Diff against Morphic-mt.840 =============== Item was changed: ----- Method: PluggableListMorph>>mouseDown: (in category 'events') ----- mouseDown: evt | selectors row | row := self rowAtLocation: evt position. evt yellowButtonPressed "First check for option (menu) click" ifTrue: [ + (self class menuRequestUpdatesSelection and: [model okToChange]) ifTrue: [ - self class menuRequestUpdatesSelection ifTrue: [ "Models depend on the correct selection:" self selectionIndex = (self modelIndexFor: row) ifFalse: [self changeModelSelection: (self modelIndexFor: row)]]. ^ self yellowButtonActivity: evt shiftPressed]. row = 0 ifTrue: [^super mouseDown: evt]. "self dragEnabled ifTrue: [aMorph highlightForMouseDown]." selectors := Array with: #click: with: (doubleClickSelector ifNotNil:[#doubleClick:]) with: nil with: (self dragEnabled ifTrue:[#startDrag:] ifFalse:[nil]). evt hand waitForClicksOrDrag: self event: evt selectors: selectors threshold: HandMorph dragThreshold "pixels".! Item was changed: ----- Method: SimpleHierarchicalListMorph>>mouseDown: (in category 'event handling') ----- mouseDown: evt | aMorph selectors | aMorph := self itemFromPoint: evt position. evt yellowButtonPressed "First check for option (menu) click" ifTrue: [ + (PluggableListMorph menuRequestUpdatesSelection and: [model okToChange]) ifTrue: [ - PluggableListMorph menuRequestUpdatesSelection ifTrue: [ aMorph == selectedMorph ifFalse: [self setSelectedMorph: aMorph]]. ^ self yellowButtonActivity: evt shiftPressed]. (aMorph notNil and:[aMorph inToggleArea: (aMorph point: evt position from: self)]) ifTrue:[^self toggleExpandedState: aMorph event: evt]. aMorph ifNil:[^super mouseDown: evt]. aMorph highlightForMouseDown. selectors := Array with: #click: with: nil with: nil with: (self dragEnabled ifTrue:[#startDrag:] ifFalse:[nil]). evt hand waitForClicksOrDrag: self event: evt selectors: selectors threshold: HandMorph dragThreshold "pixels".! From marcel.taeumel at student.hpi.uni-potsdam.de Tue Apr 7 14:44:22 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Tue Apr 7 14:56:46 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.840.mcz In-Reply-To: References: Message-ID: <1428417862002-4818060.post@n4.nabble.com> So for each change in, say, Morphic, I wipe its postload script and add my one stuff for the current changes? The update process max hence have multiple postload scripts to execute? Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-840-mcz-tp4818042p4818060.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From leves at elte.hu Tue Apr 7 15:15:25 2015 From: leves at elte.hu (Levente Uzonyi) Date: Tue Apr 7 15:15:29 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.840.mcz In-Reply-To: <1428417862002-4818060.post@n4.nabble.com> References: <1428417862002-4818060.post@n4.nabble.com> Message-ID: No. The postscript (and all other scripts) of a package is executed once (in most cases). Since the update process loads the Monticello Configurations (.mcm files) one by one, therefore you can only have one postscript per package per MC configuration. This means that there are a few different cases: (1) If you're the first to add a postscript to a package since the last .mcm, then you must delete its contents (if any) and add your code to it. (2) If you're not the first (the script exists with some code in it), then you have to check if the existing content can be run again. If yes, then append your code to the postscript. (3) In any other cases you have to create a new .mcm file first, then do what's in (1). It's also good to know that currently the postscript of a package is executed _before_ the new or modified class side #initialize methods of the package. We'll probably want to change this. Levente On Tue, 7 Apr 2015, Marcel Taeumel wrote: > So for each change in, say, Morphic, I wipe its postload script and add my > one stuff for the current changes? The update process max hence have > multiple postload scripts to execute? > > Best, > Marcel > > > > -- > View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-840-mcz-tp4818042p4818060.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > From leves at elte.hu Tue Apr 7 15:16:56 2015 From: leves at elte.hu (Levente Uzonyi) Date: Tue Apr 7 15:17:00 2015 Subject: [squeak-dev] The Trunk: EToys-topa.123.mcz In-Reply-To: References: Message-ID: What's wrong with #hasClassNamed:? Levente On Tue, 7 Apr 2015, commits@source.squeak.org wrote: > Tobias Pape uploaded a new version of EToys to project The Trunk: > http://source.squeak.org/trunk/EToys-topa.123.mcz > > ==================== Summary ==================== > > Name: EToys-topa.123 > Author: topa > Time: 7 April 2015, 2:37:32.593 pm > UUID: 71b565ae-57ad-4d33-91d2-d6bfeec75490 > Ancestors: EToys-topa.122 > > the ifPresent: part needs a block argument > > =============== Diff against EToys-topa.122 =============== > > Item was changed: > ----- Method: TileMorphTest>>expectedFailures (in category 'testing') ----- > expectedFailures > > ^ super expectedFailures, > (self class environment > at: #BaseSoundSystem > + ifPresent: [:e| #()] > - ifPresent: [#()] > ifAbsent: [#(testSoundTile) "Only this test depends on Sound"])! > > > From Das.Linux at gmx.de Tue Apr 7 15:20:07 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Tue Apr 7 15:20:12 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.840.mcz In-Reply-To: References: <1428417862002-4818060.post@n4.nabble.com> Message-ID: On 07.04.2015, at 17:15, Levente Uzonyi wrote: > No. > > The postscript (and all other scripts) of a package is executed once (in most cases). > Since the update process loads the Monticello Configurations (.mcm files) one by one, therefore you can only have one postscript per package per MC configuration. > This means that there are a few different cases: > (1) If you're the first to add a postscript to a package since the last .mcm, then you must delete its contents (if any) and add your code to it. > (2) If you're not the first (the script exists with some code in it), then you have to check if the existing content can be run again. If yes, then append your code to the postscript. > (3) In any other cases you have to create a new .mcm file first, then do what's in (1). > O.O I bet I won't remember this ? > It's also good to know that currently the postscript of a package is executed _before_ the new or modified class side #initialize methods of the package. We'll probably want to change this. > > Levente > > On Tue, 7 Apr 2015, Marcel Taeumel wrote: > >> So for each change in, say, Morphic, I wipe its postload script and add my >> one stuff for the current changes? The update process max hence have >> multiple postload scripts to execute? >> >> Best, >> Marcel >> >> >> >> -- >> View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-840-mcz-tp4818042p4818060.html >> Sent from the Squeak - Dev mailing list archive at Nabble.com. From Das.Linux at gmx.de Tue Apr 7 15:21:07 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Tue Apr 7 15:21:11 2015 Subject: [squeak-dev] The Trunk: EToys-topa.123.mcz In-Reply-To: References: Message-ID: On 07.04.2015, at 17:16, Levente Uzonyi wrote: > What's wrong with #hasClassNamed:? From my POV, it takes a String, and we wanted a symbol here ;) Also, I wanted t be conisten with #setUP > > Levente > > On Tue, 7 Apr 2015, commits@source.squeak.org wrote: > >> Tobias Pape uploaded a new version of EToys to project The Trunk: >> http://source.squeak.org/trunk/EToys-topa.123.mcz >> >> ==================== Summary ==================== >> >> Name: EToys-topa.123 >> Author: topa >> Time: 7 April 2015, 2:37:32.593 pm >> UUID: 71b565ae-57ad-4d33-91d2-d6bfeec75490 >> Ancestors: EToys-topa.122 >> >> the ifPresent: part needs a block argument >> >> =============== Diff against EToys-topa.122 =============== >> >> Item was changed: >> ----- Method: TileMorphTest>>expectedFailures (in category 'testing') ----- >> expectedFailures >> >> ^ super expectedFailures, >> (self class environment >> at: #BaseSoundSystem >> + ifPresent: [:e| #()] >> - ifPresent: [#()] >> ifAbsent: [#(testSoundTile) "Only this test depends on Sound"])! From leves at elte.hu Tue Apr 7 15:24:38 2015 From: leves at elte.hu (Levente Uzonyi) Date: Tue Apr 7 15:24:42 2015 Subject: [squeak-dev] The Trunk: EToys-topa.123.mcz In-Reply-To: References: Message-ID: But at the same time we want to minimize the usage of the dictionary API of the Environments. And Symbols are still Strings. :) Levente On Tue, 7 Apr 2015, Tobias Pape wrote: > > On 07.04.2015, at 17:16, Levente Uzonyi wrote: > >> What's wrong with #hasClassNamed:? > > From my POV, it takes a String, and we wanted a symbol here ;) > Also, I wanted t be conisten with #setUP > >> >> Levente >> >> On Tue, 7 Apr 2015, commits@source.squeak.org wrote: >> >>> Tobias Pape uploaded a new version of EToys to project The Trunk: >>> http://source.squeak.org/trunk/EToys-topa.123.mcz >>> >>> ==================== Summary ==================== >>> >>> Name: EToys-topa.123 >>> Author: topa >>> Time: 7 April 2015, 2:37:32.593 pm >>> UUID: 71b565ae-57ad-4d33-91d2-d6bfeec75490 >>> Ancestors: EToys-topa.122 >>> >>> the ifPresent: part needs a block argument >>> >>> =============== Diff against EToys-topa.122 =============== >>> >>> Item was changed: >>> ----- Method: TileMorphTest>>expectedFailures (in category 'testing') ----- >>> expectedFailures >>> >>> ^ super expectedFailures, >>> (self class environment >>> at: #BaseSoundSystem >>> + ifPresent: [:e| #()] >>> - ifPresent: [#()] >>> ifAbsent: [#(testSoundTile) "Only this test depends on Sound"])! > > > > From leves at elte.hu Tue Apr 7 15:25:39 2015 From: leves at elte.hu (Levente Uzonyi) Date: Tue Apr 7 15:25:42 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.840.mcz In-Reply-To: References: <1428417862002-4818060.post@n4.nabble.com> Message-ID: It's easy to find out if you know how the update process works. Levente On Tue, 7 Apr 2015, Tobias Pape wrote: > > On 07.04.2015, at 17:15, Levente Uzonyi wrote: > >> No. >> >> The postscript (and all other scripts) of a package is executed once (in most cases). >> Since the update process loads the Monticello Configurations (.mcm files) one by one, therefore you can only have one postscript per package per MC configuration. >> This means that there are a few different cases: >> (1) If you're the first to add a postscript to a package since the last .mcm, then you must delete its contents (if any) and add your code to it. >> (2) If you're not the first (the script exists with some code in it), then you have to check if the existing content can be run again. If yes, then append your code to the postscript. >> (3) In any other cases you have to create a new .mcm file first, then do what's in (1). >> > > O.O I bet I won't remember this ? > >> It's also good to know that currently the postscript of a package is executed _before_ the new or modified class side #initialize methods of the package. We'll probably want to change this. >> >> Levente >> >> On Tue, 7 Apr 2015, Marcel Taeumel wrote: >> >>> So for each change in, say, Morphic, I wipe its postload script and add my >>> one stuff for the current changes? The update process max hence have >>> multiple postload scripts to execute? >>> >>> Best, >>> Marcel >>> >>> >>> >>> -- >>> View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-840-mcz-tp4818042p4818060.html >>> Sent from the Squeak - Dev mailing list archive at Nabble.com. > > > > From asqueaker at gmail.com Tue Apr 7 15:27:15 2015 From: asqueaker at gmail.com (Chris Muller) Date: Tue Apr 7 15:27:18 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.829.mcz In-Reply-To: <5523848d.de28370a.59db.ffffd153SMTPIN_ADDED_MISSING@mx.google.com> References: <5523848d.de28370a.59db.ffffd153SMTPIN_ADDED_MISSING@mx.google.com> Message-ID: Ahh thank you! On Tue, Apr 7, 2015 at 2:16 AM, wrote: > Marcel Taeumel uploaded a new version of Morphic to project The Trunk: > http://source.squeak.org/trunk/Morphic-mt.829.mcz > > ==================== Summary ==================== > > Name: Morphic-mt.829 > Author: mt > Time: 7 April 2015, 9:16:41.005 am > UUID: b0d0bfd8-0f93-8646-a532-dbceaa818990 > Ancestors: Morphic-mt.828 > > Fixed the search bar to select all of its current contents on activation again (instead of deleting them).. > > =============== Diff against Morphic-mt.828 =============== > > Item was changed: > ----- Method: SearchBar>>activate:in: (in category 'accessing') ----- > activate: event in: morph > > + self selection: (1 to: self searchTerm size). > - self searchTerm: ''. "We cannot select all here, because we only get contents on #accept, which triggers a search. So earse the term." > event hand newKeyboardFocus: morph textMorph.! > > Item was changed: > ----- Method: SearchBar>>buildWith: (in category 'toolbuilder') ----- > buildWith: builder > > ^ (builder build: (builder pluggableInputFieldSpec new > model: self; > getText: #searchTerm; > setText: #smartSearch:in:; > + editText: #searchTermSilently:; > menu: #menu:shifted:; > selection: #selection; > help: 'Search...' translated)) > name: #searchBar; > wantsFrameAdornments: false; > borderWidth: 0; > yourself! > > Item was added: > + ----- Method: SearchBar>>searchTermSilently: (in category 'accessing') ----- > + searchTermSilently: aString. > + "Do not signal it to the model." > + > + searchTerm := aString.! > > From bert at freudenbergs.de Tue Apr 7 15:34:32 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Tue Apr 7 15:34:35 2015 Subject: [squeak-dev] Package postscripts (was: The Trunk: Morphic-mt.840.mcz) In-Reply-To: References: <1428417862002-4818060.post@n4.nabble.com> Message-ID: <5C4C67F1-4BD7-48D9-8896-7500BB701262@freudenbergs.de> On 07.04.2015, at 17:20, Tobias Pape wrote: > > > On 07.04.2015, at 17:15, Levente Uzonyi wrote: > >> No. >> >> The postscript (and all other scripts) of a package is executed once (in most cases). >> Since the update process loads the Monticello Configurations (.mcm files) one by one, therefore you can only have one postscript per package per MC configuration. >> This means that there are a few different cases: >> (1) If you're the first to add a postscript to a package since the last .mcm, then you must delete its contents (if any) and add your code to it. >> (2) If you're not the first (the script exists with some code in it), then you have to check if the existing content can be run again. If yes, then append your code to the postscript. >> (3) In any other cases you have to create a new .mcm file first, then do what's in (1). >> > > O.O I bet I won't remember this ? I find it easier to write scripts in a way so they can be executed repeatedly without harm. You just append new stuff below, with a comment mentioning the package version you added it. You can also check if the previous snippets are older than the version in the latest config map. If so, you can safely remove them. At the top of the script there should probably a comment explaining this process. - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150407/7f6d492f/smime-0001.bin From Das.Linux at gmx.de Tue Apr 7 15:49:35 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Tue Apr 7 15:49:38 2015 Subject: [squeak-dev] The Trunk: EToys-topa.123.mcz In-Reply-To: References: Message-ID: On 07.04.2015, at 17:24, Levente Uzonyi wrote: > But at the same time we want to minimize the usage of the dictionary API of the Environments. Do we? > And Symbols are still Strings. :) I disagree. Best -Tobias > > Levente > > On Tue, 7 Apr 2015, Tobias Pape wrote: > >> >> On 07.04.2015, at 17:16, Levente Uzonyi wrote: >> >>> What's wrong with #hasClassNamed:? >> >> From my POV, it takes a String, and we wanted a symbol here ;) >> Also, I wanted t be conisten with #setUP >> >>> >>> Levente >>> >>> On Tue, 7 Apr 2015, commits@source.squeak.org wrote: >>> >>>> Tobias Pape uploaded a new version of EToys to project The Trunk: >>>> http://source.squeak.org/trunk/EToys-topa.123.mcz >>>> >>>> ==================== Summary ==================== >>>> >>>> Name: EToys-topa.123 >>>> Author: topa >>>> Time: 7 April 2015, 2:37:32.593 pm >>>> UUID: 71b565ae-57ad-4d33-91d2-d6bfeec75490 >>>> Ancestors: EToys-topa.122 >>>> >>>> the ifPresent: part needs a block argument >>>> >>>> =============== Diff against EToys-topa.122 =============== >>>> >>>> Item was changed: >>>> ----- Method: TileMorphTest>>expectedFailures (in category 'testing') ----- >>>> expectedFailures >>>> >>>> ^ super expectedFailures, >>>> (self class environment >>>> at: #BaseSoundSystem >>>> + ifPresent: [:e| #()] >>>> - ifPresent: [#()] >>>> ifAbsent: [#(testSoundTile) "Only this test depends on Sound"])! From bert at freudenbergs.de Tue Apr 7 16:06:47 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Tue Apr 7 16:06:50 2015 Subject: [squeak-dev] The Trunk: EToys-topa.123.mcz In-Reply-To: References: Message-ID: On 07.04.2015, at 17:49, Tobias Pape wrote: > > On 07.04.2015, at 17:24, Levente Uzonyi wrote: > >> But at the same time we want to minimize the usage of the dictionary API of the Environments. > > Do we? > >> And Symbols are still Strings. :) > > I disagree. In Smalltalk, they are. - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150407/170b7728/smime.bin From marcel.taeumel at student.hpi.uni-potsdam.de Tue Apr 7 15:54:39 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Tue Apr 7 16:07:03 2015 Subject: [squeak-dev] Re: The Inbox: ShoutCore-cmm.45.mcz In-Reply-To: References: Message-ID: <1428422079509-4818111.post@n4.nabble.com> +1 Yes, only add color styles for Shout, do not remove them. Best, Marcel -- View this message in context: http://forum.world.st/The-Inbox-ShoutCore-cmm-45-mcz-tp4817909p4818111.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From leves at elte.hu Tue Apr 7 16:07:08 2015 From: leves at elte.hu (Levente Uzonyi) Date: Tue Apr 7 16:07:15 2015 Subject: [squeak-dev] The Trunk: EToys-topa.123.mcz In-Reply-To: References: Message-ID: On Tue, 7 Apr 2015, Tobias Pape wrote: > > On 07.04.2015, at 17:24, Levente Uzonyi wrote: > >> But at the same time we want to minimize the usage of the dictionary API of the Environments. > > Do we? I could only quote myself here, so someone else will have to answer this. > >> And Symbols are still Strings. :) > > I disagree. #aSymbol isKindOf: String. "==> true" Should the code be portable to other Smalltalk dialects? Do we plan to change the superclass of Symbol? Is there any other reason to not use symbols as strings in Squeak? Levente > > Best > -Tobias > >> >> Levente >> >> On Tue, 7 Apr 2015, Tobias Pape wrote: >> >>> >>> On 07.04.2015, at 17:16, Levente Uzonyi wrote: >>> >>>> What's wrong with #hasClassNamed:? >>> >>> From my POV, it takes a String, and we wanted a symbol here ;) >>> Also, I wanted t be conisten with #setUP >>> >>>> >>>> Levente >>>> >>>> On Tue, 7 Apr 2015, commits@source.squeak.org wrote: >>>> >>>>> Tobias Pape uploaded a new version of EToys to project The Trunk: >>>>> http://source.squeak.org/trunk/EToys-topa.123.mcz >>>>> >>>>> ==================== Summary ==================== >>>>> >>>>> Name: EToys-topa.123 >>>>> Author: topa >>>>> Time: 7 April 2015, 2:37:32.593 pm >>>>> UUID: 71b565ae-57ad-4d33-91d2-d6bfeec75490 >>>>> Ancestors: EToys-topa.122 >>>>> >>>>> the ifPresent: part needs a block argument >>>>> >>>>> =============== Diff against EToys-topa.122 =============== >>>>> >>>>> Item was changed: >>>>> ----- Method: TileMorphTest>>expectedFailures (in category 'testing') ----- >>>>> expectedFailures >>>>> >>>>> ^ super expectedFailures, >>>>> (self class environment >>>>> at: #BaseSoundSystem >>>>> + ifPresent: [:e| #()] >>>>> - ifPresent: [#()] >>>>> ifAbsent: [#(testSoundTile) "Only this test depends on Sound"])! > > > > From Das.Linux at gmx.de Tue Apr 7 16:30:26 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Tue Apr 7 16:30:30 2015 Subject: [squeak-dev] The Trunk: EToys-topa.123.mcz In-Reply-To: References: Message-ID: <75C8E0CC-E8AE-4B5F-A679-516A78447B0C@gmx.de> On 07.04.2015, at 18:07, Levente Uzonyi wrote: > On Tue, 7 Apr 2015, Tobias Pape wrote: > >> >> On 07.04.2015, at 17:24, Levente Uzonyi wrote: >> >>> But at the same time we want to minimize the usage of the dictionary API of the Environments. >> >> Do we? > > I could only quote myself here, so someone else will have to answer this. > >> >>> And Symbols are still Strings. :) >> >> I disagree. > > #aSymbol isKindOf: String. "==> true" > > Should the code be portable to other Smalltalk dialects? > Do we plan to change the superclass of Symbol? > Is there any other reason to not use symbols as strings in Squeak? > Just feel free to change TileMorphTest>>#expectedFailures and TileMorphTest>>#setUp to your liking. We could also just remove it. best -tobias > > Levente > >> >> Best >> -Tobias >> >>> >>> Levente >>> >>> On Tue, 7 Apr 2015, Tobias Pape wrote: >>> >>>> >>>> On 07.04.2015, at 17:16, Levente Uzonyi wrote: >>>> >>>>> What's wrong with #hasClassNamed:? >>>> >>>> From my POV, it takes a String, and we wanted a symbol here ;) >>>> Also, I wanted t be conisten with #setUP >>>> >>>>> >>>>> Levente >>>>> >>>>> On Tue, 7 Apr 2015, commits@source.squeak.org wrote: From Das.Linux at gmx.de Tue Apr 7 16:41:47 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Tue Apr 7 16:41:59 2015 Subject: [squeak-dev] The Trunk: EToys-topa.123.mcz In-Reply-To: References: Message-ID: <397723DB-7688-482A-829D-F875ABF4F664@gmx.de> Skipped content of type multipart/mixed-------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 1625 bytes Desc: Message signed with OpenPGP using GPGMail Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150407/a2af12f0/signature-0001.pgp From commits at source.squeak.org Tue Apr 7 16:43:53 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 16:43:54 2015 Subject: [squeak-dev] The Trunk: Monticello-mt.610.mcz Message-ID: Marcel Taeumel uploaded a new version of Monticello to project The Trunk: http://source.squeak.org/trunk/Monticello-mt.610.mcz ==================== Summary ==================== Name: Monticello-mt.610 Author: mt Time: 7 April 2015, 6:43:41.185 pm UUID: 2ecec5d8-703e-1d49-995d-afe7f11e69b2 Ancestors: Monticello-tfel.609 Introduced the possibility to offer one-line input fields in the MC tool builder. Used it in the save-version dialog. =============== Diff against Monticello-tfel.609 =============== Item was changed: ----- Method: MCSaveVersionDialog>>widgetSpecs (in category 'ui') ----- widgetSpecs ^ #( ((listMorph:selection:menu:keystroke: list selection methodListMenu: methodListKey:from:) (0 0 0.5 0.6) (0 0 0 -47) ) + ((inputMorph: versionName) (0.5 0 1 0) (0 0 0 30)) - ((textMorph: versionName) (0.5 0 1 0) (0 0 0 30)) ((textMorph: logMessage) (0.5 0 1 0.6) (0 30 0 -47)) ((buttonRow) (0.5 0.6 1 0.6) (0 -47 0 0)) ((textMorph: annotations) (0 0.6 0.5 0.6) (0 -47 0 0)) ((textMorph: text) (0 0.6 1 1) (0 0 0 0)) )! Item was added: + ----- Method: MCToolWindowBuilder>>inputMorph: (in category 'as yet unclassified') ----- + inputMorph: aSymbol + | text | + text := builder pluggableInputFieldSpec new. + text + model: tool; + getText: aSymbol; + setText: (aSymbol, ':') asSymbol; + frame: currentFrame. + window children add: text! From Das.Linux at gmx.de Tue Apr 7 16:46:01 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Tue Apr 7 16:46:06 2015 Subject: [squeak-dev] The Trunk: Monticello-mt.610.mcz Message-ID: On 07.04.2015, at 16:43, commits@source.squeak.org wrote: > Marcel Taeumel uploaded a new version of Monticello to project The Trunk: > http://source.squeak.org/trunk/Monticello-mt.610.mcz > > ==================== Summary ==================== > > Name: Monticello-mt.610 > Author: mt > Time: 7 April 2015, 6:43:41.185 pm > UUID: 2ecec5d8-703e-1d49-995d-afe7f11e69b2 > Ancestors: Monticello-tfel.609 > > Introduced the possibility to offer one-line input fields in the MC tool builder. > > Used it in the save-version dialog. > > =============== Diff against Monticello-tfel.609 =============== > > Item was changed: > ----- Method: MCSaveVersionDialog>>widgetSpecs (in category 'ui') ----- > widgetSpecs > ^ #( > ((listMorph:selection:menu:keystroke: list selection methodListMenu: methodListKey:from:) (0 0 0.5 0.6) (0 0 0 -47) ) > + ((inputMorph: versionName) (0.5 0 1 0) (0 0 0 30)) > - ((textMorph: versionName) (0.5 0 1 0) (0 0 0 30)) > ((textMorph: logMessage) (0.5 0 1 0.6) (0 30 0 -47)) > ((buttonRow) (0.5 0.6 1 0.6) (0 -47 0 0)) > ((textMorph: annotations) (0 0.6 0.5 0.6) (0 -47 0 0)) > ((textMorph: text) (0 0.6 1 1) (0 0 0 0)) > )! > > Item was added: > + ----- Method: MCToolWindowBuilder>>inputMorph: (in category 'as yet unclassified') ----- > + inputMorph: aSymbol > + | text | > + text := builder pluggableInputFieldSpec new. > + text > + model: tool; > + getText: aSymbol; > + setText: (aSymbol, ':') asSymbol; what about setText: aSymbol asMutator; here? Best -Tobias > + frame: currentFrame. > + window children add: text! > > From commits at source.squeak.org Tue Apr 7 16:56:43 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 16:56:46 2015 Subject: [squeak-dev] The Trunk: Tests-topa.317.mcz Message-ID: Tobias Pape uploaded a new version of Tests to project The Trunk: http://source.squeak.org/trunk/Tests-topa.317.mcz ==================== Summary ==================== Name: Tests-topa.317 Author: topa Time: 7 April 2015, 6:56:32.057 pm UUID: 700b4f27-bd86-43aa-bbee-802c1e824277 Ancestors: Tests-topa.316 Behavior toolIconSelector: has a strang push-nil, pop sequence. =============== Diff against Tests-topa.316 =============== Item was changed: ----- Method: DecompilerTests>>decompilerFailures (in category 'utilities') ----- decompilerFailures "Here is the list of failures: either a syntax error, a hard error or some failure to decompile correctly. Collected via CurrentReadOnlySourceFiles cacheDuring: [ (DecompilerTestFailuresCollector new computeFailures collect: [:mr| { mr classSymbol. mr selector }]) asArray ]." + ^#( (Behavior toolIconSelector:) + (BrowserCommentTextMorph showPane) - ^#( (BrowserCommentTextMorph showPane) (ClassDescription replaceSilently:to:) (CodeHolder getSelectorAndSendQuery:to:with:) (Date printOn:) (DecompilerTests testDecompileUnreachableParameter) (HttpUrl checkAuthorization:retry:) (MCConfigurationBrowser post) (MailComposition breakLinesInMessage:) (MVCToolBuilder setLayout:in:) "same-name block-local temps in optimized blocks" (ParagraphEditor inOutdent:delta:) (PNGReadWriter copyPixelsGray:) (PointTest testNormal) "fraction printing??" (PointTest testTheta) "fraction printing??" (ScaledDecimalTest testConvertFromFraction) "local/non-local temps" (StandardScriptingSystem holderWithAlphabet) "same-name block-local temps in optimized blocks" (SystemWindow convertAlignment) (TextEditor inOutdent:delta:) (TextURL actOnClickFor:) (TTContourConstruction segmentsDo:) "Worth fixing; these two are mistaken conversion from a whileTrue: to a to:do: but the index is used outside the whileTrue:" (TTFontReader processHorizontalMetricsTable:length:))! From eliot.miranda at gmail.com Tue Apr 7 16:57:45 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Tue Apr 7 16:57:50 2015 Subject: [squeak-dev] Re: Bug whith contextOn:do: In-Reply-To: <687515E7-90D5-4554-B558-4882B62FB9FA@freudenbergs.de> References: <85F38DF9-1002-49A4-B11B-0DF96E0A7E76@gmx.de> <1AA83643-080E-4CA3-89ED-3C9F9876AFF1@freudenbergs.de> <1E90C927-7C12-4E98-9CFB-96C60D491FCD@gmx.de> <687515E7-90D5-4554-B558-4882B62FB9FA@freudenbergs.de> Message-ID: Hi Bert, sorry. Got deep into something and have only just come up for air... On Thu, Apr 2, 2015 at 1:02 AM, Bert Freudenberg wrote: > On 01.04.2015, at 20:51, Eliot Miranda wrote: > > >> > I would find it very surprising if #jump would result in the execution >> continuing in a different process. >> > >> > That's not what they do. Instead they spawn another process to >> position the process in which we want to jump correctly. >> >> We don't want to jump to a process but within a process, like a goto? >> > > Well, jump doesn't do unwinds so the code should be simply: > > jump > "Abandon thisContext and resume self instead (using the same current > process)." > | process | > process := Processor activeProcess. > [process suspendedContext: self] fork. > Processor yield > > > Ah, I misread what you were proposing before. Simpler is better for > understanding :) > > Assuming there are more runnable processes at the active priority, could > there be a scenario where the #jump context is resumed after the yield, > before the forked process had a chance to run? Or would we have to fork it > at a higher priority? Could either in any way mess with the order of > process activation, which would not happen with the current #jump > implementation? > That depends. If the VM is /not/ in the processPreemptionYields regime (and I need to remember to put Spur images into this regime) then no, doing the fork at a higher priority cannot disturb processes. But if the process is forked at the same priority, or if the VM is in the processPreemptionYields regime, then yes, this can screw up process priorities. So assuming Smalltalk processPreemptionYields: false then the following is, I think, safe: jump "Abandon thisContext and resume self instead (using the same current process)." | process | process := Processor activeProcess. [process suspendedContext: self] forkAt: Processor activePriority + 1 of course this fails at max priority. Since we don't use the max priority we can get away with this. I think that's more acceptable than getting away with occasionally popping the receiver off a context's stack, no? If that's not acceptable we need a primitive. > - Bert - > > > > > > > -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150407/e838e0e8/attachment.htm From asqueaker at gmail.com Tue Apr 7 17:17:22 2015 From: asqueaker at gmail.com (Chris Muller) Date: Tue Apr 7 17:17:25 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.835.mcz In-Reply-To: <5523a961.01c9e50a.6256.ffffaf26SMTPIN_ADDED_MISSING@mx.google.com> References: <5523a961.01c9e50a.6256.ffffaf26SMTPIN_ADDED_MISSING@mx.google.com> Message-ID: Marcel, thanks so much for making the Search Bar better. Hey, on this, instead of width: 200 how about simply hResizing: #spaceFill? I like that because when the image window is large, SB is generously sized (and yet not too big) and if the image window is sized small, it still fits as best it can. On Tue, Apr 7, 2015 at 4:54 AM, wrote: > Marcel Taeumel uploaded a new version of Morphic to project The Trunk: > http://source.squeak.org/trunk/Morphic-mt.835.mcz > > ==================== Summary ==================== > > Name: Morphic-mt.835 > Author: mt > Time: 7 April 2015, 11:54:01.456 am > UUID: 178521f6-057f-fa40-b4e6-8463970180de > Ancestors: Morphic-mt.834 > > Default search bar width increased to 200 pixel. > > =============== Diff against Morphic-mt.834 =============== > > Item was changed: > ----- Method: TheWorldMainDockingBar>>searchBarOn: (in category 'right side') ----- > searchBarOn: aDockingBar > > aDockingBar > + addMorphBack: (SearchBar build vResizing: #spaceFill; width: 200); > - addMorphBack: (SearchBar build vResizing: #spaceFill); > addDefaultSpace! > > From Das.Linux at gmx.de Tue Apr 7 17:17:48 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Tue Apr 7 17:17:51 2015 Subject: [squeak-dev] Only 7 to go :) Message-ID: [ http://build.squeak.org/job/SqueakTrunk/1230/testReport/ ] Best -Tobias From karlramberg at gmail.com Tue Apr 7 17:32:20 2015 From: karlramberg at gmail.com (karl ramberg) Date: Tue Apr 7 17:32:24 2015 Subject: [squeak-dev] Re: A note on current window colors in Trunk In-Reply-To: <1428221943587-4817640.post@n4.nabble.com> References: <1428146039598-4817485.post@n4.nabble.com> <1428221943587-4817640.post@n4.nabble.com> Message-ID: Hi, It was a setting in my image that made this problem. Please ignore this. Karl On Sun, Apr 5, 2015 at 10:19 AM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > Can you provide a small screenshot? I did not touch that color... :-) > > Best, > Marcel > > > > -- > View this message in context: > http://forum.world.st/A-note-on-current-window-colors-in-Trunk-tp4817485p4817640.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150407/ebf36075/attachment.htm From karlramberg at gmail.com Tue Apr 7 17:33:47 2015 From: karlramberg at gmail.com (karl ramberg) Date: Tue Apr 7 17:33:51 2015 Subject: [squeak-dev] Re: Two bugs with SystemWindow In-Reply-To: <1428227938015-4817651.post@n4.nabble.com> References: <1428133558074-4817468.post@n4.nabble.com> <1428227938015-4817651.post@n4.nabble.com> Message-ID: Thanks Karl On Sun, Apr 5, 2015 at 11:58 AM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > I think I fixed that problem: > http://forum.world.st/The-Trunk-Morphic-mt-824-mcz-td4817650.html > > Best, > Marcel > > > > -- > View this message in context: > http://forum.world.st/Two-bugs-with-SystemWindow-tp4817430p4817651.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150407/3eecbfb9/attachment.htm From karlramberg at gmail.com Tue Apr 7 17:46:11 2015 From: karlramberg at gmail.com (karl ramberg) Date: Tue Apr 7 17:46:13 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: <1428085522795-4817399.post@n4.nabble.com> References: <1428085522795-4817399.post@n4.nabble.com> Message-ID: What about a possibility to push personal preferences to a monticello repository ? Everyone could just branch off the release version with their own version and push publish. It could make maintaining preferences across several images and computers a little easier. Any reason this would not work? Karl On Fri, Apr 3, 2015 at 8:25 PM, Karl Ramberg wrote: > Hi, > May I suggest removing Universes ? > Universes seem totally defunct > > Karl > > > > -- > View this message in context: > http://forum.world.st/A-plan-for-the-release-tp4817346p4817399.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150407/f12edfc7/attachment.htm From stephan at stack.nl Tue Apr 7 18:56:56 2015 From: stephan at stack.nl (Stephan Eggermont) Date: Tue Apr 7 18:57:07 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: <1428247271169-4817689.post@n4.nabble.com> References: <1428075270847-4817347.post@n4.nabble.com> <1428080178583-4817382.post@n4.nabble.com> <1428140501554-4817477.post@n4.nabble.com> <3C16CB19-9ABA-46F0-BE1B-CC8ABA86E1A8@rowledge.org> <1428247271169-4817689.post@n4.nabble.com> Message-ID: On 05/04/15 17:21, Marcel Taeumel wrote: > Then we should double-check the default window sizes *and* add a factor for > larger resolutions. I thought about making it dependent from the font size > but we may not use a smaller font for 800x600 this time ... should we? Well, > we could... what is the opinion on the default font size for 800x600? If the > font size is affected, "go full screen" is not enough anymore... but I am > not a 800x600-user. :) The difference with developer machines starts to get really large. I think 1024*720 should be safe for nearly every device sold in the past 3 years. I recently switched to 4K, and settings for 800*600 don't work too well for that. Stephan From tim at rowledge.org Tue Apr 7 19:07:41 2015 From: tim at rowledge.org (tim Rowledge) Date: Tue Apr 7 19:07:48 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: <1428044005053-4817131.post@n4.nabble.com> Message-ID: On 03-04-2015, at 10:23 AM, Chris Muller wrote: > The "power of pointing" is a wonderful UI gesture. It's so energy > efficient for the user. A simple nudge of the mouse can spawn a lot > of output and, then, simply moving away (one more nudge) reclaims all > the screen space. Sometimes I like to pop up even /interactive/ > panels my Maui apps by merely pointing. > > What is remarkable to me is how underrated it is. I guess Windows' > click-for-focus pretty much blew it out of the water.. > Except that it is an unholy pain if your pointing device has any reason to wander on its own; like a stiff cable, a sloping surface, an accidental nudge from a moving hand, a cat, an earthquake, psychokinetic leakage etc. All of which have annoyed me at some time. tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim You never finish a program, you just stop working on it. From marcel.taeumel at student.hpi.uni-potsdam.de Tue Apr 7 19:04:32 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Tue Apr 7 19:16:58 2015 Subject: [squeak-dev] Re: bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: <1428044005053-4817131.post@n4.nabble.com> Message-ID: <1428433472489-4818173.post@n4.nabble.com> Never underestimate the cat factor! ...earthquakes are rare in Berlin area... Best, Marcel -- View this message in context: http://forum.world.st/bad-UI-bug-introduced-with-recent-list-highlightiong-changes-tp4817074p4818173.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From ma.chris.m at gmail.com Tue Apr 7 20:37:38 2015 From: ma.chris.m at gmail.com (Chris Muller) Date: Tue Apr 7 20:37:43 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: <1428044005053-4817131.post@n4.nabble.com> Message-ID: On Tue, Apr 7, 2015 at 2:07 PM, tim Rowledge wrote: > > On 03-04-2015, at 10:23 AM, Chris Muller wrote: >> The "power of pointing" is a wonderful UI gesture. It's so energy >> efficient for the user. A simple nudge of the mouse can spawn a lot >> of output and, then, simply moving away (one more nudge) reclaims all >> the screen space. Sometimes I like to pop up even /interactive/ >> panels my Maui apps by merely pointing. >> >> What is remarkable to me is how underrated it is. I guess Windows' >> click-for-focus pretty much blew it out of the water.. >> > Except that it is an unholy pain if your pointing device has any reason to wander on its own; like a stiff cable, a sloping surface, an accidental nudge from a moving hand, a cat, an earthquake, psychokinetic leakage etc. All of which have annoyed me at some time. Those are rare events compared to switching focus. A minimally competent input device setup such as a laptop with a trackpad would reduce it from rare to never. From leves at elte.hu Tue Apr 7 20:43:09 2015 From: leves at elte.hu (Levente Uzonyi) Date: Tue Apr 7 20:43:13 2015 Subject: [squeak-dev] Time primitives Message-ID: Hi All, CogVM has two really nice time primitives 240 and 241. These are available via Time class >> #primUTCMicrosecondClock and Time class >> #primLocalMicrosecondClock. But there are two problems with them. 1. They are not available in the Interpreter VM (It has a similar named primitive - primitiveUtcWithOffset - available as Time class >> #primPosixMicrosecondClockWithOffset, but that's not supported in Cog, and I'd like to see its behavior changed slightly*) 2. Primitive 240 is available in Pharo under a similar, but slightly different name: #primUTCMicrosecondsClock. There are also derived "primitive" methods: #primUTCSecondsClock and #primUTCMillisecondsClock. Questions: - Which name should we use? - #primUTCMicrosecondClock - #primUTCMicrosecondsClock - something else - Can/should the interpreter VM support primitive 240 and 241? - Can/should CogVM support the name primitive primitiveUtcWithOffset? - Do we want the derived "primitives" #primUTCSecondsClock and #primUTCMillisecondsClock in Squeak? Levente * The primitive could accept an array as argument and fill that with the values if present. This could prevent frequent GCs when the primitive is used repeatedly. From tim at rowledge.org Tue Apr 7 20:45:44 2015 From: tim at rowledge.org (tim Rowledge) Date: Tue Apr 7 20:45:50 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: References: <1428044005053-4817131.post@n4.nabble.com> Message-ID: <004971E7-B892-43EB-BB10-C8094281F4EF@rowledge.org> On 07-04-2015, at 1:37 PM, Chris Muller wrote: > On Tue, Apr 7, 2015 at 2:07 PM, tim Rowledge wrote: >> >> On 03-04-2015, at 10:23 AM, Chris Muller wrote: >>> The "power of pointing" is a wonderful UI gesture. It's so energy >>> efficient for the user. A simple nudge of the mouse can spawn a lot >>> of output and, then, simply moving away (one more nudge) reclaims all >>> the screen space. Sometimes I like to pop up even /interactive/ >>> panels my Maui apps by merely pointing. >>> >>> What is remarkable to me is how underrated it is. I guess Windows' >>> click-for-focus pretty much blew it out of the water.. >>> >> Except that it is an unholy pain if your pointing device has any reason to wander on its own; like a stiff cable, a sloping surface, an accidental nudge from a moving hand, a cat, an earthquake, psychokinetic leakage etc. All of which have annoyed me at some time. > > Those are rare events compared to switching focus. A minimally > competent input device setup such as a laptop with a trackpad would > reduce it from rare to never. But I - like quite a lot of people - don?t use a laptop. Don?t even own one. Meeses are where it?s at, dude! Whatever next - a suggestion to use one of those dreadful Selker Trackpoint monstrosities? One of the big complexifiers of modern UI design is catering for the reality of so many different ways of interacting with a system. Telling people to use a trackpad just isn?t practical. tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim Fractured Idiom:- QUE SERA SERF - Life is feudal From lewis at mail.msen.com Tue Apr 7 21:17:11 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Tue Apr 7 21:17:14 2015 Subject: [squeak-dev] Time primitives In-Reply-To: References: Message-ID: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> I am away and cannot double check the code right now, but the primitives should be consistent across Cog and the interpreter VM. There had been some confusion due to the early fork between trunk and oscog, but I believe that Eliot and I got it sorted out quite a while ago. These are not necessarily set up as numbered primitives, but the implementations are there, and they can be called as named primitives in Cog/Spur and interpreter VMs. I don't know about the Pharo fork, it's quite possible that things have gotten renamed there. Note, the UTC with offset primitive is important to me because of UTCDateAndTime (http://wiki.squeak.org/squeak/6197), which is designed around the notion of a single primitive answering UTC time and local offset as an atomic call to the VM. Dave > Hi All, > > CogVM has two really nice time primitives 240 and 241. These are available > via Time class >> #primUTCMicrosecondClock and Time class >> > #primLocalMicrosecondClock. > > But there are two problems with them. > 1. They are not available in the Interpreter VM (It has a similar named > primitive - primitiveUtcWithOffset - available as Time class >> > #primPosixMicrosecondClockWithOffset, but that's not supported in Cog, and > I'd like to see its behavior changed slightly*) > 2. Primitive 240 is available in Pharo under a similar, but slightly > different name: #primUTCMicrosecondsClock. There are also derived > "primitive" methods: #primUTCSecondsClock and #primUTCMillisecondsClock. > > Questions: > - Which name should we use? > - #primUTCMicrosecondClock > - #primUTCMicrosecondsClock > - something else > > - Can/should the interpreter VM support primitive 240 and 241? > > - Can/should CogVM support the name primitive primitiveUtcWithOffset? > > - Do we want the derived "primitives" #primUTCSecondsClock and > #primUTCMillisecondsClock in Squeak? > > > Levente > > * The primitive could accept an array as argument and fill that with the > values if present. This could prevent frequent GCs when the primitive is > used repeatedly. > From ma.chris.m at gmail.com Tue Apr 7 21:28:54 2015 From: ma.chris.m at gmail.com (Chris Muller) Date: Tue Apr 7 21:28:58 2015 Subject: [squeak-dev] bad UI bug introduced with recent list highlightiong changes. In-Reply-To: <004971E7-B892-43EB-BB10-C8094281F4EF@rowledge.org> References: <1428044005053-4817131.post@n4.nabble.com> <004971E7-B892-43EB-BB10-C8094281F4EF@rowledge.org> Message-ID: >>>> The "power of pointing" is a wonderful UI gesture. It's so energy >>>> efficient for the user. A simple nudge of the mouse can spawn a lot >>>> of output and, then, simply moving away (one more nudge) reclaims all >>>> the screen space. Sometimes I like to pop up even /interactive/ >>>> panels my Maui apps by merely pointing. >>>> >>>> What is remarkable to me is how underrated it is. I guess Windows' >>>> click-for-focus pretty much blew it out of the water.. >>>> >>> Except that it is an unholy pain if your pointing device has any reason to wander on its own; like a stiff cable, a sloping surface, an accidental nudge from a moving hand, a cat, an earthquake, psychokinetic leakage etc. All of which have annoyed me at some time. >> >> Those are rare events compared to switching focus. A minimally >> competent input device setup such as a laptop with a trackpad would >> reduce it from rare to never. > > But I - like quite a lot of people - don?t use a laptop. Don?t even own one. Meeses are where it?s at, dude! Whatever next - a suggestion to use one of those dreadful Selker Trackpoint monstrosities? > > One of the big complexifiers of modern UI design is catering for the reality of so many different ways of interacting with a system. Telling people to use a trackpad just isn?t practical. I simply suggested to use a "minimally competent input device". You mentioned the "cord" being part of your trouble so, for example, you could get a cordless mouse. Microsoft's defacto click-for-focus solution to the mouse-cord problem since Windows 3.1 has led to users around the world having to make thousands of unnecessary clicks every year to this day. Not me, because I use Squeak and fix the preferences for myself, but every time we release I get this feeling of wishing we could proudly showcase the power and elegance of Squeak's UI design, not just its Windows-emulation abilities. From leves at elte.hu Tue Apr 7 21:42:21 2015 From: leves at elte.hu (Levente Uzonyi) Date: Tue Apr 7 21:42:24 2015 Subject: [squeak-dev] Time primitives In-Reply-To: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> Message-ID: On Tue, 7 Apr 2015, David T. Lewis wrote: > I am away and cannot double check the code right now, but the primitives > should be consistent across Cog and the interpreter VM. There had been > some confusion due to the early fork between trunk and oscog, but I > believe that Eliot and I got it sorted out quite a while ago. I can confirm this, but the primitives don't work correctly on the Interpreter VM (4.10.2.2614 on linux from squeakvm.org): Time primUTCMicrosecondClock. "==> 2177453298247316" Time primPosixMicrosecondClockWithOffset. "==> #(519745201 7200)" DateAndTime now. "==> 2015-04-07T23:30:28.665+01:00" The same with CogVM: Time primUTCMicrosecondClock. "==> 3605895086935548" Time primPosixMicrosecondClockWithOffset. "==> #(1428442289746346 7200)" DateAndTime now. "==> 2015-04-07T23:31:32.962+01:00" > > These are not necessarily set up as numbered primitives, but the > implementations are there, and they can be called as named primitives in > Cog/Spur and interpreter VMs. > > I don't know about the Pharo fork, it's quite possible that things have > gotten renamed there. The primitives are the same, but the method names in the image are not, and the latter is what matters for me. It's a pain to keep code running in both branches. > > Note, the UTC with offset primitive is important to me because of > UTCDateAndTime (http://wiki.squeak.org/squeak/6197), which is designed > around the notion of a single primitive answering UTC time and local > offset as an atomic call to the VM. It seems like this primitive caches the time zone offset, which is bad when there are daylight savings changes (or when the machine goes to a different time zone). Here's the current value from a long running image: Time primPosixMicrosecondClockWithOffset. "==> #(1428442620344927 3600)" But the LocalePlugin's primitives seem like they know the truth: Locale current primTimezone. "==> 120" Locale current primDST. "==> true" Levente > > Dave > >> Hi All, >> >> CogVM has two really nice time primitives 240 and 241. These are available >> via Time class >> #primUTCMicrosecondClock and Time class >> >> #primLocalMicrosecondClock. >> >> But there are two problems with them. >> 1. They are not available in the Interpreter VM (It has a similar named >> primitive - primitiveUtcWithOffset - available as Time class >> >> #primPosixMicrosecondClockWithOffset, but that's not supported in Cog, and >> I'd like to see its behavior changed slightly*) >> 2. Primitive 240 is available in Pharo under a similar, but slightly >> different name: #primUTCMicrosecondsClock. There are also derived >> "primitive" methods: #primUTCSecondsClock and #primUTCMillisecondsClock. >> >> Questions: >> - Which name should we use? >> - #primUTCMicrosecondClock >> - #primUTCMicrosecondsClock >> - something else >> >> - Can/should the interpreter VM support primitive 240 and 241? >> >> - Can/should CogVM support the name primitive primitiveUtcWithOffset? >> >> - Do we want the derived "primitives" #primUTCSecondsClock and >> #primUTCMillisecondsClock in Squeak? >> >> >> Levente >> >> * The primitive could accept an array as argument and fill that with the >> values if present. This could prevent frequent GCs when the primitive is >> used repeatedly. >> > > > > From frank.shearar at gmail.com Tue Apr 7 21:52:36 2015 From: frank.shearar at gmail.com (Frank Shearar) Date: Tue Apr 7 21:52:39 2015 Subject: [squeak-dev] The Trunk: Help-Squeak-Project-topa.22.mcz In-Reply-To: <5523ac27.b5698c0a.29df.ffffcaa5SMTPIN_ADDED_MISSING@mx.google.com> References: <5523ac27.b5698c0a.29df.ffffcaa5SMTPIN_ADDED_MISSING@mx.google.com> Message-ID: On 7 April 2015 at 11:06, wrote: > Tobias Pape uploaded a new version of Help-Squeak-Project to project The Trunk: > http://source.squeak.org/trunk/Help-Squeak-Project-topa.22.mcz > > ==================== Summary ==================== > > Name: Help-Squeak-Project-topa.22 > Author: topa > Time: 7 April 2015, 12:06:17.426 pm > UUID: bc30874c-0d15-4cb3-b40e-be224b29f619 > Ancestors: Help-Squeak-Project-cmm.21 > > Take responsibility > > =============== Diff against Help-Squeak-Project-cmm.21 =============== > > Item was added: > + ----- Method: Utilities class>>openCommandKeyHelp (in category '*Help-Squeak-Project-support windows') ----- > + openCommandKeyHelp > + "Open a window giving command key help." > + "Utilities openCommandKeyHelp" > + > + HelpBrowser openOn: SqueakTutorialsCommandKey! As long as this doesn't add any more dependencies, I guess this is OK. I'd like Utilities to die though. These "miscellaneous" buckets of methods serve as breeding grounds for mismanaged dependencies. frank From commits at source.squeak.org Tue Apr 7 21:55:04 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 7 21:55:06 2015 Subject: [squeak-dev] Daily Commit Log Message-ID: <20150407215504.11258.qmail@box4.squeakfoundation.org> Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours: http://lists.squeakfoundation.org/pipermail/packages/2015-April/007829.html Name: ToolBuilder-Kernel-mt.73 Ancestors: ToolBuilder-Kernel-mt.72 Pluggable text spec extended to provide an edit-selector, which gives the model a chance to be notified about *any* edits (not only accepts): ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007830.html Name: ToolBuilder-Morphic-mt.118 Ancestors: ToolBuilder-Morphic-mt.117 Pluggable text spec now passes edit-selector to pluggable text morph. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007831.html Name: Morphic-mt.828 Ancestors: Morphic-mt.827 Pluggable text morph can now notify about any text modification to the model -- not only accepts. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007832.html Name: Morphic-mt.829 Ancestors: Morphic-mt.828 Fixed the search bar to select all of its current contents on activation again (instead of deleting them).. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007833.html Name: Monticello-tfel.609 Ancestors: Monticello-tfel.608, Monticello-cmm.608 add an option to open changes between two different versions in the repository in a patch browser (what the Changes button does, but instead of against the image, do it against another package from the repo) ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007834.html Name: Morphic-tfel.830 Ancestors: Morphic-mt.829 add messages to spy on a selection ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007835.html Name: Tools-tfel.578 Ancestors: Tools-mt.577 add yellow-button menu entry to spy on selection. needs Morphic-tfel.830 ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007836.html Name: EToys-topa.122 Ancestors: EToys-topa.121 Style ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007837.html Name: ToolBuilder-Morphic-mt.119 Ancestors: ToolBuilder-Morphic-mt.118 Made pluggable input fields into real one-liners that scroll horizontally w/o having a scroll bar. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007838.html Name: Morphic-mt.831 Ancestors: Morphic-tfel.830 Fix scroll pane hack so that it does not reset h-offset when hiding the h-scrollbar. Not even the v-scrollbar does this... ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007839.html Name: Morphic-mt.832 Ancestors: Morphic-mt.831 Fixed pluggable text morphs to not scroll more than just its text morphs. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007840.html Name: Morphic-mt.833 Ancestors: Morphic-mt.832 Let the pluggable text morph *only* resize its text morph if autoFit is enabled. This supports real input fields. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007841.html Name: Morphic-mt.834 Ancestors: Morphic-mt.833 Fix scrolling bug in text boxes when the selection was bigger than the text box --- honors the actual text cursor/caret now. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007842.html Name: Morphic-mt.835 Ancestors: Morphic-mt.834 Default search bar width increased to 200 pixel. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007843.html Name: Help-Squeak-Project-topa.22 Ancestors: Help-Squeak-Project-cmm.21 Take responsibility ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007844.html Name: System-topa.718 Ancestors: System-mt.717 Drop dependencies. For Preferences class>>#restorePreferencesFromDisk, we restore the old version, since right away there is no good way to allow old behavior (loading 'my.prefs'), selecting a custom prefs file, AND not depending on tools. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007845.html Name: ToolBuilder-Morphic-mt.120 Ancestors: ToolBuilder-Morphic-mt.119 Remove adornment from one-line inputs. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007846.html Name: Morphic-mt.836 Ancestors: Morphic-mt.835 As a temporary workaround, give text boxes some extra v-range. We will fix that later... ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007847.html Name: Morphic-mt.837 Ancestors: Morphic-mt.836 Hooks added to text editors to send evaluation results to the model instead of invoking some default/hard-coded action. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007848.html Name: Morphic-mt.838 Ancestors: Morphic-mt.837 Search bar now spawns a new (transient) text box (like a balloon morph) to show print-it results, which can be selected and copied and ... ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007849.html Name: Collections-bf.612 Ancestors: Collections-ul.611 Ensure that copyWith/out retains the weak-ness of a weak array. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007850.html Name: Kernel-bf.917 Ancestors: Kernel-topa.916 Fix accidental non-weak arrays in ObsoleteSubclasses values ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007851.html Name: Morphic-topa.839 Ancestors: Morphic-mt.838 IndentingListItemMorph belongs to Morphic ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007852.html Name: Tools-topa.579 Ancestors: Tools-tfel.578 IndentingListItemMorph belongs to Morphic ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007853.html Name: Tests-topa.315 Ancestors: Tests-eem.314 Multilingual no longer depends on TrueType, yay ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007854.html Name: EToys-topa.123 Ancestors: EToys-topa.122 the ifPresent: part needs a block argument ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007855.html Name: CollectionsTests-topa.237 Ancestors: CollectionsTests-ul.236 HackFix: choose a font that actually can be found via a text font reference.. *sigh* ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007856.html Name: Tests-topa.316 Ancestors: Tests-topa.315 If we have nothing to switch to this test must fail ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007857.html Name: Multilingual-topa.203 Ancestors: Multilingual-topa.202 Restore an old expected behavior without introducing a dependency ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007858.html Name: Morphic-mt.840 Ancestors: Morphic-topa.839 Changed postscript to force world main docking bar update. Some other preferences might reset. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007859.html Name: Morphic-mt.841 Ancestors: Morphic-mt.840 Fixed preference "menu request updates selection" to honor model's #okToChange. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007860.html Name: Monticello-mt.610 Ancestors: Monticello-tfel.609 Introduced the possibility to offer one-line input fields in the MC tool builder. Used it in the save-version dialog. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007861.html Name: Tests-topa.317 Ancestors: Tests-topa.316 Behavior toolIconSelector: has a strang push-nil, pop sequence. ============================================= From btc at openinworld.com Wed Apr 8 00:03:08 2015 From: btc at openinworld.com (Ben Coman) Date: Wed Apr 8 00:03:33 2015 Subject: [squeak-dev] Re: Bug whith contextOn:do: In-Reply-To: References: <85F38DF9-1002-49A4-B11B-0DF96E0A7E76@gmx.de> <1AA83643-080E-4CA3-89ED-3C9F9876AFF1@freudenbergs.de> <1E90C927-7C12-4E98-9CFB-96C60D491FCD@gmx.de> <687515E7-90D5-4554-B558-4882B62FB9FA@freudenbergs.de> Message-ID: So this code would never be executed from the timer event loop that runs at priority 80? Recently I tried profiling the timer event loop and the profiler wanted to run at +1 priority and failed. cheers -ben On Wed, Apr 8, 2015 at 12:57 AM, Eliot Miranda wrote: > Hi Bert, > > sorry. Got deep into something and have only just come up for air... > > On Thu, Apr 2, 2015 at 1:02 AM, Bert Freudenberg > wrote: > >> On 01.04.2015, at 20:51, Eliot Miranda wrote: >> >> >>> > I would find it very surprising if #jump would result in the execution >>> continuing in a different process. >>> > >>> > That's not what they do. Instead they spawn another process to >>> position the process in which we want to jump correctly. >>> >>> We don't want to jump to a process but within a process, like a goto? >>> >> >> Well, jump doesn't do unwinds so the code should be simply: >> >> jump >> "Abandon thisContext and resume self instead (using the same current >> process)." >> | process | >> process := Processor activeProcess. >> [process suspendedContext: self] fork. >> Processor yield >> >> >> Ah, I misread what you were proposing before. Simpler is better for >> understanding :) >> >> Assuming there are more runnable processes at the active priority, could >> there be a scenario where the #jump context is resumed after the yield, >> before the forked process had a chance to run? Or would we have to fork it >> at a higher priority? Could either in any way mess with the order of >> process activation, which would not happen with the current #jump >> implementation? >> > > That depends. If the VM is /not/ in the processPreemptionYields regime > (and I need to remember to put Spur images into this regime) then no, doing > the fork at a higher priority cannot disturb processes. But if the process > is forked at the same priority, or if the VM is in the > processPreemptionYields regime, then yes, this can screw up process > priorities. > > So assuming > > Smalltalk processPreemptionYields: false > > then the following is, I think, safe: > > > jump > "Abandon thisContext and resume self instead (using the same current > process)." > | process | > process := Processor activeProcess. > [process suspendedContext: self] forkAt: Processor activePriority + 1 > > of course this fails at max priority. Since we don't use the max priority > we can get away with this. I think that's more acceptable than getting > away with occasionally popping the receiver off a context's stack, no? If > that's not acceptable we need a primitive. > > > >> - Bert - >> >> >> >> >> >> >> > > > -- > best, > Eliot > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150408/f7cfcd0e/attachment-0001.htm From lewis at mail.msen.com Wed Apr 8 01:10:38 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Wed Apr 8 01:10:40 2015 Subject: [squeak-dev] Time primitives In-Reply-To: References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> Message-ID: <20150408011038.GA48704@shell.msen.com> On Tue, Apr 07, 2015 at 11:42:21PM +0200, Levente Uzonyi wrote: > On Tue, 7 Apr 2015, David T. Lewis wrote: > > >I am away and cannot double check the code right now, but the primitives > >should be consistent across Cog and the interpreter VM. There had been > >some confusion due to the early fork between trunk and oscog, but I > >believe that Eliot and I got it sorted out quite a while ago. > > I can confirm this, but the primitives don't work correctly on the > Interpreter VM (4.10.2.2614 on linux from squeakvm.org): > > Time primUTCMicrosecondClock. "==> 2177453298247316" > Time primPosixMicrosecondClockWithOffset. "==> #(519745201 7200)" > DateAndTime now. "==> 2015-04-07T23:30:28.665+01:00" > > The same with CogVM: > > Time primUTCMicrosecondClock. "==> 3605895086935548" > Time primPosixMicrosecondClockWithOffset. "==> #(1428442289746346 7200)" > DateAndTime now. "==> 2015-04-07T23:31:32.962+01:00" > Why do you think this is wrong? I suspect that the one hour time zone offset in your image is not in agreement with the three hour offset that your operating system is reporting. The difference in absolute microseconds is due to different origins in the time scale. Eliot's primitive used the Smalltalk epoch UTC as its origin, and mine used Posix. Neither is wrong. > > > >These are not necessarily set up as numbered primitives, but the > >implementations are there, and they can be called as named primitives in > >Cog/Spur and interpreter VMs. > > > >I don't know about the Pharo fork, it's quite possible that things have > >gotten renamed there. > > The primitives are the same, but the method names in the image are not, > and the latter is what matters for me. It's a pain to keep code running in > both branches. > > > > >Note, the UTC with offset primitive is important to me because of > >UTCDateAndTime (http://wiki.squeak.org/squeak/6197), which is designed > >around the notion of a single primitive answering UTC time and local > >offset as an atomic call to the VM. > > It seems like this primitive caches the time zone offset, which is bad > when there are daylight savings changes (or when the machine goes to a > different time zone). Here's the current value from a long running image: > > Time primPosixMicrosecondClockWithOffset. "==> #(1428442620344927 3600)" > > But the LocalePlugin's primitives seem like they know the truth: > > Locale current primTimezone. "==> 120" > Locale current primDST. "==> true" > If you are suggesting that the handling of time zones in the various images is less than perfect, then I will be the first to agree with you. But I don't think that the primitives are wrong. We have this primitive: InterpreterPrimitives>>primitiveUtcWithOffset "Answer an array with UTC microseconds since the Posix epoch and the current seconds offset from GMT in the local time zone. An empty two element array may be supplied as a parameter. This is a named (not numbered) primitive in the null module (ie the VM)" And the unix platforms sources implement it like this (with ifdefs removed for clarity): sqInt sqUnixUtcWithOffset(sqLong *microSeconds, int *offset) { struct timeval timeval; if (gettimeofday(&timeval, NULL) == -1) return -1; time_t seconds= timeval.tv_sec; suseconds_t usec= timeval.tv_usec; *microSeconds= seconds * 1000000 + usec; *offset= localtime(&seconds)->tm_gmtoff; return 0; } So the operating system is telling you its best estimate of the current time in microseconds since the Posix epoch, as well as the local time zone offset in seconds at the time of the call. This is a single gettimeofday() call to the platform runtime library, which is about as close as we can get to a coherent result on general purpose unix systems. Dave From eliot.miranda at gmail.com Wed Apr 8 01:21:19 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Wed Apr 8 01:21:25 2015 Subject: [squeak-dev] Time primitives In-Reply-To: <20150408011038.GA48704@shell.msen.com> References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> Message-ID: <74030BD0-E235-4C34-9CD3-A87FDC9347E8@gmail.com> Hi David, named primitives have overhead that numbered ones don't. Given the importance if time prims can we not have the Cog numbered prims in the interpreter? Eliot (phone) On Apr 7, 2015, at 6:10 PM, "David T. Lewis" wrote: > On Tue, Apr 07, 2015 at 11:42:21PM +0200, Levente Uzonyi wrote: >> On Tue, 7 Apr 2015, David T. Lewis wrote: >> >>> I am away and cannot double check the code right now, but the primitives >>> should be consistent across Cog and the interpreter VM. There had been >>> some confusion due to the early fork between trunk and oscog, but I >>> believe that Eliot and I got it sorted out quite a while ago. >> >> I can confirm this, but the primitives don't work correctly on the >> Interpreter VM (4.10.2.2614 on linux from squeakvm.org): >> >> Time primUTCMicrosecondClock. "==> 2177453298247316" >> Time primPosixMicrosecondClockWithOffset. "==> #(519745201 7200)" >> DateAndTime now. "==> 2015-04-07T23:30:28.665+01:00" >> >> The same with CogVM: >> >> Time primUTCMicrosecondClock. "==> 3605895086935548" >> Time primPosixMicrosecondClockWithOffset. "==> #(1428442289746346 7200)" >> DateAndTime now. "==> 2015-04-07T23:31:32.962+01:00" > > Why do you think this is wrong? I suspect that the one hour time zone > offset in your image is not in agreement with the three hour offset that > your operating system is reporting. The difference in absolute microseconds > is due to different origins in the time scale. Eliot's primitive used the > Smalltalk epoch UTC as its origin, and mine used Posix. Neither is wrong. > >>> >>> These are not necessarily set up as numbered primitives, but the >>> implementations are there, and they can be called as named primitives in >>> Cog/Spur and interpreter VMs. >>> >>> I don't know about the Pharo fork, it's quite possible that things have >>> gotten renamed there. >> >> The primitives are the same, but the method names in the image are not, >> and the latter is what matters for me. It's a pain to keep code running in >> both branches. >> >>> >>> Note, the UTC with offset primitive is important to me because of >>> UTCDateAndTime (http://wiki.squeak.org/squeak/6197), which is designed >>> around the notion of a single primitive answering UTC time and local >>> offset as an atomic call to the VM. >> >> It seems like this primitive caches the time zone offset, which is bad >> when there are daylight savings changes (or when the machine goes to a >> different time zone). Here's the current value from a long running image: >> >> Time primPosixMicrosecondClockWithOffset. "==> #(1428442620344927 3600)" >> >> But the LocalePlugin's primitives seem like they know the truth: >> >> Locale current primTimezone. "==> 120" >> Locale current primDST. "==> true" > > If you are suggesting that the handling of time zones in the various images > is less than perfect, then I will be the first to agree with you. But I don't > think that the primitives are wrong. > > We have this primitive: > > InterpreterPrimitives>>primitiveUtcWithOffset > "Answer an array with UTC microseconds since the Posix epoch and > the current seconds offset from GMT in the local time zone. An empty > two element array may be supplied as a parameter. > This is a named (not numbered) primitive in the null module (ie the VM)" > > And the unix platforms sources implement it like this (with ifdefs removed > for clarity): > > sqInt sqUnixUtcWithOffset(sqLong *microSeconds, int *offset) > { > struct timeval timeval; > if (gettimeofday(&timeval, NULL) == -1) return -1; > time_t seconds= timeval.tv_sec; > suseconds_t usec= timeval.tv_usec; > *microSeconds= seconds * 1000000 + usec; > *offset= localtime(&seconds)->tm_gmtoff; > return 0; > } > > So the operating system is telling you its best estimate of the current time > in microseconds since the Posix epoch, as well as the local time zone offset > in seconds at the time of the call. This is a single gettimeofday() call to > the platform runtime library, which is about as close as we can get to a > coherent result on general purpose unix systems. > > Dave > > From tim at rowledge.org Wed Apr 8 01:30:36 2015 From: tim at rowledge.org (tim Rowledge) Date: Wed Apr 8 01:30:40 2015 Subject: [squeak-dev] Time primitives In-Reply-To: <74030BD0-E235-4C34-9CD3-A87FDC9347E8@gmail.com> References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> <74030BD0-E235-4C34-9CD3-A87FDC9347E8@gmail.com> Message-ID: <84C7219B-4A8D-41E3-A4D1-47297BC12D37@rowledge.org> On 07-04-2015, at 6:21 PM, Eliot Miranda wrote: > named primitives have overhead that numbered ones don't. I *thought* I?d fixed that back around ?04 by caching the actual address ? Always possible I didn?t get it right, of course. I do seem to remember some pretty good performance improvements as a result of the changes. tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim Strange OpCodes: FA: Failsafe Armed From asqueaker at gmail.com Wed Apr 8 01:43:38 2015 From: asqueaker at gmail.com (Chris Muller) Date: Wed Apr 8 01:43:41 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.838.mcz In-Reply-To: <1428407223771-4818009.post@n4.nabble.com> References: <1428407223771-4818009.post@n4.nabble.com> Message-ID: Really great! It's clear we have a Morphic wizard in our midst. Now we can not only search but do Straight-Airs and Inverted-Hand-Plants off the "Search" bar again.. :) Well done, thank you. On Tue, Apr 7, 2015 at 6:47 AM, Marcel Taeumel wrote: > > > Best, > Marcel > > > > -- > View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-838-mcz-tp4818005p4818009.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > From lewis at mail.msen.com Wed Apr 8 01:51:13 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Wed Apr 8 01:51:15 2015 Subject: [squeak-dev] Time primitives In-Reply-To: <74030BD0-E235-4C34-9CD3-A87FDC9347E8@gmail.com> References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> <74030BD0-E235-4C34-9CD3-A87FDC9347E8@gmail.com> Message-ID: <20150408015113.GA60584@shell.msen.com> Hi Eliot, In trunk Interpreter>>initializePrimitiveTable we currently have: (240 primitiveUTCMicrosecondClock) "was serial port primitive" (241 primitiveLocalMicrosecondClock) "was serial port primitive" I think these are the primitives that you wanted to have numbered. Please let me know if I missed some others. Note - I have never suggested adding #primitiveUtcWithOffset because I cannot see any performance impact beyond the initial symbol lookups, so I'm quite happy to leave it as a named primitive. Dave On Tue, Apr 07, 2015 at 06:21:19PM -0700, Eliot Miranda wrote: > Hi David, > > named primitives have overhead that numbered ones don't. Given the importance if time prims can we not have the Cog numbered prims in the interpreter? > > Eliot (phone) > > On Apr 7, 2015, at 6:10 PM, "David T. Lewis" wrote: > > > On Tue, Apr 07, 2015 at 11:42:21PM +0200, Levente Uzonyi wrote: > >> On Tue, 7 Apr 2015, David T. Lewis wrote: > >> > >>> I am away and cannot double check the code right now, but the primitives > >>> should be consistent across Cog and the interpreter VM. There had been > >>> some confusion due to the early fork between trunk and oscog, but I > >>> believe that Eliot and I got it sorted out quite a while ago. > >> > >> I can confirm this, but the primitives don't work correctly on the > >> Interpreter VM (4.10.2.2614 on linux from squeakvm.org): > >> > >> Time primUTCMicrosecondClock. "==> 2177453298247316" > >> Time primPosixMicrosecondClockWithOffset. "==> #(519745201 7200)" > >> DateAndTime now. "==> 2015-04-07T23:30:28.665+01:00" > >> > >> The same with CogVM: > >> > >> Time primUTCMicrosecondClock. "==> 3605895086935548" > >> Time primPosixMicrosecondClockWithOffset. "==> #(1428442289746346 7200)" > >> DateAndTime now. "==> 2015-04-07T23:31:32.962+01:00" > > > > Why do you think this is wrong? I suspect that the one hour time zone > > offset in your image is not in agreement with the three hour offset that > > your operating system is reporting. The difference in absolute microseconds > > is due to different origins in the time scale. Eliot's primitive used the > > Smalltalk epoch UTC as its origin, and mine used Posix. Neither is wrong. > > > >>> > >>> These are not necessarily set up as numbered primitives, but the > >>> implementations are there, and they can be called as named primitives in > >>> Cog/Spur and interpreter VMs. > >>> > >>> I don't know about the Pharo fork, it's quite possible that things have > >>> gotten renamed there. > >> > >> The primitives are the same, but the method names in the image are not, > >> and the latter is what matters for me. It's a pain to keep code running in > >> both branches. > >> > >>> > >>> Note, the UTC with offset primitive is important to me because of > >>> UTCDateAndTime (http://wiki.squeak.org/squeak/6197), which is designed > >>> around the notion of a single primitive answering UTC time and local > >>> offset as an atomic call to the VM. > >> > >> It seems like this primitive caches the time zone offset, which is bad > >> when there are daylight savings changes (or when the machine goes to a > >> different time zone). Here's the current value from a long running image: > >> > >> Time primPosixMicrosecondClockWithOffset. "==> #(1428442620344927 3600)" > >> > >> But the LocalePlugin's primitives seem like they know the truth: > >> > >> Locale current primTimezone. "==> 120" > >> Locale current primDST. "==> true" > > > > If you are suggesting that the handling of time zones in the various images > > is less than perfect, then I will be the first to agree with you. But I don't > > think that the primitives are wrong. > > > > We have this primitive: > > > > InterpreterPrimitives>>primitiveUtcWithOffset > > "Answer an array with UTC microseconds since the Posix epoch and > > the current seconds offset from GMT in the local time zone. An empty > > two element array may be supplied as a parameter. > > This is a named (not numbered) primitive in the null module (ie the VM)" > > > > And the unix platforms sources implement it like this (with ifdefs removed > > for clarity): > > > > sqInt sqUnixUtcWithOffset(sqLong *microSeconds, int *offset) > > { > > struct timeval timeval; > > if (gettimeofday(&timeval, NULL) == -1) return -1; > > time_t seconds= timeval.tv_sec; > > suseconds_t usec= timeval.tv_usec; > > *microSeconds= seconds * 1000000 + usec; > > *offset= localtime(&seconds)->tm_gmtoff; > > return 0; > > } > > > > So the operating system is telling you its best estimate of the current time > > in microseconds since the Posix epoch, as well as the local time zone offset > > in seconds at the time of the call. This is a single gettimeofday() call to > > the platform runtime library, which is about as close as we can get to a > > coherent result on general purpose unix systems. > > > > Dave > > > > From lewis at mail.msen.com Wed Apr 8 02:08:05 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Wed Apr 8 02:08:07 2015 Subject: [squeak-dev] Time primitivesjkr In-Reply-To: <84C7219B-4A8D-41E3-A4D1-47297BC12D37@rowledge.org> References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> <74030BD0-E235-4C34-9CD3-A87FDC9347E8@gmail.com> <84C7219B-4A8D-41E3-A4D1-47297BC12D37@rowledge.org> Message-ID: <20150408020805.GB60584@shell.msen.com> On Tue, Apr 07, 2015 at 06:30:36PM -0700, tim Rowledge wrote: > > On 07-04-2015, at 6:21 PM, Eliot Miranda wrote: > > named primitives have overhead that numbered ones don't. > > I *thought* I?d fixed that back around ?04 by caching the actual address ? Always possible I didn?t get it right, of course. I do seem to remember some pretty good performance improvements as a result of the changes. > Tim, As far as I can tell, your fixes work fine and there is essentially no performance difference between named and numbered primitives once the function address has been loaded. So for a frequently used primitive, there is no difference at all. I am using UTCDateAndTime in my working images, so #primitiveUtcWithOffset is used heavily as a named primitive. Overall this much faster (and better in various other ways) than the standard Squeak Chronology implemention. I have not actually tried running it with a numbered primitive, but I see no reason to think that we would get additional performance out of adding #primitiveUtcWithOffset to the primitive table. My working assumption is that numbered primitives should be defined only for the absolutely essential primitives needed to bootstrap on a new platform, and that everything else should be a named primitive. Dave From tim at rowledge.org Wed Apr 8 02:12:41 2015 From: tim at rowledge.org (tim Rowledge) Date: Wed Apr 8 02:12:49 2015 Subject: [squeak-dev] Time primitivesjkr In-Reply-To: <20150408020805.GB60584@shell.msen.com> References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> <74030BD0-E235-4C34-9CD3-A87FDC9347E8@gmail.com> <84C7219B-4A8D-41E3-A4D1-47297BC12D37@rowledge.org> <20150408020805.GB60584@shell.msen.com> Message-ID: On 07-04-2015, at 7:08 PM, David T. Lewis wrote: > As far as I can tell, your fixes work fine and there is essentially no performance > difference between named and numbered primitives once the function address has > been loaded. So for a frequently used primitive, there is no difference at all. Good; that was the intention! > > > My working assumption is that numbered primitives should be defined only for > the absolutely essential primitives needed to bootstrap on a new platform, > and that everything else should be a named primitive. I?m for that. I?ve occasionally stared meaningfully off into the distance musing about how one might have no numbered prims at all. Usually, falling over ends the recursion I get stuck in. tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim granary - old folks home From asqueaker at gmail.com Wed Apr 8 02:45:22 2015 From: asqueaker at gmail.com (Chris Muller) Date: Wed Apr 8 02:45:26 2015 Subject: [squeak-dev] The Trunk: Collections-bf.612.mcz In-Reply-To: <5523c7d5.162b370a.573d.5b8aSMTPIN_ADDED_MISSING@mx.google.com> References: <5523c7d5.162b370a.573d.5b8aSMTPIN_ADDED_MISSING@mx.google.com> Message-ID: The change to override #species may not have gotten enough scrutiny. It was a mere mention by Eliot in a prior thread, which I captured into Collections-cmm.603. It may be worth some additional peer scrutiny. It feels right on the surface but could such a change cause negative impacts elsewhere? On Tue, Apr 7, 2015 at 7:04 AM, wrote: > Tobias Pape uploaded a new version of Collections to project The Trunk: > http://source.squeak.org/trunk/Collections-bf.612.mcz > > ==================== Summary ==================== > > Name: Collections-bf.612 > Author: bf > Time: 7 April 2015, 2:04:06.99 pm > UUID: 1b9e2fc6-03fb-41c2-a3e8-197fa24c108a > Ancestors: Collections-ul.611 > > Ensure that copyWith/out retains the weak-ness of a weak array. > > =============== Diff against Collections-ul.611 =============== > > Item was added: > + ----- Method: WeakArray>>copyWith: (in category 'copying') ----- > + copyWith: newElement > + "Re-implemented to not return a strong copy." > + ^ (super copyWith: newElement) as: self class! > > Item was added: > + ----- Method: WeakArray>>copyWithout: (in category 'copying') ----- > + copyWithout: oldElement > + "Re-implemented to not return a strong copy." > + ^ (super copyWithout: oldElement) as: self class! > > Item was changed: > + ----- Method: WeakArray>>species (in category 'private') ----- > - ----- Method: WeakArray>>species (in category 'as yet unclassified') ----- > species > "More useful to have strongly-referenced results of #select: and #collect:." > ^ Array! > > From sean at clipperadams.com Wed Apr 8 03:18:07 2015 From: sean at clipperadams.com (Sean P. DeNigris) Date: Wed Apr 8 03:30:34 2015 Subject: [squeak-dev] Re: Ometa vs XTreams PEG, PetitParser, Helvetia In-Reply-To: <86pqp72l4v.fsf@red.stonehenge.com> References: <579A0D9D-8970-4511-9DF2-B3FD5B0CF202@gmail.com> <86pqp72l4v.fsf@red.stonehenge.com> Message-ID: <1428463087280-4818261.post@n4.nabble.com> Randal L. Schwartz wrote > Casey> OMeta is ridiculously cool. You can do source to source > Casey> translation in some cases, for example, without a pretty printer > Casey> by running your grammar transformations through backward. I'm not > Casey> aware of any other system that let's you do that. > > Except maybe XTreams PEG. :) Are there any examples of that, by chance? ----- Cheers, Sean -- View this message in context: http://forum.world.st/Re-Ometa-vs-XTreams-PEG-PetitParser-Helvetia-tp3418056p4818261.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From brasspen at gmail.com Wed Apr 8 04:11:37 2015 From: brasspen at gmail.com (Chris Cunnington) Date: Wed Apr 8 04:11:42 2015 Subject: [squeak-dev] Re: Ometa vs XTreams PEG, PetitParser, Helvetia In-Reply-To: <1428463087280-4818261.post@n4.nabble.com> References: <579A0D9D-8970-4511-9DF2-B3FD5B0CF202@gmail.com> <86pqp72l4v.fsf@red.stonehenge.com> <1428463087280-4818261.post@n4.nabble.com> Message-ID: > On Apr 7, 2015, at 11:18 PM, Sean P. DeNigris wrote: > > Randal L. Schwartz wrote >> Casey> OMeta is ridiculously cool. You can do source to source >> Casey> translation in some cases, for example, without a pretty printer >> Casey> by running your grammar transformations through backward. I'm not >> Casey> aware of any other system that let's you do that. >> >> Except maybe XTreams PEG. :) > > Are there any examples of that, by chance? If you look in the docs [1] you?ll start to look for subclasses of XTActor/PEG.Actor such as PEG.WikiGenerator. They are not present in Squeak or Pharo because Nicolas Cellier did not port them over. I think it was because they were plugged into other packages such as XML.Element, So the answer to your question is no. The way to find classes like WikiGenerator is to install Cincom?s VisualWorks (on a Mac for example) and include the Streams-Parsing-Tests package. Then adapt to Squeak/Pharo. Chapter 3, p. 100, footnote 9 of ?Squeak Personal Computing and Multimedia? mentions a ?Squeak demo for blowing students minds.? That?s a label Mark used for presenting the contents of a lecture he gave to students. It?s reasonable to assume that whatever was the balance of that presentation is material you?ve already been exposed to by reading Mark?s book. However, if you order the book from amazon.coom, it comes with a rich CD-ROM assembled by Stephen T. Pope with content I would expect would blow your mind. Chris [1] https://code.google.com/p/xtreams/wiki/Parsing > ----- > Cheers, > Sean > -- > View this message in context: http://forum.world.st/Re-Ometa-vs-XTreams-PEG-PetitParser-Helvetia-tp3418056p4818261.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150408/a69ffaa2/attachment.htm From Das.Linux at gmx.de Wed Apr 8 07:28:42 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Wed Apr 8 07:28:46 2015 Subject: [squeak-dev] The Trunk: Collections-bf.612.mcz In-Reply-To: References: <5523c7d5.162b370a.573d.5b8aSMTPIN_ADDED_MISSING@mx.google.com> Message-ID: <45D5DBCB-DFE3-45F8-8E15-8C010FF3C835@gmx.de> On 08.04.2015, at 04:45, Chris Muller wrote: > The change to override #species may not have gotten enough scrutiny. > It was a mere mention by Eliot in a prior thread, which I captured > into Collections-cmm.603. It may be worth some additional peer > scrutiny. It feels right on the surface but could such a change cause > negative impacts elsewhere? Always. I sat there with Bert and we tried to debug why obsoletes never got cleaned up and it turned out to be due to copyWith/without relying on species which now gives a strong class. We understood that the collection protocol might find it useful to have a strong copy of a weak collection. We really need to find out which part of the protocol has to stay weak or go strong :) Best -Tobais > > > On Tue, Apr 7, 2015 at 7:04 AM, wrote: >> Tobias Pape uploaded a new version of Collections to project The Trunk: >> http://source.squeak.org/trunk/Collections-bf.612.mcz >> >> ==================== Summary ==================== >> >> Name: Collections-bf.612 >> Author: bf >> Time: 7 April 2015, 2:04:06.99 pm >> UUID: 1b9e2fc6-03fb-41c2-a3e8-197fa24c108a >> Ancestors: Collections-ul.611 >> >> Ensure that copyWith/out retains the weak-ness of a weak array. >> >> =============== Diff against Collections-ul.611 =============== >> >> Item was added: >> + ----- Method: WeakArray>>copyWith: (in category 'copying') ----- >> + copyWith: newElement >> + "Re-implemented to not return a strong copy." >> + ^ (super copyWith: newElement) as: self class! >> >> Item was added: >> + ----- Method: WeakArray>>copyWithout: (in category 'copying') ----- >> + copyWithout: oldElement >> + "Re-implemented to not return a strong copy." >> + ^ (super copyWithout: oldElement) as: self class! >> >> Item was changed: >> + ----- Method: WeakArray>>species (in category 'private') ----- >> - ----- Method: WeakArray>>species (in category 'as yet unclassified') ----- >> species >> "More useful to have strongly-referenced results of #select: and #collect:." >> ^ Array! From eliot.miranda at gmail.com Wed Apr 8 07:47:25 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Wed Apr 8 07:47:31 2015 Subject: [squeak-dev] Time primitives In-Reply-To: <84C7219B-4A8D-41E3-A4D1-47297BC12D37@rowledge.org> References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> <74030BD0-E235-4C34-9CD3-A87FDC9347E8@gmail.com> <84C7219B-4A8D-41E3-A4D1-47297BC12D37@rowledge.org> Message-ID: <334076D0-99CE-4312-92A5-A9764AEEC424@gmail.com> Tim, that fix is fine as far as it goes. I'm talking about the Cogit's assumption that named primitives may call back imply that there is overhead in jitted code. You remember the sideways call that's necessary? I want the numbered prim for that. Eliot (phone) On Apr 7, 2015, at 6:30 PM, tim Rowledge wrote: > > On 07-04-2015, at 6:21 PM, Eliot Miranda wrote: >> named primitives have overhead that numbered ones don't. > > I *thought* I?d fixed that back around ?04 by caching the actual address ? Always possible I didn?t get it right, of course. I do seem to remember some pretty good performance improvements as a result of the changes. > > tim > -- > tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim > Strange OpCodes: FA: Failsafe Armed > > > From eliot.miranda at gmail.com Wed Apr 8 07:48:46 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Wed Apr 8 07:48:52 2015 Subject: [squeak-dev] Time primitives In-Reply-To: <20150408015113.GA60584@shell.msen.com> References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> <74030BD0-E235-4C34-9CD3-A87FDC9347E8@gmail.com> <20150408015113.GA60584@shell.msen.com> Message-ID: <80AA3494-4EA1-49B8-B857-BDB3A0E60CD6@gmail.com> Hi David, that's great. That's what I want to see. Thx! Eliot (phone) On Apr 7, 2015, at 6:51 PM, "David T. Lewis" wrote: > Hi Eliot, > > In trunk Interpreter>>initializePrimitiveTable we currently have: > > (240 primitiveUTCMicrosecondClock) "was serial port primitive" > (241 primitiveLocalMicrosecondClock) "was serial port primitive" > > I think these are the primitives that you wanted to have numbered. Please > let me know if I missed some others. > > Note - I have never suggested adding #primitiveUtcWithOffset because I cannot > see any performance impact beyond the initial symbol lookups, so I'm quite > happy to leave it as a named primitive. > > Dave > > On Tue, Apr 07, 2015 at 06:21:19PM -0700, Eliot Miranda wrote: >> Hi David, >> >> named primitives have overhead that numbered ones don't. Given the importance if time prims can we not have the Cog numbered prims in the interpreter? >> >> Eliot (phone) >> >> On Apr 7, 2015, at 6:10 PM, "David T. Lewis" wrote: >> >>> On Tue, Apr 07, 2015 at 11:42:21PM +0200, Levente Uzonyi wrote: >>>> On Tue, 7 Apr 2015, David T. Lewis wrote: >>>> >>>>> I am away and cannot double check the code right now, but the primitives >>>>> should be consistent across Cog and the interpreter VM. There had been >>>>> some confusion due to the early fork between trunk and oscog, but I >>>>> believe that Eliot and I got it sorted out quite a while ago. >>>> >>>> I can confirm this, but the primitives don't work correctly on the >>>> Interpreter VM (4.10.2.2614 on linux from squeakvm.org): >>>> >>>> Time primUTCMicrosecondClock. "==> 2177453298247316" >>>> Time primPosixMicrosecondClockWithOffset. "==> #(519745201 7200)" >>>> DateAndTime now. "==> 2015-04-07T23:30:28.665+01:00" >>>> >>>> The same with CogVM: >>>> >>>> Time primUTCMicrosecondClock. "==> 3605895086935548" >>>> Time primPosixMicrosecondClockWithOffset. "==> #(1428442289746346 7200)" >>>> DateAndTime now. "==> 2015-04-07T23:31:32.962+01:00" >>> >>> Why do you think this is wrong? I suspect that the one hour time zone >>> offset in your image is not in agreement with the three hour offset that >>> your operating system is reporting. The difference in absolute microseconds >>> is due to different origins in the time scale. Eliot's primitive used the >>> Smalltalk epoch UTC as its origin, and mine used Posix. Neither is wrong. >>> >>>>> >>>>> These are not necessarily set up as numbered primitives, but the >>>>> implementations are there, and they can be called as named primitives in >>>>> Cog/Spur and interpreter VMs. >>>>> >>>>> I don't know about the Pharo fork, it's quite possible that things have >>>>> gotten renamed there. >>>> >>>> The primitives are the same, but the method names in the image are not, >>>> and the latter is what matters for me. It's a pain to keep code running in >>>> both branches. >>>> >>>>> >>>>> Note, the UTC with offset primitive is important to me because of >>>>> UTCDateAndTime (http://wiki.squeak.org/squeak/6197), which is designed >>>>> around the notion of a single primitive answering UTC time and local >>>>> offset as an atomic call to the VM. >>>> >>>> It seems like this primitive caches the time zone offset, which is bad >>>> when there are daylight savings changes (or when the machine goes to a >>>> different time zone). Here's the current value from a long running image: >>>> >>>> Time primPosixMicrosecondClockWithOffset. "==> #(1428442620344927 3600)" >>>> >>>> But the LocalePlugin's primitives seem like they know the truth: >>>> >>>> Locale current primTimezone. "==> 120" >>>> Locale current primDST. "==> true" >>> >>> If you are suggesting that the handling of time zones in the various images >>> is less than perfect, then I will be the first to agree with you. But I don't >>> think that the primitives are wrong. >>> >>> We have this primitive: >>> >>> InterpreterPrimitives>>primitiveUtcWithOffset >>> "Answer an array with UTC microseconds since the Posix epoch and >>> the current seconds offset from GMT in the local time zone. An empty >>> two element array may be supplied as a parameter. >>> This is a named (not numbered) primitive in the null module (ie the VM)" >>> >>> And the unix platforms sources implement it like this (with ifdefs removed >>> for clarity): >>> >>> sqInt sqUnixUtcWithOffset(sqLong *microSeconds, int *offset) >>> { >>> struct timeval timeval; >>> if (gettimeofday(&timeval, NULL) == -1) return -1; >>> time_t seconds= timeval.tv_sec; >>> suseconds_t usec= timeval.tv_usec; >>> *microSeconds= seconds * 1000000 + usec; >>> *offset= localtime(&seconds)->tm_gmtoff; >>> return 0; >>> } >>> >>> So the operating system is telling you its best estimate of the current time >>> in microseconds since the Posix epoch, as well as the local time zone offset >>> in seconds at the time of the call. This is a single gettimeofday() call to >>> the platform runtime library, which is about as close as we can get to a >>> coherent result on general purpose unix systems. >>> >>> Dave > From eliot.miranda at gmail.com Wed Apr 8 07:56:53 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Wed Apr 8 07:56:57 2015 Subject: [squeak-dev] The Trunk: EToys-topa.123.mcz In-Reply-To: References: Message-ID: <176850F4-FC78-4F9E-9A70-1C585194F146@gmail.com> Hi Tobias, hasClassNamed: and symbols are to be preferred to avoid the cost of interning. The class name keys are, as they should be, symbols, and we don't want to pay the cost of interning to do that lookup. And I agree with Levente that symbols are searched for when SystemNavigation is used to find such soft class references. Your string position is understandable but needlessly expensive. The use of symbols (and the assumption that they're strings) is simple and efficient. Eliot (phone) On Apr 7, 2015, at 8:21 AM, Tobias Pape wrote: > > On 07.04.2015, at 17:16, Levente Uzonyi wrote: > >> What's wrong with #hasClassNamed:? > > From my POV, it takes a String, and we wanted a symbol here ;) > Also, I wanted t be conisten with #setUP > >> >> Levente >> >> On Tue, 7 Apr 2015, commits@source.squeak.org wrote: >> >>> Tobias Pape uploaded a new version of EToys to project The Trunk: >>> http://source.squeak.org/trunk/EToys-topa.123.mcz >>> >>> ==================== Summary ==================== >>> >>> Name: EToys-topa.123 >>> Author: topa >>> Time: 7 April 2015, 2:37:32.593 pm >>> UUID: 71b565ae-57ad-4d33-91d2-d6bfeec75490 >>> Ancestors: EToys-topa.122 >>> >>> the ifPresent: part needs a block argument >>> >>> =============== Diff against EToys-topa.122 =============== >>> >>> Item was changed: >>> ----- Method: TileMorphTest>>expectedFailures (in category 'testing') ----- >>> expectedFailures >>> >>> ^ super expectedFailures, >>> (self class environment >>> at: #BaseSoundSystem >>> + ifPresent: [:e| #()] >>> - ifPresent: [#()] >>> ifAbsent: [#(testSoundTile) "Only this test depends on Sound"])! > > > From Das.Linux at gmx.de Wed Apr 8 08:09:09 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Wed Apr 8 08:09:11 2015 Subject: [squeak-dev] The Trunk: EToys-topa.123.mcz In-Reply-To: <176850F4-FC78-4F9E-9A70-1C585194F146@gmail.com> References: <176850F4-FC78-4F9E-9A70-1C585194F146@gmail.com> Message-ID: Hi Eliot On 08.04.2015, at 09:56, Eliot Miranda wrote: > Hi Tobias, > > hasClassNamed: and symbols are to be preferred to avoid the cost of interning. I don't quite understand that. When I use a symbol, it already has been interned, either during method-compilation or because I created it. How is interning avoided here? I thought this was the very reason to not pass a Symbol to hasClassNamed? What about its sibling classNamed: (or classOrTraitNamed:)? > The class name keys are, as they should be, symbols, and we don't want to pay the cost of interning to do that lookup. And I agree with Levente that symbols are searched for when SystemNavigation is used to find such soft class references. Right, I did not argue against that :) > Your string position is understandable but needlessly expensive. The use of symbols (and the assumption that they're strings) is simple and efficient. Don't get me wrong, I think that this assumption is worthwhile in (at least) Core Squeak, yes. Best -Tobias :) > > Eliot (phone) > > On Apr 7, 2015, at 8:21 AM, Tobias Pape wrote: > >> >> On 07.04.2015, at 17:16, Levente Uzonyi wrote: >> >>> What's wrong with #hasClassNamed:? >> >> From my POV, it takes a String, and we wanted a symbol here ;) >> Also, I wanted t be conisten with #setUP >> >>> >>> Levente >>> >>> On Tue, 7 Apr 2015, commits@source.squeak.org wrote: >>> >>>> Tobias Pape uploaded a new version of EToys to project The Trunk: >>>> http://source.squeak.org/trunk/EToys-topa.123.mcz >>>> >>>> ==================== Summary ==================== >>>> >>>> Name: EToys-topa.123 >>>> Author: topa >>>> Time: 7 April 2015, 2:37:32.593 pm >>>> UUID: 71b565ae-57ad-4d33-91d2-d6bfeec75490 >>>> Ancestors: EToys-topa.122 >>>> >>>> the ifPresent: part needs a block argument >>>> >>>> =============== Diff against EToys-topa.122 =============== >>>> >>>> Item was changed: >>>> ----- Method: TileMorphTest>>expectedFailures (in category 'testing') ----- >>>> expectedFailures >>>> >>>> ^ super expectedFailures, >>>> (self class environment >>>> at: #BaseSoundSystem >>>> + ifPresent: [:e| #()] >>>> - ifPresent: [#()] >>>> ifAbsent: [#(testSoundTile) "Only this test depends on Sound"])! From leves at elte.hu Wed Apr 8 08:33:45 2015 From: leves at elte.hu (Levente Uzonyi) Date: Wed Apr 8 08:33:49 2015 Subject: [squeak-dev] Time primitives In-Reply-To: <20150408011038.GA48704@shell.msen.com> References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> Message-ID: On Tue, 7 Apr 2015, David T. Lewis wrote: > On Tue, Apr 07, 2015 at 11:42:21PM +0200, Levente Uzonyi wrote: >> On Tue, 7 Apr 2015, David T. Lewis wrote: >> >>> I am away and cannot double check the code right now, but the primitives >>> should be consistent across Cog and the interpreter VM. There had been >>> some confusion due to the early fork between trunk and oscog, but I >>> believe that Eliot and I got it sorted out quite a while ago. >> >> I can confirm this, but the primitives don't work correctly on the >> Interpreter VM (4.10.2.2614 on linux from squeakvm.org): >> >> Time primUTCMicrosecondClock. "==> 2177453298247316" >> Time primPosixMicrosecondClockWithOffset. "==> #(519745201 7200)" >> DateAndTime now. "==> 2015-04-07T23:30:28.665+01:00" >> >> The same with CogVM: >> >> Time primUTCMicrosecondClock. "==> 3605895086935548" >> Time primPosixMicrosecondClockWithOffset. "==> #(1428442289746346 7200)" >> DateAndTime now. "==> 2015-04-07T23:31:32.962+01:00" >> > > Why do you think this is wrong? I suspect that the one hour time zone Let me reorder the lines to show the actual problems: Time primUTCMicrosecondClock. "==> 2177453298247316" Time primUTCMicrosecondClock. "==> 3605895086935548" The value from the Interpreter VM (first line) is significantly smaller than the value from Cog. The former can't be right. Time primPosixMicrosecondClockWithOffset. "==> #(519745201 7200)" Time primPosixMicrosecondClockWithOffset. "==> #(1428442289746346 7200)" Same here. The microseconds value from the Interpreter VM (first line) is way smaller than what it should be. DateAndTime now. "==> 2015-04-07T23:30:28.665+01:00" DateAndTime now. "==> 2015-04-07T23:31:32.962+01:00" Both values are in the CET(+1) time zone, but the actual time zone is CEST(+2). Both images were started in CEST. > offset in your image is not in agreement with the three hour offset that > your operating system is reporting. The difference in absolute microseconds > is due to different origins in the time scale. Eliot's primitive used the > Smalltalk epoch UTC as its origin, and mine used Posix. Neither is wrong. > >>> >>> These are not necessarily set up as numbered primitives, but the >>> implementations are there, and they can be called as named primitives in >>> Cog/Spur and interpreter VMs. >>> >>> I don't know about the Pharo fork, it's quite possible that things have >>> gotten renamed there. >> >> The primitives are the same, but the method names in the image are not, >> and the latter is what matters for me. It's a pain to keep code running in >> both branches. >> >>> >>> Note, the UTC with offset primitive is important to me because of >>> UTCDateAndTime (http://wiki.squeak.org/squeak/6197), which is designed >>> around the notion of a single primitive answering UTC time and local >>> offset as an atomic call to the VM. >> >> It seems like this primitive caches the time zone offset, which is bad >> when there are daylight savings changes (or when the machine goes to a >> different time zone). Here's the current value from a long running image: >> >> Time primPosixMicrosecondClockWithOffset. "==> #(1428442620344927 3600)" >> >> But the LocalePlugin's primitives seem like they know the truth: >> >> Locale current primTimezone. "==> 120" >> Locale current primDST. "==> true" >> > > If you are suggesting that the handling of time zones in the various images > is less than perfect, then I will be the first to agree with you. But I don't > think that the primitives are wrong. > > We have this primitive: > > InterpreterPrimitives>>primitiveUtcWithOffset > "Answer an array with UTC microseconds since the Posix epoch and > the current seconds offset from GMT in the local time zone. An empty > two element array may be supplied as a parameter. > This is a named (not numbered) primitive in the null module (ie the VM)" > > And the unix platforms sources implement it like this (with ifdefs removed > for clarity): > > sqInt sqUnixUtcWithOffset(sqLong *microSeconds, int *offset) > { > struct timeval timeval; > if (gettimeofday(&timeval, NULL) == -1) return -1; > time_t seconds= timeval.tv_sec; > suseconds_t usec= timeval.tv_usec; > *microSeconds= seconds * 1000000 + usec; > *offset= localtime(&seconds)->tm_gmtoff; > return 0; > } > > So the operating system is telling you its best estimate of the current time > in microseconds since the Posix epoch, as well as the local time zone offset > in seconds at the time of the call. This is a single gettimeofday() call to > the platform runtime library, which is about as close as we can get to a > coherent result on general purpose unix systems. I'm telling that the LocalePlugin can find out the correct time zone in case of DST changes, but it seems like gettimeofday() can't. Levente > > Dave > > > From bert at freudenbergs.de Wed Apr 8 08:44:49 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Wed Apr 8 08:44:52 2015 Subject: [squeak-dev] Class names, Symbols, and Strings (was: The Trunk: EToys-topa.123.mcz) In-Reply-To: References: <176850F4-FC78-4F9E-9A70-1C585194F146@gmail.com> Message-ID: On 08.04.2015, at 10:09, Tobias Pape wrote: > > Hi Eliot > > On 08.04.2015, at 09:56, Eliot Miranda wrote: > >> Hi Tobias, >> >> hasClassNamed: and symbols are to be preferred to avoid the cost of interning. > > I don't quite understand that. When I use a symbol, it already has been interned, > either during method-compilation or because I created it. How is interning avoided here? > I thought this was the very reason to not pass a Symbol to hasClassNamed? My reason for preferring a Symbol over a String is to avoid paying the storage space twice. With a Symbol, the literal will be shared. > What about its sibling classNamed: (or classOrTraitNamed:)? That implementation uses asSymbol anyway, so it's actually preferable to pass a Symbol. - Bert - PS: Meaningful Subjects Are A Good Idea? -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150408/6b30a423/smime.bin From bert at freudenbergs.de Wed Apr 8 08:56:13 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Wed Apr 8 08:56:15 2015 Subject: [squeak-dev] Time primitives In-Reply-To: References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> Message-ID: <7A458A46-A615-4517-B7D5-6C79FCEA4A0F@freudenbergs.de> On 08.04.2015, at 10:33, Levente Uzonyi wrote: > > DateAndTime now. "==> 2015-04-07T23:30:28.665+01:00" > DateAndTime now. "==> 2015-04-07T23:31:32.962+01:00" > > Both values are in the CET(+1) time zone, but the actual time zone is CEST(+2). Both images were started in CEST. Interesting. In an Etoys image on an Interpreter on Mac OS I get the right time zone: DateAndTime now ==>2015-04-08T10:49:33+02:00 That one uses LocalePlugin. Trunk image on Cog: DateAndTime now ==> 2015-04-08T10:48:38.991+01:00 > I'm telling that the LocalePlugin can find out the correct time zone in case of DST changes, but it seems like gettimeofday() can't. In Trunk, #useLocale is disabled (enabled in Etoys). Are we seriously all using +01:00 times, and still expecting users to set the right time zone manually?! - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150408/f9c988fd/smime-0001.bin From bert at freudenbergs.de Wed Apr 8 11:16:52 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Wed Apr 8 11:16:55 2015 Subject: [squeak-dev] WeakArray species (was The Trunk: Collections-bf.612.mcz) In-Reply-To: References: <5523c7d5.162b370a.573d.5b8aSMTPIN_ADDED_MISSING@mx.google.com> Message-ID: <96F864DC-C66C-4A60-BED2-68E43988EF31@freudenbergs.de> On 08.04.2015, at 04:45, Chris Muller wrote: > > The change to override #species may not have gotten enough scrutiny. > It was a mere mention by Eliot in a prior thread, which I captured > into Collections-cmm.603. It may be worth some additional peer > scrutiny. It feels right on the surface but could such a change cause > negative impacts elsewhere? Oh, that was a recent change? I wondered why we never noticed the problems before. That explains it. - Bert - > > > On Tue, Apr 7, 2015 at 7:04 AM, wrote: >> Tobias Pape uploaded a new version of Collections to project The Trunk: >> http://source.squeak.org/trunk/Collections-bf.612.mcz >> >> ==================== Summary ==================== >> >> Name: Collections-bf.612 >> Author: bf >> Time: 7 April 2015, 2:04:06.99 pm >> UUID: 1b9e2fc6-03fb-41c2-a3e8-197fa24c108a >> Ancestors: Collections-ul.611 >> >> Ensure that copyWith/out retains the weak-ness of a weak array. >> >> =============== Diff against Collections-ul.611 =============== >> >> Item was added: >> + ----- Method: WeakArray>>copyWith: (in category 'copying') ----- >> + copyWith: newElement >> + "Re-implemented to not return a strong copy." >> + ^ (super copyWith: newElement) as: self class! >> >> Item was added: >> + ----- Method: WeakArray>>copyWithout: (in category 'copying') ----- >> + copyWithout: oldElement >> + "Re-implemented to not return a strong copy." >> + ^ (super copyWithout: oldElement) as: self class! >> >> Item was changed: >> + ----- Method: WeakArray>>species (in category 'private') ----- >> - ----- Method: WeakArray>>species (in category 'as yet unclassified') ----- >> species >> "More useful to have strongly-referenced results of #select: and #collect:." >> ^ Array! >> >> > -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150408/72c0801f/smime.bin From sean at clipperadams.com Wed Apr 8 11:29:05 2015 From: sean at clipperadams.com (Sean P. DeNigris) Date: Wed Apr 8 11:41:38 2015 Subject: [squeak-dev] Re: Ometa vs XTreams PEG, PetitParser, Helvetia In-Reply-To: References: <579A0D9D-8970-4511-9DF2-B3FD5B0CF202@gmail.com> <86pqp72l4v.fsf@red.stonehenge.com> <1428463087280-4818261.post@n4.nabble.com> Message-ID: <1428492545671-4818328.post@n4.nabble.com> Chris Cunnington-4 wrote >>> Casey> OMeta is ridiculously cool. You can do source to source >>> Casey> translation in some cases, for example, without a pretty printer > > If you look in the docs [1] you?ll start to look for subclasses of > XTActor/PEG.Actor such as PEG.WikiGenerator... Sorry, I should have been more specific. I meant examples of source to source translation with Xtreams or a pointer on how to try... ----- Cheers, Sean -- View this message in context: http://forum.world.st/Re-Ometa-vs-XTreams-PEG-PetitParser-Helvetia-tp3418056p4818328.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Wed Apr 8 11:56:34 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 8 11:56:35 2015 Subject: [squeak-dev] The Inbox: Graphics-tk.309.mcz Message-ID: Bert Freudenberg uploaded a new version of Graphics to project The Inbox: http://source.squeak.org/inbox/Graphics-tk.309.mcz ==================== Summary ==================== Name: Graphics-tk.309 Author: bf Time: 8 April 2015, 1:56:21.259 pm UUID: 413e3a6e-07a2-4dbc-ae77-7686b831bfee Ancestors: Graphics-tfel.308 Some Mac applications won't let you drop in those files because they have the wrong Type and Creator. Here is a fix that makes the Type and Creator be ' ' and ' '. This is for filing out an image of a morph. =============== Diff against Graphics-tfel.308 =============== Item was changed: ----- Method: ImageReadWriter class>>putForm:onFileNamed: (in category 'image reading/writing') ----- putForm: aForm onFileNamed: fileName "Store the given form on a file of the given name." + | writer theFile | + theFile := FileStream newFileNamed: fileName. + writer := self on: theFile binary. - | writer | - writer := self on: (FileStream newFileNamed: fileName) binary. Cursor write showWhile: [writer nextPutImage: aForm]. writer close. + theFile directory setMacFileNamed: theFile localName type: ' ' creator: ' '.! - ! Item was changed: ----- Method: JPEGReadWriter2 class>>putForm:quality:progressiveJPEG:onFileNamed: (in category 'image reading/writing') ----- putForm: aForm quality: quality progressiveJPEG: progressiveFlag onFileNamed: fileName "Store the given Form as a JPEG file of the given name, overwriting any existing file of that name. Quality goes from 0 (low) to 100 (high), where -1 means default. If progressiveFlag is true, encode as a progressive JPEG." + | writer theFile | - | writer | FileDirectory deleteFilePath: fileName. + theFile := FileStream newFileNamed: fileName. + writer := self on: theFile binary. - writer := self on: (FileStream newFileNamed: fileName) binary. Cursor write showWhile: [ writer nextPutImage: aForm quality: quality progressiveJPEG: progressiveFlag]. writer close. + theFile directory setMacFileNamed: theFile localName type: ' ' creator: ' '.! - ! From lewis at mail.msen.com Wed Apr 8 12:06:29 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Wed Apr 8 12:06:30 2015 Subject: [squeak-dev] Time primitives In-Reply-To: <7A458A46-A615-4517-B7D5-6C79FCEA4A0F@freudenbergs.de> References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> <7A458A46-A615-4517-B7D5-6C79FCEA4A0F@freudenbergs.de> Message-ID: <20150408120629.GA58602@shell.msen.com> On Wed, Apr 08, 2015 at 10:56:13AM +0200, Bert Freudenberg wrote: > On 08.04.2015, at 10:33, Levente Uzonyi wrote: > > > > DateAndTime now. "==> 2015-04-07T23:30:28.665+01:00" > > DateAndTime now. "==> 2015-04-07T23:31:32.962+01:00" > > > > Both values are in the CET(+1) time zone, but the actual time zone is CEST(+2). Both images were started in CEST. > > Interesting. In an Etoys image on an Interpreter on Mac OS I get the right time zone: > > DateAndTime now > ==>2015-04-08T10:49:33+02:00 > > That one uses LocalePlugin. > > Trunk image on Cog: > > DateAndTime now > ==> 2015-04-08T10:48:38.991+01:00 > > > I'm telling that the LocalePlugin can find out the correct time zone in case of DST changes, but it seems like gettimeofday() can't. > > In Trunk, #useLocale is disabled (enabled in Etoys). Are we seriously all using +01:00 times, and still expecting users to set the right time zone manually?! > That's a problem for sure, we should fix it in the upcoming release Dave From lewis at mail.msen.com Wed Apr 8 12:16:03 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Wed Apr 8 12:16:07 2015 Subject: [squeak-dev] Time primitives In-Reply-To: References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> Message-ID: <20150408121603.GA60334@shell.msen.com> On Wed, Apr 08, 2015 at 10:33:45AM +0200, Levente Uzonyi wrote: > On Tue, 7 Apr 2015, David T. Lewis wrote: > > >On Tue, Apr 07, 2015 at 11:42:21PM +0200, Levente Uzonyi wrote: > >>On Tue, 7 Apr 2015, David T. Lewis wrote: > >> > >>>I am away and cannot double check the code right now, but the primitives > >>>should be consistent across Cog and the interpreter VM. There had been > >>>some confusion due to the early fork between trunk and oscog, but I > >>>believe that Eliot and I got it sorted out quite a while ago. > >> > >>I can confirm this, but the primitives don't work correctly on the > >>Interpreter VM (4.10.2.2614 on linux from squeakvm.org): > >> > >>Time primUTCMicrosecondClock. "==> 2177453298247316" > >>Time primPosixMicrosecondClockWithOffset. "==> #(519745201 7200)" > >>DateAndTime now. "==> 2015-04-07T23:30:28.665+01:00" > >> > >>The same with CogVM: > >> > >>Time primUTCMicrosecondClock. "==> 3605895086935548" > >>Time primPosixMicrosecondClockWithOffset. "==> #(1428442289746346 7200)" > >>DateAndTime now. "==> 2015-04-07T23:31:32.962+01:00" > >> > > > >Why do you think this is wrong? I suspect that the one hour time zone > > Let me reorder the lines to show the actual problems: > > > Time primUTCMicrosecondClock. "==> 2177453298247316" > Time primUTCMicrosecondClock. "==> 3605895086935548" > > The value from the Interpreter VM (first line) is significantly smaller > than the value from Cog. The former can't be right. Ah sorry, I see it now. It must have been a problem in the interpreter VM as of 4.10.2-2614 that has long since been fixed. It is fine in any of the interpreter VMs that I am using now, but broken in 4.10.2-2614. So we need an update of the interpreter VM builds on squeakvm.org/unix. Dave From commits at source.squeak.org Wed Apr 8 12:25:01 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 8 12:25:03 2015 Subject: [squeak-dev] The Trunk: Graphics-tk.309.mcz Message-ID: Bert Freudenberg uploaded a new version of Graphics to project The Trunk: http://source.squeak.org/trunk/Graphics-tk.309.mcz ==================== Summary ==================== Name: Graphics-tk.309 Author: bf Time: 8 April 2015, 1:56:21.259 pm UUID: 413e3a6e-07a2-4dbc-ae77-7686b831bfee Ancestors: Graphics-tfel.308 Some Mac applications won't let you drop in those files because they have the wrong Type and Creator. Here is a fix that makes the Type and Creator be ' ' and ' '. This is for filing out an image of a morph. =============== Diff against Graphics-tfel.308 =============== Item was changed: ----- Method: ImageReadWriter class>>putForm:onFileNamed: (in category 'image reading/writing') ----- putForm: aForm onFileNamed: fileName "Store the given form on a file of the given name." + | writer theFile | + theFile := FileStream newFileNamed: fileName. + writer := self on: theFile binary. - | writer | - writer := self on: (FileStream newFileNamed: fileName) binary. Cursor write showWhile: [writer nextPutImage: aForm]. writer close. + theFile directory setMacFileNamed: theFile localName type: ' ' creator: ' '.! - ! Item was changed: ----- Method: JPEGReadWriter2 class>>putForm:quality:progressiveJPEG:onFileNamed: (in category 'image reading/writing') ----- putForm: aForm quality: quality progressiveJPEG: progressiveFlag onFileNamed: fileName "Store the given Form as a JPEG file of the given name, overwriting any existing file of that name. Quality goes from 0 (low) to 100 (high), where -1 means default. If progressiveFlag is true, encode as a progressive JPEG." + | writer theFile | - | writer | FileDirectory deleteFilePath: fileName. + theFile := FileStream newFileNamed: fileName. + writer := self on: theFile binary. - writer := self on: (FileStream newFileNamed: fileName) binary. Cursor write showWhile: [ writer nextPutImage: aForm quality: quality progressiveJPEG: progressiveFlag]. writer close. + theFile directory setMacFileNamed: theFile localName type: ' ' creator: ' '.! - ! From frank.shearar at gmail.com Wed Apr 8 13:14:46 2015 From: frank.shearar at gmail.com (Frank Shearar) Date: Wed Apr 8 13:14:49 2015 Subject: [squeak-dev] Re: Ometa vs XTreams PEG, PetitParser, Helvetia In-Reply-To: <1428492545671-4818328.post@n4.nabble.com> References: <579A0D9D-8970-4511-9DF2-B3FD5B0CF202@gmail.com> <86pqp72l4v.fsf@red.stonehenge.com> <1428463087280-4818261.post@n4.nabble.com> <1428492545671-4818328.post@n4.nabble.com> Message-ID: On 8 April 2015 at 12:29, Sean P. DeNigris wrote: > Chris Cunnington-4 wrote >>>> Casey> OMeta is ridiculously cool. You can do source to source >>>> Casey> translation in some cases, for example, without a pretty printer >> >> If you look in the docs [1] you?ll start to look for subclasses of >> XTActor/PEG.Actor such as PEG.WikiGenerator... > > Sorry, I should have been more specific. I meant examples of source to > source translation with Xtreams or a pointer on how to try... I only know of http://www.vpri.org/pdf/m2008001_parseback.pdf. frank From nicolaihess at web.de Wed Apr 8 15:33:20 2015 From: nicolaihess at web.de (Nicolai Hess) Date: Wed Apr 8 15:33:25 2015 Subject: [squeak-dev] vm crash from BalloonEngine (maybe B2DPlugin or BitBltPlugin) Message-ID: In order to reproduce it, draw a rectangle with radial gradient fill, with direction and normal, both of length 1. This one works (no vm crash): |form canvas fill direction normal| direction := 1@0. normal := 0@0. form := Form extent:300@300 depth:32. canvas := form getCanvas. fill := GradientFillStyle new colorRamp:{0 -> Color white . 0.5 -> Color green . 1 -> Color blue};origin:150@150 ;direction:direction;normal:normal;radial:true;yourself. canvas fillRectangle: (50@50 extent:200@200) fillStyle: fill. Display getCanvas drawImage: form at: 300@300. direction := 1@0. normal := 0@0. -> OK direction := 0@0. normal := 0@1. -> OK direction := 1@0. normal := 0@1. -> VM-Crash (Pharo and Squeak) Pharo: VM Version: Cog VM 4.0.0 (release) from Feb 16 2015 Compiler: gcc 4.6.2 Interpreter Build: NBCoInterpreter NativeBoost-CogPlugin-EstebanLorenzano.21 uuid: 4d9b9bdf-2dfa-4c0b-99eb-5b110dadc697 Feb 16 2015 Cogit Build: NBCogit NativeBoost-CogPlugin-EstebanLorenzano.21 uuid: 4d9b9bdf-2dfa-4c0b-99eb-5b110dadc697 Feb 16 2015 Source Version: https://github.com/pharo-project/pharo-vm.git Commit: 55fbd0b0279998a4a33852f5afb3d213986cc3ae Date: 2015-02-16 17:54:00 +0100 By: Esteban Lorenzano Jenkins build #14895 Current byte code: -1 Primitive index: 117 Smalltalk stack dump: 0x24c830 M BalloonEngine>copyLoopFaster 0x6b09b80: a(n) BalloonEngine 0x24c848 M BalloonEngine>copyBits 0x6b09b80: a(n) BalloonEngine 0x24c860 M BalloonEngine>postFlushIfNeeded 0x6b09b80: a(n) BalloonEngine 0x24c884 I BalloonEngine>drawRectangle:fill:borderWidth:borderColor:transform: 0x6b09b80: a(n) BalloonEngine 0x24c8b8 I BalloonCanvas>drawRectangle:color:borderWidth:borderColor: 0x6b099c0: a(n) BalloonCanvas 0x24c8e8 I BalloonCanvas>fillRectangle:basicFillStyle: 0x6b099c0: a(n) BalloonCanvas Squeak: VM Version: Cog VM 4.0.0 (release) from Aug 22 2013 Compiler: gcc 3.4.4 (cygming special, gdc 0.12, using dmd 0.125) Interpreter Build: CoInterpreter VMMaker.oscog-eem.331 uuid: 37d2e4b0-2f37-4e2d-8313-c63637785e59 Aug 22 2013 Cogit Build: StackToRegisterMappingCogit VMMaker.oscog-eem.333 uuid: 84da9cb8-7f30-4cb7-b4fb-239a11f63b54 Aug 22 2013 Source Version: VM: r2776 http://www.squeakvm.org/svn/squeak/branches/Cog Plugins: r2545 http://squeakvm.org/svn/squeak/trunk/platforms/Cross/plugins Current byte code: -1 Primitive index: 117 nicolai -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150408/e6f90189/attachment.htm From asqueaker at gmail.com Wed Apr 8 15:34:40 2015 From: asqueaker at gmail.com (Chris Muller) Date: Wed Apr 8 15:34:43 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: References: <1428075270847-4817347.post@n4.nabble.com> <1428080178583-4817382.post@n4.nabble.com> <1428140501554-4817477.post@n4.nabble.com> <3C16CB19-9ABA-46F0-BE1B-CC8ABA86E1A8@rowledge.org> <1428247271169-4817689.post@n4.nabble.com> Message-ID: > The difference with developer machines starts to get really large. > I think 1024*720 should be safe for nearly every device sold in the past 3 > years. I recently switched to 4K, and settings for 800*600 > don't work too well for that. My newest laptop is a Lenovo X230T with a screen resolution of 1366x768 (the best offered for that model). This is a very common screen size, lots of modern ultra-book portables use this same resolution. By the time one accounts for the real-estate taken by the underlying OS for button bars, etc., you no longer have 768 lines of vertical resolution. So if we open Squeak at 1024x768, it guaranteed to be truncated on top and/or bottom at least by the OS widgets, which is annoying to the user. I think it even sends a particular message that Squeak is a large and monolithic application which, it can be, but opening a 800x600 (especially on a large screen) reinforces the notion that there can also be multiple instances of Squeak running concurrently. If you are running on 4K, my hunch is that you would do the same thing with a 1024x768 image as you would a 800x600 image -- simply expand it. :) From asqueaker at gmail.com Wed Apr 8 16:03:27 2015 From: asqueaker at gmail.com (Chris Muller) Date: Wed Apr 8 16:03:29 2015 Subject: [squeak-dev] WeakArray species (was The Trunk: Collections-bf.612.mcz) In-Reply-To: <96F864DC-C66C-4A60-BED2-68E43988EF31@freudenbergs.de> References: <5523c7d5.162b370a.573d.5b8aSMTPIN_ADDED_MISSING@mx.google.com> <96F864DC-C66C-4A60-BED2-68E43988EF31@freudenbergs.de> Message-ID: The impetus for the change was so that (WeakArray new = Array new) would return true instead of false. But we could accomplish that by overriding #= instead of #species, I think.. Do you think overriding #species in WeakArray at this point in the release process is too aggressive? On Wed, Apr 8, 2015 at 6:16 AM, Bert Freudenberg wrote: > On 08.04.2015, at 04:45, Chris Muller wrote: >> >> The change to override #species may not have gotten enough scrutiny. >> It was a mere mention by Eliot in a prior thread, which I captured >> into Collections-cmm.603. It may be worth some additional peer >> scrutiny. It feels right on the surface but could such a change cause >> negative impacts elsewhere? > > Oh, that was a recent change? I wondered why we never noticed the problems before. That explains it. > > - Bert - > >> >> >> On Tue, Apr 7, 2015 at 7:04 AM, wrote: >>> Tobias Pape uploaded a new version of Collections to project The Trunk: >>> http://source.squeak.org/trunk/Collections-bf.612.mcz >>> >>> ==================== Summary ==================== >>> >>> Name: Collections-bf.612 >>> Author: bf >>> Time: 7 April 2015, 2:04:06.99 pm >>> UUID: 1b9e2fc6-03fb-41c2-a3e8-197fa24c108a >>> Ancestors: Collections-ul.611 >>> >>> Ensure that copyWith/out retains the weak-ness of a weak array. >>> >>> =============== Diff against Collections-ul.611 =============== >>> >>> Item was added: >>> + ----- Method: WeakArray>>copyWith: (in category 'copying') ----- >>> + copyWith: newElement >>> + "Re-implemented to not return a strong copy." >>> + ^ (super copyWith: newElement) as: self class! >>> >>> Item was added: >>> + ----- Method: WeakArray>>copyWithout: (in category 'copying') ----- >>> + copyWithout: oldElement >>> + "Re-implemented to not return a strong copy." >>> + ^ (super copyWithout: oldElement) as: self class! >>> >>> Item was changed: >>> + ----- Method: WeakArray>>species (in category 'private') ----- >>> - ----- Method: WeakArray>>species (in category 'as yet unclassified') ----- >>> species >>> "More useful to have strongly-referenced results of #select: and #collect:." >>> ^ Array! >>> >>> >> > > > > > From Das.Linux at gmx.de Wed Apr 8 16:22:52 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Wed Apr 8 16:22:56 2015 Subject: [squeak-dev] Re: A plan for the release In-Reply-To: References: <1428075270847-4817347.post@n4.nabble.com> <1428080178583-4817382.post@n4.nabble.com> <1428140501554-4817477.post@n4.nabble.com> <3C16CB19-9ABA-46F0-BE1B-CC8ABA86E1A8@rowledge.org> <1428247271169-4817689.post@n4.nabble.com> Message-ID: <82D7E85B-3474-44FC-A6BE-0FABC948EAB6@gmx.de> What about 1024x600 then? Best -Tobias On 08.04.2015, at 17:34, Chris Muller wrote: >> The difference with developer machines starts to get really large. >> I think 1024*720 should be safe for nearly every device sold in the past 3 >> years. I recently switched to 4K, and settings for 800*600 >> don't work too well for that. > > My newest laptop is a Lenovo X230T with a screen resolution of > 1366x768 (the best offered for that model). This is a very common > screen size, lots of modern ultra-book portables use this same > resolution. > > By the time one accounts for the real-estate taken by the underlying > OS for button bars, etc., you no longer have 768 lines of vertical > resolution. So if we open Squeak at 1024x768, it guaranteed to be > truncated on top and/or bottom at least by the OS widgets, which is > annoying to the user. > > I think it even sends a particular message that Squeak is a large and > monolithic application which, it can be, but opening a 800x600 > (especially on a large screen) reinforces the notion that there can > also be multiple instances of Squeak running concurrently. > > If you are running on 4K, my hunch is that you would do the same thing > with a 1024x768 image as you would a 800x600 image -- simply expand > it. :) From commits at source.squeak.org Wed Apr 8 17:40:14 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 8 17:40:16 2015 Subject: [squeak-dev] The Trunk: Collections.spur-cmm.608.mcz Message-ID: Eliot Miranda uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections.spur-cmm.608.mcz ==================== Summary ==================== Name: Collections.spur-cmm.608 Author: eem Time: 8 April 2015, 10:38:40.655 am UUID: 4db32944-345e-41b8-90bd-b176a305c1dc Ancestors: Collections-cmm.608, Collections.spur-ul.607 Collections-cmm.608 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 Merged cmm.603. =============== Diff against Collections-cmm.608 =============== Item was changed: ----- Method: Array>>elementsExchangeIdentityWith: (in category 'converting') ----- elementsExchangeIdentityWith: otherArray + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + At the same time, all pointers to the elements of otherArray are replaced by + pointers to the corresponding elements of this array. The identityHashes remain + with the pointers rather than with the objects so that objects in hashed structures + should still be properly indexed after the mutation." - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. At the same time, all pointers to the elements of otherArray are replaced by pointers to the corresponding elements of this array. The identityHashes remain with the pointers rather than with the objects so that objects in hashed structures should still be properly indexed after the mutation." + + ec == #'bad receiver' ifTrue: + [^self error: 'receiver must be of class Array']. + ec == #'bad argument' ifTrue: + [^self error: (otherArray class == Array + ifTrue: ['arg must be of class Array'] + ifFalse: ['receiver and argument must have the same size'])]. + ec == #'inappropriate operation' ifTrue: + [^self error: 'can''t become immediates such as SmallIntegers or Characters']. + ec == #'no modification' ifTrue: + [^self error: 'can''t become immutable objects']. + ec == #'object is pinned' ifTrue: + [^self error: 'can''t become pinned objects']. + ec == #'insufficient object memory' ifTrue: + [Smalltalk garbageCollect < 1048576 ifTrue: + [Smalltalk growMemoryByAtLeast: 1048576]. + ^self elementsExchangeIdentityWith: otherArray]. + self primitiveFailed! - - otherArray class == Array ifFalse: [^ self error: 'arg must be array']. - self size = otherArray size ifFalse: [^ self error: 'arrays must be same size']. - (self anySatisfy: [:obj | obj class == SmallInteger]) ifTrue: [^ self error: 'can''t become SmallIntegers']. - (otherArray anySatisfy: [:obj | obj class == SmallInteger]) ifTrue: [^ self error: 'can''t become SmallIntegers']. - self with: otherArray do:[:a :b| a == b ifTrue:[^self error:'can''t become yourself']]. - - "Must have failed because not enough space in forwarding table (see ObjectMemory-prepareForwardingTableForBecoming:with:twoWay:). Do GC and try again only once" - (Smalltalk bytesLeft: true) = Smalltalk primitiveGarbageCollect - ifTrue: [^ self primitiveFailed]. - ^ self elementsExchangeIdentityWith: otherArray! Item was changed: ----- Method: Array>>elementsForwardIdentityTo: (in category 'converting') ----- elementsForwardIdentityTo: otherArray + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + The identityHashes remain with the pointers rather than with the objects so that + the objects in this array should still be properly indexed in any existing hashed + structures after the mutation." + - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. The identityHashes remain with the pointers rather than with the objects so that the objects in this array should still be properly indexed in any existing hashed structures after the mutation." - self primitiveFailed! Item was changed: ----- Method: Array>>elementsForwardIdentityTo:copyHash: (in category 'converting') ----- elementsForwardIdentityTo: otherArray copyHash: copyHash + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + If copyHash is true, the identityHashes remain with the pointers rather than with the + objects so that the objects in the receiver should still be properly indexed in any + existing hashed structures after the mutation. If copyHash is false, then the hashes + of the objects in otherArray remain unchanged. If you know what you're doing this + may indeed be what you want." + - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. The identityHashes remain with the pointers rather than with the objects so that the objects in this array should still be properly indexed in any existing hashed structures after the mutation." - self primitiveFailed! Item was changed: ==== ERROR === Error: Unrecognized class type 8 April 2015 5:39:52.662 pm VM: unix - a SmalltalkImage Image: Squeak3.11alpha [latest update: #8824] SecurityManager state: Restricted: false FileAccess: true SocketAccess: true Working Dir /home/squeaksource Trusted Dir /home/squeaksource/secure Untrusted Dir /home/squeaksource/My Squeak MCClassDefinition(Object)>>error: Receiver: a MCClassDefinition(Character) Arguments and temporary variables: aString: 'Unrecognized class type' Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil MCClassDefinition>>kindOfSubclass Receiver: a MCClassDefinition(Character) Arguments and temporary variables: Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil MCClassDefinition>>printDefinitionOn: Receiver: a MCClassDefinition(Character) Arguments and temporary variables: stream: a WriteStream Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil [] in MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: Receiver: a MCDiffyTextWriter Arguments and temporary variables: definition: a WriteStream s: a MCClassDefinition(Character) Receiver's instance variables: stream: a WriteStream initStream: nil --- The full stack --- MCClassDefinition(Object)>>error: MCClassDefinition>>kindOfSubclass MCClassDefinition>>printDefinitionOn: [] in MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - String class(SequenceableCollection class)>>new:streamContents: String class(SequenceableCollection class)>>streamContents: MCDiffyTextWriter(MCTextWriter)>>chunkContents: MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: MCDiffyTextWriter(MCStWriter)>>visitClassDefinition: MCClassDefinition>>accept: [] in MCDiffyTextWriter(MCTextWriter)>>visitInFork: String class(SequenceableCollection class)>>new:streamContents: String class(SequenceableCollection class)>>streamContents: MCDiffyTextWriter(MCTextWriter)>>visitInFork: MCDiffyTextWriter>>writePatchFrom:to: MCDiffyTextWriter>>writeModification: [] in MCDiffyTextWriter>>writePatch: SortedCollection(OrderedCollection)>>do: MCDiffyTextWriter>>writePatch: SSDiffyTextWriter>>writePatch: [] in SSDiffyTextWriter>>writeVersion:for: BlockClosure>>on:do: SSDiffyTextWriter>>writeVersion:for: [] in SSEMailSubscription>>versionAdded:to: BlockClosure>>on:do: SSEMailSubscription>>versionAdded:to: [] in [] in SSProject>>versionAdded: [] in BlockClosure>>newProcess From commits at source.squeak.org Wed Apr 8 17:40:20 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 8 17:40:22 2015 Subject: [squeak-dev] The Trunk: Collections.spur-ul.610.mcz Message-ID: Eliot Miranda uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections.spur-ul.610.mcz ==================== Summary ==================== Name: Collections.spur-ul.610 Author: eem Time: 8 April 2015, 10:38:42.635 am UUID: 3448b17a-1361-47a8-af38-4c26b42dc028 Ancestors: Collections-ul.610, Collections.spur-cmm.608 Collections-ul.610 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 - Slightly faster SequenceableCollection >> #copyUpT* (for ByteString receivers). - SequenceableCollection >> #shuffled belongs to the shuffling category. - Added FormatCharacterSet to String, which will be used by the new implementation of #format: - Removed an unused temporary from String >> #expandMacrosWithArguments: =============== Diff against Collections-ul.610 =============== Item was changed: ----- Method: Array>>elementsExchangeIdentityWith: (in category 'converting') ----- elementsExchangeIdentityWith: otherArray + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + At the same time, all pointers to the elements of otherArray are replaced by + pointers to the corresponding elements of this array. The identityHashes remain + with the pointers rather than with the objects so that objects in hashed structures + should still be properly indexed after the mutation." - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. At the same time, all pointers to the elements of otherArray are replaced by pointers to the corresponding elements of this array. The identityHashes remain with the pointers rather than with the objects so that objects in hashed structures should still be properly indexed after the mutation." + + ec == #'bad receiver' ifTrue: + [^self error: 'receiver must be of class Array']. + ec == #'bad argument' ifTrue: + [^self error: (otherArray class == Array + ifTrue: ['arg must be of class Array'] + ifFalse: ['receiver and argument must have the same size'])]. + ec == #'inappropriate operation' ifTrue: + [^self error: 'can''t become immediates such as SmallIntegers or Characters']. + ec == #'no modification' ifTrue: + [^self error: 'can''t become immutable objects']. + ec == #'object is pinned' ifTrue: + [^self error: 'can''t become pinned objects']. + ec == #'insufficient object memory' ifTrue: + [Smalltalk garbageCollect < 1048576 ifTrue: + [Smalltalk growMemoryByAtLeast: 1048576]. + ^self elementsExchangeIdentityWith: otherArray]. + self primitiveFailed! - - otherArray class == Array ifFalse: [^ self error: 'arg must be array']. - self size = otherArray size ifFalse: [^ self error: 'arrays must be same size']. - (self anySatisfy: [:obj | obj class == SmallInteger]) ifTrue: [^ self error: 'can''t become SmallIntegers']. - (otherArray anySatisfy: [:obj | obj class == SmallInteger]) ifTrue: [^ self error: 'can''t become SmallIntegers']. - self with: otherArray do:[:a :b| a == b ifTrue:[^self error:'can''t become yourself']]. - - "Must have failed because not enough space in forwarding table (see ObjectMemory-prepareForwardingTableForBecoming:with:twoWay:). Do GC and try again only once" - (Smalltalk bytesLeft: true) = Smalltalk primitiveGarbageCollect - ifTrue: [^ self primitiveFailed]. - ^ self elementsExchangeIdentityWith: otherArray! Item was changed: ----- Method: Array>>elementsForwardIdentityTo: (in category 'converting') ----- elementsForwardIdentityTo: otherArray + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + The identityHashes remain with the pointers rather than with the objects so that + the objects in this array should still be properly indexed in any existing hashed + structures after the mutation." + - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. The identityHashes remain with the pointers rather than with the objects so that the objects in this array should still be properly indexed in any existing hashed structures after the mutation." - self primitiveFailed! Item was changed: ----- Method: Array>>elementsForwardIdentityTo:copyHash: (in category 'converting') ----- elementsForwardIdentityTo: otherArray copyHash: copyHash + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + If copyHash is true, the identityHashes remain with the pointers rather than with the + objects so that the objects in the receiver should still be properly indexed in any + existing hashed structures after the mutation. If copyHash is false, then the hashes + of the objects in otherArray remain unchanged. If you know what you're doing this + may indeed be what you want." + - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. The identityHashes remain with the pointers rather than with the objects so that the objects in this array should still be properly indexed in any existing hashed structures after the mutation." - self primitiveFailed! Item was changed: ==== ERROR === Error: Unrecognized class type 8 April 2015 5:40:12.42 pm VM: unix - a SmalltalkImage Image: Squeak3.11alpha [latest update: #8824] SecurityManager state: Restricted: false FileAccess: true SocketAccess: true Working Dir /home/squeaksource Trusted Dir /home/squeaksource/secure Untrusted Dir /home/squeaksource/My Squeak MCClassDefinition(Object)>>error: Receiver: a MCClassDefinition(Character) Arguments and temporary variables: aString: 'Unrecognized class type' Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil MCClassDefinition>>kindOfSubclass Receiver: a MCClassDefinition(Character) Arguments and temporary variables: Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil MCClassDefinition>>printDefinitionOn: Receiver: a MCClassDefinition(Character) Arguments and temporary variables: stream: a WriteStream Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil [] in MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: Receiver: a MCDiffyTextWriter Arguments and temporary variables: definition: a WriteStream s: a MCClassDefinition(Character) Receiver's instance variables: stream: a WriteStream initStream: nil --- The full stack --- MCClassDefinition(Object)>>error: MCClassDefinition>>kindOfSubclass MCClassDefinition>>printDefinitionOn: [] in MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - String class(SequenceableCollection class)>>new:streamContents: String class(SequenceableCollection class)>>streamContents: MCDiffyTextWriter(MCTextWriter)>>chunkContents: MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: MCDiffyTextWriter(MCStWriter)>>visitClassDefinition: MCClassDefinition>>accept: [] in MCDiffyTextWriter(MCTextWriter)>>visitInFork: String class(SequenceableCollection class)>>new:streamContents: String class(SequenceableCollection class)>>streamContents: MCDiffyTextWriter(MCTextWriter)>>visitInFork: MCDiffyTextWriter>>writePatchFrom:to: MCDiffyTextWriter>>writeModification: [] in MCDiffyTextWriter>>writePatch: SortedCollection(OrderedCollection)>>do: MCDiffyTextWriter>>writePatch: SSDiffyTextWriter>>writePatch: [] in SSDiffyTextWriter>>writeVersion:for: BlockClosure>>on:do: SSDiffyTextWriter>>writeVersion:for: [] in SSEMailSubscription>>versionAdded:to: BlockClosure>>on:do: SSEMailSubscription>>versionAdded:to: [] in [] in SSProject>>versionAdded: [] in BlockClosure>>newProcess From commits at source.squeak.org Wed Apr 8 17:40:26 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 8 17:40:27 2015 Subject: [squeak-dev] The Trunk: Collections.spur-ul.611.mcz Message-ID: Eliot Miranda uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections.spur-ul.611.mcz ==================== Summary ==================== Name: Collections.spur-ul.611 Author: eem Time: 8 April 2015, 10:38:45.038 am UUID: e7dc24cc-b32a-4330-81a8-3890c7afc28d Ancestors: Collections-ul.611, Collections.spur-ul.610 Collections-ul.611 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 - Stricter and faster implementation of String >> #format:. =============== Diff against Collections-ul.611 =============== Item was changed: ----- Method: Array>>elementsExchangeIdentityWith: (in category 'converting') ----- elementsExchangeIdentityWith: otherArray + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + At the same time, all pointers to the elements of otherArray are replaced by + pointers to the corresponding elements of this array. The identityHashes remain + with the pointers rather than with the objects so that objects in hashed structures + should still be properly indexed after the mutation." - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. At the same time, all pointers to the elements of otherArray are replaced by pointers to the corresponding elements of this array. The identityHashes remain with the pointers rather than with the objects so that objects in hashed structures should still be properly indexed after the mutation." + + ec == #'bad receiver' ifTrue: + [^self error: 'receiver must be of class Array']. + ec == #'bad argument' ifTrue: + [^self error: (otherArray class == Array + ifTrue: ['arg must be of class Array'] + ifFalse: ['receiver and argument must have the same size'])]. + ec == #'inappropriate operation' ifTrue: + [^self error: 'can''t become immediates such as SmallIntegers or Characters']. + ec == #'no modification' ifTrue: + [^self error: 'can''t become immutable objects']. + ec == #'object is pinned' ifTrue: + [^self error: 'can''t become pinned objects']. + ec == #'insufficient object memory' ifTrue: + [Smalltalk garbageCollect < 1048576 ifTrue: + [Smalltalk growMemoryByAtLeast: 1048576]. + ^self elementsExchangeIdentityWith: otherArray]. + self primitiveFailed! - - otherArray class == Array ifFalse: [^ self error: 'arg must be array']. - self size = otherArray size ifFalse: [^ self error: 'arrays must be same size']. - (self anySatisfy: [:obj | obj class == SmallInteger]) ifTrue: [^ self error: 'can''t become SmallIntegers']. - (otherArray anySatisfy: [:obj | obj class == SmallInteger]) ifTrue: [^ self error: 'can''t become SmallIntegers']. - self with: otherArray do:[:a :b| a == b ifTrue:[^self error:'can''t become yourself']]. - - "Must have failed because not enough space in forwarding table (see ObjectMemory-prepareForwardingTableForBecoming:with:twoWay:). Do GC and try again only once" - (Smalltalk bytesLeft: true) = Smalltalk primitiveGarbageCollect - ifTrue: [^ self primitiveFailed]. - ^ self elementsExchangeIdentityWith: otherArray! Item was changed: ----- Method: Array>>elementsForwardIdentityTo: (in category 'converting') ----- elementsForwardIdentityTo: otherArray + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + The identityHashes remain with the pointers rather than with the objects so that + the objects in this array should still be properly indexed in any existing hashed + structures after the mutation." + - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. The identityHashes remain with the pointers rather than with the objects so that the objects in this array should still be properly indexed in any existing hashed structures after the mutation." - self primitiveFailed! Item was changed: ----- Method: Array>>elementsForwardIdentityTo:copyHash: (in category 'converting') ----- elementsForwardIdentityTo: otherArray copyHash: copyHash + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + If copyHash is true, the identityHashes remain with the pointers rather than with the + objects so that the objects in the receiver should still be properly indexed in any + existing hashed structures after the mutation. If copyHash is false, then the hashes + of the objects in otherArray remain unchanged. If you know what you're doing this + may indeed be what you want." + - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. The identityHashes remain with the pointers rather than with the objects so that the objects in this array should still be properly indexed in any existing hashed structures after the mutation." - self primitiveFailed! Item was changed: ==== ERROR === Error: Unrecognized class type 8 April 2015 5:40:19.971 pm VM: unix - a SmalltalkImage Image: Squeak3.11alpha [latest update: #8824] SecurityManager state: Restricted: false FileAccess: true SocketAccess: true Working Dir /home/squeaksource Trusted Dir /home/squeaksource/secure Untrusted Dir /home/squeaksource/My Squeak MCClassDefinition(Object)>>error: Receiver: a MCClassDefinition(Character) Arguments and temporary variables: aString: 'Unrecognized class type' Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil MCClassDefinition>>kindOfSubclass Receiver: a MCClassDefinition(Character) Arguments and temporary variables: Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil MCClassDefinition>>printDefinitionOn: Receiver: a MCClassDefinition(Character) Arguments and temporary variables: stream: a WriteStream Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil [] in MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: Receiver: a MCDiffyTextWriter Arguments and temporary variables: definition: a WriteStream s: a MCClassDefinition(Character) Receiver's instance variables: stream: a WriteStream initStream: nil --- The full stack --- MCClassDefinition(Object)>>error: MCClassDefinition>>kindOfSubclass MCClassDefinition>>printDefinitionOn: [] in MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - String class(SequenceableCollection class)>>new:streamContents: String class(SequenceableCollection class)>>streamContents: MCDiffyTextWriter(MCTextWriter)>>chunkContents: MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: MCDiffyTextWriter(MCStWriter)>>visitClassDefinition: MCClassDefinition>>accept: [] in MCDiffyTextWriter(MCTextWriter)>>visitInFork: String class(SequenceableCollection class)>>new:streamContents: String class(SequenceableCollection class)>>streamContents: MCDiffyTextWriter(MCTextWriter)>>visitInFork: MCDiffyTextWriter>>writePatchFrom:to: MCDiffyTextWriter>>writeModification: [] in MCDiffyTextWriter>>writePatch: SortedCollection(OrderedCollection)>>do: MCDiffyTextWriter>>writePatch: SSDiffyTextWriter>>writePatch: [] in SSDiffyTextWriter>>writeVersion:for: BlockClosure>>on:do: SSDiffyTextWriter>>writeVersion:for: [] in SSEMailSubscription>>versionAdded:to: BlockClosure>>on:do: SSEMailSubscription>>versionAdded:to: [] in [] in SSProject>>versionAdded: [] in BlockClosure>>newProcess From eliot.miranda at gmail.com Wed Apr 8 17:40:26 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Wed Apr 8 17:40:32 2015 Subject: [squeak-dev] Re: The Inbox: ShoutCore-cmm.44.mcz In-Reply-To: <1428247690960-4817696.post@n4.nabble.com> References: <1428133209157-4817466.post@n4.nabble.com> <1428247690960-4817696.post@n4.nabble.com> Message-ID: On Sun, Apr 5, 2015 at 8:28 AM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > Please do not overwrite an existing color template for styling. Add a new > one > and we can discuss about using this as new default. :) You may re-name the > "current default" to a more appropriate name. :D > +1 > > Best, > Marcel > > > > -- > View this message in context: > http://forum.world.st/The-Inbox-ShoutCore-cmm-44-mcz-tp4817440p4817696.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150408/671dc223/attachment.htm From commits at source.squeak.org Wed Apr 8 17:41:01 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 8 17:41:03 2015 Subject: [squeak-dev] The Trunk: Collections.spur-bf.612.mcz Message-ID: Eliot Miranda uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections.spur-bf.612.mcz ==================== Summary ==================== Name: Collections.spur-bf.612 Author: eem Time: 8 April 2015, 10:38:36.073 am UUID: 63d722b6-ee8c-4c79-9312-c957e277000a Ancestors: Collections-bf.612 Collections-bf.612 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 Ensure that copyWith/out retains the weak-ness of a weak array. =============== Diff against Collections-bf.612 =============== Item was changed: ----- Method: Array>>elementsExchangeIdentityWith: (in category 'converting') ----- elementsExchangeIdentityWith: otherArray + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + At the same time, all pointers to the elements of otherArray are replaced by + pointers to the corresponding elements of this array. The identityHashes remain + with the pointers rather than with the objects so that objects in hashed structures + should still be properly indexed after the mutation." - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. At the same time, all pointers to the elements of otherArray are replaced by pointers to the corresponding elements of this array. The identityHashes remain with the pointers rather than with the objects so that objects in hashed structures should still be properly indexed after the mutation." + + ec == #'bad receiver' ifTrue: + [^self error: 'receiver must be of class Array']. + ec == #'bad argument' ifTrue: + [^self error: (otherArray class == Array + ifTrue: ['arg must be of class Array'] + ifFalse: ['receiver and argument must have the same size'])]. + ec == #'inappropriate operation' ifTrue: + [^self error: 'can''t become immediates such as SmallIntegers or Characters']. + ec == #'no modification' ifTrue: + [^self error: 'can''t become immutable objects']. + ec == #'object is pinned' ifTrue: + [^self error: 'can''t become pinned objects']. + ec == #'insufficient object memory' ifTrue: + [Smalltalk garbageCollect < 1048576 ifTrue: + [Smalltalk growMemoryByAtLeast: 1048576]. + ^self elementsExchangeIdentityWith: otherArray]. + self primitiveFailed! - - otherArray class == Array ifFalse: [^ self error: 'arg must be array']. - self size = otherArray size ifFalse: [^ self error: 'arrays must be same size']. - (self anySatisfy: [:obj | obj class == SmallInteger]) ifTrue: [^ self error: 'can''t become SmallIntegers']. - (otherArray anySatisfy: [:obj | obj class == SmallInteger]) ifTrue: [^ self error: 'can''t become SmallIntegers']. - self with: otherArray do:[:a :b| a == b ifTrue:[^self error:'can''t become yourself']]. - - "Must have failed because not enough space in forwarding table (see ObjectMemory-prepareForwardingTableForBecoming:with:twoWay:). Do GC and try again only once" - (Smalltalk bytesLeft: true) = Smalltalk primitiveGarbageCollect - ifTrue: [^ self primitiveFailed]. - ^ self elementsExchangeIdentityWith: otherArray! Item was changed: ----- Method: Array>>elementsForwardIdentityTo: (in category 'converting') ----- elementsForwardIdentityTo: otherArray + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + The identityHashes remain with the pointers rather than with the objects so that + the objects in this array should still be properly indexed in any existing hashed + structures after the mutation." + - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. The identityHashes remain with the pointers rather than with the objects so that the objects in this array should still be properly indexed in any existing hashed structures after the mutation." - self primitiveFailed! Item was changed: ----- Method: Array>>elementsForwardIdentityTo:copyHash: (in category 'converting') ----- elementsForwardIdentityTo: otherArray copyHash: copyHash + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + If copyHash is true, the identityHashes remain with the pointers rather than with the + objects so that the objects in the receiver should still be properly indexed in any + existing hashed structures after the mutation. If copyHash is false, then the hashes + of the objects in otherArray remain unchanged. If you know what you're doing this + may indeed be what you want." + - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. The identityHashes remain with the pointers rather than with the objects so that the objects in this array should still be properly indexed in any existing hashed structures after the mutation." - self primitiveFailed! Item was changed: ==== ERROR === Error: Unrecognized class type 8 April 2015 5:40:43.912 pm VM: unix - a SmalltalkImage Image: Squeak3.11alpha [latest update: #8824] SecurityManager state: Restricted: false FileAccess: true SocketAccess: true Working Dir /home/squeaksource Trusted Dir /home/squeaksource/secure Untrusted Dir /home/squeaksource/My Squeak MCClassDefinition(Object)>>error: Receiver: a MCClassDefinition(Character) Arguments and temporary variables: aString: 'Unrecognized class type' Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil MCClassDefinition>>kindOfSubclass Receiver: a MCClassDefinition(Character) Arguments and temporary variables: Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil MCClassDefinition>>printDefinitionOn: Receiver: a MCClassDefinition(Character) Arguments and temporary variables: stream: a WriteStream Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil [] in MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: Receiver: a MCDiffyTextWriter Arguments and temporary variables: definition: a WriteStream s: a MCClassDefinition(Character) Receiver's instance variables: stream: a WriteStream initStream: nil --- The full stack --- MCClassDefinition(Object)>>error: MCClassDefinition>>kindOfSubclass MCClassDefinition>>printDefinitionOn: [] in MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - String class(SequenceableCollection class)>>new:streamContents: String class(SequenceableCollection class)>>streamContents: MCDiffyTextWriter(MCTextWriter)>>chunkContents: MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: MCDiffyTextWriter(MCStWriter)>>visitClassDefinition: MCClassDefinition>>accept: [] in MCDiffyTextWriter(MCTextWriter)>>visitInFork: String class(SequenceableCollection class)>>new:streamContents: String class(SequenceableCollection class)>>streamContents: MCDiffyTextWriter(MCTextWriter)>>visitInFork: MCDiffyTextWriter>>writePatchFrom:to: MCDiffyTextWriter>>writeModification: [] in MCDiffyTextWriter>>writePatch: SortedCollection(OrderedCollection)>>do: MCDiffyTextWriter>>writePatch: SSDiffyTextWriter>>writePatch: [] in SSDiffyTextWriter>>writeVersion:for: BlockClosure>>on:do: SSDiffyTextWriter>>writeVersion:for: [] in SSEMailSubscription>>versionAdded:to: BlockClosure>>on:do: SSEMailSubscription>>versionAdded:to: [] in [] in SSProject>>versionAdded: [] in BlockClosure>>newProcess From commits at source.squeak.org Wed Apr 8 17:42:10 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 8 17:42:11 2015 Subject: [squeak-dev] The Trunk: System.spur-mt.717.mcz Message-ID: Eliot Miranda uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System.spur-mt.717.mcz ==================== Summary ==================== Name: System.spur-mt.717 Author: eem Time: 8 April 2015, 10:39:10.419 am UUID: d40e1d79-4bf2-4277-8eff-5576da0b9566 Ancestors: System-mt.717, System.spur-mt.716 System-mt.717 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 Use general window-update function when changing window colors. =============== Diff against System-mt.717 =============== Item was removed: - Object subclass: #ObjectHistory - instanceVariableNames: 'marks markProcess' - classVariableNames: 'Current' - poolDictionaries: '' - category: 'System-Support'! - - !ObjectHistory commentStamp: 'bf 11/16/2012 12:19' prior: 0! - ObjectHistory holds ObjectHistoryMark objects which are placed in the object memory at regular intervals by its markProcess in the background. Adjacent marks (with no remaining objects inbetween) are coalesced so over time the collection does not grow unnecessarily large. - - Using these markers it is possible to determine the age of objects in memory from the time the ObjectHistory was initialized. Try e.g.: - self oopTimestamp. - self oopAge. - ObjectHistory current oopClassesByDate. - - Instance Variables - marks: SortedCollection of ObjectHistoryMark objects - markProcess: a Process running our markLoop - ! Item was removed: - ----- Method: ObjectHistory class>>current (in category 'accessing') ----- - current - ^ Current ifNil: [Current := self new]! Item was removed: - ----- Method: ObjectHistory class>>initialize (in category 'class initialization') ----- - initialize - self current. - ! Item was removed: - ----- Method: ObjectHistory class>>obsolete (in category 'class initialization') ----- - obsolete - "Kill the mark process before removing the class." - Current ifNotNil: - [:objectHistory| - objectHistory terminate]. - super obsolete! Item was removed: - ----- Method: ObjectHistory>>ageOf: (in category 'queries') ----- - ageOf: anObject - "Age of anObject in seconds" - | timestamp | - timestamp := self timestampOf: anObject. - timestamp ifNil: [^0]. - ^(DateAndTime now - timestamp) asSeconds roundTo: self markRate! Item was removed: - ----- Method: ObjectHistory>>initialize (in category 'initializing') ----- - initialize - self restartMarkProcess. - - ! Item was removed: - ----- Method: ObjectHistory>>markLoop (in category 'marking') ----- - markLoop - [true] whileTrue: [ - self markUpdate. - (Delay forSeconds: self markRate) wait]! Item was removed: - ----- Method: ObjectHistory>>markRate (in category 'marking') ----- - markRate - "rate of creating ObjectHistoryMarks" - ^60! Item was removed: - ----- Method: ObjectHistory>>markUpdate (in category 'marking') ----- - markUpdate - "Add a new mark and compact the marks collection" - | mark prev | - "lazy init so this happens in the background process" - marks ifNil: [self reinitMarks]. - "add new mark to object memory" - mark := self newMark. - mark timestamp <= marks last timestamp ifTrue: [^self "could happen if clock is wrong"]. - marks addLast: mark. - "compact the table by removing adjacent marks" - prev := marks first. - marks removeAllSuchThat: [:each | | doDelete | - doDelete := prev objectAfter == each. - prev := each. - doDelete]. - "The loop above is O(n) in number of marks, but that number should never become so large to be an issue. Even if the number was large, this is running at system background priority so should not interfere with any user process, not even user background processes. The symptom should only be that the system is less idle. - - If we ever get to a point where the number of marks is an issue then the compacting here could be made partial: since old marks rarely get coalesced it would make sense to only check the newer ones often, and the old ones perhaps only at the system startup."! Item was removed: - ----- Method: ObjectHistory>>newMark (in category 'private') ----- - newMark - ^ ObjectHistoryMark new! Item was removed: - ----- Method: ObjectHistory>>oopClassesByAge (in category 'stats') ----- - oopClassesByAge - "Answer collection of (oopAge in seconds -> sorted counts of object classes) sorted from lowest age" - "ObjectHistory current oopClassesByAge" - - | stats prev endOfMemory now bag age obj | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - now := self newMark timestamp. - marks do: [:mark | - prev ifNotNil: [ - bag := Bag new. - obj := prev objectAfter. - [obj == mark] whileFalse: [ - bag add: obj class. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - age := (now - mark timestamp) asSeconds roundTo: self markRate. - stats addFirst: age -> bag sortedCounts]. - prev := mark]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>oopClassesByDate (in category 'stats') ----- - oopClassesByDate - "Answer collection of (Date -> sorted counts of object classes) sorted from newest date" - "ObjectHistory current oopClassesByDate" - - | stats prev endOfMemory bag date obj thisDate | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - thisDate := nil. - bag := Bag new. - marks do: [:mark | - prev ifNotNil: [ - obj := prev objectAfter. - [obj == mark] whileFalse: [ - bag add: obj class. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - date := mark timestamp asDate. - thisDate = date ifFalse: [ - stats addFirst: date -> bag sortedCounts. - bag := Bag new. - thisDate := date]]. - prev := mark]. - thisDate = date ifFalse: [ - stats addLast: date -> bag sortedCounts]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>oopCountsByAge (in category 'stats') ----- - oopCountsByAge - "Answer collection of (oopAge in seconds -> number of objects) sorted from lowest age" - "ObjectHistory current oopCountsByAge" - - | stats prev endOfMemory now n age obj | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - now := self newMark timestamp. - marks do: [:mark | - prev ifNotNil: [ - n := 0. - obj := prev objectAfter. - [obj == mark] whileFalse: [ - n := n + 1. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - age := (now - mark timestamp) asSeconds roundTo: self markRate. - stats addFirst: age -> n]. - prev := mark]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>reinitMarks (in category 'private') ----- - reinitMarks - marks := ObjectHistoryMark allInstances asOrderedCollection. - marks - ifEmpty: [marks add: self newMark] - ifNotEmpty: [ | prev | - prev := nil. - marks removeAllSuchThat: [:obj | - prev notNil and: [prev timestamp >= obj timestamp]]]. - ! Item was removed: - ----- Method: ObjectHistory>>restartMarkProcess (in category 'marking') ----- - restartMarkProcess - markProcess ifNotNil: [markProcess terminate]. - markProcess := [self markLoop] - forkAt: Processor systemBackgroundPriority - named: 'ObjectHistory''s markProcess'. - ! Item was removed: - ----- Method: ObjectHistory>>terminate (in category 'private') ----- - terminate - markProcess ifNotNil: - [markProcess terminate]! Item was removed: - ----- Method: ObjectHistory>>timestampOf: (in category 'queries') ----- - timestampOf: anObject - "Timestamp of anObject, or nil if too new" - | endOfMemory mark | - anObject class == SmallInteger ifTrue: [^nil]. - mark := anObject. - endOfMemory := Object new. - [mark class == ObjectHistoryMark] whileFalse: [ - mark := mark nextObject. - mark == endOfMemory ifTrue: [^nil]]. - ^mark timestamp! Item was removed: - Object subclass: #ObjectHistoryMark - instanceVariableNames: 'timestamp' - classVariableNames: '' - poolDictionaries: '' - category: 'System-Support'! - - !ObjectHistoryMark commentStamp: 'bf 11/7/2012 00:12' prior: 0! - An ObjectHistoryMark is a permanent mark in the object memory. It holds a timestamp. - - While the timestamp could be used directly as mark by ObjectHistory, it's conceivable that its format might change in the future, and we do not want the mark's relative position in memory to change (which would be the case if it was migrated to a new format). So we use a distinct object instead (and we protect it against accidental become-ing by overriding those methods).! Item was removed: - ----- Method: ObjectHistoryMark>>become: (in category 'mutating') ----- - become: otherObject - ^self error: 'marks need to stay fixed in the object memory'! Item was removed: - ----- Method: ObjectHistoryMark>>becomeForward: (in category 'mutating') ----- - becomeForward: otherObject - ^self error: 'marks need to stay fixed in the object memory'! Item was removed: - ----- Method: ObjectHistoryMark>>initialize (in category 'initialization') ----- - initialize - timestamp := DateAndTime now floor. - ! Item was removed: - ----- Method: ObjectHistoryMark>>objectAfter (in category 'accessing') ----- - objectAfter - "Answer the next object in memory after me and my timestamp" - | successor | - successor := self nextObject. - successor == timestamp - ifTrue: [successor := successor nextObject]. - ^ successor! Item was removed: - ----- Method: ObjectHistoryMark>>printOn: (in category 'printing') ----- - printOn: aStream - aStream - nextPutAll: self class name; - nextPut: $(; - print: timestamp; - nextPut: $)! Item was removed: - ----- Method: ObjectHistoryMark>>timestamp (in category 'accessing') ----- - timestamp - ^timestamp - ! Item was changed: ----- Method: SmalltalkImage>>compactClassesArray (in category 'special objects') ----- compactClassesArray "Smalltalk compactClassesArray" + "Backward-compatibility support. Spur does not have compact classes." + ^{}! - "Return the array of 31 classes whose instances may be - represented compactly" - ^ self specialObjectsArray at: 29! Item was added: + ----- Method: SmalltalkImage>>growMemoryByAtLeast: (in category 'memory space') ----- + growMemoryByAtLeast: numBytes + "Grow memory by at least the requested number of bytes. + Primitive. Essential. Fail if no memory is available." + + (numBytes isInteger and: [numBytes > 0]) ifTrue: + [OutOfMemory signal]. + ^self primitiveFailed! Item was added: + ----- Method: SmalltalkImage>>maxIdentityHash (in category 'system attributes') ----- + maxIdentityHash + "Answer the maximum identityHash value supported by the VM." + + ^self primitiveFailed! Item was changed: ----- Method: SmalltalkImage>>primBytesLeft (in category 'memory space') ----- primBytesLeft + "Primitive. Answer the number of free bytes available in old space. + Not accurate unless preceded by - "Primitive. Answer the number of bytes available for new object data. - Not accurate unless preceded by Smalltalk garbageCollectMost (for reasonable accuracy), or Smalltalk garbageCollect (for real accuracy). + See Object documentation whatIsAPrimitive." - See Object documentation whatIsAPrimitive." + ^0! - ^ 0! Item was changed: ----- Method: SmalltalkImage>>primitiveGarbageCollect (in category 'memory space') ----- primitiveGarbageCollect + "Primitive. Reclaims all garbage and answers the size of the largest free chunk in old space.." - "Primitive. Reclaims all garbage and answers the number of bytes of available space." + ^self primitiveFailed! - ^ self primBytesLeft! Item was changed: ----- Method: SmalltalkImage>>recreateSpecialObjectsArray (in category 'special objects') ----- recreateSpecialObjectsArray "Smalltalk recreateSpecialObjectsArray" "To external package developers: **** DO NOT OVERRIDE THIS METHOD. ***** If you are writing a plugin and need additional special object(s) for your own use, use addGCRoot() function and use own, separate special objects registry " "The Special Objects Array is an array of objects used by the Squeak virtual machine. Its contents are critical and accesses to it by the VM are unchecked, so don't even think of playing here unless you know what you are doing." | newArray | + newArray := Array new: 60. - newArray := Array new: 58. "Nil false and true get used throughout the interpreter" newArray at: 1 put: nil. newArray at: 2 put: false. newArray at: 3 put: true. "This association holds the active process (a ProcessScheduler)" newArray at: 4 put: (self specialObjectsArray at: 4) "(self bindingOf: #Processor) but it answers an Alias". "Numerous classes below used for type checking and instantiation" newArray at: 5 put: Bitmap. newArray at: 6 put: SmallInteger. newArray at: 7 put: ByteString. newArray at: 8 put: Array. newArray at: 9 put: Smalltalk. + newArray at: 10 put: BoxedFloat64. + newArray at: 11 put: (self globals at: #MethodContext ifAbsent: [self globals at: #Context]). + newArray at: 12 put: nil. "was BlockContext." - newArray at: 10 put: Float. - newArray at: 11 put: MethodContext. - newArray at: 12 put: BlockContext. newArray at: 13 put: Point. newArray at: 14 put: LargePositiveInteger. newArray at: 15 put: Display. newArray at: 16 put: Message. newArray at: 17 put: CompiledMethod. + newArray at: 18 put: ((self specialObjectsArray at: 18) ifNil: [Semaphore new]). "low space Semaphore" - newArray at: 18 put: (self specialObjectsArray at: 18). - "(low space Semaphore)" newArray at: 19 put: Semaphore. newArray at: 20 put: Character. newArray at: 21 put: #doesNotUnderstand:. newArray at: 22 put: #cannotReturn:. newArray at: 23 put: nil. "This is the process signalling low space." "An array of the 32 selectors that are compiled as special bytecodes, paired alternately with the number of arguments each takes." newArray at: 24 put: #( #+ 1 #- 1 #< 1 #> 1 #<= 1 #>= 1 #= 1 #~= 1 #* 1 #/ 1 #\\ 1 #@ 1 #bitShift: 1 #// 1 #bitAnd: 1 #bitOr: 1 #at: 1 #at:put: 2 #size 0 #next 0 #nextPut: 1 #atEnd 0 #== 1 #class 0 #blockCopy: 1 #value 0 #value: 1 #do: 1 #new 0 #new: 1 #x 0 #y 0 ). "An array of the 255 Characters in ascii order. + Cog inlines table into machine code at: prim so do not regenerate it. + This is nil in Spur, which has immediate Characters." - Cog inlines table into machine code at: prim so do not regenerate it." newArray at: 25 put: (self specialObjectsArray at: 25). newArray at: 26 put: #mustBeBoolean. newArray at: 27 put: ByteArray. newArray at: 28 put: Process. + "An array of up to 31 classes whose instances will have compact headers; an empty array in Spur" - "An array of up to 31 classes whose instances will have compact headers" newArray at: 29 put: self compactClassesArray. + newArray at: 30 put: ((self specialObjectsArray at: 30) ifNil: [Semaphore new]). "delay Semaphore" + newArray at: 31 put: ((self specialObjectsArray at: 31) ifNil: [Semaphore new]). "user interrupt Semaphore" - newArray at: 30 put: (self specialObjectsArray at: 30). "(delay Semaphore)" - newArray at: 31 put: (self specialObjectsArray at: 31). "(user interrupt Semaphore)" "Entries 32 - 34 unreferenced. Previously these contained prototype instances to be copied for fast initialization" + newArray at: 32 put: nil. "was the prototype Float" + newArray at: 33 put: nil. "was the prototype 4-byte LargePositiveInteger" + newArray at: 34 put: nil. "was the prototype Point" - newArray at: 32 put: nil. "was (Float new: 2)" - newArray at: 33 put: nil. "was (LargePositiveInteger new: 4)" - newArray at: 34 put: nil. "was Point new" newArray at: 35 put: #cannotInterpret:. + newArray at: 36 put: nil. "was the prototype MethodContext" - "Note: This must be fixed once we start using context prototypes (yeah, right)" - "(MethodContext new: CompiledMethod fullFrameSize)." - newArray at: 36 put: (self specialObjectsArray at: 36). "Is the prototype MethodContext (unused by the VM)" newArray at: 37 put: BlockClosure. + newArray at: 38 put: nil. "was the prototype BlockContext" - "(BlockContext new: CompiledMethod fullFrameSize)." - newArray at: 38 put: (self specialObjectsArray at: 38). "Is the prototype BlockContext (unused by the VM)" "array of objects referred to by external code" + newArray at: 39 put: (self specialObjectsArray at: 39). "external semaphores" - newArray at: 39 put: (self specialObjectsArray at: 39). "preserve external semaphores" newArray at: 40 put: nil. "Reserved for Mutex in Cog VMs" + newArray at: 41 put: ((self specialObjectsArray at: 41) ifNil: [LinkedList new]). "Reserved for a LinkedList instance for overlapped calls in CogMT" + newArray at: 42 put: ((self specialObjectsArray at: 42) ifNil: [Semaphore new]). "finalization Semaphore" - newArray at: 41 put: nil. "Reserved for a LinkedList instance for overlapped calls in CogMT" - "finalization Semaphore" - newArray at: 42 put: ((self specialObjectsArray at: 42) ifNil: [Semaphore new]). newArray at: 43 put: LargeNegativeInteger. "External objects for callout. Note: Written so that one can actually completely remove the FFI." newArray at: 44 put: (self at: #ExternalAddress ifAbsent: []). newArray at: 45 put: (self at: #ExternalStructure ifAbsent: []). newArray at: 46 put: (self at: #ExternalData ifAbsent: []). newArray at: 47 put: (self at: #ExternalFunction ifAbsent: []). newArray at: 48 put: (self at: #ExternalLibrary ifAbsent: []). newArray at: 49 put: #aboutToReturn:through:. newArray at: 50 put: #run:with:in:. "51 reserved for immutability message" + newArray at: 51 put: #attemptToAssign:withIndex:. - "newArray at: 51 put: #attemptToAssign:withIndex:." - newArray at: 51 put: (self specialObjectsArray at: 51 ifAbsent: []). newArray at: 52 put: #(nil "nil => generic error" #'bad receiver' #'bad argument' #'bad index' #'bad number of arguments' #'inappropriate operation' #'unsupported operation' #'no modification' #'insufficient object memory' #'insufficient C memory' #'not found' #'bad method' #'internal error in named primitive machinery' #'object may move' #'resource limit exceeded' + #'object is pinned' #'primitive write beyond end of object'). - #'object is pinned'). "53 to 55 are for Alien" newArray at: 53 put: (self at: #Alien ifAbsent: []). + newArray at: 54 put: #invokeCallbackContext:. "use invokeCallback:stack:registers:jmpbuf: for old Alien callbacks." - newArray at: 54 put: #invokeCallbackContext::. "use invokeCallback:stack:registers:jmpbuf: for old Alien callbacks." newArray at: 55 put: (self at: #UnsafeAlien ifAbsent: []). + "Used to be WeakFinalizationList for WeakFinalizationList hasNewFinalization, obsoleted by ephemeron support." + newArray at: 56 put: nil. - "Weak reference finalization" - newArray at: 56 put: (self at: #WeakFinalizationList ifAbsent: []). "reserved for foreign callback process" newArray at: 57 put: (self specialObjectsArray at: 57 ifAbsent: []). newArray at: 58 put: #unusedBytecode. + "59 reserved for Sista counter tripped message" + newArray at: 59 put: #conditionalBranchCounterTrippedOn:. + "60 reserved for Sista class trap message" + newArray at: 60 put: #classTrapFor:. "Now replace the interpreter's reference in one atomic operation" + self specialObjectsArray becomeForward: newArray! - self specialObjectsArray becomeForward: newArray - ! Item was changed: ----- Method: SmalltalkImage>>setGCParameters (in category 'snapshot and quit') ----- setGCParameters + "Adjust the VM's default GC parameters to avoid too much tenuring. + Maybe this should be left to the VM?" - "Adjust the VM's default GC parameters to avoid premature tenuring." + | proportion edenSize survivorSize averageObjectSize numObjects | + proportion := 0.9. "tenure when 90% of pastSpace is full" + edenSize := SmalltalkImage current vmParameterAt: 44. + survivorSize := edenSize / 5.0. "David's paper uses 140Kb eden + 2 x 28kb survivor spaces; Spur uses the same ratios :-)" + averageObjectSize := 8 * self wordSize. "a good approximation" + numObjects := (proportion * survivorSize / averageObjectSize) rounded. + SmalltalkImage current vmParameterAt: 6 put: numObjects "tenure when more than this many objects survive the GC"! - self vmParameterAt: 5 put: 4000. "do an incremental GC after this many allocations" - self vmParameterAt: 6 put: 2000. "tenure when more than this many objects survive the GC" - ! Item was changed: ----- Method: SpaceTally>>spaceForInstancesOf: (in category 'instance size') ----- spaceForInstancesOf: aClass + "Answer a pair of the number of bytes consumed by all instances of the + given class, including their object headers, and the number of instances." - "Answer the number of bytes consumed by all instances of the given class, including their object headers and the number of instances." + | instances total | + instances := aClass allInstances. + instances isEmpty ifTrue: [^#(0 0)]. - | smallHeaderSize instVarBytes isVariable bytesPerElement total lastInstance instance instanceCount | - instance := aClass someInstance ifNil: [ ^#(0 0) ]. - smallHeaderSize := aClass isCompact ifTrue: [ 4 ] ifFalse: [ 8 ]. - instVarBytes := aClass instSize * 4. - isVariable := aClass isVariable. - bytesPerElement := isVariable - ifFalse: [ 0 ] - ifTrue: [ aClass isBytes ifTrue: [ 1 ] ifFalse: [ 4 ] ]. total := 0. + aClass isVariable + ifTrue: + [instances do: + [:i| total := total + (aClass byteSizeOfInstanceOfSize: i basicSize)]] + ifFalse: + [total := instances size * aClass byteSizeOfInstance]. + ^{ total. instances size }! - instanceCount := 0. - "A modified version of #allInstancesDo: is inlined here. It avoids an infinite loop when another process is creating new instances of aClass." - self flag: #allInstancesDo:. - lastInstance := - aClass == CompiledMethod "CompiledMethod has special format, see its class comment" - ifTrue: [aClass new] - ifFalse: [aClass basicNew]. - [ instance == lastInstance ] whileFalse: [ - | contentBytes headerBytes | - contentBytes := instVarBytes + (isVariable - ifFalse: [ 0 ] - ifTrue: [ instance basicSize * bytesPerElement ]). - headerBytes := contentBytes > 255 - ifTrue: [ 12 ] - ifFalse: [ smallHeaderSize ]. - total := total + headerBytes + (contentBytes roundUpTo: 4). - instanceCount := instanceCount + 1. - instance := instance nextInstance ]. - ^{ total. instanceCount }! Item was added: + ----- Method: SystemDictionary>>growMemoryByAtLeast: (in category 'memory space') ----- + growMemoryByAtLeast: numBytes + "Grow memory by at least the requested number of bytes. + Primitive. Fail if no memory is available. Essential." + + ^(numBytes isInteger and: [numBytes > 0]) + ifTrue: [OutOfMemory signal] + ifFalse: [self primitiveFailed]! Item was added: + ----- Method: SystemDictionary>>maxIdentityHash (in category 'system attributes') ----- + maxIdentityHash + "Answer the maximum identityHash value supported by the VM." + + ^self primitiveFailed! Item was added: + ----- Method: SystemDictionary>>setGCParameters (in category 'snapshot and quit') ----- + setGCParameters + "Adjust the VM's default GC parameters to avoid too much tenuring. + Maybe this should be left to the VM?" + + | proportion edenSize survivorSize averageObjectSize numObjects | + proportion := 0.9. "tenure when 90% of pastSpace is full" + edenSize := SmalltalkImage current vmParameterAt: 44. + survivorSize := edenSize / 5.0. "David's paper uses 140Kb eden + 2 x 28kb survivor spaces; Spur uses the same ratios :-)" + averageObjectSize := 8 * self wordSize. "a good approximation" + numObjects := (proportion * survivorSize / averageObjectSize) rounded. + SmalltalkImage current vmParameterAt: 6 put: numObjects "tenure when more than this many objects survive the GC"! Item was added: + ----- Method: SystemNavigation>>allObjects (in category 'query') ----- + allObjects + "Answer an Array of all objects in the system. Fail if + there isn't enough memory to instantiate the result." + + ^self primitiveFailed! Item was changed: ----- Method: SystemNavigation>>allObjectsDo: (in category 'query') ----- allObjectsDo: aBlock + "Evaluate the argument, aBlock, for each object in the system, excluding immediates + such as SmallInteger and Character." + self allObjectsOrNil + ifNotNil: [:allObjects| allObjects do: aBlock] + ifNil: + ["Fall back on the old single object primitive code. With closures, this needs + to use an end marker (lastObject) since activation of the block will create + new contexts and cause an infinite loop. The lastObject must be created + before calling someObject, so that the VM can settle the enumeration (e.g. + by flushing new space) as a side effect of someObject" + | object lastObject | + lastObject := Object new. + object := self someObject. + [lastObject == object or: [0 == object]] whileFalse: + [aBlock value: object. + object := object nextObject]]! - "Evaluate the argument, aBlock, for each object in the system - excluding SmallIntegers. With closures, this needs to use an end - marker (lastObject) since activation of the block will create new - contexts and cause an infinite loop." - | object lastObject | - object := self someObject. - lastObject := Object new. - [lastObject == object or: [0 == object]] - whileFalse: [aBlock value: object. - object := object nextObject]! Item was added: + ----- Method: SystemNavigation>>allObjectsOrNil (in category 'query') ----- + allObjectsOrNil + "Answer an Array of all objects in the system. Fail if there isn't + enough memory to instantiate the result and answer nil." + + ^nil! From commits at source.squeak.org Wed Apr 8 17:42:11 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 8 17:42:14 2015 Subject: [squeak-dev] The Trunk: System.spur-topa.718.mcz Message-ID: Eliot Miranda uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System.spur-topa.718.mcz ==================== Summary ==================== Name: System.spur-topa.718 Author: eem Time: 8 April 2015, 10:39:13.494 am UUID: 0b4876b6-5d4d-466c-b276-3c2f36ba73f0 Ancestors: System-topa.718, System.spur-mt.717 System-topa.718 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 Drop dependencies. For Preferences class>>#restorePreferencesFromDisk, we restore the old version, since right away there is no good way to allow old behavior (loading 'my.prefs'), selecting a custom prefs file, AND not depending on tools. =============== Diff against System-topa.718 =============== Item was removed: - Object subclass: #ObjectHistory - instanceVariableNames: 'marks markProcess' - classVariableNames: 'Current' - poolDictionaries: '' - category: 'System-Support'! - - !ObjectHistory commentStamp: 'bf 11/16/2012 12:19' prior: 0! - ObjectHistory holds ObjectHistoryMark objects which are placed in the object memory at regular intervals by its markProcess in the background. Adjacent marks (with no remaining objects inbetween) are coalesced so over time the collection does not grow unnecessarily large. - - Using these markers it is possible to determine the age of objects in memory from the time the ObjectHistory was initialized. Try e.g.: - self oopTimestamp. - self oopAge. - ObjectHistory current oopClassesByDate. - - Instance Variables - marks: SortedCollection of ObjectHistoryMark objects - markProcess: a Process running our markLoop - ! Item was removed: - ----- Method: ObjectHistory class>>current (in category 'accessing') ----- - current - ^ Current ifNil: [Current := self new]! Item was removed: - ----- Method: ObjectHistory class>>initialize (in category 'class initialization') ----- - initialize - self current. - ! Item was removed: - ----- Method: ObjectHistory class>>obsolete (in category 'class initialization') ----- - obsolete - "Kill the mark process before removing the class." - Current ifNotNil: - [:objectHistory| - objectHistory terminate]. - super obsolete! Item was removed: - ----- Method: ObjectHistory>>ageOf: (in category 'queries') ----- - ageOf: anObject - "Age of anObject in seconds" - | timestamp | - timestamp := self timestampOf: anObject. - timestamp ifNil: [^0]. - ^(DateAndTime now - timestamp) asSeconds roundTo: self markRate! Item was removed: - ----- Method: ObjectHistory>>initialize (in category 'initializing') ----- - initialize - self restartMarkProcess. - - ! Item was removed: - ----- Method: ObjectHistory>>markLoop (in category 'marking') ----- - markLoop - [true] whileTrue: [ - self markUpdate. - (Delay forSeconds: self markRate) wait]! Item was removed: - ----- Method: ObjectHistory>>markRate (in category 'marking') ----- - markRate - "rate of creating ObjectHistoryMarks" - ^60! Item was removed: - ----- Method: ObjectHistory>>markUpdate (in category 'marking') ----- - markUpdate - "Add a new mark and compact the marks collection" - | mark prev | - "lazy init so this happens in the background process" - marks ifNil: [self reinitMarks]. - "add new mark to object memory" - mark := self newMark. - mark timestamp <= marks last timestamp ifTrue: [^self "could happen if clock is wrong"]. - marks addLast: mark. - "compact the table by removing adjacent marks" - prev := marks first. - marks removeAllSuchThat: [:each | | doDelete | - doDelete := prev objectAfter == each. - prev := each. - doDelete]. - "The loop above is O(n) in number of marks, but that number should never become so large to be an issue. Even if the number was large, this is running at system background priority so should not interfere with any user process, not even user background processes. The symptom should only be that the system is less idle. - - If we ever get to a point where the number of marks is an issue then the compacting here could be made partial: since old marks rarely get coalesced it would make sense to only check the newer ones often, and the old ones perhaps only at the system startup."! Item was removed: - ----- Method: ObjectHistory>>newMark (in category 'private') ----- - newMark - ^ ObjectHistoryMark new! Item was removed: - ----- Method: ObjectHistory>>oopClassesByAge (in category 'stats') ----- - oopClassesByAge - "Answer collection of (oopAge in seconds -> sorted counts of object classes) sorted from lowest age" - "ObjectHistory current oopClassesByAge" - - | stats prev endOfMemory now bag age obj | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - now := self newMark timestamp. - marks do: [:mark | - prev ifNotNil: [ - bag := Bag new. - obj := prev objectAfter. - [obj == mark] whileFalse: [ - bag add: obj class. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - age := (now - mark timestamp) asSeconds roundTo: self markRate. - stats addFirst: age -> bag sortedCounts]. - prev := mark]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>oopClassesByDate (in category 'stats') ----- - oopClassesByDate - "Answer collection of (Date -> sorted counts of object classes) sorted from newest date" - "ObjectHistory current oopClassesByDate" - - | stats prev endOfMemory bag date obj thisDate | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - thisDate := nil. - bag := Bag new. - marks do: [:mark | - prev ifNotNil: [ - obj := prev objectAfter. - [obj == mark] whileFalse: [ - bag add: obj class. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - date := mark timestamp asDate. - thisDate = date ifFalse: [ - stats addFirst: date -> bag sortedCounts. - bag := Bag new. - thisDate := date]]. - prev := mark]. - thisDate = date ifFalse: [ - stats addLast: date -> bag sortedCounts]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>oopCountsByAge (in category 'stats') ----- - oopCountsByAge - "Answer collection of (oopAge in seconds -> number of objects) sorted from lowest age" - "ObjectHistory current oopCountsByAge" - - | stats prev endOfMemory now n age obj | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - now := self newMark timestamp. - marks do: [:mark | - prev ifNotNil: [ - n := 0. - obj := prev objectAfter. - [obj == mark] whileFalse: [ - n := n + 1. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - age := (now - mark timestamp) asSeconds roundTo: self markRate. - stats addFirst: age -> n]. - prev := mark]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>reinitMarks (in category 'private') ----- - reinitMarks - marks := ObjectHistoryMark allInstances asOrderedCollection. - marks - ifEmpty: [marks add: self newMark] - ifNotEmpty: [ | prev | - prev := nil. - marks removeAllSuchThat: [:obj | - prev notNil and: [prev timestamp >= obj timestamp]]]. - ! Item was removed: - ----- Method: ObjectHistory>>restartMarkProcess (in category 'marking') ----- - restartMarkProcess - markProcess ifNotNil: [markProcess terminate]. - markProcess := [self markLoop] - forkAt: Processor systemBackgroundPriority - named: 'ObjectHistory''s markProcess'. - ! Item was removed: - ----- Method: ObjectHistory>>terminate (in category 'private') ----- - terminate - markProcess ifNotNil: - [markProcess terminate]! Item was removed: - ----- Method: ObjectHistory>>timestampOf: (in category 'queries') ----- - timestampOf: anObject - "Timestamp of anObject, or nil if too new" - | endOfMemory mark | - anObject class == SmallInteger ifTrue: [^nil]. - mark := anObject. - endOfMemory := Object new. - [mark class == ObjectHistoryMark] whileFalse: [ - mark := mark nextObject. - mark == endOfMemory ifTrue: [^nil]]. - ^mark timestamp! Item was removed: - Object subclass: #ObjectHistoryMark - instanceVariableNames: 'timestamp' - classVariableNames: '' - poolDictionaries: '' - category: 'System-Support'! - - !ObjectHistoryMark commentStamp: 'bf 11/7/2012 00:12' prior: 0! - An ObjectHistoryMark is a permanent mark in the object memory. It holds a timestamp. - - While the timestamp could be used directly as mark by ObjectHistory, it's conceivable that its format might change in the future, and we do not want the mark's relative position in memory to change (which would be the case if it was migrated to a new format). So we use a distinct object instead (and we protect it against accidental become-ing by overriding those methods).! Item was removed: - ----- Method: ObjectHistoryMark>>become: (in category 'mutating') ----- - become: otherObject - ^self error: 'marks need to stay fixed in the object memory'! Item was removed: - ----- Method: ObjectHistoryMark>>becomeForward: (in category 'mutating') ----- - becomeForward: otherObject - ^self error: 'marks need to stay fixed in the object memory'! Item was removed: - ----- Method: ObjectHistoryMark>>initialize (in category 'initialization') ----- - initialize - timestamp := DateAndTime now floor. - ! Item was removed: - ----- Method: ObjectHistoryMark>>objectAfter (in category 'accessing') ----- - objectAfter - "Answer the next object in memory after me and my timestamp" - | successor | - successor := self nextObject. - successor == timestamp - ifTrue: [successor := successor nextObject]. - ^ successor! Item was removed: - ----- Method: ObjectHistoryMark>>printOn: (in category 'printing') ----- - printOn: aStream - aStream - nextPutAll: self class name; - nextPut: $(; - print: timestamp; - nextPut: $)! Item was removed: - ----- Method: ObjectHistoryMark>>timestamp (in category 'accessing') ----- - timestamp - ^timestamp - ! Item was changed: ----- Method: SmalltalkImage>>compactClassesArray (in category 'special objects') ----- compactClassesArray "Smalltalk compactClassesArray" + "Backward-compatibility support. Spur does not have compact classes." + ^{}! - "Return the array of 31 classes whose instances may be - represented compactly" - ^ self specialObjectsArray at: 29! Item was added: + ----- Method: SmalltalkImage>>growMemoryByAtLeast: (in category 'memory space') ----- + growMemoryByAtLeast: numBytes + "Grow memory by at least the requested number of bytes. + Primitive. Essential. Fail if no memory is available." + + (numBytes isInteger and: [numBytes > 0]) ifTrue: + [OutOfMemory signal]. + ^self primitiveFailed! Item was added: + ----- Method: SmalltalkImage>>maxIdentityHash (in category 'system attributes') ----- + maxIdentityHash + "Answer the maximum identityHash value supported by the VM." + + ^self primitiveFailed! Item was changed: ----- Method: SmalltalkImage>>primBytesLeft (in category 'memory space') ----- primBytesLeft + "Primitive. Answer the number of free bytes available in old space. + Not accurate unless preceded by - "Primitive. Answer the number of bytes available for new object data. - Not accurate unless preceded by Smalltalk garbageCollectMost (for reasonable accuracy), or Smalltalk garbageCollect (for real accuracy). + See Object documentation whatIsAPrimitive." - See Object documentation whatIsAPrimitive." + ^0! - ^ 0! Item was changed: ----- Method: SmalltalkImage>>primitiveGarbageCollect (in category 'memory space') ----- primitiveGarbageCollect + "Primitive. Reclaims all garbage and answers the size of the largest free chunk in old space.." - "Primitive. Reclaims all garbage and answers the number of bytes of available space." + ^self primitiveFailed! - ^ self primBytesLeft! Item was changed: ----- Method: SmalltalkImage>>recreateSpecialObjectsArray (in category 'special objects') ----- recreateSpecialObjectsArray "Smalltalk recreateSpecialObjectsArray" "To external package developers: **** DO NOT OVERRIDE THIS METHOD. ***** If you are writing a plugin and need additional special object(s) for your own use, use addGCRoot() function and use own, separate special objects registry " "The Special Objects Array is an array of objects used by the Squeak virtual machine. Its contents are critical and accesses to it by the VM are unchecked, so don't even think of playing here unless you know what you are doing." | newArray | + newArray := Array new: 60. - newArray := Array new: 58. "Nil false and true get used throughout the interpreter" newArray at: 1 put: nil. newArray at: 2 put: false. newArray at: 3 put: true. "This association holds the active process (a ProcessScheduler)" newArray at: 4 put: (self specialObjectsArray at: 4) "(self bindingOf: #Processor) but it answers an Alias". "Numerous classes below used for type checking and instantiation" newArray at: 5 put: Bitmap. newArray at: 6 put: SmallInteger. newArray at: 7 put: ByteString. newArray at: 8 put: Array. newArray at: 9 put: Smalltalk. + newArray at: 10 put: BoxedFloat64. + newArray at: 11 put: (self globals at: #MethodContext ifAbsent: [self globals at: #Context]). + newArray at: 12 put: nil. "was BlockContext." - newArray at: 10 put: Float. - newArray at: 11 put: MethodContext. - newArray at: 12 put: BlockContext. newArray at: 13 put: Point. newArray at: 14 put: LargePositiveInteger. newArray at: 15 put: Display. newArray at: 16 put: Message. newArray at: 17 put: CompiledMethod. + newArray at: 18 put: ((self specialObjectsArray at: 18) ifNil: [Semaphore new]). "low space Semaphore" - newArray at: 18 put: (self specialObjectsArray at: 18). - "(low space Semaphore)" newArray at: 19 put: Semaphore. newArray at: 20 put: Character. newArray at: 21 put: #doesNotUnderstand:. newArray at: 22 put: #cannotReturn:. newArray at: 23 put: nil. "This is the process signalling low space." "An array of the 32 selectors that are compiled as special bytecodes, paired alternately with the number of arguments each takes." newArray at: 24 put: #( #+ 1 #- 1 #< 1 #> 1 #<= 1 #>= 1 #= 1 #~= 1 #* 1 #/ 1 #\\ 1 #@ 1 #bitShift: 1 #// 1 #bitAnd: 1 #bitOr: 1 #at: 1 #at:put: 2 #size 0 #next 0 #nextPut: 1 #atEnd 0 #== 1 #class 0 #blockCopy: 1 #value 0 #value: 1 #do: 1 #new 0 #new: 1 #x 0 #y 0 ). "An array of the 255 Characters in ascii order. + Cog inlines table into machine code at: prim so do not regenerate it. + This is nil in Spur, which has immediate Characters." - Cog inlines table into machine code at: prim so do not regenerate it." newArray at: 25 put: (self specialObjectsArray at: 25). newArray at: 26 put: #mustBeBoolean. newArray at: 27 put: ByteArray. newArray at: 28 put: Process. + "An array of up to 31 classes whose instances will have compact headers; an empty array in Spur" - "An array of up to 31 classes whose instances will have compact headers" newArray at: 29 put: self compactClassesArray. + newArray at: 30 put: ((self specialObjectsArray at: 30) ifNil: [Semaphore new]). "delay Semaphore" + newArray at: 31 put: ((self specialObjectsArray at: 31) ifNil: [Semaphore new]). "user interrupt Semaphore" - newArray at: 30 put: (self specialObjectsArray at: 30). "(delay Semaphore)" - newArray at: 31 put: (self specialObjectsArray at: 31). "(user interrupt Semaphore)" "Entries 32 - 34 unreferenced. Previously these contained prototype instances to be copied for fast initialization" + newArray at: 32 put: nil. "was the prototype Float" + newArray at: 33 put: nil. "was the prototype 4-byte LargePositiveInteger" + newArray at: 34 put: nil. "was the prototype Point" - newArray at: 32 put: nil. "was (Float new: 2)" - newArray at: 33 put: nil. "was (LargePositiveInteger new: 4)" - newArray at: 34 put: nil. "was Point new" newArray at: 35 put: #cannotInterpret:. + newArray at: 36 put: nil. "was the prototype MethodContext" - "Note: This must be fixed once we start using context prototypes (yeah, right)" - "(MethodContext new: CompiledMethod fullFrameSize)." - newArray at: 36 put: (self specialObjectsArray at: 36). "Is the prototype MethodContext (unused by the VM)" newArray at: 37 put: BlockClosure. + newArray at: 38 put: nil. "was the prototype BlockContext" - "(BlockContext new: CompiledMethod fullFrameSize)." - newArray at: 38 put: (self specialObjectsArray at: 38). "Is the prototype BlockContext (unused by the VM)" "array of objects referred to by external code" + newArray at: 39 put: (self specialObjectsArray at: 39). "external semaphores" - newArray at: 39 put: (self specialObjectsArray at: 39). "preserve external semaphores" newArray at: 40 put: nil. "Reserved for Mutex in Cog VMs" + newArray at: 41 put: ((self specialObjectsArray at: 41) ifNil: [LinkedList new]). "Reserved for a LinkedList instance for overlapped calls in CogMT" + newArray at: 42 put: ((self specialObjectsArray at: 42) ifNil: [Semaphore new]). "finalization Semaphore" - newArray at: 41 put: nil. "Reserved for a LinkedList instance for overlapped calls in CogMT" - "finalization Semaphore" - newArray at: 42 put: ((self specialObjectsArray at: 42) ifNil: [Semaphore new]). newArray at: 43 put: LargeNegativeInteger. "External objects for callout. Note: Written so that one can actually completely remove the FFI." newArray at: 44 put: (self at: #ExternalAddress ifAbsent: []). newArray at: 45 put: (self at: #ExternalStructure ifAbsent: []). newArray at: 46 put: (self at: #ExternalData ifAbsent: []). newArray at: 47 put: (self at: #ExternalFunction ifAbsent: []). newArray at: 48 put: (self at: #ExternalLibrary ifAbsent: []). newArray at: 49 put: #aboutToReturn:through:. newArray at: 50 put: #run:with:in:. "51 reserved for immutability message" + newArray at: 51 put: #attemptToAssign:withIndex:. - "newArray at: 51 put: #attemptToAssign:withIndex:." - newArray at: 51 put: (self specialObjectsArray at: 51 ifAbsent: []). newArray at: 52 put: #(nil "nil => generic error" #'bad receiver' #'bad argument' #'bad index' #'bad number of arguments' #'inappropriate operation' #'unsupported operation' #'no modification' #'insufficient object memory' #'insufficient C memory' #'not found' #'bad method' #'internal error in named primitive machinery' #'object may move' #'resource limit exceeded' + #'object is pinned' #'primitive write beyond end of object'). - #'object is pinned'). "53 to 55 are for Alien" newArray at: 53 put: (self at: #Alien ifAbsent: []). + newArray at: 54 put: #invokeCallbackContext:. "use invokeCallback:stack:registers:jmpbuf: for old Alien callbacks." - newArray at: 54 put: #invokeCallbackContext::. "use invokeCallback:stack:registers:jmpbuf: for old Alien callbacks." newArray at: 55 put: (self at: #UnsafeAlien ifAbsent: []). + "Used to be WeakFinalizationList for WeakFinalizationList hasNewFinalization, obsoleted by ephemeron support." + newArray at: 56 put: nil. - "Weak reference finalization" - newArray at: 56 put: (self at: #WeakFinalizationList ifAbsent: []). "reserved for foreign callback process" newArray at: 57 put: (self specialObjectsArray at: 57 ifAbsent: []). newArray at: 58 put: #unusedBytecode. + "59 reserved for Sista counter tripped message" + newArray at: 59 put: #conditionalBranchCounterTrippedOn:. + "60 reserved for Sista class trap message" + newArray at: 60 put: #classTrapFor:. "Now replace the interpreter's reference in one atomic operation" + self specialObjectsArray becomeForward: newArray! - self specialObjectsArray becomeForward: newArray - ! Item was changed: ----- Method: SmalltalkImage>>setGCParameters (in category 'snapshot and quit') ----- setGCParameters + "Adjust the VM's default GC parameters to avoid too much tenuring. + Maybe this should be left to the VM?" - "Adjust the VM's default GC parameters to avoid premature tenuring." + | proportion edenSize survivorSize averageObjectSize numObjects | + proportion := 0.9. "tenure when 90% of pastSpace is full" + edenSize := SmalltalkImage current vmParameterAt: 44. + survivorSize := edenSize / 5.0. "David's paper uses 140Kb eden + 2 x 28kb survivor spaces; Spur uses the same ratios :-)" + averageObjectSize := 8 * self wordSize. "a good approximation" + numObjects := (proportion * survivorSize / averageObjectSize) rounded. + SmalltalkImage current vmParameterAt: 6 put: numObjects "tenure when more than this many objects survive the GC"! - self vmParameterAt: 5 put: 4000. "do an incremental GC after this many allocations" - self vmParameterAt: 6 put: 2000. "tenure when more than this many objects survive the GC" - ! Item was changed: ----- Method: SpaceTally>>spaceForInstancesOf: (in category 'instance size') ----- spaceForInstancesOf: aClass + "Answer a pair of the number of bytes consumed by all instances of the + given class, including their object headers, and the number of instances." - "Answer the number of bytes consumed by all instances of the given class, including their object headers and the number of instances." + | instances total | + instances := aClass allInstances. + instances isEmpty ifTrue: [^#(0 0)]. - | smallHeaderSize instVarBytes isVariable bytesPerElement total lastInstance instance instanceCount | - instance := aClass someInstance ifNil: [ ^#(0 0) ]. - smallHeaderSize := aClass isCompact ifTrue: [ 4 ] ifFalse: [ 8 ]. - instVarBytes := aClass instSize * 4. - isVariable := aClass isVariable. - bytesPerElement := isVariable - ifFalse: [ 0 ] - ifTrue: [ aClass isBytes ifTrue: [ 1 ] ifFalse: [ 4 ] ]. total := 0. + aClass isVariable + ifTrue: + [instances do: + [:i| total := total + (aClass byteSizeOfInstanceOfSize: i basicSize)]] + ifFalse: + [total := instances size * aClass byteSizeOfInstance]. + ^{ total. instances size }! - instanceCount := 0. - "A modified version of #allInstancesDo: is inlined here. It avoids an infinite loop when another process is creating new instances of aClass." - self flag: #allInstancesDo:. - lastInstance := - aClass == CompiledMethod "CompiledMethod has special format, see its class comment" - ifTrue: [aClass new] - ifFalse: [aClass basicNew]. - [ instance == lastInstance ] whileFalse: [ - | contentBytes headerBytes | - contentBytes := instVarBytes + (isVariable - ifFalse: [ 0 ] - ifTrue: [ instance basicSize * bytesPerElement ]). - headerBytes := contentBytes > 255 - ifTrue: [ 12 ] - ifFalse: [ smallHeaderSize ]. - total := total + headerBytes + (contentBytes roundUpTo: 4). - instanceCount := instanceCount + 1. - instance := instance nextInstance ]. - ^{ total. instanceCount }! Item was added: + ----- Method: SystemDictionary>>growMemoryByAtLeast: (in category 'memory space') ----- + growMemoryByAtLeast: numBytes + "Grow memory by at least the requested number of bytes. + Primitive. Fail if no memory is available. Essential." + + ^(numBytes isInteger and: [numBytes > 0]) + ifTrue: [OutOfMemory signal] + ifFalse: [self primitiveFailed]! Item was added: + ----- Method: SystemDictionary>>maxIdentityHash (in category 'system attributes') ----- + maxIdentityHash + "Answer the maximum identityHash value supported by the VM." + + ^self primitiveFailed! Item was added: + ----- Method: SystemDictionary>>setGCParameters (in category 'snapshot and quit') ----- + setGCParameters + "Adjust the VM's default GC parameters to avoid too much tenuring. + Maybe this should be left to the VM?" + + | proportion edenSize survivorSize averageObjectSize numObjects | + proportion := 0.9. "tenure when 90% of pastSpace is full" + edenSize := SmalltalkImage current vmParameterAt: 44. + survivorSize := edenSize / 5.0. "David's paper uses 140Kb eden + 2 x 28kb survivor spaces; Spur uses the same ratios :-)" + averageObjectSize := 8 * self wordSize. "a good approximation" + numObjects := (proportion * survivorSize / averageObjectSize) rounded. + SmalltalkImage current vmParameterAt: 6 put: numObjects "tenure when more than this many objects survive the GC"! Item was added: + ----- Method: SystemNavigation>>allObjects (in category 'query') ----- + allObjects + "Answer an Array of all objects in the system. Fail if + there isn't enough memory to instantiate the result." + + ^self primitiveFailed! Item was changed: ----- Method: SystemNavigation>>allObjectsDo: (in category 'query') ----- allObjectsDo: aBlock + "Evaluate the argument, aBlock, for each object in the system, excluding immediates + such as SmallInteger and Character." + self allObjectsOrNil + ifNotNil: [:allObjects| allObjects do: aBlock] + ifNil: + ["Fall back on the old single object primitive code. With closures, this needs + to use an end marker (lastObject) since activation of the block will create + new contexts and cause an infinite loop. The lastObject must be created + before calling someObject, so that the VM can settle the enumeration (e.g. + by flushing new space) as a side effect of someObject" + | object lastObject | + lastObject := Object new. + object := self someObject. + [lastObject == object or: [0 == object]] whileFalse: + [aBlock value: object. + object := object nextObject]]! - "Evaluate the argument, aBlock, for each object in the system - excluding SmallIntegers. With closures, this needs to use an end - marker (lastObject) since activation of the block will create new - contexts and cause an infinite loop." - | object lastObject | - object := self someObject. - lastObject := Object new. - [lastObject == object or: [0 == object]] - whileFalse: [aBlock value: object. - object := object nextObject]! Item was added: + ----- Method: SystemNavigation>>allObjectsOrNil (in category 'query') ----- + allObjectsOrNil + "Answer an Array of all objects in the system. Fail if there isn't + enough memory to instantiate the result and answer nil." + + ^nil! From eliot.miranda at gmail.com Wed Apr 8 17:50:11 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Wed Apr 8 17:50:13 2015 Subject: [squeak-dev] The Trunk: EToys-topa.123.mcz In-Reply-To: References: <176850F4-FC78-4F9E-9A70-1C585194F146@gmail.com> Message-ID: On Wed, Apr 8, 2015 at 1:09 AM, Tobias Pape wrote: > Hi Eliot > > On 08.04.2015, at 09:56, Eliot Miranda wrote: > > > Hi Tobias, > > > > hasClassNamed: and symbols are to be preferred to avoid the cost of > interning. > > I don't quite understand that. When I use a symbol, it already has been > interned, > either during method-compilation or because I created it. How is interning > avoided here? > I thought this was the very reason to not pass a Symbol to hasClassNamed? > What about its sibling classNamed: (or classOrTraitNamed:)? > > > The class name keys are, as they should be, symbols, and we don't want > to pay the cost of interning to do that lookup. And I agree with Levente > that symbols are searched for when SystemNavigation is used to find such > soft class references. > > Right, I did not argue against that :) > I misunderstood. So this discussion is just about the argument name? In any case I'm with Bert for using symbols to refer to class names whereever possible. > > > Your string position is understandable but needlessly expensive. The > use of symbols (and the assumption that they're strings) is simple and > efficient. > > Don't get me wrong, I think that this assumption is worthwhile in (at > least) > Core Squeak, yes. > > Best > -Tobias :) > > > > > Eliot (phone) > > > > On Apr 7, 2015, at 8:21 AM, Tobias Pape wrote: > > > >> > >> On 07.04.2015, at 17:16, Levente Uzonyi wrote: > >> > >>> What's wrong with #hasClassNamed:? > >> > >> From my POV, it takes a String, and we wanted a symbol here ;) > >> Also, I wanted t be conisten with #setUP > >> > >>> > >>> Levente > >>> > >>> On Tue, 7 Apr 2015, commits@source.squeak.org wrote: > >>> > >>>> Tobias Pape uploaded a new version of EToys to project The Trunk: > >>>> http://source.squeak.org/trunk/EToys-topa.123.mcz > >>>> > >>>> ==================== Summary ==================== > >>>> > >>>> Name: EToys-topa.123 > >>>> Author: topa > >>>> Time: 7 April 2015, 2:37:32.593 pm > >>>> UUID: 71b565ae-57ad-4d33-91d2-d6bfeec75490 > >>>> Ancestors: EToys-topa.122 > >>>> > >>>> the ifPresent: part needs a block argument > >>>> > >>>> =============== Diff against EToys-topa.122 =============== > >>>> > >>>> Item was changed: > >>>> ----- Method: TileMorphTest>>expectedFailures (in category 'testing') > ----- > >>>> expectedFailures > >>>> > >>>> ^ super expectedFailures, > >>>> (self class environment > >>>> at: #BaseSoundSystem > >>>> + ifPresent: [:e| #()] > >>>> - ifPresent: [#()] > >>>> ifAbsent: [#(testSoundTile) "Only this test depends on > Sound"])! > > > > -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150408/1eccfb7d/attachment.htm From karlramberg at gmail.com Wed Apr 8 18:02:54 2015 From: karlramberg at gmail.com (karl ramberg) Date: Wed Apr 8 18:02:57 2015 Subject: [squeak-dev] vm crash from BalloonEngine (maybe B2DPlugin or BitBltPlugin) In-Reply-To: References: Message-ID: Confirmed. Karl On Wed, Apr 8, 2015 at 5:33 PM, Nicolai Hess wrote: > In order to reproduce it, draw a rectangle with radial gradient fill, with > direction > and normal, both of length 1. > > This one works (no vm crash): > |form canvas fill direction normal| > direction := 1@0. > normal := 0@0. > form := Form extent:300@300 depth:32. > canvas := form getCanvas. > fill := GradientFillStyle new colorRamp:{0 -> Color white . 0.5 -> Color > green . 1 -> Color blue};origin:150@150 > ;direction:direction;normal:normal;radial:true;yourself. > canvas fillRectangle: (50@50 extent:200@200) fillStyle: fill. > Display getCanvas drawImage: form at: 300@300. > > > direction := 1@0. > normal := 0@0. > -> OK > > direction := 0@0. > normal := 0@1. > -> OK > > direction := 1@0. > normal := 0@1. > -> VM-Crash (Pharo and Squeak) > > Pharo: > VM Version: Cog VM 4.0.0 (release) from Feb 16 2015 > Compiler: gcc 4.6.2 > Interpreter Build: NBCoInterpreter > NativeBoost-CogPlugin-EstebanLorenzano.21 uuid: > 4d9b9bdf-2dfa-4c0b-99eb-5b110dadc697 Feb 16 2015 > Cogit Build: NBCogit NativeBoost-CogPlugin-EstebanLorenzano.21 uuid: > 4d9b9bdf-2dfa-4c0b-99eb-5b110dadc697 Feb 16 2015 > Source Version: https://github.com/pharo-project/pharo-vm.git Commit: > 55fbd0b0279998a4a33852f5afb3d213986cc3ae Date: 2015-02-16 17:54:00 +0100 > By: Esteban Lorenzano Jenkins build #14895 > > Current byte code: -1 > Primitive index: 117 > Smalltalk stack dump: > 0x24c830 M BalloonEngine>copyLoopFaster 0x6b09b80: a(n) BalloonEngine > 0x24c848 M BalloonEngine>copyBits 0x6b09b80: a(n) BalloonEngine > 0x24c860 M BalloonEngine>postFlushIfNeeded 0x6b09b80: a(n) BalloonEngine > 0x24c884 I > BalloonEngine>drawRectangle:fill:borderWidth:borderColor:transform: > 0x6b09b80: a(n) BalloonEngine > 0x24c8b8 I BalloonCanvas>drawRectangle:color:borderWidth:borderColor: > 0x6b099c0: a(n) BalloonCanvas > 0x24c8e8 I BalloonCanvas>fillRectangle:basicFillStyle: 0x6b099c0: a(n) > BalloonCanvas > > > Squeak: > VM Version: Cog VM 4.0.0 (release) from Aug 22 2013 > Compiler: gcc 3.4.4 (cygming special, gdc 0.12, using dmd 0.125) > Interpreter Build: CoInterpreter VMMaker.oscog-eem.331 uuid: > 37d2e4b0-2f37-4e2d-8313-c63637785e59 Aug 22 2013 > Cogit Build: StackToRegisterMappingCogit VMMaker.oscog-eem.333 uuid: > 84da9cb8-7f30-4cb7-b4fb-239a11f63b54 Aug 22 2013 > Source Version: VM: r2776 http://www.squeakvm.org/svn/squeak/branches/Cog > Plugins: r2545 > http://squeakvm.org/svn/squeak/trunk/platforms/Cross/plugins > > Current byte code: -1 > Primitive index: 117 > > > nicolai > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150408/f9ef0d04/attachment.htm From eliot.miranda at gmail.com Wed Apr 8 18:06:47 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Wed Apr 8 18:06:49 2015 Subject: [squeak-dev] Can we get Squeak green for the release? In-Reply-To: <54C3EEC4-FA57-4D37-954C-D5B6F98A2393@gmx.de> References: <54C3EEC4-FA57-4D37-954C-D5B6F98A2393@gmx.de> Message-ID: Hi Tobias, On Tue, Apr 7, 2015 at 5:30 AM, Tobias Pape wrote: > Hi > > > On 04.04.2015, at 16:59, Frank Shearar wrote: > > > On 3 April 2015 at 16:27, Tobias Pape wrote: > >> Hey > >> > >> I am watching the CI doing its work as changes and fixes > >> chime in. > >> I noticed that there are still 13 test failing[1] and I'm > >> not sure how all of them should be fixed :) > >> Let's make it green! > > > > I am _very very happy_ to see someone other than me harping on about > > tests! Please carry on! > > > > This one ought to be easy to fix: it's a small breakage in the > > modularity of the image; some methods need to be recategorised as not > > being System: > http://build.squeak.org/job/SqueakTrunk/1207/testReport/Tests.Dependencies/PackageDependencyTest/testSystem/ > > > > This one too: > http://build.squeak.org/job/SqueakTrunk/1207/testReport/Tests.Dependencies/PackageDependencyTest/testTools/ > > (Tools shouldn't depend on _ToolBuilder-Morphic_, even though it would > > be OK to depend on ToolBuilder.) > > > > And I love that this one fails - > > > http://build.squeak.org/job/SqueakTrunk/1207/testReport/Tests.Dependencies/PackageDependencyTest/testMultilingual/ > > - Multilingual no longer depends on TrueType, and our system just got > > one dependency cleaner. > > I did some things :) > > But I need help: > There's a strange thing in the decompiler/compiler: > > > http://build.squeak.org/job/SqueakTrunk/lastCompletedBuild/testReport/Tests.Compiler/DecompilerTests/testDecompilerInClassesBAtoBM/ > > Somewhere in Behavior>>#toolIconSelector:, > a sequence of 'push nil. pop' is generated that is decompiled as 'nil.'. > Can you mail the symbolic output that shows the bytecode please? SOmetimes the COmpiler is changed but the system is not recompiled, and hence bytecode can be obsolete. I don't think we should bother to fix the decompiler for these cases. But we should remember to do a recompile all at some stage, either before a release or whenever a change to the compiler is made that would change generated code. > This does not match the source and I don't know whether it's a bug in > the Compiler emitting this or the Decompiler not recognizing the emitted > pattern. > So what happens if you recompile the method? Is the push nil, pop sequence still there? > Best > -Tobias > > > -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150408/0a0b6d46/attachment.htm From eliot.miranda at gmail.com Wed Apr 8 18:11:27 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Wed Apr 8 18:11:30 2015 Subject: [squeak-dev] Can we get Squeak green for the release? In-Reply-To: References: <54C3EEC4-FA57-4D37-954C-D5B6F98A2393@gmx.de> Message-ID: On Tue, Apr 7, 2015 at 7:39 AM, Levente Uzonyi wrote: > The decompiler is not perfect, and IIRC someone stated that it will never > be. Most of these errors are "handled" by adding them as exceptions, so > they are not tested. Some of these issues are probably fixable, but not > many people are familiar with the decompiler. > See DecompilerTests >> #decompilerFailures for the list of currently > ignored methods. > > Levente > > > On Tue, 7 Apr 2015, Tobias Pape wrote: > > Hi >> >> >> On 04.04.2015, at 16:59, Frank Shearar wrote: >> >> On 3 April 2015 at 16:27, Tobias Pape wrote: >>> >>>> Hey >>>> >>>> I am watching the CI doing its work as changes and fixes >>>> chime in. >>>> I noticed that there are still 13 test failing[1] and I'm >>>> not sure how all of them should be fixed :) >>>> Let's make it green! >>>> >>> >>> I am _very very happy_ to see someone other than me harping on about >>> tests! Please carry on! >>> >>> This one ought to be easy to fix: it's a small breakage in the >>> modularity of the image; some methods need to be recategorised as not >>> being System: http://build.squeak.org/job/SqueakTrunk/1207/testReport/ >>> Tests.Dependencies/PackageDependencyTest/testSystem/ >>> >>> This one too: http://build.squeak.org/job/SqueakTrunk/1207/testReport/ >>> Tests.Dependencies/PackageDependencyTest/testTools/ >>> (Tools shouldn't depend on _ToolBuilder-Morphic_, even though it would >>> be OK to depend on ToolBuilder.) >>> >>> And I love that this one fails - >>> http://build.squeak.org/job/SqueakTrunk/1207/testReport/ >>> Tests.Dependencies/PackageDependencyTest/testMultilingual/ >>> - Multilingual no longer depends on TrueType, and our system just got >>> one dependency cleaner. >>> >> >> I did some things :) >> >> But I need help: >> There's a strange thing in the decompiler/compiler: >> >> http://build.squeak.org/job/SqueakTrunk/lastCompletedBuild/testReport/ >> Tests.Compiler/DecompilerTests/testDecompilerInClassesBAtoBM/ >> >> Somewhere in Behavior>>#toolIconSelector:, >> a sequence of 'push nil. pop' is generated that is decompiled as 'nil.'. >> This does not match the source and I don't know whether it's a bug in >> the Compiler emitting this or the Decompiler not recognizing the emitted >> pattern. >> > Ah, I see it. Look the end of this block: self methodDictionary at: aSymbol ifPresent: [ :method | ... method hasReportableSlip ifTrue: [^ #breakpoint]]. The block (correctly) answers nil if method hasReportableSlip is false, and the bytecode contains a pushConstant: nil; blockReturn sequence to implement this. So the problem is with the decompiler not eliminating the explicit nil node in this case where it should be implicit. HTH -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150408/23cff793/attachment.htm From commits at source.squeak.org Wed Apr 8 18:27:11 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 8 18:27:12 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.842.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.842.mcz ==================== Summary ==================== Name: Morphic-mt.842 Author: mt Time: 8 April 2015, 8:26:35.712 pm UUID: 69b4e9ef-0563-9748-a5bf-fe69528f37b8 Ancestors: Morphic-mt.841 Made Slider more pluggable and thus removed PluggableSliderMorph from the system. The code that was not moved upwards into Slider was moved downwards into its sole subclass: BracketSliderMorph. It was verified that the "new color picker morph", which is the sole user of that BracketSliderMorph, stays functional. Why? The Slider should support custom min/max values whenever the default (floats with 0.0 to 1.0) is not appropriate. Truncation is supported, too. Everything was already present in the (removed) PluggableSliderMorph, but we need that behavior in ScrollBar. Note: There is still the SimpleSliderMorph, which duplicates some behavior of Slider but is a base class of slider. E-Toys uses it. We may want to remove that duplicated code later. =============== Diff against Morphic-mt.841 =============== Item was changed: + Slider subclass: #BracketSliderMorph + instanceVariableNames: 'getEnabledSelector enabled' - PluggableSliderMorph subclass: #BracketSliderMorph - instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'Morphic-Widgets'! !BracketSliderMorph commentStamp: 'gvc 5/18/2007 13:39' prior: 0! Abstract superclass for morphs that are used to select a component (R, G, B or A) of a colour.! Item was added: + ----- Method: BracketSliderMorph>>adoptPaneColor: (in category 'accessing - ui') ----- + adoptPaneColor: paneColor + "Pass on to the border too." + super adoptPaneColor: paneColor. + paneColor ifNil: [ ^ self ]. + self + fillStyle: self fillStyleToUse ; + borderStyle: + (BorderStyle inset + width: 1 ; + baseColor: self color twiceDarker) ; + sliderColor: + (self enabled + ifTrue: [ paneColor twiceDarker ] + ifFalse: [ self paneColor twiceDarker paler ])! Item was added: + ----- Method: BracketSliderMorph>>borderStyleToUse (in category 'accessing - ui') ----- + borderStyleToUse + "Answer the borderStyle that should be used for the receiver." + + ^self enabled + ifTrue: [self theme sliderNormalBorderStyleFor: self] + ifFalse: [self theme sliderDisabledBorderStyleFor: self]! Item was added: + ----- Method: BracketSliderMorph>>defaultColor (in category 'accessing - ui') ----- + defaultColor + "Answer the default color/fill style for the receiver." + + ^Color white! Item was changed: + ----- Method: BracketSliderMorph>>defaultFillStyle (in category 'accessing - ui') ----- - ----- Method: BracketSliderMorph>>defaultFillStyle (in category 'as yet unclassified') ----- defaultFillStyle "Answer the defauolt fill style." ^Color gray! Item was added: + ----- Method: BracketSliderMorph>>disable (in category 'as yet unclassified') ----- + disable + "Disable the receiver." + + self enabled: false! Item was added: + ----- Method: BracketSliderMorph>>enable (in category 'as yet unclassified') ----- + enable + "Enable the receiver." + + self enabled: true! Item was added: + ----- Method: BracketSliderMorph>>enabled (in category 'accessing') ----- + enabled + "Answer the value of enabled" + + ^ enabled! Item was added: + ----- Method: BracketSliderMorph>>enabled: (in category 'accessing') ----- + enabled: anObject + "Set the value of enabled" + + enabled = anObject ifTrue: [^self]. + enabled := anObject. + self changed: #enabled. + self + adoptPaneColor: self color; + changed! Item was changed: + ----- Method: BracketSliderMorph>>extent: (in category 'geometry') ----- - ----- Method: BracketSliderMorph>>extent: (in category 'as yet unclassified') ----- extent: aPoint "Update the gradient directions." super extent: aPoint. self updateFillStyle! Item was changed: + ----- Method: BracketSliderMorph>>fillStyleToUse (in category 'accessing - ui') ----- - ----- Method: BracketSliderMorph>>fillStyleToUse (in category 'as yet unclassified') ----- fillStyleToUse "Answer the fillStyle that should be used for the receiver." ^self fillStyle! Item was added: + ----- Method: BracketSliderMorph>>getEnabledSelector (in category 'accessing') ----- + getEnabledSelector + "Answer the value of getEnabledSelector" + + ^ getEnabledSelector! Item was added: + ----- Method: BracketSliderMorph>>getEnabledSelector: (in category 'accessing') ----- + getEnabledSelector: aSymbol + "Set the value of getEnabledSelector" + + getEnabledSelector := aSymbol. + self updateEnabled! Item was changed: + ----- Method: BracketSliderMorph>>gradient (in category 'accessing - ui') ----- - ----- Method: BracketSliderMorph>>gradient (in category 'as yet unclassified') ----- gradient "Answer the gradient." self subclassResponsibility! Item was added: + ----- Method: BracketSliderMorph>>handlesMouseDown: (in category 'event handling') ----- + handlesMouseDown: evt + "Answer true." + + ^true! Item was changed: + ----- Method: BracketSliderMorph>>initialize (in category 'initialization') ----- - ----- Method: BracketSliderMorph>>initialize (in category 'as yet unclassified') ----- initialize "Initialize the receiver." super initialize. self + enabled: true; fillStyle: self defaultFillStyle; borderStyle: (BorderStyle inset baseColor: self color; width: 1); sliderColor: Color black; clipSubmorphs: true! Item was changed: + ----- Method: BracketSliderMorph>>initializeSlider (in category 'initialization') ----- - ----- Method: BracketSliderMorph>>initializeSlider (in category 'as yet unclassified') ----- initializeSlider "Make the slider raised." slider :=( BracketMorph newBounds: self totalSliderArea) horizontal: self bounds isWide; color: self thumbColor; borderStyle: (BorderStyle raised baseColor: Color white; width: 1). sliderShadow := (BracketMorph newBounds: self totalSliderArea) horizontal: self bounds isWide; color: self pagingArea color; borderStyle: (BorderStyle inset baseColor: (Color white alpha: 0.6); width: 1). slider on: #mouseMove send: #scrollAbsolute: to: self. slider on: #mouseDown send: #mouseDownInSlider: to: self. slider on: #mouseUp send: #mouseUpInSlider: to: self. "(the shadow must have the pagingArea as its owner to highlight properly)" self pagingArea addMorph: sliderShadow. sliderShadow hide. self addMorph: slider. self computeSlider. ! Item was changed: + ----- Method: BracketSliderMorph>>layoutBounds: (in category 'layout') ----- - ----- Method: BracketSliderMorph>>layoutBounds: (in category 'as yet unclassified') ----- layoutBounds: aRectangle "Set the bounds for laying out children of the receiver. Note: written so that #layoutBounds can be changed without touching this method" super layoutBounds: aRectangle. + self computeSlider! - self updateFillStyle. - slider horizontal: self bounds isWide. - sliderShadow horizontal: self bounds isWide! Item was added: + ----- Method: BracketSliderMorph>>minHeight (in category 'layout') ----- + minHeight + "Answer the receiver's minimum height. + Give it a bit of a chance..." + + ^8 max: super minHeight! Item was added: + ----- Method: BracketSliderMorph>>mouseDown: (in category 'event handling') ----- + mouseDown: anEvent + "Set the value directly." + + self enabled ifTrue: [ + self + scrollPoint: anEvent; + computeSlider]. + super mouseDown: anEvent. + self enabled ifFalse: [^self]. + anEvent hand newMouseFocus: slider event: anEvent. + slider + mouseEnter: anEvent copy; + mouseDown: anEvent copy + ! Item was added: + ----- Method: BracketSliderMorph>>mouseDownInSlider: (in category 'other events') ----- + mouseDownInSlider: event + "Ignore if disabled." + + self enabled ifFalse: [^self]. + ^super mouseDownInSlider: event! Item was changed: + ----- Method: BracketSliderMorph>>roomToMove (in category 'geometry') ----- - ----- Method: BracketSliderMorph>>roomToMove (in category 'as yet unclassified') ----- roomToMove "Allow to run off the edges a bit." ^self bounds isWide ifTrue: [self totalSliderArea insetBy: ((self sliderThickness // 2@0) negated corner: (self sliderThickness // 2 + 1)@0)] ifFalse: [self totalSliderArea insetBy: (0@(self sliderThickness // 2) negated corner: 0@(self sliderThickness // 2 - (self sliderThickness \\ 2) + 1))]! Item was added: + ----- Method: BracketSliderMorph>>scrollAbsolute: (in category 'scrolling') ----- + scrollAbsolute: event + "Ignore if disabled." + + self enabled ifFalse: [^self]. + ^super scrollAbsolute: event! Item was added: + ----- Method: BracketSliderMorph>>scrollPoint: (in category 'event handling') ----- + scrollPoint: event + "Scroll to the event position." + + | r p | + r := self roomToMove. + bounds isWide + ifTrue: [r width = 0 ifTrue: [^ self]] + ifFalse: [r height = 0 ifTrue: [^ self]]. + p := event position - (self sliderThickness // 2) adhereTo: r. + self descending + ifFalse: + [self setValue: (bounds isWide + ifTrue: [(p x - r left) asFloat / r width] + ifFalse: [(p y - r top) asFloat / r height])] + ifTrue: + [self setValue: (bounds isWide + ifTrue: [(r right - p x) asFloat / r width] + ifFalse: [(r bottom - p y) asFloat / r height])]! Item was changed: + ----- Method: BracketSliderMorph>>sliderColor: (in category 'accessing - ui') ----- - ----- Method: BracketSliderMorph>>sliderColor: (in category 'as yet unclassified') ----- sliderColor: newColor "Set the slider colour." super sliderColor: (self enabled ifTrue: [Color black] ifFalse: [self sliderShadowColor]). slider ifNotNil: [slider borderStyle baseColor: Color white]! Item was changed: + ----- Method: BracketSliderMorph>>sliderShadowColor (in category 'accessing - ui') ----- - ----- Method: BracketSliderMorph>>sliderShadowColor (in category 'as yet unclassified') ----- sliderShadowColor "Answer the color for the slider shadow." ^Color black alpha: 0.6! Item was changed: + ----- Method: BracketSliderMorph>>sliderThickness (in category 'geometry') ----- - ----- Method: BracketSliderMorph>>sliderThickness (in category 'as yet unclassified') ----- sliderThickness "Answer the thickness of the slider." ^((self bounds isWide ifTrue: [self height] ifFalse: [self width]) // 2 max: 8) // 2 * 2 + 1! Item was added: + ----- Method: BracketSliderMorph>>update: (in category 'updating') ----- + update: aSymbol + "Update the value." + + super update: aSymbol. + aSymbol == self getEnabledSelector ifTrue: [ + ^self updateEnabled].! Item was added: + ----- Method: BracketSliderMorph>>updateEnabled (in category 'testing') ----- + updateEnabled + "Update the enablement state." + + self model ifNotNil: [ + self getEnabledSelector ifNotNil: [ + self enabled: (self model perform: self getEnabledSelector)]]! Item was changed: + ----- Method: BracketSliderMorph>>updateFillStyle (in category 'initialization') ----- - ----- Method: BracketSliderMorph>>updateFillStyle (in category 'as yet unclassified') ----- updateFillStyle "Update the fill style directions." |b fs| fs := self fillStyle. fs isOrientedFill ifTrue: [ b := self innerBounds. fs origin: b topLeft. fs direction: (b isWide ifTrue: [b width@0] ifFalse: [0@b height])]! Item was removed: - Slider subclass: #PluggableSliderMorph - instanceVariableNames: 'getValueSelector getEnabledSelector enabled min max quantum' - classVariableNames: '' - poolDictionaries: '' - category: 'Morphic-Widgets'! - - !PluggableSliderMorph commentStamp: 'gvc 7/16/2007 13:57' prior: 0! - A pluggable slider (rather than one that auto-generates access selectors). Needs to be themed...! Item was removed: - ----- Method: PluggableSliderMorph class>>on:getValue:setValue: (in category 'as yet unclassified') ----- - on: anObject getValue: getSel setValue: setSel - "Answer a new instance of the receiver with - the given selectors as the interface." - - ^self new - on: anObject - getValue: getSel - setValue: setSel! Item was removed: - ----- Method: PluggableSliderMorph class>>on:getValue:setValue:min:max:quantum: (in category 'as yet unclassified') ----- - on: anObject getValue: getSel setValue: setSel min: min max: max quantum: quantum - "Answer a new instance of the receiver with - the given selectors as the interface." - - ^self new - min: min; - max: max; - quantum: quantum; - on: anObject - getValue: getSel - setValue: setSel! Item was removed: - ----- Method: PluggableSliderMorph>>adoptPaneColor: (in category 'as yet unclassified') ----- - adoptPaneColor: paneColor - "Pass on to the border too." - super adoptPaneColor: paneColor. - paneColor ifNil: [ ^ self ]. - self - fillStyle: self fillStyleToUse ; - borderStyle: - (BorderStyle inset - width: 1 ; - baseColor: self color twiceDarker) ; - sliderColor: - (self enabled - ifTrue: [ paneColor twiceDarker ] - ifFalse: [ self paneColor twiceDarker paler ])! Item was removed: - ----- Method: PluggableSliderMorph>>borderStyleToUse (in category 'as yet unclassified') ----- - borderStyleToUse - "Answer the borderStyle that should be used for the receiver." - - ^self enabled - ifTrue: [self theme sliderNormalBorderStyleFor: self] - ifFalse: [self theme sliderDisabledBorderStyleFor: self]! Item was removed: - ----- Method: PluggableSliderMorph>>defaultColor (in category 'as yet unclassified') ----- - defaultColor - "Answer the default color/fill style for the receiver." - - ^Color white! Item was removed: - ----- Method: PluggableSliderMorph>>disable (in category 'as yet unclassified') ----- - disable - "Disable the receiver." - - self enabled: false! Item was removed: - ----- Method: PluggableSliderMorph>>enable (in category 'as yet unclassified') ----- - enable - "Enable the receiver." - - self enabled: true! Item was removed: - ----- Method: PluggableSliderMorph>>enabled (in category 'accessing') ----- - enabled - "Answer the value of enabled" - - ^ enabled! Item was removed: - ----- Method: PluggableSliderMorph>>enabled: (in category 'accessing') ----- - enabled: anObject - "Set the value of enabled" - - enabled = anObject ifTrue: [^self]. - enabled := anObject. - self changed: #enabled. - self - adoptPaneColor: self color; - changed! Item was removed: - ----- Method: PluggableSliderMorph>>fillStyleToUse (in category 'as yet unclassified') ----- - fillStyleToUse - "Answer the fillStyle that should be used for the receiver." - - ^self enabled - ifTrue: [self theme sliderNormalFillStyleFor: self] - ifFalse: [self theme sliderDisabledFillStyleFor: self]! Item was removed: - ----- Method: PluggableSliderMorph>>getEnabledSelector (in category 'accessing') ----- - getEnabledSelector - "Answer the value of getEnabledSelector" - - ^ getEnabledSelector! Item was removed: - ----- Method: PluggableSliderMorph>>getEnabledSelector: (in category 'accessing') ----- - getEnabledSelector: aSymbol - "Set the value of getEnabledSelector" - - getEnabledSelector := aSymbol. - self updateEnabled! Item was removed: - ----- Method: PluggableSliderMorph>>getValueSelector (in category 'as yet unclassified') ----- - getValueSelector - "Answer the value of getValueSelector" - - ^ getValueSelector! Item was removed: - ----- Method: PluggableSliderMorph>>getValueSelector: (in category 'as yet unclassified') ----- - getValueSelector: anObject - "Set the value of getValueSelector" - - getValueSelector := anObject! Item was removed: - ----- Method: PluggableSliderMorph>>handlesMouseDown: (in category 'as yet unclassified') ----- - handlesMouseDown: evt - "Answer true." - - ^true! Item was removed: - ----- Method: PluggableSliderMorph>>initialize (in category 'as yet unclassified') ----- - initialize - "Initialize the receiver." - - min := 0. - max := 1. - super initialize. - self enabled: true! Item was removed: - ----- Method: PluggableSliderMorph>>initializeSlider (in category 'as yet unclassified') ----- - initializeSlider - "Make the slider raised." - - super initializeSlider. - slider borderStyle: (BorderStyle raised baseColor: slider color; width: 1)! Item was removed: - ----- Method: PluggableSliderMorph>>layoutBounds: (in category 'as yet unclassified') ----- - layoutBounds: aRectangle - "Set the bounds for laying out children of the receiver. - Note: written so that #layoutBounds can be changed without touching this method" - - super layoutBounds: aRectangle. - self computeSlider! Item was removed: - ----- Method: PluggableSliderMorph>>max (in category 'accessing') ----- - max - "Answer the value of max" - - ^ max! Item was removed: - ----- Method: PluggableSliderMorph>>max: (in category 'accessing') ----- - max: anObject - "Set the value of max" - - max := anObject. - self setValue: self value! Item was removed: - ----- Method: PluggableSliderMorph>>min (in category 'accessing') ----- - min - "Answer the value of min" - - ^ min! Item was removed: - ----- Method: PluggableSliderMorph>>min: (in category 'accessing') ----- - min: anObject - "Set the value of min" - - min := anObject. - self setValue: self value! Item was removed: - ----- Method: PluggableSliderMorph>>minHeight (in category 'as yet unclassified') ----- - minHeight - "Answer the receiver's minimum height. - Give it a bit of a chance..." - - ^8 max: super minHeight! Item was removed: - ----- Method: PluggableSliderMorph>>mouseDown: (in category 'as yet unclassified') ----- - mouseDown: anEvent - "Set the value directly." - - self enabled ifTrue: [ - self - scrollPoint: anEvent; - computeSlider]. - super mouseDown: anEvent. - self enabled ifFalse: [^self]. - anEvent hand newMouseFocus: slider event: anEvent. - slider - mouseEnter: anEvent copy; - mouseDown: anEvent copy - ! Item was removed: - ----- Method: PluggableSliderMorph>>mouseDownInSlider: (in category 'as yet unclassified') ----- - mouseDownInSlider: event - "Ignore if disabled." - - self enabled ifFalse: [^self]. - ^super mouseDownInSlider: event! Item was removed: - ----- Method: PluggableSliderMorph>>on:getValue:setValue: (in category 'as yet unclassified') ----- - on: anObject getValue: getSel setValue: setSel - "Use the given selectors as the interface." - - self - model: anObject; - getValueSelector: getSel; - setValueSelector: setSel; - updateValue! Item was removed: - ----- Method: PluggableSliderMorph>>quantum (in category 'accessing') ----- - quantum - "Answer the value of quantum" - - ^ quantum! Item was removed: - ----- Method: PluggableSliderMorph>>quantum: (in category 'accessing') ----- - quantum: anObject - "Set the value of quantum" - - quantum := anObject. - self setValue: self value! Item was removed: - ----- Method: PluggableSliderMorph>>scaledValue (in category 'as yet unclassified') ----- - scaledValue - "Answer the scaled value." - - |val| - val := self value * (self max - self min) + self min. - self quantum ifNotNil: [:q | - val := val roundTo: q]. - ^(val max: self min) min: self max! Item was removed: - ----- Method: PluggableSliderMorph>>scaledValue: (in category 'as yet unclassified') ----- - scaledValue: newValue - "Set the scaled value." - - |val| - val := newValue. - self quantum ifNotNil: [:q | - val := val roundTo: q]. - self value: newValue - self min / (self max - self min)! Item was removed: - ----- Method: PluggableSliderMorph>>scrollAbsolute: (in category 'as yet unclassified') ----- - scrollAbsolute: event - "Ignore if disabled." - - self enabled ifFalse: [^self]. - ^super scrollAbsolute: event! Item was removed: - ----- Method: PluggableSliderMorph>>scrollPoint: (in category 'as yet unclassified') ----- - scrollPoint: event - "Scroll to the event position." - - | r p | - r := self roomToMove. - bounds isWide - ifTrue: [r width = 0 ifTrue: [^ self]] - ifFalse: [r height = 0 ifTrue: [^ self]]. - p := event position - (self sliderThickness // 2) adhereTo: r. - self descending - ifFalse: - [self setValue: (bounds isWide - ifTrue: [(p x - r left) asFloat / r width] - ifFalse: [(p y - r top) asFloat / r height])] - ifTrue: - [self setValue: (bounds isWide - ifTrue: [(r right - p x) asFloat / r width] - ifFalse: [(r bottom - p y) asFloat / r height])]! Item was removed: - ----- Method: PluggableSliderMorph>>setValue: (in category 'as yet unclassified') ----- - setValue: newValue - "Called internally for propagation to model." - - |scaled| - value := newValue. - self scaledValue: (scaled := self scaledValue). - self model ifNotNil: [ - self setValueSelector ifNotNil: [:sel | - self model perform: sel with: scaled]]! Item was removed: - ----- Method: PluggableSliderMorph>>setValueSelector (in category 'as yet unclassified') ----- - setValueSelector - "Answer the set selector." - - ^setValueSelector! Item was removed: - ----- Method: PluggableSliderMorph>>setValueSelector: (in category 'as yet unclassified') ----- - setValueSelector: aSymbol - "Directly set the selector to make more flexible." - - setValueSelector := aSymbol! Item was removed: - ----- Method: PluggableSliderMorph>>sliderColor: (in category 'as yet unclassified') ----- - sliderColor: newColor - "Set the slider colour." - - super sliderColor: newColor. - slider ifNotNil: [slider borderStyle baseColor: newColor]! Item was removed: - ----- Method: PluggableSliderMorph>>update: (in category 'as yet unclassified') ----- - update: aSymbol - "Update the value." - - super update: aSymbol. - aSymbol == self getEnabledSelector ifTrue: [ - ^self updateEnabled]. - aSymbol = self getValueSelector ifTrue: [ - ^self updateValue]! Item was removed: - ----- Method: PluggableSliderMorph>>updateEnabled (in category 'as yet unclassified') ----- - updateEnabled - "Update the enablement state." - - self model ifNotNil: [ - self getEnabledSelector ifNotNil: [ - self enabled: (self model perform: self getEnabledSelector)]]! Item was removed: - ----- Method: PluggableSliderMorph>>updateValue (in category 'as yet unclassified') ----- - updateValue - "Update the value." - - self model ifNotNil: [ - self getValueSelector ifNotNil: [ - self scaledValue: (self model perform: self getValueSelector)]]! Item was changed: ----- Method: ScrollBar>>doScrollByPage (in category 'scrolling') ----- doScrollByPage "Scroll automatically while mouse is down" (self waitForDelay1: 300 delay2: 100) ifFalse: [^ self]. nextPageDirection + ifTrue: [self setValue: value + pageDelta] + ifFalse: [self setValue: value - pageDelta] - ifTrue: [self setValue: (value + pageDelta min: 1.0)] - ifFalse: [self setValue: (value - pageDelta max: 0.0)] ! Item was changed: ----- Method: ScrollBar>>doScrollDown (in category 'scrolling') ----- doScrollDown "Scroll automatically while mouse is down" (self waitForDelay1: 200 delay2: 40) ifFalse: [^ self]. + self setValue: value + scrollDelta.! - self setValue: (value + scrollDelta + 0.000001 min: 1.0)! Item was changed: ----- Method: ScrollBar>>doScrollUp (in category 'scrolling') ----- doScrollUp "Scroll automatically while mouse is down" (self waitForDelay1: 200 delay2: 40) ifFalse: [^ self]. + self setValue: value - scrollDelta.! - self setValue: (value - scrollDelta - 0.000001 max: 0.0)! Item was changed: ----- Method: ScrollBar>>initialize (in category 'initialize') ----- initialize + interval := 0.2. + super initialize. scrollDelta := 0.02. pageDelta := 0.2. self color: Color transparent. self class roundedScrollBarLook ifFalse: [self borderWidth: 0] ifTrue:[self borderStyle: ((BorderStyle complexFramed width: 2) "baseColor: Color gray")].! Item was changed: ----- Method: ScrollBar>>initializeSlider (in category 'initialize') ----- initializeSlider self initializeMenuButton; initializeUpButton; initializeDownButton; initializePagingArea. super initializeSlider. + self expandSlider. + self class roundedScrollBarLook ifTrue: [slider cornerStyle: #rounded. slider borderStyle: (BorderStyle complexRaised width: 3). sliderShadow cornerStyle: #rounded]. self sliderColor: self sliderColor! Item was added: + ----- Method: ScrollBar>>interval (in category 'access') ----- + interval + + ^ interval! Item was changed: ----- Method: ScrollBar>>mouseDownInSlider: (in category 'other events') ----- mouseDownInSlider: event + interval = self maximumValue ifTrue: - interval = 1.0 ifTrue: ["make the entire scrollable area visible if a full scrollbar is clicked on" self setValue: 0. self model hideOrShowScrollBars.]. " super mouseDownInSlider: event" ! Item was changed: ----- Method: ScrollBar>>scrollDown: (in category 'scrolling') ----- scrollDown: count + self setValue: value + (scrollDelta * count).! - self setValue: (value + (scrollDelta * count) + 0.000001 min: 1.0)! Item was changed: ----- Method: ScrollBar>>scrollUp: (in category 'scrolling') ----- scrollUp: count + self setValue: value - (scrollDelta * count).! - self setValue: (value - (scrollDelta * count) - 0.000001 max: 0.0)! Item was removed: - ----- Method: ScrollBar>>setValue: (in category 'model access') ----- - setValue: newValue - "Using roundTo: instead of truncateTo: ensures that scrollUp will scroll the same distance as scrollDown." - ^ super setValue: (newValue roundTo: scrollDelta)! Item was changed: MorphicModel subclass: #Slider + instanceVariableNames: 'slider value setValueSelector getValueSelector sliderShadow sliderColor descending minimumValue maximumValue quantum getMinimumValueSelector getMaximumValueSelector' - instanceVariableNames: 'slider value setValueSelector sliderShadow sliderColor descending' classVariableNames: '' poolDictionaries: '' category: 'Morphic-Windows'! Item was added: + ----- Method: Slider class>>on:getValue:setValue: (in category 'instance creation') ----- + on: anObject getValue: getSel setValue: setSel + "Answer a new instance of the receiver with + the given selectors as the interface." + + ^self new + on: anObject + getValue: getSel + setValue: setSel! Item was added: + ----- Method: Slider class>>on:getValue:setValue:min:max:quantum: (in category 'instance creation') ----- + on: anObject getValue: getSel setValue: setSel min: min max: max quantum: quantum + "Answer a new instance of the receiver with + the given selectors as the interface." + + | instance | + instance := self new + quantum: quantum; + on: anObject + getValue: getSel + setValue: setSel. + min isSymbol + ifTrue: [instance getMinimumValueSelector: min] + ifFalse: [instance minimumValue: min]. + max isSymbol + ifTrue: [instance getMaximumValueSelector: max] + ifFalse: [instance maximumValue: max]. + ^ instance! Item was added: + ----- Method: Slider>>adoptPaneColor: (in category 'accessing - ui') ----- + adoptPaneColor: paneColor + + super adoptPaneColor: paneColor. + + paneColor ifNotNil: [:c | + self color: c. + self thumb color: c].! Item was changed: ----- Method: Slider>>computeSlider (in category 'geometry') ----- computeSlider + | r v | - | r | r := self roomToMove. + v := self maximumValue = self minimumValue + ifTrue: [0] + ifFalse: [(value - self minimumValue) / (self maximumValue - self minimumValue)]. self descending ifFalse: [slider position: (bounds isWide + ifTrue: [r topLeft + ((r width * v) asInteger @ 0)] + ifFalse: [r topLeft + (0 @ (r height * v) asInteger)])] - ifTrue: [r topLeft + ((r width * value) asInteger @ 0)] - ifFalse: [r topLeft + (0 @ (r height * value) asInteger)])] ifTrue: [slider position: (bounds isWide + ifTrue: [r bottomRight - ((r width * v) asInteger @ 0)] + ifFalse: [r bottomRight - ((0 @ (r height * v) asInteger))])]. - ifTrue: [r bottomRight - ((r width * value) asInteger @ 0)] - ifFalse: [r bottomRight - ((0 @ (r height * value) asInteger))])]. slider extent: self sliderExtent! Item was changed: + ----- Method: Slider>>descending (in category 'accessing') ----- - ----- Method: Slider>>descending (in category 'access') ----- descending + + ^ descending! - ^ descending == true! Item was changed: + ----- Method: Slider>>descending: (in category 'accessing') ----- - ----- Method: Slider>>descending: (in category 'access') ----- descending: aBoolean + descending := aBoolean. + self computeSlider.! - self value: value! Item was added: + ----- Method: Slider>>getMaximumValue (in category 'model access') ----- + getMaximumValue + + self getMaximumValueSelector ifNotNil: [:selector | + self maximumValue: (model perform: selector)]. + ^ self maximumValue! Item was added: + ----- Method: Slider>>getMaximumValueSelector (in category 'accessing - model') ----- + getMaximumValueSelector + + ^ getMaximumValueSelector! Item was added: + ----- Method: Slider>>getMaximumValueSelector: (in category 'accessing - model') ----- + getMaximumValueSelector: aSymbol + + getMaximumValueSelector := aSymbol.! Item was added: + ----- Method: Slider>>getMinimumValue (in category 'model access') ----- + getMinimumValue + + self getMinimumValueSelector ifNotNil: [:selector | + self minimumValue: (model perform: selector)]. + ^ self minimumValue! Item was added: + ----- Method: Slider>>getMinimumValueSelector (in category 'accessing - model') ----- + getMinimumValueSelector + + ^ getMinimumValueSelector! Item was added: + ----- Method: Slider>>getMinimumValueSelector: (in category 'accessing - model') ----- + getMinimumValueSelector: aSymbol + + getMinimumValueSelector := aSymbol.! Item was added: + ----- Method: Slider>>getValue (in category 'model access') ----- + getValue + "Updates internal value with model data if possible. Returns the updated value or the current one." + + self getValueSelector ifNotNil: [:selector | + self value: (model perform: selector)]. + ^ self value! Item was added: + ----- Method: Slider>>getValueSelector (in category 'accessing - model') ----- + getValueSelector + + ^ getValueSelector! Item was added: + ----- Method: Slider>>getValueSelector: (in category 'accessing - model') ----- + getValueSelector: aSymbol + + getValueSelector := aSymbol.! Item was added: + ----- Method: Slider>>maximumValue (in category 'accessing') ----- + maximumValue + + ^ maximumValue ifNil: [1.0]! Item was added: + ----- Method: Slider>>maximumValue: (in category 'accessing') ----- + maximumValue: aNumber + + maximumValue := aNumber. + self setValue: self value.! Item was added: + ----- Method: Slider>>minimumValue (in category 'accessing') ----- + minimumValue + ^ minimumValue ifNil: [0.0]! Item was added: + ----- Method: Slider>>minimumValue: (in category 'accessing') ----- + minimumValue: aNumber + + minimumValue := aNumber. + self setValue: self value.! Item was added: + ----- Method: Slider>>on:getValue:setValue: (in category 'initialization') ----- + on: anObject getValue: getSel setValue: setSel + + self + model: anObject; + getValueSelector: getSel; + setValueSelector: setSel; + getValue.! Item was changed: + ----- Method: Slider>>pagingArea (in category 'accessing - ui') ----- - ----- Method: Slider>>pagingArea (in category 'access') ----- pagingArea ^self! Item was added: + ----- Method: Slider>>quantum (in category 'accessing') ----- + quantum + + ^ quantum! Item was added: + ----- Method: Slider>>quantum: (in category 'accessing') ----- + quantum: aNumber + + quantum := aNumber. + self setValue: self value.! Item was changed: ----- Method: Slider>>scrollAbsolute: (in category 'scrolling') ----- scrollAbsolute: event | r p | r := self roomToMove. bounds isWide ifTrue: [r width = 0 ifTrue: [^ self]] ifFalse: [r height = 0 ifTrue: [^ self]]. p := event targetPoint adhereTo: r. self descending ifFalse: + [self setValueFraction: (bounds isWide - [self setValue: (bounds isWide ifTrue: [(p x - r left) asFloat / r width] ifFalse: [(p y - r top) asFloat / r height])] ifTrue: + [self setValueFraction: (bounds isWide - [self setValue: (bounds isWide ifTrue: [(r right - p x) asFloat / r width] ifFalse: [(r bottom - p y) asFloat / r height])]! Item was added: + ----- Method: Slider>>scrollBy: (in category 'scrolling') ----- + scrollBy: delta + + self setValue: self value + delta.! Item was changed: ----- Method: Slider>>setValue: (in category 'model access') ----- setValue: newValue + "Either changes the value directly or tries to go the loop through the model. See #update:." + + self setValueSelector ifNotNil: [:selector | + | trimmedValue | + trimmedValue := self trimmedValue: newValue. + "Only notify about changed values." + trimmedValue ~= self value ifTrue: [ + model perform: selector with: trimmedValue]]. + + (self setValueSelector isNil or: [self getValueSelector isNil]) + ifTrue: [self value: newValue].! - "Called internally for propagation to model" - self value: newValue. - self use: setValueSelector orMakeModelSelectorFor: 'Value:' - in: [:sel | setValueSelector := sel. model perform: sel with: value]! Item was added: + ----- Method: Slider>>setValueFraction: (in category 'support') ----- + setValueFraction: newValueFraction + + self setValue: (newValueFraction * (self maximumValue - self minimumValue)) + self minimumValue.! Item was added: + ----- Method: Slider>>setValueSelector (in category 'accessing - model') ----- + setValueSelector + + ^ setValueSelector! Item was added: + ----- Method: Slider>>setValueSelector: (in category 'accessing - model') ----- + setValueSelector: aSymbol + + setValueSelector := aSymbol.! Item was changed: + ----- Method: Slider>>sliderColor (in category 'accessing - ui') ----- - ----- Method: Slider>>sliderColor (in category 'access') ----- sliderColor "color scheme for the whole slider widget" sliderColor ifNil: [^ (color alphaMixed: 0.7 with: Color white) slightlyLighter]. ^ sliderColor! Item was changed: + ----- Method: Slider>>sliderColor: (in category 'accessing - ui') ----- - ----- Method: Slider>>sliderColor: (in category 'access') ----- sliderColor: newColor sliderColor := newColor. slider ifNotNil: [slider color: sliderColor]! Item was changed: + ----- Method: Slider>>sliderShadowColor (in category 'accessing - ui') ----- - ----- Method: Slider>>sliderShadowColor (in category 'access') ----- sliderShadowColor ^ self sliderColor alphaMixed: 0.2 with: self pagingArea color! Item was added: + ----- Method: Slider>>thumb (in category 'accessing - ui') ----- + thumb + + ^ slider! Item was changed: + ----- Method: Slider>>thumbColor (in category 'accessing - ui') ----- - ----- Method: Slider>>thumbColor (in category 'access') ----- thumbColor "Color of the draggable 'thumb'" ^ self sliderColor! Item was added: + ----- Method: Slider>>trimValue: (in category 'support') ----- + trimValue: aValue + + | trimmedValue | + trimmedValue := aValue min: self maximumValue max: self minimumValue. + self quantum ifNotNil: [:q | trimmedValue := trimmedValue roundTo: q]. + ^ trimmedValue + ! Item was added: + ----- Method: Slider>>trimmedValue: (in category 'support') ----- + trimmedValue: aValue + + | trimmedValue | + trimmedValue := aValue min: self maximumValue max: self minimumValue. + self quantum ifNotNil: [:q | trimmedValue := trimmedValue roundTo: q]. + ^ trimmedValue + ! Item was added: + ----- Method: Slider>>truncate (in category 'accessing') ----- + truncate + + ^ self quantum == 1! Item was added: + ----- Method: Slider>>truncate: (in category 'accessing') ----- + truncate: aBoolean + + self quantum: (aBoolean ifTrue: [1] ifFalse: [nil]).! Item was added: + ----- Method: Slider>>update: (in category 'updating') ----- + update: aSymbol + "Update the value." + + super update: aSymbol. + + aSymbol = self getValueSelector ifTrue: [self getValue. ^ self]. + aSymbol = self getMinimumValueSelector ifTrue: [self getMinimumValue. ^ self]. + aSymbol = self getMaximumValueSelector ifTrue: [self getMaximumValue. ^ self].! Item was changed: + ----- Method: Slider>>value (in category 'accessing') ----- - ----- Method: Slider>>value (in category 'access') ----- value + ^ value! Item was changed: + ----- Method: Slider>>value: (in category 'accessing') ----- - ----- Method: Slider>>value: (in category 'model access') ----- value: newValue + + | t | + t := self trimmedValue: newValue. + t = value ifTrue: [^ self]. + + value := t. + self computeSlider.! - "Drive the slider position externally..." - value := newValue min: 1.0 max: 0.0. - self computeSlider! Item was changed: + ----- Method: Slider>>wantsSlot (in category 'testing') ----- - ----- Method: Slider>>wantsSlot (in category 'access') ----- wantsSlot "For now do it the old way, until we sort this out" ^ true! From eliot.miranda at gmail.com Wed Apr 8 18:29:27 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Wed Apr 8 18:29:30 2015 Subject: [squeak-dev] Can we get Squeak green for the release? In-Reply-To: References: <54C3EEC4-FA57-4D37-954C-D5B6F98A2393@gmx.de> Message-ID: Skipped content of type multipart/alternative-------------- next part -------------- A non-text attachment was scrubbed... Name: Decompiler-blockTo.st Type: application/octet-stream Size: 729 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150408/d8fc10c9/Decompiler-blockTo.obj From commits at source.squeak.org Wed Apr 8 18:32:20 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 8 18:32:23 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.843.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.843.mcz ==================== Summary ==================== Name: Morphic-mt.843 Author: mt Time: 8 April 2015, 8:31:38.574 pm UUID: 1526b04c-0b9c-5546-ad8f-90e7925b10a5 Ancestors: Morphic-mt.842 Scroll pane refactored to avoid using floats for controlling the transform morph's offset but use integer values. This allows for a pixel-precise scrolling behavior. Note: The postscript should correctly update all existing scroll panes and their scroll bars. =============== Diff against Morphic-mt.842 =============== Item was changed: ----- Method: IndentingListItemMorph>>charactersOccluded (in category 'private') ----- charactersOccluded "Answer the number of characters occluded in my #visibleList by my right edge." | listIndex leftEdgeOfRightmostColumn eachString indexOfLastVisible iconWidth totalWidth | listIndex := 0. leftEdgeOfRightmostColumn := container columns ifNil: [ 0 ] ifNotNil: [ : cols | (1 to: cols size - 1) inject: 0 into: [ : sum : each | sum + (self widthOfColumn: each) ] ]. eachString := container columns ifNil: [ self complexContents asString ] ifNotNil: [ : cols | self contentsAtColumn: container columns size ]. iconWidth := self icon ifNil: [ 0 ] ifNotNil: [ : icon | icon width + 2 ]. totalWidth := self toggleBounds right. indexOfLastVisible := ((1 to: eachString size) detect: [ : stringIndex | (totalWidth:=totalWidth+(self fontToUse widthOf: (eachString at: stringIndex))) > (container width - (container vIsScrollbarShowing + ifTrue: [ container vScrollBar width ] - ifTrue: [ container scrollBar width ] ifFalse: [ 0 ]) - iconWidth - leftEdgeOfRightmostColumn) ] ifNone: [ eachString size + 1 ]) - 1. ^ eachString size - indexOfLastVisible! Item was removed: - ----- Method: PluggableTextMorph>>hExtraScrollRange (in category 'scrolling') ----- - hExtraScrollRange - - ^ 0! Item was removed: - ----- Method: PluggableTextMorph>>vExtraScrollRange (in category 'scrolling') ----- - vExtraScrollRange - - ^ 10! Item was removed: - ----- Method: ScrollPane>>extraScrollRange (in category 'geometry') ----- - extraScrollRange - "Return the amount of extra blank space to include below the bottom of the scroll content." - "The classic behavior would be ^bounds height - (bounds height * 3 // 4)" - ^ self scrollDeltaHeight! Item was changed: ----- Method: ScrollPane>>hExtraScrollRange (in category 'geometry') ----- hExtraScrollRange "Return the amount of extra blank space to include below the bottom of the scroll content." + ^ 0 - ^ self scrollDeltaWidth ! Item was changed: ----- Method: ScrollPane>>hIsScrollable (in category 'geometry testing') ----- hIsScrollable - "If the contents of the pane are too small to scroll, return false." - ^ self hLeftoverScrollRange > 0 + ^ self hLeftoverScrollRange > 0 ! Item was changed: ----- Method: ScrollPane>>hLeftoverScrollRange (in category 'geometry') ----- hLeftoverScrollRange "Return the entire scrolling range minus the currently viewed area." + + ^ scroller hasSubmorphs + ifFalse: [0] + ifTrue: [self hTotalScrollRange - scroller width max: 0] - | w | - scroller hasSubmorphs ifFalse:[^0]. - w := bounds width. - self vIsScrollbarShowing ifTrue:[ w := w - self scrollBarThickness ]. - ^ (self hTotalScrollRange - w roundTo: self scrollDeltaWidth) max: 0 ! Item was added: + ----- Method: ScrollPane>>hScrollBar (in category 'access') ----- + hScrollBar + ^ hScrollBar! Item was changed: ----- Method: ScrollPane>>hScrollBarValue: (in category 'scrolling') ----- hScrollBarValue: scrollValue + scroller hasSubmorphs ifFalse: [^ self]. + lockOffset == true ifFalse: [ + scroller offset: scrollValue @scroller offset y]. - | x | - lockOffset == true ifTrue: [^ self]. - - self hIsScrollbarShowing ifFalse: - [^scroller offset: (0 - self hMargin)@scroller offset y]. - ((x := self hLeftoverScrollRange * scrollValue) <= 0) - ifTrue:[x := 0 - self hMargin]. - scroller offset: (x@scroller offset y) ! Item was changed: ----- Method: ScrollPane>>hSetScrollDelta (in category 'geometry') ----- hSetScrollDelta "Set the ScrollBar deltas, value and interval, based on the current scroll pane size, offset and range." - | range delta | + | delta | - scroller hasSubmorphs ifFalse:[scrollBar interval: 1.0. ^self]. - delta := self scrollDeltaWidth. - range := self hLeftoverScrollRange. - range = 0 ifTrue: [ hScrollBar scrollDelta: 0.02 pageDelta: 0.2; interval: 1.0; setValue: 0. ^self]. + hScrollBar + truncate: true; + scrollDelta: delta + pageDelta: 10*delta; + maximumValue: self hLeftoverScrollRange; + interval: (self hTotalScrollRange = 0 + ifTrue: [1.0] + ifFalse: [scroller width / self hTotalScrollRange]); + setValue: scroller offset x.! - "Set up for one line (for arrow scrolling), or a full pane less one line (for paging)." - - hScrollBar - scrollDelta: (delta / range) asFloat - pageDelta: ((self innerBounds width - delta) / range) asFloat. - hScrollBar interval: ((self innerBounds width) / self hTotalScrollRange) asFloat. - hScrollBar setValue: ((scroller offset x / range) min: 1.0) asFloat. - ! Item was changed: ----- Method: ScrollPane>>initializeScrollBars (in category 'initialization') ----- initializeScrollBars "initialize the receiver's scrollBar" + (scrollBar := ScrollBar on: self getValue: nil setValue: #vScrollBarValue:) - (scrollBar := ScrollBar new model: self slotName: 'vScrollBar') borderWidth: 1; borderColor: Color black. + (hScrollBar := ScrollBar on: self getValue: nil setValue: #hScrollBarValue:) - (hScrollBar := ScrollBar new model: self slotName: 'hScrollBar') borderWidth: 1; borderColor: Color black. "" scroller := TransformMorph new color: Color transparent. scroller offset: 0 @ 0. self addMorph: scroller. "" scrollBar initializeEmbedded: retractableScrollBar not. hScrollBar initializeEmbedded: retractableScrollBar not. retractableScrollBar ifFalse: [self addMorph: scrollBar; addMorph: hScrollBar]. Preferences alwaysShowVScrollbar ifTrue: [ self alwaysShowVScrollBar: true ]. Preferences alwaysHideHScrollbar ifTrue:[self hideHScrollBarIndefinitely: true ] ifFalse: [Preferences alwaysShowHScrollbar ifTrue: [ self alwaysShowHScrollBar: true ]]. ! Item was removed: - ----- Method: ScrollPane>>scrollBar (in category 'testing') ----- - scrollBar - ^ scrollBar! Item was changed: ----- Method: ScrollPane>>scrollBy: (in category 'scrolling') ----- scrollBy: delta "Move the contents in the direction delta." + self flag: #negated. "mt: Who uses this and why is does the expected behavor negate the delta?" + self vScrollBar scrollBy: delta y negated. + self hScrollBar scrollBy: delta x negated.! - | newYoffset r newXoffset | - - "Set the offset on the scroller" - newYoffset := scroller offset y - delta y max: 0. - newXoffset := scroller offset x - delta x max: -3. - - scroller offset: newXoffset@ newYoffset. - - "Update the scrollBars" - (r := self vLeftoverScrollRange) = 0 - ifTrue: [scrollBar value: 0.0] - ifFalse: [scrollBar value: newYoffset asFloat / r]. - (r := self hLeftoverScrollRange) = 0 - ifTrue: [hScrollBar value: -3.0] - ifFalse: [hScrollBar value: newXoffset asFloat / r] - ! Item was changed: ----- Method: ScrollPane>>scrollByKeyboard: (in category 'event handling') ----- scrollByKeyboard: event "If event is ctrl+up/down then scroll and answer true" (event controlKeyPressed or:[event commandKeyPressed]) ifFalse: [^ false]. + event keyCharacter = Character arrowUp - event keyValue = 30 ifTrue: [scrollBar scrollUp: 3. ^ true]. + event keyCharacter = Character arrowDown - event keyValue = 31 ifTrue: [scrollBar scrollDown: 3. ^ true]. + "event keyCharacter = Character arrowRight + ifTrue: + [hScrollBar scrollDown: 3. + ^ true]. + event keyCharacter = Character arrowLeft + ifTrue: + [hScrollBar scrollUp: 3. + ^ true]." ^ false! Item was changed: ----- Method: ScrollPane>>setScrollDeltas (in category 'geometry') ----- setScrollDeltas "Set the ScrollBar deltas, value and interval, based on the current scroll pane size, offset and range." + scroller hasSubmorphs ifFalse: [^ self]. - scroller hasSubmorphs ifFalse: - [scrollBar interval: 1.0. - hScrollBar interval: 1.0. - ^ self]. "NOTE: fullbounds commented out now -- trying to find a case where this expensive step is necessary -- perhaps there is a less expensive way to handle that case." "scroller fullBounds." "force recompute so that leftoverScrollRange will be up-to-date" self hideOrShowScrollBars. + self vSetScrollDelta. + self hSetScrollDelta.. - - (retractableScrollBar or: [ self vIsScrollbarShowing ]) ifTrue:[ self vSetScrollDelta ]. - (retractableScrollBar or: [ self hIsScrollbarShowing ]) ifTrue:[ self hSetScrollDelta ]. ! Item was changed: ----- Method: ScrollPane>>vExtraScrollRange (in category 'geometry') ----- vExtraScrollRange "Return the amount of extra blank space to include below the bottom of the scroll content." + ^ 0 - "The classic behavior would be ^bounds height - (bounds height * 3 // 4)" - ^ self scrollDeltaHeight ! Item was changed: ----- Method: ScrollPane>>vIsScrollable (in category 'geometry testing') ----- vIsScrollable + "Return whether the verticle scrollbar is scrollable. If the contents of the pane are too small to scroll, return false." + + ^ self vLeftoverScrollRange > 0! - "Return whether the verticle scrollbar is scrollable" - - "If the contents of the pane are too small to scroll, return false." - ^ self vLeftoverScrollRange > 0 - "treat a single line as non-scrollable" - and: [self vTotalScrollRange > (self scrollDeltaHeight * 3/2)] - ! Item was changed: ----- Method: ScrollPane>>vLeftoverScrollRange (in category 'geometry') ----- vLeftoverScrollRange "Return the entire scrolling range minus the currently viewed area." - | h | + ^ scroller hasSubmorphs + ifFalse: [0] + ifTrue: [self vTotalScrollRange - scroller height max: 0] - scroller hasSubmorphs ifFalse:[^0]. - h := self vScrollBarHeight. - ^ (self vTotalScrollRange - h roundTo: self scrollDeltaHeight) max: 0 ! Item was added: + ----- Method: ScrollPane>>vScrollBar (in category 'access') ----- + vScrollBar + ^ scrollBar! Item was changed: ----- Method: ScrollPane>>vScrollBarValue: (in category 'scrolling') ----- vScrollBarValue: scrollValue + scroller hasSubmorphs ifFalse: [^ self]. lockOffset == true ifFalse: [ + scroller offset: scroller offset x @ scrollValue]. - scroller offset: (scroller offset x @ (self vLeftoverScrollRange * scrollValue) rounded)]. ! Item was changed: ----- Method: ScrollPane>>vSetScrollDelta (in category 'geometry') ----- vSetScrollDelta "Set the ScrollBar deltas, value and interval, based on the current scroll pane size, offset and range." - | range delta | + | delta | - scroller hasSubmorphs ifFalse:[scrollBar interval: 1.0. ^self]. - delta := self scrollDeltaHeight. - range := self vLeftoverScrollRange. - range = 0 ifTrue: [^ scrollBar scrollDelta: 0.02 pageDelta: 0.2; interval: 1.0; setValue: 0]. + scrollBar + truncate: true; + scrollDelta: delta + pageDelta: 10*delta; + maximumValue: self vLeftoverScrollRange; + interval: (self vTotalScrollRange = 0 + ifTrue: [1.0] + ifFalse: [scroller height / self vTotalScrollRange]); + setValue: scroller offset y.! - "Set up for one line (for arrow scrolling), or a full pane less one line (for paging)." - scrollBar scrollDelta: (delta / range) asFloat - pageDelta: ((self innerBounds height - delta) / range) asFloat. - scrollBar interval: ((self innerBounds height) / self vTotalScrollRange) asFloat. - scrollBar setValue: (scroller offset y / range min: 1.0) asFloat. - ! Item was changed: (PackageInfo named: 'Morphic') postscript: '(Preferences dictionaryOfPreferences at: #alternativeWindowBoxesLook) defaultValue: false. "Force SystemProgressMorph to be reset" SystemProgressMorph initialize; reset. "Initialize the key bindings and menus" Editor initialize. "Retain scrollBar look now that the pref actually does something" Preferences enable: #gradientScrollBars. "apply the new icons" MenuIcons initializeIcons. TheWorldMainDockingBar updateInstances. - "Cleanup old-style preferences here. Remove before new release." Preferences removePreference: #gradientMenu. "Now in MenuMorph." Preferences removePreference: #roundedMenuCorners. "Now in MenuMorph." "Fix clipping bug of open windows. New ones are not affected." + TransformMorph allInstances do: [:ea | ea clipSubmorphs: true]. + + "Update existing scrollbars." + ScrollPane allSubInstances do: [:sc | + sc vScrollBar setValueSelector: #vScrollBarValue:. + sc hScrollBar setValueSelector: #hScrollBarValue:. + sc vSetScrollDelta; hSetScrollDelta].'! - TransformMorph allInstances do: [:ea | ea clipSubmorphs: true].'! From commits at source.squeak.org Wed Apr 8 18:34:15 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 8 18:34:18 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.844.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.844.mcz ==================== Summary ==================== Name: Morphic-mt.844 Author: mt Time: 8 April 2015, 8:33:39.809 pm UUID: 33c3b696-6a7b-3d48-b6d3-4bb6d493219b Ancestors: Morphic-mt.843 Fix lists to not reset the scroll position to 0 when updating their contents but keep it if possible. Having this, we can update lists without jumpy scrolling behavior. =============== Diff against Morphic-mt.843 =============== Item was changed: ----- Method: PluggableListMorph>>updateList (in category 'updating') ----- updateList | index | "the list has changed -- update from the model" self listMorph listChanged. self setScrollDeltas. - scrollBar setValue: 0.0. index := self getCurrentSelectionIndex. self resetPotentialDropRow. self selectionIndex: (self uiIndexFor: index). ! From commits at source.squeak.org Wed Apr 8 18:35:23 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 8 18:35:24 2015 Subject: [squeak-dev] The Trunk: MorphicTests-mt.27.mcz Message-ID: Marcel Taeumel uploaded a new version of MorphicTests to project The Trunk: http://source.squeak.org/trunk/MorphicTests-mt.27.mcz ==================== Summary ==================== Name: MorphicTests-mt.27 Author: mt Time: 8 April 2015, 8:35:19.162 pm UUID: 58811b46-58b0-5c45-abcb-7802187779d5 Ancestors: MorphicTests-mt.26 Tests added for Slider and ScrollBar. =============== Diff against MorphicTests-mt.26 =============== Item was added: + SliderTest subclass: #ScrollBarTest + instanceVariableNames: '' + classVariableNames: '' + poolDictionaries: '' + category: 'MorphicTests-Widgets'! Item was added: + ----- Method: ScrollBarTest class>>shouldInheritSelectors (in category 'testing') ----- + shouldInheritSelectors + ^ true! Item was added: + ----- Method: ScrollBarTest>>subjectClass (in category 'running') ----- + subjectClass + + ^ ScrollBar! Item was added: + TestCase subclass: #SliderTest + instanceVariableNames: 'sut' + classVariableNames: '' + poolDictionaries: '' + category: 'MorphicTests-Widgets'! Item was added: + ----- Method: SliderTest>>setUp (in category 'running') ----- + setUp + + super setUp. + sut := self subjectClass + on: (ValueHolder new contents: 0.0) + getValue: #contents + setValue: #contents:. + sut extent: 400@20.! Item was added: + ----- Method: SliderTest>>subjectClass (in category 'running') ----- + subjectClass + + ^ Slider! Item was added: + ----- Method: SliderTest>>test01Value (in category 'tests') ----- + test01Value + + self assert: 0.0 equals: sut value. + self assert: 0.0 equals: sut model contents.! Item was added: + ----- Method: SliderTest>>test02SetValue (in category 'tests') ----- + test02SetValue + + sut setValue: 0.5. + self + assert: 0.5 equals: sut value; + assert: 0.5 equals: sut model contents.! Item was added: + ----- Method: SliderTest>>test03MinMax (in category 'tests') ----- + test03MinMax + + sut + minimumValue: 10; + maximumValue: 20. + + sut setValue: 5. + self assert: 10 equals: sut value truncated. + + sut setValue: 30. + self assert: 20 equals: sut value truncated. + + sut maximumValue: 15. + self assert: 15 equals: sut value truncated. + + sut setValue: 10. + sut minimumValue: 12. + self assert: 12 equals: sut value truncated. + ! Item was added: + ----- Method: SliderTest>>test04Descending (in category 'tests') ----- + test04Descending + + | px | + sut setValue: 0.3. + px := sut thumb position. + + sut descending: sut descending not. + self assert: px ~= sut thumb position.! Item was added: + ----- Method: SliderTest>>test05SliderWithoutModel (in category 'tests') ----- + test05SliderWithoutModel + + | swm | + swm := Slider new. + + self assert: 0.0 equals: swm value. + swm setValue: 0.6. + self assert: 0.6 equals: swm value.! Item was added: + ----- Method: SliderTest>>test06Truncate (in category 'tests') ----- + test06Truncate + + self assert: sut truncate not. + + sut maximumValue: 100. + sut truncate: true. + + sut setValue: 23.45. + self assert: 23 equals: sut value. + + sut setValue: 23.65. + self assert: 24 equals: sut value.! Item was added: + ----- Method: SliderTest>>test07Quantum (in category 'tests') ----- + test07Quantum + + sut maximumValue: 100. + sut quantum: 5. + + sut setValue: 23. + self assert: 25 equals: sut value.! Item was added: + ----- Method: SliderTest>>test08MinEqualsMax (in category 'tests') ----- + test08MinEqualsMax + + sut + maximumValue: 50; + minimumValue: 50. + + self assert: 50 equals: sut value.! Item was added: + ----- Method: SliderTest>>test09SliderWithoutGetter (in category 'tests') ----- + test09SliderWithoutGetter + + sut getValueSelector: nil. + sut setValue: 0.5. + + self assert: 0.5 equals: sut value. + self assert: 0.5 equals: sut model contents.! From marcel.taeumel at student.hpi.uni-potsdam.de Wed Apr 8 18:30:38 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Wed Apr 8 18:43:11 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.843.mcz In-Reply-To: References: Message-ID: <1428517838419-4818438.post@n4.nabble.com> Don't worry, I think this is the last *bigger* fix for the Squeak 4.6 release from my side. :) Let's hope that the update code in the postscript works... Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-843-mcz-tp4818434p4818438.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From Das.Linux at gmx.de Wed Apr 8 18:54:31 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Wed Apr 8 18:54:36 2015 Subject: [squeak-dev] Can we get Squeak green for the release? In-Reply-To: References: <54C3EEC4-FA57-4D37-954C-D5B6F98A2393@gmx.de> Message-ID: On 08.04.2015, at 20:29, Eliot Miranda wrote: > On Wed, Apr 8, 2015 at 11:11 AM, Eliot Miranda > wrote: > > > On Tue, Apr 7, 2015 at 7:39 AM, Levente Uzonyi wrote: > > > >> The decompiler is not perfect, and IIRC someone stated that it will never > >> be. Most of these errors are "handled" by adding them as exceptions, so > >> they are not tested. Some of these issues are probably fixable, but not > >> many people are familiar with the decompiler. > >> See DecompilerTests >> #decompilerFailures for the list of currently > >> ignored methods. > >> > >> Levente > >> > >> > >> On Tue, 7 Apr 2015, Tobias Pape wrote: > >> > >> Hi > >>> > >>> > >>> On 04.04.2015, at 16:59, Frank Shearar wrote: > >>> > >>> On 3 April 2015 at 16:27, Tobias Pape wrote: > >>>> > >>>>> Hey > >>>>> > >>>>> I am watching the CI doing its work as changes and fixes > >>>>> chime in. > >>>>> I noticed that there are still 13 test failing[1] and I'm > >>>>> not sure how all of them should be fixed :) > >>>>> Let's make it green! > >>>>> > >>>> > >>>> I am _very very happy_ to see someone other than me harping on about > >>>> tests! Please carry on! > >>>> > >>>> This one ought to be easy to fix: it's a small breakage in the > >>>> modularity of the image; some methods need to be recategorised as not > >>>> being System: http://build.squeak.org/job/SqueakTrunk/1207/testReport/ > >>>> Tests.Dependencies/PackageDependencyTest/testSystem/ > >>>> > >>>> This one too: http://build.squeak.org/job/SqueakTrunk/1207/testReport/ > >>>> Tests.Dependencies/PackageDependencyTest/testTools/ > >>>> (Tools shouldn't depend on _ToolBuilder-Morphic_, even though it would > >>>> be OK to depend on ToolBuilder.) > >>>> > >>>> And I love that this one fails - > >>>> http://build.squeak.org/job/SqueakTrunk/1207/testReport/ > >>>> Tests.Dependencies/PackageDependencyTest/testMultilingual/ > >>>> - Multilingual no longer depends on TrueType, and our system just got > >>>> one dependency cleaner. > >>>> > >>> > >>> I did some things :) > >>> > >>> But I need help: > >>> There's a strange thing in the decompiler/compiler: > >>> > >>> http://build.squeak.org/job/SqueakTrunk/lastCompletedBuild/testReport/ > >>> Tests.Compiler/DecompilerTests/testDecompilerInClassesBAtoBM/ > >>> > >>> Somewhere in Behavior>>#toolIconSelector:, > >>> a sequence of 'push nil. pop' is generated that is decompiled as 'nil.'. > >>> This does not match the source and I don't know whether it's a bug in > >>> the Compiler emitting this or the Decompiler not recognizing the emitted > >>> pattern. > >>> > >> > > Ah, I see it. > > > > Look the end of this block: > > self methodDictionary at: aSymbol ifPresent: [ :method | > > ... > > method hasReportableSlip ifTrue: [^ #breakpoint]]. > > > > The block (correctly) answers nil if method hasReportableSlip is false, > > and the bytecode contains a pushConstant: nil; blockReturn sequence to > > implement this. So the problem is with the decompiler not eliminating the > > explicit nil node in this case where it should be implicit. > > > > Oops. The pushConstant: nil; blockReturn sequence is at bytecpde pc 202 > right? That's coming from > > (self isSelectorOverride: aSymbol) > ifTrue: [ > (self isSelectorOverridden: aSymbol) > ifTrue: [ ^ #arrowUpAndDown ] > ifFalse: [ ^ #arrowUp ] ] > ifFalse: [ > (self isSelectorOverridden: aSymbol) > ifTrue: [^ #arrowDown ]]. > Yes, this is the place :) > I'll try and squash this in a principled way soon. I've squashed the > former by using the attached: > Thanks for taking care. Best -Tobias > > > -- > best, > Eliot From asqueaker at gmail.com Wed Apr 8 19:30:11 2015 From: asqueaker at gmail.com (Chris Muller) Date: Wed Apr 8 19:30:14 2015 Subject: [squeak-dev] The Inbox: ShoutCore-cmm.45.mcz In-Reply-To: References: Message-ID: >> A new version of ShoutCore was added to project The Inbox: >> http://source.squeak.org/inbox/ShoutCore-cmm.45.mcz >> >> ==================== Summary ==================== >> >> Name: ShoutCore-cmm.45 >> Author: cmm >> Time: 6 April 2015, 5:52:19.582 pm >> UUID: 7f2c4864-c8d9-4f51-8553-23db02266ad0 >> Ancestors: ShoutCore-cmm.44 >> >> - Added subdued version of Shout colors proposed in cmm.44. >> - #defaultStyleTable is misnamed because it was was not the default. Renamed it to #brightStyleTable. >> - Simplify help text for #subduedSyntaxHighlights. >> > > Did you integrate you changes into the subdued style now? > Please leave the subdued style. > Maybe we should allow for several styles? > > > Personally, I don't like the color choice yo are proposing, too much green, Well it's actually "green duller duller muchDarker" and its ONLY for unary and keyword messages. By contrast, the existing subdued table uses a 100%-saturation blue for not only messages, but also symbols (which should be black), literal-arrays (which should not be the same color as code!), AND method and block arguments. So it has a lot more blue than the new one has green. Why so much blue? > too hard to figure out at a glance the proportions of the following concepts: > > "direct access" (instvars, classes, formerly black) vs > "messages" (formerly blueish), > "self/supers" (formerly reddish) In fact, "at a glance" is one of the primary motivations for the new palette, and why I personally use bold black for self and super. But I turned off the emphasis in this subdued for Levente (maybe a different color then?). Messages are visible at-a-glance because they're the only thing that's green. Finally, I like to see inst-vars access at a glance too. In the existing table, you cannot distinguish between *local* access and *global* access at a glance, because it paints inst-vars and classes the same color. And method-args the same color as Symbols. > The proportions of the three rather distinct colors gave me a subconscious hint, > whether the method was idiomatic or not? I know what you mean, but I think the existing table is much less effective at it. Plus, it's hideous. > Also, please be very careful with underlining. The once only bolded message name > is now bold AND green AND underlined. Thats a tad too much attention. Moreover, > UML uses underlining for 'static methods' aka class methods. this could be confusing. Sure, no problem. As I said, I turned off some of the emphasis to try to win Levente's support. I don't want my own personal colors, just anything other than what we currently have for the default. > Don't get me wrong, I _like_ a variety of syntax highlighting styles, we > should support that better. I, however, don't think it is a good idea to > override a relatively accustomed style just because "it's time for a change". That's not the only reason, the existing tables have a lot of problems, IMO. From eliot.miranda at gmail.com Wed Apr 8 21:02:45 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Wed Apr 8 21:02:48 2015 Subject: [squeak-dev] Can we get Squeak green for the release? In-Reply-To: References: <54C3EEC4-FA57-4D37-954C-D5B6F98A2393@gmx.de> Message-ID: On Wed, Apr 8, 2015 at 11:54 AM, Tobias Pape wrote: > > On 08.04.2015, at 20:29, Eliot Miranda wrote: > > > On Wed, Apr 8, 2015 at 11:11 AM, Eliot Miranda > > wrote: > > > > > On Tue, Apr 7, 2015 at 7:39 AM, Levente Uzonyi wrote: > > > > > >> The decompiler is not perfect, and IIRC someone stated that it will > never > > >> be. Most of these errors are "handled" by adding them as exceptions, > so > > >> they are not tested. Some of these issues are probably fixable, but > not > > >> many people are familiar with the decompiler. > > >> See DecompilerTests >> #decompilerFailures for the list of currently > > >> ignored methods. > > >> > > >> Levente > > >> > > >> > > >> On Tue, 7 Apr 2015, Tobias Pape wrote: > > >> > > >> Hi > > >>> > > >>> > > >>> On 04.04.2015, at 16:59, Frank Shearar > wrote: > > >>> > > >>> On 3 April 2015 at 16:27, Tobias Pape wrote: > > >>>> > > >>>>> Hey > > >>>>> > > >>>>> I am watching the CI doing its work as changes and fixes > > >>>>> chime in. > > >>>>> I noticed that there are still 13 test failing[1] and I'm > > >>>>> not sure how all of them should be fixed :) > > >>>>> Let's make it green! > > >>>>> > > >>>> > > >>>> I am _very very happy_ to see someone other than me harping on about > > >>>> tests! Please carry on! > > >>>> > > >>>> This one ought to be easy to fix: it's a small breakage in the > > >>>> modularity of the image; some methods need to be recategorised as > not > > >>>> being System: > http://build.squeak.org/job/SqueakTrunk/1207/testReport/ > > >>>> Tests.Dependencies/PackageDependencyTest/testSystem/ > > >>>> > > >>>> This one too: > http://build.squeak.org/job/SqueakTrunk/1207/testReport/ > > >>>> Tests.Dependencies/PackageDependencyTest/testTools/ > > >>>> (Tools shouldn't depend on _ToolBuilder-Morphic_, even though it > would > > >>>> be OK to depend on ToolBuilder.) > > >>>> > > >>>> And I love that this one fails - > > >>>> http://build.squeak.org/job/SqueakTrunk/1207/testReport/ > > >>>> Tests.Dependencies/PackageDependencyTest/testMultilingual/ > > >>>> - Multilingual no longer depends on TrueType, and our system just > got > > >>>> one dependency cleaner. > > >>>> > > >>> > > >>> I did some things :) > > >>> > > >>> But I need help: > > >>> There's a strange thing in the decompiler/compiler: > > >>> > > >>> > http://build.squeak.org/job/SqueakTrunk/lastCompletedBuild/testReport/ > > >>> Tests.Compiler/DecompilerTests/testDecompilerInClassesBAtoBM/ > > >>> > > >>> Somewhere in Behavior>>#toolIconSelector:, > > >>> a sequence of 'push nil. pop' is generated that is decompiled as > 'nil.'. > > >>> This does not match the source and I don't know whether it's a bug in > > >>> the Compiler emitting this or the Decompiler not recognizing the > emitted > > >>> pattern. > > >>> > > >> > > > Ah, I see it. > > > > > > Look the end of this block: > > > self methodDictionary at: aSymbol ifPresent: [ :method | > > > ... > > > method hasReportableSlip ifTrue: [^ #breakpoint]]. > > > > > > The block (correctly) answers nil if method hasReportableSlip is false, > > > and the bytecode contains a pushConstant: nil; blockReturn sequence to > > > implement this. So the problem is with the decompiler not eliminating > the > > > explicit nil node in this case where it should be implicit. > > > > > > > Oops. The pushConstant: nil; blockReturn sequence is at bytecpde pc 202 > > right? That's coming from > > > > (self isSelectorOverride: aSymbol) > > ifTrue: [ > > (self isSelectorOverridden: aSymbol) > > ifTrue: [ ^ #arrowUpAndDown ] > > ifFalse: [ ^ #arrowUp ] ] > > ifFalse: [ > > (self isSelectorOverridden: aSymbol) > > ifTrue: [^ #arrowDown ]]. > > > > Yes, this is the place :) > > > I'll try and squash this in a principled way soon. I've squashed the > > former by using the attached: > > > > Thanks for taking care. > Best > -Tobias > Looks like a compiler bug to me. The push nil at 202 has no need to be generated. :-/ -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150408/247e19db/attachment.htm From commits at source.squeak.org Wed Apr 8 21:55:02 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 8 21:55:04 2015 Subject: [squeak-dev] Daily Commit Log Message-ID: <20150408215502.15329.qmail@box4.squeakfoundation.org> Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours: http://lists.squeakfoundation.org/pipermail/packages/2015-April/007862.html Name: Graphics-tk.309 Ancestors: Graphics-tfel.308 Some Mac applications won't let you drop in those files because they have the wrong Type and Creator. Here is a fix that makes the Type and Creator be ' ' and ' '. This is for filing out an image of a morph. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007863.html Name: Collections.spur-cmm.608 Ancestors: Collections-cmm.608, Collections.spur-ul.607 Collections-cmm.608 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 Merged cmm.603. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007864.html Name: Collections.spur-ul.610 Ancestors: Collections-ul.610, Collections.spur-cmm.608 Collections-ul.610 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 - Slightly faster SequenceableCollection >> #copyUpT* (for ByteString receivers). - SequenceableCollection >> #shuffled belongs to the shuffling category. - Added FormatCharacterSet to String, which will be used by the new implementation of #format: - Removed an unused temporary from String >> #expandMacrosWithArguments: ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007865.html Name: Collections.spur-ul.611 Ancestors: Collections-ul.611, Collections.spur-ul.610 Collections-ul.611 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 - Stricter and faster implementation of String >> #format:. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007866.html Name: Collections.spur-bf.612 Ancestors: Collections-bf.612 Collections-bf.612 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 Ensure that copyWith/out retains the weak-ness of a weak array. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007867.html Name: Kernel.spur-bf.917 Ancestors: Kernel-bf.917, Kernel.spur-topa.916 Kernel-bf.917 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 Fix accidental non-weak arrays in ObsoleteSubclasses values ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007868.html Name: System.spur-mt.717 Ancestors: System-mt.717, System.spur-mt.716 System-mt.717 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 Use general window-update function when changing window colors. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007869.html Name: System.spur-topa.718 Ancestors: System-topa.718, System.spur-mt.717 System-topa.718 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 Drop dependencies. For Preferences class>>#restorePreferencesFromDisk, we restore the old version, since right away there is no good way to allow old behavior (loading 'my.prefs'), selecting a custom prefs file, AND not depending on tools. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007870.html Name: Morphic-mt.842 Ancestors: Morphic-mt.841 Made Slider more pluggable and thus removed PluggableSliderMorph from the system. The code that was not moved upwards into Slider was moved downwards into its sole subclass: BracketSliderMorph. It was verified that the "new color picker morph", which is the sole user of that BracketSliderMorph, stays functional. Why? The Slider should support custom min/max values whenever the default (floats with 0.0 to 1.0) is not appropriate. Truncation is supported, too. Everything was already present in the (removed) PluggableSliderMorph, but we need that behavior in ScrollBar. Note: There is still the SimpleSliderMorph, which duplicates some behavior of Slider but is a base class of slider. E-Toys uses it. We may want to remove that duplicated code later. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007871.html Name: Morphic-mt.843 Ancestors: Morphic-mt.842 Scroll pane refactored to avoid using floats for controlling the transform morph's offset but use integer values. This allows for a pixel-precise scrolling behavior. Note: The postscript should correctly update all existing scroll panes and their scroll bars. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007872.html Name: Morphic-mt.844 Ancestors: Morphic-mt.843 Fix lists to not reset the scroll position to 0 when updating their contents but keep it if possible. Having this, we can update lists without jumpy scrolling behavior. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007873.html Name: MorphicTests-mt.27 Ancestors: MorphicTests-mt.26 Tests added for Slider and ScrollBar. ============================================= From commits at source.squeak.org Thu Apr 9 07:07:15 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 9 07:07:17 2015 Subject: [squeak-dev] The Trunk: CollectionsTests-tfel.238.mcz Message-ID: Tim Felgentreff uploaded a new version of CollectionsTests to project The Trunk: http://source.squeak.org/trunk/CollectionsTests-tfel.238.mcz ==================== Summary ==================== Name: CollectionsTests-tfel.238 Author: tfel Time: 9 April 2015, 9:07:05.355 am UUID: 7e048af5-d12e-ce41-b1c1-de810b6def31 Ancestors: CollectionsTests-topa.237 Add a test to check that running the fallback code for ByteArray>>#replaceFrom:to:with:startingAt: actually works, because primitive 105 is supposed to be optional =============== Diff against CollectionsTests-topa.237 =============== Item was added: + ----- Method: ByteArrayTest>>testFallbackReplaceFromToWith (in category 'testing') ----- + testFallbackReplaceFromToWith + | teststring ba sz cm | + teststring := 'Test string'. + sz := 'Test string' byteSize. + ba := ByteArray new: sz. + cm := SequenceableCollection compiledMethodAt: #replaceFrom:to:with:startingAt:. + self shouldnt: [cm valueWithReceiver: ba arguments: {1. sz. teststring. 1}] + raise: Exception + description: 'Primitive 105 should be optional for ByteArray' + ! From commits at source.squeak.org Thu Apr 9 07:09:22 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 9 07:09:23 2015 Subject: [squeak-dev] The Trunk: Collections-tfel.613.mcz Message-ID: Tim Felgentreff uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections-tfel.613.mcz ==================== Summary ==================== Name: Collections-tfel.613 Author: tfel Time: 9 April 2015, 9:09:08.368 am UUID: 9e6e47d3-17ac-f847-976f-40872d002ab8 Ancestors: Collections-bf.612 Fix replaceFrom:to:with:startingAt: for ByteArray if run on a VM without primitive 105 =============== Diff against Collections-bf.612 =============== Item was added: + ----- Method: ByteArray>>at:put: (in category 'accessing') ----- + at: index put: value + "try primitiveAtPut, convert value to integer if that fails and try again" + ^ self byteAt: index put: value asInteger + ! Item was changed: ----- Method: ByteArray>>byteAt: (in category 'accessing') ----- byteAt: index + ^ super at: index! - ^self at: index! Item was changed: ----- Method: ByteArray>>byteAt:put: (in category 'accessing') ----- byteAt: index put: value + ^ super at: index put: value! - ^self at: index put: value! From commits at source.squeak.org Thu Apr 9 08:01:26 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 9 08:01:28 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.845.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.845.mcz ==================== Summary ==================== Name: Morphic-mt.845 Author: mt Time: 9 April 2015, 10:00:54.492 am UUID: a00b3fe0-199f-8a4b-956a-2368877bfbee Ancestors: Morphic-mt.844 Speed-up when resizing scroll bars. They will not be re-initialized completely anymore. Menu buttons work again, too. =============== Diff against Morphic-mt.844 =============== Item was changed: Slider subclass: #ScrollBar instanceVariableNames: 'menuButton upButton downButton pagingArea scrollDelta pageDelta interval menuSelector timeOfMouseDown timeOfLastScroll nextPageDirection currentScrollDelay' + classVariableNames: 'ArrowImagesCache BoxesImagesCache RoundedScrollBarLook ScrollBarsWithoutArrowButtons ScrollBarsWithoutMenuButton UpArrow UpArrow8Bit' - classVariableNames: 'ArrowImagesCache BoxesImagesCache RoundedScrollBarLook ScrollBarsWithoutArrowButtons UpArrow UpArrow8Bit' poolDictionaries: '' category: 'Morphic-Windows'! !ScrollBar commentStamp: '' prior: 0! Inspired by an oiginal design of Hans-Martin Mosner, this ScrollBar is intended to exercise the handling of input events in Morphic. With sufficient flexibility in this area, all particular behavior can be concentrated in this single class with no need to specialize any other morphs to achieve button, slider and menu-button behavior. Once we have this working, put in logic for horizontal operation as well. CachedImages was added to reduce the number of forms created and thrown away. This will be helpful for Nebraska and others as well.! Item was added: + ----- Method: ScrollBar class>>refreshAllScrollBars (in category 'class initialization') ----- + refreshAllScrollBars + + ScrollBar allSubInstances do: [:s | + s updateSlider].! Item was changed: ----- Method: ScrollBar class>>scrollBarsWithoutArrowButtons: (in category 'preferences') ----- scrollBarsWithoutArrowButtons: aBoolean + ScrollBarsWithoutArrowButtons = aBoolean ifTrue: [^ self]. + ScrollBarsWithoutArrowButtons := aBoolean. + self refreshAllScrollBars.! - ScrollBarsWithoutArrowButtons := aBoolean.! Item was added: + ----- Method: ScrollBar class>>scrollBarsWithoutMenuButton (in category 'preferences') ----- + scrollBarsWithoutMenuButton + + + ^ ScrollBarsWithoutMenuButton ifNil: [false]! Item was added: + ----- Method: ScrollBar class>>scrollBarsWithoutMenuButton: (in category 'preferences') ----- + scrollBarsWithoutMenuButton: aBoolean + + ScrollBarsWithoutMenuButton = aBoolean ifTrue: [^ self]. + ScrollBarsWithoutMenuButton := aBoolean. + self refreshAllScrollBars.! Item was added: + ----- Method: ScrollBar>>boundsForDownButton (in category 'initialize') ----- + boundsForDownButton + + ^ self innerBounds bottomRight - self buttonExtent + extent: self buttonExtent! Item was added: + ----- Method: ScrollBar>>boundsForMenuButton (in category 'initialize') ----- + boundsForMenuButton + + ^ self innerBounds topLeft extent: self buttonExtent! Item was added: + ----- Method: ScrollBar>>boundsForUpButton (in category 'initialize') ----- + boundsForUpButton + + ^ (menuButton visible + ifFalse: [self innerBounds topLeft] + ifTrue: [bounds isWide + ifTrue: [menuButton bounds topRight - (1@0)] + ifFalse: [menuButton bounds bottomLeft - (0@1)]]) + extent: self buttonExtent! Item was changed: ----- Method: ScrollBar>>hasButtons (in category 'testing') ----- hasButtons + ^ (menuButton visible or: [upButton visible]) or: [downButton visible]! - ^ (menuButton notNil or: [upButton owner notNil]) or: [downButton owner notNil]! Item was changed: ----- Method: ScrollBar>>initializeDownButton (in category 'initialize') ----- initializeDownButton "initialize the receiver's downButton" downButton := RectangleMorph + newBounds: self boundsForDownButton - newBounds: (self innerBounds bottomRight - self buttonExtent - extent: self buttonExtent) color: self thumbColor. downButton on: #mouseDown send: #scrollDownInit to: self. downButton on: #mouseUp send: #finishedScrolling to: self. self updateDownButtonImage. self class roundedScrollBarLook ifTrue: [downButton color: Color veryLightGray. downButton borderStyle: (BorderStyle complexRaised width: 3)] ifFalse: [downButton setBorderWidth: 1 borderColor: Color lightGray]. + + self addMorph: downButton. + downButton visible: self class scrollBarsWithoutArrowButtons not.! - - self class scrollBarsWithoutArrowButtons - ifFalse: [self addMorph: downButton].! Item was changed: ----- Method: ScrollBar>>initializeMenuButton (in category 'initialize') ----- initializeMenuButton "initialize the receiver's menuButton" "Preferences disable: #scrollBarsWithoutMenuButton" "Preferences enable: #scrollBarsWithoutMenuButton" - (Preferences valueOfFlag: #scrollBarsWithoutMenuButton) - ifTrue: [menuButton := nil .^ self]. - self bounds isWide - ifTrue: [menuButton := nil .^ self]. menuButton := RectangleMorph + newBounds: self boundsForMenuButton - newBounds: (self innerBounds topLeft extent: self buttonExtent) color: self thumbColor. menuButton on: #mouseEnter send: #menuButtonMouseEnter: to: self. menuButton on: #mouseDown send: #menuButtonMouseDown: to: self. menuButton on: #mouseLeave send: #menuButtonMouseLeave: to: self. "menuButton addMorphCentered: (RectangleMorph newBounds: (0 @ 0 extent: 4 @ 2) color: Color black)." self updateMenuButtonImage. self class roundedScrollBarLook ifTrue: [menuButton color: Color veryLightGray. menuButton borderStyle: (BorderStyle complexRaised width: 3)] ifFalse: [menuButton setBorderWidth: 1 borderColor: Color lightGray]. + + self addMorph: menuButton. + menuButton visible: (self class scrollBarsWithoutMenuButton or: [self bounds isWide]) not.! - self addMorph: menuButton! Item was changed: ----- Method: ScrollBar>>initializePagingArea (in category 'initialize') ----- initializePagingArea "Appearance" pagingArea := RectangleMorph newBounds: self totalSliderArea color: (self class roundedScrollBarLook ifTrue: [Color gray: 0.9] ifFalse: [Color r: 0.6 g: 0.6 b: 0.8]). + Preferences gradientScrollBars + ifTrue: [pagingArea setBorderWidth: 1 borderColor: (Color lightGray alpha: 0.5)] + ifFalse: [pagingArea borderWidth: 0]. - pagingArea setBorderWidth: 1 borderColor: (Color lightGray alpha: 0.5). self addMorphBack: pagingArea. "Interactions" pagingArea on: #mouseDown send: #scrollPageInit: to: self. pagingArea on: #mouseUp send: #finishedScrolling to: self. ! Item was changed: ----- Method: ScrollBar>>initializeUpButton (in category 'initialize') ----- initializeUpButton "initialize the receiver's upButton" + upButton := RectangleMorph newBounds: self boundsForUpButton. - upButton := RectangleMorph - newBounds: ((menuButton - ifNil: [self innerBounds topLeft] - ifNotNil: [bounds isWide - ifTrue: [menuButton bounds topRight - (1@0)] - ifFalse: [menuButton bounds bottomLeft - (0@1)]]) - extent: self buttonExtent). upButton color: self thumbColor. upButton on: #mouseDown send: #scrollUpInit to: self. upButton on: #mouseUp send: #finishedScrolling to: self. self updateUpButtonImage. self class roundedScrollBarLook ifTrue: [upButton color: Color veryLightGray. upButton borderStyle: (BorderStyle complexRaised width: 3)] ifFalse: [upButton setBorderWidth: 1 borderColor: Color lightGray]. + + self addMorph: upButton. + upButton visible: self class scrollBarsWithoutArrowButtons not.! - - self class scrollBarsWithoutArrowButtons - ifFalse: [self addMorph: upButton].! Item was added: + ----- Method: ScrollBar>>menuSelector (in category 'access') ----- + menuSelector + ^ menuSelector! Item was added: + ----- Method: ScrollBar>>menuSelector: (in category 'access') ----- + menuSelector: aSymbol + menuSelector := aSymbol.! Item was changed: ----- Method: ScrollBar>>minExtent (in category 'geometry') ----- minExtent "The minimum extent is that of 2 or 3 buttons in a row or column, the 'up' and 'down' button and optionally the 'menu' button." | btns cnt | btns := 2. + menuButton visible ifTrue: [ - menuButton ifNotNil: [ btns := btns + 1]. cnt := 1@btns. "assume vertical layout" self bounds isWide ifTrue: [cnt := cnt transposed]. ^ upButton minExtent * cnt! Item was changed: ----- Method: ScrollBar>>sliderColor: (in category 'access') ----- sliderColor: aColor "Change the color of the scrollbar to go with aColor." | buttonColor | super sliderColor: aColor. self updateSliderColor: aColor. buttonColor := self thumbColor. + menuButton color: buttonColor. - menuButton - ifNotNil: [menuButton color: buttonColor]. upButton color: buttonColor. downButton color: buttonColor. self class updateScrollBarButtonsAspect: {menuButton. upButton. downButton} color: buttonColor. self updateMenuButtonImage. self updateUpButtonImage. self updateDownButtonImage.! Item was changed: ----- Method: ScrollBar>>totalSliderArea (in category 'geometry') ----- totalSliderArea | upperReferenceBounds lowerReferenceBounds | + upperReferenceBounds := (upButton visible ifFalse: [menuButton visible ifTrue: [menuButton] ifFalse: [nil]] ifTrue: [upButton]) - upperReferenceBounds := (upButton owner ifNil: [menuButton] ifNotNil: [upButton]) ifNil: [self topLeft corner: (bounds isWide ifTrue: [self bottomLeft + (1@0)] ifFalse: [self topRight + (0@1)])] ifNotNil: [:button | button bounds]. + lowerReferenceBounds := downButton visible + ifFalse: [(bounds isWide ifTrue: [self topRight - (1@0)] ifFalse: [self bottomLeft - (0@1)]) corner: self bottomRight] + ifTrue: [downButton bounds]. - lowerReferenceBounds := downButton owner - ifNil: [(bounds isWide ifTrue: [self topRight - (1@0)] ifFalse: [self bottomLeft - (0@1)]) corner: self bottomRight] - ifNotNil: [downButton bounds]. ^ bounds isWide ifTrue: [upperReferenceBounds topRight - (1@0) corner: lowerReferenceBounds bottomLeft + (1@0)] ifFalse:[upperReferenceBounds bottomLeft - (0@1) corner: lowerReferenceBounds topRight + (0@1)]. ! Item was changed: ----- Method: ScrollBar>>updateMenuButtonImage (in category 'initialize') ----- updateMenuButtonImage "update the receiver's menuButton. put a new image inside" - menuButton isNil ifTrue:[^ self]. menuButton removeAllMorphs. + menuButton addMorphCentered: (ImageMorph new image: self menuImage).! - menuButton - addMorphCentered: (ImageMorph new image: self menuImage)! Item was added: + ----- Method: ScrollBar>>updateSlider (in category 'initialize') ----- + updateSlider + + menuButton + visible: (self bounds isWide or: [self class scrollBarsWithoutMenuButton]) not; + bounds: self boundsForMenuButton. + upButton + visible: self class scrollBarsWithoutArrowButtons not; + bounds: self boundsForUpButton. + downButton + visible: self class scrollBarsWithoutArrowButtons not; + bounds: self boundsForDownButton. + + super updateSlider. + + pagingArea bounds: self totalSliderArea. + + self expandSlider. + ! Item was changed: ----- Method: ScrollPane>>initializeScrollBars (in category 'initialization') ----- initializeScrollBars "initialize the receiver's scrollBar" (scrollBar := ScrollBar on: self getValue: nil setValue: #vScrollBarValue:) + menuSelector: #vScrollBarMenuButtonPressed:; borderWidth: 1; borderColor: Color black. (hScrollBar := ScrollBar on: self getValue: nil setValue: #hScrollBarValue:) + menuSelector: #hScrollBarMenuButtonPressed:; borderWidth: 1; borderColor: Color black. "" scroller := TransformMorph new color: Color transparent. scroller offset: 0 @ 0. self addMorph: scroller. "" scrollBar initializeEmbedded: retractableScrollBar not. hScrollBar initializeEmbedded: retractableScrollBar not. retractableScrollBar ifFalse: [self addMorph: scrollBar; addMorph: hScrollBar]. Preferences alwaysShowVScrollbar ifTrue: [ self alwaysShowVScrollBar: true ]. Preferences alwaysHideHScrollbar ifTrue:[self hideHScrollBarIndefinitely: true ] ifFalse: [Preferences alwaysShowHScrollbar ifTrue: [ self alwaysShowHScrollBar: true ]]. ! Item was changed: ----- Method: Slider>>extent: (in category 'geometry') ----- extent: newExtent newExtent = bounds extent ifTrue: [^ self]. bounds isWide ifTrue: [super extent: (newExtent x max: self sliderThickness * 2) @ newExtent y] ifFalse: [super extent: newExtent x @ (newExtent y max: self sliderThickness * 2)]. + self updateSlider.! - self removeAllMorphs; initializeSlider! Item was added: + ----- Method: Slider>>updateSlider (in category 'initialization') ----- + updateSlider + "Updates layout properties of the slider." + + slider bounds: self totalSliderArea. + sliderShadow bounds: slider bounds. + + self computeSlider. + ! Item was changed: (PackageInfo named: 'Morphic') postscript: '(Preferences dictionaryOfPreferences at: #alternativeWindowBoxesLook) defaultValue: false. "Force SystemProgressMorph to be reset" SystemProgressMorph initialize; reset. "Initialize the key bindings and menus" Editor initialize. "Retain scrollBar look now that the pref actually does something" Preferences enable: #gradientScrollBars. "apply the new icons" MenuIcons initializeIcons. TheWorldMainDockingBar updateInstances. "Cleanup old-style preferences here. Remove before new release." Preferences removePreference: #gradientMenu. "Now in MenuMorph." Preferences removePreference: #roundedMenuCorners. "Now in MenuMorph." "Fix clipping bug of open windows. New ones are not affected." TransformMorph allInstances do: [:ea | ea clipSubmorphs: true]. "Update existing scrollbars." + ScrollBar allSubInstances do: [:sb | + sb removeAllMorphs; initializeSlider]. ScrollPane allSubInstances do: [:sc | + sc vScrollBar + setValueSelector: #vScrollBarValue:; + menuSelector: #vScrollBarMenuButtonPressed:. + sc hScrollBar + setValueSelector: #hScrollBarValue:; + menuSelector: #hScrollBarMenuButtonPressed:. + sc vSetScrollDelta; hSetScrollDelta]. + + "Now in ScrollBar." + Preferences removePreference: #scrollBarsWithoutMenuButton. '! - sc vScrollBar setValueSelector: #vScrollBarValue:. - sc hScrollBar setValueSelector: #hScrollBarValue:. - sc vSetScrollDelta; hSetScrollDelta].'! From commits at source.squeak.org Thu Apr 9 09:22:24 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 9 09:22:26 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.846.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.846.mcz ==================== Summary ==================== Name: Morphic-mt.846 Author: mt Time: 9 April 2015, 11:21:46.32 am UUID: b8e09540-d880-284d-ac5d-d1271d871caf Ancestors: Morphic-mt.845 Fixed postscript. =============== Diff against Morphic-mt.845 =============== Item was changed: + (PackageInfo named: 'Morphic') postscript: '"Update existing scrollbars." + ScrollBar allSubInstances do: [:sb | + sb removeAllMorphs; initializeSlider]. + ScrollPane allSubInstances do: [:sc | + sc vScrollBar + setValueSelector: #vScrollBarValue:; + menuSelector: #vScrollBarMenuButtonPressed:. + sc hScrollBar + setValueSelector: #hScrollBarValue:; + menuSelector: #hScrollBarMenuButtonPressed:. + sc vSetScrollDelta; hSetScrollDelta]. + + (Preferences dictionaryOfPreferences at: #alternativeWindowBoxesLook) defaultValue: false. - (PackageInfo named: 'Morphic') postscript: '(Preferences dictionaryOfPreferences at: #alternativeWindowBoxesLook) defaultValue: false. "Force SystemProgressMorph to be reset" SystemProgressMorph initialize; reset. "Initialize the key bindings and menus" Editor initialize. "Retain scrollBar look now that the pref actually does something" Preferences enable: #gradientScrollBars. "apply the new icons" MenuIcons initializeIcons. TheWorldMainDockingBar updateInstances. "Cleanup old-style preferences here. Remove before new release." Preferences removePreference: #gradientMenu. "Now in MenuMorph." Preferences removePreference: #roundedMenuCorners. "Now in MenuMorph." "Fix clipping bug of open windows. New ones are not affected." TransformMorph allInstances do: [:ea | ea clipSubmorphs: true]. - "Update existing scrollbars." - ScrollBar allSubInstances do: [:sb | - sb removeAllMorphs; initializeSlider]. - ScrollPane allSubInstances do: [:sc | - sc vScrollBar - setValueSelector: #vScrollBarValue:; - menuSelector: #vScrollBarMenuButtonPressed:. - sc hScrollBar - setValueSelector: #hScrollBarValue:; - menuSelector: #hScrollBarMenuButtonPressed:. - sc vSetScrollDelta; hSetScrollDelta]. - "Now in ScrollBar." Preferences removePreference: #scrollBarsWithoutMenuButton. '! From commits at source.squeak.org Thu Apr 9 09:39:20 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 9 09:39:20 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.847.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.847.mcz ==================== Summary ==================== Name: Morphic-mt.847 Author: mt Time: 9 April 2015, 11:38:46.961 am UUID: 5a0bfd2b-a16b-934e-9d8f-5ddf580203dc Ancestors: Morphic-mt.846 Compatibility fix: made menuMorph lazy initialized. =============== Diff against Morphic-mt.846 =============== Item was changed: ----- Method: ScrollBar>>boundsForUpButton (in category 'initialize') ----- boundsForUpButton + ^ (self menuButton visible - ^ (menuButton visible ifFalse: [self innerBounds topLeft] ifTrue: [bounds isWide + ifTrue: [self menuButton bounds topRight - (1@0)] + ifFalse: [self menuButton bounds bottomLeft - (0@1)]]) - ifTrue: [menuButton bounds topRight - (1@0)] - ifFalse: [menuButton bounds bottomLeft - (0@1)]]) extent: self buttonExtent! Item was changed: ----- Method: ScrollBar>>hasButtons (in category 'testing') ----- hasButtons + ^ (self menuButton visible or: [upButton visible]) or: [downButton visible]! - ^ (menuButton visible or: [upButton visible]) or: [downButton visible]! Item was added: + ----- Method: ScrollBar>>menuButton (in category 'access') ----- + menuButton + + ^ menuButton ifNil: [menuButton := RectangleMorph new]! Item was changed: ----- Method: ScrollBar>>minExtent (in category 'geometry') ----- minExtent "The minimum extent is that of 2 or 3 buttons in a row or column, the 'up' and 'down' button and optionally the 'menu' button." | btns cnt | btns := 2. + self menuButton visible ifTrue: [ - menuButton visible ifTrue: [ btns := btns + 1]. cnt := 1@btns. "assume vertical layout" self bounds isWide ifTrue: [cnt := cnt transposed]. ^ upButton minExtent * cnt! Item was changed: ----- Method: ScrollBar>>sliderColor: (in category 'access') ----- sliderColor: aColor "Change the color of the scrollbar to go with aColor." | buttonColor | super sliderColor: aColor. self updateSliderColor: aColor. buttonColor := self thumbColor. + self menuButton color: buttonColor. - menuButton color: buttonColor. upButton color: buttonColor. downButton color: buttonColor. + self class updateScrollBarButtonsAspect: {self menuButton. upButton. downButton} color: buttonColor. - self class updateScrollBarButtonsAspect: {menuButton. upButton. downButton} color: buttonColor. self updateMenuButtonImage. self updateUpButtonImage. self updateDownButtonImage.! Item was changed: ----- Method: ScrollBar>>totalSliderArea (in category 'geometry') ----- totalSliderArea | upperReferenceBounds lowerReferenceBounds | + upperReferenceBounds := (upButton visible ifFalse: [self menuButton visible ifTrue: [self menuButton] ifFalse: [nil]] ifTrue: [upButton]) - upperReferenceBounds := (upButton visible ifFalse: [menuButton visible ifTrue: [menuButton] ifFalse: [nil]] ifTrue: [upButton]) ifNil: [self topLeft corner: (bounds isWide ifTrue: [self bottomLeft + (1@0)] ifFalse: [self topRight + (0@1)])] ifNotNil: [:button | button bounds]. lowerReferenceBounds := downButton visible ifFalse: [(bounds isWide ifTrue: [self topRight - (1@0)] ifFalse: [self bottomLeft - (0@1)]) corner: self bottomRight] ifTrue: [downButton bounds]. ^ bounds isWide ifTrue: [upperReferenceBounds topRight - (1@0) corner: lowerReferenceBounds bottomLeft + (1@0)] ifFalse:[upperReferenceBounds bottomLeft - (0@1) corner: lowerReferenceBounds topRight + (0@1)]. ! Item was changed: ----- Method: ScrollBar>>updateMenuButtonImage (in category 'initialize') ----- updateMenuButtonImage "update the receiver's menuButton. put a new image inside" + self menuButton removeAllMorphs. + self menuButton addMorphCentered: (ImageMorph new image: self menuImage).! - menuButton removeAllMorphs. - menuButton addMorphCentered: (ImageMorph new image: self menuImage).! Item was changed: ----- Method: ScrollBar>>updateSlider (in category 'initialize') ----- updateSlider + self menuButton - menuButton visible: (self bounds isWide or: [self class scrollBarsWithoutMenuButton]) not; bounds: self boundsForMenuButton. upButton visible: self class scrollBarsWithoutArrowButtons not; bounds: self boundsForUpButton. downButton visible: self class scrollBarsWithoutArrowButtons not; bounds: self boundsForDownButton. super updateSlider. pagingArea bounds: self totalSliderArea. self expandSlider. ! From commits at source.squeak.org Thu Apr 9 09:47:55 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 9 09:47:58 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.848.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.848.mcz ==================== Summary ==================== Name: Morphic-mt.848 Author: mt Time: 9 April 2015, 11:46:59.806 am UUID: 86075430-2847-e343-b1d1-da4dfa077d3f Ancestors: Morphic-mt.847 Compatibility fix: Use lazy initialization for interval in scroll bars to make update work again. =============== Diff against Morphic-mt.847 =============== Item was changed: ----- Method: ScrollBar>>expandSlider (in category 'geometry') ----- expandSlider "Compute the new size of the slider (use the old sliderThickness as a minimum)." | r | r := self totalSliderArea. slider extent: (bounds isWide + ifTrue: [((r width * self interval) asInteger max: self sliderThickness) @ slider height] + ifFalse: [slider width @ ((r height * self interval) asInteger max: self sliderThickness)])! - ifTrue: [((r width * interval) asInteger max: self sliderThickness) @ slider height] - ifFalse: [slider width @ ((r height * interval) asInteger max: self sliderThickness)])! Item was changed: ----- Method: ScrollBar>>interval (in category 'access') ----- interval + ^ interval ifNil: [interval := 0.2]! - ^ interval! Item was changed: ----- Method: ScrollBar>>mouseDownInSlider: (in category 'other events') ----- mouseDownInSlider: event + self interval = self maximumValue ifTrue: - interval = self maximumValue ifTrue: ["make the entire scrollable area visible if a full scrollbar is clicked on" self setValue: 0. self model hideOrShowScrollBars.]. " super mouseDownInSlider: event" ! From bert at freudenbergs.de Thu Apr 9 09:54:49 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Thu Apr 9 09:54:53 2015 Subject: [squeak-dev] [BUG] List filters are not reset Message-ID: List filters are not reset anymore when clicking outside. The "Filterable Lists Clear Automatically" preference is enabled but apparently not honored. To reproduce: Open a new Test Runner, mouse over the class category list, type "rel" (to filter for release stuff), click elsewhere. Expected result: List returns from filtered pink state to white unfiltered state. Actual result: Nothing happens. There appears to be no way to get back the unfiltered view. - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/173005ac/smime.bin From bert at freudenbergs.de Thu Apr 9 10:03:14 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Thu Apr 9 10:03:17 2015 Subject: [squeak-dev] WeakArray species (was The Trunk: Collections-bf.612.mcz) In-Reply-To: References: <5523c7d5.162b370a.573d.5b8aSMTPIN_ADDED_MISSING@mx.google.com> <96F864DC-C66C-4A60-BED2-68E43988EF31@freudenbergs.de> Message-ID: <65D869D1-C084-45DF-94A8-DF1194F5A01D@freudenbergs.de> On 08.04.2015, at 18:03, Chris Muller wrote: > > The impetus for the change was so that (WeakArray new = Array new) > would return true instead of false. But we could accomplish that by > overriding #= instead of #species, I think.. > > Do you think overriding #species in WeakArray at this point in the > release process is too aggressive? Not sure. The #testNoObsoleteClasses test is still failing, even though there were fewer obsolete classes when we fixed WeakArray>>copyWith:. Would reverting #species help fix these for good? - Bert - > On Wed, Apr 8, 2015 at 6:16 AM, Bert Freudenberg wrote: >> On 08.04.2015, at 04:45, Chris Muller wrote: >>> >>> The change to override #species may not have gotten enough scrutiny. >>> It was a mere mention by Eliot in a prior thread, which I captured >>> into Collections-cmm.603. It may be worth some additional peer >>> scrutiny. It feels right on the surface but could such a change cause >>> negative impacts elsewhere? >> >> Oh, that was a recent change? I wondered why we never noticed the problems before. That explains it. >> >> - Bert - >> -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/f4667dac/smime.bin From bert at freudenbergs.de Thu Apr 9 10:04:53 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Thu Apr 9 10:04:56 2015 Subject: [squeak-dev] Time primitives In-Reply-To: <20150408120629.GA58602@shell.msen.com> References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> <7A458A46-A615-4517-B7D5-6C79FCEA4A0F@freudenbergs.de> <20150408120629.GA58602@shell.msen.com> Message-ID: > On 08.04.2015, at 14:06, David T. Lewis wrote: > > On Wed, Apr 08, 2015 at 10:56:13AM +0200, Bert Freudenberg wrote: >> On 08.04.2015, at 10:33, Levente Uzonyi wrote: >>> >>> DateAndTime now. "==> 2015-04-07T23:30:28.665+01:00" >>> DateAndTime now. "==> 2015-04-07T23:31:32.962+01:00" >>> >>> Both values are in the CET(+1) time zone, but the actual time zone is CEST(+2). Both images were started in CEST. >> >> Interesting. In an Etoys image on an Interpreter on Mac OS I get the right time zone: >> >> DateAndTime now >> ==>2015-04-08T10:49:33+02:00 >> >> That one uses LocalePlugin. >> >> Trunk image on Cog: >> >> DateAndTime now >> ==> 2015-04-08T10:48:38.991+01:00 >> >>> I'm telling that the LocalePlugin can find out the correct time zone in case of DST changes, but it seems like gettimeofday() can't. >> >> In Trunk, #useLocale is disabled (enabled in Etoys). Are we seriously all using +01:00 times, and still expecting users to set the right time zone manually?! >> > > That's a problem for sure, we should fix it in the upcoming release > > Dave So you're in a far away time zone, right? And yours still gets reported as +01:00? - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/dec3d215/smime.bin From marcel.taeumel at student.hpi.uni-potsdam.de Thu Apr 9 11:10:41 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Thu Apr 9 11:23:19 2015 Subject: [squeak-dev] Re: [BUG] List filters are not reset In-Reply-To: References: Message-ID: <1428577841460-4818542.post@n4.nabble.com> That bug seems to be related with the #mouseOverForKeyboardFocus preference. If that is off, I can reproduce it. Best, Marcel -- View this message in context: http://forum.world.st/BUG-List-filters-are-not-reset-tp4818526p4818542.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From Das.Linux at gmx.de Thu Apr 9 11:25:59 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 9 11:26:10 2015 Subject: [squeak-dev] [BUG] List filters are not reset In-Reply-To: References: Message-ID: <44D6FA71-6610-43C9-8333-C93CA0620356@gmx.de> On 09.04.2015, at 11:54, Bert Freudenberg wrote: > List filters are not reset anymore when clicking outside. The "Filterable Lists Clear Automatically" preference is enabled but apparently not honored. > > To reproduce: Open a new Test Runner, mouse over the class category list, type "rel" (to filter for release stuff), click elsewhere. > > Expected result: List returns from filtered pink state to white unfiltered state. > > Actual result: Nothing happens. There appears to be no way to get back the unfiltered view. no fix, but what happens if you type ESC or backspace? > - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 1625 bytes Desc: Message signed with OpenPGP using GPGMail Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/9b3d249a/signature.pgp From marcel.taeumel at student.hpi.uni-potsdam.de Thu Apr 9 11:22:27 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Thu Apr 9 11:35:04 2015 Subject: [squeak-dev] Re: [BUG] List filters are not reset In-Reply-To: <1428577841460-4818542.post@n4.nabble.com> References: <1428577841460-4818542.post@n4.nabble.com> Message-ID: <1428578547361-4818545.post@n4.nabble.com> Oh, my... I just learned something new. :) If morphs fail to grab the keyboard (i.e. "ActiveHand newKeyboardFocus: self"), the hand will start event processing at its owner, which is the ActiveWorld. When it does so, there will be no #keyboardFocusChange: notification sent to affected lists, which will thus not reset their filters. Some morphs that miss to grab the keyboard are: - PluggableListMorphOfMany (used in TestRunner) - PluggableTreeMorph (used in ObjectExplorer) When event processing starts at the world, things still seem to work because the foremost/topmost morph of the world will receive that event. Having this, the keyboard events because the hand is over that list, etc... We should both that keyboard grabbing this because this will also speed up event processing in those cases. Best, Marcel -- View this message in context: http://forum.world.st/BUG-List-filters-are-not-reset-tp4818526p4818545.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Thu Apr 9 11:55:16 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 9 11:55:20 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.849.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.849.mcz ==================== Summary ==================== Name: Morphic-mt.849 Author: mt Time: 9 April 2015, 1:54:41.384 pm UUID: 37f99479-4262-b749-a6e3-df4d6fbc5cd0 Ancestors: Morphic-mt.848 Fixed some widgets that failed to grab the keyboard on mouse-up, which is the normal way if #mouseOverForKeyboardFocus is not enabled in the preferences. =============== Diff against Morphic-mt.848 =============== Item was changed: ----- Method: AlternatePluggableListMorphOfMany>>mouseUp: (in category 'event handling') ----- mouseUp: event event hand newKeyboardFocus: self. + hasFocus := true.! - hasFocus := true. - ^self! Item was changed: ----- Method: PluggableListMorphOfMany>>mouseUp: (in category 'event handling') ----- mouseUp: event + dragOnOrOff := nil. "So improperly started drags will have not effect" + event hand newKeyboardFocus: self. + hasFocus := true.! - dragOnOrOff := nil. "So improperly started drags will have not effect"! Item was changed: ----- Method: SimpleHierarchicalListMorph>>mouseUp: (in category 'event handling') ----- mouseUp: event | aMorph | aMorph := self itemFromPoint: event position. aMorph ifNil: [^self]. aMorph highlightedForMouseDown ifFalse: [^self]. aMorph highlightForMouseDown: false. model okToChange ifFalse: [^self]. "No change if model is locked" ((autoDeselect isNil or: [autoDeselect]) and: [aMorph == selectedMorph]) ifTrue: [self setSelectedMorph: nil] ifFalse: [self setSelectedMorph: aMorph]. + event hand newKeyboardFocus: self. Cursor normal show! From commits at source.squeak.org Thu Apr 9 11:56:32 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 9 11:56:34 2015 Subject: [squeak-dev] The Trunk: System-mt.719.mcz Message-ID: Marcel Taeumel uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System-mt.719.mcz ==================== Summary ==================== Name: System-mt.719 Author: mt Time: 9 April 2015, 1:56:08.369 pm UUID: 22443288-c747-bb42-a402-3c8fd406ad4f Ancestors: System-topa.718 Removed menu-button pref from Preferences because it is now in ScrollBar class. =============== Diff against System-topa.718 =============== Item was removed: - ----- Method: Preferences class>>scrollBarsWithoutMenuButton (in category 'standard queries') ----- - scrollBarsWithoutMenuButton - ^ self - valueOfFlag: #scrollBarsWithoutMenuButton - ifAbsent: [ false ]! From commits at source.squeak.org Thu Apr 9 11:57:10 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 9 11:57:14 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.121.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.121.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.121 Author: mt Time: 9 April 2015, 1:57:04.47 pm UUID: 725b7bb5-175f-7442-8f90-40e66afa23c4 Ancestors: ToolBuilder-Morphic-mt.120 Missing super-send added to tree morph. =============== Diff against ToolBuilder-Morphic-mt.120 =============== Item was changed: ----- Method: PluggableTreeMorph>>keyboardFocusChange: (in category 'event handling') ----- keyboardFocusChange: aBoolean aBoolean ifFalse: [ PluggableListMorph clearFilterAutomatically ifTrue: + [ self hasFilter ifTrue: [ self removeFilter ] ] ]. + super keyboardFocusChange: aBoolean.! - [ self hasFilter ifTrue: [ self removeFilter ] ] ]! From marcel.taeumel at student.hpi.uni-potsdam.de Thu Apr 9 11:47:28 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Thu Apr 9 12:00:03 2015 Subject: [squeak-dev] Re: [BUG] List filters are not reset In-Reply-To: References: Message-ID: <1428580048058-4818559.post@n4.nabble.com> Should be fixed: http://forum.world.st/The-Trunk-Morphic-mt-849-mcz-td4818555.html Best, Marcel -- View this message in context: http://forum.world.st/BUG-List-filters-are-not-reset-tp4818526p4818559.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From Das.Linux at gmx.de Thu Apr 9 13:02:56 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 9 13:03:02 2015 Subject: [squeak-dev] Slack <-> IRC bridge Message-ID: Hi, I have set up a bridge between the Slack #public channel and the #squeak IRC channel on Freenode. I hope this is appreciated. If you want, I can mirror #general instead :) I think this makes the communication that is more actively happening on slack a little bit more available to the general public. Note that this took two integration hooks on slack and we have only five. Since the jenkins integration takes also one and an unconfigured service (probably accidental?) of Ben Coman the forth, we only have one left. If this is a problem, I'll cut down on that and disable the bridge :) Best -Tobias From bert at freudenbergs.de Thu Apr 9 13:43:03 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Thu Apr 9 13:43:07 2015 Subject: [squeak-dev] Re: [BUG] List filters are not reset In-Reply-To: <1428580048058-4818559.post@n4.nabble.com> References: <1428580048058-4818559.post@n4.nabble.com> Message-ID: On 09.04.2015, at 13:47, Marcel Taeumel wrote: > > Should be fixed: > http://forum.world.st/The-Trunk-Morphic-mt-849-mcz-td4818555.html Thank you! It's better, but not quite correct yet. If you just mouse over the test runner's category list and type without ever clicking inside the list, then clicking somewhere else will not clear the filter. Maybe we need to set the focus also when we're receiving the first filtering keystroke? - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/72c77fa3/smime.bin From bert at freudenbergs.de Thu Apr 9 13:46:20 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Thu Apr 9 13:46:26 2015 Subject: [squeak-dev] Re: [BUG] List filters are not reset In-Reply-To: References: <1428580048058-4818559.post@n4.nabble.com> Message-ID: Skipped content of type multipart/mixed-------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/8190dd36/smime-0001.bin From mbaehr at email.archlab.tuwien.ac.at Thu Apr 9 14:21:38 2015 From: mbaehr at email.archlab.tuwien.ac.at (=?utf-8?q?Martin_B=C3=A4hr?=) Date: Thu Apr 9 14:21:45 2015 Subject: [squeak-dev] Slack <-> IRC bridge In-Reply-To: References: Message-ID: <1428588384-sup-6735@email.archlab.tuwien.ac.at> Excerpts from Tobias Pape's message of 2015-04-09 15:02:56 +0200: > I have set up a bridge between > the Slack #public channel and the #squeak IRC channel on Freenode. > I hope this is appreciated. If you want, I can mirror #general instead :) > I think this makes the communication that is more actively happening on > slack a little bit more available to the general public. nice, though, could you maybe pick a shorter nickname for the bot? it takes up about half the space in an 80 column terminal: (15:25:48) squeak-slackbot:#squeak: : basically you want myobject-looklike-otherobject, so you get myobject's looklike-dot tile and drop a reference to otherobject into it (e.g. from otherobject's orange halo handle) with a short name it would look better: (15:25:48) sqb:#squeak: : basically you want myobject-looklike-otherobject, so you get myobject's looklike-dot tile and drop a reference to otherobject into it (e.g. from otherobject's orange halo handle) greetings, martin. -- eKita - the online platform for your entire academic life -- chief engineer eKita.co pike programmer pike.lysator.liu.se caudium.net societyserver.org secretary beijinglug.org mentor fossasia.org foresight developer foresightlinux.org realss.com unix sysadmin Martin B?hr working in china http://societyserver.org/mbaehr/ From karlramberg at gmail.com Thu Apr 9 14:48:48 2015 From: karlramberg at gmail.com (karl ramberg) Date: Thu Apr 9 14:48:51 2015 Subject: [squeak-dev] [BUG] Scrolling blows up after updating image Message-ID: Skipped content of type multipart/alternative-------------- next part -------------- A non-text attachment was scrubbed... Name: SqueakDebug.log Type: application/octet-stream Size: 14549 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/2c120277/SqueakDebug.obj From asqueaker at gmail.com Thu Apr 9 14:56:25 2015 From: asqueaker at gmail.com (Chris Muller) Date: Thu Apr 9 14:56:28 2015 Subject: [squeak-dev] The Trunk: Collections-tfel.613.mcz In-Reply-To: <552625a7.2111370a.530a.48abSMTPIN_ADDED_MISSING@mx.google.com> References: <552625a7.2111370a.530a.48abSMTPIN_ADDED_MISSING@mx.google.com> Message-ID: > Tim Felgentreff uploaded a new version of Collections to project The Trunk: > http://source.squeak.org/trunk/Collections-tfel.613.mcz > > ==================== Summary ==================== > > Name: Collections-tfel.613 > Author: tfel > Time: 9 April 2015, 9:09:08.368 am > UUID: 9e6e47d3-17ac-f847-976f-40872d002ab8 > Ancestors: Collections-bf.612 > > Fix replaceFrom:to:with:startingAt: for ByteArray if run on a VM without primitive 105 > > =============== Diff against Collections-bf.612 =============== > > Item was added: > + ----- Method: ByteArray>>at:put: (in category 'accessing') ----- > + at: index put: value > + "try primitiveAtPut, convert value to integer if that fails and try again" > + ^ self byteAt: index put: value asInteger Egads! This is a performance critical method that has now been slowed by half! old version: '94,500,000 per second. 10.6 nanoseconds per run.' new version: '49,400,000 per second. 20.3 nanoseconds per run.' When it comes to a low level operation like putting bytes into a ByteArray, the system should not be so forgiving if the user tried to put an invalid object in there. And look, it does not protect the user from doing: (ByteArray new: 1) at: 1 put: 300. So what are we really "protecting" from here? IMO, ByteArray's should be strict about users trying to manipulate them, not halfway forgiving and halfway strict. It should be the _callers_ responsibility to send #asInteger if necessary. > + ! > > Item was changed: > ----- Method: ByteArray>>byteAt: (in category 'accessing') ----- > byteAt: index > > + ^ super at: index! > - ^self at: index! Since there is no new implementation of ByteArray>>#at:, I guess this change makes no difference..? > Item was changed: > ----- Method: ByteArray>>byteAt:put: (in category 'accessing') ----- > byteAt: index put: value > > + ^ super at: index put: value! > - ^self at: index put: value! Calling super for a different method -- smells. This change could negatively affect Magma's performance. :-( Please, is there another way to accomplish what you want? From marcel.taeumel at student.hpi.uni-potsdam.de Thu Apr 9 14:48:48 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Thu Apr 9 15:01:26 2015 Subject: [squeak-dev] Re: [BUG] Scrolling blows up after updating image In-Reply-To: References: Message-ID: <1428590928265-4818606.post@n4.nabble.com> Oh, Spur. I think I have to update that MCM, too. But how? Best, Marcel -- View this message in context: http://forum.world.st/BUG-Scrolling-blows-up-after-updating-image-tp4818600p4818606.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From karlramberg at gmail.com Thu Apr 9 15:04:07 2015 From: karlramberg at gmail.com (karl ramberg) Date: Thu Apr 9 15:04:11 2015 Subject: [squeak-dev] Re: [BUG] Scrolling blows up after updating image In-Reply-To: <1428590928265-4818606.post@n4.nabble.com> References: <1428590928265-4818606.post@n4.nabble.com> Message-ID: Same happens in Cog trunk mage On Thu, Apr 9, 2015 at 4:48 PM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > Oh, Spur. I think I have to update that MCM, too. But how? > > Best, > Marcel > > > > -- > View this message in context: > http://forum.world.st/BUG-Scrolling-blows-up-after-updating-image-tp4818600p4818606.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/f7b0c462/attachment.htm From bert at freudenbergs.de Thu Apr 9 15:11:23 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Thu Apr 9 15:11:27 2015 Subject: [squeak-dev] The Trunk: Collections-tfel.613.mcz In-Reply-To: References: <552625a7.2111370a.530a.48abSMTPIN_ADDED_MISSING@mx.google.com> Message-ID: <34E4AA18-C466-4ABF-8FAC-98828777E102@freudenbergs.de> > On 09.04.2015, at 16:56, Chris Muller wrote: > >> Tim Felgentreff uploaded a new version of Collections to project The Trunk: >> http://source.squeak.org/trunk/Collections-tfel.613.mcz >> >> ==================== Summary ==================== >> >> Name: Collections-tfel.613 >> Author: tfel >> Time: 9 April 2015, 9:09:08.368 am >> UUID: 9e6e47d3-17ac-f847-976f-40872d002ab8 >> Ancestors: Collections-bf.612 >> >> Fix replaceFrom:to:with:startingAt: for ByteArray if run on a VM without primitive 105 >> >> =============== Diff against Collections-bf.612 =============== >> >> Item was added: >> + ----- Method: ByteArray>>at:put: (in category 'accessing') ----- >> + at: index put: value >> + "try primitiveAtPut, convert value to integer if that fails and try again" >> + ^ self byteAt: index put: value asInteger > > Egads! This is a performance critical method that has now been slowed by half! > > old version: '94,500,000 per second. 10.6 nanoseconds per run.' > new version: '49,400,000 per second. 20.3 nanoseconds per run.' What exactly are you testing? - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/6ec9509d/smime.bin From Das.Linux at gmx.de Thu Apr 9 15:15:14 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 9 15:15:18 2015 Subject: [squeak-dev] Spur CI job, odd failure Message-ID: <7C3DB7DF-8216-4D4C-8DCA-923E2F71212E@gmx.de> Hey can somebody spur-knowledgeable please look into why this spur startup and update fails? http://build.squeak.org/job/SqueakTrunkOnSpur/332/consoleFull best -Tobias From asqueaker at gmail.com Thu Apr 9 15:16:08 2015 From: asqueaker at gmail.com (Chris Muller) Date: Thu Apr 9 15:16:11 2015 Subject: [squeak-dev] The Trunk: Collections-tfel.613.mcz In-Reply-To: <34E4AA18-C466-4ABF-8FAC-98828777E102@freudenbergs.de> References: <552625a7.2111370a.530a.48abSMTPIN_ADDED_MISSING@mx.google.com> <34E4AA18-C466-4ABF-8FAC-98828777E102@freudenbergs.de> Message-ID: On Thu, Apr 9, 2015 at 10:11 AM, Bert Freudenberg wrote: > >> On 09.04.2015, at 16:56, Chris Muller wrote: >> >>> Tim Felgentreff uploaded a new version of Collections to project The Trunk: >>> http://source.squeak.org/trunk/Collections-tfel.613.mcz >>> >>> ==================== Summary ==================== >>> >>> Name: Collections-tfel.613 >>> Author: tfel >>> Time: 9 April 2015, 9:09:08.368 am >>> UUID: 9e6e47d3-17ac-f847-976f-40872d002ab8 >>> Ancestors: Collections-bf.612 >>> >>> Fix replaceFrom:to:with:startingAt: for ByteArray if run on a VM without primitive 105 >>> >>> =============== Diff against Collections-bf.612 =============== >>> >>> Item was added: >>> + ----- Method: ByteArray>>at:put: (in category 'accessing') ----- >>> + at: index put: value >>> + "try primitiveAtPut, convert value to integer if that fails and try again" >>> + ^ self byteAt: index put: value asInteger >> >> Egads! This is a performance critical method that has now been slowed by half! >> >> old version: '94,500,000 per second. 10.6 nanoseconds per run.' >> new version: '49,400,000 per second. 20.3 nanoseconds per run.' > > What exactly are you testing? |ba| ba:= ByteArray new: 1. [ba byteAt: 1 put: 200] bench and |ba| ba:= ByteArray new: 1. [ba at: 1 put: 200] bench From frank.shearar at gmail.com Thu Apr 9 15:17:55 2015 From: frank.shearar at gmail.com (Frank Shearar) Date: Thu Apr 9 15:17:57 2015 Subject: [squeak-dev] Spur CI job, odd failure In-Reply-To: <7C3DB7DF-8216-4D4C-8DCA-923E2F71212E@gmx.de> References: <7C3DB7DF-8216-4D4C-8DCA-923E2F71212E@gmx.de> Message-ID: On 9 April 2015 at 16:15, Tobias Pape wrote: > Hey > > can somebody spur-knowledgeable please look into > why this spur startup and update fails? > > http://build.squeak.org/job/SqueakTrunkOnSpur/332/consoleFull Just to spare people a click, here's the stack trace. I've not seen it before! vvvvvvvvvvvvvvvvvv Error: SmallInteger cannot be changed vvvvvvvvvvvvvvvvvv The time is 2015-04-09T17:13:59.849+01:00 ClassBuilder(Object)>>error: [] in ClassBuilder>>name:inEnvironment:subclassOf:type:instanceVariableNames:classVariableNames:poolDictionaries:category:unsafe: BlockClosure>>ensure: ClassBuilder>>name:inEnvironment:subclassOf:type:instanceVariableNames:classVariableNames:poolDictionaries:category:unsafe: ClassBuilder>>name:inEnvironment:subclassOf:type:instanceVariableNames:classVariableNames:poolDictionaries:category: [] in MCClassDefinition>>createClass BlockClosure>>on:do: MCClassDefinition>>createClass MCClassDefinition>>load [] in [] in [] in [] in [] in MCPackageLoader>>basicLoad [] in [] in OrderedCollection(Collection)>>do:displayingProgress:every: OrderedCollection>>do: [] in OrderedCollection(Collection)>>do:displayingProgress:every: [] in [] in MorphicUIManager>>displayProgress:at:from:to:during: BlockClosure>>on:do: [] in MorphicUIManager>>displayProgress:at:from:to:during: BlockClosure>>ensure: MorphicUIManager>>displayProgress:at:from:to:during: ProgressInitiationException>>defaultResumeValue ProgressInitiationException(Exception)>>resume ProgressInitiationException>>defaultAction UndefinedObject>>handleSignal: MethodContext(ContextPart)>>handleSignal: MethodContext(ContextPart)>>handleSignal: MethodContext(ContextPart)>>handleSignal: MethodContext(ContextPart)>>handleSignal: MethodContext(ContextPart)>>handleSignal: MethodContext(ContextPart)>>handleSignal: MethodContext(ContextPart)>>handleSignal: MethodContext(ContextPart)>>handleSignal: MethodContext(ContextPart)>>handleSignal: MethodContext(ContextPart)>>handleSignal: MethodContext(ContextPart)>>handleSignal: ProgressInitiationException(Exception)>>signal ProgressInitiationException>>display:at:from:to:during: ProgressInitiationException class>>display:at:from:to:during: ByteString(String)>>displayProgressAt:from:to:during: ByteString(String)>>displayProgressFrom:to:during: OrderedCollection(Collection)>>do:displayingProgress:every: OrderedCollection(Collection)>>do:displayingProgress: [] in [] in [] in [] in MCPackageLoader>>basicLoad BlockClosure>>on:do: [] in [] in [] in MCPackageLoader>>basicLoad BlockClosure>>on:do: CurrentReadOnlySourceFiles class>>cacheDuring: [] in [] in MCPackageLoader>>basicLoad BlockClosure>>ensure: [] in MCPackageLoader>>basicLoad BlockClosure>>ensure: RecentMessages>>suspendWhile: MCPackageLoader>>basicLoad [] in MCPackageLoader>>loadWithNameLike: BlockClosure>>ensure: MCPackageLoader>>useChangeSetNamed:during: MCPackageLoader>>useNewChangeSetNamedLike:during: MCPackageLoader>>loadWithNameLike: MCThreeWayMerger(MCMerger)>>loadWithNameLike: MCVersionMerger>>mergeWithNameLike: MCVersionMerger class>>mergeVersion: MCDiffyVersion(MCVersion)>>merge [] in [] in MCConfiguration>>upgrade BlockClosure>>on:do: [] in MCConfiguration>>upgrade [] in [] in MCConfiguration>>depsSatisfying:versionDo:displayingProgress: OrderedCollection>>do: MCConfiguration>>withProgress:in:do: [] in MCConfiguration>>depsSatisfying:versionDo:displayingProgress: MCHttpRepository(MCFileBasedRepository)>>cacheAllFileNamesDuring: [] in [] in MCConfiguration>>cacheAllFileNamesDuring: MCConfiguration>>cacheAllFileNamesDuring: MCConfiguration>>depsSatisfying:versionDo:displayingProgress: MCConfiguration>>upgrade [] in [] in [] in [] in MCMcmUpdater class>>updateFromRepositories: [] in [] in OrderedCollection(Collection)>>do:displayingProgress:every: OrderedCollection>>do: [] in OrderedCollection(Collection)>>do:displayingProgress:every: [] in [] in MorphicUIManager>>displayProgress:at:from:to:during: BlockClosure>>on:do: [] in MorphicUIManager>>displayProgress:at:from:to:during: BlockClosure>>ensure: MorphicUIManager>>displayProgress:at:from:to:during: ProgressInitiationException>>defaultResumeValue ProgressInitiationException(Exception)>>resume [] in [] in UndefinedObject>>DoIt BlockClosure>>cull: [] in MethodContext(ContextPart)>>handleSignal: BlockClosure>>ensure: MethodContext(ContextPart)>>handleSignal: MethodContext(ContextPart)>>handleSignal: MethodContext(ContextPart)>>handleSignal: ProgressInitiationException(Exception)>>signal ProgressInitiationException>>display:at:from:to:during: ProgressInitiationException class>>display:at:from:to:during: ByteString(String)>>displayProgressAt:from:to:during: ByteString(String)>>displayProgressFrom:to:during: OrderedCollection(Collection)>>do:displayingProgress:every: OrderedCollection(Collection)>>do:displayingProgress: [] in [] in [] in MCMcmUpdater class>>updateFromRepositories: BlockClosure>>valueWithPossibleArgument: OrderedCollection(Collection)>>ifNotEmpty: ^^^^^^^^^^^^^^^^^^ Error: SmallInteger cannot be changed ^^^^^^^^^^^^^^^^^^ frank From commits at source.squeak.org Thu Apr 9 15:27:56 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 9 15:27:59 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.850.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.850.mcz ==================== Summary ==================== Name: Morphic-mt.850 Author: mt Time: 9 April 2015, 5:27:19.129 pm UUID: 33830fe6-93af-9e40-9fbc-4ab9b925b71d Ancestors: Morphic-mt.849 Fixed scroll pane (i.e. text boxes) creation when preference "always show H/V scrollbar" was enabled. =============== Diff against Morphic-mt.849 =============== Item was changed: ----- Method: PluggableTextMorph>>scrollDeltaHeight (in category 'geometry') ----- scrollDeltaHeight "Return the increment in pixels which this pane should be scrolled." + ^ textMorph ifNil: [super scrollDeltaHeight] ifNotNil: [:tm | tm defaultLineHeight] - ^ scroller firstSubmorph defaultLineHeight ! Item was changed: ----- Method: SimpleHierarchicalListMorph>>scrollDeltaHeight (in category 'geometry') ----- scrollDeltaHeight + ^ scroller hasSubmorphs + ifTrue: [scroller firstSubmorph height] + ifFalse: [super scrollDeltaHeight]! - ^ scroller firstSubmorph height! From marcel.taeumel at student.hpi.uni-potsdam.de Thu Apr 9 15:16:23 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Thu Apr 9 15:29:03 2015 Subject: [squeak-dev] Re: [BUG] Scrolling blows up after updating image In-Reply-To: References: <1428590928265-4818606.post@n4.nabble.com> Message-ID: <1428592583371-4818618.post@n4.nabble.com> Found it. Fixed it. :) http://forum.world.st/The-Trunk-Morphic-mt-850-mcz-td4818617.html Best, Marcel -- View this message in context: http://forum.world.st/BUG-Scrolling-blows-up-after-updating-image-tp4818600p4818618.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Thu Apr 9 15:23:13 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Thu Apr 9 15:35:51 2015 Subject: [squeak-dev] Re: The Trunk: Collections-tfel.613.mcz In-Reply-To: References: <34E4AA18-C466-4ABF-8FAC-98828777E102@freudenbergs.de> Message-ID: <1428592993105-4818619.post@n4.nabble.com> With this bench code, there shouldn't be any difference at all if your VM has primitive 61. 200 actually is an integer, isn't it? :) Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Collections-tfel-613-mcz-tp4818483p4818619.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Thu Apr 9 15:24:04 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Thu Apr 9 15:36:43 2015 Subject: [squeak-dev] Re: The Trunk: Collections-tfel.613.mcz In-Reply-To: <1428592993105-4818619.post@n4.nabble.com> References: <34E4AA18-C466-4ABF-8FAC-98828777E102@freudenbergs.de> <1428592993105-4818619.post@n4.nabble.com> Message-ID: <1428593044917-4818620.post@n4.nabble.com> Oh, 60, 61, ... misread the numbers. Please ignore. Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Collections-tfel-613-mcz-tp4818483p4818620.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From bert at freudenbergs.de Thu Apr 9 16:19:20 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Thu Apr 9 16:19:23 2015 Subject: [squeak-dev] The Trunk: Collections-tfel.613.mcz In-Reply-To: References: <552625a7.2111370a.530a.48abSMTPIN_ADDED_MISSING@mx.google.com> <34E4AA18-C466-4ABF-8FAC-98828777E102@freudenbergs.de> Message-ID: On 09.04.2015, at 17:16, Chris Muller wrote: > > On Thu, Apr 9, 2015 at 10:11 AM, Bert Freudenberg wrote: >>> >>> Egads! This is a performance critical method that has now been slowed by half! >>> >>> old version: '94,500,000 per second. 10.6 nanoseconds per run.' >>> new version: '49,400,000 per second. 20.3 nanoseconds per run.' >> >> What exactly are you testing? > > |ba| ba:= ByteArray new: 1. > [ba byteAt: 1 put: 200] bench > > and > > |ba| ba:= ByteArray new: 1. > [ba at: 1 put: 200] bench These two are not equivalent. #at:put: is optimized by the VM. I would be very surprised if Tim's changes have any effect on performance one way or other. They're purely about correctness. To test, you would have to run the exact same code before and after updating. - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/c637c54e/smime.bin From karlramberg at gmail.com Thu Apr 9 16:46:16 2015 From: karlramberg at gmail.com (karl ramberg) Date: Thu Apr 9 16:46:19 2015 Subject: [squeak-dev] Re: [BUG] Scrolling blows up after updating image In-Reply-To: <1428592583371-4818618.post@n4.nabble.com> References: <1428590928265-4818606.post@n4.nabble.com> <1428592583371-4818618.post@n4.nabble.com> Message-ID: This seems to fix it. But updating the image still stops with a walkback that has to bee proceeded. Maybe the fix could be added to a earlier commit ? Karl On Thu, Apr 9, 2015 at 5:16 PM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > Found it. Fixed it. :) > > http://forum.world.st/The-Trunk-Morphic-mt-850-mcz-td4818617.html > > Best, > Marcel > > > > -- > View this message in context: > http://forum.world.st/BUG-Scrolling-blows-up-after-updating-image-tp4818600p4818618.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/0ff3e185/attachment.htm From karlramberg at gmail.com Thu Apr 9 16:46:36 2015 From: karlramberg at gmail.com (karl ramberg) Date: Thu Apr 9 16:46:39 2015 Subject: [squeak-dev] Re: [BUG] Scrolling blows up after updating image In-Reply-To: <1428592583371-4818618.post@n4.nabble.com> References: <1428590928265-4818606.post@n4.nabble.com> <1428592583371-4818618.post@n4.nabble.com> Message-ID: This seems to fix it. But updating the image still stops with a walkback that has to bee proceeded. Maybe the fix could be added to a earlier commit so there are no walkbacks in it ? Karl On Thu, Apr 9, 2015 at 5:16 PM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > Found it. Fixed it. :) > > http://forum.world.st/The-Trunk-Morphic-mt-850-mcz-td4818617.html > > Best, > Marcel > > > > -- > View this message in context: > http://forum.world.st/BUG-Scrolling-blows-up-after-updating-image-tp4818600p4818618.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/b2c00035/attachment.htm From Das.Linux at gmx.de Thu Apr 9 18:27:25 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 9 18:27:35 2015 Subject: [squeak-dev] WeakArray species (was The Trunk: Collections-bf.612.mcz) In-Reply-To: <65D869D1-C084-45DF-94A8-DF1194F5A01D@freudenbergs.de> References: <5523c7d5.162b370a.573d.5b8aSMTPIN_ADDED_MISSING@mx.google.com> <96F864DC-C66C-4A60-BED2-68E43988EF31@freudenbergs.de> <65D869D1-C084-45DF-94A8-DF1194F5A01D@freudenbergs.de> Message-ID: Hi, On 09.04.2015, at 12:03, Bert Freudenberg wrote: > On 08.04.2015, at 18:03, Chris Muller wrote: >> >> The impetus for the change was so that (WeakArray new = Array new) >> would return true instead of false. But we could accomplish that by >> overriding #= instead of #species, I think.. >> >> Do you think overriding #species in WeakArray at this point in the >> release process is too aggressive? > > Not sure. The #testNoObsoleteClasses test is still failing, even though there were fewer obsolete classes when we fixed WeakArray>>copyWith:. Would reverting #species help fix these for good? I am unsure. Is there a weak-ref-guru out there? Best -Tobias -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 1625 bytes Desc: Message signed with OpenPGP using GPGMail Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/1aab261e/signature.pgp From jannik.laval at gmail.com Thu Apr 9 19:41:38 2015 From: jannik.laval at gmail.com (jannik laval) Date: Thu Apr 9 19:41:42 2015 Subject: [squeak-dev] CFP IWST 2015 - Deadline extension - 17th April Message-ID: Please note that the deadline has been extended to the 17th April 2015 . [Please accept our apologies if you receive multiple copies of this call] [Please send to interested colleagues / mailing-lists] ************************************************************************************************************ CALL FOR PAPERS IWST15 ? International Workshop on Smalltalk Technologies Brescia, Italy; July 15, 2015 http://www.esug.org/wiki/pier/Conferences/2015/International-Workshop-IWST_15 ************************************************************************************************************ ------------------- Goals and scopes ------------------- The goals of the workshop is to create a forum around advances or experience in Smalltalk and to trigger discussions and exchanges of ideas. The topics of your paper can be on all aspect of Smalltalk, theoretical as well as practical. Participants are invited to submit research articles or industrial papers. This year we want to open two different tracks: one research track and one industrial track with less scientific constraints. We expect papers of three kinds: Short position papers describing emerging ideas Long research papers with deeper description of experiments and of research results. Industrial papers with presentation of real and innovative Smalltalk applications; this kind of paper should enlighten why Smalltalk is really appropriate for your application. We will not enforce any length restriction. -------------------- Important Dates -------------------- *Submission deadline: April 17th, 2015* Notification deadline: May 20th, 2015 Workshop : July 15th, 2015 All accepted papers will be published in ACM DL ------------------- Topics ------------------- We welcome contributions on all aspects, theoretical as well as practical, of Smalltalk related topics such as: -Aspect-oriented programming, -Design patterns, -Experience reports, -Frameworks, -Implementation, new dialects or languages implemented in Smalltalk, -Interaction with other languages, -Meta-programming and Meta-modeling, -Tools ------------------- Best Paper Award ------------------- To encourage the submission of high-quality papers, the IWST organizing committee is very proud to announce a Best Paper Award for this edition of IWST. We thank the Lam Research Corporation for its financial contribution which makes it possible for prizes for the three best papers: 1000 USD for first place, 600 USD for second place and 400 USD for third place. The ranking will be decided by the program committee during the review process. The awards will be given during the ESUG conference social event. The Best Paper Award will take place only with a minimum of six submissions. Notice also that to be eligible, a paper must be presented at the workshop by one of the author and that the presenting author must be registered at the ESUG conference. ------------------- Publication ------------------- Both submissions and final papers must be prepared using the ACM SIGPLAN 10 point format. Templates for Word and LaTeX are available at http://www.acm.org/sigs/sigplan/authorInformation.htm. This site also contains links to useful informations on how to write effective submissions. ------------------- Submission ------------------- All submissions must be sent via easychair: https://easychair.org/conferences/?conf=iwst2015 ------------------- Program chairs ------------------- Anne Etien (Universit? de Lille 1, France) Jannik Laval (Ecole des Mines de Douai, France) -- ~~Jannik Laval~~ ?cole des Mines de Douai Enseignant-chercheur http://www.jannik-laval.eu http://www.phratch.com http://www.approchealpes.info http://car.mines-douai.fr/ -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/a23c3966/attachment-0001.htm From commits at source.squeak.org Thu Apr 9 20:08:49 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 9 20:08:51 2015 Subject: [squeak-dev] The Trunk: Multilingual-topa.204.mcz Message-ID: Tobias Pape uploaded a new version of Multilingual to project The Trunk: http://source.squeak.org/trunk/Multilingual-topa.204.mcz ==================== Summary ==================== Name: Multilingual-topa.204 Author: topa Time: 9 April 2015, 10:08:35.736 pm UUID: 40a54e5e-4841-4820-b767-ad2354e6f21f Ancestors: Multilingual-topa.203 Ensure toLower et al work on WideStrings =============== Diff against Multilingual-topa.203 =============== Item was changed: (PackageInfo named: 'Multilingual') postscript: '"Remove CrLfFileStream from the startupList" (Smalltalk classNamed: ''CrLfFileStream'') ifNotNil: [ :class | + Smalltalk removeFromStartUpList: class ]. + "Ensure toLower et al work on WideStrings" + Unicode + initialize; + initializeCaseMappings. + '! - Smalltalk removeFromStartUpList: class ]'! From leves at elte.hu Thu Apr 9 20:29:19 2015 From: leves at elte.hu (Levente Uzonyi) Date: Thu Apr 9 20:29:22 2015 Subject: [squeak-dev] The Trunk: Multilingual-topa.204.mcz In-Reply-To: References: Message-ID: CrLfFileStream was removed from the startup list many .mcm files ago, so this is one of those cases, where it's better to remove it when you change the postscript. Levente On Thu, 9 Apr 2015, commits@source.squeak.org wrote: > Tobias Pape uploaded a new version of Multilingual to project The Trunk: > http://source.squeak.org/trunk/Multilingual-topa.204.mcz > > ==================== Summary ==================== > > Name: Multilingual-topa.204 > Author: topa > Time: 9 April 2015, 10:08:35.736 pm > UUID: 40a54e5e-4841-4820-b767-ad2354e6f21f > Ancestors: Multilingual-topa.203 > > Ensure toLower et al work on WideStrings > > =============== Diff against Multilingual-topa.203 =============== > > Item was changed: > (PackageInfo named: 'Multilingual') postscript: '"Remove CrLfFileStream from the startupList" > (Smalltalk classNamed: ''CrLfFileStream'') ifNotNil: [ :class | > + Smalltalk removeFromStartUpList: class ]. > + "Ensure toLower et al work on WideStrings" > + Unicode > + initialize; > + initializeCaseMappings. > + '! > - Smalltalk removeFromStartUpList: class ]'! > > > From Das.Linux at gmx.de Thu Apr 9 20:34:51 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 9 20:34:55 2015 Subject: [squeak-dev] The Trunk: Multilingual-topa.204.mcz In-Reply-To: References: Message-ID: <091A7EA8-A698-48E3-AAE4-C058FB4A496B@gmx.de> On 09.04.2015, at 22:29, Levente Uzonyi wrote: > CrLfFileStream was removed from the startup list many .mcm files ago, so this is one of those cases, where it's better to remove it when you change the postscript. Oh dear :D Can you forgive me that I leave it in there? Best -Tobias PS: See the string argument to classNamed: *IshowMyselfOut* *SCNR* > > Levente > > On Thu, 9 Apr 2015, commits@source.squeak.org wrote: > >> Tobias Pape uploaded a new version of Multilingual to project The Trunk: >> http://source.squeak.org/trunk/Multilingual-topa.204.mcz >> >> ==================== Summary ==================== >> >> Name: Multilingual-topa.204 >> Author: topa >> Time: 9 April 2015, 10:08:35.736 pm >> UUID: 40a54e5e-4841-4820-b767-ad2354e6f21f >> Ancestors: Multilingual-topa.203 >> >> Ensure toLower et al work on WideStrings >> >> =============== Diff against Multilingual-topa.203 =============== >> >> Item was changed: >> (PackageInfo named: 'Multilingual') postscript: '"Remove CrLfFileStream from the startupList" >> (Smalltalk classNamed: ''CrLfFileStream'') ifNotNil: [ :class | >> + Smalltalk removeFromStartUpList: class ]. >> + "Ensure toLower et al work on WideStrings" >> + Unicode >> + initialize; >> + initializeCaseMappings. >> + '! >> - Smalltalk removeFromStartUpList: class ]'! From asqueaker at gmail.com Thu Apr 9 20:47:12 2015 From: asqueaker at gmail.com (Chris Muller) Date: Thu Apr 9 20:47:15 2015 Subject: [squeak-dev] The Trunk: Collections-tfel.613.mcz In-Reply-To: References: <552625a7.2111370a.530a.48abSMTPIN_ADDED_MISSING@mx.google.com> <34E4AA18-C466-4ABF-8FAC-98828777E102@freudenbergs.de> Message-ID: I made a mistake in my earlier benching -- one image was Spur the other was Cog, oops! Still, there is a > 5% speed loss in byteAt:put:, which is strange unless that prim is failing... |ba| ba:= ByteArray new: 1. [ba byteAt: 1 put: 200] bench bf-612: '92,700,000 per second. 10.8 nanoseconds per run.' tfel.613: '87,900,000 per second. 11.4 nanoseconds per run.' What also is not so elegant is the inconsistency with ByteString. ByteString>>#byteAt:put: ---> coercion on prim fail ByteArray>>#byteAt:put: ---> no-coercion on prim fail ByteString>>#at:put: ----> no-coercion on prim fail ByteArray>>#at:put: ----> coercion on prim fail IMHO, #at:put: should fail if the wrong type of argument is passed. Also, I don't understand the change to ByteArray>>#byteAt:. Since there is no #at: implementation in ByteArray, isn't the change to call super unnecessary..? On Thu, Apr 9, 2015 at 11:19 AM, Bert Freudenberg wrote: > On 09.04.2015, at 17:16, Chris Muller wrote: >> >> On Thu, Apr 9, 2015 at 10:11 AM, Bert Freudenberg wrote: >>>> >>>> Egads! This is a performance critical method that has now been slowed by half! >>>> >>>> old version: '94,500,000 per second. 10.6 nanoseconds per run.' >>>> new version: '49,400,000 per second. 20.3 nanoseconds per run.' >>> >>> What exactly are you testing? >> >> |ba| ba:= ByteArray new: 1. >> [ba byteAt: 1 put: 200] bench >> >> and >> >> |ba| ba:= ByteArray new: 1. >> [ba at: 1 put: 200] bench > > These two are not equivalent. #at:put: is optimized by the VM. > > I would be very surprised if Tim's changes have any effect on performance one way or other. They're purely about correctness. > > To test, you would have to run the exact same code before and after updating. > > - Bert - > > > > From eliot.miranda at gmail.com Thu Apr 9 21:08:15 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Thu Apr 9 21:08:17 2015 Subject: [squeak-dev] Spur CI job, odd failure In-Reply-To: References: <7C3DB7DF-8216-4D4C-8DCA-923E2F71212E@gmx.de> Message-ID: Hi, when SmallIInteger gets redefined (I expect to add minVal and maxVal class side inst vars) this error from the class builder needs to be proceeded through. SmallInteger /can/ be redefined, but only do far ;-)/ On Thu, Apr 9, 2015 at 8:17 AM, Frank Shearar wrote: > On 9 April 2015 at 16:15, Tobias Pape wrote: > > Hey > > > > can somebody spur-knowledgeable please look into > > why this spur startup and update fails? > > > > http://build.squeak.org/job/SqueakTrunkOnSpur/332/consoleFull > > Just to spare people a click, here's the stack trace. I've not seen it > before! > > vvvvvvvvvvvvvvvvvv Error: SmallInteger cannot be changed vvvvvvvvvvvvvvvvvv > The time is 2015-04-09T17:13:59.849+01:00 > ClassBuilder(Object)>>error: > [] in > ClassBuilder>>name:inEnvironment:subclassOf:type:instanceVariableNames:classVariableNames:poolDictionaries:category:unsafe: > BlockClosure>>ensure: > > ClassBuilder>>name:inEnvironment:subclassOf:type:instanceVariableNames:classVariableNames:poolDictionaries:category:unsafe: > > ClassBuilder>>name:inEnvironment:subclassOf:type:instanceVariableNames:classVariableNames:poolDictionaries:category: > [] in MCClassDefinition>>createClass > BlockClosure>>on:do: > MCClassDefinition>>createClass > MCClassDefinition>>load > [] in [] in [] in [] in [] in MCPackageLoader>>basicLoad > [] in [] in OrderedCollection(Collection)>>do:displayingProgress:every: > OrderedCollection>>do: > [] in OrderedCollection(Collection)>>do:displayingProgress:every: > [] in [] in MorphicUIManager>>displayProgress:at:from:to:during: > BlockClosure>>on:do: > [] in MorphicUIManager>>displayProgress:at:from:to:during: > BlockClosure>>ensure: > MorphicUIManager>>displayProgress:at:from:to:during: > ProgressInitiationException>>defaultResumeValue > ProgressInitiationException(Exception)>>resume > ProgressInitiationException>>defaultAction > UndefinedObject>>handleSignal: > MethodContext(ContextPart)>>handleSignal: > MethodContext(ContextPart)>>handleSignal: > MethodContext(ContextPart)>>handleSignal: > MethodContext(ContextPart)>>handleSignal: > MethodContext(ContextPart)>>handleSignal: > MethodContext(ContextPart)>>handleSignal: > MethodContext(ContextPart)>>handleSignal: > MethodContext(ContextPart)>>handleSignal: > MethodContext(ContextPart)>>handleSignal: > MethodContext(ContextPart)>>handleSignal: > MethodContext(ContextPart)>>handleSignal: > ProgressInitiationException(Exception)>>signal > ProgressInitiationException>>display:at:from:to:during: > ProgressInitiationException class>>display:at:from:to:during: > ByteString(String)>>displayProgressAt:from:to:during: > ByteString(String)>>displayProgressFrom:to:during: > OrderedCollection(Collection)>>do:displayingProgress:every: > OrderedCollection(Collection)>>do:displayingProgress: > [] in [] in [] in [] in MCPackageLoader>>basicLoad > BlockClosure>>on:do: > [] in [] in [] in MCPackageLoader>>basicLoad > BlockClosure>>on:do: > CurrentReadOnlySourceFiles class>>cacheDuring: > [] in [] in MCPackageLoader>>basicLoad > BlockClosure>>ensure: > [] in MCPackageLoader>>basicLoad > BlockClosure>>ensure: > RecentMessages>>suspendWhile: > MCPackageLoader>>basicLoad > [] in MCPackageLoader>>loadWithNameLike: > BlockClosure>>ensure: > MCPackageLoader>>useChangeSetNamed:during: > MCPackageLoader>>useNewChangeSetNamedLike:during: > MCPackageLoader>>loadWithNameLike: > MCThreeWayMerger(MCMerger)>>loadWithNameLike: > MCVersionMerger>>mergeWithNameLike: > MCVersionMerger class>>mergeVersion: > MCDiffyVersion(MCVersion)>>merge > [] in [] in MCConfiguration>>upgrade > BlockClosure>>on:do: > [] in MCConfiguration>>upgrade > [] in [] in MCConfiguration>>depsSatisfying:versionDo:displayingProgress: > OrderedCollection>>do: > MCConfiguration>>withProgress:in:do: > [] in MCConfiguration>>depsSatisfying:versionDo:displayingProgress: > MCHttpRepository(MCFileBasedRepository)>>cacheAllFileNamesDuring: > [] in [] in MCConfiguration>>cacheAllFileNamesDuring: > MCConfiguration>>cacheAllFileNamesDuring: > MCConfiguration>>depsSatisfying:versionDo:displayingProgress: > MCConfiguration>>upgrade > [] in [] in [] in [] in MCMcmUpdater class>>updateFromRepositories: > [] in [] in OrderedCollection(Collection)>>do:displayingProgress:every: > OrderedCollection>>do: > [] in OrderedCollection(Collection)>>do:displayingProgress:every: > [] in [] in MorphicUIManager>>displayProgress:at:from:to:during: > BlockClosure>>on:do: > [] in MorphicUIManager>>displayProgress:at:from:to:during: > BlockClosure>>ensure: > MorphicUIManager>>displayProgress:at:from:to:during: > ProgressInitiationException>>defaultResumeValue > ProgressInitiationException(Exception)>>resume > [] in [] in UndefinedObject>>DoIt > BlockClosure>>cull: > [] in MethodContext(ContextPart)>>handleSignal: > BlockClosure>>ensure: > MethodContext(ContextPart)>>handleSignal: > MethodContext(ContextPart)>>handleSignal: > MethodContext(ContextPart)>>handleSignal: > ProgressInitiationException(Exception)>>signal > ProgressInitiationException>>display:at:from:to:during: > ProgressInitiationException class>>display:at:from:to:during: > ByteString(String)>>displayProgressAt:from:to:during: > ByteString(String)>>displayProgressFrom:to:during: > OrderedCollection(Collection)>>do:displayingProgress:every: > OrderedCollection(Collection)>>do:displayingProgress: > [] in [] in [] in MCMcmUpdater class>>updateFromRepositories: > BlockClosure>>valueWithPossibleArgument: > OrderedCollection(Collection)>>ifNotEmpty: > > ^^^^^^^^^^^^^^^^^^ Error: SmallInteger cannot be changed ^^^^^^^^^^^^^^^^^^ > > frank > > -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/4f818699/attachment.htm From eliot.miranda at gmail.com Thu Apr 9 21:28:50 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Thu Apr 9 21:28:52 2015 Subject: [squeak-dev] New Cog VMs available Message-ID: ... at http://www.mirandabanda.org/files/Cog/VM/VM.r3308/. CogVM binaries as per VMMaker.oscog-eem.1178/r3308 Plugins: Integrate Nicolas' fixes that use positiveMachineIntegerFor: for pointers. Newspeak: Print a warning in the method shared under multiple selectors scenario. Implement outer sends as clean sends just like implicit receiver sends. Add ObjectRepresentation>>illegalClassTag and use it for initializing and unlinking implicit and outer sends. Newspeak & Sista: The multiple bytecode set block initial nil counters need to be specific to the bytecode set in effect. Spur: Implement Clement's much better solution for the stale supersend problem. Place code at the send site for super sends to follow stale forwarded receivers. This parallels the interpreter implementation. Beef up the post-become scan of send sites to unlink all send sites that link to an invalid class tag. Cogit: Optimize StackToRegisterMappingCogit>>genReturnReceiver to not load ReceiverResultReg if it already contains self. Revise method map generation to provide multiple send type annotations. Add an IsAnnotationExtension annotation type that implicitly has a zero displacement and uses its displacement bits to extend the preceeding IsSendCall annotation. This allows us to eliminate all the exotic entry-points and keep only the checked and unchecked entries. Change IA32's genPushRegisterArgsForNumArgs: to not smash TempReg now that it is used in directed super send trampolines. Use PushCq to pass small integer constants in the trampolines instead of smashing TempReg, which is now used to hold the directed supersend argument. Add support for PushCq. Could use PushCw but on x86 PushCq is a lot shorter. Mac builds: Use UTC as the timezone for the build timestamp. Using the local timezone doesn't work :(. -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/da42acf0/attachment.htm From Das.Linux at gmx.de Thu Apr 9 21:38:06 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 9 21:38:11 2015 Subject: [squeak-dev] New Cog VMs available In-Reply-To: References: Message-ID: <1A959CB4-7121-4D91-8395-852B3B563835@gmx.de> Hi Eliot, On 15.02.2015, at 19:13, Eliot Miranda wrote: > Hi Frank, > > can you revert to 3253? This one should be good. I'm pretty sure the 3254 VMs are subject to the same inlning bug that I mentioned after the latest VMMaker.oscog commit and am working on fixing now. > As this bug is probably long fixed, what version would you suggest for the CI server now? Best -Tobias > On Sat, Feb 14, 2015 at 5:47 AM, Frank Shearar wrote: > On 12 February 2015 at 20:42, Eliot Miranda wrote: > > http://www.mirandabanda.org/files/Cog/VM/VM.r3254/ > > > > > > These fix two important bugs in the Spur VMs, so Newspeakers should update, > > and changes the default text encoding to UTF-8 on linux. > > I updated CI with 3254, and now I see errors like this: > > spawning command 1 with timeout 1500 seconds: > /var/lib/jenkins/workspace/SqueakTrunk/target/cog.r3254/coglinuxht/bin/squeak > -vm-sound-null -vm-display-null > "/var/lib/jenkins/workspace/SqueakTrunk/target/TrunkImage.image" > ../update-image.st > pthread_setschedparam failed: Operation not permitted > Read e.g. http://www.mirandabanda.org/files/Cog/VM/VM.r3254/README.3254 > > As it happens, we do have a /etc/security/limits.d/squeak.conf on > build.squeak.org that looks like this: > > * hard rtprio 2 > * soft rtprio 2 > > Thoughts? > > frank From commits at source.squeak.org Thu Apr 9 21:55:05 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 9 21:55:06 2015 Subject: [squeak-dev] Daily Commit Log Message-ID: <20150409215505.19162.qmail@box4.squeakfoundation.org> Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours: http://lists.squeakfoundation.org/pipermail/packages/2015-April/007874.html Name: CollectionsTests-tfel.238 Ancestors: CollectionsTests-topa.237 Add a test to check that running the fallback code for ByteArray>>#replaceFrom:to:with:startingAt: actually works, because primitive 105 is supposed to be optional ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007875.html Name: Collections-tfel.613 Ancestors: Collections-bf.612 Fix replaceFrom:to:with:startingAt: for ByteArray if run on a VM without primitive 105 ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007876.html Name: Morphic-mt.845 Ancestors: Morphic-mt.844 Speed-up when resizing scroll bars. They will not be re-initialized completely anymore. Menu buttons work again, too. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007877.html Name: Morphic-mt.846 Ancestors: Morphic-mt.845 Fixed postscript. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007878.html Name: Morphic-mt.847 Ancestors: Morphic-mt.846 Compatibility fix: made menuMorph lazy initialized. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007879.html Name: Morphic-mt.848 Ancestors: Morphic-mt.847 Compatibility fix: Use lazy initialization for interval in scroll bars to make update work again. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007880.html Name: Morphic-mt.849 Ancestors: Morphic-mt.848 Fixed some widgets that failed to grab the keyboard on mouse-up, which is the normal way if #mouseOverForKeyboardFocus is not enabled in the preferences. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007881.html Name: System-mt.719 Ancestors: System-topa.718 Removed menu-button pref from Preferences because it is now in ScrollBar class. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007882.html Name: ToolBuilder-Morphic-mt.121 Ancestors: ToolBuilder-Morphic-mt.120 Missing super-send added to tree morph. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007883.html Name: Morphic-mt.850 Ancestors: Morphic-mt.849 Fixed scroll pane (i.e. text boxes) creation when preference "always show H/V scrollbar" was enabled. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007884.html Name: Multilingual-topa.204 Ancestors: Multilingual-topa.203 Ensure toLower et al work on WideStrings ============================================= From eliot.miranda at gmail.com Thu Apr 9 22:08:51 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Thu Apr 9 22:08:53 2015 Subject: [squeak-dev] New Cog VMs available In-Reply-To: <1A959CB4-7121-4D91-8395-852B3B563835@gmx.de> References: <1A959CB4-7121-4D91-8395-852B3B563835@gmx.de> Message-ID: On Thu, Apr 9, 2015 at 2:38 PM, Tobias Pape wrote: > Hi Eliot, > > On 15.02.2015, at 19:13, Eliot Miranda wrote: > > > Hi Frank, > > > > can you revert to 3253? This one should be good. I'm pretty sure > the 3254 VMs are subject to the same inlning bug that I mentioned after the > latest VMMaker.oscog commit and am working on fixing now. > > > > As this bug is probably long fixed, what version would you suggest for the > CI server now? > The most recent, please :) 3308. > Best > -Tobias > > > On Sat, Feb 14, 2015 at 5:47 AM, Frank Shearar > wrote: > > On 12 February 2015 at 20:42, Eliot Miranda > wrote: > > > http://www.mirandabanda.org/files/Cog/VM/VM.r3254/ > > > > > > > > > These fix two important bugs in the Spur VMs, so Newspeakers should > update, > > > and changes the default text encoding to UTF-8 on linux. > > > > I updated CI with 3254, and now I see errors like this: > > > > spawning command 1 with timeout 1500 seconds: > > > /var/lib/jenkins/workspace/SqueakTrunk/target/cog.r3254/coglinuxht/bin/squeak > > -vm-sound-null -vm-display-null > > "/var/lib/jenkins/workspace/SqueakTrunk/target/TrunkImage.image" > > ../update-image.st > > pthread_setschedparam failed: Operation not permitted > > Read e.g. http://www.mirandabanda.org/files/Cog/VM/VM.r3254/README.3254 > > > > As it happens, we do have a /etc/security/limits.d/squeak.conf on > > build.squeak.org that looks like this: > > > > * hard rtprio 2 > > * soft rtprio 2 > > > > Thoughts? > > > > frank > > > > > -- best, Eliot -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150409/ef27b4c5/attachment.htm From Das.Linux at gmx.de Thu Apr 9 22:17:31 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 9 22:17:34 2015 Subject: [squeak-dev] New Cog VMs available In-Reply-To: References: Message-ID: <0F3C260D-2441-4272-8578-E4497BE65C1A@gmx.de> Updated on the CI :) Best -Tobias On 09.04.2015, at 23:28, Eliot Miranda wrote: > ... at http://www.mirandabanda.org/files/Cog/VM/VM.r3308/. > > CogVM binaries as per VMMaker.oscog-eem.1178/r3308 > > Plugins: > Integrate Nicolas' fixes that use positiveMachineIntegerFor: for pointers. > > Newspeak: > Print a warning in the method shared under multiple selectors scenario. > > Implement outer sends as clean sends just like implicit receiver sends. Add > ObjectRepresentation>>illegalClassTag and use it for initializing and unlinking > implicit and outer sends. > > Newspeak & Sista: > The multiple bytecode set block initial nil counters need > to be specific to the bytecode set in effect. > > Spur: > Implement Clement's much better solution for the stale supersend problem. > Place code at the send site for super sends to follow stale forwarded > receivers. This parallels the interpreter implementation. > > Beef up the post-become scan of send sites to > unlink all send sites that link to an invalid class tag. > > Cogit: > Optimize StackToRegisterMappingCogit>>genReturnReceiver > to not load ReceiverResultReg if it already contains self. > > Revise method map generation to provide multiple send type annotations. Add > an IsAnnotationExtension annotation type that implicitly has a zero displacement > and uses its displacement bits to extend the preceeding IsSendCall annotation. > This allows us to eliminate all the exotic entry-points and keep only the > checked and unchecked entries. > > Change IA32's genPushRegisterArgsForNumArgs: to not smash TempReg now that it > is used in directed super send trampolines. > > Use PushCq to pass small integer constants in the trampolines instead of > smashing TempReg, which is now used to hold the directed supersend argument. > Add support for PushCq. Could use PushCw but on x86 PushCq is a lot shorter. > > Mac builds: Use UTC as the timezone for the build timestamp. Using the local > timezone doesn't work :(. From commits at source.squeak.org Thu Apr 9 22:18:45 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 9 22:18:47 2015 Subject: [squeak-dev] The Trunk: Collections.spur-tfel.613.mcz Message-ID: Eliot Miranda uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections.spur-tfel.613.mcz ==================== Summary ==================== Name: Collections.spur-tfel.613 Author: eem Time: 9 April 2015, 3:18:05.86 pm UUID: daedce87-0d04-41ee-921e-0f82eca892c9 Ancestors: Collections-tfel.613, Collections.spur-bf.612 Collections-tfel.613 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 Fix replaceFrom:to:with:startingAt: for ByteArray if run on a VM without primitive 105 =============== Diff against Collections-tfel.613 =============== Item was changed: ----- Method: Array>>elementsExchangeIdentityWith: (in category 'converting') ----- elementsExchangeIdentityWith: otherArray + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + At the same time, all pointers to the elements of otherArray are replaced by + pointers to the corresponding elements of this array. The identityHashes remain + with the pointers rather than with the objects so that objects in hashed structures + should still be properly indexed after the mutation." - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. At the same time, all pointers to the elements of otherArray are replaced by pointers to the corresponding elements of this array. The identityHashes remain with the pointers rather than with the objects so that objects in hashed structures should still be properly indexed after the mutation." + + ec == #'bad receiver' ifTrue: + [^self error: 'receiver must be of class Array']. + ec == #'bad argument' ifTrue: + [^self error: (otherArray class == Array + ifTrue: ['arg must be of class Array'] + ifFalse: ['receiver and argument must have the same size'])]. + ec == #'inappropriate operation' ifTrue: + [^self error: 'can''t become immediates such as SmallIntegers or Characters']. + ec == #'no modification' ifTrue: + [^self error: 'can''t become immutable objects']. + ec == #'object is pinned' ifTrue: + [^self error: 'can''t become pinned objects']. + ec == #'insufficient object memory' ifTrue: + [Smalltalk garbageCollect < 1048576 ifTrue: + [Smalltalk growMemoryByAtLeast: 1048576]. + ^self elementsExchangeIdentityWith: otherArray]. + self primitiveFailed! - - otherArray class == Array ifFalse: [^ self error: 'arg must be array']. - self size = otherArray size ifFalse: [^ self error: 'arrays must be same size']. - (self anySatisfy: [:obj | obj class == SmallInteger]) ifTrue: [^ self error: 'can''t become SmallIntegers']. - (otherArray anySatisfy: [:obj | obj class == SmallInteger]) ifTrue: [^ self error: 'can''t become SmallIntegers']. - self with: otherArray do:[:a :b| a == b ifTrue:[^self error:'can''t become yourself']]. - - "Must have failed because not enough space in forwarding table (see ObjectMemory-prepareForwardingTableForBecoming:with:twoWay:). Do GC and try again only once" - (Smalltalk bytesLeft: true) = Smalltalk primitiveGarbageCollect - ifTrue: [^ self primitiveFailed]. - ^ self elementsExchangeIdentityWith: otherArray! Item was changed: ----- Method: Array>>elementsForwardIdentityTo: (in category 'converting') ----- elementsForwardIdentityTo: otherArray + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + The identityHashes remain with the pointers rather than with the objects so that + the objects in this array should still be properly indexed in any existing hashed + structures after the mutation." + - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. The identityHashes remain with the pointers rather than with the objects so that the objects in this array should still be properly indexed in any existing hashed structures after the mutation." - self primitiveFailed! Item was changed: ----- Method: Array>>elementsForwardIdentityTo:copyHash: (in category 'converting') ----- elementsForwardIdentityTo: otherArray copyHash: copyHash + "This primitive performs a bulk mutation, causing all pointers to the elements of the + receiver to be replaced by pointers to the corresponding elements of otherArray. + If copyHash is true, the identityHashes remain with the pointers rather than with the + objects so that the objects in the receiver should still be properly indexed in any + existing hashed structures after the mutation. If copyHash is false, then the hashes + of the objects in otherArray remain unchanged. If you know what you're doing this + may indeed be what you want." + - "This primitive performs a bulk mutation, causing all pointers to the elements of this array to be replaced by pointers to the corresponding elements of otherArray. The identityHashes remain with the pointers rather than with the objects so that the objects in this array should still be properly indexed in any existing hashed structures after the mutation." - self primitiveFailed! Item was changed: ==== ERROR === Error: Unrecognized class type 9 April 2015 10:18:37.356 pm VM: unix - a SmalltalkImage Image: Squeak3.11alpha [latest update: #8824] SecurityManager state: Restricted: false FileAccess: true SocketAccess: true Working Dir /home/squeaksource Trusted Dir /home/squeaksource/secure Untrusted Dir /home/squeaksource/My Squeak MCClassDefinition(Object)>>error: Receiver: a MCClassDefinition(Character) Arguments and temporary variables: aString: 'Unrecognized class type' Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil MCClassDefinition>>kindOfSubclass Receiver: a MCClassDefinition(Character) Arguments and temporary variables: Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil MCClassDefinition>>printDefinitionOn: Receiver: a MCClassDefinition(Character) Arguments and temporary variables: stream: a WriteStream Receiver's instance variables: name: #Character superclassName: #Magnitude variables: an OrderedCollection(a MCClassVariableDefinition(CharacterTable) a M...etc... category: #'Collections-Strings' type: #immediate comment: 'I represent a character by storing its associated Unicode as an unsig...etc... commentStamp: 'eem 8/12/2014 14:53' traitComposition: nil classTraitComposition: nil [] in MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: Receiver: a MCDiffyTextWriter Arguments and temporary variables: definition: a WriteStream s: a MCClassDefinition(Character) Receiver's instance variables: stream: a WriteStream initStream: nil --- The full stack --- MCClassDefinition(Object)>>error: MCClassDefinition>>kindOfSubclass MCClassDefinition>>printDefinitionOn: [] in MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - String class(SequenceableCollection class)>>new:streamContents: String class(SequenceableCollection class)>>streamContents: MCDiffyTextWriter(MCTextWriter)>>chunkContents: MCDiffyTextWriter(MCStWriter)>>writeClassDefinition: MCDiffyTextWriter(MCStWriter)>>visitClassDefinition: MCClassDefinition>>accept: [] in MCDiffyTextWriter(MCTextWriter)>>visitInFork: String class(SequenceableCollection class)>>new:streamContents: String class(SequenceableCollection class)>>streamContents: MCDiffyTextWriter(MCTextWriter)>>visitInFork: MCDiffyTextWriter>>writePatchFrom:to: MCDiffyTextWriter>>writeModification: [] in MCDiffyTextWriter>>writePatch: SortedCollection(OrderedCollection)>>do: MCDiffyTextWriter>>writePatch: SSDiffyTextWriter>>writePatch: [] in SSDiffyTextWriter>>writeVersion:for: BlockClosure>>on:do: SSDiffyTextWriter>>writeVersion:for: [] in SSEMailSubscription>>versionAdded:to: BlockClosure>>on:do: SSEMailSubscription>>versionAdded:to: [] in [] in SSProject>>versionAdded: [] in BlockClosure>>newProcess From commits at source.squeak.org Thu Apr 9 22:19:03 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Thu Apr 9 22:19:04 2015 Subject: [squeak-dev] The Trunk: System.spur-mt.719.mcz Message-ID: Eliot Miranda uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System.spur-mt.719.mcz ==================== Summary ==================== Name: System.spur-mt.719 Author: eem Time: 9 April 2015, 3:18:12.846 pm UUID: 7d59fd9c-5463-4e0c-afd4-dbbf9e5ca023 Ancestors: System-mt.719, System.spur-topa.718 System-mt.719 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 Removed menu-button pref from Preferences because it is now in ScrollBar class. =============== Diff against System-mt.719 =============== Item was removed: - ----- Method: Object>>oopAge (in category '*system-support') ----- - oopAge - ^ ObjectHistory current ageOf: self! Item was removed: - ----- Method: Object>>oopTimestamp (in category '*system-support') ----- - oopTimestamp - ^ ObjectHistory current timestampOf: self! Item was removed: - Object subclass: #ObjectHistory - instanceVariableNames: 'marks markProcess' - classVariableNames: 'Current' - poolDictionaries: '' - category: 'System-Support'! - - !ObjectHistory commentStamp: 'bf 11/16/2012 12:19' prior: 0! - ObjectHistory holds ObjectHistoryMark objects which are placed in the object memory at regular intervals by its markProcess in the background. Adjacent marks (with no remaining objects inbetween) are coalesced so over time the collection does not grow unnecessarily large. - - Using these markers it is possible to determine the age of objects in memory from the time the ObjectHistory was initialized. Try e.g.: - self oopTimestamp. - self oopAge. - ObjectHistory current oopClassesByDate. - - Instance Variables - marks: SortedCollection of ObjectHistoryMark objects - markProcess: a Process running our markLoop - ! Item was removed: - ----- Method: ObjectHistory class>>current (in category 'accessing') ----- - current - ^ Current ifNil: [Current := self new]! Item was removed: - ----- Method: ObjectHistory class>>initialize (in category 'class initialization') ----- - initialize - self current. - ! Item was removed: - ----- Method: ObjectHistory class>>obsolete (in category 'class initialization') ----- - obsolete - "Kill the mark process before removing the class." - Current ifNotNil: - [:objectHistory| - objectHistory terminate]. - super obsolete! Item was removed: - ----- Method: ObjectHistory>>ageOf: (in category 'queries') ----- - ageOf: anObject - "Age of anObject in seconds" - | timestamp | - timestamp := self timestampOf: anObject. - timestamp ifNil: [^0]. - ^(DateAndTime now - timestamp) asSeconds roundTo: self markRate! Item was removed: - ----- Method: ObjectHistory>>initialize (in category 'initializing') ----- - initialize - self restartMarkProcess. - - ! Item was removed: - ----- Method: ObjectHistory>>markLoop (in category 'marking') ----- - markLoop - [true] whileTrue: [ - self markUpdate. - (Delay forSeconds: self markRate) wait]! Item was removed: - ----- Method: ObjectHistory>>markRate (in category 'marking') ----- - markRate - "rate of creating ObjectHistoryMarks" - ^60! Item was removed: - ----- Method: ObjectHistory>>markUpdate (in category 'marking') ----- - markUpdate - "Add a new mark and compact the marks collection" - | mark prev | - "lazy init so this happens in the background process" - marks ifNil: [self reinitMarks]. - "add new mark to object memory" - mark := self newMark. - mark timestamp <= marks last timestamp ifTrue: [^self "could happen if clock is wrong"]. - marks addLast: mark. - "compact the table by removing adjacent marks" - prev := marks first. - marks removeAllSuchThat: [:each | | doDelete | - doDelete := prev objectAfter == each. - prev := each. - doDelete]. - "The loop above is O(n) in number of marks, but that number should never become so large to be an issue. Even if the number was large, this is running at system background priority so should not interfere with any user process, not even user background processes. The symptom should only be that the system is less idle. - - If we ever get to a point where the number of marks is an issue then the compacting here could be made partial: since old marks rarely get coalesced it would make sense to only check the newer ones often, and the old ones perhaps only at the system startup."! Item was removed: - ----- Method: ObjectHistory>>newMark (in category 'private') ----- - newMark - ^ ObjectHistoryMark new! Item was removed: - ----- Method: ObjectHistory>>oopClassesByAge (in category 'stats') ----- - oopClassesByAge - "Answer collection of (oopAge in seconds -> sorted counts of object classes) sorted from lowest age" - "ObjectHistory current oopClassesByAge" - - | stats prev endOfMemory now bag age obj | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - now := self newMark timestamp. - marks do: [:mark | - prev ifNotNil: [ - bag := Bag new. - obj := prev objectAfter. - [obj == mark] whileFalse: [ - bag add: obj class. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - age := (now - mark timestamp) asSeconds roundTo: self markRate. - stats addFirst: age -> bag sortedCounts]. - prev := mark]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>oopClassesByDate (in category 'stats') ----- - oopClassesByDate - "Answer collection of (Date -> sorted counts of object classes) sorted from newest date" - "ObjectHistory current oopClassesByDate" - - | stats prev endOfMemory bag date obj thisDate | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - thisDate := nil. - bag := Bag new. - marks do: [:mark | - prev ifNotNil: [ - obj := prev objectAfter. - [obj == mark] whileFalse: [ - bag add: obj class. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - date := mark timestamp asDate. - thisDate = date ifFalse: [ - stats addFirst: date -> bag sortedCounts. - bag := Bag new. - thisDate := date]]. - prev := mark]. - thisDate = date ifFalse: [ - stats addLast: date -> bag sortedCounts]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>oopCountsByAge (in category 'stats') ----- - oopCountsByAge - "Answer collection of (oopAge in seconds -> number of objects) sorted from lowest age" - "ObjectHistory current oopCountsByAge" - - | stats prev endOfMemory now n age obj | - endOfMemory := Object new. - stats := OrderedCollection new: 1000. - prev := nil. - now := self newMark timestamp. - marks do: [:mark | - prev ifNotNil: [ - n := 0. - obj := prev objectAfter. - [obj == mark] whileFalse: [ - n := n + 1. - obj := obj nextObject. - obj == endOfMemory ifTrue: [self error: 'should not happen']]. - age := (now - mark timestamp) asSeconds roundTo: self markRate. - stats addFirst: age -> n]. - prev := mark]. - ^ stats - ! Item was removed: - ----- Method: ObjectHistory>>reinitMarks (in category 'private') ----- - reinitMarks - marks := ObjectHistoryMark allInstances asOrderedCollection. - marks - ifEmpty: [marks add: self newMark] - ifNotEmpty: [ | prev | - prev := nil. - marks removeAllSuchThat: [:obj | - prev notNil and: [prev timestamp >= obj timestamp]]]. - ! Item was removed: - ----- Method: ObjectHistory>>restartMarkProcess (in category 'marking') ----- - restartMarkProcess - markProcess ifNotNil: [markProcess terminate]. - markProcess := [self markLoop] - forkAt: Processor systemBackgroundPriority - named: 'ObjectHistory''s markProcess'. - ! Item was removed: - ----- Method: ObjectHistory>>terminate (in category 'private') ----- - terminate - markProcess ifNotNil: - [markProcess terminate]! Item was removed: - ----- Method: ObjectHistory>>timestampOf: (in category 'queries') ----- - timestampOf: anObject - "Timestamp of anObject, or nil if too new" - | endOfMemory mark | - anObject class == SmallInteger ifTrue: [^nil]. - mark := anObject. - endOfMemory := Object new. - [mark class == ObjectHistoryMark] whileFalse: [ - mark := mark nextObject. - mark == endOfMemory ifTrue: [^nil]]. - ^mark timestamp! Item was removed: - Object subclass: #ObjectHistoryMark - instanceVariableNames: 'timestamp' - classVariableNames: '' - poolDictionaries: '' - category: 'System-Support'! - - !ObjectHistoryMark commentStamp: 'bf 11/7/2012 00:12' prior: 0! - An ObjectHistoryMark is a permanent mark in the object memory. It holds a timestamp. - - While the timestamp could be used directly as mark by ObjectHistory, it's conceivable that its format might change in the future, and we do not want the mark's relative position in memory to change (which would be the case if it was migrated to a new format). So we use a distinct object instead (and we protect it against accidental become-ing by overriding those methods).! Item was removed: - ----- Method: ObjectHistoryMark>>become: (in category 'mutating') ----- - become: otherObject - ^self error: 'marks need to stay fixed in the object memory'! Item was removed: - ----- Method: ObjectHistoryMark>>becomeForward: (in category 'mutating') ----- - becomeForward: otherObject - ^self error: 'marks need to stay fixed in the object memory'! Item was removed: - ----- Method: ObjectHistoryMark>>initialize (in category 'initialization') ----- - initialize - timestamp := DateAndTime now floor. - ! Item was removed: - ----- Method: ObjectHistoryMark>>objectAfter (in category 'accessing') ----- - objectAfter - "Answer the next object in memory after me and my timestamp" - | successor | - successor := self nextObject. - successor == timestamp - ifTrue: [successor := successor nextObject]. - ^ successor! Item was removed: - ----- Method: ObjectHistoryMark>>printOn: (in category 'printing') ----- - printOn: aStream - aStream - nextPutAll: self class name; - nextPut: $(; - print: timestamp; - nextPut: $)! Item was removed: - ----- Method: ObjectHistoryMark>>timestamp (in category 'accessing') ----- - timestamp - ^timestamp - ! Item was changed: ----- Method: SmalltalkImage>>compactClassesArray (in category 'special objects') ----- compactClassesArray "Smalltalk compactClassesArray" + "Backward-compatibility support. Spur does not have compact classes." + ^{}! - "Return the array of 31 classes whose instances may be - represented compactly" - ^ self specialObjectsArray at: 29! Item was added: + ----- Method: SmalltalkImage>>growMemoryByAtLeast: (in category 'memory space') ----- + growMemoryByAtLeast: numBytes + "Grow memory by at least the requested number of bytes. + Primitive. Essential. Fail if no memory is available." + + (numBytes isInteger and: [numBytes > 0]) ifTrue: + [OutOfMemory signal]. + ^self primitiveFailed! Item was added: + ----- Method: SmalltalkImage>>maxIdentityHash (in category 'system attributes') ----- + maxIdentityHash + "Answer the maximum identityHash value supported by the VM." + + ^self primitiveFailed! Item was changed: ----- Method: SmalltalkImage>>primBytesLeft (in category 'memory space') ----- primBytesLeft + "Primitive. Answer the number of free bytes available in old space. + Not accurate unless preceded by - "Primitive. Answer the number of bytes available for new object data. - Not accurate unless preceded by Smalltalk garbageCollectMost (for reasonable accuracy), or Smalltalk garbageCollect (for real accuracy). + See Object documentation whatIsAPrimitive." - See Object documentation whatIsAPrimitive." + ^0! - ^ 0! Item was changed: ----- Method: SmalltalkImage>>primitiveGarbageCollect (in category 'memory space') ----- primitiveGarbageCollect + "Primitive. Reclaims all garbage and answers the size of the largest free chunk in old space.." - "Primitive. Reclaims all garbage and answers the number of bytes of available space." + ^self primitiveFailed! - ^ self primBytesLeft! Item was changed: ----- Method: SmalltalkImage>>recreateSpecialObjectsArray (in category 'special objects') ----- recreateSpecialObjectsArray "Smalltalk recreateSpecialObjectsArray" "To external package developers: **** DO NOT OVERRIDE THIS METHOD. ***** If you are writing a plugin and need additional special object(s) for your own use, use addGCRoot() function and use own, separate special objects registry " "The Special Objects Array is an array of objects used by the Squeak virtual machine. Its contents are critical and accesses to it by the VM are unchecked, so don't even think of playing here unless you know what you are doing." | newArray | + newArray := Array new: 60. - newArray := Array new: 58. "Nil false and true get used throughout the interpreter" newArray at: 1 put: nil. newArray at: 2 put: false. newArray at: 3 put: true. "This association holds the active process (a ProcessScheduler)" newArray at: 4 put: (self specialObjectsArray at: 4) "(self bindingOf: #Processor) but it answers an Alias". "Numerous classes below used for type checking and instantiation" newArray at: 5 put: Bitmap. newArray at: 6 put: SmallInteger. newArray at: 7 put: ByteString. newArray at: 8 put: Array. newArray at: 9 put: Smalltalk. + newArray at: 10 put: BoxedFloat64. + newArray at: 11 put: (self globals at: #MethodContext ifAbsent: [self globals at: #Context]). + newArray at: 12 put: nil. "was BlockContext." - newArray at: 10 put: Float. - newArray at: 11 put: MethodContext. - newArray at: 12 put: BlockContext. newArray at: 13 put: Point. newArray at: 14 put: LargePositiveInteger. newArray at: 15 put: Display. newArray at: 16 put: Message. newArray at: 17 put: CompiledMethod. + newArray at: 18 put: ((self specialObjectsArray at: 18) ifNil: [Semaphore new]). "low space Semaphore" - newArray at: 18 put: (self specialObjectsArray at: 18). - "(low space Semaphore)" newArray at: 19 put: Semaphore. newArray at: 20 put: Character. newArray at: 21 put: #doesNotUnderstand:. newArray at: 22 put: #cannotReturn:. newArray at: 23 put: nil. "This is the process signalling low space." "An array of the 32 selectors that are compiled as special bytecodes, paired alternately with the number of arguments each takes." newArray at: 24 put: #( #+ 1 #- 1 #< 1 #> 1 #<= 1 #>= 1 #= 1 #~= 1 #* 1 #/ 1 #\\ 1 #@ 1 #bitShift: 1 #// 1 #bitAnd: 1 #bitOr: 1 #at: 1 #at:put: 2 #size 0 #next 0 #nextPut: 1 #atEnd 0 #== 1 #class 0 #blockCopy: 1 #value 0 #value: 1 #do: 1 #new 0 #new: 1 #x 0 #y 0 ). "An array of the 255 Characters in ascii order. + Cog inlines table into machine code at: prim so do not regenerate it. + This is nil in Spur, which has immediate Characters." - Cog inlines table into machine code at: prim so do not regenerate it." newArray at: 25 put: (self specialObjectsArray at: 25). newArray at: 26 put: #mustBeBoolean. newArray at: 27 put: ByteArray. newArray at: 28 put: Process. + "An array of up to 31 classes whose instances will have compact headers; an empty array in Spur" - "An array of up to 31 classes whose instances will have compact headers" newArray at: 29 put: self compactClassesArray. + newArray at: 30 put: ((self specialObjectsArray at: 30) ifNil: [Semaphore new]). "delay Semaphore" + newArray at: 31 put: ((self specialObjectsArray at: 31) ifNil: [Semaphore new]). "user interrupt Semaphore" - newArray at: 30 put: (self specialObjectsArray at: 30). "(delay Semaphore)" - newArray at: 31 put: (self specialObjectsArray at: 31). "(user interrupt Semaphore)" "Entries 32 - 34 unreferenced. Previously these contained prototype instances to be copied for fast initialization" + newArray at: 32 put: nil. "was the prototype Float" + newArray at: 33 put: nil. "was the prototype 4-byte LargePositiveInteger" + newArray at: 34 put: nil. "was the prototype Point" - newArray at: 32 put: nil. "was (Float new: 2)" - newArray at: 33 put: nil. "was (LargePositiveInteger new: 4)" - newArray at: 34 put: nil. "was Point new" newArray at: 35 put: #cannotInterpret:. + newArray at: 36 put: nil. "was the prototype MethodContext" - "Note: This must be fixed once we start using context prototypes (yeah, right)" - "(MethodContext new: CompiledMethod fullFrameSize)." - newArray at: 36 put: (self specialObjectsArray at: 36). "Is the prototype MethodContext (unused by the VM)" newArray at: 37 put: BlockClosure. + newArray at: 38 put: nil. "was the prototype BlockContext" - "(BlockContext new: CompiledMethod fullFrameSize)." - newArray at: 38 put: (self specialObjectsArray at: 38). "Is the prototype BlockContext (unused by the VM)" "array of objects referred to by external code" + newArray at: 39 put: (self specialObjectsArray at: 39). "external semaphores" - newArray at: 39 put: (self specialObjectsArray at: 39). "preserve external semaphores" newArray at: 40 put: nil. "Reserved for Mutex in Cog VMs" + newArray at: 41 put: ((self specialObjectsArray at: 41) ifNil: [LinkedList new]). "Reserved for a LinkedList instance for overlapped calls in CogMT" + newArray at: 42 put: ((self specialObjectsArray at: 42) ifNil: [Semaphore new]). "finalization Semaphore" - newArray at: 41 put: nil. "Reserved for a LinkedList instance for overlapped calls in CogMT" - "finalization Semaphore" - newArray at: 42 put: ((self specialObjectsArray at: 42) ifNil: [Semaphore new]). newArray at: 43 put: LargeNegativeInteger. "External objects for callout. Note: Written so that one can actually completely remove the FFI." newArray at: 44 put: (self at: #ExternalAddress ifAbsent: []). newArray at: 45 put: (self at: #ExternalStructure ifAbsent: []). newArray at: 46 put: (self at: #ExternalData ifAbsent: []). newArray at: 47 put: (self at: #ExternalFunction ifAbsent: []). newArray at: 48 put: (self at: #ExternalLibrary ifAbsent: []). newArray at: 49 put: #aboutToReturn:through:. newArray at: 50 put: #run:with:in:. "51 reserved for immutability message" + newArray at: 51 put: #attemptToAssign:withIndex:. - "newArray at: 51 put: #attemptToAssign:withIndex:." - newArray at: 51 put: (self specialObjectsArray at: 51 ifAbsent: []). newArray at: 52 put: #(nil "nil => generic error" #'bad receiver' #'bad argument' #'bad index' #'bad number of arguments' #'inappropriate operation' #'unsupported operation' #'no modification' #'insufficient object memory' #'insufficient C memory' #'not found' #'bad method' #'internal error in named primitive machinery' #'object may move' #'resource limit exceeded' + #'object is pinned' #'primitive write beyond end of object'). - #'object is pinned'). "53 to 55 are for Alien" newArray at: 53 put: (self at: #Alien ifAbsent: []). + newArray at: 54 put: #invokeCallbackContext:. "use invokeCallback:stack:registers:jmpbuf: for old Alien callbacks." - newArray at: 54 put: #invokeCallbackContext::. "use invokeCallback:stack:registers:jmpbuf: for old Alien callbacks." newArray at: 55 put: (self at: #UnsafeAlien ifAbsent: []). + "Used to be WeakFinalizationList for WeakFinalizationList hasNewFinalization, obsoleted by ephemeron support." + newArray at: 56 put: nil. - "Weak reference finalization" - newArray at: 56 put: (self at: #WeakFinalizationList ifAbsent: []). "reserved for foreign callback process" newArray at: 57 put: (self specialObjectsArray at: 57 ifAbsent: []). newArray at: 58 put: #unusedBytecode. + "59 reserved for Sista counter tripped message" + newArray at: 59 put: #conditionalBranchCounterTrippedOn:. + "60 reserved for Sista class trap message" + newArray at: 60 put: #classTrapFor:. "Now replace the interpreter's reference in one atomic operation" + self specialObjectsArray becomeForward: newArray! - self specialObjectsArray becomeForward: newArray - ! Item was changed: ----- Method: SmalltalkImage>>setGCParameters (in category 'snapshot and quit') ----- setGCParameters + "Adjust the VM's default GC parameters to avoid too much tenuring. + Maybe this should be left to the VM?" - "Adjust the VM's default GC parameters to avoid premature tenuring." + | proportion edenSize survivorSize averageObjectSize numObjects | + proportion := 0.9. "tenure when 90% of pastSpace is full" + edenSize := SmalltalkImage current vmParameterAt: 44. + survivorSize := edenSize / 5.0. "David's paper uses 140Kb eden + 2 x 28kb survivor spaces; Spur uses the same ratios :-)" + averageObjectSize := 8 * self wordSize. "a good approximation" + numObjects := (proportion * survivorSize / averageObjectSize) rounded. + SmalltalkImage current vmParameterAt: 6 put: numObjects "tenure when more than this many objects survive the GC"! - self vmParameterAt: 5 put: 4000. "do an incremental GC after this many allocations" - self vmParameterAt: 6 put: 2000. "tenure when more than this many objects survive the GC" - ! Item was changed: ----- Method: SpaceTally>>spaceForInstancesOf: (in category 'instance size') ----- spaceForInstancesOf: aClass + "Answer a pair of the number of bytes consumed by all instances of the + given class, including their object headers, and the number of instances." - "Answer the number of bytes consumed by all instances of the given class, including their object headers and the number of instances." + | instances total | + instances := aClass allInstances. + instances isEmpty ifTrue: [^#(0 0)]. - | smallHeaderSize instVarBytes isVariable bytesPerElement total lastInstance instance instanceCount | - instance := aClass someInstance ifNil: [ ^#(0 0) ]. - smallHeaderSize := aClass isCompact ifTrue: [ 4 ] ifFalse: [ 8 ]. - instVarBytes := aClass instSize * 4. - isVariable := aClass isVariable. - bytesPerElement := isVariable - ifFalse: [ 0 ] - ifTrue: [ aClass isBytes ifTrue: [ 1 ] ifFalse: [ 4 ] ]. total := 0. + aClass isVariable + ifTrue: + [instances do: + [:i| total := total + (aClass byteSizeOfInstanceOfSize: i basicSize)]] + ifFalse: + [total := instances size * aClass byteSizeOfInstance]. + ^{ total. instances size }! - instanceCount := 0. - "A modified version of #allInstancesDo: is inlined here. It avoids an infinite loop when another process is creating new instances of aClass." - self flag: #allInstancesDo:. - lastInstance := - aClass == CompiledMethod "CompiledMethod has special format, see its class comment" - ifTrue: [aClass new] - ifFalse: [aClass basicNew]. - [ instance == lastInstance ] whileFalse: [ - | contentBytes headerBytes | - contentBytes := instVarBytes + (isVariable - ifFalse: [ 0 ] - ifTrue: [ instance basicSize * bytesPerElement ]). - headerBytes := contentBytes > 255 - ifTrue: [ 12 ] - ifFalse: [ smallHeaderSize ]. - total := total + headerBytes + (contentBytes roundUpTo: 4). - instanceCount := instanceCount + 1. - instance := instance nextInstance ]. - ^{ total. instanceCount }! Item was added: + ----- Method: SystemDictionary>>growMemoryByAtLeast: (in category 'memory space') ----- + growMemoryByAtLeast: numBytes + "Grow memory by at least the requested number of bytes. + Primitive. Fail if no memory is available. Essential." + + ^(numBytes isInteger and: [numBytes > 0]) + ifTrue: [OutOfMemory signal] + ifFalse: [self primitiveFailed]! Item was added: + ----- Method: SystemDictionary>>maxIdentityHash (in category 'system attributes') ----- + maxIdentityHash + "Answer the maximum identityHash value supported by the VM." + + ^self primitiveFailed! Item was added: + ----- Method: SystemDictionary>>setGCParameters (in category 'snapshot and quit') ----- + setGCParameters + "Adjust the VM's default GC parameters to avoid too much tenuring. + Maybe this should be left to the VM?" + + | proportion edenSize survivorSize averageObjectSize numObjects | + proportion := 0.9. "tenure when 90% of pastSpace is full" + edenSize := SmalltalkImage current vmParameterAt: 44. + survivorSize := edenSize / 5.0. "David's paper uses 140Kb eden + 2 x 28kb survivor spaces; Spur uses the same ratios :-)" + averageObjectSize := 8 * self wordSize. "a good approximation" + numObjects := (proportion * survivorSize / averageObjectSize) rounded. + SmalltalkImage current vmParameterAt: 6 put: numObjects "tenure when more than this many objects survive the GC"! Item was added: + ----- Method: SystemNavigation>>allObjects (in category 'query') ----- + allObjects + "Answer an Array of all objects in the system. Fail if + there isn't enough memory to instantiate the result." + + ^self primitiveFailed! Item was changed: ----- Method: SystemNavigation>>allObjectsDo: (in category 'query') ----- allObjectsDo: aBlock + "Evaluate the argument, aBlock, for each object in the system, excluding immediates + such as SmallInteger and Character." + self allObjectsOrNil + ifNotNil: [:allObjects| allObjects do: aBlock] + ifNil: + ["Fall back on the old single object primitive code. With closures, this needs + to use an end marker (lastObject) since activation of the block will create + new contexts and cause an infinite loop. The lastObject must be created + before calling someObject, so that the VM can settle the enumeration (e.g. + by flushing new space) as a side effect of someObject" + | object lastObject | + lastObject := Object new. + object := self someObject. + [lastObject == object or: [0 == object]] whileFalse: + [aBlock value: object. + object := object nextObject]]! - "Evaluate the argument, aBlock, for each object in the system - excluding SmallIntegers. With closures, this needs to use an end - marker (lastObject) since activation of the block will create new - contexts and cause an infinite loop." - | object lastObject | - object := self someObject. - lastObject := Object new. - [lastObject == object or: [0 == object]] - whileFalse: [aBlock value: object. - object := object nextObject]! Item was added: + ----- Method: SystemNavigation>>allObjectsOrNil (in category 'query') ----- + allObjectsOrNil + "Answer an Array of all objects in the system. Fail if there isn't + enough memory to instantiate the result and answer nil." + + ^nil! From Das.Linux at gmx.de Thu Apr 9 22:21:07 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Thu Apr 9 22:21:11 2015 Subject: [squeak-dev] New Cog VMs available In-Reply-To: <0F3C260D-2441-4272-8578-E4497BE65C1A@gmx.de> References: <0F3C260D-2441-4272-8578-E4497BE65C1A@gmx.de> Message-ID: <256F46F5-91B0-4552-A9E9-25BAAA2733DF@gmx.de> On 10.04.2015, at 00:17, Tobias Pape wrote: > Updated on the CI :) > aaand reverted. We got a crash: http://build.squeak.org/job/SqueakTrunk/1245/console Best -Tobias > Best > -Tobias > On 09.04.2015, at 23:28, Eliot Miranda wrote: > >> ... at http://www.mirandabanda.org/files/Cog/VM/VM.r3308/. >> >> CogVM binaries as per VMMaker.oscog-eem.1178/r3308 >> >> Plugins: >> Integrate Nicolas' fixes that use positiveMachineIntegerFor: for pointers. >> >> Newspeak: >> Print a warning in the method shared under multiple selectors scenario. >> >> Implement outer sends as clean sends just like implicit receiver sends. Add >> ObjectRepresentation>>illegalClassTag and use it for initializing and unlinking >> implicit and outer sends. >> >> Newspeak & Sista: >> The multiple bytecode set block initial nil counters need >> to be specific to the bytecode set in effect. >> >> Spur: >> Implement Clement's much better solution for the stale supersend problem. >> Place code at the send site for super sends to follow stale forwarded >> receivers. This parallels the interpreter implementation. >> >> Beef up the post-become scan of send sites to >> unlink all send sites that link to an invalid class tag. >> >> Cogit: >> Optimize StackToRegisterMappingCogit>>genReturnReceiver >> to not load ReceiverResultReg if it already contains self. >> >> Revise method map generation to provide multiple send type annotations. Add >> an IsAnnotationExtension annotation type that implicitly has a zero displacement >> and uses its displacement bits to extend the preceeding IsSendCall annotation. >> This allows us to eliminate all the exotic entry-points and keep only the >> checked and unchecked entries. >> >> Change IA32's genPushRegisterArgsForNumArgs: to not smash TempReg now that it >> is used in directed super send trampolines. >> >> Use PushCq to pass small integer constants in the trampolines instead of >> smashing TempReg, which is now used to hold the directed supersend argument. >> Add support for PushCq. Could use PushCw but on x86 PushCq is a lot shorter. >> >> Mac builds: Use UTC as the timezone for the build timestamp. Using the local >> timezone doesn't work :(. From Das.Linux at gmx.de Fri Apr 10 00:17:45 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Fri Apr 10 00:17:50 2015 Subject: [squeak-dev] SqueakSSL + TLS SNI In-Reply-To: References: Message-ID: Hi, On 16.10.2014, at 13:46, Levente Uzonyi wrote: > Hi, > > I've implemented support for TLS SNI[1] for SqueakSSL on unix. I've uploaded the modified source files[2][3], a diff[4], and a prebuilt module[5] (built on Ubuntu 14.04 from the Cog branch). > The image side code is also available[6], along with an updated version of the WebClient[7] package, and intermediate packages with various improvements[8]. > The image side code works even if the plugin doesn't support TLS SNI, but this version of WebClient won't work with older versions of the SqueakSSL-Core package. > Please review the changes, and consider adding them to the corresponding repositories! > > Levente > > [1] https://en.wikipedia.org/wiki/Server_Name_Indication > [2] http://leves.web.elte.hu/squeak/SqueakSSL/SqueakSSL.h > [3] http://leves.web.elte.hu/squeak/SqueakSSL/sqUnixOpenSSL.c > [4] http://leves.web.elte.hu/squeak/SqueakSSL/diff.txt > [5] http://leves.web.elte.hu/squeak/SqueakSSL/SqueakSSL > [6] http://leves.web.elte.hu/squeak/SqueakSSL/SqueakSSL-Core-ul.29.mcz > [7] http://leves.web.elte.hu/squeak/SqueakSSL/WebClient-Core-ul.98.mcz > [8] http://leves.web.elte.hu/squeak/SqueakSSL/ I have things for OSX i think. Can someone confirm? -------------- next part -------------- A non-text attachment was scrubbed... Name: sqMacSSL.patch Type: application/octet-stream Size: 17491 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150410/98fbee09/sqMacSSL-0002.obj -------------- next part -------------- A non-text attachment was scrubbed... Name: sqMacSSL.c Type: application/octet-stream Size: 16378 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150410/98fbee09/sqMacSSL-0003.obj -------------- next part -------------- Best -Tobias From lewis at mail.msen.com Fri Apr 10 00:39:16 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Fri Apr 10 00:39:19 2015 Subject: [squeak-dev] Time primitives In-Reply-To: References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> <7A458A46-A615-4517-B7D5-6C79FCEA4A0F@freudenbergs.de> <20150408120629.GA58602@shell.msen.com> Message-ID: <20150410003916.GB1878@shell.msen.com> On Thu, Apr 09, 2015 at 12:04:53PM +0200, Bert Freudenberg wrote: > > On 08.04.2015, at 14:06, David T. Lewis wrote: > > On Wed, Apr 08, 2015 at 10:56:13AM +0200, Bert Freudenberg wrote: > >> > >> In Trunk, #useLocale is disabled (enabled in Etoys). Are we seriously all > >> using +01:00 times, and still expecting users to set the right time zone manually?! > > > > That's a problem for sure, we should fix it in the upcoming release > > So you're in a far away time zone, right? Why no, not at all. My time zone is right here in Michigan. It's all the rest of you that are far away ;-) > And yours still gets reported as +01:00? > Yes, that's right. With a SqueakTrunk image, I get this: DateAndTime now ==> 2015-04-09T19:52:01.01+01:00 But it should be this: DateAndTime now ==> 2015-04-09T19:52:01.01-04:00 If I enable the useLocale preference, I get the correct time zone offset: DateAndTime now ==> 2015-04-09T19:58:05.576-04:00 Dave From lewis at mail.msen.com Fri Apr 10 01:02:45 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Fri Apr 10 01:02:48 2015 Subject: [squeak-dev] SqueakSSL + TLS SNI In-Reply-To: References: Message-ID: <20150410010245.GC1878@shell.msen.com> On Fri, Apr 10, 2015 at 02:17:45AM +0200, Tobias Pape wrote: > Hi, > > > On 16.10.2014, at 13:46, Levente Uzonyi wrote: > > > Hi, > > > > I've implemented support for TLS SNI[1] for SqueakSSL on unix. I've uploaded the modified source files[2][3], a diff[4], and a prebuilt module[5] (built on Ubuntu 14.04 from the Cog branch). > > The image side code is also available[6], along with an updated version of the WebClient[7] package, and intermediate packages with various improvements[8]. > > The image side code works even if the plugin doesn't support TLS SNI, but this version of WebClient won't work with older versions of the SqueakSSL-Core package. > > Please review the changes, and consider adding them to the corresponding repositories! > > > > Levente > > > > [1] https://en.wikipedia.org/wiki/Server_Name_Indication > > [2] http://leves.web.elte.hu/squeak/SqueakSSL/SqueakSSL.h > > [3] http://leves.web.elte.hu/squeak/SqueakSSL/sqUnixOpenSSL.c > > [4] http://leves.web.elte.hu/squeak/SqueakSSL/diff.txt > > [5] http://leves.web.elte.hu/squeak/SqueakSSL/SqueakSSL > > [6] http://leves.web.elte.hu/squeak/SqueakSSL/SqueakSSL-Core-ul.29.mcz > > [7] http://leves.web.elte.hu/squeak/SqueakSSL/WebClient-Core-ul.98.mcz > > [8] http://leves.web.elte.hu/squeak/SqueakSSL/ > > I have things for OSX i think. > Can someone confirm? > > > Best > -Tobias > I added this to http://bugs.squeak.org/view.php?id=7824 Dave From tim at rowledge.org Fri Apr 10 02:52:41 2015 From: tim at rowledge.org (tim Rowledge) Date: Fri Apr 10 02:52:44 2015 Subject: [squeak-dev] Time primitives In-Reply-To: <20150410003916.GB1878@shell.msen.com> References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> <7A458A46-A615-4517-B7D5-6C79FCEA4A0F@freudenbergs.de> <20150408120629.GA58602@shell.msen.com> <20150410003916.GB1878@shell.msen.com> Message-ID: On 09-04-2015, at 5:39 PM, David T. Lewis wrote: > > Why no, not at all. My time zone is right here in Michigan. It's all > the rest of you that are far away ;-) How are we going to deal with *my* TZ? Vancouver Island is 7 minutes and 50 years behind the mainland... tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim Strange OpCodes: FR: Flip Record From lewis at mail.msen.com Fri Apr 10 03:11:30 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Fri Apr 10 03:11:31 2015 Subject: [squeak-dev] Time primitives In-Reply-To: References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> <7A458A46-A615-4517-B7D5-6C79FCEA4A0F@freudenbergs.de> <20150408120629.GA58602@shell.msen.com> <20150410003916.GB1878@shell.msen.com> Message-ID: <20150410031130.GA31028@shell.msen.com> On Thu, Apr 09, 2015 at 07:52:41PM -0700, tim Rowledge wrote: > > On 09-04-2015, at 5:39 PM, David T. Lewis wrote: > > > > Why no, not at all. My time zone is right here in Michigan. It's all > > the rest of you that are far away ;-) > > How are we going to deal with *my* TZ? Vancouver Island is 7 minutes and 50 years behind the mainland... We will need to add a preference for that. From tim at rowledge.org Fri Apr 10 03:12:35 2015 From: tim at rowledge.org (tim Rowledge) Date: Fri Apr 10 03:12:42 2015 Subject: [squeak-dev] Update your location on the swiki Message-ID: <11D3CB35-5EF0-418F-8C64-4826AF8CD787@rowledge.org> It?s been a while since the Who?s Where page (http://wiki.squeak.org/squeak/1302) got any updates. How about you all pop over and check your location is up to date. And while you?re in the area, drop by and update your personal page if you have one. Don?t have one? Find a page needing recycling (see http://wiki.squeak.org/squeak/3052) and make it your own. Then add it to http://wiki.squeak.org/squeak/5879 - go hog-wild and link around to a few things. Fix up a page or two. You can do it. Make us proud. tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim Strange OpCodes: NBRM: Unconditional No BRanch Multiple From commits at source.squeak.org Fri Apr 10 03:15:24 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 10 03:15:27 2015 Subject: [squeak-dev] The Trunk: MonticelloConfigurations-dtl.129.mcz Message-ID: David T. Lewis uploaded a new version of MonticelloConfigurations to project The Trunk: http://source.squeak.org/trunk/MonticelloConfigurations-dtl.129.mcz ==================== Summary ==================== Name: MonticelloConfigurations-dtl.129 Author: dtl Time: 9 April 2015, 11:15:18.378 pm UUID: a3862e40-7029-4a52-9d4f-62aaaa8767ff Ancestors: MonticelloConfigurations-bf.128 MCMcmUpdater class>>updateFromRepositories: has accumulated various enhancements and now wants to be factored into smaller methods. =============== Diff against MonticelloConfigurations-bf.128 =============== Item was added: + ----- Method: MCMcmUpdater class>>refreshUpdateMapFor:with: (in category 'updating') ----- + refreshUpdateMapFor: r with: updateList + "Update the LastUpdateMap and answer a possibly reduced updateList" + + | config | + (LastUpdateMap at: r description ifAbsent: [0]) = 0 ifTrue: [ + "No update has ever been loaded from this repo. If no package is + present in the image either, we can skip right to the latest config" + config := r versionNamed: updateList last value. + (config dependencies anySatisfy: [:dep| dep package hasWorkingCopy]) + ifFalse: [ (self useLatestPackagesFrom: r) + ifTrue: [LastUpdateMap at: r description put: updateList last key. + ^ #()] + ifFalse: [ ^ updateList last: 1]]]. + ^ updateList + ! Item was added: + ----- Method: MCMcmUpdater class>>updateFromConfig: (in category 'updating') ----- + updateFromConfig: config + + "Skip packages that were specifically unloaded" + config dependencies: (config dependencies + reject: [:dep| self skipPackages includes: dep package name]). + self updateMissingPackages ifFalse:[ + "Skip packages that are not in the image" + config dependencies: (config dependencies + select: [:dep| dep package hasWorkingCopy])]. + (config dependencies allSatisfy:[:dep| dep isFulfilled]) + ifFalse:[config upgrade]. + ! Item was changed: ----- Method: MCMcmUpdater class>>updateFromRepositories: (in category 'updating') ----- updateFromRepositories: repositoryUrls "MCMcmUpdater updateFromRepositories: #( 'http://squeaksource.com/MCUpdateTest' )" | repos config | MCConfiguration upgradeIsMerge: true. LastUpdateMap ifNil:[LastUpdateMap := Dictionary new]. "The list of repositories to consult in order" repos := repositoryUrls collect:[:url| MCRepositoryGroup default repositories detect:[:r| r description = url] ifNone:[ | r | r := MCHttpRepository location: url user: '' password: ''. MCRepositoryGroup default addRepository: r. r]]. "The list of updates-author.version.mcm sorted by version" + repos do:[ :r | config := self updateFromRepository: r ]. - repos do:[:r| r cacheAllFileNamesDuring:[ - | updateList | - updateList := self updateListFor: r. - "Proceed only if there are updates available at all." - updateList ifNotEmpty: [ - (LastUpdateMap at: r description ifAbsent: [0]) = 0 ifTrue: [ - "No update has ever been loaded from this repo. If no package is - present in the image either, we can skip right to the latest config" - config := r versionNamed: updateList last value. - (config dependencies anySatisfy: [:dep| dep package hasWorkingCopy]) - ifFalse: [ (self useLatestPackagesFrom: r) - ifTrue: [LastUpdateMap at: r description put: updateList last key. - updateList := #()] - ifFalse: [updateList := updateList last: 1]]]. - "Now process each update file. Check if we have all dependencies and if not, - load the entire configuration (this is mostly to skip older updates quickly)" - updateList do:[:assoc| - ProgressNotification signal: '' extra: 'Processing ', assoc value. - config := r versionNamed: assoc value. - "Skip packages that were specifically unloaded" - config dependencies: (config dependencies - reject: [:dep| self skipPackages includes: dep package name]). - self updateMissingPackages ifFalse:[ - "Skip packages that are not in the image" - config dependencies: (config dependencies - select: [:dep| dep package hasWorkingCopy])]. - (config dependencies allSatisfy:[:dep| dep isFulfilled]) - ifFalse:[config upgrade]. - LastUpdateMap at: r description put: assoc key. - ] displayingProgress: 'Processing configurations'. - "We've loaded all the provided update configurations. - Use the latest configuration to update all the remaining packages." - (self useLatestPackagesFrom: r) ifTrue: [ - config updateFromRepositories. - config upgrade]. - ]]. - ]. ^config! Item was added: + ----- Method: MCMcmUpdater class>>updateFromRepository: (in category 'updating') ----- + updateFromRepository: repository + + | config | + repository cacheAllFileNamesDuring: [ | updateList | + updateList := self updateListFor: repository. + "Proceed only if there are updates available at all." + updateList ifNotEmpty: [ + updateList := self refreshUpdateMapFor: repository with: updateList. + "Now process each update file. Check if we have all dependencies and if not, + load the entire configuration (this is mostly to skip older updates quickly)" + updateList do:[:assoc| + ProgressNotification signal: '' extra: 'Processing ', assoc value. + config := repository versionNamed: assoc value. + self updateFromConfig: config. + LastUpdateMap at: repository description put: assoc key. + ] displayingProgress: 'Processing configurations'. + "We've loaded all the provided update configurations. + Use the latest configuration to update all the remaining packages." + (self useLatestPackagesFrom: repository) ifTrue: [ + config updateFromRepositories. + config upgrade]. + ]]. + ^ config + ! From lewis at mail.msen.com Fri Apr 10 03:44:52 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Fri Apr 10 03:44:56 2015 Subject: [squeak-dev] Update your location on the swiki In-Reply-To: <11D3CB35-5EF0-418F-8C64-4826AF8CD787@rowledge.org> References: <11D3CB35-5EF0-418F-8C64-4826AF8CD787@rowledge.org> Message-ID: <20150410034452.GB31028@shell.msen.com> On Thu, Apr 09, 2015 at 08:12:35PM -0700, tim Rowledge wrote: > It?s been a while since the Who?s Where page (http://wiki.squeak.org/squeak/1302) got any updates. > > How about you all pop over and check your location is up to date. And while you?re in the area, drop by and update your personal page if you have one. Don?t have one? Find a page needing recycling (see http://wiki.squeak.org/squeak/3052) and make it your own. Then add it to > http://wiki.squeak.org/squeak/5879 - go hog-wild and link around to a few things. Fix up a page or two. > > You can do it. Make us proud. I am on that page under the Michigan -> Detroit and Ann Arbor category, which oddly enough turns out to be true since I actually do now reside in Ann Arbor. Apparently there are exactly two other Squeakers from Michigan. One is Doug Way, who has not been active in the community for quite a few years, but who I remember as being a very competent and active member of our community not so long ago. The other is Jason Rogers, who I do not really remember very clearly but who has listed himself as an Ann Arbor resident, so perhaps I will run into him at the Old Town Tavern down the street from me, which is where most of the important people are to be found. I think that Doug may still be in the area, but possibly has settled into a dreary routine of IT drudgery somewhere within Ford Motor Company. I have access to that corporate directory, so maybe I'll nag him into rejoining the world of the living (reference: http://wiki.squeak.org/squeak/2950). Dave From timfelgentreff at gmail.com Fri Apr 10 07:06:55 2015 From: timfelgentreff at gmail.com (timfelgentreff) Date: Fri Apr 10 07:19:39 2015 Subject: [squeak-dev] Re: The Trunk: Collections-tfel.613.mcz In-Reply-To: References: <34E4AA18-C466-4ABF-8FAC-98828777E102@freudenbergs.de> Message-ID: <1428649615397-4818782.post@n4.nabble.com> You're right the inconsistency isn't nice, but performance shouldn't be affected, so that is strange... About the inconsistency, I don't really see that ByteString>>byteAt:put: should do coercion. If the caller already knows they're putting a byte, than make sure that you're doing that. On the other hand, at:put: is the generic interface and for objects that can only accept bytes here, they should a) fail when it's not a byte or b) be nice and try to coerce it. My goal was to make the primitive truly optional again. That's what the test case is designed to check (although that also is also a bit brittle). I tried to find a small change that doesn't duplicate code and that passes the tests. Changing the fallback code in SequenceableCollection may also be possible, but I didn't want to add handling of byte subclasses there. That being said, the fact that the primitive allows me to at:put: a Character into a ByteArray seems inconsistent in any case (an artifact of the underlying representation in the C?). If those characters are implicitly converted into SmallIntegers in the byte range, why then can't we also put Characters into WordArrays, for example? -- View this message in context: http://forum.world.st/The-Trunk-Collections-tfel-613-mcz-tp4818483p4818782.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From mbaehr at email.archlab.tuwien.ac.at Fri Apr 10 07:27:53 2015 From: mbaehr at email.archlab.tuwien.ac.at (=?utf-8?q?Martin_B=C3=A4hr?=) Date: Fri Apr 10 07:27:59 2015 Subject: [squeak-dev] Time primitives In-Reply-To: References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> <7A458A46-A615-4517-B7D5-6C79FCEA4A0F@freudenbergs.de> <20150408120629.GA58602@shell.msen.com> <20150410003916.GB1878@shell.msen.com> Message-ID: <1428650613-sup-5236@email.archlab.tuwien.ac.at> Excerpts from tim Rowledge's message of 2015-04-10 04:52:41 +0200: > > Why no, not at all. My time zone is right here in Michigan. It's all > > the rest of you that are far away ;-) > How are we going to deal with *my* TZ? Vancouver Island is 7 minutes and 50 years behind the mainland... well, unfortunately that means that you'll have to wait a few more years before you get to use smalltalk. but in the meantime you can try to call up alan kay and find out more details from his work: http://www.smalltalk.org/smalltalk/TheEarlyHistoryOfSmalltalk_I.html greetings, martin. -- eKita - the online platform for your entire academic life -- chief engineer eKita.co pike programmer pike.lysator.liu.se caudium.net societyserver.org secretary beijinglug.org mentor fossasia.org foresight developer foresightlinux.org realss.com unix sysadmin Martin B?hr working in china http://societyserver.org/mbaehr/ From marcel.taeumel at student.hpi.uni-potsdam.de Fri Apr 10 08:21:36 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Fri Apr 10 08:34:19 2015 Subject: [squeak-dev] Re: [BUG] Scrolling blows up after updating image In-Reply-To: References: <1428590928265-4818606.post@n4.nabble.com> <1428592583371-4818618.post@n4.nabble.com> Message-ID: <1428654096107-4818799.post@n4.nabble.com> This could be another case where the Transcript windows hacks itself into displaying some contents -- regardless of whether it is running on a volatile code base... -.-" Best, Marcel -- View this message in context: http://forum.world.st/BUG-Scrolling-blows-up-after-updating-image-tp4818600p4818799.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From Das.Linux at gmx.de Fri Apr 10 09:01:26 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Fri Apr 10 09:01:31 2015 Subject: [squeak-dev] SqueakSSL + TLS SNI In-Reply-To: <20150410010245.GC1878@shell.msen.com> References: <20150410010245.GC1878@shell.msen.com> Message-ID: <462BB520-E8D2-49DD-9755-A7AAF5A831D6@gmx.de> Here's a Mac bundle, if someone is interested On 10.04.2015, at 03:02, David T. Lewis wrote: > On Fri, Apr 10, 2015 at 02:17:45AM +0200, Tobias Pape wrote: >> Hi, >> >> >> On 16.10.2014, at 13:46, Levente Uzonyi wrote: >> >>> Hi, >>> >>> I've implemented support for TLS SNI[1] for SqueakSSL on unix. I've uploaded the modified source files[2][3], a diff[4], and a prebuilt module[5] (built on Ubuntu 14.04 from the Cog branch). >>> The image side code is also available[6], along with an updated version of the WebClient[7] package, and intermediate packages with various improvements[8]. >>> The image side code works even if the plugin doesn't support TLS SNI, but this version of WebClient won't work with older versions of the SqueakSSL-Core package. >>> Please review the changes, and consider adding them to the corresponding repositories! >>> >>> Levente >>> >>> [1] https://en.wikipedia.org/wiki/Server_Name_Indication >>> [2] http://leves.web.elte.hu/squeak/SqueakSSL/SqueakSSL.h >>> [3] http://leves.web.elte.hu/squeak/SqueakSSL/sqUnixOpenSSL.c >>> [4] http://leves.web.elte.hu/squeak/SqueakSSL/diff.txt >>> [5] http://leves.web.elte.hu/squeak/SqueakSSL/SqueakSSL >>> [6] http://leves.web.elte.hu/squeak/SqueakSSL/SqueakSSL-Core-ul.29.mcz >>> [7] http://leves.web.elte.hu/squeak/SqueakSSL/WebClient-Core-ul.98.mcz >>> [8] http://leves.web.elte.hu/squeak/SqueakSSL/ >> >> I have things for OSX i think. >> Can someone confirm? >> >> >> Best >> -Tobias >> > > > I added this to http://bugs.squeak.org/view.php?id=7824 > > Dave -------------- next part -------------- A non-text attachment was scrubbed... Name: SqueakSSL.bundle.zip Type: application/zip Size: 7944 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150410/b9159a5e/SqueakSSL.bundle.zip From bert at freudenbergs.de Fri Apr 10 09:12:06 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Fri Apr 10 09:12:08 2015 Subject: [squeak-dev] Time primitives In-Reply-To: <20150410003916.GB1878@shell.msen.com> References: <35612.136.2.1.102.1428441431.squirrel@webmail.msen.com> <20150408011038.GA48704@shell.msen.com> <7A458A46-A615-4517-B7D5-6C79FCEA4A0F@freudenbergs.de> <20150408120629.GA58602@shell.msen.com> <20150410003916.GB1878@shell.msen.com> Message-ID: > On 10.04.2015, at 02:39, David T. Lewis wrote: > > On Thu, Apr 09, 2015 at 12:04:53PM +0200, Bert Freudenberg wrote: >>> On 08.04.2015, at 14:06, David T. Lewis wrote: >>> On Wed, Apr 08, 2015 at 10:56:13AM +0200, Bert Freudenberg wrote: >>>> >>>> In Trunk, #useLocale is disabled (enabled in Etoys). Are we seriously all >>>> using +01:00 times, and still expecting users to set the right time zone manually?! >>> >>> That's a problem for sure, we should fix it in the upcoming release >> >> So you're in a far away time zone, right? > > Why no, not at all. My time zone is right here in Michigan. It's all > the rest of you that are far away ;-) Midwestern-centric earth model ... why not ;-) >> And yours still gets reported as +01:00? >> > > Yes, that's right. With a SqueakTrunk image, I get this: > > DateAndTime now ==> 2015-04-09T19:52:01.01+01:00 > > But it should be this: > > DateAndTime now ==> 2015-04-09T19:52:01.01-04:00 > > If I enable the useLocale preference, I get the correct time zone offset: > > DateAndTime now ==> 2015-04-09T19:58:05.576-04:00 Well, if nothing else breaks, then maybe enabling useLocale is the simplest fix right now? It will not deal with time zone changes while the image is running, since it's only used on startup. - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150410/40cce742/smime.bin From karlramberg at gmail.com Fri Apr 10 10:32:56 2015 From: karlramberg at gmail.com (karl ramberg) Date: Fri Apr 10 10:32:59 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.849.mcz In-Reply-To: <552668ac.8a28370a.7b1b.0b67SMTPIN_ADDED_MISSING@mx.google.com> References: <552668ac.8a28370a.7b1b.0b67SMTPIN_ADDED_MISSING@mx.google.com> Message-ID: Hi, There seems to be a regression regarding mouseFocus vs. keyboardFocus. mouseFocus would scroll any pane on mouseOver disregarding the keyboard focus. This is at least my preferred style. Then there is no need to click before scrolling a pane, but I don't lose the keyboardFocus because I accidentally touched the trackpad or moved the mouse. Now there seem to be click for keyboardFocus or mouseOver for keyboardFocus only. Karl On Thu, Apr 9, 2015 at 1:54 PM, wrote: > Marcel Taeumel uploaded a new version of Morphic to project The Trunk: > http://source.squeak.org/trunk/Morphic-mt.849.mcz > > ==================== Summary ==================== > > Name: Morphic-mt.849 > Author: mt > Time: 9 April 2015, 1:54:41.384 pm > UUID: 37f99479-4262-b749-a6e3-df4d6fbc5cd0 > Ancestors: Morphic-mt.848 > > Fixed some widgets that failed to grab the keyboard on mouse-up, which is > the normal way if #mouseOverForKeyboardFocus is not enabled in the > preferences. > > =============== Diff against Morphic-mt.848 =============== > > Item was changed: > ----- Method: AlternatePluggableListMorphOfMany>>mouseUp: (in category > 'event handling') ----- > mouseUp: event > > event hand newKeyboardFocus: self. > + hasFocus := true.! > - hasFocus := true. > - ^self! > > Item was changed: > ----- Method: PluggableListMorphOfMany>>mouseUp: (in category 'event > handling') ----- > mouseUp: event > > + dragOnOrOff := nil. "So improperly started drags will have not > effect" > + event hand newKeyboardFocus: self. > + hasFocus := true.! > - dragOnOrOff := nil. "So improperly started drags will have not > effect"! > > Item was changed: > ----- Method: SimpleHierarchicalListMorph>>mouseUp: (in category 'event > handling') ----- > mouseUp: event > | aMorph | > aMorph := self itemFromPoint: event position. > aMorph ifNil: [^self]. > aMorph highlightedForMouseDown ifFalse: [^self]. > aMorph highlightForMouseDown: false. > model okToChange ifFalse: [^self]. > "No change if model is locked" > ((autoDeselect isNil or: [autoDeselect]) and: [aMorph == > selectedMorph]) > ifTrue: [self setSelectedMorph: nil] > ifFalse: [self setSelectedMorph: aMorph]. > + event hand newKeyboardFocus: self. > Cursor normal show! > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150410/20a6d9c7/attachment.htm From edgardec2005 at gmail.com Fri Apr 10 12:03:28 2015 From: edgardec2005 at gmail.com (Edgar J. De Cleene) Date: Fri Apr 10 12:30:34 2015 Subject: [squeak-dev] Slack <-> IRC bridge In-Reply-To: Message-ID: On 4/9/15, 10:02 AM, "Tobias Pape" wrote: > Hi, > > I have set up a bridge between > the Slack #public channel and the #squeak IRC channel on Freenode. > I hope this is appreciated. If you want, I can mirror #general instead :) > I think this makes the communication that is more actively happening on > slack a little bit more available to the general public. > > Note that this took two integration hooks on slack and we have only > five. Since the jenkins integration takes also one and an unconfigured > service (probably accidental?) of Ben Coman the forth, we only have one > left. If this is a problem, I'll cut down on that and disable the bridge :) > > Best > -Tobias Great. Thanks a lot and how we join this? Edgar From commits at source.squeak.org Fri Apr 10 12:58:37 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 10 12:58:38 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.851.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.851.mcz ==================== Summary ==================== Name: Morphic-mt.851 Author: mt Time: 10 April 2015, 2:57:59.334 pm UUID: 034c3519-a911-2e43-a318-d8731bd5ebc4 Ancestors: Morphic-mt.850 Keyboard-focus handling extended. Morphs may no #wantsKeyboardFocus so that they can take advantage of #keyboardFocusChange: in a transparent fashion. Until now, they to explicitely acquire the keyboard focus, which they sometimes forgot. Thus, #keyboardFocusChange: did not work as expected. All scroll panes want the keyboard focus. This includes pluggable text morphs and pluggable lists and pluggable trees. =============== Diff against Morphic-mt.850 =============== Item was changed: ----- Method: HandMorph>>newKeyboardFocus: (in category 'focus handling') ----- newKeyboardFocus: aMorphOrNil "Make the given morph the new keyboard focus, canceling the previous keyboard focus if any. If the argument is nil, the current keyboard focus is cancelled." + + | oldFocus newFocus | - | oldFocus | oldFocus := self keyboardFocus. + newFocus := aMorphOrNil ifNotNil: [:m | m keyboardFocusDelegate]. + + self keyboardFocus: newFocus. + + oldFocus == newFocus ifFalse: [ + oldFocus ifNotNil: [:m | m keyboardFocusChange: false]. + newFocus ifNotNil: [:m | m keyboardFocusChange: true]]. + + newFocus ifNotNil: [:m | + self compositionWindowManager keyboardFocusForAMorph: m]. + + ^ newFocus - self keyboardFocus: aMorphOrNil. - oldFocus ifNotNil: [oldFocus == aMorphOrNil ifFalse: [oldFocus keyboardFocusChange: false]]. - aMorphOrNil ifNotNil: [aMorphOrNil keyboardFocusChange: true. self compositionWindowManager keyboardFocusForAMorph: aMorphOrNil]. ! Item was changed: ----- Method: KeyboardEvent>>sentTo: (in category 'dispatching') ----- + sentTo: aMorph + "Dispatch the receiver into the given morph or another one if keyboard focus changes." + + | receivingMorph | + receivingMorph := aMorph. + aMorph wantsKeyboardFocus ifTrue: [ + receivingMorph := (self hand newKeyboardFocus: aMorph) ifNil: [aMorph]]. + + type == #keystroke ifTrue:[^receivingMorph handleKeystroke: self]. + type == #keyDown ifTrue:[^receivingMorph handleKeyDown: self]. + type == #keyUp ifTrue:[^receivingMorph handleKeyUp: self]. + + ^super sentTo: receivingMorph! - sentTo: anObject - "Dispatch the receiver into anObject" - type == #keystroke ifTrue:[^anObject handleKeystroke: self]. - type == #keyDown ifTrue:[^anObject handleKeyDown: self]. - type == #keyUp ifTrue:[^anObject handleKeyUp: self]. - ^super sentTo: anObject.! Item was added: + ----- Method: Morph>>keyboardFocusDelegate (in category 'event handling') ----- + keyboardFocusDelegate + "If this morph ever tries to acquire the keyboard focus, this can be delegate to, for example, a submorph." + + ^ self! Item was added: + ----- Method: Morph>>wantsKeyboardFocus (in category 'event handling') ----- + wantsKeyboardFocus + "Whether this morph should get the current keyboard focus when handling a keyboard event to speed up further event processing." + + ^ false! Item was removed: - ----- Method: PluggableListMorph>>handlesKeyboard: (in category 'event handling') ----- - handlesKeyboard: evt - ^true! Item was changed: ----- Method: PluggableListMorph>>keyStroke: (in category 'event handling') ----- keyStroke: event "Process keys The model is allowed to preview all keystrokes. If it's not interested: specialKeys are things like up, down, etc. ALWAYS HANDLED modifierKeys are regular characters either 1) accompanied with ctrl, cmd or 2) any character if the list doesn't want to handle basic keys (handlesBasicKeys returns false) basicKeys are any characters" + | aChar aSpecialKey | + (self previewKeystroke: event) + ifTrue: [^ self]. + (self scrollByKeyboard: event) + ifTrue: [^ self]. + - (self previewKeystroke: event) ifTrue: [ ^ self ]. - (self scrollByKeyboard: event) ifTrue: [^self]. aChar := event keyCharacter. + + (aSpecialKey := aChar asciiValue) < 32 + ifTrue: [^ self specialKeyPressed: aSpecialKey]. + - aSpecialKey := aChar asciiValue. - aSpecialKey < 32 ifTrue: [^ self specialKeyPressed: aSpecialKey]. (event anyModifierKeyPressed or: [self handlesBasicKeys not]) ifTrue: [^ self modifierKeyPressed: aChar]. + ^ self basicKeyPressed: aChar! Item was removed: - ----- Method: PluggableTextMorph>>handlesKeyboard: (in category 'event handling') ----- - handlesKeyboard: evt - ^true! Item was added: + ----- Method: PluggableTextMorph>>keyboardFocusDelegate (in category 'event handling') ----- + keyboardFocusDelegate + + ^ textMorph ifNil: [self]! Item was added: + ----- Method: ScrollPane>>handlesKeyboard: (in category 'event handling') ----- + handlesKeyboard: evt + ^ true! Item was added: + ----- Method: ScrollPane>>wantsKeyboardFocus (in category 'event handling') ----- + wantsKeyboardFocus + + ^ true! Item was removed: - ----- Method: SimpleHierarchicalListMorph>>handlesKeyboard: (in category 'event handling') ----- - handlesKeyboard: evt - ^true! From commits at source.squeak.org Fri Apr 10 13:05:53 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 10 13:05:54 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.852.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.852.mcz ==================== Summary ==================== Name: Morphic-mt.852 Author: mt Time: 10 April 2015, 3:05:10.54 pm UUID: 3fbc4d70-77b4-824f-8ec6-a66ae712ce9a Ancestors: Morphic-mt.851 Convenient messages added to morphs to check for current mouse or keyboard focus. Could be used, for example, to change visual appearnce to indicate that focus. Does not happen yet (except for the blinking text cursor). (in conjunction with #keyboardFocusChange:). Note: We should get rid of #hasFocus because only hands now the exact information. For multiple hands, such cached information in the morph may not valid anyway. =============== Diff against Morphic-mt.851 =============== Item was changed: ----- Method: Morph>>hasFocus (in category 'event handling') ----- hasFocus + + self flag: #obsolete. "mt: Use #hasKeyboardFocus instead, which reads live hand information and no cache." ^ false! Item was added: + ----- Method: Morph>>hasKeyboardFocus (in category 'event handling') ----- + hasKeyboardFocus + + ^ self hasKeyboardFocus: self activeHand! Item was added: + ----- Method: Morph>>hasKeyboardFocus: (in category 'event handling') ----- + hasKeyboardFocus: aHand + + ^ aHand keyboardFocus == self! Item was added: + ----- Method: Morph>>hasMouseFocus (in category 'event handling') ----- + hasMouseFocus + + ^ self hasMouseFocus: self activeHand! Item was added: + ----- Method: Morph>>hasMouseFocus: (in category 'event handling') ----- + hasMouseFocus: aHand + + ^ aHand mouseFocus == self! From commits at source.squeak.org Fri Apr 10 13:08:26 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 10 13:08:29 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.853.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.853.mcz ==================== Summary ==================== Name: Morphic-mt.853 Author: mt Time: 10 April 2015, 3:07:39.015 pm UUID: b6de4c8e-4df3-2946-9608-12ff51775de1 Ancestors: Morphic-mt.852 Some cosmetic fixes in sliders, scroll bars, and scroll panes. =============== Diff against Morphic-mt.852 =============== Item was added: + ----- Method: ScrollBar>>defaultBorderWidth (in category 'initialize') ----- + defaultBorderWidth + ^ 0! Item was changed: ----- Method: ScrollBar>>updateSlider (in category 'initialize') ----- updateSlider + | imagesNeedUpdate | + imagesNeedUpdate := upButton width ~= (self bounds isWide ifTrue: [self height] ifFalse: [self width]). + self menuButton visible: (self bounds isWide or: [self class scrollBarsWithoutMenuButton]) not; bounds: self boundsForMenuButton. upButton visible: self class scrollBarsWithoutArrowButtons not; bounds: self boundsForUpButton. downButton visible: self class scrollBarsWithoutArrowButtons not; bounds: self boundsForDownButton. super updateSlider. pagingArea bounds: self totalSliderArea. - self expandSlider. + + imagesNeedUpdate ifTrue: [ + self menuButton visible ifTrue: [self updateMenuButtonImage]. + upButton visible ifTrue: [self updateUpButtonImage]. + downButton visible ifTrue: [self updateDownButtonImage]].! - ! Item was changed: ----- Method: ScrollBar>>updateSliderColor: (in category 'access') ----- updateSliderColor: aColor - | gradient | + | gradient | - self borderWidth: 0. - Preferences gradientScrollBars ifFalse: [ slider borderColor: aColor muchDarker; color: aColor. pagingArea borderColor: (aColor muchDarker alpha: pagingArea borderStyle color alpha); color: (aColor darker alpha: 0.45). ^ self]. slider borderStyle: (BorderStyle width: 1 color: Color lightGray). "Fill the slider." gradient := GradientFillStyle ramp: { 0 -> (Color gray: 0.95). 0.49 -> (Color gray: 0.9). 0.5 -> (Color gray: 0.87). 1 -> (Color gray: 0.93). }. gradient origin: slider topLeft. gradient direction: (self bounds isWide ifTrue:[0@slider height] ifFalse:[slider width@0]). slider fillStyle: gradient. "Fill the paging area." gradient := GradientFillStyle ramp: { 0 -> (Color gray: 0.65). 0.6 -> (Color gray: 0.82). 1 -> (Color gray: 0.88). }. gradient origin: self topLeft. gradient direction: (self bounds isWide ifTrue:[0@self height] ifFalse:[self width@0]). pagingArea fillStyle: gradient.! Item was changed: ----- Method: ScrollPane>>hResizeScrollBar (in category 'geometry') ----- hResizeScrollBar | topLeft h border offset | "TEMPORARY: IF OLD SCROLLPANES LYING AROUND THAT DON'T HAVE A hScrollBar, INIT THEM" hScrollBar ifNil: [ self hInitScrollBarTEMPORARY]. (self valueOfProperty: #noHScrollBarPlease ifAbsent: [false]) ifTrue: [^self]. bounds ifNil: [ self fullBounds ]. h := self scrollBarThickness. border := borderWidth. offset := (scrollBarOnLeft and: [self vIsScrollbarShowing]) ifTrue: [h] ifFalse: [0]. topLeft := retractableScrollBar ifTrue: [bounds bottomLeft + (border + offset @ border negated)] ifFalse: [bounds bottomLeft + (border + offset @ (h + border) negated)]. + hScrollBar bounds: (topLeft + (border negated @ border) extent: self hScrollBarWidth@ h) - hScrollBar bounds: (topLeft + (-1@1) extent: self hScrollBarWidth@ h) ! Item was changed: ----- Method: ScrollPane>>initializeScrollBars (in category 'initialization') ----- initializeScrollBars "initialize the receiver's scrollBar" (scrollBar := ScrollBar on: self getValue: nil setValue: #vScrollBarValue:) + menuSelector: #vScrollBarMenuButtonPressed:. - menuSelector: #vScrollBarMenuButtonPressed:; - borderWidth: 1; - borderColor: Color black. (hScrollBar := ScrollBar on: self getValue: nil setValue: #hScrollBarValue:) + menuSelector: #hScrollBarMenuButtonPressed:. - menuSelector: #hScrollBarMenuButtonPressed:; - borderWidth: 1; - borderColor: Color black. "" scroller := TransformMorph new color: Color transparent. scroller offset: 0 @ 0. self addMorph: scroller. "" scrollBar initializeEmbedded: retractableScrollBar not. hScrollBar initializeEmbedded: retractableScrollBar not. retractableScrollBar ifFalse: [self addMorph: scrollBar; addMorph: hScrollBar]. Preferences alwaysShowVScrollbar ifTrue: [ self alwaysShowVScrollBar: true ]. Preferences alwaysHideHScrollbar ifTrue:[self hideHScrollBarIndefinitely: true ] ifFalse: [Preferences alwaysShowHScrollbar ifTrue: [ self alwaysShowHScrollBar: true ]]. ! Item was changed: ----- Method: ScrollPane>>innerBounds (in category 'geometry') ----- innerBounds | inner | inner := super innerBounds. retractableScrollBar | (submorphs includes: scrollBar) not ifFalse:[ inner := (scrollBarOnLeft ifTrue: [scrollBar right @ inner top corner: inner bottomRight] ifFalse: [inner topLeft corner: scrollBar left @ inner bottom]) ]. (retractableScrollBar | self hIsScrollbarShowing not) ifTrue: [^ inner] + ifFalse: [^ inner topLeft corner: (inner bottomRight - (0@(self scrollBarThickness - self borderWidth)))]. - ifFalse: [^ inner topLeft corner: (inner bottomRight - (0@(self scrollBarThickness - 1)))]. ! Item was changed: ----- Method: ScrollPane>>vResizeScrollBar (in category 'geometry') ----- vResizeScrollBar + | w topLeft border | - | w topLeft borderHeight innerWidth | w := self scrollBarThickness. + border := self borderWidth. - innerWidth := self flatColoredScrollBarLook - ifTrue: - [borderHeight := borderWidth. - 0] - ifFalse: - [borderHeight := 0. - 1]. topLeft := scrollBarOnLeft + ifTrue: [retractableScrollBar + ifTrue: [bounds topLeft - ((w - border) @ border negated)] + ifFalse: [bounds topLeft + (border @ border)]] + ifFalse: [retractableScrollBar + ifTrue: [bounds topRight - (border @ border negated)] + ifFalse: [bounds topRight - ((w + border) @ border negated)]]. - ifTrue: - [retractableScrollBar - ifTrue: [bounds topLeft - ((w - borderWidth) @ (0 - borderHeight))] - ifFalse: [bounds topLeft + ((borderWidth - innerWidth) @ borderHeight)]] - ifFalse: - [retractableScrollBar - ifTrue: [bounds topRight - (borderWidth @ (0 - borderHeight))] - ifFalse: - [bounds topRight - ((w + borderWidth - innerWidth) @ (0 - borderHeight))]]. scrollBar + bounds: (topLeft + ((scrollBarOnLeft ifTrue: [border negated] ifFalse: [border]) @ border negated) + extent: w @ self vScrollBarHeight) - bounds: (topLeft + ((scrollBarOnLeft ifTrue: [-1] ifFalse: [1]) @ -1) extent: w @ self vScrollBarHeight) ! Item was changed: ----- Method: Slider>>extent: (in category 'geometry') ----- extent: newExtent + + (bounds extent closeTo: newExtent) ifTrue: [^ self]. + - newExtent = bounds extent ifTrue: [^ self]. bounds isWide ifTrue: [super extent: (newExtent x max: self sliderThickness * 2) @ newExtent y] ifFalse: [super extent: newExtent x @ (newExtent y max: self sliderThickness * 2)]. + self updateSlider.! From commits at source.squeak.org Fri Apr 10 13:17:12 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 10 13:17:13 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.854.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.854.mcz ==================== Summary ==================== Name: Morphic-mt.854 Author: mt Time: 10 April 2015, 3:16:41.956 pm UUID: 343e2fa3-d761-2446-bf36-92adc76ce1ad Ancestors: Morphic-mt.853 Extracted drawing of drop-highlights and mouse-down-highlights into #drawOverlayOn: to give subclasses a chance to draw something over their submorphs in a general fashion (w/o having to overwrite #fullDrawOn:). =============== Diff against Morphic-mt.853 =============== Item was added: + ----- Method: Morph>>drawOverlayOn: (in category 'drawing') ----- + drawOverlayOn: aCanvas + "Draw something over all my submorphs." + + self drawDropHighlightOn: aCanvas. + self drawMouseDownHighlightOn: aCanvas.! Item was changed: ----- Method: Morph>>fullDrawOn: (in category 'drawing') ----- fullDrawOn: aCanvas "Draw the full Morphic structure on the given Canvas" self visible ifFalse: [^ self]. (aCanvas isVisible: self fullBounds) ifFalse:[^self]. (self hasProperty: #errorOnDraw) ifTrue:[^self drawErrorOn: aCanvas]. "Note: At some point we should generalize this into some sort of multi-canvas so that we can cross-optimize some drawing operations." "Pass 1: Draw eventual drop-shadow" self hasDropShadow ifTrue: [self drawDropShadowOn: aCanvas]. (self hasRolloverBorder and: [(aCanvas seesNothingOutside: self bounds) not]) ifTrue: [self drawRolloverBorderOn: aCanvas]. "Pass 2: Draw receiver itself" (aCanvas isVisible: self bounds) ifTrue:[aCanvas drawMorph: self]. self drawSubmorphsOn: aCanvas. + self drawOverlayOn: aCanvas.! - self drawDropHighlightOn: aCanvas. - self drawMouseDownHighlightOn: aCanvas.! From commits at source.squeak.org Fri Apr 10 13:18:47 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 10 13:18:48 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.855.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.855.mcz ==================== Summary ==================== Name: Morphic-mt.855 Author: mt Time: 10 April 2015, 3:18:14.893 pm UUID: 7ce3c391-82b8-c74b-a17b-d03774336ec9 Ancestors: Morphic-mt.854 Fixed category. =============== Diff against Morphic-mt.854 =============== Item was changed: + ----- Method: Morph>>handlerForMouseDown: (in category 'event handling') ----- - ----- Method: Morph>>handlerForMouseDown: (in category 'event handling-override') ----- handlerForMouseDown: anEvent "Return the (prospective) handler for a mouse down event. The handler is temporarily installed and can be used for morphs further down the hierarchy to negotiate whether the inner or the outer morph should finally handle the event." anEvent blueButtonPressed ifTrue: [^ self handlerForBlueButtonDown: anEvent]. anEvent yellowButtonPressed ifTrue: [^ self handlerForYellowButtonDown: anEvent]. anEvent controlKeyPressed ifTrue: [^ self handlerForMetaMenu: anEvent]. (self handlesMouseDown: anEvent) ifFalse: [^ nil]. "not interested" anEvent handler ifNil: [^ self ]. "Same priority but I am innermost" "Nobody else was interested" ^self mouseDownPriority >= anEvent handler mouseDownPriority ifTrue: [ self] ifFalse: [ nil]! From leves at elte.hu Fri Apr 10 13:33:10 2015 From: leves at elte.hu (Levente Uzonyi) Date: Fri Apr 10 13:33:14 2015 Subject: [squeak-dev] SqueakSSL + TLS SNI In-Reply-To: <462BB520-E8D2-49DD-9755-A7AAF5A831D6@gmx.de> References: <20150410010245.GC1878@shell.msen.com> <462BB520-E8D2-49DD-9755-A7AAF5A831D6@gmx.de> Message-ID: I'm sure there's interest, because websites with wildcard certificates (which means most large websites) don't work without the SNI extension. I read through your code, and it looks good to me. The "if(" -> "if (" rewrite was a bit annoying though. Maybe you should CC th vm-dev list, or just ping Eliot to get it into the Cog branch. Levente On Fri, 10 Apr 2015, Tobias Pape wrote: > Here's a Mac bundle, if someone is interested > > On 10.04.2015, at 03:02, David T. Lewis wrote: > >> On Fri, Apr 10, 2015 at 02:17:45AM +0200, Tobias Pape wrote: >>> Hi, >>> >>> >>> On 16.10.2014, at 13:46, Levente Uzonyi wrote: >>> >>>> Hi, >>>> >>>> I've implemented support for TLS SNI[1] for SqueakSSL on unix. I've uploaded the modified source files[2][3], a diff[4], and a prebuilt module[5] (built on Ubuntu 14.04 from the Cog branch). >>>> The image side code is also available[6], along with an updated version of the WebClient[7] package, and intermediate packages with various improvements[8]. >>>> The image side code works even if the plugin doesn't support TLS SNI, but this version of WebClient won't work with older versions of the SqueakSSL-Core package. >>>> Please review the changes, and consider adding them to the corresponding repositories! >>>> >>>> Levente >>>> >>>> [1] https://en.wikipedia.org/wiki/Server_Name_Indication >>>> [2] http://leves.web.elte.hu/squeak/SqueakSSL/SqueakSSL.h >>>> [3] http://leves.web.elte.hu/squeak/SqueakSSL/sqUnixOpenSSL.c >>>> [4] http://leves.web.elte.hu/squeak/SqueakSSL/diff.txt >>>> [5] http://leves.web.elte.hu/squeak/SqueakSSL/SqueakSSL >>>> [6] http://leves.web.elte.hu/squeak/SqueakSSL/SqueakSSL-Core-ul.29.mcz >>>> [7] http://leves.web.elte.hu/squeak/SqueakSSL/WebClient-Core-ul.98.mcz >>>> [8] http://leves.web.elte.hu/squeak/SqueakSSL/ >>> >>> I have things for OSX i think. >>> Can someone confirm? >>> >>> >>> Best >>> -Tobias >>> >> >> >> I added this to http://bugs.squeak.org/view.php?id=7824 >> >> Dave > > From Das.Linux at gmx.de Fri Apr 10 13:37:09 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Fri Apr 10 13:37:13 2015 Subject: [squeak-dev] Slack <-> IRC bridge In-Reply-To: References: Message-ID: <59BC7517-DC04-49C5-ADC1-B8EC4E8820A1@gmx.de> On 10.04.2015, at 14:03, Edgar J. De Cleene wrote: > > > > On 4/9/15, 10:02 AM, "Tobias Pape" wrote: > >> Hi, >> >> I have set up a bridge between >> the Slack #public channel and the #squeak IRC channel on Freenode. >> I hope this is appreciated. If you want, I can mirror #general instead :) >> I think this makes the communication that is more actively happening on >> slack a little bit more available to the general public. >> >> Note that this took two integration hooks on slack and we have only >> five. Since the jenkins integration takes also one and an unconfigured >> service (probably accidental?) of Ben Coman the forth, we only have one >> left. If this is a problem, I'll cut down on that and disable the bridge :) >> >> Best >> -Tobias > > Great. > Thanks a lot and how we join this? this is the normal #squeak channel on Freenode IRC. Freenode.net has a nice introduction and webchat.freenote.net helps, too :) Best -Tobias > > Edgar From eliot.miranda at gmail.com Fri Apr 10 13:46:33 2015 From: eliot.miranda at gmail.com (Eliot Miranda) Date: Fri Apr 10 13:46:39 2015 Subject: [squeak-dev] New Cog VMs available In-Reply-To: <256F46F5-91B0-4552-A9E9-25BAAA2733DF@gmx.de> References: <0F3C260D-2441-4272-8578-E4497BE65C1A@gmx.de> <256F46F5-91B0-4552-A9E9-25BAAA2733DF@gmx.de> Message-ID: <72A53D36-2E38-42E9-A1A9-E95DDD94AFC2@gmail.com> On Apr 9, 2015, at 3:21 PM, Tobias Pape wrote: > > On 10.04.2015, at 00:17, Tobias Pape wrote: > >> Updated on the CI :) > > aaand reverted. We got a crash: > http://build.squeak.org/job/SqueakTrunk/1245/console Yes. I get a crash in updating with the v3 VM. So far no problems with the Spur VM. But Tibias, unless the bleeding edge gets tested how will I spit these regressions? I need to know. So can we not have two builds, one with the last known good and one with the bleeding edge? Otherwise I'm flying blind. > > Best > -Tobias > >> Best >> -Tobias >> On 09.04.2015, at 23:28, Eliot Miranda wrote: >> >>> ... at http://www.mirandabanda.org/files/Cog/VM/VM.r3308/. >>> >>> CogVM binaries as per VMMaker.oscog-eem.1178/r3308 >>> >>> Plugins: >>> Integrate Nicolas' fixes that use positiveMachineIntegerFor: for pointers. >>> >>> Newspeak: >>> Print a warning in the method shared under multiple selectors scenario. >>> >>> Implement outer sends as clean sends just like implicit receiver sends. Add >>> ObjectRepresentation>>illegalClassTag and use it for initializing and unlinking >>> implicit and outer sends. >>> >>> Newspeak & Sista: >>> The multiple bytecode set block initial nil counters need >>> to be specific to the bytecode set in effect. >>> >>> Spur: >>> Implement Clement's much better solution for the stale supersend problem. >>> Place code at the send site for super sends to follow stale forwarded >>> receivers. This parallels the interpreter implementation. >>> >>> Beef up the post-become scan of send sites to >>> unlink all send sites that link to an invalid class tag. >>> >>> Cogit: >>> Optimize StackToRegisterMappingCogit>>genReturnReceiver >>> to not load ReceiverResultReg if it already contains self. >>> >>> Revise method map generation to provide multiple send type annotations. Add >>> an IsAnnotationExtension annotation type that implicitly has a zero displacement >>> and uses its displacement bits to extend the preceeding IsSendCall annotation. >>> This allows us to eliminate all the exotic entry-points and keep only the >>> checked and unchecked entries. >>> >>> Change IA32's genPushRegisterArgsForNumArgs: to not smash TempReg now that it >>> is used in directed super send trampolines. >>> >>> Use PushCq to pass small integer constants in the trampolines instead of >>> smashing TempReg, which is now used to hold the directed supersend argument. >>> Add support for PushCq. Could use PushCw but on x86 PushCq is a lot shorter. >>> >>> Mac builds: Use UTC as the timezone for the build timestamp. Using the local >>> timezone doesn't work :(. > > > From bert at freudenbergs.de Fri Apr 10 14:15:46 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Fri Apr 10 14:15:49 2015 Subject: [squeak-dev] The Trunk: MonticelloConfigurations-dtl.129.mcz In-Reply-To: References: Message-ID: <0C5B009A-ED69-4E6B-A4A8-56815605B7F0@freudenbergs.de> On 10.04.2015, at 03:15, commits@source.squeak.org wrote: > > David T. Lewis uploaded a new version of MonticelloConfigurations to project The Trunk: > http://source.squeak.org/trunk/MonticelloConfigurations-dtl.129.mcz > > ==================== Summary ==================== > > Name: MonticelloConfigurations-dtl.129 > Author: dtl > Time: 9 April 2015, 11:15:18.378 pm > UUID: a3862e40-7029-4a52-9d4f-62aaaa8767ff > Ancestors: MonticelloConfigurations-bf.128 > > MCMcmUpdater class>>updateFromRepositories: has accumulated various enhancements and now wants to be factored into smaller methods. That's way too reasonable ... ;^) - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150410/bdf0640f/smime.bin From commits at source.squeak.org Fri Apr 10 14:37:07 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 10 14:37:08 2015 Subject: [squeak-dev] The Trunk: Collections-bf.614.mcz Message-ID: Bert Freudenberg uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections-bf.614.mcz ==================== Summary ==================== Name: Collections-bf.614 Author: bf Time: 10 April 2015, 4:36:46.5 pm UUID: 11d550b8-ccbb-4711-be86-8626971305d9 Ancestors: Collections-tfel.613 Revert WeakArray>>species temporarily to see if this fixes testNoObsoleteClasses on the build server =============== Diff against Collections-tfel.613 =============== Item was changed: ----- Method: WeakArray>>species (in category 'private') ----- species "More useful to have strongly-referenced results of #select: and #collect:." + ^super species "disabled temporarily to see if this fixes testNoObsoleteClasses on the build server" + "^ Array"! - ^ Array! From bert at freudenbergs.de Fri Apr 10 14:38:12 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Fri Apr 10 14:38:15 2015 Subject: [squeak-dev] WeakArray species (was The Trunk: Collections-bf.612.mcz) In-Reply-To: References: <5523c7d5.162b370a.573d.5b8aSMTPIN_ADDED_MISSING@mx.google.com> <96F864DC-C66C-4A60-BED2-68E43988EF31@freudenbergs.de> <65D869D1-C084-45DF-94A8-DF1194F5A01D@freudenbergs.de> Message-ID: <4E426EC9-9F4C-47D6-838F-79E5B19476D7@freudenbergs.de> > On 09.04.2015, at 20:27, Tobias Pape wrote: > > Hi, > > On 09.04.2015, at 12:03, Bert Freudenberg wrote: > >> On 08.04.2015, at 18:03, Chris Muller wrote: >>> >>> The impetus for the change was so that (WeakArray new = Array new) >>> would return true instead of false. But we could accomplish that by >>> overriding #= instead of #species, I think.. >>> >>> Do you think overriding #species in WeakArray at this point in the >>> release process is too aggressive? >> >> Not sure. The #testNoObsoleteClasses test is still failing, even though there were fewer obsolete classes when we fixed WeakArray>>copyWith:. Would reverting #species help fix these for good? > > I am unsure. Is there a weak-ref-guru out there? It would help to know what still holds onto the obsolete classes. Unfortunately, the test image does not get saved for a post-mortem. Let's see if Collections-bf.614 makes a difference ... - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150410/ea5532d4/smime.bin From bert at freudenbergs.de Fri Apr 10 15:03:45 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Fri Apr 10 15:03:48 2015 Subject: [squeak-dev] WeakArray species (was The Trunk: Collections-bf.612.mcz) In-Reply-To: <4E426EC9-9F4C-47D6-838F-79E5B19476D7@freudenbergs.de> References: <5523c7d5.162b370a.573d.5b8aSMTPIN_ADDED_MISSING@mx.google.com> <96F864DC-C66C-4A60-BED2-68E43988EF31@freudenbergs.de> <65D869D1-C084-45DF-94A8-DF1194F5A01D@freudenbergs.de> <4E426EC9-9F4C-47D6-838F-79E5B19476D7@freudenbergs.de> Message-ID: <78419670-7622-46E1-8C06-138F03E19E85@freudenbergs.de> > On 10.04.2015, at 16:38, Bert Freudenberg wrote: > > >> On 09.04.2015, at 20:27, Tobias Pape wrote: >> >> Hi, >> >> On 09.04.2015, at 12:03, Bert Freudenberg wrote: >> >>> On 08.04.2015, at 18:03, Chris Muller wrote: >>>> >>>> The impetus for the change was so that (WeakArray new = Array new) >>>> would return true instead of false. But we could accomplish that by >>>> overriding #= instead of #species, I think.. >>>> >>>> Do you think overriding #species in WeakArray at this point in the >>>> release process is too aggressive? >>> >>> Not sure. The #testNoObsoleteClasses test is still failing, even though there were fewer obsolete classes when we fixed WeakArray>>copyWith:. Would reverting #species help fix these for good? >> >> I am unsure. Is there a weak-ref-guru out there? > > It would help to know what still holds onto the obsolete classes. Unfortunately, the test image does not get saved for a post-mortem. > > Let's see if Collections-bf.614 makes a difference ... Nope, no difference: ==================================================================================== http://build.squeak.org/job/SqueakTrunk/1250/console 2015-04-10T16:54:29.378+01:00: Collections (bf.614) Failed Tests.Release.ReleaseTest.testNoObsoleteClasses (from Tests) Failing for the past 620 builds (Since #631 ) Took 92 ms. Error Message AnObsoleteMCMockClassA, AnObsoleteMCMockASubclass, AnObsoleteMCMockClassB, AnObsoleteMCMockClassD, AnObsoleteMCMockClassE, AnObsoleteMCMockClassF, AnObsoleteMCMockClassG, AnObsoleteMCMockClassH, AnObsoleteMCMockClassI, AnObsoleteClassVarScopeParent, AnObsoleteClassVarScopeChild, AnObsoleteClassVarScopeGrandchild, AnObsoleteClassVarScopeParent, AnObsoleteClassVarScopeChild, AnObsoleteClassVarScopeGrandchild, AnObsoleteClassVarScopeParent, AnObsoleteClassVarScopeChild, AnObsoleteClassVarScopeGrandchild, AnObsoleteClassVarScopeParent, AnObsoleteClassVarScopeChild, AnObsoleteClassVarScopeGrandchild, AnObsoleteClassVarScopeParent, AnObsoleteClassVarScopeChild, AnObsoleteClassVarScopeGrandchild, AnObsoleteClassVarScopeParent, AnObsoleteClassVarScopeChild, AnObsoleteClassVarScopeGrandchild, AnObsoleteClassVarScopeParent, AnObsoleteClassVarScopeChild, AnObsoleteClassVarScopeGrandchild, AnObsoleteClassVarScopeParent, AnObsoleteClassVarScopeChild, AnObsoleteClassVarScopeGrandchild, AnObsoleteClassVarScopeParent, AnObsoleteClassVarScopeChild, AnObsoleteClassVarScopeGrandchild, AnObsoleteClassVarScopeParent, AnObsoleteClassVarScopeChild and AnObsoleteClassVarScopeGrandchild are obsolete Stacktrace ReleaseTest(TestCase)>>assert:description: ReleaseTest>>testNoObsoleteClasses ReleaseTest(TestCase)>>performTest ==================================================================================== - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150410/368d6531/smime.bin From Das.Linux at gmx.de Fri Apr 10 15:21:04 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Fri Apr 10 15:21:07 2015 Subject: [squeak-dev] New Cog VMs available In-Reply-To: <72A53D36-2E38-42E9-A1A9-E95DDD94AFC2@gmail.com> References: <0F3C260D-2441-4272-8578-E4497BE65C1A@gmx.de> <256F46F5-91B0-4552-A9E9-25BAAA2733DF@gmx.de> <72A53D36-2E38-42E9-A1A9-E95DDD94AFC2@gmail.com> Message-ID: <4024C928-7DE8-4F9C-963E-C7F86B834AF3@gmx.de> Hi Eliot, On 10.04.2015, at 15:46, Eliot Miranda wrote: > > > > On Apr 9, 2015, at 3:21 PM, Tobias Pape wrote: > >> >> On 10.04.2015, at 00:17, Tobias Pape wrote: >> >>> Updated on the CI :) >> >> aaand reverted. We got a crash: >> http://build.squeak.org/job/SqueakTrunk/1245/console > > Yes. I get a crash in updating with the v3 VM. So far no problems with the Spur VM. But Tibias, unless the bleeding edge gets tested how will I spit these regressions? I need to know. So can we not have two builds, one with the last known good and one with the bleeding edge? Sure, this is possible. probably something like a matrix build. Frank is more savvy with the infrastructure, tho. best -Tobias > Otherwise I'm flying blind. > >> >> Best >> -Tobias >> >>> Best >>> -Tobias >>> On 09.04.2015, at 23:28, Eliot Miranda wrote: >>> >>>> ... at http://www.mirandabanda.org/files/Cog/VM/VM.r3308/. >>>> >>>> CogVM binaries as per VMMaker.oscog-eem.1178/r3308 >>>> >>>> Plugins: >>>> Integrate Nicolas' fixes that use positiveMachineIntegerFor: for pointers. >>>> >>>> Newspeak: >>>> Print a warning in the method shared under multiple selectors scenario. >>>> >>>> Implement outer sends as clean sends just like implicit receiver sends. Add >>>> ObjectRepresentation>>illegalClassTag and use it for initializing and unlinking >>>> implicit and outer sends. >>>> >>>> Newspeak & Sista: >>>> The multiple bytecode set block initial nil counters need >>>> to be specific to the bytecode set in effect. >>>> >>>> Spur: >>>> Implement Clement's much better solution for the stale supersend problem. >>>> Place code at the send site for super sends to follow stale forwarded >>>> receivers. This parallels the interpreter implementation. >>>> >>>> Beef up the post-become scan of send sites to >>>> unlink all send sites that link to an invalid class tag. >>>> >>>> Cogit: >>>> Optimize StackToRegisterMappingCogit>>genReturnReceiver >>>> to not load ReceiverResultReg if it already contains self. >>>> >>>> Revise method map generation to provide multiple send type annotations. Add >>>> an IsAnnotationExtension annotation type that implicitly has a zero displacement >>>> and uses its displacement bits to extend the preceeding IsSendCall annotation. >>>> This allows us to eliminate all the exotic entry-points and keep only the >>>> checked and unchecked entries. >>>> >>>> Change IA32's genPushRegisterArgsForNumArgs: to not smash TempReg now that it >>>> is used in directed super send trampolines. >>>> >>>> Use PushCq to pass small integer constants in the trampolines instead of >>>> smashing TempReg, which is now used to hold the directed supersend argument. >>>> Add support for PushCq. Could use PushCw but on x86 PushCq is a lot shorter. >>>> >>>> Mac builds: Use UTC as the timezone for the build timestamp. Using the local >>>> timezone doesn't work :(. From nicolas.cellier.aka.nice at gmail.com Fri Apr 10 15:21:06 2015 From: nicolas.cellier.aka.nice at gmail.com (Nicolas Cellier) Date: Fri Apr 10 15:21:13 2015 Subject: [squeak-dev] WeakArray species (was The Trunk: Collections-bf.612.mcz) In-Reply-To: <78419670-7622-46E1-8C06-138F03E19E85@freudenbergs.de> References: <5523c7d5.162b370a.573d.5b8aSMTPIN_ADDED_MISSING@mx.google.com> <96F864DC-C66C-4A60-BED2-68E43988EF31@freudenbergs.de> <65D869D1-C084-45DF-94A8-DF1194F5A01D@freudenbergs.de> <4E426EC9-9F4C-47D6-838F-79E5B19476D7@freudenbergs.de> <78419670-7622-46E1-8C06-138F03E19E85@freudenbergs.de> Message-ID: This sounds like scories left by another TestCase... So natural questions arising are - doesn't it depend on the ordering of test cases? - How are TestCase ordered exactly? 2015-04-10 17:03 GMT+02:00 Bert Freudenberg : > > > On 10.04.2015, at 16:38, Bert Freudenberg wrote: > > > > > >> On 09.04.2015, at 20:27, Tobias Pape wrote: > >> > >> Hi, > >> > >> On 09.04.2015, at 12:03, Bert Freudenberg wrote: > >> > >>> On 08.04.2015, at 18:03, Chris Muller wrote: > >>>> > >>>> The impetus for the change was so that (WeakArray new = Array new) > >>>> would return true instead of false. But we could accomplish that by > >>>> overriding #= instead of #species, I think.. > >>>> > >>>> Do you think overriding #species in WeakArray at this point in the > >>>> release process is too aggressive? > >>> > >>> Not sure. The #testNoObsoleteClasses test is still failing, even > though there were fewer obsolete classes when we fixed > WeakArray>>copyWith:. Would reverting #species help fix these for good? > >> > >> I am unsure. Is there a weak-ref-guru out there? > > > > It would help to know what still holds onto the obsolete classes. > Unfortunately, the test image does not get saved for a post-mortem. > > > > Let's see if Collections-bf.614 makes a difference ... > > Nope, no difference: > > > > ==================================================================================== > http://build.squeak.org/job/SqueakTrunk/1250/console > 2015-04-10T16:54:29.378+01:00: Collections (bf.614) > > Failed Tests.Release.ReleaseTest.testNoObsoleteClasses (from Tests) > > Failing for the past 620 builds (Since #631 ) > Took 92 ms. > Error Message > > AnObsoleteMCMockClassA, AnObsoleteMCMockASubclass, AnObsoleteMCMockClassB, > AnObsoleteMCMockClassD, AnObsoleteMCMockClassE, AnObsoleteMCMockClassF, > AnObsoleteMCMockClassG, AnObsoleteMCMockClassH, AnObsoleteMCMockClassI, > AnObsoleteClassVarScopeParent, AnObsoleteClassVarScopeChild, > AnObsoleteClassVarScopeGrandchild, AnObsoleteClassVarScopeParent, > AnObsoleteClassVarScopeChild, AnObsoleteClassVarScopeGrandchild, > AnObsoleteClassVarScopeParent, AnObsoleteClassVarScopeChild, > AnObsoleteClassVarScopeGrandchild, AnObsoleteClassVarScopeParent, > AnObsoleteClassVarScopeChild, AnObsoleteClassVarScopeGrandchild, > AnObsoleteClassVarScopeParent, AnObsoleteClassVarScopeChild, > AnObsoleteClassVarScopeGrandchild, AnObsoleteClassVarScopeParent, > AnObsoleteClassVarScopeChild, AnObsoleteClassVarScopeGrandchild, > AnObsoleteClassVarScopeParent, AnObsoleteClassVarScopeChild, > AnObsoleteClassVarScopeGrandchild, AnObsoleteClassVarScopeParent, > AnObsoleteClassVarScopeChild, AnObsoleteClassVarScopeGrandchild, > AnObsoleteClassVarScopeParent, AnObsoleteClassVarScopeChild, > AnObsoleteClassVarScopeGrandchild, AnObsoleteClassVarScopeParent, > AnObsoleteClassVarScopeChild and AnObsoleteClassVarScopeGrandchild are > obsolete > > Stacktrace > > ReleaseTest(TestCase)>>assert:description: > ReleaseTest>>testNoObsoleteClasses > ReleaseTest(TestCase)>>performTest > > ==================================================================================== > > > > - Bert - > > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150410/ab6cef10/attachment.htm From commits at source.squeak.org Fri Apr 10 15:26:17 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 10 15:26:17 2015 Subject: [squeak-dev] The Trunk: KernelTests-ul.290.mcz Message-ID: Levente Uzonyi uploaded a new version of KernelTests to project The Trunk: http://source.squeak.org/trunk/KernelTests-ul.290.mcz ==================== Summary ==================== Name: KernelTests-ul.290 Author: ul Time: 27 February 2015, 2:14:11.716 pm UUID: ae915aaa-41be-44dc-98d0-0363cfcd2c13 Ancestors: KernelTests-eem.289 Updated RandomTest to match the new implementation of Random. =============== Diff against KernelTests-eem.289 =============== Item was changed: ClassTestCase subclass: #RandomTest + instanceVariableNames: '' - instanceVariableNames: 'gen' classVariableNames: '' poolDictionaries: '' category: 'KernelTests-Numbers'! + + !RandomTest commentStamp: 'ul 2/27/2015 12:36' prior: 0! + I test the random number generator implemented by Random. Whenever its implementation changes, I'll have to be updated to match the new implementation. + Instead of adding methods to Random to access the internal state, I use reflection (#instVarNamed:).! Item was added: + ----- Method: RandomTest>>assertFirstValuesAre:finalStatesAre:withSeed: (in category 'helpers') ----- + assertFirstValuesAre: expectedValues finalStatesAre: expectedFinalStates withSeed: seed + "Verify that the first generated numbers with the given seed are the same as in expectedValues. Also check that the state of the generator matches expectedFinalStates after the last number was generated." + + | random states | + random := Random seed: seed. + expectedValues do: [ :each | + self assert: each equals: random nextValue ]. + states := random instVarNamed: #states. + self + assert: expectedFinalStates + equals: states. + self + assert: expectedValues size \\ states size + 1 + equals: (random instVarNamed: #index) + ! Item was added: + ----- Method: RandomTest>>assertInitialStateIs:withSeed: (in category 'helpers') ----- + assertInitialStateIs: expectedInitialState withSeed: seed + "Verify that the initial values of the states variable match the given values for the given seed." + + | random | + random := Random basicNew. + random initializeStatesWith: seed. + self + assert: expectedInitialState + equals: (random instVarNamed: #states)! Item was removed: - ----- Method: RandomTest>>setUp (in category 'setup') ----- - setUp - gen := Random seed: 112629.! Item was added: + ----- Method: RandomTest>>testExpectedValuesAndFinalStates (in category 'tests') ----- + testExpectedValuesAndFinalStates + "The numbers here were generated with a modified version of dcmt. http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/DC/dc.html ." + + self + assertFirstValuesAre: #(791793822 321208675 533452018 916714539 223319369 1012473888 519521402 691227136 655932023 762631845 263546831 924338090 559722895 178321509 916222900 335844726 321863848 695515717 112692096 738657692 395570358 340088260 887167633 1009518587 243735024 275847384 769544812 100974653 906270421 342913954 97518663 1067659127 901766500 960849649 913009938 458031838 820147509 822604220 642364166 55274442 357680755 991571674 13914935 857799117 66453038 971120160 398083276 373288317 684827868 674731247) + finalStatesAre: #(635250399 668117719 848992573 251038832 98606638 713392708 276649431 1832634 607491210 416789795 914892960 325580685 799306927 249385527 318375379 748373901 904063250 170318087) + withSeed: 1. + self + assertFirstValuesAre: #(687305094 702568716 681618148 361497334 56139518 745675778 952599938 953942824 73974730 564274490 1060767469 886737457 1039805902 722013528 64171798 764123925 432128359 274234212 668956319 716744939 309797615 780783289 301460951 535739904 224961890 114117836 193753287 1031006106 336541050 154594855 533038119 881775175 158057306 77776036 493306911 605604566 1048063493 584525301 1022642202 864508130 413151089 57876224 191759976 1008496211 868455235 165567279 536395892 455845625 913969488 1031304391) + finalStatesAre: #(1042729719 217432604 1069856876 162320335 202162581 218490242 297015026 68487684 898813855 71972347 874350418 438504195 940031925 17654607 153301097 316080480 107798001 361001990) + withSeed: 16rFFFFFFFF. + self + assertFirstValuesAre: #(508754231 328289850 498391260 573176063 453719461 935895611 435707860 570185280 1062441194 1069509491 70217464 149146838 858549983 755358687 617299553 468867114 401402744 731268746 224918805 447062722 290392391 137004397 311801760 320322691 258212560 536704035 950550708 555923010 982471103 981495169 294632011 175884018 503667308 154136572 291636083 607893878 617073742 310910219 169050729 996306290 695080363 165230559 945376911 612064901 884146961 873827275 491094423 292583589 257673098 606271793) + finalStatesAre: #(650871495 911703262 863344052 176605894 655312644 446078144 11879373 102580040 573515471 123917283 104253098 1042658978 222575135 487008331 309368251 253108077 333913878 249510222) + withSeed: 36rSqueak! Item was added: + ----- Method: RandomTest>>testInitialStates (in category 'tests') ----- + testInitialStates + "The numbers here were generated with a modified version of dcmt. http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/DC/dc.html ." + + self + assertInitialStateIs: #(1 738691430 491934885 961690497 64984499 171432612 446538473 482277108 305861910 321062125 1021787430 989754889 231135540 639897334 889001601 577497588 377121465 745575081) + withSeed: 1. + self + assertInitialStateIs: #(1073741823 266459757 720566430 20126452 56152695 937338158 159797905 1043117473 406704525 811309125 915542797 222137334 82370074 761921770 934153467 57368396 980436236 43660082) + withSeed: 16rFFFFFFFF. + self + assertInitialStateIs: #(664399324 1024531762 951500119 549828849 614037886 888424945 697907173 598650154 380912181 737669773 997432646 1017772356 307774789 986202438 417447953 558454367 229264988 682340290) + withSeed: 36rSqueak. + + ! Item was changed: ----- Method: RandomTest>>testNext (in category 'tests') ----- testNext + "Generate some float values, and see if they are in the [0,1) interval. Also check that the smallest and the largest values are small/large enough." + | random min max | + min := Float infinity. + max := Float negativeInfinity. + random := Random seed: 112629. + 100000 timesRepeat: [ + | next | + next := random next. + next < min ifTrue: [ min := next ]. + next > max ifTrue: [ max := next ]. + self assert: next >= 0.0 description: [ 'Generated value ', next asString, ' should be non-negative.' ]. + self assert: next < 1.0 description: [ 'Generated value ', next asString, ' should be less than 1.0.' ] ]. + self assert: max > 0.9999 description: 'The largest generated value should be greater than 0.9999.'. + self assert: min < 0.0001 description: 'The smallest generated value should be less than 0.0001.'! - 10000 timesRepeat: [ - | next | - next := gen next. - self assert: next >= 0.0. - self assert: next < 1.0 ].! Item was removed: - ----- Method: RandomTest>>testNextForEdgeCases (in category 'tests') ----- - testNextForEdgeCases - " Test #next for edge case input-output pairs " - - self assert: 0.0 equals: (Random seed: 1407677000) next. - self assert: (1 << 31 - 1) asFloat / (1 << 31) asFloat equals: (Random seed: 0) next! Item was added: + ----- Method: RandomTest>>testNextInt (in category 'tests') ----- + testNextInt + "Generate many integer values from a small range, and see if they are distributed equally on that range. This is not an exact test, but it's good enough to find obvious errors in the generator." + + | random | + random := Random seed: 1234567812345678. + #( + 2 100000 + 3 200000 + 10 300000 + 100 400000 + ) groupsDo: [ :bucketCount :runs | + | buckets | + buckets := Array new: bucketCount withAll: 0. + runs timesRepeat: [ + | next | + next := random nextInt: bucketCount. + buckets at: next put: (buckets at: next) + 1 ]. + buckets do: [ :each | + self assert: (each / (runs / bucketCount) between: 0.95 and: 1.05) ] ]! Item was added: + ----- Method: RandomTest>>testNextIntLarge (in category 'tests') ----- + testNextIntLarge + "Generate many 1281-bit integers and see if their bits are equally distributed. This is not an exact test, but it's good enough to find obvious errors in the generator." + + + | random bits bitCounts maxValue runs | + random := Random seed: 1234567812345678. + bits := 1281. + bitCounts := Array new: bits withAll: 0. + maxValue := 1 << bits. + runs := 20000. + runs timesRepeat: [ + | value | + value := (random nextInt: maxValue) - 1. + 1 to: bits do: [ :bitIndex | + bitCounts at: bitIndex put: (bitCounts at: bitIndex) + (value bitAt: bitIndex) ] ]. + bitCounts do: [ :each | + self assert: ((each / (runs / 2)) between: 0.95 and: 1.05) ] + ! Item was removed: - ----- Method: RandomTest>>testNextValueForEdgeCases (in category 'tests') ----- - testNextValueForEdgeCases - " Test #nextValue for edge case input-output pairs " - - self assert: 1.0 equals: (Random seed: 1407677000) nextValue. - self assert: (1 << 31 - 1) asFloat equals: (Random seed: 0) nextValue! Item was removed: - ----- Method: RandomTest>>testWellKnownSequence (in category 'tests') ----- - testWellKnownSequence - "This test assert the immutability of Random generation algorithm. - It uses Float equality tests, which is a very strict notion of immutability. - Anyone changing Random algorithm will have to adapt this test." - - | theSeedOfWellKnownSequence wellKnownSequence rng effectiveSequence | - theSeedOfWellKnownSequence := 2345678901. - wellKnownSequence := #(0.32506402597067136 0.3510923149767762 0.8085456405806102 0.22658906421930952 0.28241015983857687 0.46756423286514553 0.3520695904046621 0.23361375705972953 0.3464227287780599 0.32681039875690376). - rng := Random new. - rng seed: theSeedOfWellKnownSequence. - effectiveSequence := (1 to: 10) collect: [:i | rng next ]. - self assert: effectiveSequence equals: wellKnownSequence! From commits at source.squeak.org Fri Apr 10 15:30:00 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 10 15:30:02 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.856.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.856.mcz ==================== Summary ==================== Name: Morphic-mt.856 Author: mt Time: 10 April 2015, 5:29:28.492 pm UUID: 20dbd6ea-8701-fd4c-8c03-55c3e70edbda Ancestors: Morphic-mt.855 Added the possibility to indicate the current keyboard focus for *every* morph. It is a preference, which can be enabled but is disabled by default. Why needed? It may be hard to determine the current keyboard focus if #mouseOverForKeyboardFocus is disabled. Morphs can overwrite the default preference by either implementing #indicateKeyboardFocus or setting a property with that name to #never. (PluggableTextMorph does that for its text morph) This commit includes also some fixes for #keyboardFocusChange: were overwritten methods forgot to call super. =============== Diff against Morphic-mt.855 =============== Item was added: + ----- Method: MenuMorph>>drawKeyboardFocusIndicationOn: (in category 'drawing') ----- + drawKeyboardFocusIndicationOn: aCanvas + "Draw the menu. Add keyboard-focus feedback if appropriate" + + (self rootMenu hasProperty: #hasUsedKeyboard) + ifTrue: [ + aCanvas + frameRectangle: self innerBounds + width: Preferences menuBorderWidth + color: Preferences keyboardFocusColor].! Item was removed: - ----- Method: MenuMorph>>drawOn: (in category 'drawing') ----- - drawOn: aCanvas - "Draw the menu. Add keyboard-focus feedback if appropriate" - - super drawOn: aCanvas. - - (ActiveHand notNil - and: [ActiveHand keyboardFocus == self - and: [self rootMenu hasProperty: #hasUsedKeyboard]]) - ifTrue: [ - aCanvas - frameAndFillRectangle: self innerBounds - fillColor: Color transparent - borderWidth: Preferences menuBorderWidth - borderColor: Preferences keyboardFocusColor - ]. - ! Item was added: + ----- Method: MenuMorph>>indicateKeyboardFocus (in category 'testing') ----- + indicateKeyboardFocus + + ^ true! Item was removed: - ----- Method: MenuMorph>>keyboardFocusChange: (in category 'keyboard control') ----- - keyboardFocusChange: aBoolean - "Notify change due to green border for keyboard focus" - - self changed! Item was changed: Object subclass: #Morph instanceVariableNames: 'bounds owner submorphs fullBounds color extension' + classVariableNames: 'IndicateKeyboardFocus PreferredCornerRadius UseSoftDropShadow' - classVariableNames: 'PreferredCornerRadius UseSoftDropShadow' poolDictionaries: '' category: 'Morphic-Kernel'! !Morph commentStamp: 'efc 2/26/2003 20:01' prior: 0! A Morph (from the Greek "shape" or "form") is an interactive graphical object. General information on the Morphic system can be found at http://minnow.cc.gatech.edu/squeak/30. Morphs exist in a tree, rooted at a World (generally a PasteUpMorph). The morphs owned by a morph are its submorphs. Morphs are drawn recursively; if a Morph has no owner it never gets drawn. To hide a Morph and its submorphs, set its #visible property to false using the #visible: method. The World (screen) coordinate system is used for most coordinates, but can be changed if there is a TransformMorph somewhere in the owner chain. My instance variables have accessor methods (e.g., #bounds, #bounds:). Most users should use the accessor methods instead of using the instance variables directly. Structure: instance var Type Description bounds Rectangle A Rectangle indicating my position and a size that will enclose me. owner Morph My parent Morph, or nil for the top-level Morph, which is a or nil world, typically a PasteUpMorph. submorphs Array My child Morphs. fullBounds Rectangle A Rectangle minimally enclosing me and my submorphs. color Color My primary color. Subclasses can use this in different ways. extension MorphExtension Allows extra properties to be stored without adding a or nil storage burden to all morphs. By default, Morphs do not position their submorphs. Morphs may position their submorphs directly or use a LayoutPolicy to automatically control their submorph positioning. Although Morph has some support for BorderStyle, most users should use BorderedMorph if they want borders.! Item was added: + ----- Method: Morph class>>indicateKeyboardFocus (in category 'preferences') ----- + indicateKeyboardFocus + + + ^ IndicateKeyboardFocus ifNil: [false]! Item was added: + ----- Method: Morph class>>indicateKeyboardFocus: (in category 'preferences') ----- + indicateKeyboardFocus: aBoolean + + IndicateKeyboardFocus := aBoolean.! Item was added: + ----- Method: Morph>>drawKeyboardFocusIndicationOn: (in category 'drawing') ----- + drawKeyboardFocusIndicationOn: aCanvas + + self wantsRoundedCorners + ifTrue: [aCanvas frameRoundRect: self bounds radius: self class preferredCornerRadius width: 3 "self borderStyle width" color: self keyboardFocusColor] + ifFalse: [aCanvas frameRectangle: self bounds width: 3 "self borderStyle width" color: self keyboardFocusColor].! Item was changed: ----- Method: Morph>>drawOverlayOn: (in category 'drawing') ----- drawOverlayOn: aCanvas "Draw something over all my submorphs." self drawDropHighlightOn: aCanvas. + self drawMouseDownHighlightOn: aCanvas. + + (self indicateKeyboardFocus and: [self hasKeyboardFocus]) + ifTrue: [self drawKeyboardFocusIndicationOn: aCanvas].! - self drawMouseDownHighlightOn: aCanvas.! Item was changed: ----- Method: Morph>>hasKeyboardFocus: (in category 'event handling') ----- hasKeyboardFocus: aHand + ^ aHand keyboardFocus == self keyboardFocusDelegate! - ^ aHand keyboardFocus == self! Item was added: + ----- Method: Morph>>indicateKeyboardFocus (in category 'testing') ----- + indicateKeyboardFocus + + ^ (self hasProperty: #indicateKeyboardFocus) + ifTrue: [(self valueOfProperty: #indicateKeyboardFocus) ~~ #never] + ifFalse: [self class indicateKeyboardFocus]! Item was changed: ----- Method: Morph>>keyboardFocusChange: (in category 'event handling') ----- keyboardFocusChange: aBoolean + "The message is sent to a morph when its keyboard focus change. The given argument indicates that the receiver is gaining keyboard focus (versus losing) the keyboard focus. Morphs that accept keystrokes should change their appearance in some way when they are the current keyboard focus. This default implementation does nothing." + + self indicateKeyboardFocus ifTrue: [self changed].! - "The message is sent to a morph when its keyboard focus change. The given argument indicates that the receiver is gaining keyboard focus (versus losing) the keyboard focus. Morphs that accept keystrokes should change their appearance in some way when they are the current keyboard focus. This default implementation does nothing."! Item was added: + ----- Method: Morph>>keyboardFocusColor (in category 'drawing') ----- + keyboardFocusColor + + ^ Preferences keyboardFocusColor muchDarker alpha: 0.5! Item was changed: ----- Method: PluggableListMorph>>keyboardFocusChange: (in category 'event handling') ----- keyboardFocusChange: aBoolean "The message is sent to a morph when its keyboard focus changes. The given argument indicates that the receiver is gaining (versus losing) the keyboard focus. In this case, all we need to do is to redraw border feedback" aBoolean ifFalse: [ self hoverRow: nil. self class clearFilterAutomatically ifTrue: [ self hasFilter ifTrue: [ self removeFilter ; updateList ] ] ]. + + super keyboardFocusChange: aBoolean.! - (self innerBounds areasOutside: (self innerBounds insetBy: 1)) do: - [ : rect | self invalidRect: rect ]! Item was changed: ----- Method: PluggableTextMorph>>setText: (in category 'model access') ----- setText: aText textMorph ifNil: [textMorph := self textMorphClass new contents: aText wrappedTo: self innerBounds width. textMorph margins: (3@0 corner: 0@0); + setEditView: self; + setProperty: #indicateKeyboardFocus toValue: #never. - setEditView: self. scroller addMorph: textMorph] ifNotNil: [textMorph newContents: aText]. self hasUnacceptedEdits: false. self setScrollDeltas.! Item was changed: ----- Method: TextMorphForEditView>>keyboardFocusChange: (in category 'event handling') ----- keyboardFocusChange: aBoolean "rr 3/21/2004 22:55 : removed the #ifFalse: branch, which was responsible of the deselection of text when the paragraph lost focus. This way selection works in a more standard way, and this permits the menu keyboard control to be really effective" paragraph isNil ifFalse:[paragraph focused: aBoolean]. + aBoolean + ifTrue: [ + "A hand is wanting to send us characters..." + self hasFocus ifFalse: [self editor "Forces install"]. + Editor blinkingCursor ifTrue: [self startBlinking]] + ifFalse:[ + self stopBlinking]. - aBoolean ifTrue:["A hand is wanting to send us characters..." - self hasFocus ifFalse: [self editor "Forces install"]. - Editor blinkingCursor ifTrue: [self startBlinking]. - ] ifFalse:[ - self stopBlinking. - ]. self changed. + + "Tell my edit-view about this because I am his delegate." + self editView keyboardFocusChange: aBoolean. ! Item was changed: (PackageInfo named: 'Morphic') postscript: '"Update existing scrollbars." ScrollBar allSubInstances do: [:sb | sb removeAllMorphs; initializeSlider]. ScrollPane allSubInstances do: [:sc | sc vScrollBar setValueSelector: #vScrollBarValue:; menuSelector: #vScrollBarMenuButtonPressed:. sc hScrollBar setValueSelector: #hScrollBarValue:; menuSelector: #hScrollBarMenuButtonPressed:. sc vSetScrollDelta; hSetScrollDelta]. (Preferences dictionaryOfPreferences at: #alternativeWindowBoxesLook) defaultValue: false. "Force SystemProgressMorph to be reset" SystemProgressMorph initialize; reset. "Initialize the key bindings and menus" Editor initialize. "Retain scrollBar look now that the pref actually does something" Preferences enable: #gradientScrollBars. "apply the new icons" MenuIcons initializeIcons. TheWorldMainDockingBar updateInstances. "Cleanup old-style preferences here. Remove before new release." Preferences removePreference: #gradientMenu. "Now in MenuMorph." Preferences removePreference: #roundedMenuCorners. "Now in MenuMorph." "Fix clipping bug of open windows. New ones are not affected." TransformMorph allInstances do: [:ea | ea clipSubmorphs: true]. "Now in ScrollBar." + Preferences removePreference: #scrollBarsWithoutMenuButton. + + "Keyboard focus indication." + PluggableTextMorph allSubInstances do: [:m | + m textMorph setProperty: #indicateKeyboardFocus toValue: #never].'! - Preferences removePreference: #scrollBarsWithoutMenuButton. '! From commits at source.squeak.org Fri Apr 10 15:38:47 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 10 15:38:48 2015 Subject: [squeak-dev] The Trunk: KernelTests-ul.291.mcz Message-ID: Levente Uzonyi uploaded a new version of KernelTests to project The Trunk: http://source.squeak.org/trunk/KernelTests-ul.291.mcz ==================== Summary ==================== Name: KernelTests-ul.291 Author: ul Time: 10 April 2015, 5:25:21.689 pm UUID: b331a163-0e46-4df8-9d83-0252df5dff33 Ancestors: KernelTests-ul.290 Don't keep any references to classes created in ClassVarScopeTest. =============== Diff against KernelTests-ul.290 =============== Item was changed: ----- Method: ClassVarScopeTest>>tearDown (in category 'command') ----- tearDown + + | classes | + classes := { grandchild. child. parent }. + grandchild := child := parent := nil. + classes do: [ :each | + each + removeFromChanges; + removeFromSystemUnlogged ]. - grandchild removeFromChanges; removeFromSystemUnlogged . - child removeFromChanges; removeFromSystemUnlogged . - parent removeFromChanges; removeFromSystemUnlogged . Smalltalk globals removeKey: #ClassVarScopeFoo! From leves at elte.hu Fri Apr 10 15:39:37 2015 From: leves at elte.hu (Levente Uzonyi) Date: Fri Apr 10 15:39:42 2015 Subject: [squeak-dev] The Trunk: KernelTests-ul.290.mcz In-Reply-To: References: Message-ID: Another accidental commit, but this time it doesn't cause any trouble. Sorry for the noise. Levente On Fri, 10 Apr 2015, commits@source.squeak.org wrote: > Levente Uzonyi uploaded a new version of KernelTests to project The Trunk: > http://source.squeak.org/trunk/KernelTests-ul.290.mcz > > ==================== Summary ==================== > > Name: KernelTests-ul.290 > Author: ul > Time: 27 February 2015, 2:14:11.716 pm > UUID: ae915aaa-41be-44dc-98d0-0363cfcd2c13 > Ancestors: KernelTests-eem.289 > > Updated RandomTest to match the new implementation of Random. > > =============== Diff against KernelTests-eem.289 =============== > > Item was changed: > ClassTestCase subclass: #RandomTest > + instanceVariableNames: '' > - instanceVariableNames: 'gen' > classVariableNames: '' > poolDictionaries: '' > category: 'KernelTests-Numbers'! > + > + !RandomTest commentStamp: 'ul 2/27/2015 12:36' prior: 0! > + I test the random number generator implemented by Random. Whenever its implementation changes, I'll have to be updated to match the new implementation. > + Instead of adding methods to Random to access the internal state, I use reflection (#instVarNamed:).! > > Item was added: > + ----- Method: RandomTest>>assertFirstValuesAre:finalStatesAre:withSeed: (in category 'helpers') ----- > + assertFirstValuesAre: expectedValues finalStatesAre: expectedFinalStates withSeed: seed > + "Verify that the first generated numbers with the given seed are the same as in expectedValues. Also check that the state of the generator matches expectedFinalStates after the last number was generated." > + > + | random states | > + random := Random seed: seed. > + expectedValues do: [ :each | > + self assert: each equals: random nextValue ]. > + states := random instVarNamed: #states. > + self > + assert: expectedFinalStates > + equals: states. > + self > + assert: expectedValues size \\ states size + 1 > + equals: (random instVarNamed: #index) > + ! > > Item was added: > + ----- Method: RandomTest>>assertInitialStateIs:withSeed: (in category 'helpers') ----- > + assertInitialStateIs: expectedInitialState withSeed: seed > + "Verify that the initial values of the states variable match the given values for the given seed." > + > + | random | > + random := Random basicNew. > + random initializeStatesWith: seed. > + self > + assert: expectedInitialState > + equals: (random instVarNamed: #states)! > > Item was removed: > - ----- Method: RandomTest>>setUp (in category 'setup') ----- > - setUp > - gen := Random seed: 112629.! > > Item was added: > + ----- Method: RandomTest>>testExpectedValuesAndFinalStates (in category 'tests') ----- > + testExpectedValuesAndFinalStates > + "The numbers here were generated with a modified version of dcmt. http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/DC/dc.html ." > + > + self > + assertFirstValuesAre: #(791793822 321208675 533452018 916714539 223319369 1012473888 519521402 691227136 655932023 762631845 263546831 924338090 559722895 178321509 916222900 335844726 321863848 695515717 112692096 738657692 395570358 340088260 887167633 1009518587 243735024 275847384 769544812 100974653 906270421 342913954 97518663 1067659127 901766500 960849649 913009938 458031838 820147509 822604220 642364166 55274442 357680755 991571674 13914935 857799117 66453038 971120160 398083276 373288317 684827868 674731247) > + finalStatesAre: #(635250399 668117719 848992573 251038832 98606638 713392708 276649431 1832634 607491210 416789795 914892960 325580685 799306927 249385527 318375379 748373901 904063250 170318087) > + withSeed: 1. > + self > + assertFirstValuesAre: #(687305094 702568716 681618148 361497334 56139518 745675778 952599938 953942824 73974730 564274490 1060767469 886737457 1039805902 722013528 64171798 764123925 432128359 274234212 668956319 716744939 309797615 780783289 301460951 535739904 224961890 114117836 193753287 1031006106 336541050 154594855 533038119 881775175 158057306 77776036 493306911 605604566 1048063493 584525301 1022642202 864508130 413151089 57876224 191759976 1008496211 868455235 165567279 536395892 455845625 913969488 1031304391) > + finalStatesAre: #(1042729719 217432604 1069856876 162320335 202162581 218490242 297015026 68487684 898813855 71972347 874350418 438504195 940031925 17654607 153301097 316080480 107798001 361001990) > + withSeed: 16rFFFFFFFF. > + self > + assertFirstValuesAre: #(508754231 328289850 498391260 573176063 453719461 935895611 435707860 570185280 1062441194 1069509491 70217464 149146838 858549983 755358687 617299553 468867114 401402744 731268746 224918805 447062722 290392391 137004397 311801760 320322691 258212560 536704035 950550708 555923010 982471103 981495169 294632011 175884018 503667308 154136572 291636083 607893878 617073742 310910219 169050729 996306290 695080363 165230559 945376911 612064901 884146961 873827275 491094423 292583589 257673098 606271793) > + finalStatesAre: #(650871495 911703262 863344052 176605894 655312644 446078144 11879373 102580040 573515471 123917283 104253098 1042658978 222575135 487008331 309368251 253108077 333913878 249510222) > + withSeed: 36rSqueak! > > Item was added: > + ----- Method: RandomTest>>testInitialStates (in category 'tests') ----- > + testInitialStates > + "The numbers here were generated with a modified version of dcmt. http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/DC/dc.html ." > + > + self > + assertInitialStateIs: #(1 738691430 491934885 961690497 64984499 171432612 446538473 482277108 305861910 321062125 1021787430 989754889 231135540 639897334 889001601 577497588 377121465 745575081) > + withSeed: 1. > + self > + assertInitialStateIs: #(1073741823 266459757 720566430 20126452 56152695 937338158 159797905 1043117473 406704525 811309125 915542797 222137334 82370074 761921770 934153467 57368396 980436236 43660082) > + withSeed: 16rFFFFFFFF. > + self > + assertInitialStateIs: #(664399324 1024531762 951500119 549828849 614037886 888424945 697907173 598650154 380912181 737669773 997432646 1017772356 307774789 986202438 417447953 558454367 229264988 682340290) > + withSeed: 36rSqueak. > + > + ! > > Item was changed: > ----- Method: RandomTest>>testNext (in category 'tests') ----- > testNext > + "Generate some float values, and see if they are in the [0,1) interval. Also check that the smallest and the largest values are small/large enough." > > + | random min max | > + min := Float infinity. > + max := Float negativeInfinity. > + random := Random seed: 112629. > + 100000 timesRepeat: [ > + | next | > + next := random next. > + next < min ifTrue: [ min := next ]. > + next > max ifTrue: [ max := next ]. > + self assert: next >= 0.0 description: [ 'Generated value ', next asString, ' should be non-negative.' ]. > + self assert: next < 1.0 description: [ 'Generated value ', next asString, ' should be less than 1.0.' ] ]. > + self assert: max > 0.9999 description: 'The largest generated value should be greater than 0.9999.'. > + self assert: min < 0.0001 description: 'The smallest generated value should be less than 0.0001.'! > - 10000 timesRepeat: [ > - | next | > - next := gen next. > - self assert: next >= 0.0. > - self assert: next < 1.0 ].! > > Item was removed: > - ----- Method: RandomTest>>testNextForEdgeCases (in category 'tests') ----- > - testNextForEdgeCases > - " Test #next for edge case input-output pairs " > - > - self assert: 0.0 equals: (Random seed: 1407677000) next. > - self assert: (1 << 31 - 1) asFloat / (1 << 31) asFloat equals: (Random seed: 0) next! > > Item was added: > + ----- Method: RandomTest>>testNextInt (in category 'tests') ----- > + testNextInt > + "Generate many integer values from a small range, and see if they are distributed equally on that range. This is not an exact test, but it's good enough to find obvious errors in the generator." > + > + | random | > + random := Random seed: 1234567812345678. > + #( > + 2 100000 > + 3 200000 > + 10 300000 > + 100 400000 > + ) groupsDo: [ :bucketCount :runs | > + | buckets | > + buckets := Array new: bucketCount withAll: 0. > + runs timesRepeat: [ > + | next | > + next := random nextInt: bucketCount. > + buckets at: next put: (buckets at: next) + 1 ]. > + buckets do: [ :each | > + self assert: (each / (runs / bucketCount) between: 0.95 and: 1.05) ] ]! > > Item was added: > + ----- Method: RandomTest>>testNextIntLarge (in category 'tests') ----- > + testNextIntLarge > + "Generate many 1281-bit integers and see if their bits are equally distributed. This is not an exact test, but it's good enough to find obvious errors in the generator." > + > + > + | random bits bitCounts maxValue runs | > + random := Random seed: 1234567812345678. > + bits := 1281. > + bitCounts := Array new: bits withAll: 0. > + maxValue := 1 << bits. > + runs := 20000. > + runs timesRepeat: [ > + | value | > + value := (random nextInt: maxValue) - 1. > + 1 to: bits do: [ :bitIndex | > + bitCounts at: bitIndex put: (bitCounts at: bitIndex) + (value bitAt: bitIndex) ] ]. > + bitCounts do: [ :each | > + self assert: ((each / (runs / 2)) between: 0.95 and: 1.05) ] > + ! > > Item was removed: > - ----- Method: RandomTest>>testNextValueForEdgeCases (in category 'tests') ----- > - testNextValueForEdgeCases > - " Test #nextValue for edge case input-output pairs " > - > - self assert: 1.0 equals: (Random seed: 1407677000) nextValue. > - self assert: (1 << 31 - 1) asFloat equals: (Random seed: 0) nextValue! > > Item was removed: > - ----- Method: RandomTest>>testWellKnownSequence (in category 'tests') ----- > - testWellKnownSequence > - "This test assert the immutability of Random generation algorithm. > - It uses Float equality tests, which is a very strict notion of immutability. > - Anyone changing Random algorithm will have to adapt this test." > - > - | theSeedOfWellKnownSequence wellKnownSequence rng effectiveSequence | > - theSeedOfWellKnownSequence := 2345678901. > - wellKnownSequence := #(0.32506402597067136 0.3510923149767762 0.8085456405806102 0.22658906421930952 0.28241015983857687 0.46756423286514553 0.3520695904046621 0.23361375705972953 0.3464227287780599 0.32681039875690376). > - rng := Random new. > - rng seed: theSeedOfWellKnownSequence. > - effectiveSequence := (1 to: 10) collect: [:i | rng next ]. > - self assert: effectiveSequence equals: wellKnownSequence! > > > From marcel.taeumel at student.hpi.uni-potsdam.de Fri Apr 10 15:29:14 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Fri Apr 10 15:42:02 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.849.mcz In-Reply-To: References: Message-ID: <1428679754934-4818928.post@n4.nabble.com> Hi Karl, I am not sure whether I understand it correctly. At the moment, you have to following possibilities: 1) Keyboard focus "on click" (i.e. mouseUp or mouseDown depending on the morph) -> Using the mouse via the scroll bars *does not* change the current focus. 2) Keyboard focus on "mouse over" (i.e. mouseEnter receive and mouseLeave for release) -> Using the mouse via the scroll bars preceeds a mouseEnter event and thus changes the keyboard focus. *** However, using the mouse-wheel needs keyboard focus because that's the way the VMs gives use those events. Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-849-mcz-tp4818555p4818928.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From bert at freudenbergs.de Fri Apr 10 15:43:32 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Fri Apr 10 15:43:34 2015 Subject: [squeak-dev] WeakArray species (was The Trunk: Collections-bf.612.mcz) In-Reply-To: References: <5523c7d5.162b370a.573d.5b8aSMTPIN_ADDED_MISSING@mx.google.com> <96F864DC-C66C-4A60-BED2-68E43988EF31@freudenbergs.de> <65D869D1-C084-45DF-94A8-DF1194F5A01D@freudenbergs.de> <4E426EC9-9F4C-47D6-838F-79E5B19476D7@freudenbergs.de> <78419670-7622-46E1-8C06-138F03E19E85@freudenbergs.de> Message-ID: Skipped content of type multipart/alternative-------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150410/68b1dbf4/smime-0001.bin From marcel.taeumel at student.hpi.uni-potsdam.de Fri Apr 10 15:33:38 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Fri Apr 10 15:46:22 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.856.mcz In-Reply-To: References: Message-ID: <1428680018246-4818930.post@n4.nabble.com> This is how it looks like: It's color is based on the one that is used in MenuMorphs when typing. (see Morph >> #keyboardFocusColor) Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-856-mcz-tp4818923p4818930.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Fri Apr 10 15:47:15 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 10 15:47:17 2015 Subject: [squeak-dev] The Trunk: Collections-bf.615.mcz Message-ID: Bert Freudenberg uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections-bf.615.mcz ==================== Summary ==================== Name: Collections-bf.615 Author: bf Time: 10 April 2015, 5:46:52.241 pm UUID: 081c8444-1766-451d-baa2-311e9f0d9374 Ancestors: Collections-bf.614 Restore WeakArray>>species. It's apparently not the culprit for the obsolete class refs. =============== Diff against Collections-bf.614 =============== Item was changed: ----- Method: WeakArray>>species (in category 'private') ----- species "More useful to have strongly-referenced results of #select: and #collect:." + ^ Array! - ^super species "disabled temporarily to see if this fixes testNoObsoleteClasses on the build server" - "^ Array"! From leves at elte.hu Fri Apr 10 15:47:25 2015 From: leves at elte.hu (Levente Uzonyi) Date: Fri Apr 10 15:47:31 2015 Subject: [squeak-dev] WeakArray species (was The Trunk: Collections-bf.612.mcz) In-Reply-To: References: <5523c7d5.162b370a.573d.5b8aSMTPIN_ADDED_MISSING@mx.google.com> <96F864DC-C66C-4A60-BED2-68E43988EF31@freudenbergs.de> <65D869D1-C084-45DF-94A8-DF1194F5A01D@freudenbergs.de> <4E426EC9-9F4C-47D6-838F-79E5B19476D7@freudenbergs.de> <78419670-7622-46E1-8C06-138F03E19E85@freudenbergs.de> Message-ID: On Fri, 10 Apr 2015, Bert Freudenberg wrote: > > On 10.04.2015, at 17:21, Nicolas Cellier wrote: > > This sounds like scories left by another TestCase? > > > Yep. > > So natural questions arising are > - doesn't it depend on the ordering of test cases? > > > It should. > > - How are TestCase ordered exactly? > > > I though TestRunner randomized the execution order. > Good News is that I can reproduce (part of) the problem simply by running all tests even on my Mac. After that I inspect "SystemNavigation default obsoleteClasses? and get some. Here?s what PointerFinder tells me holds onto them: IIRC the tests are run one by one on the build server, not from the TestRunner. > > > globals: Environment > declarations: IdentityDictionary > #World -> PasteUpMorph > submorphs: Array > 7: PluggableSystemWindow (1734) > model: TestRunner > result: TestResult > passed: OrderedCollection > array: Array > 550: ClassVarScopeTest > parent: AnObsoleteClassVarScopeParent class > > Apparently, that test modifies its own parent class?! I doubt it. It creates three classes. But that problem should be gone by now. The TestCase instance held references to the created classes. Levente > > I did not see the obsolete MCMock* classes on the Mac, though. > > - Bert - > > > From commits at source.squeak.org Fri Apr 10 15:59:24 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 10 15:59:25 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.857.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.857.mcz ==================== Summary ==================== Name: Morphic-mt.857 Author: mt Time: 10 April 2015, 5:58:47.128 pm UUID: c2d644ed-3407-5447-b7bb-fa65d4eaaf01 Ancestors: Morphic-mt.856 Some cosmetic changes: do not darken the paneColor in scroll bars', scroll panes', and system windows' so much. Note: This is a reaction to some feedback to make the non-gradient look more friendlier. =============== Diff against Morphic-mt.856 =============== Item was changed: ----- Method: ScrollBar>>updateSliderColor: (in category 'access') ----- updateSliderColor: aColor | gradient | Preferences gradientScrollBars ifFalse: [ slider + borderColor: (aColor adjustBrightness: -0.3); - borderColor: aColor muchDarker; color: aColor. pagingArea borderColor: (aColor muchDarker alpha: pagingArea borderStyle color alpha); + color: (aColor darker alpha: 0.35). - color: (aColor darker alpha: 0.45). ^ self]. slider borderStyle: (BorderStyle width: 1 color: Color lightGray). "Fill the slider." gradient := GradientFillStyle ramp: { 0 -> (Color gray: 0.95). 0.49 -> (Color gray: 0.9). 0.5 -> (Color gray: 0.87). 1 -> (Color gray: 0.93). }. gradient origin: slider topLeft. gradient direction: (self bounds isWide ifTrue:[0@slider height] ifFalse:[slider width@0]). slider fillStyle: gradient. "Fill the paging area." gradient := GradientFillStyle ramp: { 0 -> (Color gray: 0.65). 0.6 -> (Color gray: 0.82). 1 -> (Color gray: 0.88). }. gradient origin: self topLeft. gradient direction: (self bounds isWide ifTrue:[0@self height] ifFalse:[self width@0]). pagingArea fillStyle: gradient.! Item was changed: ----- Method: ScrollPane>>adoptPaneColor: (in category 'access') ----- adoptPaneColor: paneColor super adoptPaneColor: paneColor. "May not be in the hierarchy at the moment." scrollBar adoptPaneColor: paneColor. hScrollBar adoptPaneColor: paneColor. + paneColor ifNotNil: [:c | self borderColor: (c adjustBrightness: -0.3)].! - paneColor ifNotNil: [:c | self borderColor: c muchDarker].! Item was changed: ----- Method: SystemWindow>>setStripeColorsFrom: (in category 'colors handling') ----- setStripeColorsFrom: paneColor "Set the stripe color based on the given paneColor" labelArea ifNotNil: [labelArea color: Color transparent]. self updateBoxesColor: paneColor. stripes ifNil: [^self]. + self borderColor: (paneColor adjustBrightness: -0.3). - self borderColor: paneColor muchDarker. self class gradientWindow ifTrue: [self fillStyle: (self gradientWithColor: paneColor)] ifFalse: [self color: paneColor].! From karlramberg at gmail.com Fri Apr 10 16:18:53 2015 From: karlramberg at gmail.com (karl ramberg) Date: Fri Apr 10 16:18:55 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.849.mcz In-Reply-To: <1428679754934-4818928.post@n4.nabble.com> References: <1428679754934-4818928.post@n4.nabble.com> Message-ID: Sorry, I'm going full retard here. Just ignore my previous mail. Karl On Fri, Apr 10, 2015 at 5:29 PM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > Hi Karl, > > I am not sure whether I understand it correctly. At the moment, you have to > following possibilities: > > 1) Keyboard focus "on click" (i.e. mouseUp or mouseDown depending on the > morph) > -> Using the mouse via the scroll bars *does not* change the current focus. > > 2) Keyboard focus on "mouse over" (i.e. mouseEnter receive and mouseLeave > for release) > -> Using the mouse via the scroll bars preceeds a mouseEnter event and thus > changes the keyboard focus. > > > *** > > However, using the mouse-wheel needs keyboard focus because that's the way > the VMs gives use those events. > > Best, > Marcel > > > > -- > View this message in context: > http://forum.world.st/The-Trunk-Morphic-mt-849-mcz-tp4818555p4818928.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150410/e7881e27/attachment.htm From tim at rowledge.org Fri Apr 10 17:36:31 2015 From: tim at rowledge.org (tim Rowledge) Date: Fri Apr 10 17:36:41 2015 Subject: [squeak-dev] Reminder: Camp Smalltalk in Nanaimo BC, 25-6 April Message-ID: <4B7E4C91-A7FD-4CC6-AF48-B7A2EA4420A6@rowledge.org> Just a reminder to everyone that we?re having another Camp at Makerspace Nanaimo at the end of this month. The last one went really well and has inspired the Portland local Smalltalkers to plan an event for the fall; so we?re having a little relaxed get-together this time. http://wiki.squeak.org/squeak/532 tim -- tim Rowledge; tim@rowledge.org; http://www.rowledge.org/tim Strange OpCodes: ESC: Emulate Small Child From commits at source.squeak.org Fri Apr 10 21:07:05 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 10 21:07:06 2015 Subject: [squeak-dev] Squeak 4.5: Kernel-cwp.844.mcz Message-ID: Tobias Pape uploaded a new version of Kernel to project Squeak 4.5: http://source.squeak.org/squeak45/Kernel-cwp.844.mcz ==================== Summary ==================== Name: Kernel-cwp.844 Author: cwp Time: 22 March 2014, 7:57:39.797 pm UUID: f4f1b55b-db99-4fae-9a9b-3fcdcc0a6716 Ancestors: Kernel-cwp.840, Kernel-nice.843 merge =============== Diff against Kernel-dtl.836 =============== Item was changed: ----- Method: ClassBuilder>>superclass:subclass:instanceVariableNames:classVariableNames:poolDictionaries:category: (in category 'public') ----- superclass: newSuper subclass: t instanceVariableNames: f classVariableNames: d poolDictionaries: s category: cat "This is the standard initialization message for creating a new class as a subclass of an existing class." | env | + env := CurrentEnvironment signal ifNil: [newSuper environment]. - env := EnvironmentRequest signal ifNil: [newSuper environment]. ^self name: t inEnvironment: env subclassOf: newSuper type: newSuper typeOfClass instanceVariableNames: f classVariableNames: d poolDictionaries: s category: cat! Item was changed: ----- Method: ClassBuilder>>superclass:variableByteSubclass:instanceVariableNames:classVariableNames:poolDictionaries:category: (in category 'public') ----- superclass: aClass variableByteSubclass: t instanceVariableNames: f classVariableNames: d poolDictionaries: s category: cat "This is the standard initialization message for creating a new class as a subclass of an existing class in which the subclass is to have indexable byte-sized nonpointer variables." | oldClassOrNil actualType env | (aClass instSize > 0) ifTrue: [^self error: 'cannot make a byte subclass of a class with named fields']. (aClass isVariable and: [aClass isWords]) ifTrue: [^self error: 'cannot make a byte subclass of a class with word fields']. (aClass isVariable and: [aClass isPointers]) ifTrue: [^self error: 'cannot make a byte subclass of a class with pointer fields']. oldClassOrNil := aClass environment at: t ifAbsent:[nil]. actualType := (oldClassOrNil notNil and: [oldClassOrNil typeOfClass == #compiledMethod]) ifTrue: [#compiledMethod] ifFalse: [#bytes]. + env := CurrentEnvironment signal ifNil: [aClass environment]. - env := EnvironmentRequest signal ifNil: [aClass environment]. ^self name: t inEnvironment: env subclassOf: aClass type: actualType instanceVariableNames: f classVariableNames: d poolDictionaries: s category: cat! Item was changed: ----- Method: ClassBuilder>>superclass:variableSubclass:instanceVariableNames:classVariableNames:poolDictionaries:category: (in category 'public') ----- superclass: aClass variableSubclass: t instanceVariableNames: f classVariableNames: d poolDictionaries: s category: cat "This is the standard initialization message for creating a new class as a subclass of an existing class in which the subclass is to have indexable pointer variables." | env | aClass isBits ifTrue: [^self error: 'cannot make a pointer subclass of a class with non-pointer fields']. + env := CurrentEnvironment signal ifNil: [aClass environment]. - env := EnvironmentRequest signal ifNil: [aClass environment]. ^self name: t inEnvironment: env subclassOf: aClass type: #variable instanceVariableNames: f classVariableNames: d poolDictionaries: s category: cat! Item was changed: ----- Method: ClassBuilder>>superclass:variableWordSubclass:instanceVariableNames:classVariableNames:poolDictionaries:category: (in category 'public') ----- superclass: aClass variableWordSubclass: t instanceVariableNames: f classVariableNames: d poolDictionaries: s category: cat "This is the standard initialization message for creating a new class as a subclass of an existing class in which the subclass is to have indexable word-sized nonpointer variables." | env | (aClass instSize > 0) ifTrue: [^self error: 'cannot make a word subclass of a class with named fields']. (aClass isVariable and: [aClass isBytes]) ifTrue: [^self error: 'cannot make a word subclass of a class with byte fields']. (aClass isVariable and: [aClass isPointers]) ifTrue: [^self error: 'cannot make a word subclass of a class with pointer fields']. + env := CurrentEnvironment signal ifNil: [aClass environment]. - env := EnvironmentRequest signal ifNil: [aClass environment]. ^self name: t inEnvironment: env subclassOf: aClass type: #words instanceVariableNames: f classVariableNames: d poolDictionaries: s category: cat! Item was changed: ----- Method: ClassBuilder>>superclass:weakSubclass:instanceVariableNames:classVariableNames:poolDictionaries:category: (in category 'public') ----- superclass: aClass weakSubclass: t instanceVariableNames: f classVariableNames: d poolDictionaries: s category: cat "This is the standard initialization message for creating a new class as a subclass of an existing class (the receiver) in which the subclass is to have weak indexable pointer variables." | env | aClass isBits ifTrue: [^self error: 'cannot make a pointer subclass of a class with non-pointer fields']. + env := CurrentEnvironment signal ifNil: [aClass environment]. - env := EnvironmentRequest signal ifNil: [aClass environment]. ^self name: t inEnvironment: env subclassOf: aClass type: #weak instanceVariableNames: f classVariableNames: d poolDictionaries: s category: cat! Item was added: + ----- Method: ExtendedNumberParser>>exponentLetters (in category 'accessing') ----- + exponentLetters + "Allow uppercase exponent letter." + + ^'edqEDQ'! Item was changed: ----- Method: Float>>absPrintOn:base:digitCount: (in category 'printing') ----- absPrintOn: aStream base: base digitCount: digitCount "Print me in the given base, using digitCount significant figures." | fuzz x exp q fBase scale logScale xi | self isInfinite ifTrue: [^ aStream nextPutAll: 'Inf']. fBase := base asFloat. "x is myself normalized to [1.0, fBase), exp is my exponent" + exp := self floorLog: fBase. - exp := - self < 1.0 - ifTrue: [self reciprocalFloorLog: fBase] - ifFalse: [self floorLog: fBase]. scale := 1.0. logScale := 0. [(x := fBase raisedTo: (exp + logScale)) = 0] whileTrue: [scale := scale * fBase. logScale := logScale + 1]. x := self * scale / x. fuzz := fBase raisedTo: 1 - digitCount. "round the last digit to be printed" x := 0.5 * fuzz + x. x >= fBase ifTrue: ["check if rounding has unnormalized x" x := x / fBase. exp := exp + 1]. (exp < 6 and: [exp > -4]) ifTrue: ["decimal notation" q := 0. exp < 0 ifTrue: [1 to: 1 - exp do: [:i | aStream nextPut: ('0.0000' at: i)]]] ifFalse: ["scientific notation" q := exp. exp := 0]. [x >= fuzz] whileTrue: ["use fuzz to track significance" xi := x asInteger. aStream nextPut: (Character digitValue: xi). x := x - xi asFloat * fBase. fuzz := fuzz * fBase. exp := exp - 1. exp = -1 ifTrue: [aStream nextPut: $.]]. [exp >= -1] whileTrue: [aStream nextPut: $0. exp := exp - 1. exp = -1 ifTrue: [aStream nextPut: $.]]. q ~= 0 ifTrue: [aStream nextPut: $e. q printOn: aStream]! Item was changed: ----- Method: Float>>predecessor (in category 'truncation and round off') ----- predecessor | ulp | self isFinite ifFalse: [ (self isNaN or: [self negative]) ifTrue: [^self]. ^Float fmax]. - self = 0.0 ifTrue: [^Float fmin negated]. ulp := self ulp. ^self - (0.5 * ulp) = self ifTrue: [self - ulp] ifFalse: [self - (0.5 * ulp)]! Item was changed: ----- Method: Float>>successor (in category 'truncation and round off') ----- successor | ulp | self isFinite ifFalse: [ (self isNaN or: [self positive]) ifTrue: [^self]. ^Float fmax negated]. - self = 0.0 ifTrue: [^Float fmin]. ulp := self ulp. ^self + (0.5 * ulp) = self + ifTrue: [self * -1.0 - ulp * -1.0 "This trick is for obtaining a negativeZero"] - ifTrue: [self + ulp] ifFalse: [self + (0.5 * ulp)]! Item was changed: ----- Method: Integer>>nthRoot: (in category 'mathematical functions') ----- nthRoot: aPositiveInteger "Answer the nth root of the receiver. + Answer an Integer if root is exactly this Integer, else answer the Float nearest the exact root." - See #nthRootAlt: for an alternative implementation." + | guess p | - | selfAsFloat floatResult guess delta higher lower raised | - selfAsFloat := self asFloat. + guess := self nthRootRounded: aPositiveInteger. + (guess raisedTo: aPositiveInteger) = self - "If we can't do Float arithmetic because we are too big, then look for an exact answer in exact arithmetic" - selfAsFloat isInfinite ifTrue: [ - guess := self nthRootTruncated: aPositiveInteger. - (guess raisedToInteger: aPositiveInteger) = self - ifTrue: [ ^ guess ]. - "Nothing else can be done. No exact answer means answer must be a Float. - Answer the best we have." - ^guess asFloat ]. - - floatResult := selfAsFloat nthRoot: aPositiveInteger. - guess := floatResult rounded. - - "If got an exact answer, answer it." - raised := guess raisedToInteger: aPositiveInteger. - raised = self ifTrue: [ ^ guess ]. + p := Float precision - guess highBitOfMagnitude. + p < 0 ifTrue: [ ^ guess asFloat ]. - "In this case, maybe it failed because we are such a big integer that the Float - method gets inexact, even if we are a whole square number. - Note 1(jmv): This algorithm is faster than #nthRootTruncated: for big n (aPositiveInteger) - but fails if self asFloat isInfinite. - Note 2(jmv): The algorithms I found for computing the nthRoot would havily use - very large fractions. I wrote this one, that doesn't create fractions." - selfAsFloat abs >= (Float maxExactInteger asFloat raisedToInteger: aPositiveInteger) - ifTrue: [ - raised > self - ifTrue: [ - higher := guess. - delta := floatResult predecessor - floatResult. - [ - floatResult := floatResult + delta. - lower := floatResult rounded. - (lower raisedToInteger: aPositiveInteger) > self ] whileTrue: [ - delta := delta * 2. - higher := lower ] ] - ifFalse: [ - lower := guess. - delta := floatResult successor - floatResult. - [ - floatResult := floatResult + delta. - higher := floatResult rounded. - (higher raisedToInteger: aPositiveInteger) < self ] whileTrue: [ - delta := delta * 2. - lower := higher ]]. - [ higher - lower > 1 ] whileTrue: [ - guess := lower + higher // 2. - raised := guess raisedToInteger: aPositiveInteger. - raised = self - ifTrue: [ - ^ guess ]. - raised > self - ifTrue: [ higher := guess ] - ifFalse: [ lower := guess ]]]. + guess := self << (p * aPositiveInteger) nthRootRounded: aPositiveInteger. + ^(guess / (1 << p)) asFloat! - "We need an approximate result" - ^floatResult! Item was added: + ----- Method: Integer>>nthRootRounded: (in category 'mathematical functions') ----- + nthRootRounded: aPositiveInteger + "Answer the integer nearest the nth root of the receiver." + | guess | + self = 0 ifTrue: [^0]. + self negative + ifTrue: + [aPositiveInteger even ifTrue: [ ArithmeticError signal: 'Negative numbers don''t have even roots.' ]. + ^(self negated nthRootRounded: aPositiveInteger) negated]. + guess := self nthRootTruncated: aPositiveInteger. + ^self * 2 > ((guess + 1 raisedTo: aPositiveInteger) + (guess raisedTo: aPositiveInteger)) + ifTrue: [guess + 1] + ifFalse: [guess]! Item was removed: - ----- Method: LargePositiveInteger>>sqrtFloor (in category 'mathematical functions') ----- - sqrtFloor - "Return the integer part of the square root of self" - - | powerOfTwo | - (powerOfTwo := self lowBit - 1 // 2) > 1 - ifFalse: [^super sqrtFloor]. - ^(self bitShift: -2 * powerOfTwo) sqrtFloor bitShift: powerOfTwo! Item was removed: - ----- Method: ScaledDecimal>>// (in category 'arithmetic') ----- - // operand - "Answer the integer quotient after dividing the receiver by operand - with truncation towards negative infinity." - ^ fraction // operand! Item was changed: ----- Method: ScaledDecimal>>integerPart (in category 'truncation and round off') ----- integerPart + "Answer the integer part of the receiver." - "Answer the fractional part of the receiver." ^ ScaledDecimal newFromNumber: fraction integerPart scale: scale! From commits at source.squeak.org Fri Apr 10 21:08:21 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 10 21:08:22 2015 Subject: [squeak-dev] Squeak 4.5: Kernel-topa.845.mcz Message-ID: Tobias Pape uploaded a new version of Kernel to project Squeak 4.5: http://source.squeak.org/squeak45/Kernel-topa.845.mcz ==================== Summary ==================== Name: Kernel-topa.845 Author: topa Time: 10 April 2015, 11:08:02.396 pm UUID: 444874b7-5484-48d3-98cc-b506787a4eff Ancestors: Kernel-cwp.844 hotfix: Pick up trunk method necessary for class renames. =============== Diff against Kernel-cwp.844 =============== Item was added: + ----- Method: ClassDescription>>updateMethodBindingsTo: (in category 'initialize-release') ----- + updateMethodBindingsTo: aBinding + "ClassBuilder support for maintaining valid method bindings." + methodDict do: [:method| method methodClassAssociation: aBinding]! From Das.Linux at gmx.de Fri Apr 10 21:08:34 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Fri Apr 10 21:08:39 2015 Subject: [squeak-dev] A bug with class renaming In-Reply-To: <1428155228.3951.0@mglap> References: <839D9F43-C05C-4009-BCE4-E976E15B0BE2@gmx.de> <1427990360.17970.0@mglap> <1428155228.3951.0@mglap> Message-ID: <2C2C105F-5886-45EA-9F13-2791E1361242@gmx.de> Hi, On 04.04.2015, at 15:47, Mateusz Grotek wrote: > I've opened a ticket for it: #0007827 Sorry for taking so long. I reproduced it. For Squeak-4.5 I fixed it in Kernel-topa.845. Please see if your problem is gone :) Best -Tobias From Das.Linux at gmx.de Fri Apr 10 21:09:15 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Fri Apr 10 21:09:20 2015 Subject: [squeak-dev] Squeak 4.5: Kernel-cwp.844.mcz Message-ID: I just copied this over from trunk, as it was missing in the repo, which I don't understand; It is loaded in all 4.5 images I have laying around. Best -Tobias On 10.04.2015, at 21:06, commits@source.squeak.org wrote: > Tobias Pape uploaded a new version of Kernel to project Squeak 4.5: > http://source.squeak.org/squeak45/Kernel-cwp.844.mcz > > ==================== Summary ==================== > > Name: Kernel-cwp.844 > Author: cwp > Time: 22 March 2014, 7:57:39.797 pm > UUID: f4f1b55b-db99-4fae-9a9b-3fcdcc0a6716 > Ancestors: Kernel-cwp.840, Kernel-nice.843 > > merge > > =============== Diff against Kernel-dtl.836 =============== > > Item was changed: From commits at source.squeak.org Fri Apr 10 21:55:05 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Fri Apr 10 21:55:07 2015 Subject: [squeak-dev] Daily Commit Log Message-ID: <20150410215505.27315.qmail@box4.squeakfoundation.org> Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours: http://lists.squeakfoundation.org/pipermail/packages/2015-April/007885.html Name: Collections.spur-tfel.613 Ancestors: Collections-tfel.613, Collections.spur-bf.612 Collections-tfel.613 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 Fix replaceFrom:to:with:startingAt: for ByteArray if run on a VM without primitive 105 ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007886.html Name: System.spur-mt.719 Ancestors: System-mt.719, System.spur-topa.718 System-mt.719 patched for Spur by SpurBootstrapMonticelloPackagePatcher Cog-tpr.257 Removed menu-button pref from Preferences because it is now in ScrollBar class. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007887.html Name: MonticelloConfigurations-dtl.129 Ancestors: MonticelloConfigurations-bf.128 MCMcmUpdater class>>updateFromRepositories: has accumulated various enhancements and now wants to be factored into smaller methods. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007888.html Name: Morphic-mt.851 Ancestors: Morphic-mt.850 Keyboard-focus handling extended. Morphs may no #wantsKeyboardFocus so that they can take advantage of #keyboardFocusChange: in a transparent fashion. Until now, they to explicitely acquire the keyboard focus, which they sometimes forgot. Thus, #keyboardFocusChange: did not work as expected. All scroll panes want the keyboard focus. This includes pluggable text morphs and pluggable lists and pluggable trees. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007889.html Name: Morphic-mt.852 Ancestors: Morphic-mt.851 Convenient messages added to morphs to check for current mouse or keyboard focus. Could be used, for example, to change visual appearnce to indicate that focus. Does not happen yet (except for the blinking text cursor). (in conjunction with #keyboardFocusChange:). Note: We should get rid of #hasFocus because only hands now the exact information. For multiple hands, such cached information in the morph may not valid anyway. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007890.html Name: Morphic-mt.853 Ancestors: Morphic-mt.852 Some cosmetic fixes in sliders, scroll bars, and scroll panes. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007891.html Name: Morphic-mt.854 Ancestors: Morphic-mt.853 Extracted drawing of drop-highlights and mouse-down-highlights into #drawOverlayOn: to give subclasses a chance to draw something over their submorphs in a general fashion (w/o having to overwrite #fullDrawOn:). ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007892.html Name: Morphic-mt.855 Ancestors: Morphic-mt.854 Fixed category. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007893.html Name: Collections-bf.614 Ancestors: Collections-tfel.613 Revert WeakArray>>species temporarily to see if this fixes testNoObsoleteClasses on the build server ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007894.html Name: KernelTests-ul.290 Ancestors: KernelTests-eem.289 Updated RandomTest to match the new implementation of Random. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007895.html Name: Morphic-mt.856 Ancestors: Morphic-mt.855 Added the possibility to indicate the current keyboard focus for *every* morph. It is a preference, which can be enabled but is disabled by default. Why needed? It may be hard to determine the current keyboard focus if #mouseOverForKeyboardFocus is disabled. Morphs can overwrite the default preference by either implementing #indicateKeyboardFocus or setting a property with that name to #never. (PluggableTextMorph does that for its text morph) This commit includes also some fixes for #keyboardFocusChange: were overwritten methods forgot to call super. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007896.html Name: KernelTests-ul.291 Ancestors: KernelTests-ul.290 Don't keep any references to classes created in ClassVarScopeTest. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007897.html Name: Collections-bf.615 Ancestors: Collections-bf.614 Restore WeakArray>>species. It's apparently not the culprit for the obsolete class refs. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007898.html Name: Morphic-mt.857 Ancestors: Morphic-mt.856 Some cosmetic changes: do not darken the paneColor in scroll bars', scroll panes', and system windows' so much. Note: This is a reaction to some feedback to make the non-gradient look more friendlier. ============================================= From lewis at mail.msen.com Sat Apr 11 01:07:00 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Sat Apr 11 01:07:02 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.849.mcz In-Reply-To: References: <1428679754934-4818928.post@n4.nabble.com> Message-ID: <20150411010700.GA36784@shell.msen.com> On Fri, Apr 10, 2015 at 06:18:53PM +0200, karl ramberg wrote: > Sorry, I'm going full retard here. > Just ignore my previous mail. Hi Karl, It sure is good to have you back :-)) Dave From commits at source.squeak.org Sat Apr 11 03:11:43 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 11 03:11:44 2015 Subject: [squeak-dev] The Trunk: Tests-ul.318.mcz Message-ID: Levente Uzonyi uploaded a new version of Tests to project The Trunk: http://source.squeak.org/trunk/Tests-ul.318.mcz ==================== Summary ==================== Name: Tests-ul.318 Author: ul Time: 11 April 2015, 5:00:50.13 am UUID: 2fee61e2-b0cb-4035-ba7b-1513cb1ab885 Ancestors: Tests-topa.317 Added some tests for ThirtyTwoBitRegister. =============== Diff against Tests-topa.317 =============== Item was changed: SystemOrganization addCategory: #'Tests-Bugs'! SystemOrganization addCategory: #'Tests-Compiler'! SystemOrganization addCategory: #'Tests-Dependencies'! SystemOrganization addCategory: #'Tests-Digital Signatures'! SystemOrganization addCategory: #'Tests-Environments'! SystemOrganization addCategory: #'Tests-Exceptions'! SystemOrganization addCategory: #'Tests-FilePackage'! SystemOrganization addCategory: #'Tests-Files'! SystemOrganization addCategory: #'Tests-Finalization'! SystemOrganization addCategory: #'Tests-Hex'! SystemOrganization addCategory: #'Tests-Installer-Core'! SystemOrganization addCategory: #'Tests-Localization'! SystemOrganization addCategory: #'Tests-Monticello'! SystemOrganization addCategory: #'Tests-Monticello-Mocks'! SystemOrganization addCategory: #'Tests-Monticello-Utils'! SystemOrganization addCategory: #'Tests-Object Events'! SystemOrganization addCategory: #'Tests-ObjectsAsMethods'! SystemOrganization addCategory: #'Tests-PrimCallController'! SystemOrganization addCategory: #'Tests-Release'! SystemOrganization addCategory: #'Tests-System-Object Storage'! SystemOrganization addCategory: #'Tests-System-Support'! SystemOrganization addCategory: #'Tests-Utilities'! SystemOrganization addCategory: #'Tests-VM'! + SystemOrganization addCategory: #'Tests-System-Digital Signatures'! Item was added: + TestCase subclass: #ThirtyTwoBitRegisterTest + instanceVariableNames: 'random' + classVariableNames: '' + poolDictionaries: '' + category: 'Tests-System-Digital Signatures'! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>assertBinaryRegisterOperation:gives:times: (in category 'helpers') ----- + assertBinaryRegisterOperation: registerOperationBlock gives: integerOperationBlock times: n + + | rx ry | + rx := ThirtyTwoBitRegister new. + ry := rx copy. + n timesRepeat: [ + | x y expectedResult | + x := self nextRandom. + y := self nextRandom. + expectedResult := integerOperationBlock value: x value: y . + rx load: x. + ry load: y. + registerOperationBlock value: rx value: ry. + self assert: expectedResult equals: rx asInteger ]! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>assertComparisonRegisterOperation:gives:times: (in category 'helpers') ----- + assertComparisonRegisterOperation: registerOperationBlock gives: integerOperationBlock times: n + + | rx ry | + rx := ThirtyTwoBitRegister new. + ry := rx copy. + n timesRepeat: [ + | x y expectedResult actualResult | + x := self nextRandom. + y := self nextRandom. + expectedResult := integerOperationBlock value: x value: y . + rx load: x. + ry load: y. + actualResult := registerOperationBlock value: rx value: ry. + self assert: expectedResult equals: actualResult ]! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>assertUnaryRegisterOperation:gives:times: (in category 'helpers') ----- + assertUnaryRegisterOperation: registerOperationBlock gives: integerOperationBlock times: n + + | rx | + rx := ThirtyTwoBitRegister new. + n timesRepeat: [ + | x expectedResult | + x := self nextRandom. + expectedResult := integerOperationBlock value: x. + rx load: x. + registerOperationBlock value: rx. + self assert: expectedResult equals: rx asInteger ]! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>nextRandom (in category 'helpers') ----- + nextRandom + "Return the next random 32-bit unsigned integer value." + + ^(random nextInt: 4294967296) - 1! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>setUp (in category 'running') ----- + setUp + + random := Random seed: 36rSqueak! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testAddition (in category 'tests - accumulator ops') ----- + testAddition + + self + assertBinaryRegisterOperation: [ :rx :ry | rx += ry ] + gives: [ :x :y | x + y bitAnd: 16rFFFFFFFF ] + times: 10000! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testBitAnd (in category 'tests - accumulator ops') ----- + testBitAnd + + self + assertBinaryRegisterOperation: [ :rx :ry | rx bitAnd: ry ] + gives: [ :x :y | x bitAnd: y ] + times: 10000! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testBitInvert (in category 'tests - accumulator ops') ----- + testBitInvert + + self + assertUnaryRegisterOperation: [ :rx | rx bitInvert ] + gives: [ :x | x bitInvert32 ] + times: 10000! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testBitOr (in category 'tests - accumulator ops') ----- + testBitOr + + self + assertBinaryRegisterOperation: [ :rx :ry | rx bitOr: ry ] + gives: [ :x :y | x bitOr: y ] + times: 10000! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testBitXor (in category 'tests - accumulator ops') ----- + testBitXor + + self + assertBinaryRegisterOperation: [ :rx :ry | rx bitXor: ry ] + gives: [ :x :y | x bitXor: y ] + times: 10000! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testEquals (in category 'tests - comparison') ----- + testEquals + + self + assertComparisonRegisterOperation: [ :rx :ry | rx = ry ] + gives: [ :x :y | x = y ] + times: 1000! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testGreater (in category 'tests - comparison') ----- + testGreater + + self + assertComparisonRegisterOperation: [ :rx :ry | rx > ry ] + gives: [ :x :y | x > y ] + times: 1000! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testGreaterOrEqual (in category 'tests - comparison') ----- + testGreaterOrEqual + + self + assertComparisonRegisterOperation: [ :rx :ry | rx >= ry ] + gives: [ :x :y | x >= y ] + times: 1000! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testHi (in category 'tests') ----- + testHi + + self + assertUnaryRegisterOperation: [ :rx | rx load: rx hi ] + gives: [ :x | x bitShift: -16 ] + times: 1000! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testLeftRotateBy (in category 'tests - accumulator ops') ----- + testLeftRotateBy + + 0 to: 33 do: [ :shift | + self + assertUnaryRegisterOperation: [ :rx | rx leftRotateBy: shift ] + gives: [ :x | + | actualShift | + actualShift := shift \\ 32. + (x << actualShift bitOr: x >> (32 - actualShift)) bitAnd: 16rFFFFFFFF ] + times: 1000 ]! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testLeftShift (in category 'tests - accumulator ops') ----- + testLeftShift + + 0 to: 33 do: [ :shift | + self + assertUnaryRegisterOperation: [ :rx | rx << shift ] + gives: [ :x | x << shift bitAnd: 16rFFFFFFFF ] + times: 1000 ]! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testLess (in category 'tests - comparison') ----- + testLess + + self + assertComparisonRegisterOperation: [ :rx :ry | rx < ry ] + gives: [ :x :y | x < y ] + times: 1000! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testLessOrEqual (in category 'tests - comparison') ----- + testLessOrEqual + + self + assertComparisonRegisterOperation: [ :rx :ry | rx <= ry ] + gives: [ :x :y | x <= y ] + times: 1000! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testLoad (in category 'tests') ----- + testLoad + + 1000 timesRepeat: [ + | value | + value := self nextRandom. + self + assertUnaryRegisterOperation: [ :rx | rx load: value ] + gives: [ :x | value ] + times: 1 ]! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testLoadFrom (in category 'tests') ----- + testLoadFrom + + self + assertBinaryRegisterOperation: [ :rx :ry | rx loadFrom: ry ] + gives: [ :x :y | y ] + times: 10000! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testLow (in category 'tests') ----- + testLow + + self + assertUnaryRegisterOperation: [ :rx | rx load: rx low ] + gives: [ :x | x bitAnd: 16rFFFF ] + times: 1000! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testMultiplication (in category 'tests - accumulator ops') ----- + testMultiplication + + self + assertBinaryRegisterOperation: [ :rx :ry | rx *= ry ] + gives: [ :x :y | x * y bitAnd: 16rFFFFFFFF ] + times: 10000! Item was added: + ----- Method: ThirtyTwoBitRegisterTest>>testRightShift (in category 'tests - accumulator ops') ----- + testRightShift + + 0 to: 33 do: [ :shift | + self + assertUnaryRegisterOperation: [ :rx | rx >> shift ] + gives: [ :x | x >> shift bitAnd: 16rFFFFFFFF ] + times: 1000 ]! From commits at source.squeak.org Sat Apr 11 03:11:49 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 11 03:11:52 2015 Subject: [squeak-dev] The Trunk: System-ul.720.mcz Message-ID: Levente Uzonyi uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System-ul.720.mcz ==================== Summary ==================== Name: System-ul.720 Author: ul Time: 11 April 2015, 4:55:06.206 am UUID: 1aa19753-6581-491d-a289-4d29c9797997 Ancestors: System-mt.719 Added left and right shifts, multiplication, load from register, and comparision operators to ThirtyTwoBitRegister. Also implmenented #hash, and added #asSignedInteger. =============== Diff against System-mt.719 =============== Item was added: + ----- Method: ThirtyTwoBitRegister>>*= (in category 'accumulator ops') ----- + *= aThirtTwoBitRegister + "Replace my contents with the product of the given register and my current contents." + + | otherLow otherHi mul newLow newHi | + otherLow := aThirtTwoBitRegister low. + otherHi := aThirtTwoBitRegister hi. + "Multiply low with otherLow. Process the two highest bits of low separately if necessary to avoid LargeInteger operations." + (low bitShift: -8) * (otherLow bitShift: -8) > 16r3FFF + ifTrue: [ + mul := (low bitAnd: 16r3FFF) * otherLow. "Without the two most significant bits of low." + newLow := (mul bitAnd: 16rFFFF). + newHi := (mul bitShift: -16). + mul := (low bitShift: -14) * otherLow. "The two most significant bits of low" + newLow := newLow + ((mul bitAnd: 16r3) bitShift: 14). + newHi := newHi + (mul bitShift: -2) + (newLow bitShift: -16) "Carry from newLow" ] + ifFalse: [ + newLow := low * otherLow. "We'll trim newLow at the end of the method." + newHi := newLow bitShift: -16 ]. + "Multiply hi with otherLow." + (hi bitShift: -8) * (otherLow bitShift: -8) > 16r3FFF + ifTrue: [ + newHi := newHi + + ((hi bitAnd: 16r3FFF) * otherLow bitAnd: 16rFFFF) + + (((hi bitShift: -14) * otherLow bitAnd: 16r3) bitShift: 14) ] + ifFalse: [ newHi := newHi + (hi * otherLow bitAnd: 16rFFFF) ]. + "Multiply low with otherHi." + (low bitShift: -8) * (otherHi bitShift: -8) > 16r3FFF + ifTrue: [ + newHi := newHi + + ((low bitAnd: 16r3FFF) * otherHi bitAnd: 16rFFFF) + + (((low bitShift: -14) * otherHi bitAnd: 16r3) bitShift: 14) ] + ifFalse: [ newHi := newHi + (low * otherHi bitAnd: 16rFFFF) ]. + "Truncate and store the results." + hi := newHi bitAnd: 16rFFFF. + low := newLow bitAnd: 16rFFFF + ! Item was added: + ----- Method: ThirtyTwoBitRegister>>< (in category 'comparing') ----- + < aThirtyTwoBitRegister + + ^hi < aThirtyTwoBitRegister hi or: [ + hi = aThirtyTwoBitRegister hi and: [ + low < aThirtyTwoBitRegister low ] ]! Item was added: + ----- Method: ThirtyTwoBitRegister>><< (in category 'accumulator ops') ----- + << anInteger + "Unsigned left shift." + + | bitCount | + bitCount := anInteger. + bitCount >= 32 ifTrue: [ + hi := low := 0. + ^self ]. + bitCount >= 16 ifTrue: [ + hi := low. + low := 0. + bitCount := bitCount - 16 ]. + bitCount >= 15 ifTrue: [ + hi := ((hi bitAnd: 1) bitShift: 15) bitOr: (low bitShift: -1). + low := (low bitAnd: 1) bitShift: 15. + ^self ]. + bitCount >= 1 ifTrue: [ + hi := ((hi bitShift: bitCount) bitAnd: 16rFFFF) bitOr: (low bitShift: bitCount - 16). + low := (low bitShift: bitCount) bitAnd: 16rFFFF ]! Item was added: + ----- Method: ThirtyTwoBitRegister>><= (in category 'comparing') ----- + <= aThirtyTwoBitRegister + + ^hi < aThirtyTwoBitRegister hi or: [ + hi = aThirtyTwoBitRegister hi and: [ + low <= aThirtyTwoBitRegister low ] ]! Item was added: + ----- Method: ThirtyTwoBitRegister>>= (in category 'comparing') ----- + = anObject + + ^self class == anObject class + and: [ anObject low = low + and: [ anObject hi = hi ] ]! Item was added: + ----- Method: ThirtyTwoBitRegister>>> (in category 'comparing') ----- + > aThirtyTwoBitRegister + + ^hi > aThirtyTwoBitRegister hi or: [ + hi = aThirtyTwoBitRegister hi and: [ + low > aThirtyTwoBitRegister low ] ]! Item was added: + ----- Method: ThirtyTwoBitRegister>>>= (in category 'comparing') ----- + >= aThirtyTwoBitRegister + + ^hi > aThirtyTwoBitRegister hi or: [ + hi = aThirtyTwoBitRegister hi and: [ + low >= aThirtyTwoBitRegister low ] ]! Item was added: + ----- Method: ThirtyTwoBitRegister>>>> (in category 'accumulator ops') ----- + >> anInteger + "Unsigned right shift." + + | bitCount shift | + bitCount := anInteger. + bitCount >= 32 ifTrue: [ + hi := low := 0. + ^self ]. + bitCount >= 16 ifTrue: [ + low := hi. + hi := 0. + bitCount := bitCount - 16 ]. + bitCount >= 2 ifTrue: [ + shift := 0 - bitCount. + low := (low bitShift: shift) bitOr: ((hi bitShift: shift + 16) bitAnd: 16rFFFF). + hi := hi bitShift: shift. + ^self ]. + bitCount >= 1 ifTrue: [ + low := (low bitShift: -1) bitOr: ((hi bitAnd: 16r1) bitShift: 15). + hi := hi bitShift: -1 ]! Item was changed: + ----- Method: ThirtyTwoBitRegister>>asInteger (in category 'converting') ----- - ----- Method: ThirtyTwoBitRegister>>asInteger (in category 'accessing') ----- asInteger "Answer the integer value of my current contents." ^ (hi bitShift: 16) + low ! Item was added: + ----- Method: ThirtyTwoBitRegister>>asSignedInteger (in category 'converting') ----- + asSignedInteger + "Answer the signed integer value of my current contents." + + hi >= 16r8000 ifFalse: [ ^(hi bitShift: 16) + low ]. + ^-1 - (low bitXor: 16rFFFF) - ((hi bitXor: 16rFFFF) bitShift: 16) + + + ! Item was added: + ----- Method: ThirtyTwoBitRegister>>hash (in category 'comparing') ----- + hash + + ^((hi bitShift: 14) bitXor: low) hashMultiply! Item was added: + ----- Method: ThirtyTwoBitRegister>>loadFrom: (in category 'accessing') ----- + loadFrom: aThirtyTwoBitRegister + "Set my contents from the given ThirtyTwoBitRegister." + + hi := aThirtyTwoBitRegister hi. + low := aThirtyTwoBitRegister low + ! From karlramberg at gmail.com Sat Apr 11 03:52:08 2015 From: karlramberg at gmail.com (karl ramberg) Date: Sat Apr 11 03:52:14 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.849.mcz In-Reply-To: <20150411010700.GA36784@shell.msen.com> References: <1428679754934-4818928.post@n4.nabble.com> <20150411010700.GA36784@shell.msen.com> Message-ID: :-) On Sat, Apr 11, 2015 at 3:07 AM, David T. Lewis wrote: > On Fri, Apr 10, 2015 at 06:18:53PM +0200, karl ramberg wrote: > > Sorry, I'm going full retard here. > > Just ignore my previous mail. > > Hi Karl, > > It sure is good to have you back :-)) > > Dave > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150411/b216032e/attachment.htm From commits at source.squeak.org Sat Apr 11 06:13:22 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 11 06:13:25 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Kernel-mt.74.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Kernel to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Kernel-mt.74.mcz ==================== Summary ==================== Name: ToolBuilder-Kernel-mt.74 Author: mt Time: 11 April 2015, 8:13:18.068 am UUID: c8bbd2e5-1fdf-6147-8f13-15e4582df4e3 Ancestors: ToolBuilder-Kernel-mt.73 New preference for opening tools. Custom tool builders may consider mouse activity and thus spawn new tools directly under the mouse cursor or attached to it. Disabled by default. =============== Diff against ToolBuilder-Kernel-mt.73 =============== Item was changed: Object subclass: #ToolBuilder instanceVariableNames: 'parent' + classVariableNames: 'OpenToolsAttachedToMouseCursor' - classVariableNames: '' poolDictionaries: '' category: 'ToolBuilder-Kernel'! !ToolBuilder commentStamp: '' prior: 0! I am a tool builder, that is an object which knows how to create concrete widgets from abstract specifications. Those specifications are used by tools which want to be able to function in diverse user interface paradigms, such as MVC, Morphic, Tweak, wxWidgets etc. The following five specs must be supported by all implementations: * PluggableButton * PluggableList * PluggableText * PluggablePanel * PluggableWindow The following specs are optional: * PluggableTree: If not supported, the tool builder must answer nil when asked for a pluggableTreeSpec. Substitution will require client support so clients must be aware that some tool builders may not support trees (MVC for example, or Seaside). See examples in FileListPlus or TestRunnerPlus. * PluggableMultiSelectionList: If multi-selection lists are not supported, tool builder will silently support regular single selection lists. * PluggableInputField: Intended as a HINT for the builder that this widget will be used as a single line input field. Unless explicitly supported it will be automatically substituted by PluggableText. * PluggableActionButton: Intended as a HINT for the builder that this widget will be used as push (action) button. Unless explicitly supported it will be automatically substituted by PluggableButton. * PluggableRadioButton: Intended as a HINT for the builder that this widget will be used as radio button. Unless explicitly supported it will be automatically substituted by PluggableButton. * PluggableCheckBox: Intended as a HINT for the builder that this widget will be used as check box. Unless explicitly supported it will be automatically substituted by PluggableButton. ! Item was added: + ----- Method: ToolBuilder class>>openToolsAttachedToMouseCursor (in category 'preferences') ----- + openToolsAttachedToMouseCursor + + + ^ OpenToolsAttachedToMouseCursor ifNil: [false]! Item was added: + ----- Method: ToolBuilder class>>openToolsAttachedToMouseCursor: (in category 'preferences') ----- + openToolsAttachedToMouseCursor: aBoolean + + OpenToolsAttachedToMouseCursor := aBoolean.! From commits at source.squeak.org Sat Apr 11 06:15:23 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 11 06:15:25 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.122.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.122.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.122 Author: mt Time: 11 April 2015, 8:15:18.783 am UUID: f601e0ad-6555-0746-9827-7d81c7cf04ba Ancestors: ToolBuilder-Morphic-mt.121 If the preference #openToolsAttachedToMouseCursor is enabled, the morphic tool builder will attach any system window to the hand if the current event is a mouse event. =============== Diff against ToolBuilder-Morphic-mt.121 =============== Item was changed: ----- Method: MorphicToolBuilder>>open: (in category 'opening') ----- open: anObject "Build and open the object. Answer the widget opened." | morph | anObject isMorph ifTrue:[morph := anObject] ifFalse:[morph := self build: anObject]. (morph isKindOf: MenuMorph) ifTrue:[morph popUpInWorld: World]. (morph isKindOf: SystemWindow) + ifFalse:[morph openInWorld] + ifTrue:[ + morph := morph openInWorldExtent: morph extent. + (self class openToolsAttachedToMouseCursor and: [self currentEvent isMouse]) + ifTrue: [ + morph hasDropShadow: false. + self currentHand attachMorph: morph]]. - ifTrue:[morph := morph openInWorldExtent: morph extent] - ifFalse:[morph openInWorld]. ^morph! From commits at source.squeak.org Sat Apr 11 06:18:21 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 11 06:18:23 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.858.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.858.mcz ==================== Summary ==================== Name: Morphic-mt.858 Author: mt Time: 11 April 2015, 8:17:49.802 am UUID: 177c14bc-e5d4-ad44-9d21-37d64d7f69e0 Ancestors: Morphic-mt.857 Remove special behavior for tool-opening at the hand when inspecting or exploring morphs via the halo context menu. Use the preference #openToolsAttachedToMouseCursor if you want that behavior. Then, you will have it not only in those two cases but for any mouse-invoked tool opening. =============== Diff against Morphic-mt.857 =============== Item was changed: ----- Method: Morph>>exploreInMorphic (in category 'menus') ----- exploreInMorphic + + ToolSet explore: self.! - self currentHand attachMorph: (ToolSet explore: self).! Item was changed: ----- Method: Morph>>exploreInMorphic: (in category 'menus') ----- exploreInMorphic: evt + + ToolSet explore: self.! - evt hand attachMorph: (ToolSet explore: self).! Item was changed: ----- Method: Morph>>inspectInMorphic (in category 'menus') ----- inspectInMorphic + + ToolSet inspect: self.! - self currentHand attachMorph: ((ToolSet inspect: self) extent: 300@200)! Item was changed: ----- Method: Morph>>inspectInMorphic: (in category 'menus') ----- inspectInMorphic: evt + + ToolSet inspect: self. + ! - evt hand attachMorph: ((ToolSet inspect: self) extent: 300@200)! From commits at source.squeak.org Sat Apr 11 06:20:20 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 11 06:20:21 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.859.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.859.mcz ==================== Summary ==================== Name: Morphic-mt.859 Author: mt Time: 11 April 2015, 8:19:49.187 am UUID: 88bdb9f6-44da-814d-8510-555d3b9fc6b3 Ancestors: Morphic-mt.858 Safety-check added when spawning balloons. There is one when starting the alarm/timer, but we need one when actually showing the balloon because #wantsBalloon may have changed until then. =============== Diff against Morphic-mt.858 =============== Item was changed: ----- Method: HandMorph>>spawnBalloonFor: (in category 'balloon help') ----- spawnBalloonFor: aMorph + + aMorph wantsBalloon ifFalse: [^ self]. aMorph showBalloon: aMorph balloonText hand: self.! From commits at source.squeak.org Sat Apr 11 14:47:56 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 11 14:47:58 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.123.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.123.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.123 Author: mt Time: 11 April 2015, 4:47:51.035 pm UUID: f35b0f2e-9a5f-a54a-bc96-a486f18550a5 Ancestors: ToolBuilder-Morphic-mt.122 Due to the variety of mouse events and the high frequency of mouse-move events in particular, only spawn a new tool at the hand if preference is enabled and the current/last event was mouse-up, e.g. button or menu click. =============== Diff against ToolBuilder-Morphic-mt.122 =============== Item was changed: ----- Method: MorphicToolBuilder>>open: (in category 'opening') ----- open: anObject "Build and open the object. Answer the widget opened." | morph | anObject isMorph ifTrue:[morph := anObject] ifFalse:[morph := self build: anObject]. (morph isKindOf: MenuMorph) ifTrue:[morph popUpInWorld: World]. (morph isKindOf: SystemWindow) ifFalse:[morph openInWorld] ifTrue:[ morph := morph openInWorldExtent: morph extent. + (self class openToolsAttachedToMouseCursor + and: [self currentEvent isMouse and: [self currentEvent isMouseUp]]) + ifTrue: [ + morph hasDropShadow: false. + self currentHand attachMorph: morph]]. - (self class openToolsAttachedToMouseCursor and: [self currentEvent isMouse]) - ifTrue: [ - morph hasDropShadow: false. - self currentHand attachMorph: morph]]. ^morph! From commits at source.squeak.org Sat Apr 11 14:59:48 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 11 14:59:50 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.860.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.860.mcz ==================== Summary ==================== Name: Morphic-mt.860 Author: mt Time: 11 April 2015, 4:59:18.42 pm UUID: ee50df47-55d5-5249-9800-18e78efdf0b1 Ancestors: Morphic-mt.859 Fixed bug where switching from an MVC project back to a Morphic project did fail. (This bug was related to the Morphic drawing routine and keyboard-focus highlight.) =============== Diff against Morphic-mt.859 =============== Item was changed: ----- Method: Morph>>hasKeyboardFocus (in category 'event handling') ----- hasKeyboardFocus + ^ self activeHand + ifNil: [false] + ifNotNil: [:hand | self hasKeyboardFocus: hand]! - ^ self hasKeyboardFocus: self activeHand! Item was changed: ----- Method: Morph>>hasMouseFocus (in category 'event handling') ----- hasMouseFocus + ^ self activeHand + ifNil: [false] + ifNotNil: [:hand | self hasMouseFocus: hand]! - ^ self hasMouseFocus: self activeHand! From commits at source.squeak.org Sat Apr 11 15:07:01 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 11 15:07:03 2015 Subject: [squeak-dev] The Trunk: ST80-mt.178.mcz Message-ID: Marcel Taeumel uploaded a new version of ST80 to project The Trunk: http://source.squeak.org/trunk/ST80-mt.178.mcz ==================== Summary ==================== Name: ST80-mt.178 Author: mt Time: 11 April 2015, 5:06:52.616 pm UUID: 5b5ddb55-986d-c042-8c6b-4561bff32ae0 Ancestors: ST80-mt.177 Changed window color for MVC projects in morphic to white to compensate the removal of a former system-window hack. =============== Diff against ST80-mt.177 =============== Item was changed: ----- Method: MVCProject>>defaultBackgroundColor (in category 'initialize') ----- defaultBackgroundColor + ^ Color white! - ^ Color r: 1.0 g: 1.0 b: 0.065! From commits at source.squeak.org Sat Apr 11 15:08:26 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 11 15:08:28 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.861.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.861.mcz ==================== Summary ==================== Name: Morphic-mt.861 Author: mt Time: 11 April 2015, 5:07:58.421 pm UUID: e3d025d6-6ffb-d546-a931-2851f41d2a87 Ancestors: Morphic-mt.860 Changed window color for morphic projects in morphic to default uniform window color to compensate the removal of a former system-window hack. =============== Diff against Morphic-mt.860 =============== Item was changed: ----- Method: MorphicProject>>defaultBackgroundColor (in category 'initialize') ----- defaultBackgroundColor + ^ Preferences uniformWindowColor! - ^ Preferences defaultWorldColor! From commits at source.squeak.org Sat Apr 11 21:21:13 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 11 21:21:15 2015 Subject: [squeak-dev] The Trunk: Collections-ul.616.mcz Message-ID: Levente Uzonyi uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections-ul.616.mcz ==================== Summary ==================== Name: Collections-ul.616 Author: ul Time: 11 April 2015, 11:12:16.588 pm UUID: ff292158-e8cd-4d21-aae6-c15135dd707f Ancestors: Collections-bf.615 Optimized Interval >> #sum, OrderedCollection >> #at: and OrderedCollection >> #at:put:. =============== Diff against Collections-bf.615 =============== Item was changed: ----- Method: Interval>>sum (in category 'accessing') ----- sum + "Optimized version. Use the sum(n * i - k, i=a..b) = -1/2 * (a - b - 1) * (n * (a + b) - 2 * k) equation with a = 1, n = step, b = self size and k = step - start." - "Optimized version. Use the sum(n*i - k, i=a..b) = -1/2*(a - b - 1)*(n * (a + b) - 2 * k) equation with a = 1, n = step, b = self size." | b | b := self size. + ^b * ((b - 1) * step + (start * 2)) / 2! - ^b * ((b + 1) * step - (step - start * 2)) / 2! Item was changed: ----- Method: OrderedCollection>>at: (in category 'accessing') ----- at: anInteger "Answer my element at index anInteger. at: is used by a knowledgeable client to access an existing element" + | index | + 1 <= anInteger ifFalse: [ self errorNoSuchElement ]. + (index := anInteger + firstIndex - 1) <= lastIndex ifFalse: [ self errorNoSuchElement ]. + ^array at: index! - (anInteger < 1 or: [anInteger + firstIndex - 1 > lastIndex]) - ifTrue: [self errorNoSuchElement] - ifFalse: [^ array at: anInteger + firstIndex - 1]! Item was changed: ----- Method: OrderedCollection>>at:put: (in category 'accessing') ----- at: anInteger put: anObject "Put anObject at element index anInteger. at:put: cannot be used to append, front or back, to an ordered collection; it is used by a knowledgeable client to replace an element." + | index | + 1 <= anInteger ifFalse: [ self errorNoSuchElement ]. + (index := anInteger + firstIndex - 1) <= lastIndex ifFalse: [ self errorNoSuchElement ]. + ^array at: index put: anObject! - (anInteger < 1 or: [anInteger + firstIndex - 1 > lastIndex]) - ifTrue: [self errorNoSuchElement] - ifFalse: [^array at: anInteger + firstIndex - 1 put: anObject]! From commits at source.squeak.org Sat Apr 11 21:55:06 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sat Apr 11 21:55:10 2015 Subject: [squeak-dev] Daily Commit Log Message-ID: <20150411215506.16280.qmail@box4.squeakfoundation.org> Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours: http://lists.squeakfoundation.org/pipermail/packages/2015-April/007899.html Name: Tests-ul.318 Ancestors: Tests-topa.317 Added some tests for ThirtyTwoBitRegister. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007900.html Name: System-ul.720 Ancestors: System-mt.719 Added left and right shifts, multiplication, load from register, and comparision operators to ThirtyTwoBitRegister. Also implmenented #hash, and added #asSignedInteger. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007901.html Name: ToolBuilder-Kernel-mt.74 Ancestors: ToolBuilder-Kernel-mt.73 New preference for opening tools. Custom tool builders may consider mouse activity and thus spawn new tools directly under the mouse cursor or attached to it. Disabled by default. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007902.html Name: ToolBuilder-Morphic-mt.122 Ancestors: ToolBuilder-Morphic-mt.121 If the preference #openToolsAttachedToMouseCursor is enabled, the morphic tool builder will attach any system window to the hand if the current event is a mouse event. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007903.html Name: Morphic-mt.858 Ancestors: Morphic-mt.857 Remove special behavior for tool-opening at the hand when inspecting or exploring morphs via the halo context menu. Use the preference #openToolsAttachedToMouseCursor if you want that behavior. Then, you will have it not only in those two cases but for any mouse-invoked tool opening. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007904.html Name: Morphic-mt.859 Ancestors: Morphic-mt.858 Safety-check added when spawning balloons. There is one when starting the alarm/timer, but we need one when actually showing the balloon because #wantsBalloon may have changed until then. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007905.html Name: ToolBuilder-Morphic-mt.123 Ancestors: ToolBuilder-Morphic-mt.122 Due to the variety of mouse events and the high frequency of mouse-move events in particular, only spawn a new tool at the hand if preference is enabled and the current/last event was mouse-up, e.g. button or menu click. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007906.html Name: Morphic-mt.860 Ancestors: Morphic-mt.859 Fixed bug where switching from an MVC project back to a Morphic project did fail. (This bug was related to the Morphic drawing routine and keyboard-focus highlight.) ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007907.html Name: ST80-mt.178 Ancestors: ST80-mt.177 Changed window color for MVC projects in morphic to white to compensate the removal of a former system-window hack. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007908.html Name: Morphic-mt.861 Ancestors: Morphic-mt.860 Changed window color for morphic projects in morphic to default uniform window color to compensate the removal of a former system-window hack. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007909.html Name: Collections-ul.616 Ancestors: Collections-bf.615 Optimized Interval >> #sum, OrderedCollection >> #at: and OrderedCollection >> #at:put:. ============================================= From commits at source.squeak.org Sun Apr 12 01:52:45 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 01:52:46 2015 Subject: [squeak-dev] The Trunk: Collections-ul.617.mcz Message-ID: Levente Uzonyi uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections-ul.617.mcz ==================== Summary ==================== Name: Collections-ul.617 Author: ul Time: 12 April 2015, 2:59:01.46 am UUID: 483f2798-971c-4066-8b82-4a2271420294 Ancestors: Collections-ul.616 LRUCache changes: - added a #reset method, which removes all elements from the cache - replaced the Arrays storing the list of elements with custom classes (LRUCacheHeadNode and LRUCacheNode). - fix: the map variable gets correctly updated, when the cache is full =============== Diff against Collections-ul.616 =============== Item was changed: Object subclass: #LRUCache instanceVariableNames: 'map head calls hits size factory' classVariableNames: '' poolDictionaries: '' category: 'Collections-Cache'! + !LRUCache commentStamp: 'ul 4/12/2015 02:55' prior: 0! - !LRUCache commentStamp: 'ul 11/23/2013 22:20' prior: 0! I'm a cache of values, given a key I return a Value from the cache or from the factory. + I use a Dictionary to find the corresponding value for the given key. I also store the key-value pairs in a circular doubly-linked list with a head element. The list is implemented by an LRUCacheHeadNode - stored in the head instance variable - and an LRUCacheNode for each key-value pair. The nodes in the list are ordered by access time. The first node (next of head) is the most recently accessed, the last one (previous of head) is the least recently accessed. + If the number of stored key-value pairs is equal to size, and a new pair needs to be stored, then I remove the least recently used pair before adding the new pair.! - I use map (a Dictionary) to find the corresponding value to the given key. I store the values in nodes, which are arrays of size 4. Together with head the nodes form a circular doubly-linked list with a head element. - The first element of a list node is the next list node, the second element is the previous list node. The third element (if exists) is the key, the fourth (if exists) is the value for the given key. - The nodes in the list are ordered by access time. The first node is the most recently accessed, the last one is the least recently accessed.! Item was changed: ----- Method: LRUCache>>at: (in category 'accessing') ----- at: aKey "answer the object for aKey, if not present in the cache creates it" + head class == LRUCacheHeadNode ifFalse: [ self reset ]. calls := calls + 1. ^map at: aKey ifPresent: [ :node | hits := hits + 1. + head next == node ifFalse: [ + node + unlink; + linkAfter: head ]. + node value ] - self - unlink: node; - moveToFirst: node. - node at: 4 ] ifAbsent: [ | node | map size = size ifTrue: [ + node := head previous. + node unlink. + map removeKey: node key. ] + ifFalse: [ node := LRUCacheNode new ]. + node linkAfter: head. - node := head at: 2. - self unlink: node ] - ifFalse: [ - node := Array new: 4 ]. - self moveToFirst: node. map at: aKey put: node. node + key: aKey; + value: (factory value: aKey); + value ]! - at: 3 put: aKey; - at: 4 put: (factory value: aKey) ]! Item was changed: ----- Method: LRUCache>>initializeSize:factory: (in category 'initialization') ----- initializeSize: anInteger factory: aBlock "initialize the receiver's size and factory" anInteger strictlyPositive ifFalse: [ self error: 'Size must be at least 1' ]. size := anInteger. + head := LRUCacheHeadNode new. - head := Array new: 2. - head - at: 1 put: head; - at: 2 put: head. map := PluggableDictionary integerDictionary. factory := aBlock. calls := 0. hits := 0! Item was added: + ----- Method: LRUCache>>reset (in category 'initialization') ----- + reset + + self initializeSize: size factory: factory! Item was added: + Object subclass: #LRUCacheHeadNode + instanceVariableNames: 'next previous' + classVariableNames: '' + poolDictionaries: '' + category: 'Collections-Cache'! Item was added: + ----- Method: LRUCacheHeadNode>>initialize (in category 'initialize-release') ----- + initialize + + previous := next := self! Item was added: + ----- Method: LRUCacheHeadNode>>next (in category 'accessing') ----- + next + + ^next! Item was added: + ----- Method: LRUCacheHeadNode>>next: (in category 'accessing') ----- + next: anObject + + next := anObject! Item was added: + ----- Method: LRUCacheHeadNode>>previous (in category 'accessing') ----- + previous + + ^previous! Item was added: + ----- Method: LRUCacheHeadNode>>previous: (in category 'accessing') ----- + previous: anObject + + previous := anObject! Item was added: + LRUCacheHeadNode subclass: #LRUCacheNode + instanceVariableNames: 'key value' + classVariableNames: '' + poolDictionaries: '' + category: 'Collections-Cache'! Item was added: + ----- Method: LRUCacheNode>>key (in category 'accessing') ----- + key + + ^key! Item was added: + ----- Method: LRUCacheNode>>key: (in category 'accessing') ----- + key: anObject + + key := anObject! Item was added: + ----- Method: LRUCacheNode>>linkAfter: (in category 'list operations') ----- + linkAfter: anLRUCacheHeadNode + + next := anLRUCacheHeadNode next. + previous := anLRUCacheHeadNode. + next previous: self. + previous next: self! Item was added: + ----- Method: LRUCacheNode>>printOn: (in category 'accessing') ----- + printOn: stream + + super printOn: stream. + stream + nextPut: $(; + print: key; + nextPutAll: ', '; + print: value; + nextPut: $)! Item was added: + ----- Method: LRUCacheNode>>unlink (in category 'list operations') ----- + unlink + + next previous: previous. + previous next: next. + next := previous := nil! Item was added: + ----- Method: LRUCacheNode>>value (in category 'accessing') ----- + value + + ^value! Item was added: + ----- Method: LRUCacheNode>>value: (in category 'accessing') ----- + value: anObject + + value := anObject! From unoduetre at poczta.onet.pl Sun Apr 12 04:16:22 2015 From: unoduetre at poczta.onet.pl (Mateusz Grotek) Date: Sun Apr 12 04:05:26 2015 Subject: [squeak-dev] Two bugs. One of them is a regression. Message-ID: <1428812182.17235.0@mglap> I've found two bugs in the current Squeak 4.5 #13712. Please tell me if they're known. If not I'll create the tickets. Firstly, there is a regression. 1. Create a class called (for example) ABC. 2. Add an instance variable called (for example) xyz. 3. Open the class comment panel (click on the button "?"). 4. The contents of it is: An ABC is xxxxxxxxx. Instance Variables xyz:[TAB][TAB] xyz - xxxxx 5. Remove the [TAB]s 6. Accept it 7. An unrecoverable error shows up (after performing steps above it keeps appearing when accessing the ABC class): Error: RemoteString past end of file The error comes from RemoteString>>text Secondly there is a funny bug with UserDialogBoxMorph (and possibly other modal windows). 1. Evaluate: UserDialogBoxMorph inform: 'Hello World!'. 2. The dialog box should be modal, and it is, but one can hack it. Just drag the "OK" button (but move the mouse outside the button). (mouse down on the "OK" button, mouse move outside the "OK" button, mouse up). Other modal windows can be affected too. From unoduetre at poczta.onet.pl Sun Apr 12 04:17:34 2015 From: unoduetre at poczta.onet.pl (Mateusz Grotek) Date: Sun Apr 12 04:06:24 2015 Subject: [squeak-dev] A bug with class renaming In-Reply-To: <2C2C105F-5886-45EA-9F13-2791E1361242@gmx.de> (from Das.Linux@gmx.de on Fri Apr 10 23:08:34 2015) References: <839D9F43-C05C-4009-BCE4-E976E15B0BE2@gmx.de> <1427990360.17970.0@mglap> <1428155228.3951.0@mglap> <2C2C105F-5886-45EA-9F13-2791E1361242@gmx.de> Message-ID: <1428812254.17235.1@mglap> Dnia 10.04.2015 23:08:34, Tobias Pape napisa?(a): > Hi, > On 04.04.2015, at 15:47, Mateusz Grotek > wrote: > > > I've opened a ticket for it: #0007827 > > Sorry for taking so long. > I reproduced it. > For Squeak-4.5 I fixed it in Kernel-topa.845. > Please see if your problem is gone :) > > Best > -Tobias > > Yup! Your hotfix has solved it. Great job. Best wishes, Mateusz From unoduetre at poczta.onet.pl Sun Apr 12 04:33:04 2015 From: unoduetre at poczta.onet.pl (Mateusz Grotek) Date: Sun Apr 12 04:22:24 2015 Subject: [squeak-dev] A bug with class renaming In-Reply-To: <1428812254.17235.1@mglap> (from unoduetre@poczta.onet.pl on Sun Apr 12 06:17:34 2015) References: <839D9F43-C05C-4009-BCE4-E976E15B0BE2@gmx.de> <1427990360.17970.0@mglap> <1428155228.3951.0@mglap> <2C2C105F-5886-45EA-9F13-2791E1361242@gmx.de> <1428812254.17235.1@mglap> Message-ID: <1428813184.17235.2@mglap> Dnia 12.04.2015 06:17:34, Mateusz Grotek napisa?(a): > Dnia 10.04.2015 23:08:34, Tobias Pape napisa?(a): >> Hi, >> On 04.04.2015, at 15:47, Mateusz Grotek >> wrote: >> >> > I've opened a ticket for it: #0007827 >> >> Sorry for taking so long. >> I reproduced it. >> For Squeak-4.5 I fixed it in Kernel-topa.845. >> Please see if your problem is gone :) >> >> Best >> -Tobias >> >> > > Yup! Your hotfix has solved it. Great job. > > Best wishes, > Mateusz > > Please close the ticket. From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 12 10:33:27 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 12 10:46:26 2015 Subject: [squeak-dev] Re: Two bugs. One of them is a regression. In-Reply-To: <1428812182.17235.0@mglap> References: <1428812182.17235.0@mglap> Message-ID: <1428834807779-4819138.post@n4.nabble.com> The modality in the UserDialogBoxMorph is implemented via holding both mouse and keyboard focus. The halo takes the mouse focus away when growing or dragging a morph--without signaling it to the former focus holder. After that, the modal behavior is lost. However, the dialog is still useful as long as it is in the world because it still triggers a world's sub-cycle. I guess that it is okay to hack it via halos for debugging reasons. :) Best, Marcel -- View this message in context: http://forum.world.st/Two-bugs-One-of-them-is-a-regression-tp4819111p4819138.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Sun Apr 12 10:51:02 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 10:51:04 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.863.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.863.mcz ==================== Summary ==================== Name: Morphic-mt.863 Author: mt Time: 12 April 2015, 12:50:26.767 pm UUID: 543a4df8-0000-3541-9f10-ed7eec81f389 Ancestors: Morphic-ul.862 Help text for search bar updated. =============== Diff against Morphic-ul.862 =============== Item was changed: ----- Method: SearchBar>>buildWith: (in category 'toolbuilder') ----- buildWith: builder ^ (builder build: (builder pluggableInputFieldSpec new model: self; getText: #searchTerm; setText: #smartSearch:in:; editText: #searchTermSilently:; menu: #menu:shifted:; selection: #selection; + help: 'Search or evaluate...' translated)) - help: 'Search...' translated)) name: #searchBar; wantsFrameAdornments: false; borderWidth: 0; yourself! From commits at source.squeak.org Sun Apr 12 11:05:33 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 11:05:36 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.864.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.864.mcz ==================== Summary ==================== Name: Morphic-mt.864 Author: mt Time: 12 April 2015, 1:05:00.466 pm UUID: 549e612e-dfdf-2a42-a0ef-fb2219ce0eea Ancestors: Morphic-mt.863 Let system windows release mouse and keyboard focus the correct way to give current focus holders a chance to update. Note: #releaseAllFoci is for internal use in HandMorph only. =============== Diff against Morphic-mt.863 =============== Item was changed: ----- Method: SystemWindow>>openAsIsIn: (in category 'open/close') ----- openAsIsIn: aWorld "This msg and its callees result in the window being activeOnlyOnTop" aWorld addMorph: self. self activate. aWorld startSteppingSubmorphsOf: self. + self activeHand + releaseKeyboardFocus; + releaseMouseFocus.! - self activeHand releaseAllFoci! Item was changed: ----- Method: SystemWindow>>openInWorld: (in category 'open/close') ----- openInWorld: aWorld "This msg and its callees result in the window being activeOnlyOnTop" [^ self anyOpenWindowLikeMe ifEmpty: [ self bounds: (RealEstateAgent initialFrameFor: self world: aWorld) ; openAsIsIn: aWorld ] ifNotEmptyDo: [ : windows | windows anyOne expand ; activate ; postAcceptBrowseFor: self ]. + ] ensure: [ + self activeHand + releaseKeyboardFocus; + releaseMouseFocus. ]! - ] ensure: [ self activeHand releaseAllFoci ]! Item was changed: ----- Method: SystemWindow>>openInWorld:extent: (in category 'open/close') ----- openInWorld: aWorld extent: extent "This msg and its callees result in the window being activeOnlyOnTop" [^ self anyOpenWindowLikeMe ifEmpty: [ self position: (RealEstateAgent initialFrameFor: self initialExtent: extent world: aWorld) topLeft ; extent: extent. self openAsIsIn: aWorld ] ifNotEmptyDo: [ : windows | windows anyOne expand ; activate ; postAcceptBrowseFor: self ]. + ] ensure: [ + self activeHand + releaseKeyboardFocus; + releaseMouseFocus. ]! - ] ensure: [ self activeHand releaseAllFoci ]! From unoduetre at poczta.onet.pl Sun Apr 12 12:46:46 2015 From: unoduetre at poczta.onet.pl (Mateusz Grotek) Date: Sun Apr 12 12:35:51 2015 Subject: [SPAM] [squeak-dev] Re: Two bugs. One of them is a regression. In-Reply-To: <1428834807779-4819138.post@n4.nabble.com> (from marcel.taeumel@student.hpi.uni-potsdam.de on Sun Apr 12 12:33:27 2015) References: <1428812182.17235.0@mglap> <1428834807779-4819138.post@n4.nabble.com> Message-ID: <1428842806.17235.4@mglap> Dnia 12.04.2015 12:33:27, Marcel Taeumel napisa?(a): > The modality in the UserDialogBoxMorph is implemented via holding > both mouse > and keyboard focus. The halo takes the mouse focus away when growing > or > dragging a morph--without signaling it to the former focus holder. > After > that, the modal behavior is lost. However, the dialog is still useful > as > long as it is in the world because it still triggers a world's > sub-cycle. > > I guess that it is okay to hack it via halos for debugging reasons. :) > > Best, > Marcel > I did not mention the halo, and the bug is there without activating it. Is it related nevertheless? Of course halos should be allowed to break the modality. Do halos really have something to do with it? From commits at source.squeak.org Sun Apr 12 12:52:55 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 12:52:56 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.865.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.865.mcz ==================== Summary ==================== Name: Morphic-mt.865 Author: mt Time: 12 April 2015, 2:52:20.375 pm UUID: 68261d42-569e-3040-9d0d-fd6be8699f67 Ancestors: Morphic-mt.864 Add highlight for the matching filter term in lists. It is cached like icons and items are. Why useful? If you do not reset the filter automatically, it is now easier to recognize after which term the list is filtered. It also makes the existing filter adaption visible, which tries to avoid empty results. =============== Diff against Morphic-mt.864 =============== Item was changed: Morph subclass: #LazyListMorph + instanceVariableNames: 'listItems listIcons listFilterOffsets font selectedRow selectedRows preSelectedRow listSource maxWidth' - instanceVariableNames: 'listItems listIcons font selectedRow selectedRows preSelectedRow listSource maxWidth' classVariableNames: 'ListPreSelectionColor ListSelectionColor ListSelectionTextColor' poolDictionaries: '' category: 'Morphic-Widgets'! !LazyListMorph commentStamp: 'efc 8/6/2005 11:34' prior: 0! The morph that displays the list in a PluggableListMorph. It is "lazy" because it will only request the list items that it actually needs to display. I will cache the maximum width of my items in maxWidth to avoid this potentially expensive and frequent computation.! Item was added: + ----- Method: LazyListMorph class>>listFilterHighlightColor (in category 'preferences') ----- + listFilterHighlightColor + + ^ Color yellow paler alpha: 0.5! Item was changed: ----- Method: LazyListMorph>>display:atRow:on: (in category 'drawing') ----- display: item atRow: row on: canvas "display the given item at row row" | drawBounds emphasized rowColor itemAsText | itemAsText := item asStringOrText. + + "If it is a text, we will only use the first character's emphasis." emphasized := itemAsText isText ifTrue: [font emphasized: (itemAsText emphasisAt: 1)] ifFalse: [font]. + rowColor := self colorForRow: row. + drawBounds := (self drawBoundsForRow: row) translateBy: (self hMargin @ 0). drawBounds := drawBounds intersect: self bounds. + + "Draw icon if existing. Adjust draw bounds in that case." + (self icon: row) ifNotNil: [ :icon || top | - (self icon: row) ifNotNil: - [ :icon || top | top := drawBounds top + ((drawBounds height - icon height) // 2). canvas translucentImage: icon at: drawBounds left @ top. drawBounds := drawBounds left: drawBounds left + icon width + 2 ]. + + "Draw filter matches if any." + (self filterOffsets: row) do: [:offset | + canvas + frameAndFillRoundRect: ((drawBounds left + offset first) @ drawBounds top corner: (drawBounds left + offset last) @ drawBounds bottom) + radius: 3 + fillStyle: self class listFilterHighlightColor + borderWidth: 1 + borderColor: self class listFilterHighlightColor twiceDarker]. + + "We will only draw strings here." + canvas + drawString: itemAsText asString + in: drawBounds + font: emphasized + color: rowColor.! - canvas drawString: itemAsText in: drawBounds font: emphasized color: rowColor! Item was changed: ----- Method: LazyListMorph>>drawOn: (in category 'drawing') ----- drawOn: aCanvas + + | topRow bottomRow | + listItems ifEmpty: [ ^self ]. - | | - listItems size = 0 ifTrue: [ ^self ]. self drawPreSelectionOn: aCanvas; drawSelectionOn: aCanvas. + topRow := self topVisibleRowForCanvas: aCanvas. + bottomRow := self bottomVisibleRowForCanvas: aCanvas. - (self topVisibleRowForCanvas: aCanvas) to: (self bottomVisibleRowForCanvas: aCanvas) do: [ :row | - (listSource itemSelectedAmongMultiple: row) ifTrue: [ - self drawBackgroundForMulti: row on: aCanvas. ]]. + "Draw multi-selection." + topRow to: bottomRow do: [ :row | + (listSource itemSelectedAmongMultiple: row) ifTrue: [ + self drawBackgroundForMulti: row on: aCanvas ] ]. + + "Draw hovered row if preference enabled." PluggableListMorph highlightHoveredRow ifTrue: [ listSource hoverRow > 0 ifTrue: [ self highlightHoverRow: listSource hoverRow on: aCanvas ] ]. + "Draw all visible rows." + topRow to: bottomRow do: [ :row | + self display: (self item: row) atRow: row on: aCanvas ]. - (self topVisibleRowForCanvas: aCanvas) to: (self bottomVisibleRowForCanvas: aCanvas) do: [ :row | - self display: (self item: row) atRow: row on: aCanvas. - ]. + "Finally, highlight drop row for drag/drop operations.." listSource potentialDropRow > 0 ifTrue: [ self highlightPotentialDropRow: listSource potentialDropRow on: aCanvas ].! Item was added: + ----- Method: LazyListMorph>>filterOffsets: (in category 'list access') ----- + filterOffsets: row + "Get the character offsets for the matching filter term." + + | indexes | + "Migrate old instances if necessary." + listFilterOffsets ifNil: [listFilterOffsets := Array new: listItems size]. + + row <= listFilterOffsets size ifFalse: [ + ^ self getFilterOffsets: row]. + + (indexes := listFilterOffsets at: row) ifNil: [ + indexes := self getFilterOffsets: row. + listFilterOffsets at: row put: indexes ]. + + ^ indexes! Item was changed: ----- Method: LazyListMorph>>font: (in category 'drawing') ----- font: newFont font := (newFont ifNil: [ TextStyle default defaultFont ]). self adjustHeight. + listFilterOffsets := Array new: self getListSize withAll: nil. self changed.! Item was added: + ----- Method: LazyListMorph>>getFilterOffsets: (in category 'list access') ----- + getFilterOffsets: row + "Calculate matching character indexes for the current filter term." + + | item filter filterWidth offsets currentIndex | + filter := listSource filterTerm. + filter ifEmpty: [^ Array empty]. + filterWidth := font widthOfString: filter. + + item := self item: row. + offsets := OrderedCollection new. + + currentIndex := 1. + [currentIndex > 0] whileTrue: [ + currentIndex := item findString: filter startingAt: currentIndex caseSensitive: false. + currentIndex > 0 ifTrue: [ | left | + left := font widthOfString: item from: 1 to: currentIndex-1. + offsets addLast: (left to: left + filterWidth). + currentIndex := currentIndex + 1] ]. + ^ offsets! Item was added: + ----- Method: LazyListMorph>>getListIcon: (in category 'list access') ----- + getListIcon: row + "Grab icon directly from the model." + + ^ listSource iconAt: row + ! Item was changed: + ----- Method: LazyListMorph>>icon: (in category 'list access') ----- - ----- Method: LazyListMorph>>icon: (in category 'accessing') ----- icon: row + | icon | + "Migrate old instances if necessary." listIcons ifNil: [listIcons := Array new: listItems size]. + + row <= listIcons size ifFalse: [ + ^ self getListIcon: row]. + + (icon := listIcons at: row) ifNil: [ + icon := self getListIcon: row. + listIcons at: row put: icon ]. + - row <= listIcons size ifFalse: [^ listSource iconAt: row]. - icon := listIcons at: row. - icon ifNil: - [icon := listSource iconAt: row. - listIcons at: row put: icon]. ^ icon! Item was changed: ----- Method: LazyListMorph>>initialize (in category 'initialization') ----- initialize super initialize. self color: Color black. font := Preferences standardListFont. listItems := #(). listIcons := #(). + listFilterOffsets := #(). selectedRow := nil. selectedRows := PluggableSet integerSet. preSelectedRow := nil. self adjustHeight.! Item was changed: ----- Method: LazyListMorph>>listChanged (in category 'list management') ----- listChanged "set newList to be the list of strings to display" | size | size := self getListSize. listItems := Array new: size withAll: nil. listIcons := Array new: size withAll: nil. + listFilterOffsets := Array new: size withAll: nil. maxWidth := nil. selectedRow := nil. selectedRows := PluggableSet integerSet. preSelectedRow := nil. self adjustHeight. self adjustWidth. self changed. ! Item was added: + ----- Method: PluggableListMorph>>filterTerm (in category 'filtering') ----- + filterTerm + ^ lastKeystrokes ifNil: ['']! From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 12 12:42:04 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 12 12:55:04 2015 Subject: [SPAM] [squeak-dev] Re: Two bugs. One of them is a regression. In-Reply-To: <1428842806.17235.4@mglap> References: <1428812182.17235.0@mglap> <1428834807779-4819138.post@n4.nabble.com> <1428842806.17235.4@mglap> Message-ID: <1428842524495-4819148.post@n4.nabble.com> Hmm... how did you then drag the OK button? I assumed via halo. :) Best, Marcel -- View this message in context: http://forum.world.st/Two-bugs-One-of-them-is-a-regression-tp4819111p4819148.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 12 12:42:43 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 12 12:55:42 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.865.mcz In-Reply-To: References: Message-ID: <1428842563120-4819149.post@n4.nabble.com> Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-865-mcz-tp4819147p4819149.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 12 12:45:19 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 12 12:58:17 2015 Subject: [SPAM] [squeak-dev] Re: Two bugs. One of them is a regression. In-Reply-To: <1428842524495-4819148.post@n4.nabble.com> References: <1428812182.17235.0@mglap> <1428834807779-4819138.post@n4.nabble.com> <1428842806.17235.4@mglap> <1428842524495-4819148.post@n4.nabble.com> Message-ID: <1428842719264-4819150.post@n4.nabble.com> Ah, just drag. Literally. :D Hmmm..... Best, Marcel -- View this message in context: http://forum.world.st/Two-bugs-One-of-them-is-a-regression-tp4819111p4819150.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From karlramberg at gmail.com Sun Apr 12 13:17:16 2015 From: karlramberg at gmail.com (karl ramberg) Date: Sun Apr 12 13:17:18 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.865.mcz In-Reply-To: <1428842563120-4819149.post@n4.nabble.com> References: <1428842563120-4819149.post@n4.nabble.com> Message-ID: Nice Karl On Sun, Apr 12, 2015 at 2:42 PM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > > > Best, > Marcel > > > > -- > View this message in context: > http://forum.world.st/The-Trunk-Morphic-mt-865-mcz-tp4819147p4819149.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150412/d0cd2a1b/attachment.htm From karlramberg at gmail.com Sun Apr 12 13:22:06 2015 From: karlramberg at gmail.com (karl ramberg) Date: Sun Apr 12 13:22:08 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.865.mcz In-Reply-To: <1428842563120-4819149.post@n4.nabble.com> References: <1428842563120-4819149.post@n4.nabble.com> Message-ID: A little off topic: Where can I get info for what the icons in the list in the browser means ? Karl On Sun, Apr 12, 2015 at 2:42 PM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > > > Best, > Marcel > > > > -- > View this message in context: > http://forum.world.st/The-Trunk-Morphic-mt-865-mcz-tp4819147p4819149.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150412/e9ed7c6e/attachment.htm From commits at source.squeak.org Sun Apr 12 13:25:16 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 13:25:19 2015 Subject: [squeak-dev] The Trunk: Kernel-mt.918.mcz Message-ID: Marcel Taeumel uploaded a new version of Kernel to project The Trunk: http://source.squeak.org/trunk/Kernel-mt.918.mcz ==================== Summary ==================== Name: Kernel-mt.918 Author: mt Time: 12 April 2015, 3:24:52.584 pm UUID: ed5d1308-7dda-b24f-a6fa-9f1eae8070d8 Ancestors: Kernel-bf.917 Added a non-specific way to access all elements from a categorizer. =============== Diff against Kernel-bf.917 =============== Item was added: + ----- Method: Categorizer>>allElements (in category 'accessing') ----- + allElements + + ^ elementArray copy! Item was changed: ----- Method: Categorizer>>allMethodSelectors (in category 'accessing') ----- allMethodSelectors "give a list of all method selectors." + ^ self allElements sort! - ^ elementArray copy sort! From commits at source.squeak.org Sun Apr 12 13:26:33 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 13:26:35 2015 Subject: [squeak-dev] The Trunk: Tools-mt.580.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.580.mcz ==================== Summary ==================== Name: Tools-mt.580 Author: mt Time: 12 April 2015, 3:26:07.168 pm UUID: 5dbc59ee-fa25-794e-a41b-9f4ee5c79a63 Ancestors: Tools-topa.579 For the sake of consistency, added '-- all --' category to the list of system categories. Skipped creation of class hierarchy in that case. Too slow.... =============== Diff against Tools-topa.579 =============== Item was changed: ----- Method: Browser>>defaultClassList (in category 'class list') ----- defaultClassList "Answer an array of the class names of the selected category. Answer an empty array if no selection exists." ^ self hasSystemCategorySelected + ifFalse: [Array new] + ifTrue: [self selectedSystemCategory = SystemOrganizer allCategory + ifTrue: [systemOrganizer allElements sort] + ifFalse: [systemOrganizer listAtCategoryNamed: self selectedSystemCategory]] + ! - ifTrue: [systemOrganizer listAtCategoryNamed: self selectedSystemCategory] - ifFalse: [Array new].! Item was changed: ----- Method: Browser>>hierarchicalClassList (in category 'class list') ----- hierarchicalClassList "classNames are an arbitrary collection of classNames of the system. Reorder those class names so that they are sorted and indended by inheritance" | classes | + "Creating the hierarchy is *really slow* for the full class list. Skip it for now." + self selectedSystemCategory = SystemOrganizer allCategory + ifTrue: [^ self defaultClassList]. + classes := self defaultClassList collect: [:sym | Smalltalk classNamed: sym]. ^ self flattenHierarchyTree: (self createHierarchyTreeOf: classes) on: OrderedCollection new indent: ''.! Item was changed: ----- Method: Browser>>systemCategoryList (in category 'system category list') ----- systemCategoryList "Answer the class categories modelled by the receiver." + ^ {SystemOrganizer allCategory}, systemOrganizer categories! - ^systemOrganizer categories! From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 12 13:16:01 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 12 13:28:58 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.865.mcz In-Reply-To: References: <1428842563120-4819149.post@n4.nabble.com> Message-ID: <1428844561257-4819155.post@n4.nabble.com> For now, just in Behavor >> #toolIconSelector:, which will be called from ToolIcons >> #iconForClass:selector:. Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-865-mcz-tp4819147p4819155.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Sun Apr 12 13:45:24 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 13:45:26 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.866.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.866.mcz ==================== Summary ==================== Name: Morphic-mt.866 Author: mt Time: 12 April 2015, 3:44:51.855 pm UUID: f59e94d0-28a4-8841-a25c-2db073d92d40 Ancestors: Morphic-mt.865 Fix for filter highlight: Now correctly converts items into strings just like the display-routine does. =============== Diff against Morphic-mt.865 =============== Item was changed: ----- Method: LazyListMorph>>getFilterOffsets: (in category 'list access') ----- getFilterOffsets: row "Calculate matching character indexes for the current filter term." | item filter filterWidth offsets currentIndex | filter := listSource filterTerm. filter ifEmpty: [^ Array empty]. filterWidth := font widthOfString: filter. + item := (self item: row) asStringOrText asString. "See row drawing. Strings only." - item := self item: row. offsets := OrderedCollection new. currentIndex := 1. [currentIndex > 0] whileTrue: [ currentIndex := item findString: filter startingAt: currentIndex caseSensitive: false. currentIndex > 0 ifTrue: [ | left | left := font widthOfString: item from: 1 to: currentIndex-1. offsets addLast: (left to: left + filterWidth). currentIndex := currentIndex + 1] ]. ^ offsets! From karlramberg at gmail.com Sun Apr 12 14:02:00 2015 From: karlramberg at gmail.com (karl ramberg) Date: Sun Apr 12 14:02:02 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.865.mcz In-Reply-To: <1428844561257-4819155.post@n4.nabble.com> References: <1428842563120-4819149.post@n4.nabble.com> <1428844561257-4819155.post@n4.nabble.com> Message-ID: Thanks Karl On Sun, Apr 12, 2015 at 3:16 PM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > For now, just in Behavor >> #toolIconSelector:, which will be called from > ToolIcons >> #iconForClass:selector:. > > Best, > Marcel > > > > -- > View this message in context: > http://forum.world.st/The-Trunk-Morphic-mt-865-mcz-tp4819147p4819155.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150412/a52b45b3/attachment.htm From commits at source.squeak.org Sun Apr 12 14:43:45 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 14:43:47 2015 Subject: [squeak-dev] The Trunk: Tools-mt.581.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.581.mcz ==================== Summary ==================== Name: Tools-mt.581 Author: mt Time: 12 April 2015, 4:43:28.671 pm UUID: 6b7d43e3-76f0-3241-aee8-84b532a1c45e Ancestors: Tools-mt.580 For Bert: Added a button to easily switch between inspector and object explorer. =============== Diff against Tools-mt.580 =============== Item was changed: ----- Method: Inspector>>buildCodePaneWith: (in category 'toolbuilder') ----- buildCodePaneWith: builder | textSpec | textSpec := builder pluggableTextSpec new. textSpec model: self; getText: #trash; + setText: #trash:; + help: #helpText; - setText: #trash:; selection: #contentsSelection; menu: #codePaneMenu:shifted:; askBeforeDiscardingEdits: false. ^textSpec! Item was added: + ----- Method: Inspector>>buildExploreButtonWith: (in category 'toolbuilder') ----- + buildExploreButtonWith: builder + + ^ builder pluggableButtonSpec new + model: self; + label: 'explore'; + action: #exploreObject; + help: 'Switch to an explorer tool'! Item was changed: ----- Method: Inspector>>buildValuePaneWith: (in category 'toolbuilder') ----- buildValuePaneWith: builder | textSpec | textSpec := builder pluggableTextSpec new. textSpec model: self; getText: #contents; setText: #accept:; + help: 'Select a field on the left.'; selection: #contentsSelection; menu: #codePaneMenu:shifted:. ^textSpec! Item was changed: ----- Method: Inspector>>buildWith: (in category 'toolbuilder') ----- buildWith: builder "Inspector openOn: SystemOrganization" + | windowSpec buttonOffset | + buttonOffset := (Preferences standardButtonFont widthOfString: 'explore') * 3/2. - | windowSpec | windowSpec := self buildWindowWith: builder specs: { + (0@0 corner: 0.3@0.75) -> [self buildFieldListWith: builder]. + (0.3@0.0corner: 1@0.75) -> [self buildValuePaneWith: builder]. + (LayoutFrame fractions: (0@0.75 corner: 1@1) offsets: (0@0 corner: buttonOffset negated@0)) -> [self buildCodePaneWith: builder]. + (LayoutFrame fractions: (1@0.75 corner: 1@1) offsets: (buttonOffset negated@0 corner: 0 @ 0)) -> [self buildExploreButtonWith: builder]. - (0@0 corner: 0.3@0.7) -> [self buildFieldListWith: builder]. - (0.3@0.0corner: 1@0.7) -> [self buildValuePaneWith: builder]. - (0.0@0.7corner: 1@1) -> [self buildCodePaneWith: builder]. }. + windowSpec extent: self initialExtent. ^builder build: windowSpec! Item was added: + ----- Method: Inspector>>exploreObject (in category 'toolbuilder') ----- + exploreObject + "Switch to an explorer tool." + + self object explore + bounds: self containingWindow bounds. + self changed: #close.! Item was added: + ----- Method: Inspector>>helpText (in category 'accessing') ----- + helpText + + ^ 'Evaluate expressions for ''{1}'' here...' format: {self object printStringLimitedTo: 20}! Item was changed: ----- Method: Inspector>>initialExtent (in category 'accessing') ----- initialExtent "Answer the desired extent for the receiver when it is first opened on the screen. " + ^ 350 @ 250! - ^ 250 @ 200! Item was changed: ----- Method: Inspector>>object: (in category 'accessing') ----- object: anObject "Set anObject to be the object being inspected by the receiver." | oldIndex | anObject == object ifTrue: [self update] ifFalse: [oldIndex := selectionIndex <= 2 ifTrue: [selectionIndex] ifFalse: [0]. self inspect: anObject. oldIndex := oldIndex min: self fieldList size. self changed: #inspectObject. oldIndex > 0 ifTrue: [self toggleIndex: oldIndex]. self changed: #fieldList. + self changed: #contents. + self changed: #helpText]! - self changed: #contents]! Item was changed: ----- Method: Object>>inspect (in category '*Tools-inspecting') ----- inspect "Create and schedule an Inspector in which the user can examine the receiver's variables." + ^ ToolSet inspect: self! - ToolSet inspect: self! Item was changed: ----- Method: ObjectExplorer>>buildWith: (in category 'toolbuilder') ----- buildWith: builder + | windowSpec treeSpec textSpec buttonSpec buttonOffset | - | windowSpec treeSpec textSpec | windowSpec := builder pluggableWindowSpec new. windowSpec model: self; children: OrderedCollection new; + label: #label; + extent: self initialExtent. + - label: #label. - treeSpec := builder pluggableTreeSpec new. treeSpec model: self; nodeClass: self class nodeClass; roots: #getList; keyPress: #explorerKey:from:event:; getSelected: #currentSelection; setSelected: #currentSelection:; setSelectedParent: #currentParent:; menu: #genericMenu:; autoDeselect: false; columns: (ObjectExplorerWrapper showContentsInColumns ifTrue: [{ [:listMorph | (listMorph filteredItems collect: [:item | item preferredWidthOfColumn: 1]) max]. nil "take all the space"}]); + frame: (0@0 corner: 1@0.75). - frame: (0@0 corner: 1@0.85). windowSpec children add: treeSpec. + buttonOffset := (Preferences standardButtonFont widthOfString: 'inspect') * 3/2. + textSpec := builder pluggableTextSpec new. textSpec model: self; menu: #codePaneMenu:shifted:; help: 'Evaluate expressions for the current tree selection...' translated; + frame: (LayoutFrame fractions: (0@0.75 corner: 1@1) offsets: (0@0 corner: buttonOffset negated@0)). - frame: (0@0.85 corner: 1@1). windowSpec children add: textSpec. + buttonSpec := builder pluggableButtonSpec new + model: self; + label: 'inspect'; + action: #inspectObject; + help: 'Switch to an inspector tool'; + frame: (LayoutFrame fractions: (1@0.75 corner: 1@1) offsets: (buttonOffset negated@0 corner: 0 @ 0)). + windowSpec children add: buttonSpec. + [^ builder build: windowSpec] ensure: [self changed: #expandRootsRequested]! Item was changed: ----- Method: ObjectExplorer>>initialExtent (in category 'user interface') ----- initialExtent + ^350@250! - ^400@400! Item was added: + ----- Method: ObjectExplorer>>inspectObject (in category 'toolbuilder') ----- + inspectObject + "Switch to an inspector tool." + + self object inspect + bounds: self containingWindow bounds. + self changed: #close.! From commits at source.squeak.org Sun Apr 12 14:56:48 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 14:56:50 2015 Subject: [squeak-dev] The Trunk: Tools-mt.582.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.582.mcz ==================== Summary ==================== Name: Tools-mt.582 Author: mt Time: 12 April 2015, 4:56:27.909 pm UUID: 3ad55be5-74b1-f84f-98d1-b1cf671476d2 Ancestors: Tools-mt.581 Preserve expressions that were entered in the code pane in inspector/explorer when switching between those tools. =============== Diff against Tools-mt.581 =============== Item was changed: StringHolder subclass: #Inspector + instanceVariableNames: 'object selectionIndex timeOfLastListUpdate selectionUpdateTime context expression' - instanceVariableNames: 'object selectionIndex timeOfLastListUpdate selectionUpdateTime context' classVariableNames: '' poolDictionaries: '' category: 'Tools-Inspector'! !Inspector commentStamp: '' prior: 0! I represent a query path into the internal representation of an object. As a StringHolder, the string I represent is the value of the currently selected variable of the observed object.! Item was changed: ----- Method: Inspector>>buildCodePaneWith: (in category 'toolbuilder') ----- buildCodePaneWith: builder | textSpec | textSpec := builder pluggableTextSpec new. textSpec model: self; + getText: #expression; + editText: #expression:; - getText: #trash; - setText: #trash:; help: #helpText; selection: #contentsSelection; menu: #codePaneMenu:shifted:; askBeforeDiscardingEdits: false. ^textSpec! Item was changed: ----- Method: Inspector>>exploreObject (in category 'toolbuilder') ----- exploreObject "Switch to an explorer tool." + | window model | + window := self object explore. + model := window model. + + model setExpression: self expression. + window bounds: self containingWindow bounds. - self object explore - bounds: self containingWindow bounds. self changed: #close.! Item was added: + ----- Method: Inspector>>expression (in category 'accessing') ----- + expression + + ^ expression ifNil: ['']! Item was added: + ----- Method: Inspector>>expression: (in category 'accessing') ----- + expression: aString + + expression := aString.! Item was added: + ----- Method: Inspector>>setExpression: (in category 'code') ----- + setExpression: aString + + self expression: aString. + self changed: #expression.! Item was changed: AbstractHierarchicalList subclass: #ObjectExplorer + instanceVariableNames: 'root currentParent inspector monitorList expression' - instanceVariableNames: 'root currentParent inspector monitorList' classVariableNames: '' poolDictionaries: '' category: 'Tools-Explorer'! !ObjectExplorer commentStamp: '' prior: 0! ObjectExplorer provides a hierarchical alternative to #inspect. Simply evaluate an expression like: World explore and enjoy.! Item was changed: ----- Method: ObjectExplorer>>buildWith: (in category 'toolbuilder') ----- buildWith: builder | windowSpec treeSpec textSpec buttonSpec buttonOffset | windowSpec := builder pluggableWindowSpec new. windowSpec model: self; children: OrderedCollection new; label: #label; extent: self initialExtent. treeSpec := builder pluggableTreeSpec new. treeSpec model: self; nodeClass: self class nodeClass; roots: #getList; keyPress: #explorerKey:from:event:; getSelected: #currentSelection; setSelected: #currentSelection:; setSelectedParent: #currentParent:; menu: #genericMenu:; autoDeselect: false; columns: (ObjectExplorerWrapper showContentsInColumns ifTrue: [{ [:listMorph | (listMorph filteredItems collect: [:item | item preferredWidthOfColumn: 1]) max]. nil "take all the space"}]); frame: (0@0 corner: 1@0.75). windowSpec children add: treeSpec. buttonOffset := (Preferences standardButtonFont widthOfString: 'inspect') * 3/2. textSpec := builder pluggableTextSpec new. textSpec model: self; + getText: #expression; + editText: #expression:; menu: #codePaneMenu:shifted:; help: 'Evaluate expressions for the current tree selection...' translated; frame: (LayoutFrame fractions: (0@0.75 corner: 1@1) offsets: (0@0 corner: buttonOffset negated@0)). windowSpec children add: textSpec. buttonSpec := builder pluggableButtonSpec new model: self; label: 'inspect'; action: #inspectObject; help: 'Switch to an inspector tool'; frame: (LayoutFrame fractions: (1@0.75 corner: 1@1) offsets: (buttonOffset negated@0 corner: 0 @ 0)). windowSpec children add: buttonSpec. [^ builder build: windowSpec] ensure: [self changed: #expandRootsRequested]! Item was added: + ----- Method: ObjectExplorer>>expression (in category 'accessing') ----- + expression + + ^ expression! Item was added: + ----- Method: ObjectExplorer>>expression: (in category 'accessing') ----- + expression: aString + + expression := aString.! Item was changed: ----- Method: ObjectExplorer>>inspectObject (in category 'toolbuilder') ----- inspectObject "Switch to an inspector tool." + | window model | + window := self object inspect. + model := window model. + + model setExpression: self expression. + window bounds: self containingWindow bounds. - self object inspect - bounds: self containingWindow bounds. self changed: #close.! Item was added: + ----- Method: ObjectExplorer>>setExpression: (in category 'accessing - other') ----- + setExpression: aString + + self expression: aString. + self changed: #expression.! From commits at source.squeak.org Sun Apr 12 15:52:49 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 15:52:50 2015 Subject: [squeak-dev] The Trunk: HelpSystem-Core-mt.68.mcz Message-ID: Marcel Taeumel uploaded a new version of HelpSystem-Core to project The Trunk: http://source.squeak.org/trunk/HelpSystem-Core-mt.68.mcz ==================== Summary ==================== Name: HelpSystem-Core-mt.68 Author: mt Time: 12 April 2015, 5:52:42.706 pm UUID: 31491b8c-3fee-eb48-8c6c-d59bf06a465d Ancestors: HelpSystem-Core-mt.67 Concurrent search added to help browser. Having this, we can also search web contents. =============== Diff against HelpSystem-Core-mt.67 =============== Item was changed: + Model subclass: #AbstractHelpTopic - Object subclass: #AbstractHelpTopic instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'HelpSystem-Core-Model'! !AbstractHelpTopic commentStamp: 'mt 3/24/2015 16:26' prior: 0! A HelpTopic provides content information that can be used as a help to the user. It can be labeled with a title and marked with an (optional) icon. Help topics form a hierarchy since any topic is able to have zero or more subtopics. ! Item was added: + ----- Method: AbstractHelpTopic>>isSearchable (in category 'testing') ----- + isSearchable + + ^ true! Item was added: + ----- Method: AbstractHelpTopic>>priorityForSearch (in category 'accessing') ----- + priorityForSearch + + ^ 0! Item was changed: AbstractHelpTopic subclass: #ClassBasedHelpTopic + instanceVariableNames: 'helpClass subtopics' - instanceVariableNames: 'helpClass' classVariableNames: '' poolDictionaries: '' category: 'HelpSystem-Core-Model'! !ClassBasedHelpTopic commentStamp: 'mt 3/24/2015 16:28' prior: 0! This kind of topic uses subclasses and methods to encode books and pages.! Item was changed: ----- Method: ClassBasedHelpTopic>>subtopics (in category 'accessing') ----- subtopics + ^ subtopics ifNil: [self updateSubtopics]! - | pages | - pages := (self helpClass pages collect: [:pageSelectorOrClassName | - (Smalltalk hasClassNamed: pageSelectorOrClassName asString) - ifTrue: [Smalltalk classNamed: pageSelectorOrClassName asString] - ifFalse: [pageSelectorOrClassName]]) asOrderedCollection. - - self helpClass subclasses do: [:cls | - pages addIfNotPresent: cls]. - - ^ pages withIndexCollect: [:pageSelectorOrClass :priority | - pageSelectorOrClass isBehavior - ifFalse: [(self helpClass perform: pageSelectorOrClass) priority: priority - pages size; yourself] - ifTrue: [pageSelectorOrClass asHelpTopic]]! Item was added: + ----- Method: ClassBasedHelpTopic>>updateSubtopics (in category 'updating') ----- + updateSubtopics + + | pages | + pages := (self helpClass pages collect: [:pageSelectorOrClassName | + (Smalltalk hasClassNamed: pageSelectorOrClassName asString) + ifTrue: [Smalltalk classNamed: pageSelectorOrClassName asString] + ifFalse: [pageSelectorOrClassName]]) asOrderedCollection. + + self helpClass subclasses do: [:cls | + pages addIfNotPresent: cls]. + + ^ subtopics := pages withIndexCollect: [:pageSelectorOrClass :priority | + pageSelectorOrClass isBehavior + ifFalse: [(self helpClass perform: pageSelectorOrClass) priority: priority - pages size; yourself] + ifTrue: [pageSelectorOrClass asHelpTopic]]! Item was changed: + Model subclass: #HelpBrowser + instanceVariableNames: 'rootTopic currentTopic result searchTopic topicPath toplevelTopics' - Object subclass: #HelpBrowser - instanceVariableNames: 'rootTopic topic result' classVariableNames: 'DefaultHelpBrowser' poolDictionaries: '' category: 'HelpSystem-Core-UI'! !HelpBrowser commentStamp: 'tbn 3/8/2010 09:33' prior: 0! A HelpBrowser is used to display a hierarchy of help topics and their contents. Instance Variables rootTopic: window: treeMorph: contentMorph: rootTopic - xxxxx window - xxxxx treeMorph - xxxxx contentMorph - xxxxx ! Item was changed: ----- Method: HelpBrowser>>accept: (in category 'actions') ----- accept: text "Accept edited text. Compile it into a HelpTopic" | code topicClass topicMethod | (self find: self topic contents) asArray ifNotEmpty: [:refs | topicClass := refs first actualClass theNonMetaClass. topicMethod := refs first selector]. code := String streamContents:[:s| s nextPutAll: topicMethod. s crtab; nextPutAll: '"This method was automatically generated. Edit it using:"'. s crtab; nextPutAll: '"', self name,' edit: ', topicMethod storeString,'"'. s crtab; nextPutAll: '^HelpTopic'. + s crtab: 2; nextPutAll: 'title: ', currentTopic title storeString. - s crtab: 2; nextPutAll: 'title: ', topic title storeString. s crtab: 2; nextPutAll: 'contents: '. s cr; nextPutAll: (String streamContents:[:c| c nextChunkPutWithStyle: text]) storeString. s nextPutAll:' readStream nextChunkText'. ]. topicClass class compile: code classified: ((topicClass class organization categoryOfElement: topicMethod) ifNil:['pages']). self flag: #fixme. "mt: Update will not work because the topic builder eagerly cached all the contents and lost track of its origins. We need to get rid of the topic builders and create topic contents lazily resp. live." + self changed: #toplevelTopics.. + self changed: #currentTopic. - self changed: #topics. - self changed: #topic. self changed: #topicContents. ! Item was changed: ----- Method: HelpBrowser>>buildWith: (in category 'toolbuilder') ----- buildWith: builder + | windowSpec treeSpec textSpec searchSpec | - | windowSpec treeSpec textSpec | windowSpec := builder pluggableWindowSpec new. windowSpec model: self; children: OrderedCollection new; label: #label. + searchSpec := builder pluggableInputFieldSpec new. + searchSpec + model: self; + getText: #searchTerm; + setText: #searchTerm:; + help: 'Search...'; + frame: (LayoutFrame + fractions: (0@0 corner: 1@0) + offsets: (0@0 corner: 0@ (Preferences standardDefaultTextFont height * 2))). + windowSpec children add: searchSpec. + treeSpec := builder pluggableTreeSpec new. treeSpec model: self; nodeClass: HelpTopicListItemWrapper; + roots: #toplevelTopics; + getSelected: #currentTopic; + setSelected: #currentTopic:; + getSelectedPath: #currentTopicPath; - roots: #topics; - getSelected: #topic; - setSelected: #topic:; - menu: #menu:; autoDeselect: false; + frame: (LayoutFrame + fractions: (0@0 corner: 0.3@1) + offsets: (0@ (Preferences standardDefaultTextFont height * 2) corner: 0@0)). - frame: (0@0 corner: 0.3@1). windowSpec children add: treeSpec. textSpec := builder pluggableTextSpec new. textSpec model: self; getText: #topicContents; setText: #accept:; menu: #codePaneMenu:shifted:; + frame: (LayoutFrame + fractions: (0.3@0.0 corner: 1@1) + offsets: (0@ (Preferences standardDefaultTextFont height * 2) corner: 0@0)). - frame: (0.3@0 corner: 1@1). windowSpec children add: textSpec. ^ builder build: windowSpec! Item was added: + ----- Method: HelpBrowser>>currentTopic (in category 'accessing') ----- + currentTopic + + ^ currentTopic! Item was added: + ----- Method: HelpBrowser>>currentTopic: (in category 'accessing') ----- + currentTopic: aHelpTopic + + self currentTopic == aHelpTopic ifTrue: [^ self]. + + currentTopic := aHelpTopic. + topicPath := nil. + + self changed: #currentTopic. + self changed: #topicContents.! Item was added: + ----- Method: HelpBrowser>>currentTopicPath (in category 'accessing') ----- + currentTopicPath + "Only used for dynamic dispatch. Should be nil or empty on manual evaluation. See #topic:." + + ^ topicPath ifNil: [#()]! Item was added: + ----- Method: HelpBrowser>>currentTopicPath: (in category 'accessing') ----- + currentTopicPath: someTopics + "Use the tree structure to select a nested topic." + + topicPath := someTopics. + self changed: #currentTopicPath.! Item was changed: ----- Method: HelpBrowser>>findAgain (in category 'actions') ----- findAgain | i | + (i := result indexOf: currentTopic) ~= 0 - (i := result indexOf: topic) ~= 0 ifTrue: [i = result size ifTrue: [(self confirm: 'Start over?') ifTrue: [i := 1] ifFalse: [^ self]]. self onItemClicked: (result at: i + 1)]! Item was changed: ----- Method: HelpBrowser>>rootTopic: (in category 'accessing') ----- rootTopic: aHelpTopic rootTopic := aHelpTopic asHelpTopic. + self toplevelTopics: ((self rootTopic ifNil: [#()] ifNotNil: #subtopics) sorted, {self searchTopic}). + self changed: #label.! - self changed: #label. - self changed: #topics.! Item was added: + ----- Method: HelpBrowser>>searchTerm (in category 'searching') ----- + searchTerm + + ^ '' "Reset. Terms are cached in SearchTopic instances."! Item was added: + ----- Method: HelpBrowser>>searchTerm: (in category 'searching') ----- + searchTerm: aString + "Spawn a new search topic." + + | topic | + topic := self searchTopic subtopics + detect: [:t | t term = aString] + ifNone: [ | newTopic | + newTopic := SearchTopic new + term: aString; + yourself. + self searchTopic addSubtopic: newTopic. + newTopic addDependent: self. "Tell me about your updates." + newTopic]. + + "self changed: #searchTerm." + + "Select results and expand searches node if necessary." + self currentTopicPath: {self searchTopic. topic}. + self assert: self currentTopic == topic. + + topic + topicsToSearch: self toplevelTopics allButLast; + startSearch.! Item was added: + ----- Method: HelpBrowser>>searchTopic (in category 'searching') ----- + searchTopic + + ^ searchTopic ifNil: [searchTopic := HelpTopic new + title: 'Search Results'; + addDependent: self; + yourself]! Item was removed: - ----- Method: HelpBrowser>>topic (in category 'accessing') ----- - topic - - ^ topic! Item was removed: - ----- Method: HelpBrowser>>topic: (in category 'accessing') ----- - topic: aHelpTopic - - self topic == aHelpTopic ifTrue: [^ self]. - - topic := aHelpTopic. - - self changed: #topic. - self changed: #topicContents.! Item was changed: ----- Method: HelpBrowser>>topicContents (in category 'accessing - ui') ----- topicContents + ^ (self currentTopic ifNil: [self rootTopic]) ifNil: '' ifNotNil: #contents! - ^ (self topic ifNil: [self rootTopic]) ifNil: '' ifNotNil: #contents! Item was removed: - ----- Method: HelpBrowser>>topics (in category 'accessing - ui') ----- - topics - - ^ (self rootTopic ifNil: [#()] ifNotNil: #subtopics) sorted! Item was added: + ----- Method: HelpBrowser>>toplevelTopics (in category 'accessing') ----- + toplevelTopics + + ^ toplevelTopics ifNil: [#()]! Item was added: + ----- Method: HelpBrowser>>toplevelTopics: (in category 'accessing') ----- + toplevelTopics: someTopics + + toplevelTopics := someTopics. + self changed: #toplevelTopics.! Item was added: + ----- Method: HelpBrowser>>update:with: (in category 'updating') ----- + update: aspect with: object + + aspect == #contents ifTrue: [ + object == self currentTopic ifTrue: [self changed: #topicContents]]. + aspect == #searchResultSelected ifTrue: [ + self currentTopicPath: object].! Item was added: + ----- Method: HelpBrowser>>windowIsClosing (in category 'updating') ----- + windowIsClosing + + super windowIsClosing. + + self searchTopic subtopics do: [:topic | + topic stopSearch].! Item was changed: ----- Method: HelpTopic>>addSubtopic: (in category 'accessing') ----- addSubtopic: aTopic "Adds the given topic to the receivers collection of subtopics" self subtopics add: aTopic. + self changed: #subtopicAdded with: aTopic. ^aTopic! Item was added: + ----- Method: HelpTopicListItemWrapper>>update:with: (in category 'accessing') ----- + update: aspect with: object + + super update: aspect with: object. + + "Map the domain-specific aspect to a framework-specific one." + aspect = #subtopicAdded ifTrue: [ + self changed: #contents].! Item was changed: AbstractHelpTopic subclass: #HtmlHelpTopic + instanceVariableNames: 'url document selectBlock convertBlock subtopicUrls subtopics level' - instanceVariableNames: 'url cache selectBlock convertBlock subtopicUrls' classVariableNames: '' poolDictionaries: '' category: 'HelpSystem-Core-Model'! Item was changed: ----- Method: HtmlHelpTopic>>contents (in category 'accessing') ----- contents | start end | start := (self document findString: '' startingAt: start) + 1. end := self document findString: '' startingAt: start. + start > end ifTrue: [^ self document]. - start > end ifTrue: [^ '']. ^ (self document copyFrom: start to: end - 1) asUnHtml withBlanksTrimmed! Item was changed: ----- Method: HtmlHelpTopic>>document (in category 'accessing') ----- document + ^ document ifNil: [document := + [ + (HTTPSocket httpGet: self url accept: 'text/html') contents + ] on: Error do: [:err | err printString]]! - ^ cache ifNil: [cache := (HTTPSocket httpGet: self url accept: 'text/html') contents]! Item was added: + ----- Method: HtmlHelpTopic>>fetchSubtopics (in category 'caching') ----- + fetchSubtopics + "If this method is called from another process than the ui process, there will be no progress shown." + + | updateBlock | + updateBlock := [:topic | topic document; subtopicUrls]. + + Project current uiProcess == Processor activeProcess + ifFalse: [self subtopics do: updateBlock] + ifTrue: [self subtopics + do: updateBlock + displayingProgress: [:topic | 'Fetching documents ... ', topic url]].! Item was added: + ----- Method: HtmlHelpTopic>>isSearchable (in category 'testing') ----- + isSearchable + + ^ self level < 2! Item was added: + ----- Method: HtmlHelpTopic>>level (in category 'accessing') ----- + level + + ^ level ifNil: [level := 1]! Item was added: + ----- Method: HtmlHelpTopic>>level: (in category 'accessing') ----- + level: anInteger + + level := anInteger.! Item was added: + ----- Method: HtmlHelpTopic>>priorityForSearch (in category 'accessing') ----- + priorityForSearch + + ^ 999 "very late"! Item was added: + ----- Method: HtmlHelpTopic>>refresh (in category 'caching') ----- + refresh + "Re-fetch document and all referenced urls." + + document := nil. + subtopics := nil. + + self changed: #contents. "See #contents. It is based on document." + self changed: #subtopics.! Item was changed: ----- Method: HtmlHelpTopic>>subtopics (in category 'accessing') ----- subtopics | start end urls | + subtopics ifNotNil: [^ subtopics]. + urls := OrderedCollection new. start := self document findString: ' 0] whileTrue: [ start := self document findString: 'href' startingAt: start. start := (self document findString: '"' startingAt: start) + 1. end := self document findString: '"' startingAt: start. urls addIfNotPresent: (self document copyFrom: start to: end - 1). start := self document findString: '>title (in category 'accessing') ----- title | start end | start := (self document findString: '' startingAt: start) + 1. end := self document findString: '' startingAt: start. + start > end ifTrue: [^ self url asUrl authority]. - start > end ifTrue: [^ self url printStringLimitedTo: 10]. ^ self document copyFrom: start to: end - 1! Item was added: + AbstractHelpTopic subclass: #SearchTopic + instanceVariableNames: 'term process results resultText topicsToSearch mutex updatePending' + classVariableNames: '' + poolDictionaries: '' + category: 'HelpSystem-Core-Model'! Item was added: + ----- Method: SearchTopic>><= (in category 'comparing') ----- + <= anotherHelpTopic + + ^ true "Keep insertion order in parent topic."! Item was added: + ----- Method: SearchTopic>>contents (in category 'accessing') ----- + contents + + ^ resultText ifNil: [self updateResultText]! Item was added: + ----- Method: SearchTopic>>find:in:results: (in category 'as yet unclassified') ----- + find: term in: path results: results + + | resultTemplate c topic | + topic := path last. + resultTemplate := Array new: 5. + (topic title asString findString: term startingAt: 1 caseSensitive: false) in: [:index | + index > 0 ifTrue: [resultTemplate at: 2 put: (index to: index + term size)]]. + + ((c := topic contents asString withSqueakLineEndings) findString: term startingAt: 1 caseSensitive: false) in: [:index | + index > 0 ifTrue: [ + | leadingContext trailingContext i | + leadingContext := 0. + trailingContext := 0. + i := index. + [i notNil] whileTrue: [ + (leadingContext = 2 or: [i = 1]) + ifTrue: [ + leadingContext := i = 1 ifTrue: [i] ifFalse: [i+1]. + i := nil] + ifFalse: [ + ((c at: i) = Character cr) ifTrue: [ + leadingContext := leadingContext + 1]. + i := i - 1] ]. + i := index + term size. + [i notNil] whileTrue: [ + (trailingContext = 2 or: [i = c size]) + ifTrue: [ + trailingContext := i = c size ifTrue: [i] ifFalse: [i-1]. + i := nil] + ifFalse: [ + ((c at: i) = Character cr) ifTrue: [ + trailingContext := trailingContext + 1]. + i := i + 1] ]. + + resultTemplate + at: 1 put: path; + at: 3 put: (index - leadingContext + 1 to: index - leadingContext + term size); + at: 4 put: (c copyFrom: leadingContext to: trailingContext); + at: 5 put: leadingContext. + + self mutex critical: [ results add: resultTemplate ]. + self triggerUpdateContents. + + ] ]. + + topic isSearchable ifTrue: [ + topic subtopics do: [:t | self find: term in: path, {t} results: results]].! Item was added: + ----- Method: SearchTopic>>mutex (in category 'as yet unclassified') ----- + mutex + + ^ mutex ifNil: [mutex := Mutex new]! Item was added: + ----- Method: SearchTopic>>printResultEntry: (in category 'as yet unclassified') ----- + printResultEntry: entry + + | resultEntry topic | + resultEntry := '' asText. + topic := entry first last. + + entry second notNil + ifFalse: [resultEntry append: ( + (topic title) asText + addAttribute: TextEmphasis bold)] + ifTrue: [resultEntry append: ( + (topic title) asText + addAttribute: TextEmphasis bold; + addAttribute: (TextColor color: Color green muchDarker) + from: entry second first + to: entry second last)]. + + resultEntry append: (' (open topic)' asText + addAttribute: (PluggableTextAttribute evalBlock: [self changed: #searchResultSelected with: entry first])). + + resultEntry append: String cr. + + entry fourth in: [:contents | + | text | + text := contents asText. + text + addAttribute: (TextColor color: Color green muchDarker) + from: entry third first + to: entry third last; + addAttribute: TextEmphasis bold + from: entry third first + to: entry third last. + resultEntry + append: text withBlanksTrimmed; + append: '\\' withCRs. + + ]. + + ^ resultEntry! Item was added: + ----- Method: SearchTopic>>startSearch (in category 'as yet unclassified') ----- + startSearch + + self stopSearch. + results := OrderedCollection new. + + self topicsToSearch ifEmpty: [ + self changed: #contents. + ^ self]. + + process := [ + + (self topicsToSearch + sorted: [:t1 :t2 | t1 priorityForSearch <= t2 priorityForSearch]) + do: [:topic | + | nestedResults | + nestedResults := OrderedCollection new. + self mutex critical: [results add: topic -> nestedResults]. + self find: self term in: {topic} results: nestedResults]. + + results add: 'Search finished.'. + self triggerUpdateContents. + + ] forkAt: 35.! Item was added: + ----- Method: SearchTopic>>stopSearch (in category 'as yet unclassified') ----- + stopSearch + + process ifNotNil: #terminate. + process := nil.! Item was added: + ----- Method: SearchTopic>>term (in category 'accessing') ----- + term + + ^ term! Item was added: + ----- Method: SearchTopic>>term: (in category 'accessing') ----- + term: aString + + term := aString.! Item was added: + ----- Method: SearchTopic>>title (in category 'accessing') ----- + title + + ^ '''', self term, ''''! Item was added: + ----- Method: SearchTopic>>topicsToSearch (in category 'accessing') ----- + topicsToSearch + + ^ topicsToSearch ifNil: [#()]! Item was added: + ----- Method: SearchTopic>>topicsToSearch: (in category 'accessing') ----- + topicsToSearch: someTopics + + topicsToSearch := someTopics.! Item was added: + ----- Method: SearchTopic>>triggerUpdateContents (in category 'as yet unclassified') ----- + triggerUpdateContents + + self mutex critical: [ + updatePending == true ifFalse: [ + updatePending := true. + Project current addDeferredUIMessage: [ActiveWorld + addAlarm: #updateContents withArguments: #() + for: self at: Time millisecondClockValue + 250] ] ]. + ! Item was added: + ----- Method: SearchTopic>>updateContents (in category 'as yet unclassified') ----- + updateContents + + self mutex critical: [ updatePending := false ]. + + resultText := nil. + self changed: #contents with: self.! Item was added: + ----- Method: SearchTopic>>updateResultText (in category 'as yet unclassified') ----- + updateResultText + + resultText := '' asText. + + self mutex critical: [ + results ifNil: [^ resultText]. + results do: [:topicToResult | + topicToResult isString + ifTrue: [resultText append: ( + (topicToResult, String cr) asText + addAttribute: (TextColor color: (Color gray: 0.7)); + yourself)] + ifFalse: [ + resultText append: ( + ('\----- Matches found in ''', topicToResult key title, ''' -----\\') withCRs asText + addAttribute: (TextColor color: (Color gray: 0.7))). + topicToResult value do: [:entry | + resultText append: (self printResultEntry: entry)] + ]]]. + + ^ resultText! From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 12 15:42:21 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 12 15:55:22 2015 Subject: [squeak-dev] Re: The Trunk: HelpSystem-Core-mt.68.mcz In-Reply-To: References: Message-ID: <1428853341515-4819172.post@n4.nabble.com> help-browser.png We should open the help browser in the new release to display important information--not a workspace. Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-HelpSystem-Core-mt-68-mcz-tp4819171p4819172.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From karlramberg at gmail.com Sun Apr 12 16:27:54 2015 From: karlramberg at gmail.com (karl ramberg) Date: Sun Apr 12 16:27:58 2015 Subject: [squeak-dev] The Trunk: Tools-mt.582.mcz In-Reply-To: <552a87b8.9011370a.3349.ffff8fbeSMTPIN_ADDED_MISSING@mx.google.com> References: <552a87b8.9011370a.3349.ffff8fbeSMTPIN_ADDED_MISSING@mx.google.com> Message-ID: Hi, You are making really nice enhancements :-) BTW : Could we preserve the selection in the list as well ? Or are the list models too different for it to make sense ? First level selection should probably work... Karl On Sun, Apr 12, 2015 at 4:56 PM, wrote: > Marcel Taeumel uploaded a new version of Tools to project The Trunk: > http://source.squeak.org/trunk/Tools-mt.582.mcz > > ==================== Summary ==================== > > Name: Tools-mt.582 > Author: mt > Time: 12 April 2015, 4:56:27.909 pm > UUID: 3ad55be5-74b1-f84f-98d1-b1cf671476d2 > Ancestors: Tools-mt.581 > > Preserve expressions that were entered in the code pane in > inspector/explorer when switching between those tools. > > =============== Diff against Tools-mt.581 =============== > > Item was changed: > StringHolder subclass: #Inspector > + instanceVariableNames: 'object selectionIndex timeOfLastListUpdate > selectionUpdateTime context expression' > - instanceVariableNames: 'object selectionIndex timeOfLastListUpdate > selectionUpdateTime context' > classVariableNames: '' > poolDictionaries: '' > category: 'Tools-Inspector'! > > !Inspector commentStamp: '' prior: 0! > I represent a query path into the internal representation of an object. > As a StringHolder, the string I represent is the value of the currently > selected variable of the observed object.! > > Item was changed: > ----- Method: Inspector>>buildCodePaneWith: (in category 'toolbuilder') > ----- > buildCodePaneWith: builder > | textSpec | > textSpec := builder pluggableTextSpec new. > textSpec > model: self; > + getText: #expression; > + editText: #expression:; > - getText: #trash; > - setText: #trash:; > help: #helpText; > selection: #contentsSelection; > menu: #codePaneMenu:shifted:; > askBeforeDiscardingEdits: false. > ^textSpec! > > Item was changed: > ----- Method: Inspector>>exploreObject (in category 'toolbuilder') ----- > exploreObject > "Switch to an explorer tool." > > + | window model | > + window := self object explore. > + model := window model. > + > + model setExpression: self expression. > + window bounds: self containingWindow bounds. > - self object explore > - bounds: self containingWindow bounds. > self changed: #close.! > > Item was added: > + ----- Method: Inspector>>expression (in category 'accessing') ----- > + expression > + > + ^ expression ifNil: ['']! > > Item was added: > + ----- Method: Inspector>>expression: (in category 'accessing') ----- > + expression: aString > + > + expression := aString.! > > Item was added: > + ----- Method: Inspector>>setExpression: (in category 'code') ----- > + setExpression: aString > + > + self expression: aString. > + self changed: #expression.! > > Item was changed: > AbstractHierarchicalList subclass: #ObjectExplorer > + instanceVariableNames: 'root currentParent inspector monitorList > expression' > - instanceVariableNames: 'root currentParent inspector monitorList' > classVariableNames: '' > poolDictionaries: '' > category: 'Tools-Explorer'! > > !ObjectExplorer commentStamp: '' prior: 0! > ObjectExplorer provides a hierarchical alternative to #inspect. Simply > evaluate an expression like: > > World explore > > and enjoy.! > > Item was changed: > ----- Method: ObjectExplorer>>buildWith: (in category 'toolbuilder') > ----- > buildWith: builder > > | windowSpec treeSpec textSpec buttonSpec buttonOffset | > windowSpec := builder pluggableWindowSpec new. > windowSpec > model: self; > children: OrderedCollection new; > label: #label; > extent: self initialExtent. > > treeSpec := builder pluggableTreeSpec new. > treeSpec > model: self; > nodeClass: self class nodeClass; > roots: #getList; > keyPress: #explorerKey:from:event:; > getSelected: #currentSelection; > setSelected: #currentSelection:; > setSelectedParent: #currentParent:; > menu: #genericMenu:; > autoDeselect: false; > columns: (ObjectExplorerWrapper showContentsInColumns > ifTrue: [{ > [:listMorph | (listMorph filteredItems > collect: [:item | > item preferredWidthOfColumn: 1]) > max]. > nil "take all the space"}]); > frame: (0@0 corner: 1@0.75). > windowSpec children add: treeSpec. > > buttonOffset := (Preferences standardButtonFont widthOfString: > 'inspect') * 3/2. > > textSpec := builder pluggableTextSpec new. > textSpec > model: self; > + getText: #expression; > + editText: #expression:; > menu: #codePaneMenu:shifted:; > help: 'Evaluate expressions for the current tree > selection...' translated; > frame: (LayoutFrame fractions: (0@0.75 corner: 1@1) > offsets: (0@0 corner: buttonOffset negated@0)). > windowSpec children add: textSpec. > > buttonSpec := builder pluggableButtonSpec new > model: self; > label: 'inspect'; > action: #inspectObject; > help: 'Switch to an inspector tool'; > frame: (LayoutFrame fractions: (1@0.75 corner: 1@1) > offsets: (buttonOffset negated@0 corner: 0 @ 0)). > windowSpec children add: buttonSpec. > > [^ builder build: windowSpec] > ensure: [self changed: #expandRootsRequested]! > > Item was added: > + ----- Method: ObjectExplorer>>expression (in category 'accessing') ----- > + expression > + > + ^ expression! > > Item was added: > + ----- Method: ObjectExplorer>>expression: (in category 'accessing') ----- > + expression: aString > + > + expression := aString.! > > Item was changed: > ----- Method: ObjectExplorer>>inspectObject (in category 'toolbuilder') > ----- > inspectObject > "Switch to an inspector tool." > > + | window model | > + window := self object inspect. > + model := window model. > + > + model setExpression: self expression. > + window bounds: self containingWindow bounds. > - self object inspect > - bounds: self containingWindow bounds. > self changed: #close.! > > Item was added: > + ----- Method: ObjectExplorer>>setExpression: (in category 'accessing - > other') ----- > + setExpression: aString > + > + self expression: aString. > + self changed: #expression.! > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150412/a31842d5/attachment.htm From commits at source.squeak.org Sun Apr 12 16:29:47 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 16:29:49 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Kernel-mt.75.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Kernel to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Kernel-mt.75.mcz ==================== Summary ==================== Name: ToolBuilder-Kernel-mt.75 Author: mt Time: 12 April 2015, 6:29:39.866 pm UUID: 1d55bdbe-2b99-b948-b676-aff38c190c00 Ancestors: ToolBuilder-Kernel-mt.74 Missing optional widget added to tool builder. Fall-back to regular list. =============== Diff against ToolBuilder-Kernel-mt.74 =============== Item was added: + ----- Method: ToolBuilder>>buildPluggableAlternateMultiSelectionList: (in category 'widgets optional') ----- + buildPluggableAlternateMultiSelectionList: aSpec + + ^ self buildPluggableList: aSpec! From commits at source.squeak.org Sun Apr 12 16:30:31 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 16:30:32 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.124.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.124.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.124 Author: mt Time: 12 April 2015, 6:30:24.599 pm UUID: dac1df35-d6de-5c4b-8cba-3d9c185f3cc4 Ancestors: ToolBuilder-Morphic-mt.123 Morphic tool builder messages re-organized. =============== Diff against ToolBuilder-Morphic-mt.123 =============== Item was changed: + ----- Method: MorphicToolBuilder>>buildHelpFor:spec: (in category 'private') ----- - ----- Method: MorphicToolBuilder>>buildHelpFor:spec: (in category 'pluggable widgets') ----- buildHelpFor: widget spec: aSpec aSpec help ifNotNil: [:stringOrSymbol | stringOrSymbol isSymbol ifTrue: [widget balloonTextSelector: stringOrSymbol] ifFalse: [widget balloonText: stringOrSymbol]].! Item was changed: + ----- Method: MorphicToolBuilder>>buildPluggableActionButton: (in category 'widgets optional') ----- - ----- Method: MorphicToolBuilder>>buildPluggableActionButton: (in category 'pluggable widgets') ----- buildPluggableActionButton: aSpec | button | button := self buildPluggableButton: aSpec. button color: Color white. ^button! Item was changed: + ----- Method: MorphicToolBuilder>>buildPluggableAlternateMultiSelectionList: (in category 'widgets optional') ----- - ----- Method: MorphicToolBuilder>>buildPluggableAlternateMultiSelectionList: (in category 'pluggable widgets') ----- buildPluggableAlternateMultiSelectionList: aSpec | listMorph listClass | aSpec getSelected ifNotNil: [ ^ self error: 'There is no PluggableAlternateListMorphOfManyByItem' ]. listClass := self alternateMultiSelectListClass. listMorph := listClass on: aSpec model list: aSpec list primarySelection: aSpec getIndex changePrimarySelection: aSpec setIndex listSelection: aSpec getSelectionList changeListSelection: aSpec setSelectionList menu: aSpec menu. listMorph setProperty: #highlightSelector toValue: #highlightMessageList:with: ; setProperty: #itemConversionMethod toValue: #asStringOrText ; setProperty: #balloonTextSelectorForSubMorphs toValue: #balloonTextForClassAndMethodString ; enableDragNDrop: SystemBrowser browseWithDragNDrop ; menuTitleSelector: #messageListSelectorTitle. self register: listMorph id: aSpec name. listMorph keystrokeActionSelector: aSpec keyPress ; getListElementSelector: aSpec listItem ; getListSizeSelector: aSpec listSize. self buildHelpFor: listMorph spec: aSpec. self setFrame: aSpec frame in: listMorph. parent ifNotNil: [ self add: listMorph to: parent ]. panes ifNotNil: [ aSpec list ifNotNil:[panes add: aSpec list ] ]. ^ listMorph! Item was changed: + ----- Method: MorphicToolBuilder>>buildPluggableButton: (in category 'widgets required') ----- - ----- Method: MorphicToolBuilder>>buildPluggableButton: (in category 'pluggable widgets') ----- buildPluggableButton: aSpec | widget label state action enabled | label := aSpec label. state := aSpec state. action := aSpec action. widget := self buttonClass on: aSpec model getState: (state isSymbol ifTrue:[state]) action: nil label: (label isSymbol ifTrue:[label]). widget style: aSpec style. aSpec changeLabelWhen ifNotNilDo: [ :event | widget whenChanged: event update: aSpec label]. self register: widget id: aSpec name. enabled := aSpec enabled. enabled isSymbol ifTrue:[widget getEnabledSelector: enabled] ifFalse:[widget enabled:enabled]. widget action: action. widget getColorSelector: aSpec color. widget offColor: Color white.. self buildHelpFor: widget spec: aSpec. (label isSymbol or:[label == nil]) ifFalse:[widget label: label]. self setFrame: aSpec frame in: widget. parent ifNotNil:[self add: widget to: parent]. ^widget! Item was changed: + ----- Method: MorphicToolBuilder>>buildPluggableCheckBox: (in category 'widgets optional') ----- - ----- Method: MorphicToolBuilder>>buildPluggableCheckBox: (in category 'pluggable widgets') ----- buildPluggableCheckBox: spec | widget label state action | label := spec label. state := spec state. action := spec action. widget := self checkBoxClass on: spec model getState: (state isSymbol ifTrue:[state]) action: (action isSymbol ifTrue:[action]) label: (label isSymbol ifTrue:[label]). self register: widget id: spec name. widget installButton. " widget getColorSelector: spec color. widget offColor: Color white.. self buildHelpFor: widget spec: spec. (label isSymbol or:[label == nil]) ifFalse:[widget label: label]. " self setFrame: spec frame in: widget. parent ifNotNil:[self add: widget to: parent]. ^widget! Item was changed: + ----- Method: MorphicToolBuilder>>buildPluggableCodePane: (in category 'widgets optional') ----- - ----- Method: MorphicToolBuilder>>buildPluggableCodePane: (in category 'pluggable widgets') ----- buildPluggableCodePane: aSpec "Install the default styler for code panes. Implementation note: We should just be doing something like, e.g., ^(self buildPluggableText: aSpec) useDefaultStyler Unfortunately, this will retrieve and layout the initial text twice which can make for a noticable performance difference when looking at some larger piece of code. So instead we copy the implementation from buildPlugggableText: here and insert #useDefaultStyler at the right point" | widget | widget := self codePaneClass new. widget useDefaultStyler. widget on: aSpec model text: aSpec getText accept: aSpec setText readSelection: aSpec selection menu: aSpec menu. widget font: Preferences standardCodeFont. self register: widget id: aSpec name. widget getColorSelector: aSpec color. self setFrame: aSpec frame in: widget. parent ifNotNil:[self add: widget to: parent]. widget borderColor: Color lightGray. widget color: Color white. ^widget! Item was changed: + ----- Method: MorphicToolBuilder>>buildPluggableDropDownList: (in category 'widgets optional') ----- - ----- Method: MorphicToolBuilder>>buildPluggableDropDownList: (in category 'pluggable widgets') ----- buildPluggableDropDownList: spec | widget model listSelector selectionSelector selectionSetter | model := spec model. listSelector := spec listSelector. selectionSelector := spec selectionSelector. selectionSetter := spec selectionSetter. widget := self dropDownListClass new model: model; listSelector: listSelector; selectionSelector: selectionSelector; selectionSetter: selectionSetter; yourself. self register: widget id: spec name. widget installDropDownList. self setFrame: spec frame in: widget. parent ifNotNil:[self add: widget to: parent]. ^widget! Item was changed: + ----- Method: MorphicToolBuilder>>buildPluggableInputField: (in category 'widgets optional') ----- - ----- Method: MorphicToolBuilder>>buildPluggableInputField: (in category 'pluggable widgets') ----- buildPluggableInputField: aSpec | widget | widget := self buildPluggableText: aSpec. widget acceptOnCR: true. widget hideScrollBarsIndefinitely. widget wantsFrameAdornments: false. widget textMorph autoFit: false; wrapFlag: true; width: 999999. ^widget! Item was changed: + ----- Method: MorphicToolBuilder>>buildPluggableList: (in category 'widgets required') ----- - ----- Method: MorphicToolBuilder>>buildPluggableList: (in category 'pluggable widgets') ----- buildPluggableList: aSpec | widget listClass getIndex setIndex | aSpec getSelected ifNil:[ listClass := self listClass. getIndex := aSpec getIndex. setIndex := aSpec setIndex. ] ifNotNil:[ listClass := self listByItemClass. getIndex := aSpec getSelected. setIndex := aSpec setSelected. ]. widget := listClass on: aSpec model list: aSpec list selected: getIndex changeSelected: setIndex menu: aSpec menu keystroke: aSpec keyPress. self register: widget id: aSpec name. widget getListElementSelector: aSpec listItem. widget getListSizeSelector: aSpec listSize. widget getIconSelector: aSpec icon. widget getHelpSelector: aSpec help. widget doubleClickSelector: aSpec doubleClick. widget dragItemSelector: aSpec dragItem. widget dropItemSelector: aSpec dropItem. widget wantsDropSelector: aSpec dropAccept. widget autoDeselect: aSpec autoDeselect. widget keystrokePreviewSelector: aSpec keystrokePreview. aSpec color isNil ifTrue: [widget borderWidth: 1; borderColor: Color lightGray; color: Color white] ifFalse: [widget color: aSpec color]. self setFrame: aSpec frame in: widget. parent ifNotNil:[self add: widget to: parent]. panes ifNotNil:[ aSpec list ifNotNil:[panes add: aSpec list]. ]. ^widget! Item was changed: + ----- Method: MorphicToolBuilder>>buildPluggableMultiSelectionList: (in category 'widgets optional') ----- - ----- Method: MorphicToolBuilder>>buildPluggableMultiSelectionList: (in category 'pluggable widgets') ----- buildPluggableMultiSelectionList: aSpec | widget listClass | aSpec getSelected ifNotNil:[^self error:'There is no PluggableListMorphOfManyByItem']. listClass := self multiSelectListClass. widget := listClass on: aSpec model list: aSpec list primarySelection: aSpec getIndex changePrimarySelection: aSpec setIndex listSelection: aSpec getSelectionList changeListSelection: aSpec setSelectionList menu: aSpec menu. self register: widget id: aSpec name. widget keystrokeActionSelector: aSpec keyPress. widget getListElementSelector: aSpec listItem. widget getListSizeSelector: aSpec listSize. self buildHelpFor: widget spec: aSpec. self setFrame: aSpec frame in: widget. parent ifNotNil:[self add: widget to: parent]. panes ifNotNil:[ aSpec list ifNotNil:[panes add: aSpec list]. ]. ^widget! Item was changed: + ----- Method: MorphicToolBuilder>>buildPluggablePanel: (in category 'widgets required') ----- - ----- Method: MorphicToolBuilder>>buildPluggablePanel: (in category 'pluggable widgets') ----- buildPluggablePanel: aSpec | widget children frame | widget := self panelClass new. self register: widget id: aSpec name. widget model: aSpec model. widget color: Color transparent. widget clipSubmorphs: true. children := aSpec children. children isSymbol ifTrue:[ widget getChildrenSelector: children. widget update: children. children := #(). ]. self buildAll: children in: widget. self buildHelpFor: widget spec: aSpec. self setFrame: aSpec frame in: widget. parent ifNotNil:[self add: widget to: parent]. self setLayout: aSpec layout in: widget. widget layoutInset: 0. widget borderWidth: 0. widget submorphsDo:[:sm| (frame := sm layoutFrame) ifNotNil:[ (frame rightFraction = 0 or:[frame rightFraction = 1]) ifFalse:[frame rightOffset:1]. (frame bottomFraction = 0 or:[frame bottomFraction = 1]) ifFalse:[frame bottomOffset: 1]]]. widget color: Color transparent. ^widget! Item was changed: + ----- Method: MorphicToolBuilder>>buildPluggableText: (in category 'widgets required') ----- - ----- Method: MorphicToolBuilder>>buildPluggableText: (in category 'pluggable widgets') ----- buildPluggableText: aSpec | widget | widget := self textPaneClass on: aSpec model text: aSpec getText accept: aSpec setText readSelection: aSpec selection menu: aSpec menu. widget editTextSelector: aSpec editText. widget askBeforeDiscardingEdits: aSpec askBeforeDiscardingEdits. widget font: Preferences standardCodeFont. self register: widget id: aSpec name. widget getColorSelector: aSpec color. self buildHelpFor: widget spec: aSpec. self setFrame: aSpec frame in: widget. parent ifNotNil:[self add: widget to: parent]. widget borderColor: Color lightGray. widget color: Color white. ^widget! Item was changed: + ----- Method: MorphicToolBuilder>>buildPluggableTree: (in category 'widgets required') ----- - ----- Method: MorphicToolBuilder>>buildPluggableTree: (in category 'pluggable widgets') ----- buildPluggableTree: aSpec | widget | widget := self treeClass new. self register: widget id: aSpec name. widget model: aSpec model. widget getSelectedPathSelector: aSpec getSelectedPath. widget setSelectedSelector: aSpec setSelected. widget getSelectedSelector: aSpec getSelected. widget setSelectedParentSelector: aSpec setSelectedParent. widget getChildrenSelector: aSpec getChildren. widget hasChildrenSelector: aSpec hasChildren. widget getLabelSelector: aSpec label. widget getIconSelector: aSpec icon. widget getHelpSelector: aSpec help. widget getMenuSelector: aSpec menu. widget keystrokeActionSelector: aSpec keyPress. widget nodeClass: aSpec nodeClass. widget getRootsSelector: aSpec roots. widget autoDeselect: aSpec autoDeselect. widget dropItemSelector: aSpec dropItem. widget wantsDropSelector: aSpec dropAccept. widget dragItemSelector: aSpec dragItem. widget columns: aSpec columns. self setFrame: aSpec frame in: widget. parent ifNotNil:[self add: widget to: parent]. " panes ifNotNil:[ aSpec roots ifNotNil:[panes add: aSpec roots]. ]. " ^widget! Item was changed: + ----- Method: MorphicToolBuilder>>buildPluggableWindow: (in category 'widgets required') ----- - ----- Method: MorphicToolBuilder>>buildPluggableWindow: (in category 'pluggable widgets') ----- buildPluggableWindow: aSpec | widget children | aSpec layout == #proportional ifFalse:[ "This needs to be implemented - probably by adding a single pane and then the rest" ^self error: 'Not implemented'. ]. widget := (self windowClassFor: aSpec) new. self register: widget id: aSpec name. widget model: aSpec model. aSpec label ifNotNil: [:label| label isSymbol ifTrue:[widget getLabelSelector: label] ifFalse:[widget setLabel: label]]. aSpec multiWindowStyle notNil ifTrue: [widget savedMultiWindowState: (SavedMultiWindowState on: aSpec model)]. children := aSpec children. children isSymbol ifTrue:[ widget getChildrenSelector: children. widget update: children. children := #(). ]. widget closeWindowSelector: aSpec closeAction. panes := OrderedCollection new. self buildAll: children in: widget. self buildHelpFor: widget spec: aSpec. widget bounds: (RealEstateAgent initialFrameFor: widget initialExtent: (aSpec extent ifNil:[widget initialExtent]) world: self currentWorld). widget setUpdatablePanesFrom: panes. ^widget! From commits at source.squeak.org Sun Apr 12 16:32:04 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 16:32:04 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-MVC-mt.39.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-MVC to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-MVC-mt.39.mcz ==================== Summary ==================== Name: ToolBuilder-MVC-mt.39 Author: mt Time: 12 April 2015, 6:31:58.165 pm UUID: 2e8d6ace-8555-3845-8d8f-e28c085c4811 Ancestors: ToolBuilder-MVC-dtl.38 Messages re-organized. We need an MVC tree implementation... or a useful fall-back. (Apple's multi-column views?) =============== Diff against ToolBuilder-MVC-dtl.38 =============== Item was added: + ----- Method: MVCToolBuilder>>buildPluggableAlternateMultiSelectionList: (in category 'widgets optional') ----- + buildPluggableAlternateMultiSelectionList: aSpec + + "Trim selector to one argument to match list expectations." + aSpec setIndex: (aSpec setIndex first: (aSpec setIndex findString: ':')) asSymbol. + ^ self buildPluggableList: aSpec.! Item was changed: + ----- Method: MVCToolBuilder>>buildPluggableButton: (in category 'widgets required') ----- - ----- Method: MVCToolBuilder>>buildPluggableButton: (in category 'pluggable widgets') ----- buildPluggableButton: aSpec | widget label state | label := aSpec label. state := aSpec state. widget := PluggableButtonView on: aSpec model getState: (state isSymbol ifTrue:[state]) action: aSpec action label: (label isSymbol ifTrue:[label]). self register: widget id: aSpec name. label ifNotNil: [label isSymbol ifTrue: [widget label: (aSpec model perform: label)] ifFalse: [widget label: label]]. self setFrame: aSpec frame in: widget. parent ifNotNil: [parent addSubView: widget]. ^widget! Item was changed: + ----- Method: MVCToolBuilder>>buildPluggableList: (in category 'widgets required') ----- - ----- Method: MVCToolBuilder>>buildPluggableList: (in category 'pluggable widgets') ----- buildPluggableList: aSpec | widget listClass getIndex setIndex | aSpec getSelected ifNil:[ listClass := PluggableListView. getIndex := aSpec getIndex. setIndex := aSpec setIndex. ] ifNotNil:[ listClass := PluggableListViewByItem. getIndex := aSpec getSelected. setIndex := aSpec setSelected. ]. widget := listClass on: aSpec model list: aSpec list selected: getIndex changeSelected: setIndex menu: aSpec menu keystroke: aSpec keyPress. self register: widget id: aSpec name. self setFrame: aSpec frame in: widget. parent ifNotNil:[parent addSubView: widget]. panes ifNotNil:[ aSpec list ifNotNil:[panes add: aSpec list]. ]. ^widget! Item was changed: + ----- Method: MVCToolBuilder>>buildPluggablePanel: (in category 'widgets required') ----- - ----- Method: MVCToolBuilder>>buildPluggablePanel: (in category 'pluggable widgets') ----- buildPluggablePanel: aSpec | widget children | widget := View new model: aSpec model. self register: widget id: aSpec name. children := aSpec children. children isSymbol ifTrue:[ "@@@@ FIXME: PluggablePanes need to remember their getChildrenSelector" "widget getChildrenSelector: children. widget update: children." children := #(). ]. self setFrame: aSpec frame in: widget. self buildAll: children in: widget. parent ifNotNil:[parent addSubView: widget]. self setLayout: aSpec layout in: widget. ^widget! Item was changed: + ----- Method: MVCToolBuilder>>buildPluggableText: (in category 'widgets required') ----- - ----- Method: MVCToolBuilder>>buildPluggableText: (in category 'pluggable widgets') ----- buildPluggableText: aSpec | widget | widget := PluggableTextView on: aSpec model text: aSpec getText accept: aSpec setText readSelection: aSpec selection menu: aSpec menu. self register: widget id: aSpec name. self setFrame: aSpec frame in: widget. parent ifNotNil:[parent addSubView: widget]. panes ifNotNil:[ aSpec getText ifNotNil:[panes add: aSpec getText]. ]. ^widget! Item was added: + ----- Method: MVCToolBuilder>>buildPluggableTree: (in category 'widgets required') ----- + buildPluggableTree: aSpec + + self shouldBeImplemented.! Item was changed: + ----- Method: MVCToolBuilder>>buildPluggableWindow: (in category 'widgets required') ----- - ----- Method: MVCToolBuilder>>buildPluggableWindow: (in category 'pluggable widgets') ----- buildPluggableWindow: aSpec | widget children label | topSize := 0@0 corner: 640@480. aSpec layout == #proportional ifFalse:[ "This needs to be implemented - probably by adding a single pane and then the rest" ^self error: 'Not implemented'. ]. widget := StandardSystemView new. self register: widget id: aSpec name. widget model: aSpec model. label := aSpec label. label isSymbol ifTrue: [label := aSpec model perform: label]. label isNil ifFalse: [widget setLabel: label]. children := aSpec children. children isSymbol ifTrue:[ "This isn't implemented by StandardSystemView, so we fake it" children := widget model perform: children. ]. aSpec extent ifNotNil:[topSize := 0@0 extent: aSpec extent]. widget window: topSize. panes := OrderedCollection new. self buildAll: children in: widget. widget setUpdatablePanesFrom: panes. ^widget! From commits at source.squeak.org Sun Apr 12 16:33:45 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 16:33:47 2015 Subject: [squeak-dev] The Trunk: Tools-mt.583.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.583.mcz ==================== Summary ==================== Name: Tools-mt.583 Author: mt Time: 12 April 2015, 6:33:23.285 pm UUID: 263063d1-76b2-764d-aaad-3de55bbb20a8 Ancestors: Tools-mt.582 Compatibility for MVC. There are no fancy multi-selection lists in MVC. The callback must be simpler so that we can use regular lists there. =============== Diff against Tools-mt.582 =============== Item was added: + ----- Method: MessageTrace>>toggleSelectionAt: (in category 'actions') ----- + toggleSelectionAt: currentPosition + "Compatibility with MVC" + + ^ self + toggleSelectionAt: currentPosition + shifted: false + controlled: false! From karlramberg at gmail.com Sun Apr 12 16:35:18 2015 From: karlramberg at gmail.com (karl ramberg) Date: Sun Apr 12 16:35:22 2015 Subject: [squeak-dev] The Trunk: Tools-mt.582.mcz In-Reply-To: References: <552a87b8.9011370a.3349.ffff8fbeSMTPIN_ADDED_MISSING@mx.google.com> Message-ID: Hmm. I seems when you click explore/ inspect the current selection you "jump up" a level and then you lose the inspector/ explorer for the object you had in the previous tool. Eg: Inspect a object. Select it's instance variable Click Explore A explorer for the instance variable opens You can't go back to original object Karl On Sun, Apr 12, 2015 at 6:27 PM, karl ramberg wrote: > Hi, > You are making really nice enhancements :-) > > BTW : Could we preserve the selection in the list as well ? > Or are the list models too different for it to make sense ? > First level selection should probably work... > > Karl > > > > On Sun, Apr 12, 2015 at 4:56 PM, wrote: > >> Marcel Taeumel uploaded a new version of Tools to project The Trunk: >> http://source.squeak.org/trunk/Tools-mt.582.mcz >> >> ==================== Summary ==================== >> >> Name: Tools-mt.582 >> Author: mt >> Time: 12 April 2015, 4:56:27.909 pm >> UUID: 3ad55be5-74b1-f84f-98d1-b1cf671476d2 >> Ancestors: Tools-mt.581 >> >> Preserve expressions that were entered in the code pane in >> inspector/explorer when switching between those tools. >> >> =============== Diff against Tools-mt.581 =============== >> >> Item was changed: >> StringHolder subclass: #Inspector >> + instanceVariableNames: 'object selectionIndex >> timeOfLastListUpdate selectionUpdateTime context expression' >> - instanceVariableNames: 'object selectionIndex >> timeOfLastListUpdate selectionUpdateTime context' >> classVariableNames: '' >> poolDictionaries: '' >> category: 'Tools-Inspector'! >> >> !Inspector commentStamp: '' prior: 0! >> I represent a query path into the internal representation of an object. >> As a StringHolder, the string I represent is the value of the currently >> selected variable of the observed object.! >> >> Item was changed: >> ----- Method: Inspector>>buildCodePaneWith: (in category 'toolbuilder') >> ----- >> buildCodePaneWith: builder >> | textSpec | >> textSpec := builder pluggableTextSpec new. >> textSpec >> model: self; >> + getText: #expression; >> + editText: #expression:; >> - getText: #trash; >> - setText: #trash:; >> help: #helpText; >> selection: #contentsSelection; >> menu: #codePaneMenu:shifted:; >> askBeforeDiscardingEdits: false. >> ^textSpec! >> >> Item was changed: >> ----- Method: Inspector>>exploreObject (in category 'toolbuilder') ----- >> exploreObject >> "Switch to an explorer tool." >> >> + | window model | >> + window := self object explore. >> + model := window model. >> + >> + model setExpression: self expression. >> + window bounds: self containingWindow bounds. >> - self object explore >> - bounds: self containingWindow bounds. >> self changed: #close.! >> >> Item was added: >> + ----- Method: Inspector>>expression (in category 'accessing') ----- >> + expression >> + >> + ^ expression ifNil: ['']! >> >> Item was added: >> + ----- Method: Inspector>>expression: (in category 'accessing') ----- >> + expression: aString >> + >> + expression := aString.! >> >> Item was added: >> + ----- Method: Inspector>>setExpression: (in category 'code') ----- >> + setExpression: aString >> + >> + self expression: aString. >> + self changed: #expression.! >> >> Item was changed: >> AbstractHierarchicalList subclass: #ObjectExplorer >> + instanceVariableNames: 'root currentParent inspector monitorList >> expression' >> - instanceVariableNames: 'root currentParent inspector monitorList' >> classVariableNames: '' >> poolDictionaries: '' >> category: 'Tools-Explorer'! >> >> !ObjectExplorer commentStamp: '' prior: 0! >> ObjectExplorer provides a hierarchical alternative to #inspect. Simply >> evaluate an expression like: >> >> World explore >> >> and enjoy.! >> >> Item was changed: >> ----- Method: ObjectExplorer>>buildWith: (in category 'toolbuilder') >> ----- >> buildWith: builder >> >> | windowSpec treeSpec textSpec buttonSpec buttonOffset | >> windowSpec := builder pluggableWindowSpec new. >> windowSpec >> model: self; >> children: OrderedCollection new; >> label: #label; >> extent: self initialExtent. >> >> treeSpec := builder pluggableTreeSpec new. >> treeSpec >> model: self; >> nodeClass: self class nodeClass; >> roots: #getList; >> keyPress: #explorerKey:from:event:; >> getSelected: #currentSelection; >> setSelected: #currentSelection:; >> setSelectedParent: #currentParent:; >> menu: #genericMenu:; >> autoDeselect: false; >> columns: (ObjectExplorerWrapper showContentsInColumns >> ifTrue: [{ >> [:listMorph | (listMorph filteredItems >> collect: [:item | >> item preferredWidthOfColumn: 1]) >> max]. >> nil "take all the space"}]); >> frame: (0@0 corner: 1@0.75). >> windowSpec children add: treeSpec. >> >> buttonOffset := (Preferences standardButtonFont widthOfString: >> 'inspect') * 3/2. >> >> textSpec := builder pluggableTextSpec new. >> textSpec >> model: self; >> + getText: #expression; >> + editText: #expression:; >> menu: #codePaneMenu:shifted:; >> help: 'Evaluate expressions for the current tree >> selection...' translated; >> frame: (LayoutFrame fractions: (0@0.75 corner: 1@1) >> offsets: (0@0 corner: buttonOffset negated@0)). >> windowSpec children add: textSpec. >> >> buttonSpec := builder pluggableButtonSpec new >> model: self; >> label: 'inspect'; >> action: #inspectObject; >> help: 'Switch to an inspector tool'; >> frame: (LayoutFrame fractions: (1@0.75 corner: 1@1) >> offsets: (buttonOffset negated@0 corner: 0 @ 0)). >> windowSpec children add: buttonSpec. >> >> [^ builder build: windowSpec] >> ensure: [self changed: #expandRootsRequested]! >> >> Item was added: >> + ----- Method: ObjectExplorer>>expression (in category 'accessing') ----- >> + expression >> + >> + ^ expression! >> >> Item was added: >> + ----- Method: ObjectExplorer>>expression: (in category 'accessing') >> ----- >> + expression: aString >> + >> + expression := aString.! >> >> Item was changed: >> ----- Method: ObjectExplorer>>inspectObject (in category 'toolbuilder') >> ----- >> inspectObject >> "Switch to an inspector tool." >> >> + | window model | >> + window := self object inspect. >> + model := window model. >> + >> + model setExpression: self expression. >> + window bounds: self containingWindow bounds. >> - self object inspect >> - bounds: self containingWindow bounds. >> self changed: #close.! >> >> Item was added: >> + ----- Method: ObjectExplorer>>setExpression: (in category 'accessing - >> other') ----- >> + setExpression: aString >> + >> + self expression: aString. >> + self changed: #expression.! >> >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150412/a41e3fba/attachment.htm From karlramberg at gmail.com Sun Apr 12 16:43:11 2015 From: karlramberg at gmail.com (karl ramberg) Date: Sun Apr 12 16:43:15 2015 Subject: [squeak-dev] Re: The Trunk: HelpSystem-Core-mt.68.mcz In-Reply-To: <1428853341515-4819172.post@n4.nabble.com> References: <1428853341515-4819172.post@n4.nabble.com> Message-ID: On Sun, Apr 12, 2015 at 5:42 PM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > help-browser.png > > We should open the help browser in the new release to display important > information--not a workspace. > > This seems like a good way to go. The HelpBrowser is starting to become a really nice and useful tool. Karl > > > -- > View this message in context: > http://forum.world.st/The-Trunk-HelpSystem-Core-mt-68-mcz-tp4819171p4819172.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150412/fc3d2ba9/attachment.htm From commits at source.squeak.org Sun Apr 12 17:12:30 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 17:12:32 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-MVC-mt.40.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-MVC to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-MVC-mt.40.mcz ==================== Summary ==================== Name: ToolBuilder-MVC-mt.40 Author: mt Time: 12 April 2015, 7:12:26.033 pm UUID: a81e1177-3c7e-794a-a1d3-a7f6e2031070 Ancestors: ToolBuilder-MVC-mt.39 Do not try to give nil as tree spec. We have fall-backs for this. =============== Diff against ToolBuilder-MVC-mt.39 =============== Item was removed: - ----- Method: MVCToolBuilder>>pluggableTreeSpec (in category 'defaults') ----- - pluggableTreeSpec - "We have no tree widget in MVC right now" - ^nil! From commits at source.squeak.org Sun Apr 12 17:14:11 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 17:14:12 2015 Subject: [squeak-dev] The Trunk: Tools-mt.584.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.584.mcz ==================== Summary ==================== Name: Tools-mt.584 Author: mt Time: 12 April 2015, 7:13:53.589 pm UUID: a5f20353-d6c2-f84e-bf86-a470a2e42610 Ancestors: Tools-mt.583 Make file list tool work in MVC again. =============== Diff against Tools-mt.583 =============== Item was added: + ----- Method: FileList class>>openInMVC (in category 'mvc compatibility') ----- + openInMVC + "Open a view of an instance of me on the default directory." + + | dir aFileList topView volListView templateView fileListView fileContentsView underPane pHeight | + dir := FileDirectory default. + aFileList := self new directory: dir. + topView := StandardSystemView new. + topView + model: aFileList; + label: dir pathName; + minimumSize: 200@200. + topView borderWidth: 1. + + volListView := PluggableListView on: aFileList + list: #volumeList + selected: #volumeListIndex + changeSelected: #volumeListIndex: + menu: #volumeMenu:. + volListView autoDeselect: false. + volListView window: (0@0 extent: 80@45). + topView addSubView: volListView. + + templateView _ PluggableTextView on: aFileList + text: #pattern + accept: #pattern:. + templateView askBeforeDiscardingEdits: false. + templateView window: (0@0 extent: 80@15). + topView addSubView: templateView below: volListView. + + aFileList wantsOptionalButtons + ifTrue: + [underPane := aFileList optionalButtonViewForMVC. + underPane isNil + ifTrue: [pHeight := 60] + ifFalse: [ + topView addSubView: underPane toRightOf: volListView. + pHeight := 60 - aFileList optionalButtonHeight]] + ifFalse: + [underPane := nil. + pHeight := 60]. + + fileListView := PluggableListView on: aFileList + list: #fileList + selected: #fileListIndex + changeSelected: #fileListIndex: + menu: #fileListMenu:. + fileListView window: (0@0 extent: 120@pHeight). + underPane isNil + ifTrue: [topView addSubView: fileListView toRightOf: volListView] + ifFalse: [topView addSubView: fileListView below: underPane]. + fileListView controller terminateDuringSelect: true. "Pane to left may change under scrollbar" + + fileContentsView := PluggableTextView on: aFileList + text: #contents accept: #put: + readSelection: #contentsSelection menu: #fileContentsMenu:shifted:. + fileContentsView window: (0@0 extent: 200@140). + topView addSubView: fileContentsView below: templateView. + + topView controller open! Item was changed: ----- Method: FileList>>entriesMatching: (in category 'private') ----- entriesMatching: patternString "Answer a list of directory entries which match the patternString. The patternString may consist of multiple patterns separated by ';'. Each pattern can include a '*' or '#' as wildcards - see String>>match:" | entries patterns | + entries := directory entries reject:[:e| Smalltalk isMorphic and: [e isDirectory]]. - entries := directory entries reject:[:e| e isDirectory]. patterns := patternString findTokens: ';'. (patterns anySatisfy: [:each | each = '*']) ifTrue: [^ entries]. ^ entries select: [:entry | patterns anySatisfy: [:each | each match: entry name]]! Item was added: + ----- Method: FileList>>optionalButtonViewForMVC (in category 'mvc compatibility') ----- + optionalButtonViewForMVC + "Answer a view of optional buttons" + + | aView bHeight windowWidth offset previousView aButtonView wid services sel allServices | + aView := View new model: self. + bHeight := self optionalButtonHeight. + windowWidth := 120. + aView window: (0 @ 0 extent: windowWidth @ bHeight). + offset := 0. + allServices := self universalButtonServices. + services := allServices copyFrom: 1 to: (allServices size min: 5). + previousView := nil. + services + do: [:service | sel := service selector. + aButtonView := sel asString numArgs = 0 + ifTrue: [PluggableButtonView + on: service provider + getState: (service extraSelector == #none + ifFalse: [service extraSelector]) + action: sel] + ifFalse: [PluggableButtonView + on: service provider + getState: (service extraSelector == #none + ifFalse: [service extraSelector]) + action: sel + getArguments: #fullName + from: self]. + service selector = services last selector + ifTrue: [wid := windowWidth - offset] + ifFalse: [aButtonView + borderWidthLeft: 0 + right: 1 + top: 0 + bottom: 0. + wid := windowWidth // services size - 2]. + aButtonView label: service buttonLabel asParagraph; + window: (offset @ 0 extent: wid @ bHeight). + offset := offset + wid. + service selector = services first selector + ifTrue: [aView addSubView: aButtonView] + ifFalse: [aView addSubView: aButtonView toRightOf: previousView]. + previousView := aButtonView]. + ^ aView! From commits at source.squeak.org Sun Apr 12 17:15:23 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 17:15:24 2015 Subject: [squeak-dev] The Trunk: ST80Tools-mt.5.mcz Message-ID: Marcel Taeumel uploaded a new version of ST80Tools to project The Trunk: http://source.squeak.org/trunk/ST80Tools-mt.5.mcz ==================== Summary ==================== Name: ST80Tools-mt.5 Author: mt Time: 12 April 2015, 7:15:18.831 pm UUID: 87d40711-287a-2a4d-8752-26c8e9881221 Ancestors: ST80Tools-bf.4 Use explicit MVC hook to open a file list. We have to do this, because we have to fall-back for pluggable trees yet and thus cannot use the normal way to build a tool for the FileList model. =============== Diff against ST80Tools-bf.4 =============== Item was changed: ----- Method: ScreenController>>openFileList (in category '*ST80Tools') ----- openFileList "Create and schedule a FileList view for specifying files to access." + FileList openInMVC! - FileList open! From asqueaker at gmail.com Sun Apr 12 18:35:09 2015 From: asqueaker at gmail.com (Chris Muller) Date: Sun Apr 12 18:35:11 2015 Subject: [squeak-dev] Re: Two bugs. One of them is a regression. In-Reply-To: <1428834807779-4819138.post@n4.nabble.com> References: <1428812182.17235.0@mglap> <1428834807779-4819138.post@n4.nabble.com> Message-ID: On Sun, Apr 12, 2015 at 5:33 AM, Marcel Taeumel wrote: > The modality in the UserDialogBoxMorph is implemented via holding both mouse > and keyboard focus. The halo takes the mouse focus away when growing or > dragging a morph--without signaling it to the former focus holder. After > that, the modal behavior is lost. However, the dialog is still useful as > long as it is in the world because it still triggers a world's sub-cycle. Yeah, it doesn't seem like a very big problem. In fact, now that I know about it I'll probably find it useful so I _don't_ have to press the break key.. Its a "feature"! :) From asqueaker at gmail.com Sun Apr 12 18:36:50 2015 From: asqueaker at gmail.com (Chris Muller) Date: Sun Apr 12 18:36:53 2015 Subject: [squeak-dev] Re: The Trunk: Morphic-mt.865.mcz In-Reply-To: <1428842563120-4819149.post@n4.nabble.com> References: <1428842563120-4819149.post@n4.nabble.com> Message-ID: So do we still need the pink background at all then? I think we should consider ditching it now! On Sun, Apr 12, 2015 at 7:42 AM, Marcel Taeumel wrote: > > > Best, > Marcel > > > > -- > View this message in context: http://forum.world.st/The-Trunk-Morphic-mt-865-mcz-tp4819147p4819149.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > From commits at source.squeak.org Sun Apr 12 19:06:02 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 19:06:03 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Kernel-mt.76.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Kernel to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Kernel-mt.76.mcz ==================== Summary ==================== Name: ToolBuilder-Kernel-mt.76 Author: mt Time: 12 April 2015, 9:05:55.135 pm UUID: 19c6b708-a969-4b48-ae05-936532d6a747 Ancestors: ToolBuilder-Kernel-mt.75 Pluggable menus as required widgets added. =============== Diff against ToolBuilder-Kernel-mt.75 =============== Item was added: + ----- Method: ToolBuilder>>buildPluggableMenu: (in category 'widgets required') ----- + buildPluggableMenu: menuSpec + + self subclassResponsibility.! Item was added: + ----- Method: ToolBuilder>>buildPluggableMenuItem: (in category 'widgets required') ----- + buildPluggableMenuItem: menuSpec + + self subclassResponsibility.! From commits at source.squeak.org Sun Apr 12 19:07:17 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 19:07:19 2015 Subject: [squeak-dev] The Trunk: Services-Base-mt.55.mcz Message-ID: Marcel Taeumel uploaded a new version of Services-Base to project The Trunk: http://source.squeak.org/trunk/Services-Base-mt.55.mcz ==================== Summary ==================== Name: Services-Base-mt.55 Author: mt Time: 12 April 2015, 9:07:10.492 pm UUID: 3b374e3f-27ec-ff4f-9af9-89da39d9d38b Ancestors: Services-Base-topa.54 MVC compatibility. =============== Diff against Services-Base-topa.54 =============== Item was changed: ----- Method: ServiceGui>>menuItemForAction: (in category 'serviceactions') ----- menuItemForAction: aServiceAction "Returns a menuItem triggering self" self menu add: (aServiceAction menuLabelNumbered: self n) target: aServiceAction selector: #execute. + Smalltalk isMorphic ifTrue: [ + self menu lastItem isEnabled: aServiceAction executeCondition. + self menu balloonTextForLastItem: aServiceAction description]! - self menu lastItem isEnabled: aServiceAction executeCondition. - self menu balloonTextForLastItem: aServiceAction description! From commits at source.squeak.org Sun Apr 12 19:09:49 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 19:09:54 2015 Subject: [squeak-dev] The Trunk: System-mt.722.mcz Message-ID: Marcel Taeumel uploaded a new version of System to project The Trunk: http://source.squeak.org/trunk/System-mt.722.mcz ==================== Summary ==================== Name: System-mt.722 Author: mt Time: 12 April 2015, 9:08:20.54 pm UUID: 44ce6f36-9f13-6e44-b430-ef5a8933a51c Ancestors: System-ul.721 MVC compatibility fix for the "Do..." menu. =============== Diff against System-ul.721 =============== Item was changed: ----- Method: Utilities class>>offerCommonRequests (in category 'common requests') ----- offerCommonRequests "Offer up the common-requests menu. If the user chooses one, then evaluate it, and -- provided the value is a number or string -- show it in the Transcript." "Utilities offerCommonRequests" + | reply result index normalItemCount strings lines | - | reply result aMenu index normalItemCount strings | Smalltalk isMorphic ifTrue: [^ self offerCommonRequestsInMorphic]. (CommonRequestStrings == nil or: [CommonRequestStrings isKindOf: Array]) ifTrue: [self initializeCommonRequestStrings]. strings := CommonRequestStrings contents. + lines := strings asString lines copyWith: 'edit this menu'. + normalItemCount := lines size - 1. + + index := UIManager default + chooseFrom: lines - normalItemCount := strings asString lineCount. - aMenu := UIManager default - chooseFrom: (strings asString lines copyWith: 'edit this menu') lines: (Array with: normalItemCount). - index := aMenu startUp. index = 0 ifTrue: [^ self]. - reply := aMenu labelString lineNumber: index. - reply size = 0 ifTrue: [^ self]. index > normalItemCount ifTrue: [^ self editCommonRequestStrings]. + reply := lines at: index. + reply size = 0 ifTrue: [^ self]. + + result := Compiler evaluate: reply. - result := self evaluate: reply in: nil to: nil. (result isNumber) | (result isString) ifTrue: [Transcript cr; nextPutAll: result printString]! From commits at source.squeak.org Sun Apr 12 19:12:01 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 19:12:03 2015 Subject: [squeak-dev] The Trunk: Tools-mt.585.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.585.mcz ==================== Summary ==================== Name: Tools-mt.585 Author: mt Time: 12 April 2015, 9:10:55.87 pm UUID: 691d31e5-ac8b-654f-80fe-12e17c85d60f Ancestors: Tools-mt.584 Some models assume Morphic. This is not good. Added some guards to make those models work with MVC. =============== Diff against Tools-mt.584 =============== Item was changed: ----- Method: CodeHolder>>listPaneWithSelector: (in category 'categories & search pane') ----- listPaneWithSelector: aSelector "If, among my window's paneMorphs, there is a list pane defined with aSelector as its retriever, answer it, else answer nil" | aWindow | + Smalltalk isMorphic ifFalse: [^ nil]. ^ (aWindow := self containingWindow) ifNotNil: [aWindow paneMorphSatisfying: [:aMorph | (aMorph isKindOf: PluggableListMorph) and: [aMorph getListSelector == aSelector]]]! Item was added: + ----- Method: CustomMenu>>add:target:selector: (in category 'compatibility') ----- + add: aString target: target selector: aSymbol + + self add: aString + target: target + selector: aSymbol + argumentList: #()! Item was changed: ----- Method: Inspector>>buildWith: (in category 'toolbuilder') ----- buildWith: builder "Inspector openOn: SystemOrganization" + | windowSpec specs buttonOffset wantsExploreButton | + wantsExploreButton := Smalltalk isMorphic. - | windowSpec buttonOffset | buttonOffset := (Preferences standardButtonFont widthOfString: 'explore') * 3/2. + + self flag: #mvc. "mt: We can remove this if we can build trees in MVC and thus have a working object explorer there." + specs := { - windowSpec := self buildWindowWith: builder specs: { (0@0 corner: 0.3@0.75) -> [self buildFieldListWith: builder]. + (0.3@0.0corner: 1@0.75) -> [self buildValuePaneWith: builder]}, + (wantsExploreButton + ifTrue: [{ + (LayoutFrame fractions: (0@0.75 corner: 1@1) offsets: (0@0 corner: buttonOffset negated@0)) -> [self buildCodePaneWith: builder]. + (LayoutFrame fractions: (1@0.75 corner: 1@1) offsets: (buttonOffset negated@0 corner: 0 @ 0)) -> [self buildExploreButtonWith: builder].}] + ifFalse: [{(0.0@0.7corner: 1@1) -> [self buildCodePaneWith: builder]}]). + + windowSpec := self buildWindowWith: builder specs: specs. - (0.3@0.0corner: 1@0.75) -> [self buildValuePaneWith: builder]. - (LayoutFrame fractions: (0@0.75 corner: 1@1) offsets: (0@0 corner: buttonOffset negated@0)) -> [self buildCodePaneWith: builder]. - (LayoutFrame fractions: (1@0.75 corner: 1@1) offsets: (buttonOffset negated@0 corner: 0 @ 0)) -> [self buildExploreButtonWith: builder]. - }. windowSpec extent: self initialExtent. ^builder build: windowSpec! Item was changed: ----- Method: MessageSet>>modelWakeUp (in category 'user interface') ----- modelWakeUp "A window with me as model has been activated." - | tm | super modelWakeUp. + (self canDiscardEdits and: [autoSelectString notNil]) ifTrue: [ + self codeTextMorph ifNotNil: [:tm | + (tm hasProperty: #launched) ifFalse: [ + tm scrollSelectionIntoView. + tm setProperty: #launched toValue: true] ] ]! - (self canDiscardEdits and: [autoSelectString notNil]) ifTrue: - [tm := self codeTextMorph. - (tm hasProperty: #launched) ifFalse: - [tm scrollSelectionIntoView. - tm setProperty: #launched toValue: true] - ]! Item was changed: ----- Method: StringHolder>>textPaneWithSelector: (in category '*Tools') ----- textPaneWithSelector: aSelector "If, among my window's paneMorphs, there is a text pane defined with aSelector as its retriever, answer it, else answer nil" | aWindow | + Smalltalk isMorphic ifFalse: [^ nil]. ^ (aWindow := self containingWindow) ifNotNil: [aWindow paneMorphSatisfying: [:aMorph | (aMorph isKindOf: PluggableTextMorph) and: [aMorph getTextSelector == aSelector]]]! From commits at source.squeak.org Sun Apr 12 19:12:45 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 19:12:46 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-MVC-mt.41.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-MVC to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-MVC-mt.41.mcz ==================== Summary ==================== Name: ToolBuilder-MVC-mt.41 Author: mt Time: 12 April 2015, 9:12:29.901 pm UUID: 7e3ddec1-1470-dd41-8840-93ac896551dc Ancestors: ToolBuilder-MVC-mt.40 Fixes regarding pluggable menus and opening tools. =============== Diff against ToolBuilder-MVC-mt.40 =============== Item was changed: ToolBuilder subclass: #MVCToolBuilder + instanceVariableNames: 'panes topSize widgets parentMenu' - instanceVariableNames: 'panes topSize widgets' classVariableNames: '' poolDictionaries: '' category: 'ToolBuilder-MVC'! !MVCToolBuilder commentStamp: 'ar 2/11/2005 15:02' prior: 0! The MVC tool builder.! Item was added: + ----- Method: MVCToolBuilder>>buildPluggableMenu: (in category 'widgets required') ----- + buildPluggableMenu: menuSpec + "Just a very simple mapping to selection menu. It assumes that all item specs have the same receiver." + + | menu | + menu := CustomMenu new. + menuSpec items do: [:ea | + menu + add: ea label + target: ea action receiver + selector: ea action selector + argumentList: ea action arguments. + ea separator ifTrue: [menu addLine]]. + ^ menu! Item was added: + ----- Method: MVCToolBuilder>>buildPluggableMenuItem: (in category 'widgets required') ----- + buildPluggableMenuItem: itemSpec + + ^ itemSpec label! Item was changed: ----- Method: MVCToolBuilder>>buildPluggablePanel: (in category 'widgets required') ----- buildPluggablePanel: aSpec | widget children | widget := View new model: aSpec model. + widget borderWidth: 1. self register: widget id: aSpec name. children := aSpec children. children isSymbol ifTrue:[ "@@@@ FIXME: PluggablePanes need to remember their getChildrenSelector" "widget getChildrenSelector: children. widget update: children." children := #(). ]. self setFrame: aSpec frame in: widget. self buildAll: children in: widget. parent ifNotNil:[parent addSubView: widget]. self setLayout: aSpec layout in: widget. ^widget! Item was changed: ----- Method: MVCToolBuilder>>open: (in category 'opening') ----- open: anObject "Build and open the object. Answer the widget opened." | window | + window := (anObject isKindOf: View) + ifTrue: [anObject] + ifFalse: [self build: anObject]. + (window isKindOf: PopUpMenu) + ifTrue: [window invokeOn: nil]. + (window isKindOf: View) + ifTrue: [window controller open]. - window := self build: anObject. - window controller open. ^window! Item was changed: ----- Method: MVCToolBuilder>>runModal: (in category 'opening') ----- runModal: aWidget "Run the (previously opened) widget modally, e.g., do not return control to the sender before the user has responded." + ! - self error: 'Please implement me'.! From commits at source.squeak.org Sun Apr 12 19:13:44 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 19:13:45 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.125.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.125.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.125 Author: mt Time: 12 April 2015, 9:13:36.15 pm UUID: 439aa91f-e743-484c-b3de-ab565e2cfdfe Ancestors: ToolBuilder-Morphic-mt.124 Pluggable menus recategorized as required widgets. =============== Diff against ToolBuilder-Morphic-mt.124 =============== Item was changed: + ----- Method: MorphicToolBuilder>>buildPluggableMenu: (in category 'widgets required') ----- - ----- Method: MorphicToolBuilder>>buildPluggableMenu: (in category 'building') ----- buildPluggableMenu: menuSpec | prior menu | prior := parentMenu. parentMenu := menu := self menuClass new. menuSpec label ifNotNil:[parentMenu addTitle: menuSpec label]. menuSpec items do:[:each| each buildWith: self]. parentMenu := prior. ^menu! Item was changed: + ----- Method: MorphicToolBuilder>>buildPluggableMenuItem: (in category 'widgets required') ----- - ----- Method: MorphicToolBuilder>>buildPluggableMenuItem: (in category 'building') ----- buildPluggableMenuItem: itemSpec | item action label menu | item := self menuItemClass new. label := (itemSpec isCheckable ifTrue: [ itemSpec checked ifTrue: [''] ifFalse: ['']] ifFalse: ['']), itemSpec label. item contents: label. item isEnabled: itemSpec enabled. (action := itemSpec action) ifNotNil:[ item target: action receiver; selector: action selector; arguments: action arguments. ]. (menu := itemSpec subMenu) ifNotNil:[ item subMenu: (menu buildWith: self). ]. parentMenu ifNotNil:[parentMenu addMorphBack: item]. itemSpec separator ifTrue:[parentMenu addLine]. ^item! From commits at source.squeak.org Sun Apr 12 19:15:41 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 19:15:42 2015 Subject: [squeak-dev] The Trunk: ST80-mt.179.mcz Message-ID: Marcel Taeumel uploaded a new version of ST80 to project The Trunk: http://source.squeak.org/trunk/ST80-mt.179.mcz ==================== Summary ==================== Name: ST80-mt.179 Author: mt Time: 12 April 2015, 9:15:30.231 pm UUID: 890f2b8f-21de-a647-8f0e-f78143e46401 Ancestors: ST80-mt.178 Some MVC fixes in main menu and modal controller. =============== Diff against ST80-mt.178 =============== Item was added: + ----- Method: ModalController>>closeAndUnscheduleNoTerminate (in category 'as yet unclassified') ----- + closeAndUnscheduleNoTerminate + "Erase the receiver's view and remove it from the collection of scheduled views, but do not terminate the current process." + + view erase. + view release. + ScheduledControllers unschedule: self.! Item was changed: ----- Method: ScreenController>>openMenu (in category 'nested menus') ----- openMenu "Smalltalk hasMorphic ifTrue: [^self openMenuWithMorphicOptions]." ^ SelectionMenu labelList: + #( - #( 'keep this menu up' - 'browser' 'package browser' 'method finder' 'workspace' 'file list' 'file...' 'transcript' 'simple change sorter' 'dual change sorter' 'new project' ) lines: #(1 8 10) + selections: #(openBrowser openPackageBrowser openSelectorBrowser openWorkspace openFileList openFile openTranscript - selections: #(durableOpenMenu - openBrowser openPackageBrowser openSelectorBrowser openWorkspace openFileList openFile openTranscript openSimpleChangeSorter openChangeManager openProject ) " ScreenController new openMenu startUp "! Item was changed: ----- Method: ScreenController>>openMenuWithMorphicOptions (in category 'nested menus') ----- openMenuWithMorphicOptions "Include 'morphic world' and 'morphic project' selections" ^ SelectionMenu labelList: + #( 'browser' - #( 'keep this menu up' - - 'browser' 'package browser' 'method finder' 'workspace' 'file list' 'file...' 'transcript' 'morphic world' 'simple change sorter' 'dual change sorter' 'mvc project' 'morphic project' ) lines: #(1 9 11) + selections: #(openBrowser openPackageBrowser openSelectorBrowser openWorkspace openFileList openFile openTranscript openMorphicWorld - selections: #(durableOpenMenu - openBrowser openPackageBrowser openSelectorBrowser openWorkspace openFileList openFile openTranscript openMorphicWorld openSimpleChangeSorter openChangeManager openProject openMorphicProject ) " ScreenController new openMenuWithMorphicOptions startUp "! From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 12 19:12:39 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 12 19:25:40 2015 Subject: [squeak-dev] MVC in Squeak 4.6/5.0 *thumbs up* Message-ID: <1428865959960-4819215.post@n4.nabble.com> I got rid of several nasty bugs. Seems to work fine now except for some visual glitches. Best, Marcel -- View this message in context: http://forum.world.st/MVC-in-Squeak-4-6-5-0-thumbs-up-tp4819215.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Sun Apr 12 19:30:27 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 19:30:30 2015 Subject: [squeak-dev] The Trunk: Tools-mt.586.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.586.mcz ==================== Summary ==================== Name: Tools-mt.586 Author: mt Time: 12 April 2015, 9:30:07.393 pm UUID: 79784972-f538-694e-9db7-3ad3b5a310e8 Ancestors: Tools-mt.585 Fix for object explorer to inspect the root object when switching to an inspector. =============== Diff against Tools-mt.585 =============== Item was changed: ----- Method: ObjectExplorer>>inspectObject (in category 'toolbuilder') ----- inspectObject "Switch to an inspector tool." | window model | + window := self rootObject inspect. - window := self object inspect. model := window model. model setExpression: self expression. window bounds: self containingWindow bounds. self changed: #close.! From marcel.taeumel at student.hpi.uni-potsdam.de Sun Apr 12 19:18:04 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Sun Apr 12 19:31:04 2015 Subject: [squeak-dev] Re: The Trunk: Tools-mt.582.mcz In-Reply-To: References: Message-ID: <1428866284833-4819217.post@n4.nabble.com> Thanks. :) http://forum.world.st/The-Trunk-Tools-mt-586-mcz-td4819216.html Best, Marcel -- View this message in context: http://forum.world.st/The-Trunk-Tools-mt-582-mcz-tp4819168p4819217.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From unoduetre at poczta.onet.pl Sun Apr 12 20:07:54 2015 From: unoduetre at poczta.onet.pl (Mateusz Grotek) Date: Sun Apr 12 19:55:45 2015 Subject: [SPAM] [squeak-dev] MVC in Squeak 4.6/5.0 *thumbs up* In-Reply-To: <1428865959960-4819215.post@n4.nabble.com> (from marcel.taeumel@student.hpi.uni-potsdam.de on Sun Apr 12 21:12:39 2015) References: <1428865959960-4819215.post@n4.nabble.com> Message-ID: <1428869274.24532.0@mglap> Dnia 12.04.2015 21:12:39, Marcel Taeumel napisa?(a): > > > I got rid of several nasty bugs. Seems to work fine now except for > some > visual glitches. > > Best, > Marcel > > Thats great! From Das.Linux at gmx.de Sun Apr 12 20:11:57 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Sun Apr 12 20:11:56 2015 Subject: [squeak-dev] Two bugs. One of them is a regression. In-Reply-To: <1428812182.17235.0@mglap> References: <1428812182.17235.0@mglap> Message-ID: <1FA3752A-CF49-41B5-84C8-77E81105148D@gmx.de> On 12.04.2015, at 06:16, Mateusz Grotek wrote: > I've found two bugs in the current Squeak 4.5 #13712. Please tell me if they're known. If not I'll create the tickets. > > Firstly, there is a regression. > 1. Create a class called (for example) ABC. > 2. Add an instance variable called (for example) xyz. > 3. Open the class comment panel (click on the button "?"). > 4. The contents of it is: > An ABC is xxxxxxxxx. > > Instance Variables > xyz:[TAB][TAB] > > xyz > - xxxxx > 5. Remove the [TAB]s > 6. Accept it > 7. An unrecoverable error shows up (after performing steps above it keeps appearing when accessing the ABC class): > Error: RemoteString past end of file > The error comes from RemoteString>>text It may be we know that. Are you on ubuntu? Best -Tobias From karlramberg at gmail.com Sun Apr 12 20:12:59 2015 From: karlramberg at gmail.com (karl ramberg) Date: Sun Apr 12 20:13:02 2015 Subject: [squeak-dev] Re: The Trunk: Tools-mt.582.mcz In-Reply-To: <1428866284833-4819217.post@n4.nabble.com> References: <1428866284833-4819217.post@n4.nabble.com> Message-ID: Great Karl On Sun, Apr 12, 2015 at 9:18 PM, Marcel Taeumel < marcel.taeumel@student.hpi.uni-potsdam.de> wrote: > Thanks. :) > > http://forum.world.st/The-Trunk-Tools-mt-586-mcz-td4819216.html > > Best, > Marcel > > > > -- > View this message in context: > http://forum.world.st/The-Trunk-Tools-mt-582-mcz-tp4819168p4819217.html > Sent from the Squeak - Dev mailing list archive at Nabble.com. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150412/935d9997/attachment.htm From unoduetre at poczta.onet.pl Sun Apr 12 20:33:18 2015 From: unoduetre at poczta.onet.pl (Mateusz Grotek) Date: Sun Apr 12 20:21:43 2015 Subject: [squeak-dev] Two bugs. One of them is a regression. In-Reply-To: <1FA3752A-CF49-41B5-84C8-77E81105148D@gmx.de> (from Das.Linux@gmx.de on Sun Apr 12 22:11:57 2015) References: <1428812182.17235.0@mglap> <1FA3752A-CF49-41B5-84C8-77E81105148D@gmx.de> Message-ID: <1428870798.24532.1@mglap> Dnia 12.04.2015 22:11:57, Tobias Pape napisa?(a): > > On 12.04.2015, at 06:16, Mateusz Grotek > wrote: > > > I've found two bugs in the current Squeak 4.5 #13712. Please tell > me if they're known. If not I'll create the tickets. > > > > Firstly, there is a regression. > > 1. Create a class called (for example) ABC. > > 2. Add an instance variable called (for example) xyz. > > 3. Open the class comment panel (click on the button "?"). > > 4. The contents of it is: > > An ABC is xxxxxxxxx. > > > > Instance Variables > > xyz:[TAB][TAB] > > > > xyz > > - xxxxx > > 5. Remove the [TAB]s > > 6. Accept it > > 7. An unrecoverable error shows up (after performing steps above it > keeps appearing when accessing the ABC class): > > Error: RemoteString past end of file > > The error comes from RemoteString>>text > > It may be we know that. > Are you on ubuntu? > > Best > -Tobias > > > No, but on Linux (Gentoo). From Das.Linux at gmx.de Sun Apr 12 21:01:43 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Sun Apr 12 21:01:50 2015 Subject: [squeak-dev] Two bugs. One of them is a regression. In-Reply-To: <1428870798.24532.1@mglap> References: <1428812182.17235.0@mglap> <1FA3752A-CF49-41B5-84C8-77E81105148D@gmx.de> <1428870798.24532.1@mglap> Message-ID: <4CD105A2-86C3-43D2-93F9-FF9EBC7325FD@gmx.de> On 12.04.2015, at 22:33, Mateusz Grotek wrote: > Dnia 12.04.2015 22:11:57, Tobias Pape napisa?(a): >> On 12.04.2015, at 06:16, Mateusz Grotek wrote: >> > I've found two bugs in the current Squeak 4.5 #13712. Please tell me if they're known. If not I'll create the tickets. >> > >> > Firstly, there is a regression. >> > 1. Create a class called (for example) ABC. >> > 2. Add an instance variable called (for example) xyz. >> > 3. Open the class comment panel (click on the button "?"). >> > 4. The contents of it is: >> > An ABC is xxxxxxxxx. >> > >> > Instance Variables >> > xyz:[TAB][TAB] >> > >> > xyz >> > - xxxxx >> > 5. Remove the [TAB]s >> > 6. Accept it >> > 7. An unrecoverable error shows up (after performing steps above it keeps appearing when accessing the ABC class): >> > Error: RemoteString past end of file >> > The error comes from RemoteString>>text >> It may be we know that. >> Are you on ubuntu? >> Best >> -Tobias > No, but on Linux (Gentoo). If you put a self flush at the end of WriteStream>>nextChunkPut: does that help? best -Tobias From commits at source.squeak.org Sun Apr 12 21:55:04 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 21:55:07 2015 Subject: [squeak-dev] Daily Commit Log Message-ID: <20150412215504.1019.qmail@box4.squeakfoundation.org> Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours: http://lists.squeakfoundation.org/pipermail/packages/2015-April/007910.html Name: Collections-ul.617 Ancestors: Collections-ul.616 LRUCache changes: - added a #reset method, which removes all elements from the cache - replaced the Arrays storing the list of elements with custom classes (LRUCacheHeadNode and LRUCacheNode). - fix: the map variable gets correctly updated, when the cache is full ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007911.html Name: Morphic-mt.863 Ancestors: Morphic-ul.862 Help text for search bar updated. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007912.html Name: Morphic-mt.864 Ancestors: Morphic-mt.863 Let system windows release mouse and keyboard focus the correct way to give current focus holders a chance to update. Note: #releaseAllFoci is for internal use in HandMorph only. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007913.html Name: Morphic-mt.865 Ancestors: Morphic-mt.864 Add highlight for the matching filter term in lists. It is cached like icons and items are. Why useful? If you do not reset the filter automatically, it is now easier to recognize after which term the list is filtered. It also makes the existing filter adaption visible, which tries to avoid empty results. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007914.html Name: Kernel-mt.918 Ancestors: Kernel-bf.917 Added a non-specific way to access all elements from a categorizer. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007915.html Name: Tools-mt.580 Ancestors: Tools-topa.579 For the sake of consistency, added '-- all --' category to the list of system categories. Skipped creation of class hierarchy in that case. Too slow.... ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007916.html Name: Morphic-mt.866 Ancestors: Morphic-mt.865 Fix for filter highlight: Now correctly converts items into strings just like the display-routine does. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007917.html Name: Tools-mt.581 Ancestors: Tools-mt.580 For Bert: Added a button to easily switch between inspector and object explorer. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007918.html Name: Tools-mt.582 Ancestors: Tools-mt.581 Preserve expressions that were entered in the code pane in inspector/explorer when switching between those tools. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007919.html Name: HelpSystem-Core-mt.68 Ancestors: HelpSystem-Core-mt.67 Concurrent search added to help browser. Having this, we can also search web contents. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007920.html Name: ToolBuilder-Kernel-mt.75 Ancestors: ToolBuilder-Kernel-mt.74 Missing optional widget added to tool builder. Fall-back to regular list. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007921.html Name: ToolBuilder-Morphic-mt.124 Ancestors: ToolBuilder-Morphic-mt.123 Morphic tool builder messages re-organized. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007922.html Name: ToolBuilder-MVC-mt.39 Ancestors: ToolBuilder-MVC-dtl.38 Messages re-organized. We need an MVC tree implementation... or a useful fall-back. (Apple's multi-column views?) ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007923.html Name: Tools-mt.583 Ancestors: Tools-mt.582 Compatibility for MVC. There are no fancy multi-selection lists in MVC. The callback must be simpler so that we can use regular lists there. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007924.html Name: ToolBuilder-MVC-mt.40 Ancestors: ToolBuilder-MVC-mt.39 Do not try to give nil as tree spec. We have fall-backs for this. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007925.html Name: Tools-mt.584 Ancestors: Tools-mt.583 Make file list tool work in MVC again. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007926.html Name: ST80Tools-mt.5 Ancestors: ST80Tools-bf.4 Use explicit MVC hook to open a file list. We have to do this, because we have to fall-back for pluggable trees yet and thus cannot use the normal way to build a tool for the FileList model. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007927.html Name: ToolBuilder-Kernel-mt.76 Ancestors: ToolBuilder-Kernel-mt.75 Pluggable menus as required widgets added. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007928.html Name: Services-Base-mt.55 Ancestors: Services-Base-topa.54 MVC compatibility. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007929.html Name: System-mt.722 Ancestors: System-ul.721 MVC compatibility fix for the "Do..." menu. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007930.html Name: Tools-mt.585 Ancestors: Tools-mt.584 Some models assume Morphic. This is not good. Added some guards to make those models work with MVC. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007931.html Name: ToolBuilder-MVC-mt.41 Ancestors: ToolBuilder-MVC-mt.40 Fixes regarding pluggable menus and opening tools. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007932.html Name: ToolBuilder-Morphic-mt.125 Ancestors: ToolBuilder-Morphic-mt.124 Pluggable menus recategorized as required widgets. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007933.html Name: ST80-mt.179 Ancestors: ST80-mt.178 Some MVC fixes in main menu and modal controller. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007934.html Name: Tools-mt.586 Ancestors: Tools-mt.585 Fix for object explorer to inspect the root object when switching to an inspector. ============================================= From commits at source.squeak.org Sun Apr 12 22:17:51 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Sun Apr 12 22:17:54 2015 Subject: [squeak-dev] The Trunk: Collections-ul.618.mcz Message-ID: Levente Uzonyi uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections-ul.618.mcz ==================== Summary ==================== Name: Collections-ul.618 Author: ul Time: 13 April 2015, 12:08:16.127 am UUID: 5a6b50bd-668b-48d1-b4c5-fe0b78c6271a Ancestors: Collections-ul.617 Various OrderedCollection changes. Adding: - #addAllFirst: can accept any collection as argument, but uses #reverseDo: if the argument has that method. It's implemented with double dispatch by #addAllFirstTo:. - Simplified and recategorized #at:ifAbsentPut:, but kept the unusual semantics of nil values. - Simplified #addAllLast: a bit, and updated its comment. Removing: - #removeAllSuchThat: stores the read element in a temporary - #removeFirst: and #removeLast: doesn't use #removeFirst and #removeLast anymore. Error handling: - removed the unsent #errorConditionNotSatisfied method - changed #errorNoSuchElement to use the name of the receiver instead of "an ordered collection" - added #errorNotEnoughElements, which is used by #removeFirst: and #removeLast: Other: - implemented #indexOf:startingAt:ifAbsent: for better performance - fixed the comment of #isSortedBy:between:and: =============== Diff against Collections-ul.617 =============== Item was added: + ----- Method: Collection>>addAllFirstTo: (in category 'adding') ----- + addAllFirstTo: anOrderedCollection + "Add all of my elements to the beginning of anOrderedCollection" + + self do: [ :each | anOrderedCollection addFirst: each ]! Item was added: + ----- Method: Interval>>addAllFirstTo: (in category 'adding') ----- + addAllFirstTo: anOrderedCollection + "Add all of my elements to the beginning of anOrderedCollection" + + self reverseDo: [ :each | anOrderedCollection addFirst: each ]! Item was changed: ----- Method: OrderedCollection>>addAllFirst: (in category 'adding') ----- + addAllFirst: aCollection + "Add all elements of aCollection to the beginning of the me. Answer aCollection. Use double dispatch to add elements in reverse order if aCollection implements #reverseDo:." - addAllFirst: anOrderedCollection - "Add each element of anOrderedCollection at the beginning of the - receiver. Answer anOrderedCollection." + ^aCollection addAllFirstTo: self! - anOrderedCollection reverseDo: [:each | self addFirst: each]. - ^anOrderedCollection! Item was changed: ----- Method: OrderedCollection>>addAllLast: (in category 'adding') ----- addAllLast: aCollection + "Add each element of aCollection at the end of me. Answer aCollection." - "Add each element of aCollection at the end of the receiver. - Answer aCollection." + ^aCollection do: [ :each | self addLast: each ]! - aCollection do: [ :each | self addLast: each]. - ^aCollection! Item was changed: + ----- Method: OrderedCollection>>at:ifAbsentPut: (in category 'accessing') ----- - ----- Method: OrderedCollection>>at:ifAbsentPut: (in category 'adding') ----- at: index ifAbsentPut: block "Return value at index, however, if value does not exist (nil or out of bounds) then add block's value at index (growing self if necessary)" + [ index <= self size ] whileFalse: [ self add: nil ]. + ^(self at: index) ifNil: [ self at: index put: block value ]! - | v | - index <= self size ifTrue: [ - ^ (v := self at: index) - ifNotNil: [v] - ifNil: [self at: index put: block value] - ]. - [self size < index] whileTrue: [self add: nil]. - ^ self at: index put: block value! Item was removed: - ----- Method: OrderedCollection>>errorConditionNotSatisfied (in category 'private') ----- - errorConditionNotSatisfied - - self error: 'no element satisfies condition'! Item was changed: ----- Method: OrderedCollection>>errorNoSuchElement (in category 'private') ----- errorNoSuchElement + self error: (String streamContents: [ :stream | + stream nextPutAll: 'attempt to index a non-existent element in '. + self printNameOn: stream ])! - self error: 'attempt to index non-existent element in an ordered collection'! Item was added: + ----- Method: OrderedCollection>>errorNotEnoughElements (in category 'private') ----- + errorNotEnoughElements + + self error: (String streamContents: [ :stream | + stream nextPutAll: 'attempt to remove more elements than possible from '. + self printNameOn: stream ])! Item was added: + ----- Method: OrderedCollection>>indexOf:startingAt:ifAbsent: (in category 'accessing') ----- + indexOf: anElement startingAt: start ifAbsent: exceptionBlock + "Optimized version." + + firstIndex + start - 1 to: lastIndex do: [ :index | + (array at: index) = anElement ifTrue: [ ^index - firstIndex + 1 ] ]. + ^exceptionBlock value! Item was changed: ----- Method: OrderedCollection>>isSortedBy:between:and: (in category 'sorting') ----- isSortedBy: aSortBlockOrNil between: startIndex and: endIndex + "Return true if the receiver is sorted by aSortBlockOrNil between startIndex and endIndex. Use #<= for comparison if aSortBlockOrNil is nil." - "Return true if the receiver is sorted by #<= between startIndex and endIndex." ^array isSortedBy: aSortBlockOrNil between: startIndex + firstIndex - 1 and: endIndex + firstIndex - 1! Item was changed: ----- Method: OrderedCollection>>removeAllSuchThat: (in category 'removing') ----- removeAllSuchThat: aBlock "Remove each element of the receiver for which aBlock evaluates to true. The method in Collection is O(N^2), this is O(N)." | n | n := firstIndex. + firstIndex to: lastIndex do: [ :index | + | element | + (aBlock value: (element := array at: index)) ifFalse: [ + array at: n put: element. + n := n + 1 ] ]. - firstIndex to: lastIndex do: [:index | - (aBlock value: (array at: index)) ifFalse: [ - array at: n put: (array at: index). - n := n + 1]]. array from: n to: lastIndex put: nil. lastIndex := n - 1! Item was changed: ----- Method: OrderedCollection>>removeFirst: (in category 'removing') ----- removeFirst: n + "Remove the first n objects into an array." + + | lastIndexToRemove result | + n < 1 ifTrue: [ self errorNoSuchElement ]. + lastIndex < (lastIndexToRemove := firstIndex + n - 1) ifTrue: [ self errorNotEnoughElements ]. + result := array copyFrom: firstIndex to: lastIndexToRemove. + array from: firstIndex to: lastIndexToRemove put: nil. + firstIndex := lastIndexToRemove + 1. + ^result! - "Remove first n object into an array" - | list | - list := self class arrayType new: n. - 1 - to: n - do: - [ : i | list - at: i - put: self removeFirst ]. - ^ list! Item was changed: ----- Method: OrderedCollection>>removeLast: (in category 'removing') ----- removeLast: n + "Remove the last n objects into an array with last in last position." + + | firstIndexToRemove result | + n < 1 ifTrue: [ self errorNoSuchElement ]. + (firstIndexToRemove := lastIndex - n + 1) < firstIndex ifTrue: [ self errorNotEnoughElements ]. + result := array copyFrom: firstIndexToRemove to: lastIndex. + array from: firstIndexToRemove to: lastIndex put: nil. + lastIndex := firstIndexToRemove - 1. + ^result! - "Remove last n object into an array with last in last position" - | list | - list := self class arrayType new: n. - n - to: 1 - by: -1 - do: - [ : i | list - at: i - put: self removeLast ]. - ^ list! Item was added: + ----- Method: SequenceableCollection>>addAllFirstTo: (in category 'adding') ----- + addAllFirstTo: anOrderedCollection + "Add all of my elements to the beginning of anOrderedCollection" + + self reverseDo: [ :each | anOrderedCollection addFirst: each ]! From unoduetre at poczta.onet.pl Sun Apr 12 22:46:24 2015 From: unoduetre at poczta.onet.pl (Mateusz Grotek) Date: Sun Apr 12 22:34:34 2015 Subject: [squeak-dev] Two bugs. One of them is a regression. In-Reply-To: <4CD105A2-86C3-43D2-93F9-FF9EBC7325FD@gmx.de> (from Das.Linux@gmx.de on Sun Apr 12 23:01:43 2015) References: <1428812182.17235.0@mglap> <1FA3752A-CF49-41B5-84C8-77E81105148D@gmx.de> <1428870798.24532.1@mglap> <4CD105A2-86C3-43D2-93F9-FF9EBC7325FD@gmx.de> Message-ID: <1428878784.24532.3@mglap> Dnia 12.04.2015 23:01:43, Tobias Pape napisa?(a): > > On 12.04.2015, at 22:33, Mateusz Grotek > wrote: > > > Dnia 12.04.2015 22:11:57, Tobias Pape napisa?(a): > >> On 12.04.2015, at 06:16, Mateusz Grotek > wrote: > >> > I've found two bugs in the current Squeak 4.5 #13712. Please > tell me if they're known. If not I'll create the tickets. > >> > > >> > Firstly, there is a regression. > >> > 1. Create a class called (for example) ABC. > >> > 2. Add an instance variable called (for example) xyz. > >> > 3. Open the class comment panel (click on the button "?"). > >> > 4. The contents of it is: > >> > An ABC is xxxxxxxxx. > >> > > >> > Instance Variables > >> > xyz:[TAB][TAB] > >> > > >> > xyz > >> > - xxxxx > >> > 5. Remove the [TAB]s > >> > 6. Accept it > >> > 7. An unrecoverable error shows up (after performing steps above > it keeps appearing when accessing the ABC class): > >> > Error: RemoteString past end of file > >> > The error comes from RemoteString>>text > >> It may be we know that. > >> Are you on ubuntu? > >> Best > >> -Tobias > > No, but on Linux (Gentoo). > > If you put a > > self flush > > at the end of WriteStream>>nextChunkPut: > does that help? > > best > -Tobias > > Yes, that solves the problem. Best wishes, Mateusz From lewis at mail.msen.com Sun Apr 12 23:39:02 2015 From: lewis at mail.msen.com (David T. Lewis) Date: Sun Apr 12 23:39:05 2015 Subject: [squeak-dev] MVC in Squeak 4.6/5.0 *thumbs up* In-Reply-To: <1428865959960-4819215.post@n4.nabble.com> References: <1428865959960-4819215.post@n4.nabble.com> Message-ID: <20150412233902.GA81015@shell.msen.com> On Sun, Apr 12, 2015 at 12:12:39PM -0700, Marcel Taeumel wrote: > > > I got rid of several nasty bugs. Seems to work fine now except for some > visual glitches. > Excellent! With a good useable MVC environment it should be possible to utimately make Morphic itself into a fully unloadable/reloadable environment. Dave From commits at source.squeak.org Mon Apr 13 03:30:47 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Mon Apr 13 03:30:49 2015 Subject: [squeak-dev] The Trunk: Collections-ul.619.mcz Message-ID: Levente Uzonyi uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections-ul.619.mcz ==================== Summary ==================== Name: Collections-ul.619 Author: ul Time: 13 April 2015, 5:28:55.991 am UUID: be05c88a-9d99-4e79-a4af-d986d63ee773 Ancestors: Collections-ul.618 Reset all LRUCache instances in postscript to force migration to the new internal list format. =============== Diff against Collections-ul.618 =============== Item was changed: + (PackageInfo named: 'Collections') postscript: 'LRUCache allInstances do: [ :each | each reset ]'! - (PackageInfo named: 'Collections') postscript: 'Text ignoreStyleIfOnlyBold: Preferences ignoreStyleIfOnlyBold. - Preferences removePreference: #ignoreStyleIfOnlyBold.'! From commits at source.squeak.org Mon Apr 13 03:44:57 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Mon Apr 13 03:45:00 2015 Subject: [squeak-dev] The Trunk: Collections-ul.620.mcz Message-ID: Levente Uzonyi uploaded a new version of Collections to project The Trunk: http://source.squeak.org/trunk/Collections-ul.620.mcz ==================== Summary ==================== Name: Collections-ul.620 Author: ul Time: 13 April 2015, 5:37:50.831 am UUID: 3f6f10ae-f7e2-4218-92cb-02ac39b1d25c Ancestors: Collections-ul.619 Removed the migration code, and obsolete private methods from LRUCache. =============== Diff against Collections-ul.619 =============== Item was changed: ----- Method: LRUCache>>at: (in category 'accessing') ----- at: aKey "answer the object for aKey, if not present in the cache creates it" - head class == LRUCacheHeadNode ifFalse: [ self reset ]. calls := calls + 1. ^map at: aKey ifPresent: [ :node | hits := hits + 1. head next == node ifFalse: [ node unlink; linkAfter: head ]. node value ] ifAbsent: [ | node | map size = size ifTrue: [ node := head previous. node unlink. map removeKey: node key. ] ifFalse: [ node := LRUCacheNode new ]. node linkAfter: head. map at: aKey put: node. node key: aKey; value: (factory value: aKey); value ]! Item was removed: - ----- Method: LRUCache>>moveToFirst: (in category 'private') ----- - moveToFirst: node - "Move node after head in the doubly-linked list. If the node is linked, it must be unlinked first." - - | next | - next := head at: 1. - next == node ifTrue: [ ^self ]. - node - at: 1 put: next; - at: 2 put: head. - next at: 2 put: node. - head at: 1 put: node! Item was removed: - ----- Method: LRUCache>>unlink: (in category 'private') ----- - unlink: node - "Unlink the node from the doubly-linked list represented by head." - - | next previous | - next := node at: 1. - previous := node at: 2. - next at: 2 put: previous. - previous at: 1 put: next! From marcel.taeumel at student.hpi.uni-potsdam.de Mon Apr 13 07:14:58 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Mon Apr 13 07:28:02 2015 Subject: [squeak-dev] Re: MVC in Squeak 4.6/5.0 *thumbs up* In-Reply-To: <20150412233902.GA81015@shell.msen.com> References: <1428865959960-4819215.post@n4.nabble.com> <20150412233902.GA81015@shell.msen.com> Message-ID: <1428909298438-4819254.post@n4.nabble.com> Like a Linux system that comes with some kind of shell and is able to load any kind of graphical environment or other shell? :-D Best, Marcel -- View this message in context: http://forum.world.st/MVC-in-Squeak-4-6-5-0-thumbs-up-tp4819215p4819254.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From timfelgentreff at gmail.com Mon Apr 13 07:37:53 2015 From: timfelgentreff at gmail.com (timfelgentreff) Date: Mon Apr 13 07:50:58 2015 Subject: [squeak-dev] Re: MVC in Squeak 4.6/5.0 *thumbs up* In-Reply-To: <1428909298438-4819254.post@n4.nabble.com> References: <1428865959960-4819215.post@n4.nabble.com> <20150412233902.GA81015@shell.msen.com> <1428909298438-4819254.post@n4.nabble.com> Message-ID: <1428910673250-4819257.post@n4.nabble.com> Well, regarding that I feel the scripting package could eventually go into trunk ;) -- View this message in context: http://forum.world.st/MVC-in-Squeak-4-6-5-0-thumbs-up-tp4819215p4819257.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From hannes.hirzel at gmail.com Mon Apr 13 09:11:43 2015 From: hannes.hirzel at gmail.com (H. Hirzel) Date: Mon Apr 13 09:11:45 2015 Subject: [squeak-dev] MVC in Squeak 4.6/5.0 *thumbs up* In-Reply-To: <1428865959960-4819215.post@n4.nabble.com> References: <1428865959960-4819215.post@n4.nabble.com> Message-ID: On 4/12/15, Marcel Taeumel wrote: > > > I got rid of several nasty bugs. Seems to work fine now except for some > visual glitches. > > Best, > Marcel Great success, Marcel Could you please elaborate a bit what you did? --Hannes From marcel.taeumel at student.hpi.uni-potsdam.de Mon Apr 13 09:13:01 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Mon Apr 13 09:26:06 2015 Subject: [squeak-dev] Re: MVC in Squeak 4.6/5.0 *thumbs up* In-Reply-To: References: <1428865959960-4819215.post@n4.nabble.com> Message-ID: <1428916381959-4819262.post@n4.nabble.com> Basically, MVC got bugs whenever the MorphicToolBuilder was extended "recklessly" w/o considering the MVCToolBuilder. MVC has no tree view yet---not even a fallback. Having this, we need to keep the old-style FileList GUI for MVC. Then the variety of list morphs are sometimes difficult for MVC. That is, the multi-selection and challenging callbacks of the AlternatePluggableListMorphOfMany makes it difficult to fall-back on PluggableListMorph (resp. PluggableListView). One example is MessageTrace. In the long run, we should provide a simple tree view for MVC (e.g. one like Apple's multi-column views to just recycle PluggableListView in a scroll pane) and merge multi-selection behavior of AlternatePluggableListMorphOfMany into PluggableListMorph and think about fall-backs to keep MVC development manageable. Besides that: Everything looks fine. Not much effort required to keep MVC functional. :) Best, Marcel -- View this message in context: http://forum.world.st/MVC-in-Squeak-4-6-5-0-thumbs-up-tp4819215p4819262.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From edgardec2005 at gmail.com Mon Apr 13 09:26:57 2015 From: edgardec2005 at gmail.com (Edgar J. De Cleene) Date: Mon Apr 13 09:27:04 2015 Subject: [squeak-dev] Re: MVC in Squeak 4.6/5.0 *thumbs up* In-Reply-To: <1428909298438-4819254.post@n4.nabble.com> Message-ID: On 4/13/15, 4:14 AM, "Marcel Taeumel" wrote: > Like a Linux system that comes with some kind of shell and is able to load > any kind of graphical environment or other shell? :-D > > Best, > Marcel Bravo Marcel !!! And why do not have a SqueakNOS like our Pharo cousins? Tiny Core or SliTaz as Linux part ... A working pendrive could be made. Edgar From marcel.taeumel at student.hpi.uni-potsdam.de Mon Apr 13 09:42:06 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Mon Apr 13 09:55:10 2015 Subject: [squeak-dev] Re: MVC in Squeak 4.6/5.0 *thumbs up* In-Reply-To: References: <1428865959960-4819215.post@n4.nabble.com> <20150412233902.GA81015@shell.msen.com> <1428909298438-4819254.post@n4.nabble.com> Message-ID: <1428918126131-4819265.post@n4.nabble.com> ... and MacOS and Windows ... ;) Best, Marcel -- View this message in context: http://forum.world.st/MVC-in-Squeak-4-6-5-0-thumbs-up-tp4819215p4819265.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From frank.shearar at gmail.com Mon Apr 13 11:29:47 2015 From: frank.shearar at gmail.com (Frank Shearar) Date: Mon Apr 13 11:29:51 2015 Subject: [squeak-dev] New Cog VMs available In-Reply-To: <4024C928-7DE8-4F9C-963E-C7F86B834AF3@gmx.de> References: <0F3C260D-2441-4272-8578-E4497BE65C1A@gmx.de> <256F46F5-91B0-4552-A9E9-25BAAA2733DF@gmx.de> <72A53D36-2E38-42E9-A1A9-E95DDD94AFC2@gmail.com> <4024C928-7DE8-4F9C-963E-C7F86B834AF3@gmx.de> Message-ID: On 10 April 2015 at 16:21, Tobias Pape wrote: > Hi Eliot, > > On 10.04.2015, at 15:46, Eliot Miranda wrote: > >> >> >> >> On Apr 9, 2015, at 3:21 PM, Tobias Pape wrote: >> >>> >>> On 10.04.2015, at 00:17, Tobias Pape wrote: >>> >>>> Updated on the CI :) >>> >>> aaand reverted. We got a crash: >>> http://build.squeak.org/job/SqueakTrunk/1245/console >> > > >> Yes. I get a crash in updating with the v3 VM. So far no problems with the Spur VM. But Tibias, unless the bleeding edge gets tested how will I spit these regressions? I need to know. So can we not have two builds, one with the last known good and one with the bleeding edge? > > Sure, this is possible. > probably something like a matrix build. > Frank is more savvy with the infrastructure, tho. I'd say that SqueakTrunk should use the latest stable Cog - its main purpose is to test _trunk's_ bleeding edge. We do also have SqueakTrunkOnSpur, which should track Spur's/Cog's bleeding edge. Which means we should split the versions in the build scripts. Maybe we should just have a COG_VERSION and a SPUR_COG_VERSION as a not-too-stinky quick win? frank > best > -Tobias > > >> Otherwise I'm flying blind. >> >>> >>> Best >>> -Tobias >>> >>>> Best >>>> -Tobias >>>> On 09.04.2015, at 23:28, Eliot Miranda wrote: >>>> >>>>> ... at http://www.mirandabanda.org/files/Cog/VM/VM.r3308/. >>>>> >>>>> CogVM binaries as per VMMaker.oscog-eem.1178/r3308 >>>>> >>>>> Plugins: >>>>> Integrate Nicolas' fixes that use positiveMachineIntegerFor: for pointers. >>>>> >>>>> Newspeak: >>>>> Print a warning in the method shared under multiple selectors scenario. >>>>> >>>>> Implement outer sends as clean sends just like implicit receiver sends. Add >>>>> ObjectRepresentation>>illegalClassTag and use it for initializing and unlinking >>>>> implicit and outer sends. >>>>> >>>>> Newspeak & Sista: >>>>> The multiple bytecode set block initial nil counters need >>>>> to be specific to the bytecode set in effect. >>>>> >>>>> Spur: >>>>> Implement Clement's much better solution for the stale supersend problem. >>>>> Place code at the send site for super sends to follow stale forwarded >>>>> receivers. This parallels the interpreter implementation. >>>>> >>>>> Beef up the post-become scan of send sites to >>>>> unlink all send sites that link to an invalid class tag. >>>>> >>>>> Cogit: >>>>> Optimize StackToRegisterMappingCogit>>genReturnReceiver >>>>> to not load ReceiverResultReg if it already contains self. >>>>> >>>>> Revise method map generation to provide multiple send type annotations. Add >>>>> an IsAnnotationExtension annotation type that implicitly has a zero displacement >>>>> and uses its displacement bits to extend the preceeding IsSendCall annotation. >>>>> This allows us to eliminate all the exotic entry-points and keep only the >>>>> checked and unchecked entries. >>>>> >>>>> Change IA32's genPushRegisterArgsForNumArgs: to not smash TempReg now that it >>>>> is used in directed super send trampolines. >>>>> >>>>> Use PushCq to pass small integer constants in the trampolines instead of >>>>> smashing TempReg, which is now used to hold the directed supersend argument. >>>>> Add support for PushCq. Could use PushCw but on x86 PushCq is a lot shorter. >>>>> >>>>> Mac builds: Use UTC as the timezone for the build timestamp. Using the local >>>>> timezone doesn't work :(. > > > From Das.Linux at gmx.de Mon Apr 13 11:35:17 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Mon Apr 13 11:35:22 2015 Subject: [squeak-dev] New Cog VMs available In-Reply-To: References: <0F3C260D-2441-4272-8578-E4497BE65C1A@gmx.de> <256F46F5-91B0-4552-A9E9-25BAAA2733DF@gmx.de> <72A53D36-2E38-42E9-A1A9-E95DDD94AFC2@gmail.com> <4024C928-7DE8-4F9C-963E-C7F86B834AF3@gmx.de> Message-ID: <5F8ADF1B-0C0A-4435-AFFE-6D8BA2FFD461@gmx.de> Hi, On 13.04.2015, at 13:29, Frank Shearar wrote: > On 10 April 2015 at 16:21, Tobias Pape wrote: >> Hi Eliot, >> >> On 10.04.2015, at 15:46, Eliot Miranda wrote: >> >>> >>> >>> >>> On Apr 9, 2015, at 3:21 PM, Tobias Pape wrote: >>> >>>> >>>> On 10.04.2015, at 00:17, Tobias Pape wrote: >>>> >>>>> Updated on the CI :) >>>> >>>> aaand reverted. We got a crash: >>>> http://build.squeak.org/job/SqueakTrunk/1245/console >>> >> >> >>> Yes. I get a crash in updating with the v3 VM. So far no problems with the Spur VM. But Tibias, unless the bleeding edge gets tested how will I spit these regressions? I need to know. So can we not have two builds, one with the last known good and one with the bleeding edge? >> >> Sure, this is possible. >> probably something like a matrix build. >> Frank is more savvy with the infrastructure, tho. > > I'd say that SqueakTrunk should use the latest stable Cog - its main > purpose is to test _trunk's_ bleeding edge. We do also have > SqueakTrunkOnSpur, which should track Spur's/Cog's bleeding edge. > Ack :) > Which means we should split the versions in the build scripts. Maybe > we should just have a COG_VERSION and a SPUR_COG_VERSION as a > not-too-stinky quick win? Probably? I don't know yet. Have to make up my mind :) > > frank > >> best >> -Tobias >> >> >>> Otherwise I'm flying blind. >>> >>>> >>>> Best >>>> -Tobias >>>> >>>>> Best >>>>> -Tobias >>>>> On 09.04.2015, at 23:28, Eliot Miranda wrote: From marcel.taeumel at student.hpi.uni-potsdam.de Mon Apr 13 11:31:37 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Mon Apr 13 11:44:43 2015 Subject: [squeak-dev] Re: New Cog VMs available In-Reply-To: References: Message-ID: <1428924697917-4819276.post@n4.nabble.com> Nice! :) In the Squeak.manifest for cogwin, can we change ... true ... to false? Best, Marcel -- View this message in context: http://forum.world.st/New-Cog-VMs-available-tp4818711p4819276.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From bert at freudenbergs.de Mon Apr 13 12:47:24 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Mon Apr 13 14:17:47 2015 Subject: [squeak-dev] Two bugs. One of them is a regression. In-Reply-To: <1428834807779-4819138.post@n4.nabble.com> References: <1428812182.17235.0@mglap> <1428834807779-4819138.post@n4.nabble.com> Message-ID: > On 12.04.2015, at 12:33, Marcel Taeumel wrote: > > The modality in the UserDialogBoxMorph is implemented via holding both mouse > and keyboard focus. The halo takes the mouse focus away when growing or > dragging a morph--without signaling it to the former focus holder. After > that, the modal behavior is lost. However, the dialog is still useful as > long as it is in the world because it still triggers a world's sub-cycle. ... but only as long as the current process is running. If you create a new UI process (by error or user interrupt), the dialog will still be in the world but not be able to do anything useful. - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150413/b2d985a1/smime-0001.bin From bert at freudenbergs.de Mon Apr 13 12:54:25 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Mon Apr 13 14:17:51 2015 Subject: [squeak-dev] The Trunk: Tools-mt.581.mcz In-Reply-To: References: Message-ID: > On 12.04.2015, at 14:43, commits@source.squeak.org wrote: > > Marcel Taeumel uploaded a new version of Tools to project The Trunk: > http://source.squeak.org/trunk/Tools-mt.581.mcz > > ==================== Summary ==================== > > Name: Tools-mt.581 > Author: mt > Time: 12 April 2015, 4:43:28.671 pm > UUID: 6b7d43e3-76f0-3241-aee8-84b532a1c45e > Ancestors: Tools-mt.580 > > For Bert: Added a button to easily switch between inspector and object explorer. For me? Awwww, than you ^_^ - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150413/bd9dc9e1/smime.bin From bert at freudenbergs.de Mon Apr 13 13:15:50 2015 From: bert at freudenbergs.de (Bert Freudenberg) Date: Mon Apr 13 14:17:52 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.122.mcz In-Reply-To: References: Message-ID: > On 11.04.2015, at 06:15, commits@source.squeak.org wrote: > > Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: > http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.122.mcz > > ==================== Summary ==================== > > Name: ToolBuilder-Morphic-mt.122 > Author: mt > Time: 11 April 2015, 8:15:18.783 am > UUID: f601e0ad-6555-0746-9827-7d81c7cf04ba > Ancestors: ToolBuilder-Morphic-mt.121 > > If the preference #openToolsAttachedToMouseCursor is enabled, the morphic tool builder will attach any system window to the hand if the current event is a mouse event. Interesting! Can we make it so that when dropping the window you can change its size? Like in the old Smalltalk days ... If you just click to drop, the window would stay at its default size. So no changed behavior from what it is now. But if you drag instead, it would drop the window with its default size and then track the mouse pointer to change its size. - Bert - -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 4115 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150413/8602a482/smime.bin From commits at source.squeak.org Mon Apr 13 15:16:50 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Mon Apr 13 15:16:52 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.867.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.867.mcz ==================== Summary ==================== Name: Morphic-mt.867 Author: mt Time: 13 April 2015, 5:16:16.01 pm UUID: 52e544de-d33f-0346-9646-bfe830d53ac5 Ancestors: Morphic-mt.866 Fixed a bug with scrolling that occured at the transition from needing to not needing scrollbars (or vice versa). We must ensure that scroll bars reflect the current of the scroller---regardless of their visibility. =============== Diff against Morphic-mt.866 =============== Item was changed: ----- Method: ScrollPane>>extent: (in category 'geometry') ----- extent: newExtent | oldW oldH wasHShowing wasVShowing noVPlease noHPlease minH minW | oldW := self width. oldH := self height. wasHShowing := self hIsScrollbarShowing. wasVShowing := self vIsScrollbarShowing. "Figure out the minimum width and height for this pane so that scrollbars will appear" noVPlease := self valueOfProperty: #noVScrollBarPlease ifAbsent: [false]. noHPlease := self valueOfProperty: #noHScrollBarPlease ifAbsent: [false]. minH := self scrollBarThickness + 16. minW := self scrollBarThickness + 20. noVPlease ifTrue:[ noHPlease ifTrue:[minH := 1. minW := 1 ] ifFalse:[minH := self scrollBarThickness ]. ] ifFalse:[ noHPlease ifTrue:[minH := self scrollBarThickness + 5]. ]. super extent: (newExtent max: (minW@minH)). "Now reset widget sizes" self resizeScrollBars; resizeScroller; hideOrShowScrollBars. "Now resetScrollDeltas where appropriate, first the vScrollBar..." + self height ~~ oldH ifTrue: [self vSetScrollDelta]. - ((self height ~~ oldH) or: [ wasHShowing ~~ self hIsScrollbarShowing]) ifTrue: - [(retractableScrollBar or: [ self vIsScrollbarShowing ]) ifTrue: - [ self vSetScrollDelta ]]. "...then the hScrollBar" + self width ~~ oldW ifTrue: [self hSetScrollDelta]. - ((self width ~~ oldW) or: [wasVShowing ~~ self vIsScrollbarShowing]) ifTrue: - [(retractableScrollBar or: [ self hIsScrollbarShowing ]) ifTrue: - [ self hSetScrollDelta ]]. ! From commits at source.squeak.org Mon Apr 13 20:37:04 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Mon Apr 13 20:37:07 2015 Subject: [squeak-dev] The Trunk: Installer-Core-cmm.396.mcz Message-ID: Chris Muller uploaded a new version of Installer-Core to project The Trunk: http://source.squeak.org/trunk/Installer-Core-cmm.396.mcz ==================== Summary ==================== Name: Installer-Core-cmm.396 Author: cmm Time: 13 April 2015, 3:36:53.591 pm UUID: 23a88591-d058-4c91-bf90-745c2971aab7 Ancestors: Installer-Core-ul.395 Add entry for easy access to latest code which hosts source.squeak.org. =============== Diff against Installer-Core-ul.395 =============== Item was added: + ----- Method: Installer>>squeaksource (in category 'package-definitions') ----- + squeaksource + "The code which manages Squeak's internal source code repository." + ^ { #squeak -> 'ss'. + 'SmaCC'. + 'DynamicBindings'. + 'KomServices'. + 'KomHttpServer'. + 'Seaside2'. + 'Mewa'. + 'TinyWiki'. + 'SqueakSource'}! From commits at source.squeak.org Mon Apr 13 21:55:03 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Mon Apr 13 21:55:05 2015 Subject: [squeak-dev] Daily Commit Log Message-ID: <20150413215503.8648.qmail@box4.squeakfoundation.org> Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours: http://lists.squeakfoundation.org/pipermail/packages/2015-April/007935.html Name: Collections-ul.618 Ancestors: Collections-ul.617 Various OrderedCollection changes. Adding: - #addAllFirst: can accept any collection as argument, but uses #reverseDo: if the argument has that method. It's implemented with double dispatch by #addAllFirstTo:. - Simplified and recategorized #at:ifAbsentPut:, but kept the unusual semantics of nil values. - Simplified #addAllLast: a bit, and updated its comment. Removing: - #removeAllSuchThat: stores the read element in a temporary - #removeFirst: and #removeLast: doesn't use #removeFirst and #removeLast anymore. Error handling: - removed the unsent #errorConditionNotSatisfied method - changed #errorNoSuchElement to use the name of the receiver instead of "an ordered collection" - added #errorNotEnoughElements, which is used by #removeFirst: and #removeLast: Other: - implemented #indexOf:startingAt:ifAbsent: for better performance - fixed the comment of #isSortedBy:between:and: ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007936.html Name: Collections-ul.619 Ancestors: Collections-ul.618 Reset all LRUCache instances in postscript to force migration to the new internal list format. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007937.html Name: Collections-ul.620 Ancestors: Collections-ul.619 Removed the migration code, and obsolete private methods from LRUCache. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007938.html Name: Morphic-mt.867 Ancestors: Morphic-mt.866 Fixed a bug with scrolling that occured at the transition from needing to not needing scrollbars (or vice versa). We must ensure that scroll bars reflect the current of the scroller---regardless of their visibility. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007939.html Name: Installer-Core-cmm.396 Ancestors: Installer-Core-ul.395 Add entry for easy access to latest code which hosts source.squeak.org. ============================================= From commits at source.squeak.org Tue Apr 14 01:29:10 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 01:29:12 2015 Subject: [squeak-dev] The Trunk: Installer-Core-cmm.397.mcz Message-ID: Chris Muller uploaded a new version of Installer-Core to project The Trunk: http://source.squeak.org/trunk/Installer-Core-cmm.397.mcz ==================== Summary ==================== Name: Installer-Core-cmm.397 Author: cmm Time: 13 April 2015, 8:28:57.87 pm UUID: e3825d75-2e08-4420-b2d0-25d7946a4371 Ancestors: Installer-Core-cmm.396 SqueakSource employs server-specific versions of OSProcess and RFB. =============== Diff against Installer-Core-cmm.396 =============== Item was changed: ----- Method: Installer>>squeaksource (in category 'package-definitions') ----- squeaksource + "A source code repository." - "The code which manages Squeak's internal source code repository." ^ { #squeak -> 'ss'. + 'OSProcess'. + 'RFB'. 'SmaCC'. 'DynamicBindings'. 'KomServices'. 'KomHttpServer'. 'Seaside2'. 'Mewa'. 'TinyWiki'. + 'SqueakSource' }! - 'SqueakSource'}! From commits at source.squeak.org Tue Apr 14 06:51:50 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 06:51:51 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.868.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.868.mcz ==================== Summary ==================== Name: Morphic-mt.868 Author: mt Time: 14 April 2015, 8:51:16.376 am UUID: e03a8bed-de5d-7847-97b3-d38b5c1b1339 Ancestors: Morphic-mt.867 Extended the "openToolsAttachedToMouseCursor" preference to allow resizing-after-dropping directly if you keep the mouse button pressed and move it. Thanks Bert for the idea! :-) Note: With fast-dragging enabled, accidential resize might shrink the window unexpectedly because we cannot change mouse position programmatically. =============== Diff against Morphic-mt.867 =============== Item was added: + ----- Method: AbstractResizerMorph>>referencePoint: (in category 'as yet unclassified') ----- + referencePoint: aPoint + + lastMouse := aPoint.! Item was changed: ----- Method: SystemWindow>>justDroppedInto:event: (in category 'geometry') ----- justDroppedInto: aMorph event: anEvent + ToolBuilder openToolsAttachedToMouseCursor ifTrue: [ + (self submorphs detect: [:m | m isKindOf: BottomRightGripMorph] ifNone: []) + ifNotNil: [:grip | + grip referencePoint: anEvent position. + anEvent hand newMouseFocus: grip]]. + self hasDropShadow: (self isActive and: [Preferences menuAppearance3d]). isCollapsed ifTrue: [self position: ((self position max: 0@0) grid: 8@8). collapsedFrame := self bounds] ifFalse: [fullFrame := self bounds. TopWindow ~~ self ifTrue: [self activate]]. ^super justDroppedInto: aMorph event: anEvent! From commits at source.squeak.org Tue Apr 14 07:24:47 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 07:24:49 2015 Subject: [squeak-dev] The Trunk: Tools-mt.587.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.587.mcz ==================== Summary ==================== Name: Tools-mt.587 Author: mt Time: 14 April 2015, 9:24:29.942 am UUID: 016aa5a8-25f3-6642-92d6-f058b1a78716 Ancestors: Tools-mt.586 Fixed a regression in file contents browser. That browser misuses the system category pane for displaying the file name. Having this, it has to consider the normal use of that list in browsers. Note: Having '-- all --' in the list of system categories will normally not affect other browsers as we can see in the HierarchBrowser. Thanks to Chris for pointing out that bug. =============== Diff against Tools-mt.586 =============== Item was added: + ----- Method: FileContentsBrowser>>systemCategoryList (in category 'system category list') ----- + systemCategoryList + + ^ self packages size = 1 + ifTrue: [super systemCategoryList allButFirst "without all category"] + ifFalse: [super systemCategoryList]! From commits at source.squeak.org Tue Apr 14 07:28:49 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 07:28:50 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.869.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.869.mcz ==================== Summary ==================== Name: Morphic-mt.869 Author: mt Time: 14 April 2015, 9:28:12.825 am UUID: 4af45ac7-0ca2-3940-bdd5-205c009a434c Ancestors: Morphic-mt.868 Fixed resize-after-drop to work only for the initial drop. =============== Diff against Morphic-mt.868 =============== Item was changed: ----- Method: SystemWindow>>justDroppedInto:event: (in category 'geometry') ----- justDroppedInto: aMorph event: anEvent + (ToolBuilder openToolsAttachedToMouseCursor and: (self hasProperty: #initialDrop)) + ifTrue: [ + self removeProperty: #initialDrop. + (self submorphs detect: [:m | m isKindOf: BottomRightGripMorph] ifNone: []) + ifNotNil: [:grip | + grip referencePoint: anEvent position. + anEvent hand newMouseFocus: grip]]. - ToolBuilder openToolsAttachedToMouseCursor ifTrue: [ - (self submorphs detect: [:m | m isKindOf: BottomRightGripMorph] ifNone: []) - ifNotNil: [:grip | - grip referencePoint: anEvent position. - anEvent hand newMouseFocus: grip]]. self hasDropShadow: (self isActive and: [Preferences menuAppearance3d]). isCollapsed ifTrue: [self position: ((self position max: 0@0) grid: 8@8). collapsedFrame := self bounds] ifFalse: [fullFrame := self bounds. TopWindow ~~ self ifTrue: [self activate]]. ^super justDroppedInto: aMorph event: anEvent! From commits at source.squeak.org Tue Apr 14 07:29:32 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 07:29:34 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.126.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.126.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.126 Author: mt Time: 14 April 2015, 9:29:26.397 am UUID: 76b36a27-8583-cc47-a8eb-52393ca59710 Ancestors: ToolBuilder-Morphic-mt.125 Fixed resize-after-drop to work only for the initial drop. Added a flag for #initialDrop to the affected tool window. =============== Diff against ToolBuilder-Morphic-mt.125 =============== Item was changed: ----- Method: MorphicToolBuilder>>open: (in category 'opening') ----- open: anObject "Build and open the object. Answer the widget opened." | morph | anObject isMorph ifTrue:[morph := anObject] ifFalse:[morph := self build: anObject]. (morph isKindOf: MenuMorph) ifTrue:[morph popUpInWorld: World]. (morph isKindOf: SystemWindow) ifFalse:[morph openInWorld] ifTrue:[ morph := morph openInWorldExtent: morph extent. (self class openToolsAttachedToMouseCursor and: [self currentEvent isMouse and: [self currentEvent isMouseUp]]) ifTrue: [ + morph setProperty: #initialDrop toValue: true. morph hasDropShadow: false. self currentHand attachMorph: morph]]. ^morph! From commits at source.squeak.org Tue Apr 14 07:42:46 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 07:42:47 2015 Subject: [squeak-dev] The Trunk: Kernel-mt.919.mcz Message-ID: Marcel Taeumel uploaded a new version of Kernel to project The Trunk: http://source.squeak.org/trunk/Kernel-mt.919.mcz ==================== Summary ==================== Name: Kernel-mt.919 Author: mt Time: 14 April 2015, 9:42:18.399 am UUID: 6ccd73b1-d88b-d045-89c6-6dfddbdc7f66 Ancestors: Kernel-mt.918 Fixed Object organization to not have all-category as a real category. Was empty anyway. =============== Diff against Kernel-mt.918 =============== Item was changed: SystemOrganization addCategory: #'Kernel-Chronology'! SystemOrganization addCategory: #'Kernel-Classes'! SystemOrganization addCategory: #'Kernel-Exceptions'! SystemOrganization addCategory: #'Kernel-Exceptions-Kernel'! SystemOrganization addCategory: #'Kernel-Methods'! SystemOrganization addCategory: #'Kernel-Models'! SystemOrganization addCategory: #'Kernel-Numbers'! SystemOrganization addCategory: #'Kernel-Numbers-Exceptions'! SystemOrganization addCategory: #'Kernel-Objects'! + SystemOrganization addCategory: #'Kernel-Pools'! SystemOrganization addCategory: #'Kernel-Processes'! SystemOrganization addCategory: #'Kernel-Processes-Variables'! - SystemOrganization addCategory: #'Kernel-Pools'! Item was changed: ----- Method: Categorizer>>categories (in category 'accessing') ----- categories "Answer an Array of categories (names)." categoryArray isNil ifTrue: [^ nil]. + self isEmpty ifTrue: [^Array with: NullCategory]. - (categoryArray size = 1 - and: [categoryArray first = Default & (elementArray size = 0)]) - ifTrue: [^Array with: NullCategory]. ^categoryArray! Item was added: + ----- Method: Categorizer>>isEmpty (in category 'testing') ----- + isEmpty + + ^ (categoryArray size = 1 + and: [categoryArray first = Default & (elementArray size = 0)])! From commits at source.squeak.org Tue Apr 14 07:43:46 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 07:43:48 2015 Subject: [squeak-dev] The Trunk: KernelTests-mt.292.mcz Message-ID: Marcel Taeumel uploaded a new version of KernelTests to project The Trunk: http://source.squeak.org/trunk/KernelTests-mt.292.mcz ==================== Summary ==================== Name: KernelTests-mt.292 Author: mt Time: 14 April 2015, 9:43:37.143 am UUID: ed0c5020-a0e5-c740-91af-5590f79f96c0 Ancestors: KernelTests-ul.291 Test added for checking whether some class organization has special categories in it. =============== Diff against KernelTests-ul.291 =============== Item was added: + ----- Method: CategorizerTest>>testNoSpecialCategories (in category 'testing') ----- + testNoSpecialCategories + + SystemNavigation allClasses do: [:class | + {class. class class} do: [:classOrMetaClass | + self + assert: (classOrMetaClass organization categories includes: Categorizer allCategory) not + description: ('{1} must not have the all-category in its organization.' format: {class name}). + self + assert: (classOrMetaClass organization isEmpty or: [ + (classOrMetaClass organization categories includes: Categorizer nullCategory) not]) + description: ('{1} must not have the null-category in its organization.' format: {class name}).]].! From commits at source.squeak.org Tue Apr 14 08:04:26 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 08:04:28 2015 Subject: [squeak-dev] The Trunk: ST80Tools-topa.6.mcz Message-ID: Tobias Pape uploaded a new version of ST80Tools to project The Trunk: http://source.squeak.org/trunk/ST80Tools-topa.6.mcz ==================== Summary ==================== Name: ST80Tools-topa.6 Author: topa Time: 14 April 2015, 10:04:21.905 am UUID: 1c2237e9-0dc7-479b-a7a2-236e4f1f793f Ancestors: ST80Tools-mt.5 Assume responsibility of #openInMVC in a Tool =============== Diff against ST80Tools-mt.5 =============== Item was added: + ----- Method: FileList class>>openInMVC (in category '*ST80Tools-instance creation') ----- + openInMVC + "Open a view of an instance of me on the default directory." + + | dir aFileList topView volListView templateView fileListView fileContentsView underPane pHeight | + dir := FileDirectory default. + aFileList := self new directory: dir. + topView := StandardSystemView new. + topView + model: aFileList; + label: dir pathName; + minimumSize: 200@200. + topView borderWidth: 1. + + volListView := PluggableListView on: aFileList + list: #volumeList + selected: #volumeListIndex + changeSelected: #volumeListIndex: + menu: #volumeMenu:. + volListView autoDeselect: false. + volListView window: (0@0 extent: 80@45). + topView addSubView: volListView. + + templateView _ PluggableTextView on: aFileList + text: #pattern + accept: #pattern:. + templateView askBeforeDiscardingEdits: false. + templateView window: (0@0 extent: 80@15). + topView addSubView: templateView below: volListView. + + aFileList wantsOptionalButtons + ifTrue: + [underPane := aFileList optionalButtonViewForMVC. + underPane isNil + ifTrue: [pHeight := 60] + ifFalse: [ + topView addSubView: underPane toRightOf: volListView. + pHeight := 60 - aFileList optionalButtonHeight]] + ifFalse: + [underPane := nil. + pHeight := 60]. + + fileListView := PluggableListView on: aFileList + list: #fileList + selected: #fileListIndex + changeSelected: #fileListIndex: + menu: #fileListMenu:. + fileListView window: (0@0 extent: 120@pHeight). + underPane isNil + ifTrue: [topView addSubView: fileListView toRightOf: volListView] + ifFalse: [topView addSubView: fileListView below: underPane]. + fileListView controller terminateDuringSelect: true. "Pane to left may change under scrollbar" + + fileContentsView := PluggableTextView on: aFileList + text: #contents accept: #put: + readSelection: #contentsSelection menu: #fileContentsMenu:shifted:. + fileContentsView window: (0@0 extent: 200@140). + topView addSubView: fileContentsView below: templateView. + + topView controller open! From commits at source.squeak.org Tue Apr 14 08:05:34 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 08:05:35 2015 Subject: [squeak-dev] The Trunk: Tools-topa.588.mcz Message-ID: Tobias Pape uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-topa.588.mcz ==================== Summary ==================== Name: Tools-topa.588 Author: topa Time: 14 April 2015, 10:05:13.422 am UUID: 386b83af-d3f9-4388-98cd-dc98749962ff Ancestors: Tools-mt.587 Drop responsibility of #openInMVC to ST80Tools =============== Diff against Tools-mt.587 =============== Item was removed: - ----- Method: FileList class>>openInMVC (in category 'mvc compatibility') ----- - openInMVC - "Open a view of an instance of me on the default directory." - - | dir aFileList topView volListView templateView fileListView fileContentsView underPane pHeight | - dir := FileDirectory default. - aFileList := self new directory: dir. - topView := StandardSystemView new. - topView - model: aFileList; - label: dir pathName; - minimumSize: 200@200. - topView borderWidth: 1. - - volListView := PluggableListView on: aFileList - list: #volumeList - selected: #volumeListIndex - changeSelected: #volumeListIndex: - menu: #volumeMenu:. - volListView autoDeselect: false. - volListView window: (0@0 extent: 80@45). - topView addSubView: volListView. - - templateView _ PluggableTextView on: aFileList - text: #pattern - accept: #pattern:. - templateView askBeforeDiscardingEdits: false. - templateView window: (0@0 extent: 80@15). - topView addSubView: templateView below: volListView. - - aFileList wantsOptionalButtons - ifTrue: - [underPane := aFileList optionalButtonViewForMVC. - underPane isNil - ifTrue: [pHeight := 60] - ifFalse: [ - topView addSubView: underPane toRightOf: volListView. - pHeight := 60 - aFileList optionalButtonHeight]] - ifFalse: - [underPane := nil. - pHeight := 60]. - - fileListView := PluggableListView on: aFileList - list: #fileList - selected: #fileListIndex - changeSelected: #fileListIndex: - menu: #fileListMenu:. - fileListView window: (0@0 extent: 120@pHeight). - underPane isNil - ifTrue: [topView addSubView: fileListView toRightOf: volListView] - ifFalse: [topView addSubView: fileListView below: underPane]. - fileListView controller terminateDuringSelect: true. "Pane to left may change under scrollbar" - - fileContentsView := PluggableTextView on: aFileList - text: #contents accept: #put: - readSelection: #contentsSelection menu: #fileContentsMenu:shifted:. - fileContentsView window: (0@0 extent: 200@140). - topView addSubView: fileContentsView below: templateView. - - topView controller open! From commits at source.squeak.org Tue Apr 14 08:20:26 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 08:20:28 2015 Subject: [squeak-dev] The Trunk: Kernel-topa.920.mcz Message-ID: Tobias Pape uploaded a new version of Kernel to project The Trunk: http://source.squeak.org/trunk/Kernel-topa.920.mcz ==================== Summary ==================== Name: Kernel-topa.920 Author: topa Time: 14 April 2015, 10:20:01.78 am UUID: 22c1b724-e8e2-486b-b91b-49405ebc489a Ancestors: Kernel-mt.919 Remove spurious -- all -- category that crept into Object =============== Diff against Kernel-mt.919 =============== Item was changed: (PackageInfo named: 'Kernel') postscript: '"Fix accidental non-weak arrays in ObsoleteSubclasses values" Behavior classPool at: #ObsoleteSubclasses ifPresent: [:os | os keysAndValuesDo: [:superclass :obsoletes | obsoletes class isWeak ifFalse: [ + os at: superclass put: (obsoletes as: WeakArray)]]]. + "Remove spurious -- all -- category that crept into Object" + [Object organization removeCategory: #''-- all --''. + ] on: Error do: [:e| + "Category not empty, silently leave it there" + e return].'! - os at: superclass put: (obsoletes as: WeakArray)]]].'! From commits at source.squeak.org Tue Apr 14 08:31:43 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 08:31:45 2015 Subject: [squeak-dev] The Trunk: ToolsTests-topa.72.mcz Message-ID: Tobias Pape uploaded a new version of ToolsTests to project The Trunk: http://source.squeak.org/trunk/ToolsTests-topa.72.mcz ==================== Summary ==================== Name: ToolsTests-topa.72 Author: topa Time: 14 April 2015, 10:31:36.416 am UUID: 0c975601-52ad-4b6f-96a5-1197a85f7a32 Ancestors: ToolsTests-mt.71 Adapt BrowserTests to rely less on global state, namely SystemOrganization =============== Diff against ToolsTests-mt.71 =============== Item was changed: + ----- Method: BrowserTest>>setUp (in category 'running') ----- - ----- Method: BrowserTest>>setUp (in category 'as yet unclassified') ----- setUp browser := Browser new.! Item was changed: ----- Method: BrowserTest>>testGetSystemCategoryListIndex (in category 'as yet unclassified') ----- testGetSystemCategoryListIndex | cat | + cat := browser systemCategoryList first. - cat := SystemOrganization categories first. browser selectSystemCategory: cat. + self assert: browser systemCategoryListIndex = (browser systemCategoryList indexOf: browser selectedSystemCategory).! - self assert: browser systemCategoryListIndex = (SystemOrganization categories indexOf: browser selectedSystemCategory).! Item was changed: ----- Method: BrowserTest>>testSelectedSystemCategory (in category 'as yet unclassified') ----- testSelectedSystemCategory | cat newCat | + cat := browser systemCategoryList first. + newCat := browser systemCategoryList second. - cat := SystemOrganization categories first. - newCat := SystemOrganization categories second. browser selectSystemCategory: cat. self assert: browser selectedSystemCategory = cat. browser systemCategoryListIndex: 2. self assert: browser selectedSystemCategory = newCat.! Item was changed: ----- Method: BrowserTest>>testSystemCategoryListIndex (in category 'as yet unclassified') ----- testSystemCategoryListIndex | oldCat | browser systemCategoryListIndex: 1. oldCat := browser selectedSystemCategory. + self assert: browser selectedSystemCategory = browser systemCategoryList first. - self assert: browser selectedSystemCategory = SystemOrganization categories first. browser systemCategoryListIndex: 2. self deny: browser selectedSystemCategory = oldCat. + self assert: browser selectedSystemCategory = browser systemCategoryList second.! - self assert: browser selectedSystemCategory = SystemOrganization categories second.! From commits at source.squeak.org Tue Apr 14 09:04:45 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 09:04:46 2015 Subject: [squeak-dev] The Trunk: Multilingual-topa.205.mcz Message-ID: Tobias Pape uploaded a new version of Multilingual to project The Trunk: http://source.squeak.org/trunk/Multilingual-topa.205.mcz ==================== Summary ==================== Name: Multilingual-topa.205 Author: topa Time: 14 April 2015, 11:04:27.175 am UUID: da7bc0f1-5f76-40d0-9bcb-7cf96596ac92 Ancestors: Multilingual-topa.204, Multilingual-cbc.201 Pick up a fix for MultiByteFileStream>>#nextChunk =============== Diff against Multilingual-topa.204 =============== Item was changed: ----- Method: MultiByteFileStream>>nextChunk (in category 'fileIn/Out') ----- nextChunk "Answer the contents of the receiver, up to the next terminator character. Doubled terminators indicate an embedded terminator character." + ^(wantsLineEndConversion and: [ lineEndConvention notNil ]) + ifTrue: [converter nextChunkLineEndConvertingFromStream: self] + ifFalse: [converter nextChunkFromStream: self]! - ^converter nextChunkFromStream: self! Item was added: + ----- Method: UTF8TextConverter>>nextChunkLineEndConvertingFromStream: (in category 'fileIn/Out') ----- + nextChunkLineEndConvertingFromStream: input + "Answer the contents of input, up to the next terminator character. Doubled terminators indicate an embedded terminator character." + "Obey line end conversion." + + self skipSeparatorsFrom: input. + ^self + parseLangTagFor: ( + self class decodeByteString: ( + String new: 1000 streamContents: [ :stream | + [ + stream nextPutAll: (input upTo: $!!). + input basicNext == $!! ] + whileTrue: [ + stream nextPut: $!! ]. + input atEnd ifFalse: [ input skip: -1 ] ])) + fromStream: input! From commits at source.squeak.org Tue Apr 14 09:05:32 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 09:05:34 2015 Subject: [squeak-dev] The Trunk: Multilingual-cbc.201.mcz Message-ID: Tobias Pape uploaded a new version of Multilingual to project The Trunk: http://source.squeak.org/trunk/Multilingual-cbc.201.mcz ==================== Summary ==================== Name: Multilingual-cbc.201 Author: cbc Time: 25 August 2014, 7:26:42.814 pm UUID: ec7dc4af-4bd3-e348-a14c-b56327372ce3 Ancestors: Multilingual-ul.200 Modify #nextChunk to pass test MultiByteFileStreamTest>>testLIneEndingChunk =============== Diff against Multilingual-ul.200 =============== Item was changed: ----- Method: MultiByteFileStream>>nextChunk (in category 'fileIn/Out') ----- nextChunk "Answer the contents of the receiver, up to the next terminator character. Doubled terminators indicate an embedded terminator character." + ^(wantsLineEndConversion and: [ lineEndConvention notNil ]) + ifTrue: [converter nextChunkLineEndConvertingFromStream: self] + ifFalse: [converter nextChunkFromStream: self]! - ^converter nextChunkFromStream: self! Item was added: + ----- Method: UTF8TextConverter>>nextChunkLineEndConvertingFromStream: (in category 'fileIn/Out') ----- + nextChunkLineEndConvertingFromStream: input + "Answer the contents of input, up to the next terminator character. Doubled terminators indicate an embedded terminator character." + "Obey line end conversion." + + self skipSeparatorsFrom: input. + ^self + parseLangTagFor: ( + self class decodeByteString: ( + String new: 1000 streamContents: [ :stream | + [ + stream nextPutAll: (input upTo: $!!). + input basicNext == $!! ] + whileTrue: [ + stream nextPut: $!! ]. + input atEnd ifFalse: [ input skip: -1 ] ])) + fromStream: input! From marcel.taeumel at student.hpi.uni-potsdam.de Tue Apr 14 09:41:35 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Tue Apr 14 09:54:49 2015 Subject: [squeak-dev] VM crash on full GC in CogVM 3308 Message-ID: <1429004495515-4819477.post@n4.nabble.com> gc-bug.dmp 0x9a751c I SmalltalkImage>garbageCollect 0x1046b6a4: a(n) SmalltalkImage 0x9a7540 M [] in ClassBuilder>update:to: 0x13ad56e0: a(n) ClassBuilder 0x9ac428 M BlockClosure>ensure: 0x13b298cc: a(n) BlockClosure 0x9ac458 I BlockClosure>valueUnpreemptively 0x13b298cc: a(n) BlockClosure 0x9ac474 M ClassBuilder>update:to: 0x13ad56e0: a(n) ClassBuilder 0x9ac49c I ClassBuilder>mutate:to: 0x13ad56e0: a(n) ClassBuilder 0x9ac4cc I [] in ClassBuilder>recompile:from:to:mutate: 0x13ad56e0: a(n) ClassBuilder 0x9ac4e8 M BlockClosure>on:do: 0x13ad8a3c: a(n) BlockClosure 0x9ac514 I CurrentReadOnlySourceFiles class>cacheDuring: 0x1056ceb0: a(n) CurrentReadOnlySourceFiles class ... Best, Marcel -- View this message in context: http://forum.world.st/VM-crash-on-full-GC-in-CogVM-3308-tp4819477.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From marcel.taeumel at student.hpi.uni-potsdam.de Tue Apr 14 09:44:39 2015 From: marcel.taeumel at student.hpi.uni-potsdam.de (Marcel Taeumel) Date: Tue Apr 14 09:57:51 2015 Subject: [squeak-dev] Re: VM crash on full GC in CogVM 3308 In-Reply-To: <1429004495515-4819477.post@n4.nabble.com> References: <1429004495515-4819477.post@n4.nabble.com> Message-ID: <1429004679707-4819479.post@n4.nabble.com> Not occuring with CogVM 3306. Best, Marcel -- View this message in context: http://forum.world.st/VM-crash-on-full-GC-in-CogVM-3308-tp4819477p4819479.html Sent from the Squeak - Dev mailing list archive at Nabble.com. From commits at source.squeak.org Tue Apr 14 11:09:13 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 11:09:15 2015 Subject: [squeak-dev] The Trunk: Universes-kfr.47.mcz Message-ID: Karl Ramberg uploaded a new version of Universes to project The Trunk: http://source.squeak.org/trunk/Universes-kfr.47.mcz ==================== Summary ==================== Name: Universes-kfr.47 Author: kfr Time: 14 April 2015, 1:03:28.878 pm UUID: 46838035-8633-0b4f-90d5-adb4fbe07143 Ancestors: Universes-nice.46 Post removal clean up =============== Diff against Universes-nice.46 =============== Item was added: + (PackageInfo named: 'Universes') postscriptOfRemoval: 'TheWorldMenu cleanUp'! From leves at elte.hu Tue Apr 14 11:17:52 2015 From: leves at elte.hu (Levente Uzonyi) Date: Tue Apr 14 11:17:57 2015 Subject: [squeak-dev] The Trunk: Multilingual-topa.205.mcz In-Reply-To: References: Message-ID: This doesn't look right, because it'll decode the input twice. Once in #upTo:, and once in #decodeByteString:. The latter will fail if its argument is not a valid UTF-8 string after the first decoding. Levente On Tue, 14 Apr 2015, commits@source.squeak.org wrote: > Tobias Pape uploaded a new version of Multilingual to project The Trunk: > http://source.squeak.org/trunk/Multilingual-topa.205.mcz > > ==================== Summary ==================== > > Name: Multilingual-topa.205 > Author: topa > Time: 14 April 2015, 11:04:27.175 am > UUID: da7bc0f1-5f76-40d0-9bcb-7cf96596ac92 > Ancestors: Multilingual-topa.204, Multilingual-cbc.201 > > Pick up a fix for MultiByteFileStream>>#nextChunk > > =============== Diff against Multilingual-topa.204 =============== > > Item was changed: > ----- Method: MultiByteFileStream>>nextChunk (in category 'fileIn/Out') ----- > nextChunk > "Answer the contents of the receiver, up to the next terminator character. Doubled terminators indicate an embedded terminator character." > > + ^(wantsLineEndConversion and: [ lineEndConvention notNil ]) > + ifTrue: [converter nextChunkLineEndConvertingFromStream: self] > + ifFalse: [converter nextChunkFromStream: self]! > - ^converter nextChunkFromStream: self! > > Item was added: > + ----- Method: UTF8TextConverter>>nextChunkLineEndConvertingFromStream: (in category 'fileIn/Out') ----- > + nextChunkLineEndConvertingFromStream: input > + "Answer the contents of input, up to the next terminator character. Doubled terminators indicate an embedded terminator character." > + "Obey line end conversion." > + > + self skipSeparatorsFrom: input. > + ^self > + parseLangTagFor: ( > + self class decodeByteString: ( > + String new: 1000 streamContents: [ :stream | > + [ > + stream nextPutAll: (input upTo: $!!). > + input basicNext == $!! ] > + whileTrue: [ > + stream nextPut: $!! ]. > + input atEnd ifFalse: [ input skip: -1 ] ])) > + fromStream: input! > > > From Das.Linux at gmx.de Tue Apr 14 11:21:38 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Tue Apr 14 11:21:45 2015 Subject: [squeak-dev] The Trunk: Multilingual-topa.205.mcz In-Reply-To: References: Message-ID: <868A3DB8-7F44-4225-8197-4343E883B756@gmx.de> On 14.04.2015, at 13:17, Levente Uzonyi wrote: > This doesn't look right, because it'll decode the input twice. Once in #upTo:, and once in #decodeByteString:. The latter will fail if > its argument is not a valid UTF-8 string after the first decoding. > Darn. Do you have an Idea? Probably the magic of upTo must me moved to decodeByteString for the UTF converter? Best -Tobias > Levente > > On Tue, 14 Apr 2015, commits@source.squeak.org wrote: > >> Tobias Pape uploaded a new version of Multilingual to project The Trunk: >> http://source.squeak.org/trunk/Multilingual-topa.205.mcz >> >> ==================== Summary ==================== >> >> Name: Multilingual-topa.205 >> Author: topa >> Time: 14 April 2015, 11:04:27.175 am >> UUID: da7bc0f1-5f76-40d0-9bcb-7cf96596ac92 >> Ancestors: Multilingual-topa.204, Multilingual-cbc.201 >> >> Pick up a fix for MultiByteFileStream>>#nextChunk >> >> =============== Diff against Multilingual-topa.204 =============== >> >> Item was changed: >> ----- Method: MultiByteFileStream>>nextChunk (in category 'fileIn/Out') ----- >> nextChunk >> "Answer the contents of the receiver, up to the next terminator character. Doubled terminators indicate an embedded terminator character." >> >> + ^(wantsLineEndConversion and: [ lineEndConvention notNil ]) >> + ifTrue: [converter nextChunkLineEndConvertingFromStream: self] >> + ifFalse: [converter nextChunkFromStream: self]! >> - ^converter nextChunkFromStream: self! >> >> Item was added: >> + ----- Method: UTF8TextConverter>>nextChunkLineEndConvertingFromStream: (in category 'fileIn/Out') ----- >> + nextChunkLineEndConvertingFromStream: input >> + "Answer the contents of input, up to the next terminator character. Doubled terminators indicate an embedded terminator character." >> + "Obey line end conversion." >> + >> + self skipSeparatorsFrom: input. >> + ^self >> + parseLangTagFor: ( >> + self class decodeByteString: ( >> + String new: 1000 streamContents: [ :stream | >> + [ >> + stream nextPutAll: (input upTo: $!!). >> + input basicNext == $!! ] >> + whileTrue: [ >> + stream nextPut: $!! ]. >> + input atEnd ifFalse: [ input skip: -1 ] ])) >> + fromStream: input! From commits at source.squeak.org Tue Apr 14 11:45:40 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 11:45:43 2015 Subject: [squeak-dev] The Trunk: Tools-mt.589.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.589.mcz ==================== Summary ==================== Name: Tools-mt.589 Author: mt Time: 14 April 2015, 1:45:01.137 pm UUID: e40f6b35-2f6c-e84b-8c4b-cacc6cec64dc Ancestors: Tools-topa.588 Fixed missing update of changed class definitions in system browsers (and their subclasses). =============== Diff against Tools-topa.588 =============== Item was changed: CodeHolder subclass: #Browser + instanceVariableNames: 'environment systemOrganizer classOrganizer metaClassOrganizer editSelection metaClassIndicated selectedSystemCategory selectedClassName selectedMessageName selectedMessageCategoryName classDefinition metaClassDefinition' - instanceVariableNames: 'environment systemOrganizer classOrganizer metaClassOrganizer editSelection metaClassIndicated selectedSystemCategory selectedClassName selectedMessageName selectedMessageCategoryName' classVariableNames: 'ListClassesHierarchically RecentClasses ShowClassIcons ShowMessageIcons SortMessageCategoriesAlphabetically' poolDictionaries: '' category: 'Tools-Browser'! !Browser commentStamp: 'cwp 12/27/2012 11:09' prior: 0! I represent a query path into the class descriptions, the software of the system.! Item was added: + ----- Method: Browser>>classDefinitionIndicated (in category 'metaclass') ----- + classDefinitionIndicated + + ^ editSelection == #editClass + ! Item was added: + ----- Method: Browser>>didCodeChangeElsewhere (in category 'self-updating') ----- + didCodeChangeElsewhere + + ^ super didCodeChangeElsewhere or: [self classDefinitionIndicated + and: [self metaClassIndicated + ifFalse: [classDefinition ~= self selectedClass definition] + ifTrue: [metaClassDefinition ~= self selectedClass classSide definition]]]! Item was changed: ----- Method: Browser>>selectClassNamed: (in category 'class list') ----- selectClassNamed: aSymbolOrString | className currentMessageCategoryName currentMessageName | currentMessageCategoryName := [self selectedMessageCategoryName] on: Error do: [:ex| ex return: nil]. currentMessageName := [self selectedMessageName] on: Error do: [:ex| ex return: nil]. selectedClassName := aSymbolOrString ifNotNil: [ aSymbolOrString asSymbol ]. self setClassOrganizer. + self setClassDefinition. "Try to reselect the category and/or selector if the new class has them." selectedMessageCategoryName :=(self messageCategoryList includes: currentMessageCategoryName) ifTrue: [currentMessageCategoryName] ifFalse: [nil]. selectedMessageName := (self messageList includes: currentMessageName) ifTrue: [currentMessageName] ifFalse: [nil]. self hasMessageSelected ifTrue: [self editSelection: #editMessage] ifFalse: [self hasMessageCategorySelected ifTrue: [self editSelection: #newMessage] ifFalse: [self classCommentIndicated ifTrue: [self editSelection: #editComment] ifFalse: [self editSelection: (self hasClassSelected not ifTrue: [(metaClassIndicated or: [ self hasSystemCategorySelected not ]) ifTrue: [#none] ifFalse: [#newClass]] ifFalse: [#editClass])]]]. contents := nil. self selectedClass isNil ifFalse: [className := self selectedClass name. (RecentClasses includes: className) ifTrue: [RecentClasses remove: className]. RecentClasses addFirst: className. RecentClasses size > 16 ifTrue: [RecentClasses removeLast]]. self changed: #classSelectionChanged. self changed: #classCommentText. self changed: #classListIndex. "update my selection" self changed: #messageCategoryList. self changed: #messageList. self changed: #relabel. self contentsChanged! Item was added: + ----- Method: Browser>>setClassDefinition (in category 'metaclass') ----- + setClassDefinition + "Remember the current class definition." + + | theClass | + classDefinition := nil. + metaClassDefinition := nil. + self hasClassSelected ifFalse: [^ self]. + theClass := self selectedClass ifNil: [ ^self ]. + classDefinition := theClass definition. + metaClassDefinition := theClass classSide definition.! From commits at source.squeak.org Tue Apr 14 11:50:19 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 11:50:21 2015 Subject: [squeak-dev] The Trunk: Tools-mt.590.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.590.mcz ==================== Summary ==================== Name: Tools-mt.590 Author: mt Time: 14 April 2015, 1:50:02.932 pm UUID: 79c52b3c-791b-e94f-bc09-a230ca57bf5c Ancestors: Tools-mt.589 Use PseudoClass-compatible protocol to access meta-class. =============== Diff against Tools-mt.589 =============== Item was changed: ----- Method: Browser>>didCodeChangeElsewhere (in category 'self-updating') ----- didCodeChangeElsewhere ^ super didCodeChangeElsewhere or: [self classDefinitionIndicated and: [self metaClassIndicated ifFalse: [classDefinition ~= self selectedClass definition] + ifTrue: [metaClassDefinition ~= self selectedClass theMetaClass definition]]]! - ifTrue: [metaClassDefinition ~= self selectedClass classSide definition]]]! Item was changed: ----- Method: Browser>>setClassDefinition (in category 'metaclass') ----- setClassDefinition "Remember the current class definition." | theClass | classDefinition := nil. metaClassDefinition := nil. self hasClassSelected ifFalse: [^ self]. theClass := self selectedClass ifNil: [ ^self ]. classDefinition := theClass definition. + metaClassDefinition := theClass theMetaClass definition.! - metaClassDefinition := theClass classSide definition.! From commits at source.squeak.org Tue Apr 14 12:13:21 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 12:13:25 2015 Subject: [squeak-dev] The Trunk: ST80Tools-mt.7.mcz Message-ID: Marcel Taeumel uploaded a new version of ST80Tools to project The Trunk: http://source.squeak.org/trunk/ST80Tools-mt.7.mcz ==================== Summary ==================== Name: ST80Tools-mt.7 Author: mt Time: 14 April 2015, 2:13:17.821 pm UUID: 3d397bba-6398-da44-8a73-6c6c27ea5724 Ancestors: ST80Tools-topa.6 MVC compatibility for FileList button row =============== Diff against ST80Tools-topa.6 =============== Item was added: + ----- Method: FileList>>optionalButtonViewForMVC (in category '*ST80Tools-initialization') ----- + optionalButtonViewForMVC + "Answer a view of optional buttons" + + | aView bHeight windowWidth offset previousView aButtonView wid services sel allServices | + aView := View new model: self. + bHeight := self optionalButtonHeight. + windowWidth := 120. + aView window: (0 @ 0 extent: windowWidth @ bHeight). + offset := 0. + allServices := self universalButtonServices. + services := allServices copyFrom: 1 to: (allServices size min: 5). + previousView := nil. + services + do: [:service | sel := service selector. + aButtonView := sel asString numArgs = 0 + ifTrue: [PluggableButtonView + on: service provider + getState: (service extraSelector == #none + ifFalse: [service extraSelector]) + action: sel] + ifFalse: [PluggableButtonView + on: service provider + getState: (service extraSelector == #none + ifFalse: [service extraSelector]) + action: sel + getArguments: #fullName + from: self]. + service selector = services last selector + ifTrue: [wid := windowWidth - offset] + ifFalse: [aButtonView + borderWidthLeft: 0 + right: 1 + top: 0 + bottom: 0. + wid := windowWidth // services size - 2]. + aButtonView label: service buttonLabel asParagraph; + window: (offset @ 0 extent: wid @ bHeight). + offset := offset + wid. + service selector = services first selector + ifTrue: [aView addSubView: aButtonView] + ifFalse: [aView addSubView: aButtonView toRightOf: previousView]. + previousView := aButtonView]. + ^ aView! From commits at source.squeak.org Tue Apr 14 12:14:45 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 12:14:47 2015 Subject: [squeak-dev] The Trunk: Tools-mt.591.mcz Message-ID: Marcel Taeumel uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-mt.591.mcz ==================== Summary ==================== Name: Tools-mt.591 Author: mt Time: 14 April 2015, 2:14:27.025 pm UUID: c1af0e66-0871-7d49-856d-fc78f8f28086 Ancestors: Tools-mt.590 MVC dependency removed =============== Diff against Tools-mt.590 =============== Item was removed: - ----- Method: FileList>>optionalButtonViewForMVC (in category 'mvc compatibility') ----- - optionalButtonViewForMVC - "Answer a view of optional buttons" - - | aView bHeight windowWidth offset previousView aButtonView wid services sel allServices | - aView := View new model: self. - bHeight := self optionalButtonHeight. - windowWidth := 120. - aView window: (0 @ 0 extent: windowWidth @ bHeight). - offset := 0. - allServices := self universalButtonServices. - services := allServices copyFrom: 1 to: (allServices size min: 5). - previousView := nil. - services - do: [:service | sel := service selector. - aButtonView := sel asString numArgs = 0 - ifTrue: [PluggableButtonView - on: service provider - getState: (service extraSelector == #none - ifFalse: [service extraSelector]) - action: sel] - ifFalse: [PluggableButtonView - on: service provider - getState: (service extraSelector == #none - ifFalse: [service extraSelector]) - action: sel - getArguments: #fullName - from: self]. - service selector = services last selector - ifTrue: [wid := windowWidth - offset] - ifFalse: [aButtonView - borderWidthLeft: 0 - right: 1 - top: 0 - bottom: 0. - wid := windowWidth // services size - 2]. - aButtonView label: service buttonLabel asParagraph; - window: (offset @ 0 extent: wid @ bHeight). - offset := offset + wid. - service selector = services first selector - ifTrue: [aView addSubView: aButtonView] - ifFalse: [aView addSubView: aButtonView toRightOf: previousView]. - previousView := aButtonView]. - ^ aView! From karlramberg at gmail.com Tue Apr 14 12:18:03 2015 From: karlramberg at gmail.com (karl ramberg) Date: Tue Apr 14 12:18:07 2015 Subject: [squeak-dev] Adding WebClient and SqueakSSL to Trunk? In-Reply-To: <7D10A95B-7E3C-43A2-9308-1237B30480DC@gmx.de> References: <1428247573797-4817693.post@n4.nabble.com> <56781.136.2.1.105.1428339540.squirrel@webmail.msen.com> <7D10A95B-7E3C-43A2-9308-1237B30480DC@gmx.de> Message-ID: We should pull these in to trunk as soon as possible so we can get stuff tested before the release of a new image. Can you do that Levente, as you seem most familiar with the changes you made ? Karl On Mon, Apr 6, 2015 at 9:22 PM, Tobias Pape wrote: > Hi Levente > > On 06.04.2015, at 20:43, Levente Uzonyi wrote: > > > It would be better for these packages too, because they would get more > > attention. > > The SqueakSSL/WebClient changes I made in October[1] are still missing > from the official repositories. > > > > Levente > > > > [1] > http://lists.squeakfoundation.org/pipermail/squeak-dev/2014-October/180251.html > > > > I just now saw that there is more than just vm stuff. > > The problem with WebClient and SqueakSSL as of now is, that > its maintenance-ship is, well, complicated. I went forth and > pushed tiny changes to WebClient by just being somewhat on > my own initiative[1]. > > =========== > > Dear Squeak Community as a whole and dear Ron as person possibly > best fit to make a decision on this: > > Should we put the maintainer-ship of WebClient and > SqueakSSL into the hands of the Squeak Core Team? > > > =========== > > Best > -Tobias > > > > > [1]: There's a saying, initiative is discipline-lessness with positive > outcome > > > On Mon, 6 Apr 2015, Tobias Pape wrote: > > > >> > >> On 06.04.2015, at 18:59, David T. Lewis wrote: > >> > >>>> On Sun, Apr 5, 2015 at 10:26 AM, Marcel Taeumel > >>>> wrote: > >>>>> Hey! :) > >>>>> > >>>>> Can we add both to the update map (somehow?) and see if it works out > >>>>> during > >>>>> the following days/weeks until the release? > >>>> > >>>> +1 > >>>> > >>> > >>> What is the point of moving these into the base image? Aren't these > >>> exactly the kinds of things that you would want to have maintained as > >>> independent packages that can be easily loaded from SqueakMap? > >> > >> I think both these are Extremely Important (capital). > >> WebClient as replacement for HTTPSocket (it already provides a > compatibility > >> layer; Andreas seemed to always considered WebClient to replace > HTTPSocket), > >> and SqueakSSL because you can't load anything meaningful on the web > without > >> SSL; github, twitter, most sites. And that's good. > >> Plus we _finally_ could put the Plain Text Passwords for Monticello > behind > >> SSL? > >> > >> Best > >> -Tobias > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150414/639d6e75/attachment-0001.htm From commits at source.squeak.org Tue Apr 14 14:59:30 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 14:59:32 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.870.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.870.mcz ==================== Summary ==================== Name: Morphic-mt.870 Author: mt Time: 14 April 2015, 4:58:54.922 pm UUID: 45d654e6-9c05-454e-b09c-78cdbd3fbfaf Ancestors: Morphic-mt.869 Fixed a really, really, really nasty GUI bug in system window, which overwrote border width and color of all added morphs. As I do not want to change all Pluggable*Morphs, I just made ScrollPanes white by default. We could move this down the hierarchy... =============== Diff against Morphic-mt.869 =============== Item was added: + ----- Method: ScrollPane>>defaultBorderWidth (in category 'initialization') ----- + defaultBorderWidth + + ^ 1 ! Item was added: + ----- Method: ScrollPane>>defaultColor (in category 'initialization') ----- + defaultColor + + ^ Color white ! Item was changed: ----- Method: SystemWindow>>addMorph:fullFrame: (in category 'panes') ----- addMorph: aMorph fullFrame: aLayoutFrame "Add aMorph according to aLayoutFrame." | windowBorderWidth | windowBorderWidth := self class borderWidth. "If the property #allowPaneSplitters is set to false, do *not* inset morphs by the borderWidth to make room for splitters. This allows windows with non-traditional contents to avoid their component morphs from being clipped. Do *NOT* remove this code please!! Just because there may be no setters of allowPaneSplitters to false in the image doesn't mean they're not out there. Thanks!! eem 6/13/2013" (self valueOfProperty: #allowPaneSplitters ifAbsent: [true]) ifTrue: [| left right bottom top | left := aLayoutFrame leftOffset ifNil: [0]. right := aLayoutFrame rightOffset ifNil: [0]. bottom := aLayoutFrame bottomOffset ifNil: [0]. top := aLayoutFrame topOffset ifNil: [0]. aLayoutFrame rightFraction = 1 ifTrue: [aLayoutFrame rightOffset: right - windowBorderWidth]. aLayoutFrame leftFraction = 0 ifTrue: [aLayoutFrame leftOffset: left + windowBorderWidth] ifFalse: [aLayoutFrame leftOffset: left + ProportionalSplitterMorph splitterWidth]. aLayoutFrame bottomFraction = 1 ifTrue: [aLayoutFrame bottomOffset: bottom - windowBorderWidth]. aLayoutFrame topFraction = 0 ifTrue: [aLayoutFrame topOffset: top + windowBorderWidth] ifFalse: [aLayoutFrame topOffset: top + ProportionalSplitterMorph splitterWidth]]. "this code should not be here!!!! As of 6/13/2013 there aren't even any users of BrowserCommentTextMorph." (aMorph class name = #BrowserCommentTextMorph) ifTrue: [aLayoutFrame rightOffset: windowBorderWidth negated. aLayoutFrame leftOffset: windowBorderWidth. aLayoutFrame bottomOffset: windowBorderWidth negated. aLayoutFrame topOffset: (windowBorderWidth negated) + 4]. super addMorph: aMorph fullFrame: aLayoutFrame. paneMorphs := paneMorphs copyReplaceFrom: 1 to: 0 with: (Array with: aMorph). + aMorph isImageMorph ifFalse: [aMorph adoptPaneColor: self paneColor]. - aMorph isImageMorph ifFalse: - [aMorph adoptPaneColor: self paneColor. - aMorph borderWidth: 1; borderColor: Color lightGray; color: Color white]. Preferences scrollBarsOnRight ifTrue:"reorder panes so flop-out right-side scrollbar is visible" [self addMorphBack: aMorph]. self addPaneSplitters! From commits at source.squeak.org Tue Apr 14 15:02:20 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 15:02:22 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.127.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.127.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.127 Author: mt Time: 14 April 2015, 5:02:13.442 pm UUID: 3b120a47-da89-fc4c-a76a-f61713c2e969 Ancestors: ToolBuilder-Morphic-mt.126 Fixes another really, really, really nasty GUI bug where the tool builder overwrites visual properties when configuring just the layout frame... *sigh* =============== Diff against ToolBuilder-Morphic-mt.126 =============== Item was changed: ----- Method: MorphicToolBuilder>>setFrame:in: (in category 'private') ----- setFrame: aRectangle in: widget | frame | aRectangle ifNil:[^nil]. frame := aRectangle isRectangle ifTrue: [self asFrame: aRectangle] ifFalse: [aRectangle]. "assume LayoutFrame" widget layoutFrame: frame. + widget hResizing: #spaceFill; vResizing: #spaceFill.! - widget hResizing: #spaceFill; vResizing: #spaceFill. - (parent isSystemWindow) ifTrue:[ - widget borderWidth: 2; borderColor: #inset. - ].! From commits at source.squeak.org Tue Apr 14 15:04:23 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 15:04:26 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.128.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.128.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.128 Author: mt Time: 14 April 2015, 5:04:16.422 pm UUID: 93b11520-1c7c-9347-8230-e7d4b3fb1179 Ancestors: ToolBuilder-Morphic-mt.127 Pluggable buttons can get a default color now by just giving that color into the spec's #color:. =============== Diff against ToolBuilder-Morphic-mt.127 =============== Item was changed: ----- Method: MorphicToolBuilder>>buildPluggableButton: (in category 'widgets required') ----- buildPluggableButton: aSpec | widget label state action enabled | label := aSpec label. state := aSpec state. action := aSpec action. widget := self buttonClass on: aSpec model getState: (state isSymbol ifTrue:[state]) action: nil label: (label isSymbol ifTrue:[label]). widget style: aSpec style. aSpec changeLabelWhen ifNotNilDo: [ :event | widget whenChanged: event update: aSpec label]. self register: widget id: aSpec name. enabled := aSpec enabled. enabled isSymbol ifTrue:[widget getEnabledSelector: enabled] ifFalse:[widget enabled:enabled]. widget action: action. + aSpec color isColor + ifTrue: [widget + onColor: aSpec color + offColor: aSpec color] + ifFalse: [ + widget getColorSelector: aSpec color. + widget offColor: Color white]. - widget getColorSelector: aSpec color. - widget offColor: Color white.. self buildHelpFor: widget spec: aSpec. (label isSymbol or:[label == nil]) ifFalse:[widget label: label]. self setFrame: aSpec frame in: widget. parent ifNotNil:[self add: widget to: parent]. ^widget! Item was changed: ----- Method: PluggableButtonMorphPlus>>update: (in category 'updating') ----- update: what + + self getModelState + ifTrue: [self color: onColor] + ifFalse: [self color: offColor]. + what ifNil:[^self]. + what == getLabelSelector ifTrue: [ self label: (model perform: getLabelSelector)]. what == getEnabledSelector ifTrue:[^self enabled: (model perform: getEnabledSelector)]. getColorSelector ifNotNil: [ | cc | color = (cc := model perform: getColorSelector) ifFalse:[ color := cc. self onColor: color offColor: color. self changed. ]. ]. + - self getModelState - ifTrue: [self color: onColor] - ifFalse: [self color: offColor]. getEnabledSelector ifNotNil:[ self enabled: (model perform: getEnabledSelector). ]. updateMap ifNotNil: [(updateMap at: what ifAbsent: []) ifNotNilDo: [ :newTarget | ^self update: newTarget]]. ! From commits at source.squeak.org Tue Apr 14 15:05:36 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 15:05:38 2015 Subject: [squeak-dev] The Trunk: PreferenceBrowser-mt.50.mcz Message-ID: Marcel Taeumel uploaded a new version of PreferenceBrowser to project The Trunk: http://source.squeak.org/trunk/PreferenceBrowser-mt.50.mcz ==================== Summary ==================== Name: PreferenceBrowser-mt.50 Author: mt Time: 14 April 2015, 5:05:30.706 pm UUID: 26cf7124-6923-664f-9f77-0924580051ed Ancestors: PreferenceBrowser-fbs.49 After fixing those nasty GUI bugs in SystemWindow, the preference browser had to be adapted. Looks somewhat nicer now. More like the other tools in the system. Note: We still need to introduce ToolBuilder to the preference browser. =============== Diff against PreferenceBrowser-fbs.49 =============== Item was changed: ----- Method: PreferenceBrowserMorph>>mainPanel (in category 'submorphs - main panel') ----- mainPanel ^mainPanel ifNil: [mainPanel := Morph new color: Color transparent; hResizing: #spaceFill; vResizing: #spaceFill; cellInset: 5; layoutPolicy: TableLayout new; listCentering: #topLeft; listDirection: #leftToRight; cellPositioning: #topLeft; clipSubmorphs: true; on: #mouseEnter send: #paneTransition: to: self; + addMorphBack: self newCategoryList; + addMorphBack: self preferenceList; - addMorphBack: self newCategoryListPanel; - addMorphBack: self newPreferenceListPanel; yourself].! Item was changed: ----- Method: PreferenceBrowserMorph>>newButtonRow (in category 'submorphs - buttons') ----- newButtonRow ^BorderedMorph new color: Color transparent; + borderWidth: 0; cellInset: 2; layoutInset: 2; layoutPolicy: TableLayout new; listDirection: #leftToRight; listCentering: #topLeft; cellPositioning: #topLeft; on: #mouseEnter send: #paneTransition: to: self; on: #mouseLeave send: #paneTransition: to: self; addMorphBack: self defaultButton; addMorphBack: self newSeparator; addMorphBack: self saveButton; addMorphBack: self loadButton; addMorphBack: self newSeparator; addMorphBack: self saveToDiskButton; addMorphBack: self loadFromDiskButton; addMorphBack: self newSeparator; addMorphBack: self themeButton; addMorphBack: self newTransparentFiller; addMorphBack: self helpButton; yourself.! Item was changed: ----- Method: PreferenceBrowserMorph>>newSearchTextField (in category 'submorphs - search panel') ----- newSearchTextField | ptm | + ptm := PluggableTextMorphPlus - ptm := PluggableTextMorph on: self model text: #searchPatternNeverTriggered accept: #searchPattern:. ptm + balloonText: 'Search preferences ...'; hideVScrollBarIndefinitely: true; borderInset; color: Color white; vResizing: #rigid; hResizing: #spaceFill; height: TextStyle defaultFont height * 2; acceptOnCR: true; onKeyStrokeSend: #value to: [ ptm hasUnacceptedEdits ifTrue: [ ptm accept ] ]. ^ptm.! Item was changed: ----- Method: PreferenceBrowserMorph>>rootPanel (in category 'submorphs - root panel') ----- rootPanel ^BorderedMorph new color: Color transparent; + borderWidth: 0; - layoutInset: 10; cellInset: 10; layoutPolicy: TableLayout new; listDirection: #topToBottom; listCentering: #topLeft; cellPositioning: #topLeft; + addMorphBack: self newSearchTextField; - addMorphBack: self newSearchPanel; addMorphBack: self mainPanel; yourself.! From commits at source.squeak.org Tue Apr 14 15:11:20 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 15:11:21 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Kernel-mt.77.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Kernel to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Kernel-mt.77.mcz ==================== Summary ==================== Name: ToolBuilder-Kernel-mt.77 Author: mt Time: 14 April 2015, 5:11:14.532 pm UUID: ea748059-159e-c341-b3f1-6cc025c53148 Ancestors: ToolBuilder-Kernel-mt.76 Added possibility to choose multiple items from a list of items. =============== Diff against ToolBuilder-Kernel-mt.76 =============== Item was added: + ----- Method: UIManager>>chooseMultipleFrom: (in category 'ui requests') ----- + chooseMultipleFrom: aList + "Choose one or more items from the given list. Answer the indices of the selected items." + + ^ self chooseMultipleFrom: aList lines: #()! Item was added: + ----- Method: UIManager>>chooseMultipleFrom:lines: (in category 'ui requests') ----- + chooseMultipleFrom: aList lines: linesArray + "Choose one or more items from the given list. Answer the indices of the selected items." + + ^ self chooseMultipleFrom: aList lines: linesArray title: ''! Item was added: + ----- Method: UIManager>>chooseMultipleFrom:lines:title: (in category 'ui requests') ----- + chooseMultipleFrom: aList lines: linesArray title: aString + "Choose one or more items from the given list. Answer the indices of the selected items." + + ^ (self chooseFrom: aList lines: linesArray title: aString) in: [:result | + result = 0 ifTrue: [#()] ifFalse: [{result}]]! Item was added: + ----- Method: UIManager>>chooseMultipleFrom:title: (in category 'ui requests') ----- + chooseMultipleFrom: aList title: aString + "Choose one or more items from the given list. Answer the indices of the selected items." + + ^self chooseMultipleFrom: aList lines: #() title: aString! Item was added: + ----- Method: UIManager>>chooseMultipleFrom:values: (in category 'ui requests') ----- + chooseMultipleFrom: labelList values: valueList + "Choose one or more items from the given list. Answer the selected items." + + ^ self chooseMultipleFrom: labelList values: valueList lines: #()! Item was added: + ----- Method: UIManager>>chooseMultipleFrom:values:lines: (in category 'ui requests') ----- + chooseMultipleFrom: labelList values: valueList lines: linesArray + "Choose one or more items from the given list. Answer the selected items." + + ^ self chooseMultipleFrom: labelList values: valueList lines: linesArray title: ''! Item was added: + ----- Method: UIManager>>chooseMultipleFrom:values:lines:title: (in category 'ui requests') ----- + chooseMultipleFrom: labelList values: valueList lines: linesArray title: aString + "Choose one or more items from the given list. Answer the selected items." + + ^ (self chooseFrom: labelList values: valueList lines: linesArray title: aString) + ifNil: [#()] + ifNotNil: [:resultValue | {resultValue}]! Item was added: + ----- Method: UIManager>>chooseMultipleFrom:values:title: (in category 'ui requests') ----- + chooseMultipleFrom: labelList values: valueList title: aString + "Choose one or more items from the given list. Answer the selected items." + + ^ self chooseMultipleFrom: labelList values: valueList lines: #() title: aString! From commits at source.squeak.org Tue Apr 14 15:12:51 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 15:12:53 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.129.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.129.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.129 Author: mt Time: 14 April 2015, 5:12:45.809 pm UUID: b45b099e-a5a7-1247-87fb-4be9a197efbf Ancestors: ToolBuilder-Morphic-mt.128 Added possibility to choose multiple items from a list of items in Morphic. =============== Diff against ToolBuilder-Morphic-mt.128 =============== Item was added: + Model subclass: #ListMultipleChooser + instanceVariableNames: 'selection labels values title choice' + classVariableNames: '' + poolDictionaries: '' + category: 'ToolBuilder-Morphic'! + + !ListMultipleChooser commentStamp: 'mt 4/14/2015 17:09' prior: 0! + I am like the ListChooser but for multiple choices. I have no extra search field. Enable the preference #filterableLists if lists get too big to choose from. Also, I do not support adding new items to the choice.! Item was added: + ----- Method: ListMultipleChooser class>>chooseFrom:title: (in category 'ui requests') ----- + chooseFrom: someLabels title: aString + + ^ self chooseIndexFrom: someLabels title: aString! Item was added: + ----- Method: ListMultipleChooser class>>chooseIndexListFrom:title: (in category 'ui requests') ----- + chooseIndexListFrom: someObjects title: aString + + ^ self new + title: aString; + labels: (someObjects collect: [:ea | ea asString]); + choose! Item was added: + ----- Method: ListMultipleChooser class>>chooseItemListFrom:title: (in category 'ui requests') ----- + chooseItemListFrom: someObjects title: aString + + ^ self new + title: aString; + labels: (someObjects collect: [:ea | ea asString]); + values: someObjects; + choose! Item was added: + ----- Method: ListMultipleChooser>>accept (in category 'actions') ----- + accept + + choice := #accepted. + self changed: #close.! Item was added: + ----- Method: ListMultipleChooser>>buildWith: (in category 'toolbuilder') ----- + buildWith: builder + + | windowSpec choicesSpec acceptSpec cancelSpec buttonHeight | + windowSpec := builder pluggableWindowSpec new + model: self; + extent: 250@400; + label: #title; + children: OrderedCollection new. + + buttonHeight := Preferences standardButtonFont height * 4. + + choicesSpec := builder pluggableMultiSelectionListSpec new + model: self; + list: #labels; + setIndex: #selectedIndex:; + getIndex: #selectedIndex; + setSelectionList: #selectionAt:put:; + getSelectionList: #selectionAt:; + frame: (LayoutFrame fractions: (0@0 corner: 1@1) offsets: (0@0 corner: 0@ buttonHeight negated)). + windowSpec children add: choicesSpec. + + acceptSpec := builder pluggableButtonSpec new + model: self; + label: 'accept'; + color: ColorTheme current okColor; + action: #accept; + frame: (LayoutFrame fractions: (0@1 corner: 0.5@1) offsets: (0@ buttonHeight negated corner: 0@0)). + windowSpec children add: acceptSpec. + + cancelSpec := builder pluggableButtonSpec new + model: self; + label: 'cancel'; + color: ColorTheme current cancelColor; + action: #cancel; + frame: (LayoutFrame fractions: (0.5@1 corner: 1@1) offsets: (0@ buttonHeight negated corner: 0@0)). + windowSpec children add: cancelSpec. + + ^ builder build: windowSpec! Item was added: + ----- Method: ListMultipleChooser>>cancel (in category 'actions') ----- + cancel + + choice := #cancelled. + self changed: #close.! Item was added: + ----- Method: ListMultipleChooser>>choose (in category 'actions') ----- + choose + + | builder window | + builder := ToolBuilder default. + window := builder open: self.. + window center: Sensor cursorPoint. "Avoid morphic dependency here..." + builder runModal: window. + + ^ self selectedValues! Item was added: + ----- Method: ListMultipleChooser>>labels (in category 'accessing') ----- + labels + + ^ labels! Item was added: + ----- Method: ListMultipleChooser>>labels: (in category 'accessing') ----- + labels: someStrings + + labels := someStrings. + self changed: #labels.! Item was added: + ----- Method: ListMultipleChooser>>selectedIndex (in category 'accessing') ----- + selectedIndex + "Sigh. Required from widget..." + ^ 0! Item was added: + ----- Method: ListMultipleChooser>>selectedIndex: (in category 'accessing') ----- + selectedIndex: anIndex + "Sigh. Required from widget..." + self changed: #selectedIndex.! Item was added: + ----- Method: ListMultipleChooser>>selectedValues (in category 'accessing') ----- + selectedValues + + | i | + choice ~~ #accepted ifTrue: [^ nil]. + + i := 0. + ^ self values select: [:object | i := i + 1. self selection at: i]! Item was added: + ----- Method: ListMultipleChooser>>selection (in category 'accessing') ----- + selection + + ^ selection ifNil: [selection := Array new: self values size withAll: false]! Item was added: + ----- Method: ListMultipleChooser>>selectionAt: (in category 'accessing') ----- + selectionAt: index + + ^ self selection at: index! Item was added: + ----- Method: ListMultipleChooser>>selectionAt:put: (in category 'accessing') ----- + selectionAt: index put: boolean + + self selection at: index put: boolean. + self changed: #selectedIndex! Item was added: + ----- Method: ListMultipleChooser>>title (in category 'accessing') ----- + title + + ^ (title isNil or: [title isEmpty]) + ifFalse: [title] + ifTrue: ['Choose multiple:']! Item was added: + ----- Method: ListMultipleChooser>>title: (in category 'accessing') ----- + title: aString + + title := aString. + self changed: #title.! Item was added: + ----- Method: ListMultipleChooser>>values (in category 'accessing') ----- + values + + ^ values ifNil: [values := (1 to: self labels size) asArray]! Item was added: + ----- Method: ListMultipleChooser>>values: (in category 'accessing') ----- + values: someObjects + + values := someObjects.! Item was added: + ----- Method: MorphicUIManager>>chooseMultipleFrom:lines:title: (in category 'ui requests') ----- + chooseMultipleFrom: aList lines: linesArray title: aString + "Choose one or more items from the given list. Answer the indices of the selected items." + + ^ ListMultipleChooser + chooseFrom: aList + title: aString! Item was added: + ----- Method: MorphicUIManager>>chooseMultipleFrom:values:lines:title: (in category 'ui requests') ----- + chooseMultipleFrom: labelList values: valueList lines: linesArray title: aString + "Choose one or more items from the given list. Answer the selected items." + + ^ (ListMultipleChooser + chooseFrom: labelList + title: aString) ifNotNil: [:indexList | + indexList collect: [:index | valueList at: index]]! From commits at source.squeak.org Tue Apr 14 15:24:42 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 15:24:44 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.130.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.130.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.130 Author: mt Time: 14 April 2015, 5:24:26.493 pm UUID: a335a666-59fb-694d-9c6f-3fb16b988a12 Ancestors: ToolBuilder-Morphic-mt.129 Typo fixed. =============== Diff against ToolBuilder-Morphic-mt.129 =============== Item was changed: ----- Method: ListMultipleChooser class>>chooseFrom:title: (in category 'ui requests') ----- chooseFrom: someLabels title: aString + ^ self chooseIndexListFrom: someLabels title: aString! - ^ self chooseIndexFrom: someLabels title: aString! From commits at source.squeak.org Tue Apr 14 16:32:16 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 16:32:18 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.871.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.871.mcz ==================== Summary ==================== Name: Morphic-mt.871 Author: mt Time: 14 April 2015, 6:31:44.754 pm UUID: d91a8d3d-b59d-6245-be59-df35d9ca1c1f Ancestors: Morphic-mt.870 FillInTheBlankMorph is now resized to better fit its initialAnswer. =============== Diff against Morphic-mt.870 =============== Item was changed: ----- Method: FillInTheBlankMorph class>>defaultAnswerExtent (in category 'default constants') ----- defaultAnswerExtent + ^ (200@ (3 * Preferences standardDefaultTextFont height))! - ^ (200@60 * (Preferences standardMenuFont height / 12)) rounded! Item was changed: ----- Method: FillInTheBlankMorph>>setQuery:initialAnswer:answerExtent:acceptOnCR: (in category 'initialization') ----- setQuery: queryString initialAnswer: initialAnswer answerExtent: answerExtent acceptOnCR: acceptBoolean | query topOffset accept cancel buttonAreaHeight | response := initialAnswer. done := false. self removeAllMorphs. self layoutPolicy: ProportionalLayout new. query := self createQueryTextMorph: queryString. topOffset := query height + 4. accept := self createAcceptButton. cancel := self createCancelButton. buttonAreaHeight := (accept height max: cancel height) + 7. textPane := self createTextPaneExtent: answerExtent acceptBoolean: acceptBoolean topOffset: topOffset buttonAreaHeight: buttonAreaHeight. + + self extent: ((answerExtent max: query extent) + max: (initialAnswer asText asMorph extent)) + (20@30) + (0 @ (topOffset + buttonAreaHeight))! - self extent: (query extent x max: answerExtent x) - + 4 @ (topOffset + answerExtent y + 4 + buttonAreaHeight). - ! From commits at source.squeak.org Tue Apr 14 17:12:18 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 17:12:19 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.872.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.872.mcz ==================== Summary ==================== Name: Morphic-mt.872 Author: mt Time: 14 April 2015, 7:11:42.968 pm UUID: 9805bd03-c0bd-e14a-9898-0501f7b9d66e Ancestors: Morphic-mt.871 A fix for small scroll bars. Lower the min extent to 4@8 or 8@4 to support smaller fonts. =============== Diff against Morphic-mt.871 =============== Item was changed: ----- Method: ScrollBar>>extent: (in category 'geometry') ----- extent: p p x > p y ifTrue: [super + extent: (p max: 8 @ 4)] - extent: (p max: 42 @ 8)] ifFalse: [super + extent: (p max: 4 @ 8)]. - extent: (p max: 8 @ 42)]. ! From commits at source.squeak.org Tue Apr 14 17:14:05 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 17:14:08 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.873.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.873.mcz ==================== Summary ==================== Name: Morphic-mt.873 Author: mt Time: 14 April 2015, 7:13:14.346 pm UUID: 425d78a8-53e2-c344-a4cd-82ae0d9926aa Ancestors: Morphic-mt.872 New color picker morph now uses one-liner for displaying the color expression. It also adds a drop-shadow if menuAppearance3d is enabled. (Note: There seems to be still some v-scrolling bug... hmmmm...) =============== Diff against Morphic-mt.872 =============== Item was changed: ----- Method: NewColorPickerMorph>>newColorExpressionMorph (in category 'initialize-release') ----- newColorExpressionMorph + | inputField builder | + builder := ToolBuilder default. + inputField := (builder build: (builder pluggableInputFieldSpec new + model: self; + getText: #colorExpression; + setText: #colorExpression:)). + inputField - | pluggable | - pluggable := (PluggableTextMorph - on: self - text: #colorExpression - accept: #colorExpression:) hResizing: #spaceFill ; vResizing: #rigid ; + height: (Preferences standardDefaultTextFont height * 3/2). + ^ inputField! - height: 20 ; - acceptOnCR: true ; - retractableOrNot ; - yourself. - pluggable textMorph autoFit: false. - ^ pluggable! Item was changed: ----- Method: NewColorPickerMorph>>setup (in category 'initialize-release') ----- setup self color: (Color white slightlyDarker alpha: 0.88) ; cornerStyle: #rounded ; changeTableLayout ; hResizing: #rigid ; vResizing: #rigid ; extent: 240@240 ; addMorphBack: hsvaMorph ; addMorphBack: self newColorExpressionMorph ; addMorphBack: self newBottomRow ; layoutInset: 4 ; + cellInset: 2. + + Preferences menuAppearance3d + ifTrue: [self addDropShadow].! - cellInset: 0! From commits at source.squeak.org Tue Apr 14 21:55:09 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 21:55:11 2015 Subject: [squeak-dev] Daily Commit Log Message-ID: <20150414215509.24789.qmail@box4.squeakfoundation.org> Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours: http://lists.squeakfoundation.org/pipermail/packages/2015-April/007966.html Name: Installer-Core-cmm.397 Ancestors: Installer-Core-cmm.396 SqueakSource employs server-specific versions of OSProcess and RFB. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007967.html Name: Morphic-mt.868 Ancestors: Morphic-mt.867 Extended the "openToolsAttachedToMouseCursor" preference to allow resizing-after-dropping directly if you keep the mouse button pressed and move it. Thanks Bert for the idea! :-) Note: With fast-dragging enabled, accidential resize might shrink the window unexpectedly because we cannot change mouse position programmatically. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007968.html Name: Tools-mt.587 Ancestors: Tools-mt.586 Fixed a regression in file contents browser. That browser misuses the system category pane for displaying the file name. Having this, it has to consider the normal use of that list in browsers. Note: Having '-- all --' in the list of system categories will normally not affect other browsers as we can see in the HierarchBrowser. Thanks to Chris for pointing out that bug. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007969.html Name: Morphic-mt.869 Ancestors: Morphic-mt.868 Fixed resize-after-drop to work only for the initial drop. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007970.html Name: ToolBuilder-Morphic-mt.126 Ancestors: ToolBuilder-Morphic-mt.125 Fixed resize-after-drop to work only for the initial drop. Added a flag for #initialDrop to the affected tool window. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007971.html Name: Kernel-mt.919 Ancestors: Kernel-mt.918 Fixed Object organization to not have all-category as a real category. Was empty anyway. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007972.html Name: KernelTests-mt.292 Ancestors: KernelTests-ul.291 Test added for checking whether some class organization has special categories in it. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007973.html Name: ST80Tools-topa.6 Ancestors: ST80Tools-mt.5 Assume responsibility of #openInMVC in a Tool ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007974.html Name: Tools-topa.588 Ancestors: Tools-mt.587 Drop responsibility of #openInMVC to ST80Tools ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007975.html Name: Kernel-topa.920 Ancestors: Kernel-mt.919 Remove spurious -- all -- category that crept into Object ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007976.html Name: ToolsTests-topa.72 Ancestors: ToolsTests-mt.71 Adapt BrowserTests to rely less on global state, namely SystemOrganization ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007977.html Name: Multilingual-topa.205 Ancestors: Multilingual-topa.204, Multilingual-cbc.201 Pick up a fix for MultiByteFileStream>>#nextChunk ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007978.html Name: Multilingual-cbc.201 Ancestors: Multilingual-ul.200 Modify #nextChunk to pass test MultiByteFileStreamTest>>testLIneEndingChunk ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007979.html Name: Universes-kfr.47 Ancestors: Universes-nice.46 Post removal clean up ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007980.html Name: Tools-mt.589 Ancestors: Tools-topa.588 Fixed missing update of changed class definitions in system browsers (and their subclasses). ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007981.html Name: Tools-mt.590 Ancestors: Tools-mt.589 Use PseudoClass-compatible protocol to access meta-class. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007982.html Name: ST80Tools-mt.7 Ancestors: ST80Tools-topa.6 MVC compatibility for FileList button row ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007983.html Name: Tools-mt.591 Ancestors: Tools-mt.590 MVC dependency removed ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007984.html Name: Morphic-mt.870 Ancestors: Morphic-mt.869 Fixed a really, really, really nasty GUI bug in system window, which overwrote border width and color of all added morphs. As I do not want to change all Pluggable*Morphs, I just made ScrollPanes white by default. We could move this down the hierarchy... ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007985.html Name: ToolBuilder-Morphic-mt.127 Ancestors: ToolBuilder-Morphic-mt.126 Fixes another really, really, really nasty GUI bug where the tool builder overwrites visual properties when configuring just the layout frame... *sigh* ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007986.html Name: ToolBuilder-Morphic-mt.128 Ancestors: ToolBuilder-Morphic-mt.127 Pluggable buttons can get a default color now by just giving that color into the spec's #color:. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007987.html Name: PreferenceBrowser-mt.50 Ancestors: PreferenceBrowser-fbs.49 After fixing those nasty GUI bugs in SystemWindow, the preference browser had to be adapted. Looks somewhat nicer now. More like the other tools in the system. Note: We still need to introduce ToolBuilder to the preference browser. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007988.html Name: ToolBuilder-Kernel-mt.77 Ancestors: ToolBuilder-Kernel-mt.76 Added possibility to choose multiple items from a list of items. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007989.html Name: ToolBuilder-Morphic-mt.129 Ancestors: ToolBuilder-Morphic-mt.128 Added possibility to choose multiple items from a list of items in Morphic. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007990.html Name: ToolBuilder-Morphic-mt.130 Ancestors: ToolBuilder-Morphic-mt.129 Typo fixed. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007991.html Name: Morphic-mt.871 Ancestors: Morphic-mt.870 FillInTheBlankMorph is now resized to better fit its initialAnswer. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007992.html Name: Morphic-mt.872 Ancestors: Morphic-mt.871 A fix for small scroll bars. Lower the min extent to 4 at 8 or 8 at 4 to support smaller fonts. ============================================= http://lists.squeakfoundation.org/pipermail/packages/2015-April/007993.html Name: Morphic-mt.873 Ancestors: Morphic-mt.872 New color picker morph now uses one-liner for displaying the color expression. It also adds a drop-shadow if menuAppearance3d is enabled. (Note: There seems to be still some v-scrolling bug... hmmmm...) ============================================= From commits at source.squeak.org Tue Apr 14 23:16:31 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Tue Apr 14 23:16:33 2015 Subject: [squeak-dev] The Inbox: Multilingual-ul.206.mcz Message-ID: A new version of Multilingual was added to project The Inbox: http://source.squeak.org/inbox/Multilingual-ul.206.mcz ==================== Summary ==================== Name: Multilingual-ul.206 Author: ul Time: 15 April 2015, 12:58:54.863 am UUID: 87d8c067-7d51-4aec-b5bc-d439b821e143 Ancestors: Multilingual-topa.205 TextConverter >> #decodeString: and UTF8TextConverter >> #decodeString: does line end conversion as requested. UTF8TextConverter >> #decodeString: takes into account the requested line end conversion. UTF8TextConverter >> #nextChunkFromStream: uses #decodeString:, which does implements line end conversion. =============== Diff against Multilingual-topa.205 =============== Item was changed: ----- Method: MultiByteFileStream>>nextChunk (in category 'fileIn/Out') ----- nextChunk "Answer the contents of the receiver, up to the next terminator character. Doubled terminators indicate an embedded terminator character." + ^converter nextChunkFromStream: self! - ^(wantsLineEndConversion and: [ lineEndConvention notNil ]) - ifTrue: [converter nextChunkLineEndConvertingFromStream: self] - ifFalse: [converter nextChunkFromStream: self]! Item was changed: ----- Method: TextConverter>>decodeString: (in category 'conversion') ----- decodeString: aString + | result | + result := String new: aString size streamContents: [ :stream | - ^String new: aString size streamContents: [ :stream | | readStream character | readStream := aString readStream. [ (character := self nextFromStream: readStream) == nil ] + whileFalse: [ stream nextPut: character ] ]. + self class latin1Encodings == latin1Encodings ifTrue: [ ^result ]. + ^result withSqueakLineEndings! - whileFalse: [ stream nextPut: character ] ] - ! Item was changed: ----- Method: UTF8TextConverter>>decodeString: (in category 'conversion') ----- decodeString: aString + | result | + aString isByteString ifFalse: [ ^super decodeString: aString ]. + result := self class decodeByteString: aString. + self class latin1Encodings == latin1Encodings ifTrue: [ ^result ]. + ^result withSqueakLineEndings! - aString isByteString ifTrue: [ ^self class decodeByteString: aString ]. - ^super decodeString: aString! Item was changed: ----- Method: UTF8TextConverter>>encodeString: (in category 'conversion') ----- encodeString: aString + | result | + aString isByteString ifFalse: [ ^super encodeString: aString ]. + result := self class encodeByteString: aString. + self class latin1Encodings == latin1Encodings ifTrue: [ ^result ]. + ^result withLineEndings: (latin1Encodings at: 14) + ! - aString isByteString ifTrue: [ ^self class encodeByteString: aString ]. - ^super encodeString: aString! Item was changed: ----- Method: UTF8TextConverter>>nextChunkFromStream: (in category 'fileIn/Out') ----- nextChunkFromStream: input "Answer the contents of input, up to the next terminator character. Doubled terminators indicate an embedded terminator character." self skipSeparatorsFrom: input. ^self parseLangTagFor: ( + self decodeString: ( - self class decodeByteString: ( String new: 1000 streamContents: [ :stream | [ stream nextPutAll: (input basicUpTo: $!!). input basicNext == $!! ] whileTrue: [ stream nextPut: $!! ]. input atEnd ifFalse: [ input skip: -1 ] ])) fromStream: input! Item was removed: - ----- Method: UTF8TextConverter>>nextChunkLineEndConvertingFromStream: (in category 'fileIn/Out') ----- - nextChunkLineEndConvertingFromStream: input - "Answer the contents of input, up to the next terminator character. Doubled terminators indicate an embedded terminator character." - "Obey line end conversion." - - self skipSeparatorsFrom: input. - ^self - parseLangTagFor: ( - self class decodeByteString: ( - String new: 1000 streamContents: [ :stream | - [ - stream nextPutAll: (input upTo: $!!). - input basicNext == $!! ] - whileTrue: [ - stream nextPut: $!! ]. - input atEnd ifFalse: [ input skip: -1 ] ])) - fromStream: input! From leves at elte.hu Tue Apr 14 23:20:17 2015 From: leves at elte.hu (Levente Uzonyi) Date: Tue Apr 14 23:20:19 2015 Subject: [squeak-dev] The Trunk: Multilingual-topa.205.mcz In-Reply-To: <868A3DB8-7F44-4225-8197-4343E883B756@gmx.de> References: <868A3DB8-7F44-4225-8197-4343E883B756@gmx.de> Message-ID: On Tue, 14 Apr 2015, Tobias Pape wrote: > > On 14.04.2015, at 13:17, Levente Uzonyi wrote: > >> This doesn't look right, because it'll decode the input twice. Once in #upTo:, and once in #decodeByteString:. The latter will fail if >> its argument is not a valid UTF-8 string after the first decoding. >> > > Darn. > Do you have an Idea? > Probably the magic of upTo must me moved > to decodeByteString for the UTF converter? I've uploaded Multilingual-ul.206 to the Inbox with a more general fix. The asymmetry in line end conversions was a bit surprising to me, but the tests are green. Levente > Best > -Tobias > >> Levente >> >> On Tue, 14 Apr 2015, commits@source.squeak.org wrote: >> >>> Tobias Pape uploaded a new version of Multilingual to project The Trunk: >>> http://source.squeak.org/trunk/Multilingual-topa.205.mcz >>> >>> ==================== Summary ==================== >>> >>> Name: Multilingual-topa.205 >>> Author: topa >>> Time: 14 April 2015, 11:04:27.175 am >>> UUID: da7bc0f1-5f76-40d0-9bcb-7cf96596ac92 >>> Ancestors: Multilingual-topa.204, Multilingual-cbc.201 >>> >>> Pick up a fix for MultiByteFileStream>>#nextChunk >>> >>> =============== Diff against Multilingual-topa.204 =============== >>> >>> Item was changed: >>> ----- Method: MultiByteFileStream>>nextChunk (in category 'fileIn/Out') ----- >>> nextChunk >>> "Answer the contents of the receiver, up to the next terminator character. Doubled terminators indicate an embedded terminator character." >>> >>> + ^(wantsLineEndConversion and: [ lineEndConvention notNil ]) >>> + ifTrue: [converter nextChunkLineEndConvertingFromStream: self] >>> + ifFalse: [converter nextChunkFromStream: self]! >>> - ^converter nextChunkFromStream: self! >>> >>> Item was added: >>> + ----- Method: UTF8TextConverter>>nextChunkLineEndConvertingFromStream: (in category 'fileIn/Out') ----- >>> + nextChunkLineEndConvertingFromStream: input >>> + "Answer the contents of input, up to the next terminator character. Doubled terminators indicate an embedded terminator character." >>> + "Obey line end conversion." >>> + >>> + self skipSeparatorsFrom: input. >>> + ^self >>> + parseLangTagFor: ( >>> + self class decodeByteString: ( >>> + String new: 1000 streamContents: [ :stream | >>> + [ >>> + stream nextPutAll: (input upTo: $!!). >>> + input basicNext == $!! ] >>> + whileTrue: [ >>> + stream nextPut: $!! ]. >>> + input atEnd ifFalse: [ input skip: -1 ] ])) >>> + fromStream: input! > > > > From Das.Linux at gmx.de Wed Apr 15 00:34:31 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Wed Apr 15 00:34:36 2015 Subject: [squeak-dev] The Trunk: Multilingual-topa.205.mcz In-Reply-To: References: <868A3DB8-7F44-4225-8197-4343E883B756@gmx.de> Message-ID: <7D223EA0-78A2-4D2B-B44B-89A926F1D4DF@gmx.de> On 15.04.2015, at 01:20, Levente Uzonyi wrote: > On Tue, 14 Apr 2015, Tobias Pape wrote: > >> >> On 14.04.2015, at 13:17, Levente Uzonyi wrote: >> >>> This doesn't look right, because it'll decode the input twice. Once in #upTo:, and once in #decodeByteString:. The latter will fail if >>> its argument is not a valid UTF-8 string after the first decoding. >>> >> >> Darn. >> Do you have an Idea? >> Probably the magic of upTo must me moved >> to decodeByteString for the UTF converter? > > I've uploaded Multilingual-ul.206 to the Inbox with a more general fix. > The asymmetry in line end conversions was a bit surprising to me, but the tests are green. Thank you, Levente! Best -Tobias > >> Best >> -Tobias >> >>> Levente >>> >>> On Tue, 14 Apr 2015, commits@source.squeak.org wrote: >>> >>>> Tobias Pape uploaded a new version of Multilingual to project The Trunk: >>>> http://source.squeak.org/trunk/Multilingual-topa.205.mcz >>>> >>>> ==================== Summary ==================== >>>> >>>> Name: Multilingual-topa.205 >>>> Author: topa >>>> Time: 14 April 2015, 11:04:27.175 am >>>> UUID: da7bc0f1-5f76-40d0-9bcb-7cf96596ac92 >>>> Ancestors: Multilingual-topa.204, Multilingual-cbc.201 >>>> >>>> Pick up a fix for MultiByteFileStream>>#nextChunk >>>> >>>> =============== Diff against Multilingual-topa.204 =============== >>>> >>>> Item was changed: >>>> ----- Method: MultiByteFileStream>>nextChunk (in category 'fileIn/Out') ----- >>>> nextChunk >>>> "Answer the contents of the receiver, up to the next terminator character. Doubled terminators indicate an embedded terminator character." >>>> >>>> + ^(wantsLineEndConversion and: [ lineEndConvention notNil ]) >>>> + ifTrue: [converter nextChunkLineEndConvertingFromStream: self] >>>> + ifFalse: [converter nextChunkFromStream: self]! >>>> - ^converter nextChunkFromStream: self! >>>> >>>> Item was added: >>>> + ----- Method: UTF8TextConverter>>nextChunkLineEndConvertingFromStream: (in category 'fileIn/Out') ----- >>>> + nextChunkLineEndConvertingFromStream: input >>>> + "Answer the contents of input, up to the next terminator character. Doubled terminators indicate an embedded terminator character." >>>> + "Obey line end conversion." >>>> + >>>> + self skipSeparatorsFrom: input. >>>> + ^self >>>> + parseLangTagFor: ( >>>> + self class decodeByteString: ( >>>> + String new: 1000 streamContents: [ :stream | >>>> + [ >>>> + stream nextPutAll: (input upTo: $!!). >>>> + input basicNext == $!! ] >>>> + whileTrue: [ >>>> + stream nextPut: $!! ]. >>>> + input atEnd ifFalse: [ input skip: -1 ] ])) >>>> + fromStream: input! From Das.Linux at gmx.de Wed Apr 15 08:47:48 2015 From: Das.Linux at gmx.de (Tobias Pape) Date: Wed Apr 15 08:47:56 2015 Subject: [squeak-dev] SqueakSSL + TLS SNI In-Reply-To: References: <20150410010245.GC1878@shell.msen.com> <462BB520-E8D2-49DD-9755-A7AAF5A831D6@gmx.de> Message-ID: Hey On 10.04.2015, at 15:33, Levente Uzonyi wrote: > I'm sure there's interest, because websites with wildcard certificates (which means most large websites) don't work without the SNI extension. > > I read through your code, and it looks good to me. The "if(" -> "if (" rewrite was a bit annoying though. Sorry :/ > Maybe you should CC th vm-dev list, or just ping Eliot to get it into the Cog branch. Ok, hello vm-dev. I also attached a new version of sqMacSSL.c, I made a small protocol selection error before. Sadly, I cannot attach it to the mantis bug due to a "duplicate file" error. Best -Tobias > > Levente > > On Fri, 10 Apr 2015, Tobias Pape wrote: > >> Here's a Mac bundle, if someone is interested >> >> On 10.04.2015, at 03:02, David T. Lewis wrote: >> >>> On Fri, Apr 10, 2015 at 02:17:45AM +0200, Tobias Pape wrote: >>>> Hi, >>>> >>>> >>>> On 16.10.2014, at 13:46, Levente Uzonyi wrote: >>>> >>>>> Hi, >>>>> >>>>> I've implemented support for TLS SNI[1] for SqueakSSL on unix. I've uploaded the modified source files[2][3], a diff[4], and a prebuilt module[5] (built on Ubuntu 14.04 from the Cog branch). >>>>> The image side code is also available[6], along with an updated version of the WebClient[7] package, and intermediate packages with various improvements[8]. >>>>> The image side code works even if the plugin doesn't support TLS SNI, but this version of WebClient won't work with older versions of the SqueakSSL-Core package. >>>>> Please review the changes, and consider adding them to the corresponding repositories! >>>>> >>>>> Levente >>>>> >>>>> [1] https://en.wikipedia.org/wiki/Server_Name_Indication >>>>> [2] http://leves.web.elte.hu/squeak/SqueakSSL/SqueakSSL.h >>>>> [3] http://leves.web.elte.hu/squeak/SqueakSSL/sqUnixOpenSSL.c >>>>> [4] http://leves.web.elte.hu/squeak/SqueakSSL/diff.txt >>>>> [5] http://leves.web.elte.hu/squeak/SqueakSSL/SqueakSSL >>>>> [6] http://leves.web.elte.hu/squeak/SqueakSSL/SqueakSSL-Core-ul.29.mcz >>>>> [7] http://leves.web.elte.hu/squeak/SqueakSSL/WebClient-Core-ul.98.mcz >>>>> [8] http://leves.web.elte.hu/squeak/SqueakSSL/ >>>> >>>> I have things for OSX i think. >>>> Can someone confirm? >>>> >>>> >>>> Best >>>> -Tobias >>>> >>> >>> >>> I added this to http://bugs.squeak.org/view.php?id=7824 >>> >>> Dave -------------- next part -------------- A non-text attachment was scrubbed... Name: sqMacSSL.c Type: application/octet-stream Size: 16374 bytes Desc: not available Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20150415/4d0b11d7/sqMacSSL.obj -------------- next part -------------- From commits at source.squeak.org Wed Apr 15 14:54:10 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 15 14:54:12 2015 Subject: [squeak-dev] The Trunk: Tools-topa.592.mcz Message-ID: Tobias Pape uploaded a new version of Tools to project The Trunk: http://source.squeak.org/trunk/Tools-topa.592.mcz ==================== Summary ==================== Name: Tools-topa.592 Author: topa Time: 15 April 2015, 4:53:52.024 pm UUID: 047f479a-9d41-437f-91f6-3f244f266dfc Ancestors: Tools-mt.591 Add conditional menu separator to default code pane menu =============== Diff against Tools-mt.591 =============== Item was changed: ----- Method: StringHolder class>>shiftedYellowButtonMenuItems (in category '*Tools-yellow button menu') ----- shiftedYellowButtonMenuItems "Returns the standard yellow button menu items" | entries | entries := OrderedCollection withAll: { + #-. {'explain' translated. #explain}. {'pretty print' translated. #prettyPrint}. {'pretty print with color' translated. #prettyPrintWithColor}. {'file it in (G)' translated. #fileItIn}. {'spawn (o)' translated. #spawn}. #-. {'browse it (b)' translated. #browseIt}. {'senders of it (n)' translated. #sendersOfIt}. {'implementors of it (m)' translated. #implementorsOfIt}. {'references to it (N)' translated. #referencesToIt}. #-. {'selectors containing it (W)' translated. #methodNamesContainingIt}. {'method strings with it (E)' translated. #methodStringsContainingit}. {'method source with it' translated. #methodSourceContainingIt}. {'class names containing it' translated. #classNamesContainingIt}. {'class comments with it' translated. #classCommentsContainingIt}. {'change sets with it' translated. #browseChangeSetsWithSelector}. #-. {'save contents to file...' translated. #saveContentsInFile}. {'send contents to printer' translated. #sendContentsToPrinter}. {'printer setup' translated. #printerSetup}. #-. }. Smalltalk isMorphic ifFalse: [ entries add: {'special menu...' translated. #presentSpecialMenu}.]. entries add: {'more...' translated. #yellowButtonActivity}. ^ entries! Item was changed: ----- Method: StringHolder class>>yellowButtonMenuItems (in category '*Tools-yellow button menu') ----- yellowButtonMenuItems "Returns the standard yellow button menu items" ^{ + #-. {'set font... (k)' translated. #offerFontMenu}. {'set style... (K)' translated. #changeStyle}. {'set alignment... (u)' translated. #chooseAlignment}. #-. {'make project link (P)' translated. #makeProjectLink}. #-. {'find...(f)' translated. #find}. {'find again (g)' translated. #findAgain}. {'set search string (h)' translated. #setSearchString}. #-. {'do again (j)' translated. #again}. {'undo (z)' translated. #undo}. #-. {'copy (c)' translated. #copySelection}. {'cut (x)' translated. #cut}. {'paste (v)' translated. #paste}. {'paste...' translated. #pasteRecent}. #-. {'do it (d)' translated. #doIt}. {'print it (p)' translated. #printIt}. {'inspect it (i)' translated. #inspectIt}. {'explore it (I)' translated. #exploreIt}. {'debug it' translated. #debugIt}. {'button for it' translated. #buttonForIt}. {'tally it' translated. #tallyIt}. {'spy on it' translated. #spyOnIt}. #-. {'accept (s)' translated. #accept}. {'cancel (l)' translated. #cancel}. #-. {'show bytecodes' translated. #showBytecodes}. #-. {'copy html' translated. #copyHtml}. #-. {'more...' translated. #shiftedTextPaneMenuRequest}. }! From commits at source.squeak.org Wed Apr 15 15:00:26 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 15 15:00:29 2015 Subject: [squeak-dev] The Trunk: PreferenceBrowser-mt.51.mcz Message-ID: Marcel Taeumel uploaded a new version of PreferenceBrowser to project The Trunk: http://source.squeak.org/trunk/PreferenceBrowser-mt.51.mcz ==================== Summary ==================== Name: PreferenceBrowser-mt.51 Author: mt Time: 15 April 2015, 5:00:21.164 pm UUID: 9bcdaa03-bc59-854d-8a1d-4412c4ac1051 Ancestors: PreferenceBrowser-mt.50 Update to support retractableScrollBars. TableLayout seems to go crazy about it. :-) =============== Diff against PreferenceBrowser-mt.50 =============== Item was changed: ----- Method: PreferenceBrowserMorph>>initializeWithModel: (in category 'initialization') ----- initializeWithModel: aPreferenceBrowser lastKeystrokeTime := 0. lastKeystrokes := ''. self model: aPreferenceBrowser; - clipSubmorphs: true; setLabel: self model windowTitle; name: 'PreferenceBrowser'; addMorph: self rootPanel fullFrame: self rootPanelLayoutFrame; addMorph: self newButtonRow fullFrame: self buttonRowLayoutFrame.! Item was changed: ----- Method: PreferenceBrowserMorph>>mainPanel (in category 'submorphs - main panel') ----- mainPanel ^mainPanel ifNil: + [mainPanel := BorderedMorph new - [mainPanel := Morph new color: Color transparent; + borderWidth: 0; hResizing: #spaceFill; vResizing: #spaceFill; cellInset: 5; + changeProportionalLayout; - layoutPolicy: TableLayout new; - listCentering: #topLeft; - listDirection: #leftToRight; - cellPositioning: #topLeft; - clipSubmorphs: true; on: #mouseEnter send: #paneTransition: to: self; addMorphBack: self newCategoryList; addMorphBack: self preferenceList; + layoutFrame: (LayoutFrame fractions: (0@0 corner: 1@1) offsets: (0@ 30 corner: 0@0)); + addPaneSplitters; yourself].! Item was changed: ----- Method: PreferenceBrowserMorph>>newCategoryList (in category 'submorphs - category list') ----- newCategoryList ^(PluggableListMorph on: self model list: #categoryList selected: #selectedCategoryIndex changeSelected: #selectedCategoryIndex:) color: Color white; borderInset; + hResizing: #spaceFill; vResizing: #spaceFill; + layoutFrame: (LayoutFrame fractions: (0@0 corner: 0.25@1)); - hResizing: #rigid; - width: 150; yourself.! Item was changed: ----- Method: PreferenceBrowserMorph>>newSearchTextField (in category 'submorphs - search panel') ----- newSearchTextField | ptm | ptm := PluggableTextMorphPlus on: self model text: #searchPatternNeverTriggered accept: #searchPattern:. ptm balloonText: 'Search preferences ...'; hideVScrollBarIndefinitely: true; + layoutFrame: (LayoutFrame fractions: (0@0 corner: 1@0) offsets: (0@0 corner: 0@ 30)); borderInset; color: Color white; vResizing: #rigid; hResizing: #spaceFill; height: TextStyle defaultFont height * 2; acceptOnCR: true; onKeyStrokeSend: #value to: [ ptm hasUnacceptedEdits ifTrue: [ ptm accept ] ]. ^ptm.! Item was changed: ----- Method: PreferenceBrowserMorph>>preferenceList (in category 'submorphs - preference list') ----- preferenceList ^preferenceList ifNil: [preferenceList := ScrollPane new color: Color white; borderInset; vResizing: #spaceFill; + hResizing: #spaceFill; + layoutFrame: (LayoutFrame fractions: (0.25@0 corner: 1@1)). - hResizing: #spaceFill. preferenceList scroller on: #mouseEnter send: #value: to: [:event | event hand newKeyboardFocus: preferenceList scroller]; on: #keyStroke send: #keyPressed: to: self. preferenceList.]! Item was changed: ----- Method: PreferenceBrowserMorph>>rootPanel (in category 'submorphs - root panel') ----- rootPanel ^BorderedMorph new color: Color transparent; borderWidth: 0; + changeProportionalLayout; - cellInset: 10; - layoutPolicy: TableLayout new; - listDirection: #topToBottom; - listCentering: #topLeft; - cellPositioning: #topLeft; addMorphBack: self newSearchTextField; addMorphBack: self mainPanel; yourself.! From commits at source.squeak.org Wed Apr 15 15:01:36 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 15 15:01:38 2015 Subject: [squeak-dev] The Trunk: SUnitGUI-mt.60.mcz Message-ID: Marcel Taeumel uploaded a new version of SUnitGUI to project The Trunk: http://source.squeak.org/trunk/SUnitGUI-mt.60.mcz ==================== Summary ==================== Name: SUnitGUI-mt.60 Author: mt Time: 15 April 2015, 5:01:30.243 pm UUID: 5cfe5c9e-bea4-2843-802c-fd5723b32da1 Ancestors: SUnitGUI-fbs.59 Replaced input-field with regular text input to show all test results again, which needed two lines of text. =============== Diff against SUnitGUI-fbs.59 =============== Item was changed: ----- Method: TestRunner>>buildStatusWith: (in category 'building') ----- buildStatusWith: aBuilder + ^ aBuilder pluggableTextSpec new - ^ aBuilder pluggableInputFieldSpec new model: self; menu: #statusMenu:; color: #statusColor; getText: #statusText; yourself.! From commits at source.squeak.org Wed Apr 15 15:03:13 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 15 15:03:15 2015 Subject: [squeak-dev] The Trunk: ToolBuilder-Morphic-mt.131.mcz Message-ID: Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk: http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.131.mcz ==================== Summary ==================== Name: ToolBuilder-Morphic-mt.131 Author: mt Time: 15 April 2015, 5:03:08.876 pm UUID: 9edadf2c-970c-f343-ab24-cf92eb411835 Ancestors: ToolBuilder-Morphic-mt.130 Avoid clipping submorphs in panels. Should not be required in general. Why? Retractable scrollbars will else not be possible. =============== Diff against ToolBuilder-Morphic-mt.130 =============== Item was changed: ----- Method: MorphicToolBuilder>>buildPluggablePanel: (in category 'widgets required') ----- buildPluggablePanel: aSpec | widget children frame | widget := self panelClass new. self register: widget id: aSpec name. widget model: aSpec model. widget color: Color transparent. - widget clipSubmorphs: true. children := aSpec children. children isSymbol ifTrue:[ widget getChildrenSelector: children. widget update: children. children := #(). ]. self buildAll: children in: widget. self buildHelpFor: widget spec: aSpec. self setFrame: aSpec frame in: widget. parent ifNotNil:[self add: widget to: parent]. self setLayout: aSpec layout in: widget. widget layoutInset: 0. widget borderWidth: 0. widget submorphsDo:[:sm| (frame := sm layoutFrame) ifNotNil:[ (frame rightFraction = 0 or:[frame rightFraction = 1]) ifFalse:[frame rightOffset:1]. (frame bottomFraction = 0 or:[frame bottomFraction = 1]) ifFalse:[frame bottomOffset: 1]]]. widget color: Color transparent. ^widget! From commits at source.squeak.org Wed Apr 15 15:08:45 2015 From: commits at source.squeak.org (commits@source.squeak.org) Date: Wed Apr 15 15:08:48 2015 Subject: [squeak-dev] The Trunk: Morphic-mt.874.mcz Message-ID: Marcel Taeumel uploaded a new version of Morphic to project The Trunk: http://source.squeak.org/trunk/Morphic-mt.874.mcz ==================== Summary ==================== Name: Morphic-mt.874 Author: mt Time: 15 April 2015, 5:08:05.427 pm UUID: bc13e9b8-2884-0449-bf15-a26307959176 Ancestors: Morphic-mt.873 Fixes in scroll bar and scroll pane. Retractable scroll bars (known from MVC) work again and can be enabled via preferences. =============== Diff against Morphic-mt.873 =============== Item was changed: ----- Method: PluggableListMorph>>extent: (in category 'geometry') ----- extent: newExtent super extent: newExtent. "Change listMorph's bounds to the new width. It is either the size of the widest list item, or the size of self, whatever is bigger" + self listMorph width: (self width max: listMorph hUnadjustedScrollRange). - self listMorph width: ((self width max: listMorph hUnadjustedScrollRange) + 20). ! Item was changed: ----- Method: PluggableTextMorph>>extent: (in category 'geometry') ----- + extent: aPoint - extent: newExtent + super extent: aPoint. + + "Update vertical scroll bars because if text is wrapped." + textMorph ifNotNil: [:tm | + tm isAutoFit ifTrue: [self vSetScrollDelta]].! - bounds extent = newExtent ifTrue: [^ self]. - super extent: (newExtent max: 36@16). - self setScrollDeltas - ! Item was added: + ----- Method: PluggableTextMorph>>hasFocus (in category 'accessing') ----- + hasFocus + + ^ super hasFocus or: [textMorph notNil and: [textMorph hasKeyboardFocus]]! Item was removed: - ----- Method: PluggableTextMorph>>resetExtent (in category 'geometry') ----- - resetExtent - "Reset the extent while maintaining the current selection. Needed when resizing while the editor is active (when inside the pane)." - | tempSelection | - textMorph notNil ifTrue: - ["the current selection gets munged by resetting the extent, so store it" - tempSelection := self selectionInterval. - - "don't reset it if it's not active" - tempSelection = (Interval from: 1 to: 0) - ifTrue: [retractableScrollBar - ifTrue:[ ^ self]]. - self extent: self extent. - self setSelection: tempSelection]. - super resetExtent.! Item was changed: ----- Method: ScrollBar>>minExtent (in category 'geometry') ----- minExtent "The minimum extent is that of 2 or 3 buttons in a row or column, the 'up' and 'down' button and optionally the 'menu' button." | btns cnt | + btns := { + upButton visible. + downButton visible. + self menuButton visible. } count: [:ea | ea]. + cnt := 0 @ btns. "assume vertical layout" - btns := 2. - self menuButton visible ifTrue: [ - btns := btns + 1]. - cnt := 1@btns. "assume vertical layout" self bounds isWide ifTrue: [cnt := cnt transposed]. + ^ (upButton minExtent * cnt) + (self sliderThickness @ self sliderThickness)! - ^ upButton minExtent * cnt! Item was changed: ----- Method: ScrollBar>>sliderColor: (in category 'access') ----- sliderColor: aColor "Change the color of the scrollbar to go with aColor." | buttonColor | super sliderColor: aColor. self updateSliderColor: aColor. buttonColor := self thumbColor. - self menuButton color: buttonColor. - upButton color: buttonColor. - downButton color: buttonColor. + self menuButton color: aColor. + upButton color: aColor. + downButton color: aColor. - self class updateScrollBarButtonsAspect: {self menuButton. upButton. downButton} color: buttonColor. + self class updateScrollBarButtonsAspect: {self menuButton. upButton. downButton} color: aColor. + self updateMenuButtonImage. self updateUpButtonImage. self updateDownButtonImage.! Item was changed: MorphicModel subclass: #ScrollPane instanceVariableNames: 'scrollBar scroller retractableScrollBar scrollBarOnLeft getMenuSelector getMenuTitleSelector scrollBarHidden hasFocus hScrollBar lockOffset' + classVariableNames: 'UseRetractableScrollBars' - classVariableNames: '' poolDictionaries: '' category: 'Morphic-Windows'! !ScrollPane commentStamp: 'mk 8/9/2005 10:34' prior: 0! The scroller (a transform) of a scrollPane is driven by the scrollBar. The scroll values vary from 0.0, meaning zero offset to 1.0 meaning sufficient offset such that the bottom of the scrollable material appears 3/4 of the way down the pane. The total distance to achieve this range is called the totalScrollRange. Basic clue about utilization of the ScrollPane class is given in: ScrollPane example1. ScrollPane example2.! Item was added: + ----- Method: ScrollPane class>>useRetractableScrollBars (in category 'preferences') ----- + useRetractableScrollBars + +