Skip to content

Class endstone::SignSide

ClassList > endstone > SignSide

Represents a side of a sign.

  • #include <endstone/block/sign/sign_side.h>

Public Functions

Type Name
virtual Color getColor () const = 0
Gets the color of this side of the sign.
virtual std::string getLine (int index) const = 0
Gets the line of text at the specified index on this side of the sign.
virtual std::vector< std::string > getLines () const = 0
Gets all the lines of text currently on this side of the sign.
virtual bool isGlowingText () const = 0
Gets whether this side of the sign has glowing text.
virtual void setColor (Color color) = 0
Sets the color of this side of the sign.
virtual void setGlowingText (bool glowing) = 0
Sets whether this side of the sign has glowing text.
virtual void setLine (int index, std::string line) = 0
Sets the line of text at the specified index on this side of the sign.
virtual ~SignSide () = default

Public Functions Documentation

function getColor

Gets the color of this side of the sign.

virtual Color endstone::SignSide::getColor () const = 0

Bedrock stores the text color of a sign as a color rather than as one of the dyes, so this returns a Color where Bukkit returns a DyeColor.

Returns:

the color


function getLine

Gets the line of text at the specified index on this side of the sign.

virtual std::string endstone::SignSide::getLine (
    int index
) const = 0

For example, getLine(0) will return the first line of text.

Parameters:

  • index the index of the line to get, between 0 and 3

Returns:

the text of the line, empty if the line is blank


function getLines

Gets all the lines of text currently on this side of the sign.

virtual std::vector< std::string > endstone::SignSide::getLines () const = 0

Returns:

the lines of text


function isGlowingText

Gets whether this side of the sign has glowing text.

virtual bool endstone::SignSide::isGlowingText () const = 0

Returns:

true if this side of the sign has glowing text


function setColor

Sets the color of this side of the sign.

virtual void endstone::SignSide::setColor (
    Color color
) = 0

Parameters:

  • color the color to set

function setGlowingText

Sets whether this side of the sign has glowing text.

virtual void endstone::SignSide::setGlowingText (
    bool glowing
) = 0

Parameters:

  • glowing whether this side of the sign has glowing text

function setLine

Sets the line of text at the specified index on this side of the sign.

virtual void endstone::SignSide::setLine (
    int index,
    std::string line
) = 0

For example, setLine(0, "Line One") will set the first line to "Line One".

Parameters:

  • index the index of the line to set, between 0 and 3
  • line the new text to set

function ~SignSide

virtual endstone::SignSide::~SignSide () = default


The documentation for this class was generated from the following file include/endstone/block/sign/sign_side.h