Ticket #10712 (closed defect: fixed)

Opened 4 years ago

Last modified 3 years ago

wrong cursor on welcome screen

Reported by: dsd Owned by: erikos
Priority: high Milestone: 11.3.0
Component: sugar Version: Development build as of this date
Keywords: wm Cc:
Action Needed: test in build Verified: no
Deployments affected: Blocked By:
Blocking:

Description

On the sugar welcome screen where you are asked for your name, the mouse cursor is a regular arrow instead of the big sugar one. Reproduced on 11.2.0 build 9.

Change History

Changed 4 years ago by erikos

  • keywords wm added
  • version changed from not specified to Development build as of this date
  • next_action changed from never set to code

Looks like we set the cursor in sugar because otherwise metacity sets it. Looks like we do set it too late for the intro screen.

def setup_window_manager():
    logging.debug('STARTUP: window_manager')

    # have to reset cursor(metacity sets it on startup)                                                                                                      
    if subprocess.call('echo $DISPLAY; xsetroot -cursor_name left_ptr', shell=True):
        logging.warning('Can not reset cursor')

    if subprocess.call('metacity-message disable-keybindings',
            shell=True):
        logging.warning('Can not disable metacity keybindings')

Changed 4 years ago by RafaelOrtiz

FWIW I've been tempted to report this, but I didn't have the time. Thanks for looking.

Changed 4 years ago by erikos

Ok, I have been following the attempts to handle the root issue:

1) First, we tried to set the gnome cursor_theme to use the sugar one:  http://git.sugarlabs.org/sugar/mainline/commit/23516911ebc21e9714f662a6c47cf385660a88b0

2) Because this broke the GNOME cursor when logging into GNOME we did reset the cursor once we logged into Sugar "xsetroot -cursor_name left_ptr"  #1433  http://git.sugarlabs.org/sugar/mainline/commit/293a3fc5a11fb4309eba4414702570b778508f4f

3) We moved this code around since the "Alt+Space" shortcut was not working anymore, we do set the the cursor once the  window-manager-changes for the shell window  #1476  http://git.sugarlabs.org/sugar/mainline/commit/b0520607503b0876020d5e764b1a98322a2bf949

4) we once more moved the code to supress a race condtion:  #1371  http://git.sugarlabs.org/sugar/mainline/commit/26ba76b965984ddc8681a3c25ee075a6664c98ef

Changed 4 years ago by mikus

This ticket was written against the "screen where you are asked for your name". [Through experience, the user ought to learn what to do in the specific case of this 'your name' screen.] But the problem symptom is more widespread than that.:

I think it is in sugar-0.88 (or perhaps in 0.90) where EVERY instance of Sugar starting on the XO first displays that miniscule (on XO screen) GNOME cursor. The problem is that immediately before, a completely blank white screen was being shown -- unless the user is paying close attention, he may not realize (until Sugar's centered XO icon appears) that Sugar has started -- the difficult-to-see small cursor might confuse the user into thinking "nothing is happening".

Changed 4 years ago by sascha_silbe

I can't reproduce this using Debian Squeeze. As long as the following line is in sugar(.in) and metacity gets started, the Sugar cursor is shown right from the start (even if I start an xterm instead of Sugar):

echo Xcursor.theme: sugar | xrdb -merge

Tested with sugar-jhbuild + sugar-emulator, sugar-jhbuild + ~/.xsession and native Debian packages + ~/.xsession.

However, I could reproduce the issue on a Dextrose-3 build, even after downgrading metacity from 2.30.3 to 2.30.0 (Debian ships 2.30.1 for Squeeze). Since the cursor shows fine as soon as Sugar is started iff the above line is used, I assume that the cursor theme is found, just not used.

If I add an xsetroot invocation right in front of the metacity invocation, the cursor switches to the Sugar cursor (xsetroot) and back to the default cursor (metacity).

We should investigate why metacity behaves differently on Fedora (compared to Debian). Neither Debian nor Fedora apply any patches that look like they might affect this, so either it's an unintended side effect (could be checked by rebuilding both packages with no patches applied) or a bug in some other package (e.g. Xorg).

Changed 3 years ago by erikos

  • priority changed from normal to high

Changed 3 years ago by erikos

  • keywords wm, blocker? added; wm removed

Changed 3 years ago by erikos

  • keywords wm added; wm, blocker? removed

Changed 3 years ago by erikos

  • next_action changed from code to review

Sent patch:  http://lists.sugarlabs.org/archive/sugar-devel/2011-October/033854.html

{{{This issue has a long history outlined in detail in [1]. We once moved the xsetroot around to compensate for SL #1476 but Daniel fixed this in Metacity in OLPC #10693.

The proposed patch does work for me in Jhbuild and the latest 0.94 based OLPC build. Both the cursor in the intro screen and under Sugar are the correct ones.

[1]  http://dev.laptop.org/ticket/10712#comment:3 }}}

Changed 3 years ago by erikos

  • next_action changed from review to add to build

Patch is in Sugar 0.94.1, which is in my public folder.

Changed 3 years ago by dsd

  • next_action changed from add to build to test in build

test in 11.3.0 candidate build 882

Changed 3 years ago by godiard

Tested in os882. Working as expected.

Changed 3 years ago by dsd

  • status changed from new to closed
  • resolution set to fixed

in 11.3.0 build 882 on XO-1.75 the GNOME cursor appears briefly and then the sugar cursor appears just before the naming screen is drawn. with the DCON the GNOME cursor will not be shown at all. works well!

Note: See TracTickets for help on using tickets.