I run Ubuntu on my laptop. Roughly 75% of the time, I'm at work with a second monitor attached. The rest of the time I'm running with just the laptop screen. I can configure my panels (and a few misc things like Conky) fine with dual monitors, but then when I run with my laptop only things look messed up (multiple top and bottom panels, etc). If I set things up for a single monitor, then things aren't set up when I'm using dual monitors.
What I want to do is be able to define things like my gnome panels in a user choosable (or automatically selected) to get around this.
Is this possible, and if so, where do I start?
Best Answer
I use two scripts for using my notebook-monitor or an external monitor. Maybe you can use them as a starting point.
Note: My notebook has a nvidia graphic card, so i have to use disper instead of xrandr.
Script to switch to the external monitor and set gnome-panel to monitor 1:
Second script to switch back to Notebook-monitor: