Sophie

Sophie

distrib > * > 2009.0 > i586 > by-pkgid > a6711891ce757817bba854bf3f25205a > files > 933

qtjambi-doc-4.3.3-3mdv2008.1.i586.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc (build 1.5.0_09) on Tue Aug 07 17:05:35 CEST 2007 -->
<TITLE>
QTextLayout
</TITLE>

<META NAME="keywords" CONTENT="com.trolltech.qt.gui.QTextLayout class">

<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">

<SCRIPT type="text/javascript">
function windowTitle()
{
    parent.document.title="QTextLayout";
}
</SCRIPT>
<NOSCRIPT>
</NOSCRIPT>

</HEAD>

<BODY BGCOLOR="white" onload="windowTitle();">


<!-- ========= START OF TOP NAVBAR ======= -->
<A NAME="navbar_top"><!-- --></A>
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../com/trolltech/qt/gui/QTextItem.RenderFlags.html" title="class in com.trolltech.qt.gui"><B>PREV CLASS</B></A>&nbsp;
&nbsp;<A HREF="../../../../com/trolltech/qt/gui/QTextLayout_FormatRange.html" title="class in com.trolltech.qt.gui"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../../../index.html?com/trolltech/qt/gui/QTextLayout.html" target="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="QTextLayout.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
&nbsp;<SCRIPT type="text/javascript">
  <!--
  if(window==top) {
    document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
  }
  //-->
</SCRIPT>
<NOSCRIPT>
  <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>


</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  SUMMARY:&nbsp;<A HREF="#nested_class_summary">NESTED</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_top"></A>
<!-- ========= END OF TOP NAVBAR ========= -->

<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
com.trolltech.qt.gui</FONT>
<BR>
Class QTextLayout</H2>
<PRE>
java.lang.Object
  <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><A HREF="../../../../com/trolltech/qt/QSignalEmitter.html" title="class in com.trolltech.qt">com.trolltech.qt.QSignalEmitter</A>
      <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><A HREF="../../../../com/trolltech/qt/QtJambiObject.html" title="class in com.trolltech.qt">com.trolltech.qt.QtJambiObject</A>
          <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><B>com.trolltech.qt.gui.QTextLayout</B>
</PRE>
<DL>
<DT><B>All Implemented Interfaces:</B> <DD><A HREF="../../../../com/trolltech/qt/QtJambiInterface.html" title="interface in com.trolltech.qt">QtJambiInterface</A></DD>
</DL>
<HR>
<DL>
<DT><PRE>public class <B>QTextLayout</B><DT>extends <A HREF="../../../../com/trolltech/qt/QtJambiObject.html" title="class in com.trolltech.qt">QtJambiObject</A></DL>
</PRE>

<P>
<p>The <a href="QTextLayout.html#QTextLayout(com.trolltech.qt.gui.QTextBlock)"><tt>QTextLayout</tt></a> class is used to lay out and paint a single paragraph of text.</p>
<p>It offers most features expected from a modern text layout engine, including Unicode compliant rendering, line breaking and handling of cursor positioning. It can also produce and render device independent layout, something that is important for WYSIWYG applications.</p>
<p>The class has a rather low level API and unless you intend to implement your own text rendering for some specialized widget, you probably won't need to use it directly.</p>
<p><a href="QTextLayout.html#QTextLayout(com.trolltech.qt.gui.QTextBlock)"><tt>QTextLayout</tt></a> can currently deal with plain text and rich text paragraphs that are part of a <a href="QTextDocument.html"><tt>QTextDocument</tt></a>.</p>
<p><a href="QTextLayout.html#QTextLayout(com.trolltech.qt.gui.QTextBlock)"><tt>QTextLayout</tt></a> can be used to create a sequence of <a href="QTextLine.html"><tt>QTextLine</tt></a>'s with given widths and can position them independently on the screen. Once the layout is done, these lines can be drawn on a paint device.</p>
<p>Here's some pseudo code that presents the layout phase:</p>
<pre>    int leading = fontMetrics.leading();
    int height = 0;
    qreal widthUsed = 0;
    textLayout.beginLayout();
    while (1) {
        QTextLine line = textLayout.createLine();
        if (!line.isValid())
            break;

        line.setLineWidth(lineWidth);
        height += leading;
        line.setPosition(QPoint(0, height));
        height += line.height();
        widthUsed = qMax(widthUsed, line.naturalTextWidth());
    }
    textLayout.endLayout();</pre>
<p>The text can be drawn by calling the layout's <a href="QTextLayout.html#draw(com.trolltech.qt.gui.QPainter, com.trolltech.qt.core.QPointF, java.util.List<com.trolltech.qt.gui.QTextLayout_FormatRange>, com.trolltech.qt.core.QRectF)"><tt>draw</tt></a> function:</p>
<pre>    QPainter painter(this);
    textLayout.draw(&amp;painter, QPoint(0, 0));</pre>
<p>The text layout's text is set in the constructor or with <a href="QTextLayout.html#setText(java.lang.String)"><tt>setText</tt></a>. The layout can be seen as a sequence of <a href="QTextLine.html"><tt>QTextLine</tt></a> objects; use <a href="QTextLayout.html#lineAt(int)"><tt>lineAt</tt></a> or <a href="QTextLayout.html#lineForTextPosition(int)"><tt>lineForTextPosition</tt></a> to get a <a href="QTextLine.html"><tt>QTextLine</tt></a>, <a href="QTextLayout.html#createLine()"><tt>createLine</tt></a> to create one. For a given position in the text you can find a valid cursor position with <a href="QTextLayout.html#isValidCursorPosition(int)"><tt>isValidCursorPosition</tt></a>, <a href="QTextLayout.html#nextCursorPosition(int, com.trolltech.qt.gui.QTextLayout.CursorMode)"><tt>nextCursorPosition</tt></a>, and <a href="QTextLayout.html#previousCursorPosition(int, com.trolltech.qt.gui.QTextLayout.CursorMode)"><tt>previousCursorPosition</tt></a>. The layout itself can be positioned with <a href="QTextLayout.html#setPosition(com.trolltech.qt.core.QPointF)"><tt>setPosition</tt></a>; it has a <a href="QTextLayout.html#boundingRect()"><tt>boundingRect</tt></a>, and a <a href="QTextLayout.html#minimumWidth()"><tt>minimumWidth</tt></a> and a <a href="QTextLayout.html#maximumWidth()"><tt>maximumWidth</tt></a>. A text layout can be drawn on a painter device using <a href="QTextLayout.html#draw(com.trolltech.qt.gui.QPainter, com.trolltech.qt.core.QPointF, java.util.List<com.trolltech.qt.gui.QTextLayout_FormatRange>, com.trolltech.qt.core.QRectF)"><tt>draw</tt></a>.</p>
<P>

