Our SharePoint 2013 generated web page has a width of 1024. The main content div is styled as follows:
#container_master {
width:1024px !important;
margin-left: auto !important;
margin-right: auto !important;
background-color:#FFF !important;
}
This works perfectly on resolutions above 1024. However, when someone sets their resolution to 1024 (which some users do), there is extra padding on the left and right sides causing a horizontal scroll bar to appear.
Upon inspecting with FireBug, I noticed the following HTML being generated:
<div aria-relevant="all" aria-live="polite" style="margin-left: 20px; margin-right: 20px; min-width: 1024px;">
The issue lies in this 20px margin on the left and right. To remove it, I added the following CSS:
html body.ms-backgroundImage form#aspnetForm div#s4-workspace.ms-core-overlay div#s4-bodyContainer div#contentRow div {
margin-left: 0px !important;
margin-right: 0px !important;
}
However, applying this change results in the page no longer being centered on screen sizes greater than 1024. Any suggestions on how to achieve a "full-screen" display for those using 1024 resolution while keeping it centered for higher resolutions?