:orphan:

=============
TKE_Text_Font
=============

Opcode
======

.. csv-table::

	"ASCII", "F"
	"Hexadecimal", "46"
	"Decimal", "70"


Operands
========

| Byte mask, Byte value, [Byte mask_high, Byte value_high]
| [Word mask_high2, Word value_high2]
| [Byte names_length], [(names_length)xByte names],
| [Float size, Byte size_units],
| [Float size_tolerance, Byte tolerance_units],
| [Byte transforms], [Float rotation], [Float slant], [Float width_scale],
| [Float extra_space, Byte extra_space_units], [Float line_spacing],
| [Float greeking_limit,  Byte greeking_limit_units],
| [Byte greeking_mode],
| [Byte renderer] 

.. raw:: html

	<table BORDER =1 WIDTH="530">
	  <TR> 
		<TD height=21 width=131>mask</TD>
		<TD height=21 width=390>bitmask of options.</TD>
	  </TR>
	  <TR> 
		<TD height=21 width=131>value</TD>
		<TD height=21 width=390>bitmask indicating which options are set <em>on</em>.</TD>
	  </TR>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">mask_high</td>
		<td WIDTH="390" HEIGHT="21">if high bit is set in the first <em>mask</em> 
		  byte, this set of bits is added to <em>mask</em>.</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">value_high</td>
		<td WIDTH="390" HEIGHT="21">if high bit is set in the first <em>mask</em> 
		  byte, this set of bits is added to <em>value</em>.</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">mask_high2</td>
		<td WIDTH="390" HEIGHT="21">if high bit is set in the second <em>mask</em> 
		  byte, this set of bits is added to <em>mask</em>.</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">value_high2</td>
		<td WIDTH="390" HEIGHT="21">if high bit is set in the second <em>mask</em> 
		  byte, this set of bits is added to <em>value</em>.</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">names_length</td>
		<td WIDTH="390" HEIGHT="21">length of names string</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">names</td>
		<td WIDTH="390" HEIGHT="21">one or more font names to attempt to use</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">size</td>
		<td WIDTH="390" HEIGHT="21">desired size of text</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">size_units</td>
		<td WIDTH="390" HEIGHT="21">enumeration describing how size is interpreted</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">size_tolerance</td>
		<td WIDTH="390" HEIGHT="21">indicates acceptable size difference for fixed-size 
		  bitmap fonts</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">tolerance_units</td>
		<td WIDTH="390" HEIGHT="21">enumeration describing how tolerance is interpreted</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">transforms</td>
		<td WIDTH="390" HEIGHT="21">enumeration indicating how text string is 
		  affected by modelling matrix</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">rotation</td>
		<td WIDTH="390" HEIGHT="21">rotation of characters relative to the horizontal 
		  (in degrees). value of -1 indicates characters are rotated to lie along 
		  the text path</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">slant</td>
		<td WIDTH="390" HEIGHT="21">amount of slant applied to characters (in 
		  degrees)</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">width_scale</td>
		<td WIDTH="390" HEIGHT="21">horizontal scaling applied to the entire text 
		  string</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">extra_space</td>
		<td WIDTH="390" HEIGHT="21">additional space added between characters</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">extra_space_units</td>
		<td WIDTH="390" HEIGHT="21">enumeration describing how extra space is 
		  interpreted</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">line_spacing</td>
		<td WIDTH="390" HEIGHT="21">distance between baseline of multi-line strings, 
		  as a multiple of the font height</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">greeking_limit</td>
		<td WIDTH="390" HEIGHT="21">limit below which text may be replaced by 
		  simple geometry</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">greeking_limit_units</td>
		<td WIDTH="390" HEIGHT="21">enumeration describing how greeking limit 
		  is interpreted</td>
	  </tr>
	  <tr> 
		<td height="21" width="131"> greeking_mode</td>
		<td height="21" width="390"> enumeration describing to handle text below 
		  the greeking limit</td>
	  </tr>
	  <tr> 
		<td WIDTH="131" HEIGHT="21">renderer</td>
		<td WIDTH="390" HEIGHT="21">enumeration describing limitation on font 
		  type</td>
	  </tr>
	</table>
	
	
Notes
=====

Text attributes which are set on the currently open segment.&nbsp; These attributes are applied to any text that lies in this part of the segment tree.
  
  
Mask/value bits
---------------

