Sophie

Sophie

distrib > Mandriva > 9.1 > ppc > media > main > by-pkgid > ca81b57b553ae75608ba0fc5e7925e4e > files > 426

libgtkmm1.2-devel-1.2.10-1mdk.ppc.rpm

<html>
<head><title>Gtk-- Reference: Gtk::Text</title></head>

<body bgcolor="#F0F0F0" text="#000000" link="#0000FF"
vlink="#000077" alink="#FF0000">
<table align=center border=0 cellspacing=10> <tr>
<td><a href="class_index.html">Class Index</a></td>
<td><a href="cross_index.html">Cross Index</a></td>
<td><a href="name_index.html">Namespace Index</a></td>
</table>
<h1 align=center>Class Gtk::Text</h1><p>
<b>  Text widget which allows display and manipulation of arbitrary text.</b><br>
Contained in: <a href="Gtk.html">Gtk</a><br>
Derived from:
<a href="Gtk%3A%3AEditable.html">Gtk::Editable</a>
<br>
Derived by:
<i>none</i>
<p>
#include &lt;gtk--/text.h&gt;
<p>
<hr noshade>
<table border=0>
<tr><td colspan=3><h3>public function member index:</h3></td>
<tr valign=top><td align=right><tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2949"><tt><font color=blue><b>Text</b></font></tt></a></td><td><tt>(<a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>& <tt><font color=blue>hadj</font></tt>, <a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>& <tt><font color=blue>vadj</font></tt>)</tt>;</td>
<tr valign=top><td align=right><tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2950"><tt><font color=blue><b>Text</b></font></tt></a></td><td><tt>()</tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>gint</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2967"><tt><font color=blue><b>backward_delete</b></font></tt></a></td><td><tt>(<tt><font color=purple>guint</font></tt> <tt><font color=blue>nchars</font></tt>)</tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>gint</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2968"><tt><font color=blue><b>forward_delete</b></font></tt></a></td><td><tt>(<tt><font color=purple>guint</font></tt> <tt><font color=blue>nchars</font></tt>)</tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>void</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2961"><tt><font color=blue><b>freeze</b></font></tt></a></td><td><tt>()</tt>;</td>
<tr valign=top><td align=right><tt><a href="Gtk%3A%3AText.html#2964">Context</a></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2971"><tt><font color=blue><b>get_context</b></font></tt></a></td><td><tt>() <tt>const</tt></tt>;</td>
<tr valign=top><td align=right><tt><a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>*</tt> </td><td align=right><a href="Gtk%3A%3AText.html#2956"><tt><font color=blue><b>get_hadjustment</b></font></tt></a></td><td><tt>() <tt>const</tt></tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>guint</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2960"><tt><font color=blue><b>get_length</b></font></tt></a></td><td><tt>() <tt>const</tt></tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>guint</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2959"><tt><font color=blue><b>get_point</b></font></tt></a></td><td><tt>() <tt>const</tt></tt>;</td>
<tr valign=top><td align=right><tt><a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>*</tt> </td><td align=right><a href="Gtk%3A%3AText.html#2957"><tt><font color=blue><b>get_vadjustment</b></font></tt></a></td><td><tt>() <tt>const</tt></tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=navy>GtkText</font></tt>*</tt> </td><td align=right><a href="Gtk%3A%3AText.html#2945"><tt><font color=blue><b>gtkobj</b></font></tt></a></td><td><tt>()</tt>;</td>
<tr valign=top><td align=right><tt><tt>const</tt> <tt><font color=navy>GtkText</font></tt>*</tt> </td><td align=right><a href="Gtk%3A%3AText.html#2946"><tt><font color=blue><b>gtkobj</b></font></tt></a></td><td><tt>() <tt>const</tt></tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>void</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2963"><tt><font color=blue><b>insert</b></font></tt></a></td><td><tt>(<tt>const</tt> <tt><font color=navy>Gdk_Font</font></tt>& <tt><font color=blue>font</font></tt>, <tt>const</tt> <tt><font color=navy>Gdk_Color</font></tt>& <tt><font color=blue>fore</font></tt>, <tt>const</tt> <tt><font color=navy>Gdk_Color</font></tt>& <tt><font color=blue>back</font></tt>, <tt>const</tt> <a href="Gtk%3A%3Anstring.html"><tt><font color=navy><b>nstring</b></font></tt></a>& <tt><font color=blue>chars</font></tt>, <tt><font color=purple>gint</font></tt> <tt><font color=blue>length</font></tt>)</tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>void</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2965"><tt><font color=blue><b>insert</b></font></tt></a></td><td><tt>(<tt>const</tt> <a href="Gtk%3A%3AText.html#2964">Context</a>& <tt><font color=blue>gc</font></tt>, <tt>const</tt> <tt><font color=navy>string</font></tt>& <tt><font color=blue>text</font></tt>)</tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>void</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2966"><tt><font color=blue><b>insert</b></font></tt></a></td><td><tt>(<tt>const</tt> <tt><font color=navy>string</font></tt>& <tt><font color=blue>text</font></tt>)</tt>;</td>
<tr valign=top><td align=right><tt><tt>static</tt> <tt><font color=purple>bool</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2947"><tt><font color=blue><b>isA</b></font></tt></a></td><td><tt>(<a href="Gtk%3A%3AObject.html"><tt><font color=navy><b>Object</b></font></tt></a>* <tt><font color=blue>object</font></tt>)</tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>void</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2954"><tt><font color=blue><b>set_adjustments</b></font></tt></a></td><td><tt>(<a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>* <tt><font color=blue>hadj</font></tt>=0, <a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>* <tt><font color=blue>vadj</font></tt>=0)</tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>void</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2955"><tt><font color=blue><b>set_adjustments</b></font></tt></a></td><td><tt>(<a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>& <tt><font color=blue>hadj</font></tt>, <a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>& <tt><font color=blue>vadj</font></tt>)</tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>void</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2969"><tt><font color=blue><b>set_context</b></font></tt></a></td><td><tt>()</tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>void</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2970"><tt><font color=blue><b>set_context</b></font></tt></a></td><td><tt>(<tt>const</tt> <a href="Gtk%3A%3AText.html#2964">Context</a>& <tt><font color=blue>gc</font></tt>)</tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>void</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2953"><tt><font color=blue><b>set_line_wrap</b></font></tt></a></td><td><tt>(<tt><font color=purple>bool</font></tt> <tt><font color=blue>line_wrap</font></tt>)</tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>void</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2958"><tt><font color=blue><b>set_point</b></font></tt></a></td><td><tt>(<tt><font color=purple>guint</font></tt> <tt><font color=blue>index</font></tt>)</tt>;</td>
<tr valign=top><td align=right><tt><tt>emitable</tt> <tt>signal</tt> <tt><font color=purple>void</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2951"><tt><font color=blue><b>set_scroll_adjustments</b></font></tt></a></td><td><tt>(<a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>*, <a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>*)</tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>void</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2952"><tt><font color=blue><b>set_word_wrap</b></font></tt></a></td><td><tt>(<tt><font color=purple>bool</font></tt> <tt><font color=blue>word_wrap</font></tt>)</tt>;</td>
<tr valign=top><td align=right><tt><tt><font color=purple>void</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2962"><tt><font color=blue><b>thaw</b></font></tt></a></td><td><tt>()</tt>;</td>
<tr valign=top><td align=right><tt><tt>virtual</tt> </tt> </td><td align=right><a href="Gtk%3A%3AText.html#2948"><tt><font color=blue><b>~Text</b></font></tt></a></td><td><tt>()</tt>;</td>
<tr><td>&nbsp;</td><tr><td colspan=3><h3>protected function member index:</h3></td>
<tr valign=top><td align=right><tt><tt>virtual</tt> <tt><font color=purple>void</font></tt></tt> </td><td align=right><a href="Gtk%3A%3AText.html#2973"><tt><font color=blue><b>set_scroll_adjustments_impl</b></font></tt></a></td><td><tt>(<a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>* <tt><font color=blue>p0</font></tt>, <a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>* <tt><font color=blue>p1</font></tt>)</tt>;</td>
<tr><td>&nbsp;</td></table>
<hr noshade>
<h2>Description:</h2>
  A <tt><font color=navy><b>Gtk::Text</b></font></tt> widget allows one to display any given text and manipulate it
  by deleting from one point to another, selecting a region, and various other
  functions as outlined below. It is inherited from <tt><a href="Gtk.html"><tt><font color=navy><b>Gtk</b></font></tt></a>::<a href="Gtk%3A%3AEditable.html"><tt><font color=navy><b>Editable</b></font></tt></a></tt>.<br>
