2002-04-15 00:12:54 +00:00
|
|
|
<?xml version="1.0" encoding="iso-8859-1"?>
|
2005-07-22 12:09:30 +00:00
|
|
|
<!-- $Revision: 1.7 $ -->
|
2002-04-15 00:12:54 +00:00
|
|
|
<!-- splitted from ./en/functions/pdf.xml, last change in rev 1.42 -->
|
|
|
|
<refentry id="function.pdf-stringwidth">
|
|
|
|
<refnamediv>
|
|
|
|
<refname>pdf_stringwidth</refname>
|
|
|
|
<refpurpose>Returns width of text using current font</refpurpose>
|
|
|
|
</refnamediv>
|
|
|
|
<refsect1>
|
|
|
|
<title>Description</title>
|
|
|
|
<methodsynopsis>
|
|
|
|
<type>float</type><methodname>pdf_stringwidth</methodname>
|
2003-08-09 04:31:34 +00:00
|
|
|
<methodparam><type>resource</type><parameter>pdfdoc</parameter></methodparam>
|
2002-04-15 00:12:54 +00:00
|
|
|
<methodparam><type>string</type><parameter>text</parameter></methodparam>
|
2004-08-13 12:05:17 +00:00
|
|
|
<methodparam><type>int</type><parameter>font</parameter></methodparam>
|
|
|
|
<methodparam><type>float</type><parameter>size</parameter></methodparam>
|
2002-04-15 00:12:54 +00:00
|
|
|
</methodsynopsis>
|
|
|
|
<para>
|
2005-07-22 12:09:30 +00:00
|
|
|
Returns the width of <parameter>text</parameter> using the parameters
|
|
|
|
<parameter>font</parameter> and <parameter>size</parameter>.
|
|
|
|
Please note that <parameter>font</parameter> is a font handle returned
|
|
|
|
by <function>pdf_findfont</function>.
|
2004-08-13 12:05:17 +00:00
|
|
|
Parameters <parameter>font</parameter> and <parameter>size</parameter>
|
2005-07-22 12:09:30 +00:00
|
|
|
are optional before PHP 4.3.5 or with PDFlib less than 5. If they are
|
|
|
|
not specified, the font set by <function>pdf_setfont</function> is used.
|
2002-04-15 00:12:54 +00:00
|
|
|
</para>
|
|
|
|
<note>
|
|
|
|
<para>
|
|
|
|
Both the <parameter>font</parameter> and <parameter>size</parameter>
|
2003-08-09 04:31:34 +00:00
|
|
|
parameters must be used together.
|
2002-04-15 00:12:54 +00:00
|
|
|
</para>
|
|
|
|
</note>
|
|
|
|
<para>
|
2003-02-22 03:11:45 +00:00
|
|
|
See also
|
|
|
|
<function>pdf_setfont</function> and
|
2002-04-15 00:12:54 +00:00
|
|
|
<function>pdf_findfont</function>.
|
|
|
|
</para>
|
|
|
|
</refsect1>
|
|
|
|
</refentry>
|
|
|
|
|
|
|
|
<!-- Keep this comment at the end of the file
|
|
|
|
Local variables:
|
|
|
|
mode: sgml
|
|
|
|
sgml-omittag:t
|
|
|
|
sgml-shorttag:t
|
|
|
|
sgml-minimize-attributes:nil
|
|
|
|
sgml-always-quote-attributes:t
|
|
|
|
sgml-indent-step:1
|
|
|
|
sgml-indent-data:t
|
|
|
|
indent-tabs-mode:nil
|
|
|
|
sgml-parent-document:nil
|
|
|
|
sgml-default-dtd-file:"../../../../manual.ced"
|
|
|
|
sgml-exposed-tags:nil
|
|
|
|
sgml-local-catalogs:nil
|
|
|
|
sgml-local-ecat-files:nil
|
|
|
|
End:
|
|
|
|
vim600: syn=xml fen fdm=syntax fdl=2 si
|
|
|
|
vim: et tw=78 syn=sgml
|
|
|
|
vi: ts=1 sw=1
|
|
|
|
-->
|