How do you save a monitor configuration based on how many displays are available on a laptop?
I have a laptop that I often use with and without an external monitor. When I connect the monitor, Gnome-Shell automatically reconfigures to use the second display, but it always places the laptop's screen to the left. I have it physically located to the right, so I use the Displays dialog to move it. However, this is lost every time I unplug the display or suspend and resume the laptop.
This is similar to this question but I don't want to hard-code my Xorg/Xrandr setup to force dual displays because I often use the laptop without a monitor. I just want it to automatically place my laptop's screen to the right whenever I plug in the external monitor.
Edit: Output of xrandr
with external monitor setup.
Screen 0: minimum 8 x 8, current 3200 x 1080, maximum 8192 x 8192
LVDS-0 connected primary 1280x800+1920+0 (normal left inverted right x axis y axis) 286mm x 179mm
1280x800 60.2*+
DP-0 connected 1920x1080+0+0 (normal left inverted right x axis y axis) 510mm x 290mm
1920x1080 60.0*+
1680x1050 60.0
1280x1024 75.0 60.0
1280x960 60.0
1152x864 75.0
1024x768 75.0 60.0
800x600 75.0 60.3 56.2
640x480 75.0 59.9
DP-1 disconnected (normal left inverted right x axis y axis)
xrandr
with your second monitor connected and set up as you want it? You can post the link in a comment, later we can combine it in the question. – Jacob Vlijm Jun 11 '15 at 15:23