For a project I am involved in I am looking at alternatives for running
applications in the web browser to avoid having to install stuff on a
user's machine. So I took a look at http://try.squeak.org/ and think it
is a fabulous resouce for our community. Unfortunately, I would not
point out this page to people I want to get interested in Squeak. The
reason for that is that they are likely to get frustrated by the
differences in the Squeak 2.2 GUI in relation to "normal" OSes.
The solution to this problem could be as simple as adding a paragraph
between "Above you see..." and "Other Squeak image" explaining how to do
stuff in Squeak 2.2 when you have one, two or three buttons on your
mouse. It is important to explain how to get a world menu and how to "do
it" and "print it". A child might play around until they find out these
things on their own but most adults will give up after just a few
seconds of things not working as they are used to.
An alternative would be a video explaining the same thing and embeded
right below the live SqueakJS.
I would not put a link to a nice tutorial in another page because we
want people to stay on the "try" page.
-- Jecel
A new version of Collections was added to project The Inbox:
http://source.squeak.org/inbox/Collections-tonyg.733.1.mcz
==================== Summary ====================
Name: Collections-tonyg.733.1
Author: tonyg
Time: 23 February 2017, 2:44:28.751184 pm
UUID: e754e6ad-dd14-4e97-8ec1-82422b8feaa5
Ancestors: Collections-topa.733
Allow zero and negative startingAt indices in SequenceableCollection>>#indexOfSubCollection:startingAt:ifAbsent:, for compatibility with the existing implementation in String. Fixes tests in CollectionsTests-tonyg.275 and NetworkTests-tonyg.44.
=============== Diff against Collections-topa.733 ===============
Item was changed:
----- Method: SequenceableCollection>>indexOfSubCollection:startingAt:ifAbsent: (in category 'accessing') -----
indexOfSubCollection: sub startingAt: start ifAbsent: exceptionBlock
"Answer the index of the receiver's first element, such that that element
equals the first element of sub, and the next elements equal
the rest of the elements of sub. Begin the search at element
start of the receiver. If no such match is found, answer the result of
evaluating argument, exceptionBlock."
| first index |
sub isEmpty ifTrue: [^ exceptionBlock value].
first := sub first.
+ (start max: 1) to: self size - sub size + 1 do:
- start to: self size - sub size + 1 do:
[:startIndex |
(self at: startIndex) = first ifTrue:
[index := 1.
[(self at: startIndex+index-1) = (sub at: index)]
whileTrue:
[index = sub size ifTrue: [^startIndex].
index := index+1]]].
^ exceptionBlock value!
Hi all,
Are Mantis password reset emails getting through for other people?
I just tried to send one to myself, and it seems not to have made it
through.
Tony
A new version of Multilingual was added to project The Inbox:
http://source.squeak.org/inbox/Multilingual-tonyg.218.mcz
==================== Summary ====================
Name: Multilingual-tonyg.218
Author: tonyg
Time: 23 February 2017, 2:13:59.45456 pm
UUID: 86e12680-7d6d-400c-8215-62a8315f01f1
Ancestors: Multilingual-tfel.217
Override PositionableStream>>#upToPosition:, introduced in Collections-tonyg.734, in order to reflect the fact that positions count bytes here; previously, #next: was being used, but that method expects a count of characters, not bytes. This is the second half of a fix for Mantis #4665. See also MultilingualTests-tonyg.22.
=============== Diff against Multilingual-tfel.217 ===============
Item was added:
+ ----- Method: MultiByteFileStream>>upToPosition: (in category 'accessing') -----
+ upToPosition: anInteger
+ "Answer a subcollection containing items starting from the current position and ending including the given position. Usefully different to #next: in that positions measure *bytes* from the file, where #next: wants to measure *characters*."
+ ^self collectionSpecies new: 1000 streamContents: [ :stream |
+ | ch |
+ [ (ch := self next) == nil or: [ position > anInteger ] ]
+ whileFalse: [ stream nextPut: ch ] ]!
A new version of Collections was added to project The Inbox:
http://source.squeak.org/inbox/Collections-tonyg.734.mcz
==================== Summary ====================
Name: Collections-tonyg.734
Author: tonyg
Time: 23 February 2017, 2:08:07.162997 pm
UUID: 9edf6f29-ea5e-4c3b-9d05-03c54d4ba86c
Ancestors: Collections-topa.733
Factor out #upToPosition:, which lets us address the discrepancy between position counting bytes in MultiByteFileStream, but #next: expecting a count of items in #upToAll:. This is the first half of a fix for Mantis #4665. See also MultilingualTests-tonyg.22.
=============== Diff against Collections-topa.733 ===============
Item was changed:
----- Method: PositionableStream>>upToAll: (in category 'accessing') -----
upToAll: aCollection
"Answer a subcollection from the current access position to the occurrence (if any, but not inclusive) of aCollection. If aCollection is not in the stream, answer the entire rest of the stream."
| startPos endMatch result |
startPos := self position.
(self match: aCollection)
ifTrue: [endMatch := self position.
self position: startPos.
+ result := self upToPosition: endMatch - aCollection size.
- result := self next: endMatch - startPos - aCollection size.
self position: endMatch.
^ result]
ifFalse: [self position: startPos.
^ self upToEnd]!
Item was added:
+ ----- Method: PositionableStream>>upToPosition: (in category 'accessing') -----
+ upToPosition: anInteger
+ "Answer a subcollection containing items starting from the current position and ending including the given position. Usefully different to #next: in that in the case of MultiByteFileStream, and perhaps others, positions measure in terms of encoded items, while #next: convention is to name a number of items, independent of their encoding in the underlying buffer."
+ ^ self next: anInteger - position
+ !
Hi All,
How can I tell what operating system I'm running on from within my Squeak program?
Maybe some OSProcess call?
Lou
--
Louis LaBrunda
Keystone Software Corp.
SkypeMe callto://PhotonDemon
On 2/20/17, Tobias Pape <Das.Linux(a)gmx.de> wrote:
>
> On 20.02.2017, at 23:00, Bert Freudenberg <bert(a)freudenbergs.de> wrote:
>
>> How about some automatic server-side cleanup? If a package gets saved or
>> merged into trunk, move it to treated-inbox.
>>
>> Then all you have to do in image is to copy/merge the version from inbox
>> to trunk.
>>
>
> Na, lets leave it that way for now :)
> Its a-ok
How are treated fixes moved from inbox to treated currently?
For example this one
'The Inbox: Morphic-mdlh.1297.mcz'
has been treated but is still in the inbox
http://source.squeak.org/inbox/
instead of
http://source.squeak.org/treated/
This applies to quite a number of more fixes in the inbox.
--Hannes
>> - Bert -
>>
>> On Mon, Feb 20, 2017 at 10:54 PM, Tobias Pape <Das.Linux(a)gmx.de> wrote:
>>
>> On 20.02.2017, at 22:44, Levente Uzonyi <leves(a)caesar.elte.hu> wrote:
>>
>> > Inbox submissions are still rare enough to not justify creating an API
>> > for squeaksource. :)
>>
>> But I Must Not leave my Squeak image :D
>>
>> >
>> > Levente
>> >
>> > On Sat, 18 Feb 2017, Tobias Pape wrote:
>> >
>> >> So, I think we need a way to move from inbox to trunk/treated from the
>> >> image.
>> >> Website-only is cumbersome…
>> >>
>> >> Best regards
>> >> -Tobias
>> >> On 18.02.2017, at 08:44, commits(a)source.squeak.org wrote:
>> >>
>> >>> Tobias Pape uploaded a new version of KernelTests to project The
>> >>> Trunk:
>> >>> http://source.squeak.org/trunk/KernelTests-tonyg.318.mcz
>> >>> ==================== Summary ====================
>> >>> Name: KernelTests-tonyg.318
>> >>> Author: tonyg
>> >>> Time: 17 February 2017, 2:10:54.13995 pm
>> >>> UUID: 550fed38-fe11-4cea-bccb-2e3c13b421d0
>> >>> Ancestors: KernelTests-nice.317
>> >>> Add tests for Promise>>wait (including proposed change from
>> >>> Kernel-tonyg.1059)
>> >>> =============== Diff against KernelTests-nice.317 ===============
>> >>> Item was added:
>> >>> + ----- Method: PromiseTest>>testWaitForRejection (in category
>> >>> 'testing - monad') -----
>> >>> + testWaitForRejection
>> >>> + | p |
>> >>> + p := Promise new.
>> >>> + [ (Delay forMilliseconds: 1) wait. p rejectWith: Error new ] fork.
>> >>> + self should: [ p wait ] raise: BrokenPromise.!
>> >>> Item was added:
>> >>> + ----- Method: PromiseTest>>testWaitForResolution (in category
>> >>> 'testing - monad') -----
>> >>> + testWaitForResolution
>> >>> + | p |
>> >>> + p := Promise new.
>> >>> + [ (Delay forMilliseconds: 1) wait. p resolveWith: #ok ] fork.
>> >>> + self assert: [ p wait = #ok ]!
>> >>> Item was added:
>> >>> + ----- Method:
>> >>> PromiseTest>>testWaitRejectionYieldsCorrectBrokenPromise (in category
>> >>> 'testing - monad') -----
>> >>> + testWaitRejectionYieldsCorrectBrokenPromise
>> >>> + | p |
>> >>> + p := Promise new.
>> >>> + [ (Delay forMilliseconds: 1) wait. p rejectWith: Error new ] fork.
>> >>> + [ p wait ] on: BrokenPromise do: [ :bp | ^ self assert: [ bp
>> >>> promise == p ] ].
>> >>> + self fail: 'Should not reach this point'!
>> >
>>
>>
>>
>>
>
>
>
Hi all
here's a nasty side effect of our way of ensuring that the heartbeat-thread thing works.
https://github.com/dalehenrich/metacello-work/issues/427#issuecomment-28191…
TL;DR:
(1) Run squeak w/ superuser/root rights creates the 'package-cache' directory as root
(2) Installing something with monticello then _SILENTLY_ fails
Both is bad.
So, (1) is hard to fix. I would have said, hey, if we are root, just _don't_ run squeak but just create the heartbeat files.
But that makes no sense when we actually want to run squeak as root.
SUGGESTION:
- Do not ship heartbeat vm in the all in one[1]
- Ship the heartbeat vm only in system packages[2]
- Fix handling File-open failures.
I'm onto (2), and frankly, I was surprised to learn that:
squeak-dir$ mkdir foo
squeak-dir$ chmod -w foo
and then
(FileDirectory default / 'foo') newFileNamed: 'bar'. "==> nil"
this Must Not happen.
To many to-dos in one mail, I know :(
Best regards
-Tobias
[1]: Yes, I know, performance is bad then, but the user experience is badder [sic]. That is a hard-to-cope-with tradeoff.
[2]: Wich means, that we eventually, finally, have to package debs and rpms, I'd say.
Merlin de la Haye uploaded a new version of Morphic to project The Inbox:
http://source.squeak.org/inbox/Morphic-mdlh.1297.mcz
==================== Summary ====================
Name: Morphic-mdlh.1297
Author: mdlh
Time: 29 December 2016, 11:46:25.676308 am
UUID: b2c44cf8-e058-dd49-a748-161548b2da23
Ancestors: Morphic-mt.1296
corrected typo in description text (amout -> amount)
=============== Diff against Morphic-mt.1296 ===============
Item was changed:
----- Method: PluggableTextMorph class>>visualWrapBorder (in category 'preferences') -----
visualWrapBorder
<preference: 'Show wrap border in code panes.'
categoryList: #(editing visuals performance)
+ description: 'Show a visual border after a specific amount of characters. Makes sense for monospaced fonts.'
- description: 'Show a visual border after a specific amout of characters. Makes sense for monospaced fonts.'
type: #Boolean>
^ VisualWrapBorder ifNil: [false]!
Item was changed:
----- Method: ScrollBar>>scrollPageInit: (in category 'scrolling') -----
scrollPageInit: evt
evt redButtonPressed ifFalse: [^ self].
self resetTimer.
self setNextDirectionFromEvent: evt.
self scrollBarAction: #doScrollByPage.
self startStepping.!
Item was changed:
----- Method: TheWorldMainDockingBar>>listWindowsOn: (in category 'submenu - windows') -----
listWindowsOn: menu
| windows |
windows := self allVisibleWindows sorted: [:winA :winB |
((winA model isNil or: [winB model isNil]) or: [winA model name = winB model name])
ifTrue: [winA label < winB label]
ifFalse: [winA model name < winB model name]].
windows ifEmpty: [
menu addItem: [ :item |
item
contents: 'No Windows' translated;
isEnabled: false ] ].
windows do: [ :each |
menu addItem: [ :item |
item
contents: (self windowMenuItemLabelFor: each);
+ icon: ((each model respondsTo: #windowColorToUse)
+ ifTrue: [self colorIcon: each model windowColorToUse]
+ ifFalse: [self colorIcon: each color]);
- icon: (each model ifNotNil: [self colorIcon: each model windowColorToUse]);
target: each;
selector: #comeToFront;
subMenuUpdater: self
selector: #windowMenuFor:on:
arguments: { each };
action: [ each beKeyWindow; expand ] ] ].
menu
addLine;
add: 'Close all windows' target: self selector: #closeAllWindowsUnsafe;
addItem: [:item | item
contents: 'Close all windows without changes';
target: self;
icon: MenuIcons smallBroomIcon;
selector: #closeAllWindows];
add: 'Close all windows but workspaces' target: self selector: #closeAllWindowsButWorkspaces.!