<P>
<HR>

<P>
<!-- ======== NESTED CLASS SUMMARY ======== -->

<A NAME="nested_class_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Nested Class Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;class</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.CursorMode.html" title="enum in com.trolltech.qt.gui">QTextLayout.CursorMode</A></B></CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Press link for info on QTextLayout.CursorMode</TD>
</TR>
</TABLE>
&nbsp;<A NAME="nested_classes_inherited_from_class_com.trolltech.qt.QSignalEmitter"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TH ALIGN="left"><B>Nested classes/interfaces inherited from class com.trolltech.qt.<A HREF="../../../../com/trolltech/qt/QSignalEmitter.html" title="class in com.trolltech.qt">QSignalEmitter</A></B></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal0.html" title="class in com.trolltech.qt">QSignalEmitter.Signal0</A>, <A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal1.html" title="class in com.trolltech.qt">QSignalEmitter.Signal1</A>&lt;<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal1.html" title="type parameter in QSignalEmitter.Signal1">A</A>&gt;, <A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal2.html" title="class in com.trolltech.qt">QSignalEmitter.Signal2</A>&lt;<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal2.html" title="type parameter in QSignalEmitter.Signal2">A</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal2.html" title="type parameter in QSignalEmitter.Signal2">B</A>&gt;, <A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal3.html" title="class in com.trolltech.qt">QSignalEmitter.Signal3</A>&lt;<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal3.html" title="type parameter in QSignalEmitter.Signal3">A</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal3.html" title="type parameter in QSignalEmitter.Signal3">B</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal3.html" title="type parameter in QSignalEmitter.Signal3">C</A>&gt;, <A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal4.html" title="class in com.trolltech.qt">QSignalEmitter.Signal4</A>&lt;<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal4.html" title="type parameter in QSignalEmitter.Signal4">A</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal4.html" title="type parameter in QSignalEmitter.Signal4">B</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal4.html" title="type parameter in QSignalEmitter.Signal4">C</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal4.html" title="type parameter in QSignalEmitter.Signal4">D</A>&gt;, <A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal5.html" title="class in com.trolltech.qt">QSignalEmitter.Signal5</A>&lt;<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal5.html" title="type parameter in QSignalEmitter.Signal5">A</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal5.html" title="type parameter in QSignalEmitter.Signal5">B</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal5.html" title="type parameter in QSignalEmitter.Signal5">C</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal5.html" title="type parameter in QSignalEmitter.Signal5">D</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal5.html" title="type parameter in QSignalEmitter.Signal5">E</A>&gt;, <A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal6.html" title="class in com.trolltech.qt">QSignalEmitter.Signal6</A>&lt;<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal6.html" title="type parameter in QSignalEmitter.Signal6">A</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal6.html" title="type parameter in QSignalEmitter.Signal6">B</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal6.html" title="type parameter in QSignalEmitter.Signal6">C</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal6.html" title="type parameter in QSignalEmitter.Signal6">D</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal6.html" title="type parameter in QSignalEmitter.Signal6">E</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal6.html" title="type parameter in QSignalEmitter.Signal6">F</A>&gt;, <A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal7.html" title="class in com.trolltech.qt">QSignalEmitter.Signal7</A>&lt;<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal7.html" title="type parameter in QSignalEmitter.Signal7">A</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal7.html" title="type parameter in QSignalEmitter.Signal7">B</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal7.html" title="type parameter in QSignalEmitter.Signal7">C</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal7.html" title="type parameter in QSignalEmitter.Signal7">D</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal7.html" title="type parameter in QSignalEmitter.Signal7">E</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal7.html" title="type parameter in QSignalEmitter.Signal7">F</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal7.html" title="type parameter in QSignalEmitter.Signal7">G</A>&gt;, <A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal8.html" title="class in com.trolltech.qt">QSignalEmitter.Signal8</A>&lt;<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal8.html" title="type parameter in QSignalEmitter.Signal8">A</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal8.html" title="type parameter in QSignalEmitter.Signal8">B</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal8.html" title="type parameter in QSignalEmitter.Signal8">C</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal8.html" title="type parameter in QSignalEmitter.Signal8">D</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal8.html" title="type parameter in QSignalEmitter.Signal8">E</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal8.html" title="type parameter in QSignalEmitter.Signal8">F</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal8.html" title="type parameter in QSignalEmitter.Signal8">G</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal8.html" title="type parameter in QSignalEmitter.Signal8">H</A>&gt;, <A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal9.html" title="class in com.trolltech.qt">QSignalEmitter.Signal9</A>&lt;<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal9.html" title="type parameter in QSignalEmitter.Signal9">A</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal9.html" title="type parameter in QSignalEmitter.Signal9">B</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal9.html" title="type parameter in QSignalEmitter.Signal9">C</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal9.html" title="type parameter in QSignalEmitter.Signal9">D</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal9.html" title="type parameter in QSignalEmitter.Signal9">E</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal9.html" title="type parameter in QSignalEmitter.Signal9">F</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal9.html" title="type parameter in QSignalEmitter.Signal9">G</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal9.html" title="type parameter in QSignalEmitter.Signal9">H</A>,<A HREF="../../../../com/trolltech/qt/QSignalEmitter.Signal9.html" title="type parameter in QSignalEmitter.Signal9">I</A>&gt;</CODE></TD>
</TR>
</TABLE>
&nbsp;

<!-- ======== CONSTRUCTOR SUMMARY ======== -->

