Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Nov 1, 2008, 7:04:09 PM (16 years ago)
Author:
landauf
Message:

merged objecthierarchy branch back to trunk

Location:
code/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/trunk

  • code/trunk/src/orxonox/overlays/OverlayText.h

    r1625 r2087  
    3434#include <string>
    3535#include <OgrePrerequisites.h>
     36#include <OgreTextAreaOverlayElement.h>
    3637#include "OrxonoxOverlay.h"
    3738
     
    4142    {
    4243    public:
    43         OverlayText();
     44        OverlayText(BaseObject* creator);
    4445        virtual ~OverlayText();
    4546
    4647        virtual void XMLPort(Element& xmlElement, XMLPort::Mode mode);
    4748
     49        void setCaption(const std::string& caption) { this->text_->setCaption(caption); }
     50        std::string getCaption() const              { return this->text_->getCaption(); }
     51
     52        void setFont(const std::string& font);
     53        const std::string& getFont() const { return this->text_->getFontName(); }
     54
     55        void setColour(const ColourValue& colour) { this->text_->setColour(colour); }
     56        const ColourValue& getColour() const      { return this->text_->getColour(); }
     57
     58        void setAlignment(Ogre::TextAreaOverlayElement::Alignment alignment) { this->text_->setAlignment(alignment); }
     59        Ogre::TextAreaOverlayElement::Alignment getAlignment() const         { return this->text_->getAlignment(); }
     60
    4861    protected:
    4962        virtual void sizeChanged();
    5063
    51         void setCaption(const std::string& caption) { this->caption_ = caption; }
    52         const std::string& getCaption() const       { return this->caption_; }
    53 
    54         void setFont(const std::string& font);
    55         const std::string& getFont() const;
     64        void setAlignmentString(const std::string& alignment);
     65        std::string getAlignmentString() const;
    5666
    5767        void setTextSize(float size) { this->setSize(Vector2(size, size)); }
     
    5969
    6070        Ogre::TextAreaOverlayElement* text_;
    61 
    62     private:
    63         std::string caption_;
    6471    };
    6572}
Note: See TracChangeset for help on using the changeset viewer.