# GrapeCity.Documents.Imaging.GcBitmap.AddShadow

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="GrapeCity_Documents_Imaging_GcBitmap_AddShadow_" data-uid="GrapeCity.Documents.Imaging.GcBitmap.AddShadow*">AddShadow Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="GrapeCity_Documents_Imaging_GcBitmap_AddShadow_" data-uid="GrapeCity.Documents.Imaging.GcBitmap.AddShadow*"></a>
<h4 id="GrapeCity_Documents_Imaging_GcBitmap_AddShadow_System_Int32_System_Int32_System_Nullable_System_Drawing_Color__System_Drawing_Color_System_Single_System_Int32_" data-uid="GrapeCity.Documents.Imaging.GcBitmap.AddShadow(System.Int32,System.Int32,System.Nullable{System.Drawing.Color},System.Drawing.Color,System.Single,System.Int32)">AddShadow(int, int, Color?, Color, float, int)</h4>
<div class="markdown level1 summary"><p>Creates a new bitmap by adding a shadow to text and graphics on the current image.
The shadow appears only if some pixels of the current image are transparent or semi-transparent.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public GcBitmap AddShadow(int xOffset, int yOffset, Color? backColor, Color shadowColor, float shadowOpacity = 0.6, int gaussianBlurRadius = 9)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Function AddShadow(xOffset As Integer, yOffset As Integer, backColor As Color?, shadowColor As Color, Optional shadowOpacity As Single = 0.6, Optional gaussianBlurRadius As Integer = 9) As GcBitmap</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">xOffset</span></td>
      <td><p>The horizontal offset of the shadow, in pixels.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">yOffset</span></td>
      <td><p>The vertical offset of the shadow, in pixels.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.drawing.color">Color</a>?</td>
      <td><span class="parametername">backColor</span></td>
      <td><p>The optional background color of the resulting image.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.drawing.color">Color</a></td>
      <td><span class="parametername">shadowColor</span></td>
      <td><p>The shadow color.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.single">float</a></td>
      <td><span class="parametername">shadowOpacity</span></td>
      <td><p>The shadow opacity, from 0 to 1.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">gaussianBlurRadius</span></td>
      <td><p>The shadow blur radius, in pixels.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="GrapeCity.Documents.Imaging.GcBitmap.html">GcBitmap</a></td>
      <td><p>A <a class="xref" href="GrapeCity.Documents.Imaging.GcBitmap.html">GcBitmap</a> with the added shadow.</p>
</td>
    </tr>
  </tbody>
</table>
</div>
