Since I've been reminded that the RB's context menu is, well, context
sensitive, I've been clicking around some more. Also, I've upgraded my CSS-foo, which allows me to get rid of the first parameter of the following method: renderArrowAt: aDistance on: html (html div) class: 'blueimage'; with: [(html image) style: 'padding-top: ', aDistance , ';'; url: SupportFiles / #logoPng] I double-click on 'aDistance' in the first line, and choose Refactor > Remove parameter from the context menu. I'm reminded that "at least one implementor is still using this parameter". Ok, remove the style-assignment and repeat the invocation. The parameter is removed, but the resulting message is called just "on:". Given my experience with Dolphin's RB implementation, I'd have expected something like "renderArrowAtOn:" or maybe even be asked for the resulting name, but truncating it to "on:" is ... not nice. There are probably many cases where just "joining" the available parts of the message name won't result in a "good" name, but if I have to change it anyways, I'd rather change the handful of "my" references to "renderArrowAtOn:" instead of wading through the many system references to "on:". To change this, the method RemoveParameterRefactoring>>computNewSelector needs to be modified: computeNewSelector | keywords stream | oldSelector numArgs == 0 ifTrue: [self refactoringError: #MethodHasNoArgs << #browser >> 'This method contains no arguments']. oldSelector isInfix ifTrue: [self refactoringError: #CannotRemoveParamsOfInfix << #browser >> 'Cannot remove parameters of infix selectors']. keywords := oldSelector keywords asOrderedCollection. keywords size = 1 ifTrue: [^ (keywords first copyWithout: $:) asSymbol]. + parameterIndex < keywords size + ifTrue: + [| first second | + first := (keywords at: parameterIndex) copyWithout: $:. + second := (keywords at: parameterIndex + 1) copy. + second at: 1 put: second first asUppercase. + keywords at: parameterIndex + 1 put: first , second]. keywords removeAtIndex: parameterIndex. stream := WriteStream on: String new. keywords do: [:each | stream nextPutAll: each]. ^ stream contents asSymbol Is there a chance of this patch going into base, or should I keep it in my personal patch package? Thanks, s. _______________________________________________ vwnc mailing list [hidden email] http://lists.cs.uiuc.edu/mailman/listinfo/vwnc |
On Jun 13, 2008, at 1:51 PM, Stefan Schmiedl wrote:
AR 54581 was created. I'll try to get it in ASAP. Thank you for the suggested fix. And yes, this has bugged me before too. <snip> > Is there a chance of this patch going into base, or should I keep > it in my personal patch package? Your call on this one. I'll try to get it in next weeks build possibly. But that doesn't do much for you if you're on 7.6. So possibly a little of both is the best way to proceed. -- Travis Griggs Objologist "I think that we should be men first, and subjects afterward." - Henry David Thoreau _______________________________________________ vwnc mailing list [hidden email] http://lists.cs.uiuc.edu/mailman/listinfo/vwnc |
On Fri, 13 Jun 2008 14:46:22 -0700
Travis Griggs <[hidden email]> wrote: > On Jun 13, 2008, at 1:51 PM, Stefan Schmiedl wrote: > > AR 54581 was created. I'll try to get it in ASAP. Thank you for the > suggested fix. And yes, this has bugged me before too. > > <snip> > > Is there a chance of this patch going into base, or should I keep > > it in my personal patch package? > > Your call on this one. I'll try to get it in next weeks build > possibly. But that doesn't do much for you if you're on 7.6. So > possibly a little of both is the best way to proceed. who's running 7.6? Now that I've automated preparing my set of development images, I'm mostly running this or last week, depending on whether I can relate to the topics of the ARs. Keeps you on your toes, and is good practice for perfecting deployment. The only things my pre-loader lacks are: How can I close the installation workspace window programmatically? How can I avoid the annoying "are you sure" dialog while closing the ADvance Workbench programmatically? s. _______________________________________________ vwnc mailing list [hidden email] http://lists.cs.uiuc.edu/mailman/listinfo/vwnc |
Stefan Schmiedl wrote:
> The only things my pre-loader lacks are: > How can I close the installation workspace window programmatically? Workbook allInstances first closeAndUnschedule. HTH, Martin _______________________________________________ vwnc mailing list [hidden email] http://lists.cs.uiuc.edu/mailman/listinfo/vwnc |
In reply to this post by Travis Griggs-3
For closing the Advance window I use: WindowManager managerRegistry do: [:aWindowManager | aWindowManager scheduledWindows do: [:aWindow | aWindow label = 'ADvance Workbench' ifTrue: [ aWindow close. ^aWindow unscheduleWindow]]] Cheers, Christian > -----Ursprüngliche Nachricht----- > Von: [hidden email] > [mailto:[hidden email]] Im Auftrag von Stefan Schmiedl > Gesendet: Samstag, 14. Juni 2008 01:15 > An: Travis Griggs > Cc: vwnc List > Betreff: Re: [vwnc] [RB] Remove parameter causes unfortunate renaming > > On Fri, 13 Jun 2008 14:46:22 -0700 > Travis Griggs <[hidden email]> wrote: > > > On Jun 13, 2008, at 1:51 PM, Stefan Schmiedl wrote: > > > > AR 54581 was created. I'll try to get it in ASAP. Thank you > for the > > suggested fix. And yes, this has bugged me before too. > > > > <snip> > > > Is there a chance of this patch going into base, or should I keep > > > it in my personal patch package? > > > > Your call on this one. I'll try to get it in next weeks build > > possibly. But that doesn't do much for you if you're on 7.6. So > > possibly a little of both is the best way to proceed. > > who's running 7.6? Now that I've automated preparing my set of > development images, I'm mostly running this or last week, depending > on whether I can relate to the topics of the ARs. Keeps you on your > toes, and is good practice for perfecting deployment. > > The only things my pre-loader lacks are: > How can I close the installation workspace window programmatically? > How can I avoid the annoying "are you sure" dialog while closing the > ADvance Workbench programmatically? > > s. > _______________________________________________ > vwnc mailing list > [hidden email] > http://lists.cs.uiuc.edu/mailman/listinfo/vwnc > > > > > No virus found in this incoming message. > Checked by AVG. > Version: 8.0.100 / Virus Database: 270.3.0/1501 - Release > Date: 13.06.2008 06:33 > Checked by AVG. Version: 8.0.100 / Virus Database: 270.3.0/1501 - Release Date: 13.06.2008 06:33 _______________________________________________ vwnc mailing list [hidden email] http://lists.cs.uiuc.edu/mailman/listinfo/vwnc |
In reply to this post by Stefan Schmiedl
Hi Travis,
since you're interested in "what would others think", I guess the message was intended for the list. On Fri, 13 Jun 2008 23:18:03 -0700 Travis Griggs <[hidden email]> wrote: > > There are probably many cases where just "joining" the available > > parts of the message name won't result in a "good" name, but if I have > > to change it anyways, I'd rather change the handful of "my" references > > to "renderArrowAtOn:" instead of wading through the many system > > references to "on:". > > There are a couple of different algorithms that could be employed. > It's quite likely that I might not like the end result. It seems > better to go bit farther. And basically ascertain that the selector is > unique (i.e. an as yet not interned symbol). > > For example, if you have: > > foo, > foo: > foo:bar: > bar: > bar > > you can remove parameter on any of the middle 3. At all. It'll just > tell you that the result is already taken. The other case, is that you > end up with something that is megamorphic (i.e. on:, from:, with:, > etc). And impossible to work with afterwards. > > So what would others think of doing our best to do a sensible joining, > but ultimately doing things to ascertain the selectors uniqueness (for > example, throwing an _ or two in there if need be). Yes... we could > pop up a dialog, but I'd rather not burden the common case with the > rare occurrence. If the tool can just do it with no intervention 90% > of the time, it should. You can always remove and then remove. How much work would it be to pop up a dialog if and only if the computed name was already taken? The simple "join the parts" strategy would work silently in your 90%, while the remaining 10% could prompt the user like so: The message #foo: cannot be renamed to #foo, since it already exists. Please provide another name or cancel the refactoring: "__RB__foo" Ok Cancel Use a really ugly prefix here so that I can still find the bugger easily after I hit Ok by reflex ;-> s. _______________________________________________ vwnc mailing list [hidden email] http://lists.cs.uiuc.edu/mailman/listinfo/vwnc |
In reply to this post by Christian Haider
Thanks to Christian and Martin for completing the missing parts.
In case somebody's interested, here is my (almost) handsfree installation procedure. To everybody else, apologies for this lengthy piece of ugliness. 0. Download ISO image 1. Adapt paths in prepared options.txt 2. Automated Install $isovw/bin/linux86/visual $isovw/image/install.im -nogui -options options.txt where $isovw points to the location of the mounted ISO image. 3. Create "virgin" image with ./visual.im -filein bin/ImageBuilder-virgin.st where the filein contains just ==== ImageBuilder-virgin.st Snapshot new saveAs: 'virgin' thenQuit: false. TimeZone setDefaultTimeZone: (TimeZone timeDifference: 1 DST: 1 start: 2 end: 3 from: 90 "on March 31" to: 304 "until October 31" startDay: #Sunday). UI.UISettings preferenceFor: #defaultLookSelector put: #{UI.WinXPLookPolicy}; preferenceFor: #feelSelection put: #{UI.Win95FeelPolicy}; updateAllPreferences. Workbook allInstances first closeAndUnschedule. Snapshot new saveAs: 'virgin' thenQuit: true. ==== ImageBuilder-virgin.st 4. Create "loaded" image with my working environment but without projects: ./virgin.im -filein bin/ImageBuilder-loaded.st ==== ImageBuilder-loaded.st ! "load parcels, don't start seaside server now" Smalltalk at: #DoNotStartSeasideServer put: true. Parcel loadParcelByName: 'StoreForPostgreSQL'; loadParcelByName: 'Seaside'. "load some more..." Parcel unloadParcelNamed: 'A0_Prerequisites'. ! "get repositories, connect to local store" Store.RepositoryManager importRepositoriesFromStream: ('repositories.xml' asFilename withEncoding: #UTF_8) readStream. Store.DbRegistry connectTo: (Store.RepositoryManager repositories detect: [:each | each name = 'stefan@g64']). ! "get pundles from local store" (Store.Bundle withName: 'Mocketry' version: '1.0') first loadSrc. (Store.Package withName: 'ODBCUnixSupport' version: '2') first loadSrc. "... and many more" ! "fine tuning" Smalltalk removeKey: #DoNotStartSeasideServer ifAbsent: []. Seaside.SeasideServer autoOpenWebBrowser: false; serverAddress: '127.0.0.1'; portNumber: 8008; start. Refactory.Browser.BrowserApplicationModel promptOnRefactoring: true. Refactory.Browser.ListNavigatorPart showHorizontalScrollbar: true. Refactory.Browser.BrowserCodeTool saveAutoFormat: false; browseAutoFormat: false. Refactory.Browser.RBConfigurableFormatter.NewLineBeforeFirstCascade := true. Refactory.Browser.RBConfigurableFormatter.NewLineBeforeFirstKeyword := true. Refactory.Browser.RBConfigurableFormatter.NumberOfArgumentsForMultiLine := 3. Refactory.Browser.RBConfigurableFormatter.FormatCommentWithStatements := true. Refactory.Browser.RBConfigurableFormatter.StringFollowingReturn := ' '. ThreePaneSelectorsBrowser.WindowMode := #newTab. ! "clean up" Workbook allInstances first closeAndUnschedule. WindowManager managerRegistryDo: [:aWindowManager | aWindowManager scheduledWindows do: [:aWindow | aWindow label = 'ADvance Workbench' ifTrue: [ aWindow controller closeAndUnschedule]]]. ! Transcript clear. Snapshot new saveAs: 'loaded' thenQuit: true. ==== ImageBuilder-loaded.st 5. use loaded.im to produce "project images" in the same way. Takes less than five minutes and runs all by itself. The one hair left in the soup is the "focus grabbing" by the running image that occurs way too often on my linux box to be able to work during this time. But hey, being forced out of the chair once a week is not bad, either :-) s. _______________________________________________ vwnc mailing list [hidden email] http://lists.cs.uiuc.edu/mailman/listinfo/vwnc |
Stefan Schmiedl escreveu:
[snipped] > TimeZone setDefaultTimeZone: > (TimeZone timeDifference: 1 > DST: 1 start: 2 end: 3 > from: 90 "on March 31" > to: 304 "until October 31" > startDay: #Sunday). I think this is a thing we could have in the install image as an option during the start of the process. Perhaps automated by the OSTimeZone? -- Cesar Rabak GNU/Linux User 52247. Get counted: http://counter.li.org/ _______________________________________________ vwnc mailing list [hidden email] http://lists.cs.uiuc.edu/mailman/listinfo/vwnc |
In reply to this post by Stefan Schmiedl
We have a whole list of windows we close automatically when creating develoment images such as gfst, welcome workspace etc. _______________________________________________ vwnc mailing list [hidden email] http://lists.cs.uiuc.edu/mailman/listinfo/vwnc |
Free forum by Nabble | Edit this page |