MCStyle
Importing the class
It might be required for you to import the package if you encounter any issues (like casting an Array), so better be safe than sorry and add the import at the very top of the file.
Constructors
No Description Provided
Methods
Applies the formatting characteristics (Bold, Italic, Obfucated, etc) of the given MCTExtFormatting as well as the colour of the formatting.
Returns: A new MCStyle with the given Formatting.
Return Type: MCStyle
Parameter | Type | Description |
---|---|---|
Parameter formatting | Type TextFormatting | Description The formatting to set. |
Return Type: boolean
Parameter | Type | Description |
---|---|---|
Parameter other | Type Object | Description No Description Provided |
Return Type: boolean
Return Type: int
Return Type: MCResourceLocation
Return Type: string
Return Type: boolean
Return Type: boolean
Return Type: boolean
Return Type: boolean
Return Type: int
Whether or not this style is empty (inherits everything from the parent).
Return Type: boolean
Return Type: MCStyle
Parameter | Type | Description |
---|---|---|
Parameter boldIn | Type bool? | Description No Description Provided |
Return Type: MCStyle
Parameter | Type | Description |
---|---|---|
Parameter colour | Type int | Description No Description Provided |
Return Type: MCStyle
Parameter | Type | Description |
---|---|---|
Parameter formatting | Type TextFormatting | Description No Description Provided |
Return Type: MCStyle
Parameter | Type | Description |
---|---|---|
Parameter location | Type MCResourceLocation | Description No Description Provided |
Sets the formatting of the style.
This will only take the colour of the text formatting, so using <formatting:obfuscated>
would not do anything as it does not have a colour.
If you want to take the actual characteristics of the MCTextFormatting, use MCStyle#applyFormatting(MCTextFormatting)
Returns: A new MCStyle with the given Formatting.
Return Type: MCStyle
Parameter | Type | Description |
---|---|---|
Parameter formatting | Type TextFormatting | Description The formatting to set. |
Set a text to be inserted into Chat when the component is shift-clicked
Return Type: MCStyle
Parameter | Type | Description |
---|---|---|
Parameter insertion | Type string | Description No Description Provided |
Return Type: MCStyle
Parameter | Type | Description |
---|---|---|
Parameter italic | Type bool? | Description No Description Provided |
Return Type: MCStyle
Parameter | Type | Description |
---|---|---|
Parameter obfuscated | Type bool? | Description No Description Provided |
Return Type: MCStyle
Parameter | Type | Description |
---|---|---|
Parameter strikethrough | Type bool? | Description No Description Provided |
Return Type: MCStyle
Parameter | Type | Description |
---|---|---|
Parameter underlined | Type bool? | Description No Description Provided |
Return Type: MCStyle
Parameter | Type | Description |
---|---|---|
Parameter underlined | Type boolean | Description No Description Provided |
Return Type: string