branchobj.cpp
changeset 460 12e763c3e486
parent 425 7014be3ac7d0
child 462 494a5b8c131e
     1.1 --- a/branchobj.cpp	Mon Feb 12 09:28:46 2007 +0000
     1.2 +++ b/branchobj.cpp	Wed Apr 25 16:02:54 2007 +0000
     1.3 @@ -572,7 +572,6 @@
     1.4  	QPointF ap=getAbsPos();
     1.5  	bbox.moveTopLeft (ap);
     1.6  	positionContents();
     1.7 -	setSelBox();
     1.8  
     1.9  	// set the frame
    1.10  	frame->setRect(QRectF(bbox.x(),bbox.y(),bbox.width(),bbox.height() ) );
    1.11 @@ -661,12 +660,20 @@
    1.12  	// Sets childpos and parpos depending on orientation
    1.13  	if (getOrientation()==OrientLeftOfCenter )
    1.14      {
    1.15 -		childPos=QPointF (ornamentsBBox.bottomLeft().x(), ornamentsBBox.bottomLeft().y() );
    1.16 -		parPos=QPointF (ornamentsBBox.bottomRight().x(),ornamentsBBox.bottomRight().y() );
    1.17 +		childPos=QPointF (
    1.18 +			ornamentsBBox.bottomLeft().x(), 
    1.19 +			bottomlineY);
    1.20 +		parPos=QPointF (
    1.21 +			ornamentsBBox.bottomRight().x(),
    1.22 +			bottomlineY);
    1.23      } else
    1.24      {
    1.25 -		childPos=QPointF (ornamentsBBox.bottomRight().x(), ornamentsBBox.bottomRight().y() );
    1.26 -		parPos=QPointF (ornamentsBBox.bottomLeft().x(),ornamentsBBox.bottomLeft().y() );
    1.27 +		childPos=QPointF (
    1.28 +			ornamentsBBox.bottomRight().x(), 
    1.29 +			bottomlineY);
    1.30 +		parPos=QPointF (
    1.31 +			ornamentsBBox.bottomLeft().x(),
    1.32 +			bottomlineY);
    1.33      }
    1.34  }
    1.35  
    1.36 @@ -1451,7 +1458,7 @@
    1.37  
    1.38  void BranchObj::select()
    1.39  {
    1.40 -	// set Text in Editor	
    1.41 +	// update NoteEditor
    1.42  	textEditor->setText(note.getNote() );
    1.43  	QString fnh=note.getFilenameHint();
    1.44  	if (fnh!="")
    1.45 @@ -1461,7 +1468,9 @@
    1.46  	textEditor->setFontHint (note.getFontHint() );
    1.47  	isNoteInEditor=true;
    1.48  
    1.49 +	// set selected and visible
    1.50      LinkableMapObj::select();
    1.51 +
    1.52  	// Tell parent that I am selected now:
    1.53  	BranchObj* po=(BranchObj*)(parObj);
    1.54      if (po)	// TODO	    Try to get rid of this cast...