How can I stop a window maximizing across two screens?

Solution 1:

I know the way to achieve the opposite effect (force single-monitor behaviour on a dual monitor), so assuming coherence the following should work for you:

  1. Install compizconfig-settings-manager
  2. Open it by typing ccsm into the dash
  3. Go to General options > display settings
  4. Do one of the following:
    1. If you have "Detect outputs" unchecked, check it again
    2. If not, uncheck it, and modify the outputs in the table at the bottom so that you have one for each monitor in the format <resolution-x>x<resolution-y>+<offset-x>+<offset-y>. For example 1280x1024+0+0 and 1280x1024+1280+0 for two monitors side by side at 1280x1024
  5. Press Alt+F2 and enter unity --replace so that compiz restarts. If compiz still refuses to apply the setting try logging out and back in

If 4.1 does not work, give 4.2 a try.