FSlateDrawElement::MakeGradient

Creates a gradient element

Choose your operating system:

Windows

macOS

Linux

References

Module

SlateCore

Header

/Engine/Source/Runtime/SlateCore/Public/Rendering/DrawElements.h

Include

#include "Rendering/DrawElements.h"

Source

/Engine/Source/Runtime/SlateCore/Private/Rendering/DrawElements.cpp

Syntax

static void MakeGradient
(
    FSlateWindowElementList & ElementList,
    uint32 InLayer,
    const FPaintGeometry & PaintGeometry,
    TArray< FSlateGradientStop > InGradientStops,
    EOrientation InGradientType,
    ESlateDrawEffect InDrawEffects,
    FVector4 CornerRadius
)

Remarks

Creates a gradient element

Parameters

Parameter

Description

ElementList

The list in which to add elements

InLayer

The layer to draw the element on

PaintGeometry

DrawSpace position and dimensions; see FPaintGeometry

InGradientStops

List of gradient stops which define the element

InGradientType

The type of gradient (I.E Horizontal, vertical)

InDrawEffects

Optional draw effects to apply

CornerRadius

Rounds the corners of the box created by the gradient by the specified radius