[Vm-dev] Re: [squeak-dev] Switch full screen ON to OFF

David T. Lewis lewis at mail.msen.com
Thu Mar 20 03:27:50 UTC 2014


Hi Gustavo,

The problem with full screen on/off looks like it may be caused by
the X11 window manager in Ubuntu, and I do not know how long it may
take to resolve this in the Squeak VM or in Ubuntu. I see from your
explanation here that the problem may be affecting children in the
Plan Ceibal project already, so it would be good to find a solution
soon.

I think that I have found a workaround for the problem that may help.
I am attaching a change set that you can file in to a Squeak image,
either the Squeak 3.9 image that you mentioned, or any other recent
Squeak 4.5 image. This change uses one of the plugins in the squeak-vm
package on Ubuntu, and it will force a reconnection to the X11 display
after the Squeak window returns from full screen mode.

Can you please try loading this change set into Squeak, and testing
it on an MG3 laptop with Ubuntu 12.04?

I have not tested this yet with Scratch, but if it works on Squeak
with Ubuntu 12.04, then it will probably work with Scratch also.

This is not a real solution to the problem, but if it works on the
laptops for Plan Ciebal then maybe it will help until we are able to
fix the real problem.

Thanks,

Dave


On Mon, Mar 17, 2014 at 06:11:44PM -0300, Gustavo Duarte wrote:
> Hi,
> 
> Overview
> ========
> 
> I would like make a brief overview of the situation.
> 
> In my case, this problem is happening on laptos Magalahes model MG3, 
> these kind of the machines are manufactured by a Portuguese company, 
> http://www.jp-ik.com/, focuses on provide laptop for children.
> 
> Here in Uruguay there is a country wide Educational Project, called 
> "Plan Ceibal"[1] [2]. Thousand of these machines were distributed to 
> children on the schools around all the country.
> 
> Until last year 2013, this machines comes with Ubnutu 10.04 installed 
> and Squeak was working like a charm.
> 
> Currently a migration to Ubuntu 12.04 is on deployment stage, and some 
> of the remaining issues is this (Squeak).
> 
> More info about the HW of this Machine [3]
> 
> 
> Research results so far:
> ==========================
> 
> I tried get more information, calling fullScreenON and Off from 
> Worksapce unsessfully, same behavior happened, but no additional data 
> were printed out.
> 
> 
> Now, I will take the another approach, related with a comment did by Tim 
> Rowledge on the old thread.
> 
> <<
> "I?d say that strongly suggests a problem in the code setting the screen 
> mode; you?ll find it (for unix) in platforms/unix/vm-display-
> X11/sqUnixX11.c at the function  display_ioSetFullScreen(sqInt 
> fullScreen). Since it works on many unices and has for a long time I 
> imagine it means some problem with the specific machine?s display driver 
> code. That could be all sorts of fun to solve. At the very least you?ll 
> need to find an X expert, which is not me."
> >>
> 
> 
> Taking in account, i have never developed on Squeak, my plan would be like:
> 
> 1) Add debugging cide like "printf" to sqUnix11.c to may debug, and 
> check if there where the problem
> 
> 2) Compile Squeak - VM from sourece code, modified.
> 
> 3) Run Squeak vm with clean Squeak image.
> 
> 4) See the output of debugging code.
> 
> 5) With these new clues, i'll ask help to a X expert.
> 
> What do you think, that sounds reasonable ?
> 
> Is another easier approach ?
> 
> Thanks in advance.
> 
> 
> Gustavo.
> 
> 
> [1] http://www.ceibal.edu.uy
> [2] http://en.wikipedia.org/wiki/Ceibal_project
> [3] 
> http://www.ceibal.edu.uy/art%C3%ADculo/noticias/consultas/hardwaremagallanes3
> 
> 
> On 03/17/2014 01:58 PM, gettimothy wrote:
> >No Eeks!, flurps, oopsies, fscks or oy's here.
> >
> >Full screen works just dandy with dual monitors.
> >Platform is a workstation, NVidia GEForce, Slackware Linux.
> >
> >Image
> >-----
> >
> >Squeak4.5
> >latest update: #13680
> >Current Change Set: dude
> >Image format 6505 (32 bit)
> >
> >Virtual Machine
> >---------------
> >/home/wm/usr/bin/coglinux/lib/squeak/4.0-2749/squeak
> >Croquet Closure Cog VM [CoInterpreter VMMaker.oscog-eem.302]
> >Unix built on Jul 15 2013 15:49:06 Compiler: 4.1.2 20080704 (Red Hat
> >4.1.2-48)
> >platform sources revision VM: r2749
> >http://www.squeakvm.org/svn/squeak/branches/Cog Plugins: r2545
> >http://squeakvm.org/svn/squeak/trunk/platforms/Cross/plugins
> >CoInterpreter VMMaker.oscog-eem.302 uuid:
> >2ac39432-ac54-4584-964e-b129c90792f4 Jul 15 2013
> >StackToRegisterMappingCogit VMMaker.oscog-eem.302 uuid:
> >2ac39432-ac54-4584-964e-b129c90792f4 Jul 15 2013
> >
> >
> >
> >
> >
> >
-------------- next part --------------
'From Squeak4.5 of 16 March 2014 [latest update: #13699] on 19 March 2014 at 10:37:32 pm'!
"Change Set:		Ubuntu-fullScreen-workaround-dtl
Date:			19 March 2014
Author:			David T. Lewis

The X11 window manager on some Ubuntu Linux distributions does not work properly with the full screen on/off mechanism used by the Squeak VM (but no other window managers have this problem). As a temporary workaround for this issue, use the XDisplayControlPlugin to reconnect with a new X11 session after restoring the Squeak display to a managed window."!


!DisplayScreen methodsFor: 'other' stamp: 'dtl 3/19/2014 22:34'!
fullScreenMode: aBoolean
	"On platforms that support it, set full-screen mode to the value of the argument. (Note: you'll need to restore the Display after calling this primitive."
	"Display fullScreenMode: true. Display newDepth: Display depth"

	self primFullScreenMode: aBoolean.
	aBoolean ifFalse: [self primDisconnectXDisplay; primOpenXDisplay]
! !

!DisplayScreen methodsFor: 'other' stamp: 'dtl 3/19/2014 22:31'!
primFullScreenMode: aBoolean
	"On platforms that support it, set full-screen mode to the value of the argument. (Note: you'll need to restore the Display after calling this primitive."
	"Display fullScreenMode: true. Display newDepth: Display depth"

	<primitive: 233>
	self primitiveFailed
! !

!DisplayScreen methodsFor: 'Ubuntu-hack' stamp: 'dtl 3/19/2014 22:04'!
primDisconnectXDisplay
	"Disconnect the X display session. The actual Squeak window on the X server is not
	effected, but this instance of Squeak will not have any further interaction with it."

	<primitive: 'primitiveDisconnectDisplay' module: 'XDisplayControlPlugin'>
! !

!DisplayScreen methodsFor: 'Ubuntu-hack' stamp: 'dtl 3/19/2014 21:50'!
primOpenXDisplay
	"Call an internal function which will open the X display session."

	<primitive: 'primitiveOpenDisplay' module: 'XDisplayControlPlugin'>

! !



More information about the Vm-dev mailing list