Sophie

Sophie

distrib > Mageia > 7 > i586 > media > core-release > by-pkgid > a2116f36018873d572acbcadddb8e994 > files > 952

clanlib0.8-docs-0.8.1-22.mga7.i586.rpm


<!-- clanlib header begin -->
<HTML>
<HEAD>
<TITLE>CL_Font::get_width - ClanLib Game SDK</TITLE>
<STYLE TYPE="text/css"><!--
HTML BODY
{
	font-family: verdana, helvetica, sans-serif;
	font-size: 12px;
}
H1 { font-size: 22px; }
H2 { font-size: 18px; }
H3 { font-size: 16px; }
H4 { font-size: 14px; }
P { font-size: 12px; }
LI { font-size: 12px; }
--></STYLE>
</HEAD>

<body bgcolor=white text=black link=blue vlink=#800080>

<center>
<img src="http://clanlib.org/gfx/clanlib.png">
</center>
<!-- clanlib header end -->

<center>
<p>
<a href="http://clanlib.org/docs.html">Home</a> |
<a href="classes.html">All Classes</a> |
<a href="modules.html">Grouped Classes</a> |
<a href="index.html">Index</a> |
<a href="search.html">Search</a>
</p>
</center>
<h1>CL_Font::get_width</h1>
<p>  Returns the drawn width of a character or string.</p>
<pre>
	int get_width(
		unsigned int letter);

	int get_width(
		const std::string& str, CL_Size max_size = CL_Size(0, 0));

	int get_width(
		std::string::const_iterator start, std::string::const_iterator end, CL_Size max_size = CL_Size(0, 0));
</pre>
<p><b>Parameters:</b></p>
<dl>
<dt><i>letter</i></dt><dd>Character to get the width of.</dd>
<dt><i>str</i></dt><dd>String to get the width of.</dd>
<dt><i>start</i></dt><dd>A starting iterator, inclusive.</dd>
<dt><i>end</i></dt><dd>An ending iterator, exclusive.</dd>
<dt><i>max_size</i></dt><dd>Same effect as the size of the dest rectangle passed to draw(), for word wrapping and height truncating.</dd>
</dl>
<p><b>Return value:</b></p>
<p>The width in pixels.<br></p>
<p><b>See also:</b></p>
<p><a href="CL_Font.html">CL_Font</a> | <a href="CL_Size.html">CL_Size</a></p>


<!-- clanlib footer begin -->

<center><br><br><font color="#a0a0a0">
Questions or comments, write to the <a href="http://clanlib.org/contact.html">ClanLib mailing list</a>.
</font></center>

</body>
</html>
<!-- clanlib footer end -->