<p>
<hr noshade>
<h2>Function Member Descriptions:</h2>
<a name="2967"><font size=+1><b>Gtk::Text::backward_delete</b></font></a> -   Deletes from the current point position backward the given number of characters.<br>
<hr size="1" width="70%" align="left" noshade="noshade"><tt><tt><font color=purple>gint</font></tt></tt> <a href="Gtk%3A%3AText.html#2967"><tt><font color=blue><b>backward_delete</b></font></tt></a><tt>(<tt><font color=purple>guint</font></tt> <tt><font color=blue>nchars</font></tt>)</tt>;<br><blockquote>  <tt><font color=blue>nchars</font></tt>: The number of characters to delete.
<P>
  <tt><font color=blue>Returns</font></tt>: TRUE if the operation was successful, otherwise returns FALSE.</blockquote>
<br><br>
<a name="2968"><font size=+1><b>Gtk::Text::forward_delete</b></font></a> -   Deletes from the current point position forward the given number of characters.<br>
<hr size="1" width="70%" align="left" noshade="noshade"><tt><tt><font color=purple>gint</font></tt></tt> <a href="Gtk%3A%3AText.html#2968"><tt><font color=blue><b>forward_delete</b></font></tt></a><tt>(<tt><font color=purple>guint</font></tt> <tt><font color=blue>nchars</font></tt>)</tt>;<br><blockquote>  <tt><font color=blue>nchars</font></tt>: The number of characters to delete.
<P>
  <tt><font color=blue>Returns</font></tt>: TRUE if the operation was successful, otherwise returns FALSE.</blockquote>