.. raw:: html

	<table BORDER =1 WIDTH="500">
	  <TR> 
		<TD height=21 width=50>00000001</TD>
		<TD height=21 width=390>Names</TD>
	  </TR>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00000002</td>
		<td WIDTH=390 HEIGHT=21>Size</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00000004</td>
		<td WIDTH=390 HEIGHT=21>Size Tolerance</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00000008</td>
		<td WIDTH=390 HEIGHT=21>Transforms</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00000010</td>
		<td WIDTH=390 HEIGHT=21>Rotation</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00000020</td>
		<td WIDTH=390 HEIGHT=21>Slant</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00000040</td>
		<td WIDTH=390 HEIGHT=21>Width_Scale</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00000080</td>
		<td WIDTH=390 HEIGHT=21>second byte required</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00000100</td>
		<td WIDTH=390 HEIGHT=21>Extra Space</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00000200</td>
		<td WIDTH=390 HEIGHT=21>Line Spacing</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00000400</td>
		<td WIDTH=390 HEIGHT=21>Outline preferred</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00000800</td>
		<td WIDTH=390 HEIGHT=21>Underline preferred</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00001000</td>
		<td WIDTH=390 HEIGHT=21>Strikethrough preferred</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00002000</td>
		<td WIDTH=390 HEIGHT=21>Overline preferred</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00004000</td>
		<td WIDTH=390 HEIGHT=21>Force non-proportional spacing</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00008000</td>
		<td WIDTH=390 HEIGHT=21>second word required</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00010000</td>
		<td WIDTH=390 HEIGHT=21>Greeking Limit</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00020000</td>
		<td WIDTH=390 HEIGHT=21>Fill Edges</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00040000</td>
		<td WIDTH=390 HEIGHT=21>Bold desired</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00080000</td>
		<td WIDTH=390 HEIGHT=21>Italic desired</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>00100000</td>
		<td WIDTH=390 HEIGHT=21>Renderer specified</td>
	  </tr>
	  <tr> 
		<td height="21" width="50"> 00200000</td>
		<td height="21" width="390"> Greeking Mode specified</td>
	  </tr>
	</table>


Size units options
------------------

.. raw:: html

	<table BORDER =1 WIDTH="500">
	  <TR> 
		<TD height=21 width=50>0</TD>
		<TD height=21 width=390>Object space size</TD>
	  </TR>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>1</td>
		<td WIDTH=390 HEIGHT=21>Screen space size</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>2</td>
		<td WIDTH=390 HEIGHT=21>Window space size</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>3</td>
		<td WIDTH=390 HEIGHT=21>Points</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>4</td>
		<td WIDTH=390 HEIGHT=21>Pixels</td>
	  </tr>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>5</td>
		<td WIDTH=390 HEIGHT=21>Percentage (only used for Size Tolerance)</td>
	  </tr>
	</table>


Transform options
-----------------

.. raw:: html

	<table BORDER =1 WIDTH="500">
	  <TR> 
		<TD height=21 width=50>0</TD>
		<TD height=21 width=390>Only position of each character is transformed</TD>
	  </TR>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>1</td>
		<td WIDTH=390 HEIGHT=21>Entire character glyphs are transformed</td>
	  </tr>
	</table>


Greeking mode options
---------------------

.. raw:: html

	<table border="1" width="500">
	  <tr> 
		<td height="21" width="50"> 0</td>
		<td height="21" width="390"> Greeked text is not drawn</td>
	  </tr>
	  <tr> 
		<td height="21" width="50"> 1</td>
		<td height="21" width="390"> Greeked text is replaced with a simple grid 
		  of lines</td>
	  </tr>
	  <tr> 
		<td height="21" width="50"> 2</td>
		<td height="21" width="390"> Greeked text is replaced with a halftone 
		  filled box</td>
	  </tr>
	</table>
	
	
Renderer options
----------------

.. raw:: html

	<table BORDER =1 WIDTH="500">
	  <TR> 
		<TD height=21 width=50>0</TD>
		<TD height=21 width=390>Use any available fonts</TD>
	  </TR>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>1</td>
		<td WIDTH=390 HEIGHT=21>Limit choices to driver-specific fonts</td>
	  </tr>
	  <TR> 
		<TD height=21 width=50>2</TD>
		<TD height=21 width=390>Limit choices to Truetype (or similar, such as 
		  Type1) fonts</TD>
	  </TR>
	  <tr> 
		<td WIDTH=50 HEIGHT=21>3</td>
		<td WIDTH=390 HEIGHT=21>Limit choices to Defined (stroked) fonts</td>
	  </tr>
	</table>
