DsPdfJS API - v9.1.0
    Preparing search index...

    Type Alias ButtonAppearanceProperties

    Defines properties of a ButtonAppearance object.

    type ButtonAppearanceProperties = {
        caption?: string;
        captionImageRelation?: CaptionImageRelation;
        downCaption?: string;
        image?: PdfImageHandler;
        imageScale?: ImageScaleProperties | "scale" | "stretch";
        rolloverCaption?: string;
    }
    Index

    Properties

    caption?: string

    The button's caption.

    captionImageRelation?: CaptionImageRelation

    Indicating how to position the button's caption relative to image.

    downCaption?: string

    The button's caption used when the mouse button is pressed within its active area.

    The button's image.

    You can use PdfImageHandler to assign an image to this property, for example:

    const img = await Image.load(IMAGE_BYTES);
    btn.buttonAppearance.image = doc.imageHandlers.GetImageHandler(img);
    imageScale?: ImageScaleProperties | "scale" | "stretch"

    The image scaling, it can be specified as an ImageScaleProperties object or one of predefined values: "scale", "stretch".

    rolloverCaption?: string

    The button's caption used when the user rolls the cursor into its active area without pressing the mouse button.