[squeak-dev] How can the main window title in Squeak and Pharo be set?

Ron Teitelbaum ron at usmedrec.com
Fri Jan 11 04:41:13 UTC 2013


Hi All,

We change the window title on Windows and Mac so I looked it up.

We use:

Smalltalk windowLabel: 'Terf'

Doesn't seem to be in Squeak 4.3  but the included HostWindowPlugin appears
to support it.

I added Andreas' code to Squeak 4.3 and it worked on Windows.  It probably
works on Mac, doubt it works on Linux.

SmalltalkImage >> windowLabel: aString
	"Set the window label for the main Squeak window"
	^self primitiveWindowLabel: (aString ifNil:[''] ifNotNil:[aString
squeakToUtf8])

SmalltalkImage >> primitiveWindowLabel: aString
	"Set the window label for the main Squeak window"
	<primitive: 'primitiveSetWindowLabel'>
	^nil

Hope that helps.

All the best,

Ron Teitelbaum
Head Of Engineering
3d Immersive Collaboration Consulting
ron at 3dicc.com
Follow Me On Twitter: @RonTeitelbaum
www.3dicc.com 




> -----Original Message-----
> From: squeak-dev-bounces at lists.squeakfoundation.org [mailto:squeak-dev-
> bounces at lists.squeakfoundation.org] On Behalf Of Bert Freudenberg
> Sent: Thursday, January 10, 2013 10:16 PM
> To: The general-purpose Squeak developers list
> Subject: Re: [squeak-dev] How can the main window title in Squeak and
Pharo
> be set?
> 
> 
> On 10.01.2013, at 18:18, tim Rowledge <tim at rowledge.org> wrote:
> 
> >
> > On 10-01-2013, at 6:07 PM, "Ron Teitelbaum" <ron at usmedrec.com> wrote:
> >
> >> Hi Frank,
> >>
> >> This might be really dumb but I set the window title in the ini file.
> >
> > That's a way of doing it permanently; there's a similar option in the
RISC OS
> !run file.
> 
> There is no such option on the Mac or in the Unix VM.
> 
> > The HostWindow stuff depends on there being an actual HostWindowPlugin
> installed that functions. I know it's there for RISC OS. I know it's
likely there for
> Mac. I think it's there for Windows; I'm fairly sure it isn't for unix.
> 
> 
> For Unix (X11 specifically) there is just enough HostWindowPlugin stuff
> implemented to be able to change the title and size of the main window.
The
> multi-window stuff is there as stubs.
> 
> - Bert -
> 
> 
> 




More information about the Squeak-dev mailing list