<br><br>
<a name="2961"><font size=+1><b>Gtk::Text::freeze</b></font></a> -   Freezes the <tt><font color=navy><b>Gtk::Text</b></font></tt> widget which disallows redrawing of the
  widget until it is thawed.<br>
<hr size="1" width="70%" align="left" noshade="noshade"><tt><tt><font color=purple>void</font></tt></tt> <a href="Gtk%3A%3AText.html#2961"><tt><font color=blue><b>freeze</b></font></tt></a><tt>()</tt>;<br><blockquote>  This is useful if a large number of changes are going to made to
  the text within the widget, reducing the amount of flicker seen by the user.</blockquote>
<br><br>
<a name="2960"><font size=+1><b>Gtk::Text::get_length</b></font></a> -   Returns the length of the all the text contained within the
  <tt><font color=navy><b>Gtk::Text</b></font></tt> widget; disregards current point position.<br>
<hr size="1" width="70%" align="left" noshade="noshade"><tt><tt><font color=purple>guint</font></tt></tt> <a href="Gtk%3A%3AText.html#2960"><tt><font color=blue><b>get_length</b></font></tt></a><tt>() <tt>const</tt></tt>;<br><blockquote>  <tt><font color=blue>Returns</font></tt>: The length of the text.</blockquote>
<br><br>
<a name="2959"><font size=+1><b>Gtk::Text::get_point</b></font></a> -   Gets the current position of the cursor as the number of characters from the
  upper left corner of the <tt><font color=navy><b>Gtk::Text</b></font></tt> widget.<br>
