# C1.Util.DX.Size2D

## Content

<div class="doc-site-dotnet-api-container">



  <h1 id="C1_Util_DX_Size2D" data-uid="C1.Util.DX.Size2D" class="text-break">Size2D Struct
</h1>
  <div class="markdown level0 summary"><p>Structure specifing a size with double Width and Height.</p>
</div>
  <div class="markdown level0 conceptual"></div>
  <div class="implements">
    <h5>Implements</h5>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.iequatable-1">IEquatable</a>&lt;<a class="xref" href="C1.Util.DX.Size2D.html">Size2D</a>&gt;</div>
  </div>
  <h6><strong>Namespace</strong>: <a class="xref" href="C1.Util.DX.html">C1.Util.DX</a></h6>
  <h6><strong>Assembly</strong>: C1.Win.DX.4.8.dll</h6>
  <h5 id="C1_Util_DX_Size2D_syntax">Syntax</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public struct Size2D : IEquatable&lt;Size2D&gt;</code></pre>
  </div>
  <div class="codewrapper">
    <pre><code class="lang-vbnet hljs">Public Structure Size2D
    Implements IEquatable(Of Size2D)</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_Util_DX_Size2D__ctor_C1_Util_DX_Size2F_" data-uid="C1.Util.DX.Size2D.#ctor(C1.Util.DX.Size2F)">
          <a class="xref" href="C1.Util.DX.Size2D.-ctor.html#C1_Util_DX_Size2D__ctor_C1_Util_DX_Size2F_">Size2D(Size2F)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="C1.Util.DX.Size2D.html">Size2D</a> struct.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D__ctor_C1_Win_Interop_Size_" data-uid="C1.Util.DX.Size2D.#ctor(C1.Win.Interop.Size)">
          <a class="xref" href="C1.Util.DX.Size2D.-ctor.html#C1_Util_DX_Size2D__ctor_C1_Win_Interop_Size_">Size2D(Size)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="C1.Util.DX.Size2D.html">Size2D</a> struct.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D__ctor_System_Double_System_Double_" data-uid="C1.Util.DX.Size2D.#ctor(System.Double,System.Double)">
          <a class="xref" href="C1.Util.DX.Size2D.-ctor.html#C1_Util_DX_Size2D__ctor_System_Double_System_Double_">Size2D(double, double)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="C1.Util.DX.Size2D.html">Size2D</a> struct.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D__ctor_System_Drawing_SizeF_" data-uid="C1.Util.DX.Size2D.#ctor(System.Drawing.SizeF)">
          <a class="xref" href="C1.Util.DX.Size2D.-ctor.html#C1_Util_DX_Size2D__ctor_System_Drawing_SizeF_">Size2D(SizeF)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="C1.Util.DX.Size2D.html">Size2D</a> struct.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="fields">Fields
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_Util_DX_Size2D_Empty" data-uid="C1.Util.DX.Size2D.Empty">
          <a class="xref" href="C1.Util.DX.Size2D.Empty.html">Empty</a>
        </td>
        <td class="markdown level1 summary"><p>An empty size.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_Height" data-uid="C1.Util.DX.Size2D.Height">
          <a class="xref" href="C1.Util.DX.Size2D.Height.html">Height</a>
        </td>
        <td class="markdown level1 summary"><p>The vertical component of this <a class="xref" href="C1.Util.DX.Size2D.html">Size2D</a> structure.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_Infinite" data-uid="C1.Util.DX.Size2D.Infinite">
          <a class="xref" href="C1.Util.DX.Size2D.Infinite.html">Infinite</a>
        </td>
        <td class="markdown level1 summary"><p>A size with infinite Width and Height.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_SizeInBytes" data-uid="C1.Util.DX.Size2D.SizeInBytes">
          <a class="xref" href="C1.Util.DX.Size2D.SizeInBytes.html">SizeInBytes</a>
        </td>
        <td class="markdown level1 summary"><p>The size of the <a class="xref" href="C1.Util.DX.Size2D.html">Size2D</a> type, in bytes.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_Width" data-uid="C1.Util.DX.Size2D.Width">
          <a class="xref" href="C1.Util.DX.Size2D.Width.html">Width</a>
        </td>
        <td class="markdown level1 summary"><p>The horizontal component of this <a class="xref" href="C1.Util.DX.Size2D.html">Size2D</a> structure.</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_Util_DX_Size2D_IsEmpty" data-uid="C1.Util.DX.Size2D.IsEmpty">
          <a class="xref" href="C1.Util.DX.Size2D.IsEmpty.html#C1_Util_DX_Size2D_IsEmpty">IsEmpty</a>
        </td>
        <td class="markdown level1 summary"><p>Determines if all components of <a class="xref" href="C1.Util.DX.Size2D.html">Size2D</a> are equal to zero.</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_Util_DX_Size2D_Add_C1_Util_DX_Size2D_C1_Util_DX_Size2D_" data-uid="C1.Util.DX.Size2D.Add(C1.Util.DX.Size2D,C1.Util.DX.Size2D)">
          <a class="xref" href="C1.Util.DX.Size2D.Add.html#C1_Util_DX_Size2D_Add_C1_Util_DX_Size2D_C1_Util_DX_Size2D_">Add(Size2D, Size2D)</a>
        </td>
        <td class="markdown level1 summary"><p>Adds the width and height of one Size2D structure to the width and height of another Size2D structure.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_Equals_C1_Util_DX_Size2D_" data-uid="C1.Util.DX.Size2D.Equals(C1.Util.DX.Size2D)">
          <a class="xref" href="C1.Util.DX.Size2D.Equals.html#C1_Util_DX_Size2D_Equals_C1_Util_DX_Size2D_">Equals(Size2D)</a>
        </td>
        <td class="markdown level1 summary"><p>Indicates whether this instance and a specified object are equal.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_Equals_System_Object_" data-uid="C1.Util.DX.Size2D.Equals(System.Object)">
          <a class="xref" href="C1.Util.DX.Size2D.Equals.html#C1_Util_DX_Size2D_Equals_System_Object_">Equals(object)</a>
        </td>
        <td class="markdown level1 summary"><p>Indicates whether this instance and a specified object are equal.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_GetHashCode" data-uid="C1.Util.DX.Size2D.GetHashCode">
          <a class="xref" href="C1.Util.DX.Size2D.GetHashCode.html#C1_Util_DX_Size2D_GetHashCode">GetHashCode()</a>
        </td>
        <td class="markdown level1 summary"><p>Returns a hash code for this instance.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_Round" data-uid="C1.Util.DX.Size2D.Round">
          <a class="xref" href="C1.Util.DX.Size2D.Round.html#C1_Util_DX_Size2D_Round">Round()</a>
        </td>
        <td class="markdown level1 summary"><p>Returns a <a class="xref" href="C1.Util.DX.Size2L.html">Size2L</a> with rounded width and height.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_Scale_C1_Util_DX_Size2D_System_Double_" data-uid="C1.Util.DX.Size2D.Scale(C1.Util.DX.Size2D,System.Double)">
          <a class="xref" href="C1.Util.DX.Size2D.Scale.html#C1_Util_DX_Size2D_Scale_C1_Util_DX_Size2D_System_Double_">Scale(Size2D, double)</a>
        </td>
        <td class="markdown level1 summary"><p>Scales the width and height by the specified scaleFactor.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_Scale_C1_Util_DX_Size2D_System_Double_System_Double_" data-uid="C1.Util.DX.Size2D.Scale(C1.Util.DX.Size2D,System.Double,System.Double)">
          <a class="xref" href="C1.Util.DX.Size2D.Scale.html#C1_Util_DX_Size2D_Scale_C1_Util_DX_Size2D_System_Double_System_Double_">Scale(Size2D, double, double)</a>
        </td>
        <td class="markdown level1 summary"><p>Scales the width and height by the specified scaleX and scaleY.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_Scale_System_Double_" data-uid="C1.Util.DX.Size2D.Scale(System.Double)">
          <a class="xref" href="C1.Util.DX.Size2D.Scale.html#C1_Util_DX_Size2D_Scale_System_Double_">Scale(double)</a>
        </td>
        <td class="markdown level1 summary"><p>Scales the width and height by the specified scaleFactor.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_Scale_System_Double_System_Double_" data-uid="C1.Util.DX.Size2D.Scale(System.Double,System.Double)">
          <a class="xref" href="C1.Util.DX.Size2D.Scale.html#C1_Util_DX_Size2D_Scale_System_Double_System_Double_">Scale(double, double)</a>
        </td>
        <td class="markdown level1 summary"><p>Scales the width and height by the specified scaleX and scaleY.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_Subtract_C1_Util_DX_Size2D_C1_Util_DX_Size2D_" data-uid="C1.Util.DX.Size2D.Subtract(C1.Util.DX.Size2D,C1.Util.DX.Size2D)">
          <a class="xref" href="C1.Util.DX.Size2D.Subtract.html#C1_Util_DX_Size2D_Subtract_C1_Util_DX_Size2D_C1_Util_DX_Size2D_">Subtract(Size2D, Size2D)</a>
        </td>
        <td class="markdown level1 summary"><p>Subtracts the width and height of one Size2D structure from the width and height of another Size2D structure.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_ToSize" data-uid="C1.Util.DX.Size2D.ToSize">
          <a class="xref" href="C1.Util.DX.Size2D.ToSize.html#C1_Util_DX_Size2D_ToSize">ToSize()</a>
        </td>
        <td class="markdown level1 summary"><p>Converts <a class="xref" href="C1.Util.DX.Size2D.html">Size2D</a> to <span class="xref">C1.Win.Interop.Size</span>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_ToSize2F" data-uid="C1.Util.DX.Size2D.ToSize2F">
          <a class="xref" href="C1.Util.DX.Size2D.ToSize2F.html#C1_Util_DX_Size2D_ToSize2F">ToSize2F()</a>
        </td>
        <td class="markdown level1 summary"><p>Converts <a class="xref" href="C1.Util.DX.Size2D.html">Size2D</a> to <a class="xref" href="C1.Util.DX.Size2F.html">Size2F</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_ToSizeF" data-uid="C1.Util.DX.Size2D.ToSizeF">
          <a class="xref" href="C1.Util.DX.Size2D.ToSizeF.html#C1_Util_DX_Size2D_ToSizeF">ToSizeF()</a>
        </td>
        <td class="markdown level1 summary"><p>Converts <a class="xref" href="C1.Util.DX.Size2D.html">Size2D</a> to <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.drawing.sizef">SizeF</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_ToString" data-uid="C1.Util.DX.Size2D.ToString">
          <a class="xref" href="C1.Util.DX.Size2D.ToString.html#C1_Util_DX_Size2D_ToString">ToString()</a>
        </td>
        <td class="markdown level1 summary"><p>Returns a string that represents the current object.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_Truncate" data-uid="C1.Util.DX.Size2D.Truncate">
          <a class="xref" href="C1.Util.DX.Size2D.Truncate.html#C1_Util_DX_Size2D_Truncate">Truncate()</a>
        </td>
        <td class="markdown level1 summary"><p>Returns a <a class="xref" href="C1.Util.DX.Size2L.html">Size2L</a> with truncated width and height.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="operators">Operators
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_Util_DX_Size2D_op_Equality_C1_Util_DX_Size2D_C1_Util_DX_Size2D_" data-uid="C1.Util.DX.Size2D.op_Equality(C1.Util.DX.Size2D,C1.Util.DX.Size2D)">
          <a class="xref" href="C1.Util.DX.Size2D.op_Equality.html#C1_Util_DX_Size2D_op_Equality_C1_Util_DX_Size2D_C1_Util_DX_Size2D_">operator ==(Size2D, Size2D)</a>
        </td>
        <td class="markdown level1 summary"><p>Determines if the specified values are equal.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_op_Explicit_C1_Util_DX_Size2D__C1_Win_Interop_Size" data-uid="C1.Util.DX.Size2D.op_Explicit(C1.Util.DX.Size2D)~C1.Win.Interop.Size">
          <a class="xref" href="C1.Util.DX.Size2D.op_Explicit.html#C1_Util_DX_Size2D_op_Explicit_C1_Util_DX_Size2D__C1_Win_Interop_Size">explicit operator Size(Size2D)</a>
        </td>
        <td class="markdown level1 summary"><p>Performs an explicit conversion from <a class="xref" href="C1.Util.DX.Size2D.html">Size2D</a> to <span class="xref">C1.Win.Interop.Size</span>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_op_Explicit_C1_Win_Interop_Size__C1_Util_DX_Size2D" data-uid="C1.Util.DX.Size2D.op_Explicit(C1.Win.Interop.Size)~C1.Util.DX.Size2D">
          <a class="xref" href="C1.Util.DX.Size2D.op_Explicit.html#C1_Util_DX_Size2D_op_Explicit_C1_Win_Interop_Size__C1_Util_DX_Size2D">explicit operator Size2D(Size)</a>
        </td>
        <td class="markdown level1 summary"><p>Performs an explicit conversion from <span class="xref">C1.Win.Interop.Size</span> to <a class="xref" href="C1.Util.DX.Size2D.html">Size2D</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Util_DX_Size2D_op_Inequality_C1_Util_DX_Size2D_C1_Util_DX_Size2D_" data-uid="C1.Util.DX.Size2D.op_Inequality(C1.Util.DX.Size2D,C1.Util.DX.Size2D)">
          <a class="xref" href="C1.Util.DX.Size2D.op_Inequality.html#C1_Util_DX_Size2D_op_Inequality_C1_Util_DX_Size2D_C1_Util_DX_Size2D_">operator !=(Size2D, Size2D)</a>
        </td>
        <td class="markdown level1 summary"><p>Determines if the specified values are not equal.</p>
</td>
      </tr>
    </tbody>
  </table>

</div>