<A NAME="constructor_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Constructor Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#QTextLayout()">QTextLayout</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs an empty text layout.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#QTextLayout(com.trolltech.qt.gui.QTextBlock)">QTextLayout</A></B>(<A HREF="../../../../com/trolltech/qt/gui/QTextBlock.html" title="class in com.trolltech.qt.gui">QTextBlock</A>&nbsp;b)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method is used internally by Qt Jambi.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#QTextLayout(java.lang.String)">QTextLayout</A></B>(java.lang.String&nbsp;text)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs a text layout to lay out the given <tt>text</tt>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#QTextLayout(java.lang.String, com.trolltech.qt.gui.QFont)">QTextLayout</A></B>(java.lang.String&nbsp;text,
            <A HREF="../../../../com/trolltech/qt/gui/QFont.html" title="class in com.trolltech.qt.gui">QFont</A>&nbsp;font)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Equivalent to <a href="QTextLayout.html#QTextLayout(com.trolltech.qt.gui.QTextBlock)"><tt>QTextLayout</tt></a>(<tt>text</tt>, <tt>font</tt>, 0).</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#QTextLayout(java.lang.String, com.trolltech.qt.gui.QFont, com.trolltech.qt.gui.QPaintDeviceInterface)">QTextLayout</A></B>(java.lang.String&nbsp;text,
            <A HREF="../../../../com/trolltech/qt/gui/QFont.html" title="class in com.trolltech.qt.gui">QFont</A>&nbsp;font,
            <A HREF="../../../../com/trolltech/qt/gui/QPaintDeviceInterface.html" title="interface in com.trolltech.qt.gui">QPaintDeviceInterface</A>&nbsp;paintdevice)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs a text layout to lay out the given <tt>text</tt> with the specified <tt>font</tt>.</TD>
</TR>
</TABLE>
&nbsp;
<!-- ========== METHOD SUMMARY =========== -->

<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Method Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;java.util.List&lt;<A HREF="../../../../com/trolltech/qt/gui/QTextLayout_FormatRange.html" title="class in com.trolltech.qt.gui">QTextLayout_FormatRange</A>&gt;</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#additionalFormats()">additionalFormats</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the list of additional formats supported by the text layout.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#beginLayout()">beginLayout</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Begins the layout process.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../com/trolltech/qt/core/QRectF.html" title="class in com.trolltech.qt.core">QRectF</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#boundingRect()">boundingRect</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The smallest rectangle that contains all the lines in the layout.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;boolean</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#cacheEnabled()">cacheEnabled</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns true if the complete layout information is cached; otherwise returns false.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#clearAdditionalFormats()">clearAdditionalFormats</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Clears the list of additional formats supported by the text layout.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../com/trolltech/qt/gui/QTextLine.html" title="class in com.trolltech.qt.gui">QTextLine</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#createLine()">createLine</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a new text line to be laid out if there is text to be inserted into the layout; otherwise returns an invalid text line.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#draw(com.trolltech.qt.gui.QPainter, com.trolltech.qt.core.QPointF, java.util.List)">draw</A></B>(<A HREF="../../../../com/trolltech/qt/gui/QPainter.html" title="class in com.trolltech.qt.gui">QPainter</A>&nbsp;p,
     <A HREF="../../../../com/trolltech/qt/core/QPointF.html" title="class in com.trolltech.qt.core">QPointF</A>&nbsp;pos,
     java.util.List&lt;<A HREF="../../../../com/trolltech/qt/gui/QTextLayout_FormatRange.html" title="class in com.trolltech.qt.gui">QTextLayout_FormatRange</A>&gt;&nbsp;selections)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Draws the whole layout on the painter <tt>p</tt> at the position