<hr size="1" width="70%" align="left" noshade="noshade"><tt><tt><font color=purple>guint</font></tt></tt> <a href="Gtk%3A%3AText.html#2959"><tt><font color=blue><b>get_point</b></font></tt></a><tt>() <tt>const</tt></tt>;<br><blockquote>  <tt><font color=blue>Returns</font></tt>: The number of characters from the upper left corner.</blockquote>
<br><br>
<a name="2945"><font size=+1><b>Gtk::Text::gtkobj</b></font></a> -   Returns the underlaying gtk+ object.<br>
<hr size="1" width="70%" align="left" noshade="noshade"><tt><tt><font color=navy>GtkText</font></tt>*</tt> <a href="Gtk%3A%3AText.html#2945"><tt><font color=blue><b>gtkobj</b></font></tt></a><tt>()</tt>;<br><br>
<a name="2963"><font size=+1><b>Gtk::Text::insert</b></font></a> -   Inserts given text into the GtkText widget with the given properties as outlined below.<br>
<hr size="1" width="70%" align="left" noshade="noshade"><tt><tt><font color=purple>void</font></tt></tt> <a href="Gtk%3A%3AText.html#2963"><tt><font color=blue><b>insert</b></font></tt></a><tt>(<tt>const</tt> <tt><font color=navy>Gdk_Font</font></tt>& <tt><font color=blue>font</font></tt>, <tt>const</tt> <tt><font color=navy>Gdk_Color</font></tt>& <tt><font color=blue>fore</font></tt>, <tt>const</tt> <tt><font color=navy>Gdk_Color</font></tt>& <tt><font color=blue>back</font></tt>, <tt>const</tt> <a href="Gtk%3A%3Anstring.html"><tt><font color=navy><b>nstring</b></font></tt></a>& <tt><font color=blue>chars</font></tt>, <tt><font color=purple>gint</font></tt> <tt><font color=blue>length</font></tt>)</tt>;<br><blockquote>  <tt><font color=blue>font</font></tt>: The <tt><tt><font color=navy><b>Gdk::Font</b></font></tt></tt> to use.
<P>
  <tt><font color=blue>fore</font></tt>: The foreground color to insert with.
<P>
  <tt><font color=blue>back</font></tt>: The background color to insert with.
<P>
  <tt><font color=blue>chars</font></tt>: The actual text to be inserted.
<P>
  <tt><font color=blue>length</font></tt>: The length of the text to be inserted, passing -1 makes it insert all the text.</blockquote>
<br><br>
<a name="2947"><font size=+1><b>Gtk::Text::isA</b></font></a> -   Returns true if object is this type.<br>
<hr size="1" width="70%" align="left" noshade="noshade"><tt><tt>static</tt> <tt><font color=purple>bool</font></tt></tt> <a href="Gtk%3A%3AText.html#2947"><tt><font color=blue><b>isA</b></font></tt></a><tt>(<a href="Gtk%3A%3AObject.html"><tt><font color=navy><b>Object</b></font></tt></a>* <tt><font color=blue>object</font></tt>)</tt>;<br><br>
<a name="2954"><font size=+1><b>Gtk::Text::set_adjustments</b></font></a> -   Allows you to set GtkAdjustment pointers which in turn allows you to keep track of
  the viewing position of the <tt><font color=navy><b>Gtk::Text</b></font></tt> widget.<br>
<hr size="1" width="70%" align="left" noshade="noshade"><tt><tt><font color=purple>void</font></tt></tt> <a href="Gtk%3A%3AText.html#2954"><tt><font color=blue><b>set_adjustments</b></font></tt></a><tt>(<a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>* <tt><font color=blue>hadj</font></tt>=0, <a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>* <tt><font color=blue>vadj</font></tt>=0)</tt>;<br><blockquote>  <tt><font color=blue>hadj</font></tt>: The horizontal adjustment.
<P>
  <tt><font color=blue>vadj</font></tt>: The vertical adjustment.</blockquote>
<br><br>
<a name="2955"><font size=+1><b>Gtk::Text::set_adjustments</b></font></a> -   Allows you to set GtkAdjustment pointers which in turn allows you to keep track of
  the viewing position of the <tt><font color=navy><b>Gtk::Text</b></font></tt> widget.<br>
