Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7457 in orxonox.OLD for trunk/src/lib/graphics/text_engine


Ignore:
Timestamp:
Apr 30, 2006, 4:28:17 AM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: Size2D is ok now for the MultiLineText

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/lib/graphics/text_engine/multi_line_text.cc

    r7456 r7457  
    3232
    3333  this->lineSpacing = 1.0f;
    34   this->lineWidth = 100.0f;
    35   this->setupTextWidth();
     34  this->setLineWidth(100.0f);
    3635}
    3736
     
    4342{
    4443  this->lineWidth = lineWidth;
     44  this->setSizeX2D(lineWidth);
    4545  this->setupTextWidth();
    4646}
     
    141141      width += this->getFont()->getGlyphArray()[this->getText()[i]]->advance;
    142142  }
    143   this->setSizeY2D(this->lineEnds.size() * (this->lineSpacing + this->getFont()->getMaxHeight()));
     143  this->setSizeY2D((this->lineEnds.size()+1) * (this->lineSpacing + this->getFont()->getMaxHeight()));
    144144}
Note: See TracChangeset for help on using the changeset viewer.