Ginga  0.13.6.2086-83aa
The iTV middleware.
PlayerText.h
1 /* Copyright (C) 2006-2018 PUC-Rio/Laboratorio TeleMidia
2 
3 This file is part of Ginga (Ginga-NCL).
4 
5 Ginga is free software: you can redistribute it and/or modify it
6 under the terms of the GNU General Public License as published by
7 the Free Software Foundation, either version 2 of the License, or
8 (at your option) any later version.
9 
10 Ginga is distributed in the hope that it will be useful, but WITHOUT
11 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
12 or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
13 License for more details.
14 
15 You should have received a copy of the GNU General Public License
16 along with Ginga. If not, see <https://www.gnu.org/licenses/>. */
17 
18 #ifndef PLAYER_TEXT_H
19 #define PLAYER_TEXT_H
20 
21 #include "Player.h"
22 
23 GINGA_NAMESPACE_BEGIN
24 
25 class PlayerText : public Player
26 {
27 public:
28  static cairo_surface_t *renderSurface (const string &, const string &,
29  const string &, const string &,
30  const string &, Color, Color, Rect,
31  const string &, const string &,
32  bool, Rect *);
33 
34  PlayerText (Formatter *, Media *);
35  ~PlayerText ();
36  void reload () override;
37 
38 protected:
39  bool doSetProperty (Property, const string &, const string &) override;
40 
41 private:
42  struct
43  {
44  Color fontColor;
45  Color fontBgColor;
46  string fontFamily;
47  string fontSize;
48  string fontStyle;
49  string fontVariant;
50  string fontWeight;
51  string horzAlign;
52  string vertAlign;
53  } _prop;
54 };
55 
56 GINGA_NAMESPACE_END
57 
58 #endif // PLAYER_TEXT
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.
Definition: PlayerText.cpp:44
Definition: PlayerText.h:25
Interface between libginga and the external world.
Definition: Formatter.h:37
Definition: Media.h:26
Definition: Player.h:28