specified by <tt>pos</tt>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#draw(com.trolltech.qt.gui.QPainter, com.trolltech.qt.core.QPointF, java.util.List, com.trolltech.qt.core.QRectF)">draw</A></B>(<A HREF="../../../../com/trolltech/qt/gui/QPainter.html" title="class in com.trolltech.qt.gui">QPainter</A>&nbsp;p,
     <A HREF="../../../../com/trolltech/qt/core/QPointF.html" title="class in com.trolltech.qt.core">QPointF</A>&nbsp;pos,
     java.util.List&lt;<A HREF="../../../../com/trolltech/qt/gui/QTextLayout_FormatRange.html" title="class in com.trolltech.qt.gui">QTextLayout_FormatRange</A>&gt;&nbsp;selections,
     <A HREF="../../../../com/trolltech/qt/core/QRectF.html" title="class in com.trolltech.qt.core">QRectF</A>&nbsp;clip)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Draws the whole layout on the painter <tt>p</tt> at the position specified by <tt>pos</tt>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#drawCursor(com.trolltech.qt.gui.QPainter, com.trolltech.qt.core.QPointF, int)">drawCursor</A></B>(<A HREF="../../../../com/trolltech/qt/gui/QPainter.html" title="class in com.trolltech.qt.gui">QPainter</A>&nbsp;p,
           <A HREF="../../../../com/trolltech/qt/core/QPointF.html" title="class in com.trolltech.qt.core">QPointF</A>&nbsp;pos,
           int&nbsp;cursorPosition)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Draws a text cursor with the current pen at the given <tt>pos</tt> using the <tt>p</tt> specified.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#drawCursor(com.trolltech.qt.gui.QPainter, com.trolltech.qt.core.QPointF, int, int)">drawCursor</A></B>(<A HREF="../../../../com/trolltech/qt/gui/QPainter.html" title="class in com.trolltech.qt.gui">QPainter</A>&nbsp;p,
           <A HREF="../../../../com/trolltech/qt/core/QPointF.html" title="class in com.trolltech.qt.core">QPointF</A>&nbsp;pos,
           int&nbsp;cursorPosition,
           int&nbsp;width)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Draws a text cursor with the current pen and the specified <tt>width</tt> at the given <tt>pos</tt> using the <tt>p</tt> specified.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#endLayout()">endLayout</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Ends the layout process.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../com/trolltech/qt/gui/QFont.html" title="class in com.trolltech.qt.gui">QFont</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#font()">font</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the current font that is used for the layout, or a default font if none is set.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;<A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html" title="class in com.trolltech.qt.gui">QTextLayout</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#fromNativePointer(com.trolltech.qt.QNativePointer)">fromNativePointer</A></B>(<A HREF="../../../../com/trolltech/qt/QNativePointer.html" title="class in com.trolltech.qt">QNativePointer</A>&nbsp;nativePointer)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This function returns the QTextLayout instance pointed to by nativePointer</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;boolean</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#isValidCursorPosition(int)">isValidCursorPosition</A></B>(int&nbsp;pos)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns true if position <tt>pos</tt> is a valid cursor position.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../com/trolltech/qt/gui/QTextLine.html" title="class in com.trolltech.qt.gui">QTextLine</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#lineAt(int)">lineAt</A></B>(int&nbsp;i)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the <tt>i</tt>-th line of text in this text layout.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#lineCount()">lineCount</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the number of lines in this text layout.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../com/trolltech/qt/gui/QTextLine.html" title="class in com.trolltech.qt.gui">QTextLine</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#lineForTextPosition(int)">lineForTextPosition</A></B>(int&nbsp;pos)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the line that contains the cursor position specified by <tt>pos</tt>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;double</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#maximumWidth()">maximumWidth</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The maximum width the layout could expand to; this is essentially the width of the entire text.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;double</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#minimumWidth()">minimumWidth</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The minimum width the layout needs.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#nextCursorPosition(int)">nextCursorPosition</A></B>(int&nbsp;oldPos)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Equivalent to <a href="QTextLayout.html#nextCursorPosition(int, com.trolltech.qt.gui.QTextLayout.CursorMode)"><tt>nextCursorPosition</tt></a>(<tt>oldPos</tt>, SkipCharacters).</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#nextCursorPosition(int, com.trolltech.qt.gui.QTextLayout.CursorMode)">nextCursorPosition</A></B>(int&nbsp;oldPos,
                   <A HREF="../../../../com/trolltech/qt/gui/QTextLayout.CursorMode.html" title="enum in com.trolltech.qt.gui">QTextLayout.CursorMode</A>&nbsp;mode)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the next valid cursor position after <tt>oldPos</tt> that respects the given cursor <tt>mode</tt>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../com/trolltech/qt/core/QPointF.html" title="class in com.trolltech.qt.core">QPointF</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#position()">position</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The global position of the layout.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#preeditAreaPosition()">preeditAreaPosition</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the position of the area in the text layout that will be processed before editing occurs.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#preeditAreaText()">preeditAreaText</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the text that is inserted in the layout before editing occurs.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#previousCursorPosition(int)">previousCursorPosition</A></B>(int&nbsp;oldPos)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Equivalent to <a href="QTextLayout.html#previousCursorPosition(int, com.trolltech.qt.gui.QTextLayout.CursorMode)"><tt>previousCursorPosition</tt></a>(<tt>oldPos</tt>, SkipCharacters).</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#previousCursorPosition(int, com.trolltech.qt.gui.QTextLayout.CursorMode)">previousCursorPosition</A></B>(int&nbsp;oldPos,
                       <A HREF="../../../../com/trolltech/qt/gui/QTextLayout.CursorMode.html" title="enum in com.trolltech.qt.gui">QTextLayout.CursorMode</A>&nbsp;mode)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the first valid cursor position before <tt>oldPos</tt> that respects the given cursor <tt>mode</tt>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#setAdditionalFormats(java.util.List)">setAdditionalFormats</A></B>(java.util.List&lt;<A HREF="../../../../com/trolltech/qt/gui/QTextLayout_FormatRange.html" title="class in com.trolltech.qt.gui">QTextLayout_FormatRange</A>&gt;&nbsp;overrides)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the additional formats supported by the text layout to <tt>overrides</tt>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#setCacheEnabled(boolean)">setCacheEnabled</A></B>(boolean&nbsp;enable)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Enables caching of the complete layout information if <tt>enable</tt> is true; otherwise disables layout caching.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#setFont(com.trolltech.qt.gui.QFont)">setFont</A></B>(<A HREF="../../../../com/trolltech/qt/gui/QFont.html" title="class in com.trolltech.qt.gui">QFont</A>&nbsp;f)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the layout's font to the given <tt>f</tt>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#setPosition(com.trolltech.qt.core.QPointF)">setPosition</A></B>(<A HREF="../../../../com/trolltech/qt/core/QPointF.html" title="class in com.trolltech.qt.core">QPointF</A>&nbsp;p)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Moves the text layout to point <tt>p</tt>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#setPreeditArea(int, java.lang.String)">setPreeditArea</A></B>(int&nbsp;position,
               java.lang.String&nbsp;text)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the <tt>position</tt> and <tt>text</tt> of the area in the layout that is processed before editing occurs.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#setText(java.lang.String)">setText</A></B>(java.lang.String&nbsp;string)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the layout's text to the given <tt>string</tt>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#setTextOption(com.trolltech.qt.gui.QTextOption)">setTextOption</A></B>(<A HREF="../../../../com/trolltech/qt/gui/QTextOption.html" title="class in com.trolltech.qt.gui">QTextOption</A>&nbsp;option)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the text option structure that controls the layout process to the given <tt>option</tt>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#text()">text</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the layout's text.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../com/trolltech/qt/gui/QTextOption.html" title="class in com.trolltech.qt.gui">QTextOption</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html#textOption()">textOption</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the current text option used to control the layout process.</TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_com.trolltech.qt.QtJambiObject"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TH ALIGN="left"><B>Methods inherited from class com.trolltech.qt.<A HREF="../../../../com/trolltech/qt/QtJambiObject.html" title="class in com.trolltech.qt">QtJambiObject</A></B></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="../../../../com/trolltech/qt/QtJambiObject.html#dispose()">dispose</A>, <A HREF="../../../../com/trolltech/qt/QtJambiObject.html#disposed()">disposed</A>, <A HREF="../../../../com/trolltech/qt/QtJambiObject.html#finalize()">finalize</A>, <A HREF="../../../../com/trolltech/qt/QtJambiObject.html#reassignNativeResources(com.trolltech.qt.QtJambiObject, java.lang.Class)">reassignNativeResources</A>, <A HREF="../../../../com/trolltech/qt/QtJambiObject.html#tr(java.lang.String)">tr</A>, <A HREF="../../../../com/trolltech/qt/QtJambiObject.html#tr(java.lang.String, java.lang.String)">tr</A>, <A HREF="../../../../com/trolltech/qt/QtJambiObject.html#tr(java.lang.String, java.lang.String, int)">tr</A></CODE></TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_com.trolltech.qt.QSignalEmitter"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TH ALIGN="left"><B>Methods inherited from class com.trolltech.qt.<A HREF="../../../../com/trolltech/qt/QSignalEmitter.html" title="class in com.trolltech.qt">QSignalEmitter</A></B></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="../../../../com/trolltech/qt/QSignalEmitter.html#blockSignals(boolean)">blockSignals</A>, <A HREF="../../../../com/trolltech/qt/QSignalEmitter.html#disconnect()">disconnect</A>, <A HREF="../../../../com/trolltech/qt/QSignalEmitter.html#disconnect(java.lang.Object)">disconnect</A>, <A HREF="../../../../com/trolltech/qt/QSignalEmitter.html#signalsBlocked()">signalsBlocked</A>, <A HREF="../../../../com/trolltech/qt/QSignalEmitter.html#signalSender()">signalSender</A>, <A HREF="../../../../com/trolltech/qt/QSignalEmitter.html#thread()">thread</A></CODE></TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TH ALIGN="left"><B>Methods inherited from class java.lang.Object</B></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE>clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_com.trolltech.qt.QtJambiInterface"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TH ALIGN="left"><B>Methods inherited from interface com.trolltech.qt.<A HREF="../../../../com/trolltech/qt/QtJambiInterface.html" title="interface in com.trolltech.qt">QtJambiInterface</A></B></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="../../../../com/trolltech/qt/QtJambiInterface.html#disableGarbageCollection()">disableGarbageCollection</A>, <A HREF="../../../../com/trolltech/qt/QtJambiInterface.html#nativeId()">nativeId</A>, <A HREF="../../../../com/trolltech/qt/QtJambiInterface.html#nativePointer()">nativePointer</A>, <A HREF="../../../../com/trolltech/qt/QtJambiInterface.html#reenableGarbageCollection()">reenableGarbageCollection</A>, <A HREF="../../../../com/trolltech/qt/QtJambiInterface.html#setJavaOwnership()">setJavaOwnership</A></CODE></TD>
