Text.hpp
Go to the documentation of this file.
1 
6 #pragma once
7 
8 #include <etk/Color.hpp>
9 
10 #include <ewol/debug.hpp>
15 #include <exml/exml.hpp>
16 #include <string>
17 
18 #include <etk/Color.hpp>
19 
20 namespace ewol {
21  namespace compositing {
23  protected:
25  public:
31  Text(const std::string& _fontName="", int32_t _fontSize=-1);
35  virtual ~Text();
36  public:
37  virtual void drawD(bool _disableDepthTest);
38  virtual void drawMT(const mat4& _transformationMatrix, bool _enableDepthTest);
39  protected:
40  float m_size;
41  public:
42  virtual float getHeight();
43  virtual float getSize();
44  virtual ewol::GlyphProperty * getGlyphPointer(char32_t _charcode);
45 
46  public:
47  virtual void setFontSize(int32_t _fontSize);
48  virtual void setFontName(const std::string& _fontName);
49  virtual void setFont(std::string _fontName, int32_t _fontSize);
50  virtual void setFontMode(enum ewol::font::mode _mode);
51  virtual void printChar(const char32_t& _charcode);
52  virtual vec3 calculateSizeChar(const char32_t& _charcode);
53  };
54  }
55 }
56 
virtual void setFont(std::string _fontName, int32_t _fontSize)
Specify the font property (this reset the internal element of the current text (system requirement) ...
Definition: TextBase.hpp:43
virtual void setFontSize(int32_t _fontSize)
Specify the font size (this reset the internal element of the current text (system requirement) ...
mode
Definition: TexturedFont.hpp:16
virtual void drawD(bool _disableDepthTest)
draw All the refistered text in the current element on openGL
Definition: Text.hpp:22
Definition: Area.hpp:16
virtual void printChar(const char32_t &_charcode)
display the current char in the current element (note that the kerning is availlable if the position ...
virtual void setFontMode(enum ewol::font::mode _mode)
Specify the font mode for the next print.
Definition: GlyphProperty.hpp:48
Text(const std::string &_fontName="", int32_t _fontSize=-1)
generic constructor
virtual vec3 calculateSizeChar(const char32_t &_charcode)
virtual ~Text()
generic destructor
virtual void drawMT(const mat4 &_transformationMatrix, bool _enableDepthTest)
ememory::SharedPtr< ewol::resource::TexturedFont > m_font
Font resources.
Definition: Text.hpp:24
virtual void setFontName(const std::string &_fontName)
Specify the font name (this reset the internal element of the current text (system requirement) ...