Menu

[r144]: / trunk / htdocs / matplotlib.text.html.template  Maximize  Restore  History

Download this file

148 lines (104 with data), 11.0 kB

@header@
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="heading">
<tr bgcolor="#7799ee">
<td valign=bottom>&nbsp;<br>
<font color="#ffffff" face="helvetica, arial">&nbsp;<br><big><big><strong><a href="matplotlib.html"><font color="#ffffff">matplotlib</font></a>.text</strong></big></big></font></td
><td align=right valign=bottom
><font color="#ffffff" face="helvetica, arial"><a href=".">index</a><br><a href="/matplotlib/text.py">/matplotlib/text.py</a></font></td></tr></table>
    <p><tt>Figure&nbsp;and&nbsp;Axes&nbsp;text</tt></p>
<p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#ee77aa">
<td colspan=3 valign=bottom>&nbsp;<br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Classes</strong></big></font></td></tr>
    
<tr><td bgcolor="#ee77aa"><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
<td width="100%"><dl>
<dt><font face="helvetica, arial"><a href="matplotlib.artist.html#Artist">matplotlib.artist.Artist</a>
</font></dt><dd>
<dl>
<dt><font face="helvetica, arial"><a href="matplotlib.text.html#Text">Text</a>
</font></dt></dl>
</dd>
</dl>
 <p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#ffc8d8">
<td colspan=3 valign=bottom>&nbsp;<br>
<font color="#000000" face="helvetica, arial"><a name="Text">class <strong>Text</strong></a>(<a href="matplotlib.artist.html#Artist">matplotlib.artist.Artist</a>)</font></td></tr>
    
<tr bgcolor="#ffc8d8"><td rowspan=2><tt>&nbsp;&nbsp;&nbsp;</tt></td>
<td colspan=2><tt>Handle&nbsp;storing&nbsp;and&nbsp;drawing&nbsp;of&nbsp;text&nbsp;in&nbsp;window&nbsp;or&nbsp;data&nbsp;coordinates<br>
&nbsp;<br>
Publicly&nbsp;accessible&nbsp;attributes<br>
&nbsp;&nbsp;dpi&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:&nbsp;a&nbsp;DPI&nbsp;instance<br>
&nbsp;&nbsp;bbox&nbsp;&nbsp;&nbsp;&nbsp;:&nbsp;the&nbsp;display&nbsp;bounding&nbsp;box&nbsp;Bound2D&nbsp;instance<br>
&nbsp;&nbsp;transx&nbsp;:&nbsp;the&nbsp;transform&nbsp;of&nbsp;the&nbsp;x&nbsp;data<br>
&nbsp;&nbsp;transy&nbsp;:&nbsp;the&nbsp;transform&nbsp;of&nbsp;the&nbsp;y&nbsp;data<br>&nbsp;</tt></td></tr>
<tr><td>&nbsp;</td>
<td width="100%">Methods defined here:<br>
<dl><dt><a name="Text-__init__"><strong>__init__</strong></a>(self, dpi, bbox, x<font color="#909090">=0</font>, y<font color="#909090">=0</font>, text<font color="#909090">=''</font>, color<font color="#909090">='k'</font>, verticalalignment<font color="#909090">='bottom'</font>, horizontalalignment<font color="#909090">='left'</font>, fontname<font color="#909090">='Times'</font>, fontsize<font color="#909090">=10</font>, fontweight<font color="#909090">='normal'</font>, fontangle<font color="#909090">='normal'</font>, rotation<font color="#909090">=None</font>, transx<font color="#909090">=Transform: Bound1D: 0 1 to Bound1D: 0 1</font>, transy<font color="#909090">=Transform: Bound1D: 0 1 to Bound1D: 0 1</font>)</dt></dl>

<dl><dt><a name="Text-copy_properties"><strong>copy_properties</strong></a>(self, text)</dt></dl>