</TR>
</TABLE>
&nbsp;
<P>

<!-- ========= CONSTRUCTOR DETAIL ======== -->

<A NAME="constructor_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Constructor Detail</B></FONT></TH>
</TR>
</TABLE>

<A NAME="QTextLayout()"><!-- --></A><H3>
QTextLayout</H3>
<PRE>
public <B>QTextLayout</B>()</PRE>
<DL>
<DD><p>Constructs an empty text layout.</p>
<P>
<DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#setText(java.lang.String)"><tt>setText</tt></a></DL>
</DL>
<HR>

<A NAME="QTextLayout(java.lang.String, com.trolltech.qt.gui.QFont)"><!-- --></A><H3>
QTextLayout</H3>
<PRE>
public <B>QTextLayout</B>(java.lang.String&nbsp;text,
                   <A HREF="../../../../com/trolltech/qt/gui/QFont.html" title="class in com.trolltech.qt.gui">QFont</A>&nbsp;font)</PRE>
<DL>
<DD><p>Equivalent to <a href="QTextLayout.html#QTextLayout(com.trolltech.qt.gui.QTextBlock)"><tt>QTextLayout</tt></a>(<tt>text</tt>, <tt>font</tt>, 0).
<P>
</DL>
<HR>

<A NAME="QTextLayout(java.lang.String, com.trolltech.qt.gui.QFont, com.trolltech.qt.gui.QPaintDeviceInterface)"><!-- --></A><H3>
QTextLayout</H3>
<PRE>
public <B>QTextLayout</B>(java.lang.String&nbsp;text,
                   <A HREF="../../../../com/trolltech/qt/gui/QFont.html" title="class in com.trolltech.qt.gui">QFont</A>&nbsp;font,
                   <A HREF="../../../../com/trolltech/qt/gui/QPaintDeviceInterface.html" title="interface in com.trolltech.qt.gui">QPaintDeviceInterface</A>&nbsp;paintdevice)</PRE>
<DL>
<DD><p>Constructs a text layout to lay out the given <tt>text</tt> with the specified <tt>font</tt>.</p>
<p>All the metric and layout calculations will be done in terms of the paint device, <tt>paintdevice</tt>. If <tt>paintdevice</tt> is 0 the calculations will be done in screen metrics.</p>
<P>
</DL>
<HR>

<A NAME="QTextLayout(java.lang.String)"><!-- --></A><H3>
QTextLayout</H3>
<PRE>
public <B>QTextLayout</B>(java.lang.String&nbsp;text)</PRE>
<DL>
<DD><p>Constructs a text layout to lay out the given <tt>text</tt>.</p>
<P>
</DL>
<HR>

<A NAME="QTextLayout(com.trolltech.qt.gui.QTextBlock)"><!-- --></A><H3>
QTextLayout</H3>
<PRE>
public <B>QTextLayout</B>(<A HREF="../../../../com/trolltech/qt/gui/QTextBlock.html" title="class in com.trolltech.qt.gui">QTextBlock</A>&nbsp;b)</PRE>
<DL>
<DD><p>This method is used internally by Qt Jambi.
Do not use it in your applications.</p>
<P>
</DL>

<!-- ============ METHOD DETAIL ========== -->

<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Method Detail</B></FONT></TH>
</TR>
</TABLE>

