# C1.Win.TouchToolKit.C1Zoom.BackgroundImageLayout

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="C1_Win_TouchToolKit_C1Zoom_BackgroundImageLayout_" data-uid="C1.Win.TouchToolKit.C1Zoom.BackgroundImageLayout*">BackgroundImageLayout Property
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="C1_Win_TouchToolKit_C1Zoom_BackgroundImageLayout_" data-uid="C1.Win.TouchToolKit.C1Zoom.BackgroundImageLayout*"></a>
<h4 id="C1_Win_TouchToolKit_C1Zoom_BackgroundImageLayout" data-uid="C1.Win.TouchToolKit.C1Zoom.BackgroundImageLayout">BackgroundImageLayout</h4>
<div class="markdown level1 summary"><p>Gets or sets the background image layout as defined in the <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.forms.imagelayout">ImageLayout</a> enumeration.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public ImageLayout BackgroundImageLayout { get; set; }</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Property BackgroundImageLayout As ImageLayout</code></pre>
</div>
<h5 class="propertyValue">Property Value</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="https://learn.microsoft.com/dotnet/api/system.windows.forms.imagelayout">ImageLayout</a></td>
      <td><p>One of the values of <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.forms.imagelayout">ImageLayout</a> (<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.forms.imagelayout#system-windows-forms-imagelayout-center">Center</a> , <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.forms.imagelayout#system-windows-forms-imagelayout-none">None</a>, <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.forms.imagelayout#system-windows-forms-imagelayout-stretch">Stretch</a>, <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.forms.imagelayout#system-windows-forms-imagelayout-tile">Tile</a>, or <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.forms.imagelayout#system-windows-forms-imagelayout-zoom">Zoom</a>). <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.forms.imagelayout#system-windows-forms-imagelayout-tile">Tile</a> is the default value.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 id="C1_Win_TouchToolKit_C1Zoom_BackgroundImageLayout_remarks">Remarks</h5>
<div class="markdown level1 remarks"><p>
Use the BackgroundImageLayout property to specify the position and behavior of an image you have placed onto the blank areas of Form when to zoom and scroll. BackgroundImageLayout takes effect only if the <a class="xref" href="C1.Win.TouchToolKit.C1Zoom.BackgroundImage.html#C1_Win_TouchToolKit_C1Zoom_BackgroundImage">BackgroundImage</a> property is set.
</p>
</div>
<h5 id="C1_Win_TouchToolKit_C1Zoom_BackgroundImageLayout_examples">Examples</h5>
<p>
  The following code example shows how to use this property. 
</p>
<p>
  This code example is part of a larger example provided for the <a class="xref" href="C1.Win.TouchToolKit.C1Zoom.BackColor.html#C1_Win_TouchToolKit_C1Zoom_BackColor">BackColor</a> property. 
</p>
<pre><code class="lang-csharp">public class GcZoomBackColorDemo : Form
{
	private Button _backImageButton;
	private GcZoom _gcZoom1 = new GcZoom();

	public GcZoomBackColorDemo()
	{
		InitializeComponent();

		_gcZoom1.Target = this;

		_backImageButton.Click += _backImageButton_Click;
	}

	void _backImageButton_Click(object sender, EventArgs e)
	{
		this._gcZoom1.BackgroundImage = Image.FromFile(@"c:\backimage.jpg");
		this._gcZoom1.BackgroundImageLayout = ImageLayout.Stretch;
	}

	private void InitializeComponent()
	{
		_backImageButton = new Button();
		_backImageButton.Text = "BackImage";
		_backImageButton.Location = new Point(20, 50);
		_backImageButton.Size = new Size(120, 25);
		this.Controls.Add(_backImageButton);
	}
}</code></pre>
<pre><code class="lang-csharp">Public Class GcZoomBackColorDemo
	Inherits Form
	Private _backImageButton As Button
	Private _gcZoom1 As New GcZoom()

	Public Sub New()
		InitializeComponent()

		_gcZoom1.Target = Me

		AddHandler _backImageButton.Click, AddressOf _backImageButton_Click
	End Sub

	Private Sub _backImageButton_Click(sender As Object, e As EventArgs)
		Me._gcZoom1.BackgroundImage = Image.FromFile("c:\backimage.jpg")
 		Me._gcZoom1.BackgroundImageLayout = ImageLayout.Stretch
	End Sub

	Private Sub InitializeComponent()
		_backImageButton = New Button()
 		_backImageButton.Text = "BackImage"
 		_backImageButton.Location = New Point(20, 50)
 		_backImageButton.Size = New Size(120, 25)
		Me.Controls.Add(_backImageButton)
	End Sub
End Class</code></pre>

</div>
