Class LabelSettings
- Namespace
- Godot
- Assembly
- GodotSharp.dll
LabelSettings is a resource that provides common settings to customize the text in a Label. It will take priority over the properties defined in Theme. The resource can be shared between multiple labels and changed on the fly, so it's convenient and flexible way to setup text style.
public class LabelSettings : Resource, IDisposable
- Inheritance
-
LabelSettings
- Implements
- Inherited Members
Constructors
LabelSettings()
public LabelSettings()
Properties
Font
Font used for the text.
public Font Font { get; set; }
Property Value
FontColor
Color of the text.
public Color FontColor { get; set; }
Property Value
FontSize
Size of the text.
public int FontSize { get; set; }
Property Value
LineSpacing
Vertical space between lines when the text is multiline.
public float LineSpacing { get; set; }
Property Value
OutlineColor
The color of the outline.
public Color OutlineColor { get; set; }
Property Value
OutlineSize
Text outline size.
public int OutlineSize { get; set; }
Property Value
ShadowColor
Color of the shadow effect. If alpha is 0
, no shadow will be drawn.
public Color ShadowColor { get; set; }
Property Value
ShadowOffset
Offset of the shadow effect, in pixels.
public Vector2 ShadowOffset { get; set; }
Property Value
ShadowSize
Size of the shadow effect.
public int ShadowSize { get; set; }
Property Value
Methods
HasGodotClassMethod(in godot_string_name)
Check if the type contains a method with the given name. This method is used by Godot to check if a method exists before invoking it. Do not call or override this method.
protected override bool HasGodotClassMethod(in godot_string_name method)
Parameters
method
godot_string_nameName of the method to check for.
Returns
HasGodotClassSignal(in godot_string_name)
Check if the type contains a signal with the given name. This method is used by Godot to check if a signal exists before raising it. Do not call or override this method.
protected override bool HasGodotClassSignal(in godot_string_name signal)
Parameters
signal
godot_string_nameName of the signal to check for.
Returns
InvokeGodotClassMethod(in godot_string_name, NativeVariantPtrArgs, out godot_variant)
Invokes the method with the given name, using the given arguments. This method is used by Godot to invoke methods from the engine side. Do not call or override this method.
protected override bool InvokeGodotClassMethod(in godot_string_name method, NativeVariantPtrArgs args, out godot_variant ret)
Parameters
method
godot_string_nameName of the method to invoke.
args
NativeVariantPtrArgsArguments to use with the invoked method.
ret
godot_variantValue returned by the invoked method.