<A NAME="additionalFormats()"><!-- --></A><H3>
additionalFormats</H3>
<PRE>
public final java.util.List&lt;<A HREF="../../../../com/trolltech/qt/gui/QTextLayout_FormatRange.html" title="class in com.trolltech.qt.gui">QTextLayout_FormatRange</A>&gt; <B>additionalFormats</B>()</PRE>
<DL>
<DD><p>Returns the list of additional formats supported by the text layout.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#setAdditionalFormats(java.util.List<com.trolltech.qt.gui.QTextLayout_FormatRange>)"><tt>setAdditionalFormats</tt></a>, 
<a href="QTextLayout.html#clearAdditionalFormats()"><tt>clearAdditionalFormats</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="beginLayout()"><!-- --></A><H3>
beginLayout</H3>
<PRE>
public final void <B>beginLayout</B>()</PRE>
<DL>
<DD><p>Begins the layout process.</p>
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="boundingRect()"><!-- --></A><H3>
boundingRect</H3>
<PRE>
public final <A HREF="../../../../com/trolltech/qt/core/QRectF.html" title="class in com.trolltech.qt.core">QRectF</A> <B>boundingRect</B>()</PRE>
<DL>
<DD><p>The smallest rectangle that contains all the lines in the layout.</p>
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="cacheEnabled()"><!-- --></A><H3>
cacheEnabled</H3>
<PRE>
public final boolean <B>cacheEnabled</B>()</PRE>
<DL>
<DD><p>Returns true if the complete layout information is cached; otherwise returns false.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#setCacheEnabled(boolean)"><tt>setCacheEnabled</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="clearAdditionalFormats()"><!-- --></A><H3>
clearAdditionalFormats</H3>
<PRE>
public final void <B>clearAdditionalFormats</B>()</PRE>
<DL>
<DD><p>Clears the list of additional formats supported by the text layout.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#additionalFormats()"><tt>additionalFormats</tt></a>, 
<a href="QTextLayout.html#setAdditionalFormats(java.util.List<com.trolltech.qt.gui.QTextLayout_FormatRange>)"><tt>setAdditionalFormats</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="createLine()"><!-- --></A><H3>
createLine</H3>
<PRE>
public final <A HREF="../../../../com/trolltech/qt/gui/QTextLine.html" title="class in com.trolltech.qt.gui">QTextLine</A> <B>createLine</B>()</PRE>
<DL>
<DD><p>Returns a new text line to be laid out if there is text to be inserted into the layout; otherwise returns an invalid text line.</p>
<p>The text layout creates a new line object that starts after the last line in the layout, or at the beginning if the layout is empty. The layout maintains an internal cursor, and each line is filled with text from the cursor position onwards when the QTextLine::setLineWidth() function is called.</p>
<p>Once QTextLine::setLineWidth() is called, a new line can be created and filled with text. Repeating this process will lay out the whole block of text contained in the <a href="QTextLayout.html#QTextLayout(com.trolltech.qt.gui.QTextBlock)"><tt>QTextLayout</tt></a>. If there is no text left to be inserted into the layout, the <a href="QTextLine.html"><tt>QTextLine</tt></a> returned will not be valid (isValid() will return false).</p>
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="draw(com.trolltech.qt.gui.QPainter, com.trolltech.qt.core.QPointF, java.util.List)"><!-- --></A><H3>
draw</H3>
<PRE>
public final void <B>draw</B>(<A HREF="../../../../com/trolltech/qt/gui/QPainter.html" title="class in com.trolltech.qt.gui">QPainter</A>&nbsp;p,
                       <A HREF="../../../../com/trolltech/qt/core/QPointF.html" title="class in com.trolltech.qt.core">QPointF</A>&nbsp;pos,
                       java.util.List&lt;<A HREF="../../../../com/trolltech/qt/gui/QTextLayout_FormatRange.html" title="class in com.trolltech.qt.gui">QTextLayout_FormatRange</A>&gt;&nbsp;selections)</PRE>
<DL>
<DD>Draws the whole layout on the painter <tt>p</tt> at the position
specified by <tt>pos</tt>.  The rendered layout includes the given
<tt>selections</tt>.
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="draw(com.trolltech.qt.gui.QPainter, com.trolltech.qt.core.QPointF, java.util.List, com.trolltech.qt.core.QRectF)"><!-- --></A><H3>
draw</H3>
<PRE>
public final void <B>draw</B>(<A HREF="../../../../com/trolltech/qt/gui/QPainter.html" title="class in com.trolltech.qt.gui">QPainter</A>&nbsp;p,
                       <A HREF="../../../../com/trolltech/qt/core/QPointF.html" title="class in com.trolltech.qt.core">QPointF</A>&nbsp;pos,
                       java.util.List&lt;<A HREF="../../../../com/trolltech/qt/gui/QTextLayout_FormatRange.html" title="class in com.trolltech.qt.gui">QTextLayout_FormatRange</A>&gt;&nbsp;selections,
                       <A HREF="../../../../com/trolltech/qt/core/QRectF.html" title="class in com.trolltech.qt.core">QRectF</A>&nbsp;clip)</PRE>
<DL>
<DD><p>Draws the whole layout on the painter <tt>p</tt> at the position specified by <tt>pos</tt>. The rendered layout includes the given <tt>selections</tt> and is clipped within the rectangle specified by <tt>clip</tt>.</p>
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="drawCursor(com.trolltech.qt.gui.QPainter, com.trolltech.qt.core.QPointF, int, int)"><!-- --></A><H3>
drawCursor</H3>
<PRE>
public final void <B>drawCursor</B>(<A HREF="../../../../com/trolltech/qt/gui/QPainter.html" title="class in com.trolltech.qt.gui">QPainter</A>&nbsp;p,
                             <A HREF="../../../../com/trolltech/qt/core/QPointF.html" title="class in com.trolltech.qt.core">QPointF</A>&nbsp;pos,
                             int&nbsp;cursorPosition,
                             int&nbsp;width)</PRE>
<DL>
<DD><p>Draws a text cursor with the current pen and the specified <tt>width</tt> at the given <tt>pos</tt> using the <tt>p</tt> specified. The corresponding position within the text is specified by <tt>cursorPosition</tt>.</p>
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="drawCursor(com.trolltech.qt.gui.QPainter, com.trolltech.qt.core.QPointF, int)"><!-- --></A><H3>
drawCursor</H3>
<PRE>
public final void <B>drawCursor</B>(<A HREF="../../../../com/trolltech/qt/gui/QPainter.html" title="class in com.trolltech.qt.gui">QPainter</A>&nbsp;p,
                             <A HREF="../../../../com/trolltech/qt/core/QPointF.html" title="class in com.trolltech.qt.core">QPointF</A>&nbsp;pos,
                             int&nbsp;cursorPosition)</PRE>
