Home>Support>Why the negative margin for rows?

Why the negative margin for rows?

A negative right and left margins (half the gutter width) are added to the rows.

Any specific reason for this?

It doesn’t feel natural and can be annoying for non developers.

This is our free support forum. Replies can take several days. If you need fast email support, please purchase a SiteOrigin Premium license.

  1. 9 years, 8 months ago Satish Gandham

    Also, panel-grid-cell padding is set to zero when browser width is below 780px??

  2. 9 years, 7 months ago Greg Priday
    Hi, I Work Here

    Hi Satish

    Basically, they’re used to cancel out the gutter padding. The negative margin is used to make it possible for the columns to have percentage based widths. Without them, Page Builder would need to know the width of the exact width of its container.

  3. 9 years, 7 months ago Satish Gandham

    Hi Greg,
    Which gutter paddings?
    I’m using page builder on a page templates without any sidebars, and this negative margin is creating unnecessary horizontal scroll bars when using fluid layout.

    I feel that you don’t need negative margins, your are setting columns width 1/number of columns * 100, with their box sizing set as border box, so there is no problem in using percentages.

    I’m not sure if I explained myself clearly. If you do not understand what I’m trying to say, I can setup a demo for you.

  4. 9 years, 7 months ago Greg Priday
    Hi, I Work Here

    Hi Satish

    I can understand what’s happening to cause those horizontal scroll bars. That is an unfortunate side effect. I’ll see if I can get Page Builder to deal with that particular instance slightly better.

    I wrote up a full description of the reasoning behind the negative margins in Page Builder. Let me see if I can find that post.

Replies on this thread are closed. Please create a new thread if you have a question, or purchase a SiteOrigin Premium license if you need one-on-one email support.

Get The Most Out of SiteOrigin with SiteOrigin Premium

Find Out More