So, I have read several questions - with and without answers - and though this is similar to others, I have found nothing particular to the issues I am experiencing. It is a three-part problem and I think they're all related erego why they are being posed as a single question.
- My desktop icons are all on my secondary display and I can't move them back.
- I can no longer maximize windows on my primary display by dragging them to the top of the screen, this results in them being dragged to a desktop with no display that shouldn't be an accessible area anyway.
- After hours of searching for solutions, I was finally able to write a script that will create and assign the proper resolution and position to my secondary display, and leave it alone if it isn't connected. The catch there is that I have to log in first, so prior to login I am stuck with a sideways login screen that is, oddly enough, on my secondary display.
I am using an older VAIO laptop with a VGA output (hence the need to create the proper resolution for my external monitor) and running Ubuntu MATE 16.04.
Here's a screen shot:
And here's my script: feel free to do whatever you want with it. It may be of use to people with display configuration issues.
#!/bin/bash
xrandr --auto
cvt 1920 1080
xrandr --newmode "1920x1080_60.00" 173.00 1920 2048 2248 2576 1080 1083 1088 1120 -hsync +vsync
xrandr --addmode VGA1 1920x1080_60.00
xrandr --output VGA1 --mode 1920x1080_60.00
xrandr --output VGA1 --rotate right
xrandr --output LVDS1 --pos 0x1281 --output VGA1 --pos 1281x0
xrandr --auto