<hr size="1" width="70%" align="left" noshade="noshade"><tt><tt><font color=purple>void</font></tt></tt> <a href="Gtk%3A%3AText.html#2955"><tt><font color=blue><b>set_adjustments</b></font></tt></a><tt>(<a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>& <tt><font color=blue>hadj</font></tt>, <a href="Gtk%3A%3AAdjustment.html"><tt><font color=navy><b>Adjustment</b></font></tt></a>& <tt><font color=blue>vadj</font></tt>)</tt>;<br><blockquote>  <tt><font color=blue>hadj</font></tt>: The horizontal adjustment.
<P>
  <tt><font color=blue>vadj</font></tt>: The vertical adjustment.</blockquote>
<br><br>
<a name="2953"><font size=+1><b>Gtk::Text::set_line_wrap</b></font></a> -   Controls how <tt><font color=navy><b>Gtk::Text</b></font></tt> handles long lines of continuous text.<br>
<hr size="1" width="70%" align="left" noshade="noshade"><tt><tt><font color=purple>void</font></tt></tt> <a href="Gtk%3A%3AText.html#2953"><tt><font color=blue><b>set_line_wrap</b></font></tt></a><tt>(<tt><font color=purple>bool</font></tt> <tt><font color=blue>line_wrap</font></tt>)</tt>;<br><blockquote>  If line wrap is on, the line is broken when it reaches the extent of the
  <tt><font color=navy><b>Gtk::Text</b></font></tt> widget viewing area and the rest is displayed on the next line.
  If it is not set, the line continues regardless size of current viewing area.
  Similar to word wrap but it disregards word boundaries.
<P>
  <tt><font color=blue>line_wrap</font></tt>: TRUE turns line wrap on, FALSE turns it off.</blockquote>
<br><br>
<a name="2958"><font size=+1><b>Gtk::Text::set_point</b></font></a> -   Sets the cursor at the given point.<br>
<hr size="1" width="70%" align="left" noshade="noshade"><tt><tt><font color=purple>void</font></tt></tt> <a href="Gtk%3A%3AText.html#2958"><tt><font color=blue><b>set_point</b></font></tt></a><tt>(<tt><font color=purple>guint</font></tt> <tt><font color=blue>index</font></tt>)</tt>;<br><blockquote>  In this case a point constitutes the number of characters from the extreme upper
  left corner of the <tt><font color=navy><b>Gtk::Text</b></font></tt> widget.
  <tt><font color=blue>index</font></tt>: The number of characters from the upper left corner.</blockquote>
<br><br>
<a name="2952"><font size=+1><b>Gtk::Text::set_word_wrap</b></font></a> -   Sets whether the <tt><font color=navy><b>Gtk::Text</b></font></tt> widget wraps words down to the next line if
  it can't be completed on the current line.<br>
<hr size="1" width="70%" align="left" noshade="noshade"><tt><tt><font color=purple>void</font></tt></tt> <a href="Gtk%3A%3AText.html#2952"><tt><font color=blue><b>set_word_wrap</b></font></tt></a><tt>(<tt><font color=purple>bool</font></tt> <tt><font color=blue>word_wrap</font></tt>)</tt>;<br><blockquote>  <tt><font color=blue>word_wrap</font></tt>: TRUE makes it word wrap, FALSE disables word wrapping.</blockquote>
<br><br>
<a name="2962"><font size=+1><b>Gtk::Text::thaw</b></font></a> -   Allows the <tt><font color=navy><b>Gtk::Text</b></font></tt> widget to be redrawn again by GTK.<br>
<hr size="1" width="70%" align="left" noshade="noshade"><tt><tt><font color=purple>void</font></tt></tt> <a href="Gtk%3A%3AText.html#2962"><tt><font color=blue><b>thaw</b></font></tt></a><tt>()</tt>;<br><br>
<hr noshade>
<h2>Variable Member Descriptions:</h2>
<hr noshade>
</html>