<DL>
<DD><p>Draws a text cursor with the current pen at the given <tt>pos</tt> using the <tt>p</tt> specified. The corresponding position within the text is specified by <tt>cursorPosition</tt>.</p>
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="endLayout()"><!-- --></A><H3>
endLayout</H3>
<PRE>
public final void <B>endLayout</B>()</PRE>
<DL>
<DD><p>Ends the layout process.</p>
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="font()"><!-- --></A><H3>
font</H3>
<PRE>
public final <A HREF="../../../../com/trolltech/qt/gui/QFont.html" title="class in com.trolltech.qt.gui">QFont</A> <B>font</B>()</PRE>
<DL>
<DD><p>Returns the current font that is used for the layout, or a default font if none is set.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#setFont(com.trolltech.qt.gui.QFont)"><tt>setFont</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="isValidCursorPosition(int)"><!-- --></A><H3>
isValidCursorPosition</H3>
<PRE>
public final boolean <B>isValidCursorPosition</B>(int&nbsp;pos)</PRE>
<DL>
<DD><p>Returns true if position <tt>pos</tt> is a valid cursor position.</p>
<p>In a Unicode context some positions in the text are not valid cursor positions, because the position is inside a Unicode surrogate or a grapheme cluster.</p>
<p>A grapheme cluster is a sequence of two or more Unicode characters that form one indivisible entity on the screen. For example the latin character `&Auml;' can be represented in Unicode by two characters, `A' (0x41), and the combining diaresis (0x308). A text cursor can only validly be positioned before or after these two characters, never between them since that wouldn't make sense. In indic languages every syllable forms a grapheme cluster.</p>
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="lineAt(int)"><!-- --></A><H3>
lineAt</H3>
<PRE>
public final <A HREF="../../../../com/trolltech/qt/gui/QTextLine.html" title="class in com.trolltech.qt.gui">QTextLine</A> <B>lineAt</B>(int&nbsp;i)</PRE>
<DL>
<DD><p>Returns the <tt>i</tt>-th line of text in this text layout.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#lineCount()"><tt>lineCount</tt></a>, 
<a href="QTextLayout.html#lineForTextPosition(int)"><tt>lineForTextPosition</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="lineCount()"><!-- --></A><H3>
lineCount</H3>
<PRE>
public final int <B>lineCount</B>()</PRE>
<DL>
<DD><p>Returns the number of lines in this text layout.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#lineAt(int)"><tt>lineAt</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="lineForTextPosition(int)"><!-- --></A><H3>
lineForTextPosition</H3>
<PRE>
public final <A HREF="../../../../com/trolltech/qt/gui/QTextLine.html" title="class in com.trolltech.qt.gui">QTextLine</A> <B>lineForTextPosition</B>(int&nbsp;pos)</PRE>
<DL>
<DD><p>Returns the line that contains the cursor position specified by <tt>pos</tt>.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#isValidCursorPosition(int)"><tt>isValidCursorPosition</tt></a>, 
<a href="QTextLayout.html#lineAt(int)"><tt>lineAt</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="maximumWidth()"><!-- --></A><H3>
maximumWidth</H3>
<PRE>
public final double <B>maximumWidth</B>()</PRE>
<DL>
<DD><p>The maximum width the layout could expand to; this is essentially the width of the entire text.</p>
<p><b>Warning:</b> This function only returns a valid value after the layout has been done.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#minimumWidth()"><tt>minimumWidth</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="minimumWidth()"><!-- --></A><H3>
minimumWidth</H3>
<PRE>
public final double <B>minimumWidth</B>()</PRE>
<DL>
<DD><p>The minimum width the layout needs. This is the width of the layout's smallest non-breakable substring.</p>
<p><b>Warning:</b> This function only returns a valid value after the layout has been done.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#maximumWidth()"><tt>maximumWidth</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="nextCursorPosition(int)"><!-- --></A><H3>
nextCursorPosition</H3>
<PRE>
public final int <B>nextCursorPosition</B>(int&nbsp;oldPos)</PRE>
<DL>
<DD><p>Equivalent to <a href="QTextLayout.html#nextCursorPosition(int, com.trolltech.qt.gui.QTextLayout.CursorMode)"><tt>nextCursorPosition</tt></a>(<tt>oldPos</tt>, SkipCharacters).
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="nextCursorPosition(int, com.trolltech.qt.gui.QTextLayout.CursorMode)"><!-- --></A><H3>
nextCursorPosition</H3>
<PRE>
public final int <B>nextCursorPosition</B>(int&nbsp;oldPos,
                                    <A HREF="../../../../com/trolltech/qt/gui/QTextLayout.CursorMode.html" title="enum in com.trolltech.qt.gui">QTextLayout.CursorMode</A>&nbsp;mode)</PRE>
<DL>
<DD><p>Returns the next valid cursor position after <tt>oldPos</tt> that respects the given cursor <tt>mode</tt>.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#isValidCursorPosition(int)"><tt>isValidCursorPosition</tt></a>, 
<a href="QTextLayout.html#previousCursorPosition(int, com.trolltech.qt.gui.QTextLayout.CursorMode)"><tt>previousCursorPosition</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="position()"><!-- --></A><H3>
position</H3>
<PRE>
public final <A HREF="../../../../com/trolltech/qt/core/QPointF.html" title="class in com.trolltech.qt.core">QPointF</A> <B>position</B>()</PRE>
<DL>
<DD><p>The global position of the layout. This is independent of the bounding rectangle and of the layout process.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#setPosition(com.trolltech.qt.core.QPointF)"><tt>setPosition</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="preeditAreaPosition()"><!-- --></A><H3>
preeditAreaPosition</H3>
<PRE>
public final int <B>preeditAreaPosition</B>()</PRE>
<DL>
<DD><p>Returns the position of the area in the text layout that will be processed before editing occurs.</p>
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="preeditAreaText()"><!-- --></A><H3>
preeditAreaText</H3>
<PRE>
public final java.lang.String <B>preeditAreaText</B>()</PRE>
<DL>
<DD><p>Returns the text that is inserted in the layout before editing occurs.</p>
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="previousCursorPosition(int)"><!-- --></A><H3>
previousCursorPosition</H3>
<PRE>
public final int <B>previousCursorPosition</B>(int&nbsp;oldPos)</PRE>
<DL>
<DD><p>Equivalent to <a href="QTextLayout.html#previousCursorPosition(int, com.trolltech.qt.gui.QTextLayout.CursorMode)"><tt>previousCursorPosition</tt></a>(<tt>oldPos</tt>, SkipCharacters).
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="previousCursorPosition(int, com.trolltech.qt.gui.QTextLayout.CursorMode)"><!-- --></A><H3>
previousCursorPosition</H3>
<PRE>
public final int <B>previousCursorPosition</B>(int&nbsp;oldPos,
                                        <A HREF="../../../../com/trolltech/qt/gui/QTextLayout.CursorMode.html" title="enum in com.trolltech.qt.gui">QTextLayout.CursorMode</A>&nbsp;mode)</PRE>
