Window Management
Revision as of 14:07, 19 May 2008 by RafaelOrtiz (talk | contribs)
Despite the fact that the Sugar UI is very different from a standard desktop, it's almost completely implemented using standard window manager hints and properties. We are planning to move from matchbox to a more compliant window manager and to address the little incompatibilities at the shell level, so that standard desktop applications can run out of the box in Sugar.
Here are some of the steps to get there:
- Change the sugar-shell startup code to run metacity instead of matchbox.
- Works. Change the
_start_matchbox()
method in sugar/src/main.py to start metacity instead of matchbox
- Works. Change the
- See which parts of Sugar breaks. I expect the frame will not work well, the windows needs to be hinted as panels.
- Frame breaks. However, it works fine if it is hinted as a panel. Add
self.set_type_hint(gtk.gdk.WINDOW_TYPE_HINT_DOCK)
to the__init__()
method of theFrameWindow
class in sugar/src/view/frame/framewindow.py - Activity switching (eg: by clicking on the currently running activity's icon on the home view) does not seem to work.
- Frame breaks. However, it works fine if it is hinted as a panel. Add
- Decide how to make activities run fullscreen. We could either modify metacity to run every toplevel window in fullscreen. Or we could set the fullscreen hint on the activity windows. We should clarify the tradeoffs there.
- Setting the window to be fullscreen (via
set_fullscreen()
)does not seem to work, since it stops the frame from popping up, and also an icon to exit fullscreen appears at the top right corner. One possible solution to this is to make the activity window undecorated (we do not need maximise/minimize/resize buttons), and making their height/width equal to the dimensions of the screen.
- Setting the window to be fullscreen (via
- Maximized + undecorated perhaps? -- Marcopg
- Tried that. As soon as I set the window to undecorated, it seems to assume fullscreen properties. Is there any convention which signifies maximized + undecorated = fullscreen ? -- SayaminduDasgupta
- Maybe some hacks in metacity :( -- Marcopg
- Tried that. As soon as I set the window to undecorated, it seems to assume fullscreen properties. Is there any convention which signifies maximized + undecorated = fullscreen ? -- SayaminduDasgupta
- Support standard window icons in the frame activity list.
- TBD