GNU Octave  9.1.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
text_renderer Class Reference

#include "text-renderer.h"

Classes

class  font
 
class  string
 

Public Member Functions

 text_renderer ()
 
 ~text_renderer ()
 
Matrix get_extent (const std::string &txt, double rotation=0.0, const caseless_str &interpreter="tex")
 
Matrix get_extent (text_element *elt, double rotation=0.0)
 
octave_map get_system_fonts ()
 
bool ok () const
 
void set_anti_aliasing (bool val)
 
void set_color (const Matrix &c)
 
void set_font (const std::string &name, const std::string &weight, const std::string &angle, double size)
 
void text_to_pixels (const std::string &txt, uint8NDArray &pxls, Matrix &bbox, int halign, int valign, double rotation=0.0, const caseless_str &interpreter="tex", bool handle_rotation=true)
 
void text_to_strlist (const std::string &txt, std::list< string > &lst, Matrix &box, int halign, int valign, double rotation=0.0, const caseless_str &interpreter="tex")
 

Detailed Description

Definition at line 44 of file text-renderer.h.

Constructor & Destructor Documentation

◆ text_renderer()

text_renderer::text_renderer ( )

Definition at line 39 of file text-renderer.cc.

◆ ~text_renderer()

text_renderer::~text_renderer ( )

Definition at line 44 of file text-renderer.cc.

Member Function Documentation

◆ get_extent() [1/2]

Matrix text_renderer::get_extent ( const std::string &  txt,
double  rotation = 0.0,
const caseless_str interpreter = "tex" 
)

Definition at line 78 of file text-renderer.cc.

References base_text_renderer::get_extent(), base_text_renderer::ok(), and ok().

◆ get_extent() [2/2]

Matrix text_renderer::get_extent ( text_element elt,
double  rotation = 0.0 
)

Definition at line 70 of file text-renderer.cc.

References base_text_renderer::get_extent(), and ok().

◆ get_system_fonts()

octave_map text_renderer::get_system_fonts ( )

Definition at line 99 of file text-renderer.cc.

References base_text_renderer::get_system_fonts(), and ok().

◆ ok()

◆ set_anti_aliasing()

void text_renderer::set_anti_aliasing ( bool  val)

Definition at line 92 of file text-renderer.cc.

References ok(), and base_text_renderer::set_anti_aliasing().

Referenced by opengl_renderer::set_font().

◆ set_color()

void text_renderer::set_color ( const Matrix c)

Definition at line 121 of file text-renderer.cc.

References ok(), and base_text_renderer::set_color().

Referenced by opengl_renderer::set_color().

◆ set_font()

void text_renderer::set_font ( const std::string &  name,
const std::string &  weight,
const std::string &  angle,
double  size 
)

Definition at line 110 of file text-renderer.cc.

References ok(), and base_text_renderer::set_font().

Referenced by opengl_renderer::set_font().

◆ text_to_pixels()

void text_renderer::text_to_pixels ( const std::string &  txt,
uint8NDArray pxls,
Matrix bbox,
int  halign,
int  valign,
double  rotation = 0.0,
const caseless_str interpreter = "tex",
bool  handle_rotation = true 
)

◆ text_to_strlist()

void text_renderer::text_to_strlist ( const std::string &  txt,
std::list< string > &  lst,
Matrix box,
int  halign,
int  valign,
double  rotation = 0.0,
const caseless_str interpreter = "tex" 
)

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