aboutsummaryrefslogtreecommitdiff
path: root/graphics
diff options
context:
space:
mode:
authorKamil Zbróg2013-12-09 19:03:42 +0000
committerKamil Zbróg2013-12-09 19:03:42 +0000
commit7add223d859ae270834cafa5eaac2fb5d5a6bb50 (patch)
treeee6551d2d7de3c0e07ffb86d7453691f815b1757 /graphics
parent8e772f936c43a68e4ae7c68b178bd9fa3a3e4f1f (diff)
parent8a936200037e6d97212a4d0ad6a710c87cc15b58 (diff)
downloadscummvm-rg350-7add223d859ae270834cafa5eaac2fb5d5a6bb50.tar.gz
scummvm-rg350-7add223d859ae270834cafa5eaac2fb5d5a6bb50.tar.bz2
scummvm-rg350-7add223d859ae270834cafa5eaac2fb5d5a6bb50.zip
Merge remote-tracking branch 'sync/master' into prince-malik
Diffstat (limited to 'graphics')
-rw-r--r--graphics/fonts/ttf.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/graphics/fonts/ttf.h b/graphics/fonts/ttf.h
index e1464b1f45..65aba32fbf 100644
--- a/graphics/fonts/ttf.h
+++ b/graphics/fonts/ttf.h
@@ -32,6 +32,24 @@
namespace Graphics {
class Font;
+
+/**
+ * Loads a TTF font file from a given data stream object.
+ *
+ * @param stream Stream object to load font data from.
+ * @param size The point size to load.
+ * @param dpi The dpi to use for size calculations, by default 72dpi
+ * are used.
+ * @param monochrome Whether the font should be loaded in pure monochrome
+ * mode. In case this is true no aliasing is used.
+ * @param mapping A mapping from code points 0-255 into UTF-32 code points.
+ * This can be used to support various 8bit character sets.
+ * In case the msb of the UTF-32 code point is set the font
+ * loading fails in case no glyph for it is found. When this
+ * is non-null only characters given in the mapping are
+ * supported.
+ * @return 0 in case loading fails, otherwise a pointer to the Font object.
+ */
Font *loadTTFFont(Common::SeekableReadStream &stream, int size, uint dpi = 0, bool monochrome = false, const uint32 *mapping = 0);
void shutdownTTF();