# C1.C1Preview.RenderText

## Content

<div class="doc-site-dotnet-api-container">



  <h1 id="C1_C1Preview_RenderText" data-uid="C1.C1Preview.RenderText" class="text-break">RenderText Class
</h1>
  <div class="markdown level0 summary"><p>Represents a run of text in a <a class="xref" href="C1.C1Preview.C1PrintDocument.html">C1PrintDocument</a>.
Text is drawn using a single style (see <a class="xref" href="C1.C1Preview.RenderParagraph.html">RenderParagraph</a> for multi-style text).</p>
</div>
  <div class="markdown level0 conceptual"></div>
  <div class="inheritance">
    <h5>Inheritance</h5>
    <div class="level0"><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object">object</a></div>
    <div class="level1"><a class="xref" href="C1.C1Preview.RenderObject.html">RenderObject</a></div>
    <div class="level2"><a class="xref" href="C1.C1Preview.RenderTextBase.html">RenderTextBase</a></div>
    <div class="level3"><span class="xref">RenderText</span></div>
      <div class="level4"><a class="xref" href="C1.C1Preview.RenderVerticalText.html">RenderVerticalText</a></div>
  </div>
  <div class="implements">
    <h5>Implements</h5>
    <div><a class="xref" href="C1.C1Preview.IStyleOwner.html">IStyleOwner</a></div>
    <div><a class="xref" href="C1.C1Preview.IDocumentLocation.html">IDocumentLocation</a></div>
  </div>
  <h6><strong>Namespace</strong>: <a class="xref" href="C1.C1Preview.html">C1.C1Preview</a></h6>
  <h6><strong>Assembly</strong>: C1.PrintDocument.4.8.dll</h6>
  <h5 id="C1_C1Preview_RenderText_syntax">Syntax</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public class RenderText : RenderTextBase, IStyleOwner, IDocumentLocation</code></pre>
  </div>
  <div class="codewrapper">
    <pre><code class="lang-vbnet hljs">Public Class RenderText
    Inherits RenderTextBase
    Implements IStyleOwner, IDocumentLocation</code></pre>
  </div>
  <h3 id="constructors">Constructors
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_C1Preview_RenderText__ctor" data-uid="C1.C1Preview.RenderText.#ctor">
          <a class="xref" href="C1.C1Preview.RenderText.-ctor.html#C1_C1Preview_RenderText__ctor">RenderText()</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="C1.C1Preview.RenderText.html">RenderText</a> class.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Preview_RenderText__ctor_System_String_" data-uid="C1.C1Preview.RenderText.#ctor(System.String)">
          <a class="xref" href="C1.C1Preview.RenderText.-ctor.html#C1_C1Preview_RenderText__ctor_System_String_">RenderText(string)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="C1.C1Preview.RenderText.html">RenderText</a> class,
assigning the <a class="xref" href="C1.C1Preview.RenderText.Text.html#C1_C1Preview_RenderText_Text">Text</a> property.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Preview_RenderText__ctor_System_String_C1_C1Preview_AlignHorzEnum_" data-uid="C1.C1Preview.RenderText.#ctor(System.String,C1.C1Preview.AlignHorzEnum)">
          <a class="xref" href="C1.C1Preview.RenderText.-ctor.html#C1_C1Preview_RenderText__ctor_System_String_C1_C1Preview_AlignHorzEnum_">RenderText(string, AlignHorzEnum)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="C1.C1Preview.RenderText.html">RenderText</a> class,
assigning the <a class="xref" href="C1.C1Preview.RenderText.Text.html#C1_C1Preview_RenderText_Text">Text</a> property,
and text alignment.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Preview_RenderText__ctor_System_String_C1_C1Preview_Style_" data-uid="C1.C1Preview.RenderText.#ctor(System.String,C1.C1Preview.Style)">
          <a class="xref" href="C1.C1Preview.RenderText.-ctor.html#C1_C1Preview_RenderText__ctor_System_String_C1_C1Preview_Style_">RenderText(string, Style)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="C1.C1Preview.RenderText.html">RenderText</a> class,