<dl><dt><a name="Text-get_color"><strong>get_color</strong></a>(self)</dt><dd><tt>Return&nbsp;the&nbsp;color&nbsp;of&nbsp;the&nbsp;text</tt></dd></dl>

<dl><dt><a name="Text-get_fontangle"><strong>get_fontangle</strong></a>(self)</dt><dd><tt>Get&nbsp;the&nbsp;font&nbsp;angle&nbsp;as&nbsp;string</tt></dd></dl>

<dl><dt><a name="Text-get_fontname"><strong>get_fontname</strong></a>(self)</dt><dd><tt>Return&nbsp;the&nbsp;font&nbsp;name&nbsp;as&nbsp;string</tt></dd></dl>

<dl><dt><a name="Text-get_fontsize"><strong>get_fontsize</strong></a>(self)</dt><dd><tt>Return&nbsp;the&nbsp;font&nbsp;size&nbsp;as&nbsp;integer</tt></dd></dl>

<dl><dt><a name="Text-get_fontweight"><strong>get_fontweight</strong></a>(self)</dt><dd><tt>Get&nbsp;the&nbsp;font&nbsp;weight&nbsp;as&nbsp;string</tt></dd></dl>

<dl><dt><a name="Text-get_horizontalalignment"><strong>get_horizontalalignment</strong></a>(self)</dt><dd><tt>Return&nbsp;the&nbsp;horizontal&nbsp;alignment&nbsp;as&nbsp;string</tt></dd></dl>

<dl><dt><a name="Text-get_position"><strong>get_position</strong></a>(self)</dt><dd><tt>Return&nbsp;x,&nbsp;y&nbsp;as&nbsp;tuple</tt></dd></dl>

<dl><dt><a name="Text-get_prop_tup"><strong>get_prop_tup</strong></a>(self)</dt><dd><tt>Return&nbsp;a&nbsp;hashable&nbsp;tuple&nbsp;of&nbsp;properties<br>
&nbsp;<br>
Not&nbsp;intended&nbsp;to&nbsp;be&nbsp;human&nbsp;readable,&nbsp;but&nbsp;useful&nbsp;for&nbsp;backends&nbsp;who<br>
want&nbsp;to&nbsp;cache&nbsp;derived&nbsp;information&nbsp;about&nbsp;text&nbsp;(eg&nbsp;layouts)&nbsp;and<br>
need&nbsp;to&nbsp;know&nbsp;if&nbsp;the&nbsp;text&nbsp;has&nbsp;changed</tt></dd></dl>

<dl><dt><a name="Text-get_rotation"><strong>get_rotation</strong></a>(self)</dt><dd><tt>Return&nbsp;the&nbsp;text&nbsp;rotation&nbsp;arg</tt></dd></dl>

<dl><dt><a name="Text-get_text"><strong>get_text</strong></a>(self)</dt><dd><tt>Get&nbsp;the&nbsp;text&nbsp;as&nbsp;string</tt></dd></dl>

<dl><dt><a name="Text-get_verticalalignment"><strong>get_verticalalignment</strong></a>(self)</dt><dd><tt>Return&nbsp;the&nbsp;vertical&nbsp;alignment&nbsp;as&nbsp;string</tt></dd></dl>

<dl><dt><a name="Text-get_window_extent"><strong>get_window_extent</strong></a>(self, renderer)</dt><dd><tt>Return&nbsp;the&nbsp;bounding&nbsp;box&nbsp;of&nbsp;the&nbsp;text&nbsp;in&nbsp;window&nbsp;coords&nbsp;as&nbsp;a<br>
Bound2D&nbsp;instance</tt></dd></dl>

<dl><dt><a name="Text-get_xy_display"><strong>get_xy_display</strong></a>(self)</dt></dl>

<dl><dt><a name="Text-set_backgroundcolor"><strong>set_backgroundcolor</strong></a>(self, color)</dt><dd><tt>Set&nbsp;the&nbsp;background&nbsp;color&nbsp;of&nbsp;the&nbsp;text</tt></dd></dl>

