79 lines
6.3 KiB
HTML
79 lines
6.3 KiB
HTML
|
|
<!doctype html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
|
<html><head><title>Python: module robofab.tools.proof</title>
|
|
</head><body bgcolor="#f0f0f8">
|
|
|
|
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="heading">
|
|
<tr bgcolor="#7799ee">
|
|
<td valign=bottom> <br>
|
|
<font color="#ffffff" face="helvetica, arial"> <br><big><big><strong><a href="robofab.html"><font color="#ffffff">robofab</font></a>.<a href="robofab.tools.html"><font color="#ffffff">tools</font></a>.proof</strong></big></big></font></td
|
|
><td align=right valign=bottom
|
|
><font color="#ffffff" face="helvetica, arial"><a href=".">index</a><br><a href="file:/code/projects/robofab/Lib/robofab/tools/proof.py">/code/projects/robofab/Lib/robofab/tools/proof.py</a></font></td></tr></table>
|
|
<p><tt>This is the place for stuff that makes proofs and test text settings etc</tt></p>
|
|
<p>
|
|
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
|
<tr bgcolor="#aa55cc">
|
|
<td colspan=3 valign=bottom> <br>
|
|
<font color="#fffff" face="helvetica, arial"><big><strong>Modules</strong></big></font></td></tr>
|
|
|
|
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
|
|
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="string.html">string</a><br>
|
|
</td><td width="25%" valign=top></td><td width="25%" valign=top></td><td width="25%" valign=top></td></tr></table></td></tr></table><p>
|
|
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
|
<tr bgcolor="#ee77aa">
|
|
<td colspan=3 valign=bottom> <br>
|
|
<font color="#ffffff" face="helvetica, arial"><big><strong>Classes</strong></big></font></td></tr>
|
|
|
|
<tr><td bgcolor="#ee77aa"><tt> </tt></td><td> </td>
|
|
<td width="100%"><dl>
|
|
<dt><font face="helvetica, arial"><a href="robofab.tools.proof.html#IDTaggedText">IDTaggedText</a>
|
|
</font></dt></dl>
|
|
<p>
|
|
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
|
<tr bgcolor="#ffc8d8">
|
|
<td colspan=3 valign=bottom> <br>
|
|
<font color="#000000" face="helvetica, arial"><a name="IDTaggedText">class <strong>IDTaggedText</strong></a></font></td></tr>
|
|
|
|
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
|
<td colspan=2><tt>Export a text as a XML tagged text file for InDesign (2.0?).<br>
|
|
The tags can contain information about<br>
|
|
- family: font family i.e. "Times"<br>
|
|
- weight: font weight "Bold"<br>
|
|
- size: typesize in points<br>
|
|
- leading: leading in points<br>
|
|
- color: a CMYK color, as a 4 tuple of floats between 0 and 1<br>
|
|
- insert special glyphs based on glyphindex<br>
|
|
(which is why it only makes sense if you use this in FontLab,<br>
|
|
otherwise there is no other way to get the indices)<br> </tt></td></tr>
|
|
<tr><td> </td>
|
|
<td width="100%">Methods defined here:<br>
|
|
<dl><dt><a name="IDTaggedText-__init__"><strong>__init__</strong></a>(self, family, weight, size<font color="#909090">=36</font>, leading<font color="#909090">=None</font>)</dt></dl>
|
|
|
|
<dl><dt><a name="IDTaggedText-add"><strong>add</strong></a>(self, text)</dt><dd><tt>Method to add text to the file.</tt></dd></dl>
|
|
|
|
<dl><dt><a name="IDTaggedText-addGlyph"><strong>addGlyph</strong></a>(self, index)</dt><dd><tt>Add a special glyph, index is the glyphIndex in an OpenType font.</tt></dd></dl>
|
|
|
|
<dl><dt><a name="IDTaggedText-addHeader"><strong>addHeader</strong></a>(self)</dt><dd><tt>Add the standard header.</tt></dd></dl>
|
|
|
|
<dl><dt><a name="IDTaggedText-addStyle"><strong>addStyle</strong></a>(self, family<font color="#909090">=None</font>, weight<font color="#909090">=None</font>, size<font color="#909090">=None</font>, leading<font color="#909090">=None</font>, color<font color="#909090">=None</font>)</dt><dd><tt>Set the paragraph style for the following text.</tt></dd></dl>
|
|
|
|
<dl><dt><a name="IDTaggedText-charToGlyph"><strong>charToGlyph</strong></a>(self, text)</dt></dl>
|
|
|
|
<dl><dt><a name="IDTaggedText-replace"><strong>replace</strong></a>(self, old, new)</dt><dd><tt>Replace occurances of 'old' with 'new' in all content.</tt></dd></dl>
|
|
|
|
<dl><dt><a name="IDTaggedText-save"><strong>save</strong></a>(self, path)</dt><dd><tt>Save the tagged text here.</tt></dd></dl>
|
|
|
|
</td></tr></table></td></tr></table><p>
|
|
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
|
<tr bgcolor="#55aa55">
|
|
<td colspan=3 valign=bottom> <br>
|
|
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
|
|
|
|
<tr><td bgcolor="#55aa55"><tt> </tt></td><td> </td>
|
|
<td width="100%"><strong>autoLinespaceFactor</strong> = 1.2<br>
|
|
<strong>idColor</strong> = r'<cColor:COLOR\:%(model)s\:Process\:%(c)f\,%(m)f\,%(y)f\,%(k)f>'<br>
|
|
<strong>idGlyphStyle</strong> = '<cTypeface:%(weight)s><cSize:%(size)f><cLeading:%(leading)f><cFont:%(family)s>'<br>
|
|
<strong>idHeader</strong> = '<ASCII-MAC><font color="#c040c0">\n</font><Version:2.000000><FeatureSet:InDesi...MYK:Process:0.000000,0.000000,0.000000,1.000000>>'<br>
|
|
<strong>idParaStyle</strong> = '<ParaStyle:><cTypeface:%(weight)s><cSize:%(size)f><cLeading:%(leading)f><cFont:%(family)s>'<br>
|
|
<strong>seperator</strong> = ''</td></tr></table>
|
|
</body></html> |