function adjustLayout() {
    mCol=xGetElementById('lMain');
    lCol=xGetElementById('lLeftCol');
    cCol=xGetElementById('lContent');
    rCol=xGetElementById('lRightCol');
    fCol=xGetElementById('lFooter');
    tCol=xGetElementById('lTop');

    //ustawienie do wysokości strony
    h=xClientHeight();
    if( h > xHeight(mCol) ){ cCol.style.height = cCol.style.minHeight = h-xHeight(fCol)-xHeight(tCol)-14+'px'; }
    
    leftHeight = xHeight(lCol)+xHeight(fCol);
    centerHeight = xHeight(cCol)+xHeight(tCol)+xHeight(fCol)-14;
    if(rCol!=undefined) { rightHeight = xHeight(rCol)+xHeight(fCol)+xHeight(tCol); } else { rightHeight = 0; cCol.style.paddingRight = '0'; }
    
    m=Math.max(leftHeight, centerHeight, rightHeight);
   
    cCol.style.height = cCol.style.minHeight = m-xHeight(tCol)-xHeight(fCol)+'px';
    lCol.style.height = lCol.style.minHeight = m-xHeight(fCol)+14+'px';
    if(rCol!=undefined) { rCol.style.height = rCol.style.minHeight = m-xHeight(tCol)-xHeight(fCol)+'px'; }
    
    if( xIE ){
        if( xWidth(mCol)>(xWidth(cCol)+171) ){
            cCol.style.width = xWidth(mCol);
        }
    }
}