<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"> <title>/home/James/ZEngine-dev/include/ZE_ZFont.h Source File</title> <link href="doxygen.css" rel="stylesheet" type="text/css"> </head><body> <!-- Generated by Doxygen 1.3-rc1 --> <center> <a class="qindex" href="index.html">Main Page</a> <a class="qindex" href="namespaces.html">Namespace List</a> <a class="qindex" href="hierarchy.html">Class Hierarchy</a> <a class="qindex" href="annotated.html">Compound List</a> <a class="qindex" href="files.html">File List</a> <a class="qindex" href="namespacemembers.html">Namespace Members</a> <a class="qindex" href="functions.html">Compound Members</a> <a class="qindex" href="globals.html">File Members</a> </center> <hr><h1>/home/James/ZEngine-dev/include/ZE_ZFont.h</h1><a href="ZE__ZFont_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre>00001 <span class="comment">/*******************************************************************************</span> 00002 <span class="comment"> This file is Part of the ZEngine Library for SDL Game Development.</span> 00003 <span class="comment"> Copyright (C) 2002 ConceptOfZero.net</span> 00004 <span class="comment"></span> 00005 <span class="comment"> Licensed under the BSD License, see licensing.txt.</span> 00006 <span class="comment"></span> 00007 <span class="comment"> The maintainer of this library is James Turk (jturk@conceptofzero.net) </span> 00008 <span class="comment"> and the home of this Library is http://www.conceptofzero.net/</span> 00009 <span class="comment">*******************************************************************************/</span> 00010 00024 <span class="preprocessor">#ifndef __ze_zfont_h__</span> 00025 <span class="preprocessor"></span><span class="preprocessor">#define __ze_zfont_h__</span> 00026 <span class="preprocessor"></span> 00027 <span class="preprocessor">#include "<a class="code" href="ZE__ZObject_8h.html">ZE_ZObject.h</a>"</span> 00028 <span class="preprocessor">#include "<a class="code" href="ZE__ZImage_8h.html">ZE_ZImage.h</a>"</span> 00029 00030 <span class="preprocessor">#ifdef USE_SDL_TTF</span> 00031 <span class="preprocessor"></span> 00032 <span class="keyword">namespace </span>ZE 00033 { 00034 00040 <span class="keyword">class </span>ZFont : <span class="keyword">public</span> ZObject 00041 { 00042 <span class="keyword">protected</span>: 00044 FontData <a class="code" href="classZE_1_1ZFont.html#n0">rFont</a>; 00046 SDL_Color <a class="code" href="classZE_1_1ZFont.html#n1">rColor</a>; 00048 SDL_Color <a class="code" href="classZE_1_1ZFont.html#n2">rBGColor</a>; 00049 00050 <span class="keyword">public</span>: 00051 00053 <span class="comment">//Opening and Closing//</span> 00055 <span class="comment"></span> 00061 <span class="comment"></span> <a class="code" href="classZE_1_1ZFont.html#a0">ZFont</a>(); 00062 00070 <a class="code" href="classZE_1_1ZFont.html#a0">ZFont</a>(string filename, <span class="keywordtype">int</span> size); 00071 00077 <a class="code" href="classZE_1_1ZFont.html#a2">~ZFont</a>(); 00078 00086 <span class="keywordtype">void</span> <a class="code" href="classZE_1_1ZFont.html#a3">Open</a>(string filename, <span class="keywordtype">int</span> size); 00087 00093 <span class="keywordtype">void</span> <a class="code" href="classZE_1_1ZFont.html#a4">Release</a>(); 00094 00096 <span class="comment">//Settings and Drawing//</span> 00098 <span class="comment"></span> 00106 <span class="comment"></span> <span class="keywordtype">void</span> <a class="code" href="classZE_1_1ZFont.html#a5">DrawText</a>(string text, ZImage &image); 00107 00115 <span class="keywordtype">void</span> <a class="code" href="classZE_1_1ZFont.html#a6">DrawShadedText</a>(string text, ZImage &image); 00116 00125 <span class="keywordtype">void</span> <a class="code" href="classZE_1_1ZFont.html#a7">SetColor</a>(Uint8 r, Uint8 g, Uint8 b); 00126 00135 <span class="keywordtype">void</span> <a class="code" href="classZE_1_1ZFont.html#a8">SetBGColor</a>(Uint8 r, Uint8 g, Uint8 b); 00136 00145 <span class="keywordtype">void</span> <a class="code" href="classZE_1_1ZFont.html#a9">SetStyle</a>(<span class="keywordtype">bool</span> bold, <span class="keywordtype">bool</span> italic, <span class="keywordtype">bool</span> underline); 00146 00153 <span class="keywordtype">void</span> <a class="code" href="classZE_1_1ZFont.html#a10">Resize</a>(<span class="keywordtype">int</span> size); 00154 00156 <span class="comment">//Accessors//</span> 00158 <span class="comment"></span> 00165 <span class="comment"></span> <span class="keywordtype">bool</span> <a class="code" href="classZE_1_1ZFont.html#a11">IsLoaded</a>(); 00166 00173 <span class="keywordtype">bool</span> <a class="code" href="classZE_1_1ZFont.html#a12">IsBold</a>(); 00174 00181 <span class="keywordtype">bool</span> <a class="code" href="classZE_1_1ZFont.html#a13">IsItalic</a>(); 00182 00189 <span class="keywordtype">bool</span> <a class="code" href="classZE_1_1ZFont.html#a14">IsUnderlined</a>(); 00190 00197 <span class="keywordtype">int</span> <a class="code" href="classZE_1_1ZFont.html#a15">GetHeight</a>(); 00198 00205 <span class="keywordtype">int</span> <a class="code" href="classZE_1_1ZFont.html#a16">GetLineSkip</a>(); 00206 00214 <span class="keywordtype">int</span> <a class="code" href="classZE_1_1ZFont.html#a17">GetStringWidth</a>(string text); 00215 00223 <span class="keywordtype">int</span> <a class="code" href="classZE_1_1ZFont.html#a18">GetStringHeight</a>(string text); 00224 }; 00225 00226 } 00227 00228 <span class="preprocessor">#endif //USE_SDL_TTF</span> 00229 <span class="preprocessor"></span> 00230 <span class="preprocessor">#endif //__ze_zfont_h__</span> </pre></div><hr><address style="align: right;"><small>Generated on Wed Nov 20 01:18:05 2002 for ZEngine by <a href="http://www.doxygen.org/index.html"> <img src="doxygen.png" alt="doxygen" align="middle" border=0 width=110 height=53></a>1.3-rc1 </small></address> </body> </html>