assigning the <a class="xref" href="C1.C1Preview.RenderText.Text.html#C1_C1Preview_RenderText_Text">Text</a> property and style.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Preview_RenderText__ctor_System_String_C1_C1Preview_Style_C1_C1Preview_Style_" data-uid="C1.C1Preview.RenderText.#ctor(System.String,C1.C1Preview.Style,C1.C1Preview.Style)">
          <a class="xref" href="C1.C1Preview.RenderText.-ctor.html#C1_C1Preview_RenderText__ctor_System_String_C1_C1Preview_Style_C1_C1Preview_Style_">RenderText(string, Style, Style)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="C1.C1Preview.RenderText.html">RenderText</a> class,
assigning the <a class="xref" href="C1.C1Preview.RenderText.Text.html#C1_C1Preview_RenderText_Text">Text</a> property,
and the parent styles.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Preview_RenderText__ctor_System_String_System_Drawing_Font_" data-uid="C1.C1Preview.RenderText.#ctor(System.String,System.Drawing.Font)">
          <a class="xref" href="C1.C1Preview.RenderText.-ctor.html#C1_C1Preview_RenderText__ctor_System_String_System_Drawing_Font_">RenderText(string, Font)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="C1.C1Preview.RenderText.html">RenderText</a> class,
assigning the <a class="xref" href="C1.C1Preview.RenderText.Text.html#C1_C1Preview_RenderText_Text">Text</a> property and font.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Preview_RenderText__ctor_System_String_System_Drawing_Font_C1_C1Preview_AlignHorzEnum_" data-uid="C1.C1Preview.RenderText.#ctor(System.String,System.Drawing.Font,C1.C1Preview.AlignHorzEnum)">
          <a class="xref" href="C1.C1Preview.RenderText.-ctor.html#C1_C1Preview_RenderText__ctor_System_String_System_Drawing_Font_C1_C1Preview_AlignHorzEnum_">RenderText(string, Font, AlignHorzEnum)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="C1.C1Preview.RenderText.html">RenderText</a> class,
assigning the <a class="xref" href="C1.C1Preview.RenderText.Text.html#C1_C1Preview_RenderText_Text">Text</a> property,
font and text alignment.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Preview_RenderText__ctor_System_String_System_Drawing_Font_System_Drawing_Color_" data-uid="C1.C1Preview.RenderText.#ctor(System.String,System.Drawing.Font,System.Drawing.Color)">
          <a class="xref" href="C1.C1Preview.RenderText.-ctor.html#C1_C1Preview_RenderText__ctor_System_String_System_Drawing_Font_System_Drawing_Color_">RenderText(string, Font, Color)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="C1.C1Preview.RenderText.html">RenderText</a> class,
assigning the <a class="xref" href="C1.C1Preview.RenderText.Text.html#C1_C1Preview_RenderText_Text">Text</a> property,
font and text color.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Preview_RenderText__ctor_System_String_System_Drawing_Font_System_Drawing_Color_C1_C1Preview_AlignHorzEnum_" data-uid="C1.C1Preview.RenderText.#ctor(System.String,System.Drawing.Font,System.Drawing.Color,C1.C1Preview.AlignHorzEnum)">
          <a class="xref" href="C1.C1Preview.RenderText.-ctor.html#C1_C1Preview_RenderText__ctor_System_String_System_Drawing_Font_System_Drawing_Color_C1_C1Preview_AlignHorzEnum_">RenderText(string, Font, Color, AlignHorzEnum)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="C1.C1Preview.RenderText.html">RenderText</a> class,
