TX Text Control .NET for WPF

ImageEventArgs Class

Class
Namespace
TXTextControl
Package
TXTextControl.TextControl.WPF.SDK from the private NuGet feed or Text Control Offline Packages
Assembly
TXTextControl.dll
Install
dotnet add package TXTextControl.TextControl.WPF.SDK .NET 8 and later. For .NET Framework, reference TXTextControl.dll from the setup.
Inherits
  1. EventArgs
  2. ImageEventArgs

Description

The ImageEventArgs class provides data for all events that occur with images. These are the TextControl.ImageCreated, TextControl.ImageDeleted, TextControl.ImageClicked, TextControl.ImageDoubleClicked, TextControl.ImageRightClicked, TextControl.ImageMoved, TextControl.ImageSelected, TextControl.ImageDeselected and TextControl.ImageSized events.

Syntax

public class ImageEventArgs : EventArgs

Examples

The following example uses ImageEventArgs.Image while handling ImageClicked.

textControl.ImageClicked += (_, e) =>
{
    if (e.Image != null)
    {
        e.Image.DescriptiveText = "Quarterly sales by region";
    }
};

Members

Properties

PropertyDescription
ImageGets an object that represents the image which causes the event. It is of the type Image.

Further Reading

  • Resize Images to Fit into Page –