<DL>
<DD><p>Returns the first valid cursor position before <tt>oldPos</tt> that respects the given cursor <tt>mode</tt>.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#isValidCursorPosition(int)"><tt>isValidCursorPosition</tt></a>, 
<a href="QTextLayout.html#nextCursorPosition(int, com.trolltech.qt.gui.QTextLayout.CursorMode)"><tt>nextCursorPosition</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="setAdditionalFormats(java.util.List)"><!-- --></A><H3>
setAdditionalFormats</H3>
<PRE>
public final void <B>setAdditionalFormats</B>(java.util.List&lt;<A HREF="../../../../com/trolltech/qt/gui/QTextLayout_FormatRange.html" title="class in com.trolltech.qt.gui">QTextLayout_FormatRange</A>&gt;&nbsp;overrides)</PRE>
<DL>
<DD><p>Sets the additional formats supported by the text layout to <tt>overrides</tt>.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#additionalFormats()"><tt>additionalFormats</tt></a>, 
<a href="QTextLayout.html#clearAdditionalFormats()"><tt>clearAdditionalFormats</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="setCacheEnabled(boolean)"><!-- --></A><H3>
setCacheEnabled</H3>
<PRE>
public final void <B>setCacheEnabled</B>(boolean&nbsp;enable)</PRE>
<DL>
<DD><p>Enables caching of the complete layout information if <tt>enable</tt> is true; otherwise disables layout caching. Usually <a href="QTextLayout.html#QTextLayout(com.trolltech.qt.gui.QTextBlock)"><tt>QTextLayout</tt></a> throws most of the layouting information away after a call to <a href="QTextLayout.html#endLayout()"><tt>endLayout</tt></a> to reduce memory consumption. If you however want to draw the laid out text directly afterwards enabling caching might speed up drawing significantly.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#cacheEnabled()"><tt>cacheEnabled</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="setFont(com.trolltech.qt.gui.QFont)"><!-- --></A><H3>
setFont</H3>
<PRE>
public final void <B>setFont</B>(<A HREF="../../../../com/trolltech/qt/gui/QFont.html" title="class in com.trolltech.qt.gui">QFont</A>&nbsp;f)</PRE>
<DL>
<DD><p>Sets the layout's font to the given <tt>f</tt>. The layout is invalidated and must be laid out again.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#font()"><tt>font</tt></a>, 
<a href="QTextLayout.html#text()"><tt>text</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="setPosition(com.trolltech.qt.core.QPointF)"><!-- --></A><H3>
setPosition</H3>
<PRE>
public final void <B>setPosition</B>(<A HREF="../../../../com/trolltech/qt/core/QPointF.html" title="class in com.trolltech.qt.core">QPointF</A>&nbsp;p)</PRE>
<DL>
<DD><p>Moves the text layout to point <tt>p</tt>.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#position()"><tt>position</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="setPreeditArea(int, java.lang.String)"><!-- --></A><H3>
setPreeditArea</H3>
<PRE>
public final void <B>setPreeditArea</B>(int&nbsp;position,
                                 java.lang.String&nbsp;text)</PRE>
<DL>
<DD><p>Sets the <tt>position</tt> and <tt>text</tt> of the area in the layout that is processed before editing occurs.</p>
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="setText(java.lang.String)"><!-- --></A><H3>
setText</H3>
<PRE>
public final void <B>setText</B>(java.lang.String&nbsp;string)</PRE>
<DL>
<DD><p>Sets the layout's text to the given <tt>string</tt>. The layout is invalidated and must be laid out again.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#text()"><tt>text</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="setTextOption(com.trolltech.qt.gui.QTextOption)"><!-- --></A><H3>
setTextOption</H3>
<PRE>
public final void <B>setTextOption</B>(<A HREF="../../../../com/trolltech/qt/gui/QTextOption.html" title="class in com.trolltech.qt.gui">QTextOption</A>&nbsp;option)</PRE>
<DL>
<DD><p>Sets the text option structure that controls the layout process to the given <tt>option</tt>.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#textOption()"><tt>textOption</tt></a>, 
<a href="QTextOption.html"><tt>QTextOption</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="text()"><!-- --></A><H3>
text</H3>
<PRE>
public final java.lang.String <B>text</B>()</PRE>
<DL>
<DD><p>Returns the layout's text.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#setText(java.lang.String)"><tt>setText</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="textOption()"><!-- --></A><H3>
textOption</H3>
<PRE>
public final <A HREF="../../../../com/trolltech/qt/gui/QTextOption.html" title="class in com.trolltech.qt.gui">QTextOption</A> <B>textOption</B>()</PRE>
<DL>
<DD><p>Returns the current text option used to control the layout process.</p>
<P>
<DD><DL>
<DT><B>See Also:</B><DD><a href="QTextLayout.html#setTextOption(com.trolltech.qt.gui.QTextOption)"><tt>setTextOption</tt></a>, 
<a href="QTextOption.html"><tt>QTextOption</tt></a></DL>
</DD>
</DL>
<HR>

<A NAME="fromNativePointer(com.trolltech.qt.QNativePointer)"><!-- --></A><H3>
fromNativePointer</H3>
<PRE>
public static <A HREF="../../../../com/trolltech/qt/gui/QTextLayout.html" title="class in com.trolltech.qt.gui">QTextLayout</A> <B>fromNativePointer</B>(<A HREF="../../../../com/trolltech/qt/QNativePointer.html" title="class in com.trolltech.qt">QNativePointer</A>&nbsp;nativePointer)</PRE>
<DL>
<DD>This function returns the QTextLayout instance pointed to by nativePointer
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>nativePointer</CODE> - the QNativePointer of which object should be returned.</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>


<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../com/trolltech/qt/gui/QTextItem.RenderFlags.html" title="class in com.trolltech.qt.gui"><B>PREV CLASS</B></A>&nbsp;
&nbsp;<A HREF="../../../../com/trolltech/qt/gui/QTextLayout_FormatRange.html" title="class in com.trolltech.qt.gui"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../../../index.html?com/trolltech/qt/gui/QTextLayout.html" target="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="QTextLayout.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
&nbsp;<SCRIPT type="text/javascript">
  <!--
  if(window==top) {
    document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
  }
  //-->
</SCRIPT>
<NOSCRIPT>
  <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>


</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  SUMMARY:&nbsp;<A HREF="#nested_class_summary">NESTED</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->

<HR>

</BODY>
</HTML>