Leadtools.Windows.Controls Send comments on this topic. | Back to Introduction - LEADTOOLS WPF | Help Version 16.5.9.25
OwnerDrawStyleKey Property
See Also  Example
Leadtools.Windows.Controls Namespace > ImageListItem Class : OwnerDrawStyleKey Property





A resource key that represents the default OwnerDraw style for ImageListItem(s).

Syntax

Visual Basic (Declaration) 
Public Shared ReadOnly Property OwnerDrawStyleKey As ResourceKey
Visual Basic (Usage)Copy Code
Dim value As ResourceKey
 
value = ImageListItem.OwnerDrawStyleKey
C# 
public static ResourceKey OwnerDrawStyleKey {get;}
C++/CLI 
public:
static property ResourceKey OwnerDrawStyleKey {
   ResourceKey get();
}
XAML Attributes Usage 

<object property={x:Static ImageListItem.OwnerDrawStyleKey}/>

XAML Values 

System.Windows.ResourceKey A resource key that represents the OwnerDraw style for ImageListItem.

XAML Attributes Usage 

<object property={x:Static ImageListItem.OwnerDrawStyleKey}/>

XAML Values 

System.Windows.ResourceKey A resource key that represents the OwnerDraw style for ImageListItem.

Return Value

Gets the OwnerDraw style applied on ImageListItem

Example

This example creates an ImageListItem control and overrider it's style keys.

XAMLCopy Code
<Window Height="600" Width="800" Title="using ImageListItem with ListBox Sample" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:Leadtools_Windows_Controls="clr-namespace:Leadtools.Windows.Controls;assembly=Leadtools.Windows.Controls"> 
  <DockPanel> 
    <ListBox Name="theListBox" DockPanel.Dock="Bottom" HorizontalAlignment="Center" VerticalAlignment="Bottom"> 
      <Leadtools_Windows_Controls:ImageListItem ViewStyle="Normal" Image="file:///c:\Program Files\LEAD Technologies\LEADTOOLS 16\Images\slave.jpg" Text="slave.jpg" ShowText="True" SelectedForeground="Red" SelectedBackground="Yellow" FileName="e:\Program Files(32)\LEAD Technologies\LEADTOOLS 16\Images\slave.jpg" ImageSize="128,128" /> 
      <Leadtools_Windows_Controls:ImageListItem ViewStyle="Button" Image="file:///c:\Program Files\LEAD Technologies\LEADTOOLS 16\Images\clean.tif" Text="clean.tif" ShowText="False" FileName="e:\Program Files(32)\LEAD Technologies\LEADTOOLS 16\Images\clean.tif" ImageSize="150,150" /> 
    </ListBox> 
  </DockPanel> 
</Window>

Remarks

This property is used to change the OwnerDraw style for the ImageListItem.

Requirements

Target Platforms: Microsoft .NET Framework 3.0, Windows XP, Windows Vista, and Windows Server 2003 family

See Also