branchobj.cpp
changeset 213 b411e48266cd
parent 169 aa48c7b52549
child 220 6d4e5cefba7f
     1.1 --- a/branchobj.cpp	Fri Feb 17 09:22:02 2006 +0000
     1.2 +++ b/branchobj.cpp	Tue Feb 21 16:18:23 2006 +0000
     1.3 @@ -642,10 +642,17 @@
     1.4  					if (rp.y()+foi->height() > h)
     1.5  						botPad=max (botPad,rp.y()+foi->height()-h);
     1.6  				}		
     1.7 +				if (includeImagesHor)
     1.8 +				{
     1.9 +					if (rp.x() < 0) 
    1.10 +						leftPad=max (leftPad,-rp.x());
    1.11 +					if (rp.x()+foi->width() > w)
    1.12 +						rightPad=max (rightPad,rp.x()+foi->width()-w);
    1.13 +				}		
    1.14  			}	
    1.15  		}	
    1.16 -		
    1.17  		h+=topPad+botPad;
    1.18 +		w+=leftPad+rightPad;
    1.19  	}
    1.20  
    1.21  	// Frame thickness
    1.22 @@ -878,7 +885,7 @@
    1.23  	calcBBoxSize();
    1.24  	positionBBox();
    1.25  	requestReposition();
    1.26 -	// FIMXE undo needed
    1.27 +	//FIXME undo needed
    1.28  }
    1.29  
    1.30  bool BranchObj::getIncludeImagesVer()
    1.31 @@ -892,7 +899,7 @@
    1.32  	calcBBoxSize();
    1.33  	positionBBox();
    1.34  	requestReposition();
    1.35 -	// FIMXE undo needed
    1.36 +	//FIXME undo needed
    1.37  }
    1.38  
    1.39  bool BranchObj::getIncludeImagesHor()
    1.40 @@ -908,9 +915,9 @@
    1.41  	else
    1.42  		a=attribut ("incImgV","false");
    1.43  	if (includeImagesHor)
    1.44 -		a+=" "+attribut ("incImgH","true");
    1.45 +		a+=attribut ("incImgH","true");
    1.46  	else
    1.47 -		a+=" "+attribut ("incImgH","false");
    1.48 +		a+=attribut ("incImgH","false");
    1.49  	return a;	
    1.50  }
    1.51  
    1.52 @@ -1249,10 +1256,10 @@
    1.53  		switch (orientation) 
    1.54  		{
    1.55  			case OrientLeftOfCenter:
    1.56 -				move (ref.x()-bbox.width(), ref.y() + (th-bbox.height())/2 +topPad);
    1.57 +				move (ref.x() + rightPad - bbox.width(), ref.y() + (th-bbox.height())/2 +topPad);
    1.58  			break;
    1.59  			case OrientRightOfCenter:	
    1.60 -				move (ref.x(), ref.y() + (th-bbox.height())/2 + topPad);
    1.61 +				move (ref.x() + rightPad, ref.y() + (th-bbox.height())/2 + topPad);
    1.62  			break;
    1.63  			default:
    1.64  				cout <<"LMO::alignRelativeTo: oops, no orientation given...\n";