<dl><dt><a name="Text-set_color"><strong>set_color</strong></a>(self, color)</dt><dd><tt>Set&nbsp;the&nbsp;foreground&nbsp;color&nbsp;of&nbsp;the&nbsp;text</tt></dd></dl>

<dl><dt><a name="Text-set_fontangle"><strong>set_fontangle</strong></a>(self, angle)</dt><dd><tt>Set&nbsp;the&nbsp;font&nbsp;angle,&nbsp;one&nbsp;of&nbsp;'normal',&nbsp;'italic',&nbsp;'oblique'</tt></dd></dl>

<dl><dt><a name="Text-set_fontname"><strong>set_fontname</strong></a>(self, fontname)</dt><dd><tt>Set&nbsp;the&nbsp;font&nbsp;name,&nbsp;eg,&nbsp;'Sans',&nbsp;'Courier',&nbsp;'Helvetica'</tt></dd></dl>

<dl><dt><a name="Text-set_fontsize"><strong>set_fontsize</strong></a>(self, fontsize)</dt><dd><tt>Set&nbsp;the&nbsp;font&nbsp;size,&nbsp;eg,&nbsp;8,&nbsp;10,&nbsp;12,&nbsp;14...</tt></dd></dl>

<dl><dt><a name="Text-set_fontweight"><strong>set_fontweight</strong></a>(self, weight)</dt><dd><tt>Set&nbsp;the&nbsp;font&nbsp;weight,&nbsp;one&nbsp;of:<br>
'normal',&nbsp;'bold',&nbsp;'heavy',&nbsp;'light',&nbsp;'ultrabold',&nbsp;&nbsp;'ultralight'</tt></dd></dl>

<dl><dt><a name="Text-set_horizontalalignment"><strong>set_horizontalalignment</strong></a>(self, align)</dt><dd><tt>Set&nbsp;the&nbsp;horizontal&nbsp;alignment&nbsp;to&nbsp;one&nbsp;of<br>
'center',&nbsp;'right',&nbsp;or&nbsp;'left'</tt></dd></dl>

<dl><dt><a name="Text-set_position"><strong>set_position</strong></a>(self, xy)</dt></dl>

<dl><dt><a name="Text-set_rotation"><strong>set_rotation</strong></a>(self, s)</dt><dd><tt>Currently&nbsp;only&nbsp;s='vertical',&nbsp;or&nbsp;s='horizontal'&nbsp;are&nbsp;supported</tt></dd></dl>

<dl><dt><a name="Text-set_text"><strong>set_text</strong></a>(self, text)</dt><dd><tt>Set&nbsp;the&nbsp;text</tt></dd></dl>

<dl><dt><a name="Text-set_transx"><strong>set_transx</strong></a>(self, trans)</dt><dd><tt>Set&nbsp;the&nbsp;x&nbsp;transform</tt></dd></dl>

<dl><dt><a name="Text-set_transy"><strong>set_transy</strong></a>(self, trans)</dt><dd><tt>Set&nbsp;the&nbsp;y&nbsp;transform</tt></dd></dl>

<dl><dt><a name="Text-set_verticalalignment"><strong>set_verticalalignment</strong></a>(self, align)</dt><dd><tt>Set&nbsp;the&nbsp;vertical&nbsp;alignment&nbsp;to&nbsp;one&nbsp;of<br>
'center',&nbsp;'top',&nbsp;or&nbsp;'bottom'</tt></dd></dl>

<dl><dt><a name="Text-set_x"><strong>set_x</strong></a>(self, x)</dt></dl>

<dl><dt><a name="Text-set_y"><strong>set_y</strong></a>(self, y)</dt></dl>