assigning the <a class="xref" href="C1.C1Preview.RenderText.Text.html#C1_C1Preview_RenderText_Text">Text</a> property,
font, text color and alignment.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="properties">Properties
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_C1Preview_RenderText_HasText" data-uid="C1.C1Preview.RenderText.HasText">
          <a class="xref" href="C1.C1Preview.RenderText.HasText.html#C1_C1Preview_RenderText_HasText">HasText</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a value indicating whether the <a class="xref" href="C1.C1Preview.RenderText.Text.html#C1_C1Preview_RenderText_Text">Text</a> property of the current object is
not <b>null</b> and has a greater than zero length.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Preview_RenderText_Text" data-uid="C1.C1Preview.RenderText.Text">
          <a class="xref" href="C1.C1Preview.RenderText.Text.html#C1_C1Preview_RenderText_Text">Text</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the text of the current object.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Preview_RenderText_TextLength" data-uid="C1.C1Preview.RenderText.TextLength">
          <a class="xref" href="C1.C1Preview.RenderText.TextLength.html#C1_C1Preview_RenderText_TextLength">TextLength</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the length of the string returned by the <a class="xref" href="C1.C1Preview.RenderText.Text.html#C1_C1Preview_RenderText_Text">Text</a> property.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="methods">Methods
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_C1Preview_RenderText_AssignFrom_C1_C1Preview_RenderObject_System_Boolean_System_Boolean_System_Boolean_System_Boolean_System_Boolean_System_Boolean_" data-uid="C1.C1Preview.RenderText.AssignFrom(C1.C1Preview.RenderObject,System.Boolean,System.Boolean,System.Boolean,System.Boolean,System.Boolean,System.Boolean)">
          <a class="xref" href="C1.C1Preview.RenderText.AssignFrom.html#C1_C1Preview_RenderText_AssignFrom_C1_C1Preview_RenderObject_System_Boolean_System_Boolean_System_Boolean_System_Boolean_System_Boolean_System_Boolean_">AssignFrom(RenderObject, bool, bool, bool, bool, bool, bool)</a>
        </td>
        <td class="markdown level1 summary"><p>Assigns (copies) properties from another <a class="xref" href="C1.C1Preview.RenderObject.html">RenderObject</a> to the current object.
Calls the base <a class="xref" href="C1.C1Preview.RenderObject.AssignFrom.html#C1_C1Preview_RenderObject_AssignFrom_C1_C1Preview_RenderObject_System_Boolean_System_Boolean_System_Boolean_System_Boolean_System_Boolean_System_Boolean_">AssignFrom(RenderObject, bool, bool, bool, bool, bool, bool)</a> method.
If <code class="paramref">source</code> is a <a class="xref" href="C1.C1Preview.RenderText.html">RenderText</a>, also copies <a class="xref" href="C1.C1Preview.RenderText.html">RenderText</a>-specific properties.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Preview_RenderText_CreateSame" data-uid="C1.C1Preview.RenderText.CreateSame">
          <a class="xref" href="C1.C1Preview.RenderText.CreateSame.html#C1_C1Preview_RenderText_CreateSame">CreateSame()</a>
        </td>
        <td class="markdown level1 summary"><p>Creates new empty <a class="xref" href="C1.C1Preview.RenderText.html">RenderText</a> object
linked with same <a class="xref" href="C1.C1Preview.C1PrintDocument.html">C1PrintDocument</a> as current object.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Preview_RenderText_ShouldSerializeText" data-uid="C1.C1Preview.RenderText.ShouldSerializeText">
          <a class="xref" href="C1.C1Preview.RenderText.ShouldSerializeText.html#C1_C1Preview_RenderText_ShouldSerializeText">ShouldSerializeText()</a>
        </td>
        <td class="markdown level1 summary"><p>Indicates whether the <a class="xref" href="C1.C1Preview.RenderText.Text.html#C1_C1Preview_RenderText_Text">Text</a> property should be serialized.</p>
</td>
      </tr>
    </tbody>
  </table>

</div>
