Ideal screen rotation
helge.hafting at hist.no
Wed Nov 4 13:55:29 CET 2009
Neil Jerram wrote:
> Having just written an automatic screen rotation program (like
> omnewrotate), I'm now wondering about the best way of using it, so
> that everything Just Works the way that it should.
> In particular, I've realized now that
> - for many apps there is a preferred orientation (e.g. zhone and
> hex-a-hop), and the best thing is to rotate the screen to what is best
> for each app, regardless of how the phone is being held
> - for some apps you definitely don't want the screen to be rotated
> underneath them, e.g. mokomaze
> - for the apps where autorotation makes sense, you want the control to
> be easily accessible - certainly a lot easier than switching back to
> the launcher or an xterm and doing something there :-)
> Have others already thought about this and devised solutions?
> I think a good solution might involve the window manager - since the
> window manager knows which app is at the front of the screen and so
> could rotate the screen correctly for it (including enabling
> autorotation for the apps where that makes sense). Alternatively - at
> least for e17 - an easily accessible gadget in the top shelf could
> make it very simple to choose a specific orientation and to enable and
> disable autorotation.
The software that control rotation need to know if the foreground app
should run in landscape, portrait or auto mode. (And perhaps the
upside-down variants as well.)
There are many ways to do this. For example:
1. Add this to enlightenment.
Advantages: e already knows at all times
which app is in the foreground. The .desktop
files in /usr/share/applications/ can specify
You can also have rotation gadgets on the
top shelf, for overriding when necessary.
Disadvantage: Works only with e - obviously.
2. Give omnewrotate (or similiar rotation app) a list of apps and their
Advantage: works for all window managers
disadvantage: overriding the rotation could be trickier, and
omnewrotate will need a way to get notified about
focus/foreground changes. Fast polling will slow down
the phone, slow polling will be too slow. So
notification is necessary.
More information about the community