<dl><dt><a name="Text-update_properties"><strong>update_properties</strong></a>(self, d)</dt><dd><tt>Update&nbsp;the&nbsp;font&nbsp;attributes&nbsp;with&nbsp;the&nbsp;dictionary&nbsp;in&nbsp;d</tt></dd></dl>

<hr>
Methods inherited from <a href="matplotlib.artist.html#Artist">matplotlib.artist.Artist</a>:<br>
<dl><dt><a name="Text-draw"><strong>draw</strong></a>(self, renderer<font color="#909090">=None</font>, *args, **kwargs)</dt><dd><tt>Derived&nbsp;classes&nbsp;drawing&nbsp;method</tt></dd></dl>

<dl><dt><a name="Text-get_alpha"><strong>get_alpha</strong></a>(self)</dt><dd><tt>Return&nbsp;the&nbsp;alpha&nbsp;value&nbsp;used&nbsp;for&nbsp;blending&nbsp;-&nbsp;not&nbsp;supported&nbsp;on<br>
all&nbsp;backends</tt></dd></dl>

<dl><dt><a name="Text-get_child_artists"><strong>get_child_artists</strong></a>(self)</dt><dd><tt>Return&nbsp;all&nbsp;artists&nbsp;contained&nbsp;in&nbsp;self</tt></dd></dl>

<dl><dt><a name="Text-get_clip_on"><strong>get_clip_on</strong></a>(self)</dt><dd><tt>Return&nbsp;whether&nbsp;artist&nbsp;uses&nbsp;clipping</tt></dd></dl>

<dl><dt><a name="Text-get_dpi"><strong>get_dpi</strong></a>(self)</dt><dd><tt>Get&nbsp;the&nbsp;DPI&nbsp;of&nbsp;the&nbsp;display</tt></dd></dl>

<dl><dt><a name="Text-set_alpha"><strong>set_alpha</strong></a>(self, alpha)</dt><dd><tt>Set&nbsp;the&nbsp;alpha&nbsp;value&nbsp;used&nbsp;for&nbsp;blending&nbsp;-&nbsp;not&nbsp;supported&nbsp;on<br>
all&nbsp;backends</tt></dd></dl>

<dl><dt><a name="Text-set_child_attr"><strong>set_child_attr</strong></a>(self, attr, val)</dt><dd><tt>Set&nbsp;attribute&nbsp;attr&nbsp;for&nbsp;self,&nbsp;and&nbsp;all&nbsp;child&nbsp;artists</tt></dd></dl>

<dl><dt><a name="Text-set_clip_on"><strong>set_clip_on</strong></a>(self, b)</dt><dd><tt>Set&nbsp;whether&nbsp;artist&nbsp;is&nbsp;clipped&nbsp;to&nbsp;bbox</tt></dd></dl>

<dl><dt><a name="Text-set_lod"><strong>set_lod</strong></a>(self, on)</dt><dd><tt>Set&nbsp;Level&nbsp;of&nbsp;Detail&nbsp;on&nbsp;or&nbsp;off.&nbsp;&nbsp;If&nbsp;on,&nbsp;the&nbsp;artists&nbsp;may&nbsp;examine<br>
things&nbsp;like&nbsp;the&nbsp;pixel&nbsp;width&nbsp;of&nbsp;the&nbsp;axes&nbsp;and&nbsp;draw&nbsp;a&nbsp;subset&nbsp;of<br>
their&nbsp;contents&nbsp;accordingly</tt></dd></dl>

<hr>
Data and other attributes inherited from <a href="matplotlib.artist.html#Artist">matplotlib.artist.Artist</a>:<br>
<dl><dt><strong>aname</strong> = 'Artist'</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>&nbsp;<br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
    
<tr><td bgcolor="#55aa55"><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
<td width="100%"><strong>False</strong> = False<br>
<strong>True</strong> = True<br>
<strong>division</strong> = _Feature((2, 2, 0, 'alpha', 2), (3, 0, 0, 'alpha', 0), 8192)</td></tr></table>
@footer@
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.