Ginga  0.13.6.2086-83aa
The iTV middleware.
PlayerText Class Reference
Inheritance diagram for PlayerText:
Collaboration diagram for PlayerText:

Public Member Functions

 PlayerText (Formatter *, Media *)
 
void reload () override
 
- Public Member Functions inherited from Player
 Player (Formatter *, Media *)
 
State getState ()
 
void getZ (int *, int *)
 
bool isFocused ()
 
Time getTime ()
 
void incTime (Time)
 
Time getDuration ()
 
void setDuration (Time)
 
bool getEOS ()
 
void setEOS (bool)
 
virtual void start ()
 
virtual void stop ()
 
virtual void pause ()
 
virtual void resume ()
 
virtual string getProperty (const string &)
 
virtual void setProperty (const string &, const string &)
 
void resetProperties ()
 
void resetProperties (set< string > *)
 
void schedulePropertyAnimation (const string &, const string &, const string &, Time)
 
virtual void redraw (cairo_t *)
 
virtual void sendKeyEvent (const string &, bool)
 
virtual void sendPresentationEvent (const string &, const string &)
 

Static Public Member Functions

static cairo_surface_t * renderSurface (const string &, const string &, const string &, const string &, const string &, Color, Color, Rect, const string &, const string &, bool, Rect *)
 Creates surface from text. More...
 
- Static Public Member Functions inherited from Player
static string getCurrentFocus ()
 
static void setCurrentFocus (const string &)
 
static Property getPlayerProperty (const string &, string *)
 
static PlayercreatePlayer (Formatter *, Media *, const string &, const string &type="")
 

Protected Member Functions

bool doSetProperty (Property, const string &, const string &) override
 

Private Attributes

struct {
   Color   fontColor
 
   Color   fontBgColor
 
   string   fontFamily
 
   string   fontSize
 
   string   fontStyle
 
   string   fontVariant
 
   string   fontWeight
 
   string   horzAlign
 
   string   vertAlign
 
_prop
 

Additional Inherited Members

- Public Types inherited from Player
enum  State { SLEEPING = 1, OCCURRING, PAUSED }
 
enum  Property {
  PROP_UNKNOWN = 0, PROP_BACKGROUND, PROP_BALANCE, PROP_BASS,
  PROP_BOTTOM, PROP_BOUNDS, PROP_DEBUG, PROP_DURATION,
  PROP_EXPLICIT_DUR, PROP_FOCUS_INDEX, PROP_FONT_BG_COLOR, PROP_FONT_COLOR,
  PROP_FONT_FAMILY, PROP_FONT_SIZE, PROP_FONT_STYLE, PROP_FONT_VARIANT,
  PROP_FONT_WEIGHT, PROP_FREEZE, PROP_FREQ, PROP_HEIGHT,
  PROP_HORZ_ALIGN, PROP_LEFT, PROP_LOCATION, PROP_MUTE,
  PROP_RIGHT, PROP_SIZE, PROP_SPEED, PROP_TIME,
  PROP_TOP, PROP_TRANSPARENCY, PROP_TREBLE, PROP_TYPE,
  PROP_URI, PROP_VERT_ALIGN, PROP_VISIBLE, PROP_VOLUME,
  PROP_WAVE, PROP_WIDTH, PROP_Z_INDEX, PROP_Z_ORDER
}
 
- Protected Attributes inherited from Player
Formatter_formatter
 
Media_media
 
string _id
 
State _state
 
Time _time
 
bool _eos
 
cairo_surface_t * _surface
 
bool _opengl
 
guint _gltexture
 
bool _dirty
 
PlayerAnimator_animator
 
list< int > _crop
 
map< string, string > _properties
 
struct {
   Color   bgColor
 
   Rect   rect
 
   Time   duration
 
   bool   debug
 
   bool   visible
 
   guint8   alpha
 
   int   z
 
   int   zorder
 
   string   focusIndex
 
   string   type
 
   string   uri
 
_prop
 

Member Function Documentation

◆ renderSurface()

GINGA_NAMESPACE_BEGIN cairo_surface_t * PlayerText::renderSurface ( const string &  text,
const string &  family,
const string &  weight,
const string &  style,
const string &  size,
Color  fg,
Color  bg,
Rect  rect,
const string &  halign,
const string &  valign,
bool  antialias,
Rect *  ink 
)
static

Creates surface from text.

Parameters
textText to be rendered.
familyFont family.
weightFont weight ("normal" or "bold").
styleFont style ("normal" or "italic").
sizeFont size
fgText color.
bgBackground color.
rectDimensions of the resulting surface.
halignHorizontal alignment ("left", "center", "right", or "justified").
valignVertical alignment ("bottom", "middle", or "top").
antialiasWhether to use antialias.
inkVariable to store the inked rectangle.
Returns
The resulting surface.

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