le2d v0.4.7
2D game engine framework
 
Loading...
Searching...
No Matches
le::TextBuffer Class Reference

Wall of text as a single Primitive. More...

#include <le2d/text/text_buffer.hpp>

Public Member Functions

 TextBuffer (gsl::not_null< IFontAtlas * > atlas, std::size_t limit, float n_line_spacing=1.5f)
 
void push_front (std::string text, kvf::Color color)
 
void push_front (std::span< std::string > lines, kvf::Color color)
 
auto get_size () const -> glm::vec2
 
auto to_primitive () const -> Primitive
 

Detailed Description

Wall of text as a single Primitive.

Constructor & Destructor Documentation

◆ TextBuffer()

le::TextBuffer::TextBuffer ( gsl::not_null< IFontAtlas * >  atlas,
std::size_t  limit,
float  n_line_spacing = 1.5f 
)
explicit

Member Function Documentation

◆ get_size()

auto le::TextBuffer::get_size ( ) const -> glm::vec2
inline

◆ push_front() [1/2]

void le::TextBuffer::push_front ( std::span< std::string >  lines,
kvf::Color  color 
)

◆ push_front() [2/2]

void le::TextBuffer::push_front ( std::string  text,
kvf::Color  color 
)
inline

◆ to_primitive()

auto le::TextBuffer::to_primitive ( ) const -> Primitive

The documentation for this class was generated from the following file: