Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7451 in orxonox.OLD for trunk


Ignore:
Timestamp:
Apr 29, 2006, 9:49:11 PM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: Test the MultiLineText in this revision

Location:
trunk/src/lib
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/lib/BuildLibs.am

    r7256 r7451  
    22libORXlibs_a_LIBRARIES_ = \
    33                $(LIB_PREFIX)/libORXlibs.a \
     4                $(LIB_PREFIX)/shell/libORXshell.a \
    45                $(LIB_PREFIX)/gui/gtk_gui/libORXgui.a \
    56                $(LIB_PREFIX)/gui/gl_gui/libORXglgui.a \
     
    1819                $(LIB_PREFIX)/parser/cmdline_parser/libCmdLineParser.a \
    1920                $(LIB_PREFIX)/parser/ini_parser/libIniParser.a \
    20                 $(LIB_PREFIX)/shell/libORXshell.a \
    2121                $(LIB_PREFIX)/math/libORXmath.a \
    2222                $(LIB_PREFIX)/libORXlibs.a
  • trunk/src/lib/graphics/text_engine/multi_line_text.cc

    r7450 r7451  
    8080
    8181  glBegin(GL_QUADS);
    82   for (unsigned int i = 0; i < this->getText().size(); i++)
     82  for (unsigned int i = 0; i < this->getText().size(); ++i)
    8383  {
    84     if (unlikely(tmpGlyph->character == '\n' || i == this->lineEnds[lineNumber]))
     84    if (unlikely(this->getText()[i] == '\n' || i == this->lineEnds[lineNumber]))
    8585    {
    86     // go to the next Line.
    87       lineNumber++;
     86      // go to the next Line.
     87      ++lineNumber;
    8888      posX = 0.0f;
    8989      posY += this->lineSpacing + this->getFont()->getMaxHeight();
     
    117117{
    118118  this->lineEnds.clear();
     119  this->lineEnds.push_back(0);
    119120  float width = 0.0f;
    120121  // TODO make size local to this (not using the one from Element2D.
  • trunk/src/lib/shell/shell_input.cc

    r7374 r7451  
    4646  */
    4747  ShellInput::ShellInput ()
    48       : Text ("")
    49   {
     48      : MultiLineText ("")
     49  {
     50    this->setLineWidth(100);
     51
    5052    this->pressedKey = SDLK_FIRST;
    5153    this->setClassID(CL_SHELL_INPUT, "ShellInput");
  • trunk/src/lib/shell/shell_input.h

    r7403 r7451  
    1010#define _SHELL_INPUT_H
    1111
    12 #include "text.h"
     12#include "multi_line_text.h"
    1313#include "event_listener.h"
    1414#include "shell_completion.h"
     
    2828   * [UP] and [DOWN] move through the history of allready given commands.
    2929   */
    30   class ShellInput : public Text,  public EventListener
     30  class ShellInput : public MultiLineText,  public EventListener
    3131  {
    3232
Note: See TracChangeset for help on using the changeset viewer.