Uses of Class
net.minecraft.text.Style
-
Uses of Style in net.minecraft.client.font
Fields in net.minecraft.client.font declared as Style Modifier and Type Field Description private StyleTextHandler.LineBreakingVisitor. endStyleprivate StyleTextHandler.LineBreakingVisitor. lastSpaceStyleprivate StyleTextHandler.StyledString. styleMethods in net.minecraft.client.font that return Style Modifier and Type Method Description StyleTextHandler.LineBreakingVisitor. getEndingStyle()@Nullable StyleTextHandler. getStyleAt(OrderedText text, int x)Gets the style at thexposition in a text.@Nullable StyleTextHandler. getStyleAt(StringVisitable text, int x)Gets the style at thexposition in a text.Methods in net.minecraft.client.font with parameters of type Style Modifier and Type Method Description booleanTextHandler.LineBreakingVisitor. accept(int index, Style style, int codePoint)Visits a single character.voidTextHandler.LineWrappingConsumer. accept(Style style, int start, int end)Accepts the information on a line-wrap segment.booleanTextHandler.WidthLimitingVisitor. accept(int index, Style style, int codePoint)Visits a single character.booleanTextRenderer.Drawer. accept(int index, Style style, int codePoint)Visits a single character.private booleanTextHandler.LineBreakingVisitor. breakLine(int finishIndex, Style finishStyle)StringVisitableTextHandler.LineWrappingCollector. collectLine(int lineLength, int skippedLength, Style style)intTextHandler. getTrimmedLength(String text, int maxWidth, Style style)Returns the length of a string when it is trimmed to be at mostmaxWidthwide.floatTextHandler.WidthRetriever. getWidth(int codePoint, Style style)Returns the width of a character.List<StringVisitable>TextHandler. method_35714(StringVisitable stringVisitable, int int2, Style style, StringVisitable stringVisitable2)intTextHandler. method_35715(String string, int int2, Style style)StringTextHandler. method_35716(String string, int int2, Style style)intTextHandler. method_35717(String string, int int2, Style style)StringTextHandler. trimToWidth(String text, int maxWidth, Style style)Trim a string to be at mostmaxWidthwide.StringVisitableTextHandler. trimToWidth(StringVisitable text, int width, Style style)StringTextHandler. trimToWidthBackwards(String text, int maxWidth, Style style)Trim a string from right to left to be at mostmaxWidthwide.<T> Optional<T>TextHandler.StyledString. visit(StringVisitable.StyledVisitor<T> styledVisitor, Style style)Supplies this visitable's literal content and contextual style to the visitor.static booleanTextVisitFactory. visitBackwards(String text, Style style, CharacterVisitor visitor)Visits the code points of a string in backward (right to left) direction.static booleanTextVisitFactory. visitFormatted(String text, int startIndex, Style style, CharacterVisitor visitor)Visits the code points of a string, applying the formatting codes within.static booleanTextVisitFactory. visitFormatted(String text, int startIndex, Style startingStyle, Style resetStyle, CharacterVisitor visitor)Visits the code points of a string, applying the formatting codes within.static booleanTextVisitFactory. visitFormatted(String text, Style style, CharacterVisitor visitor)Visits the code points of a string, applying the formatting codes within.static booleanTextVisitFactory. visitFormatted(StringVisitable text, Style style, CharacterVisitor visitor)Visits the code points for every literal string and the formatting codes supplied by the renderable.static booleanTextVisitFactory. visitForwards(String text, Style style, CharacterVisitor visitor)Visits the code points of a string in forward (left to right) direction.private static booleanTextVisitFactory. visitRegularCharacter(Style style, CharacterVisitor visitor, int index, char c)List<StringVisitable>TextHandler. wrapLines(String text, int maxWidth, Style style)voidTextHandler. wrapLines(String text, int maxWidth, Style style, boolean retainTrailingWordSplit, TextHandler.LineWrappingConsumer consumer)List<StringVisitable>TextHandler. wrapLines(StringVisitable text, int maxWidth, Style style)voidTextHandler. wrapLines(StringVisitable text, int maxWidth, Style style, BiConsumer<StringVisitable,Boolean> biConsumer)Constructors in net.minecraft.client.font with parameters of type Style Constructor Description StyledString(String literal, Style style) -
Uses of Style in net.minecraft.client.gui.hud
Methods in net.minecraft.client.gui.hud that return Style Modifier and Type Method Description @Nullable StyleChatHud. getText(double x, double y) -
Uses of Style in net.minecraft.client.gui.screen
Fields in net.minecraft.client.gui.screen declared as Style Modifier and Type Field Description private static StyleCommandSuggestor. ERROR_FORMATTINGprivate static StyleCommandSuggestor. INFO_FORMATTINGFields in net.minecraft.client.gui.screen with type parameters of type Style Modifier and Type Field Description private static List<Style>CommandSuggestor. HIGHLIGHT_FORMATTINGSMethods in net.minecraft.client.gui.screen that return Style Modifier and Type Method Description private @Nullable StyleDeathScreen. getTextComponentUnderMouse(int mouseX)Methods in net.minecraft.client.gui.screen with parameters of type Style Modifier and Type Method Description booleanScreen. handleTextClick(@Nullable Style style)protected voidScreen. renderTextHoverEffect(MatrixStack matrices, @Nullable Style style, int x, int y) -
Uses of Style in net.minecraft.client.gui.screen.ingame
Fields in net.minecraft.client.gui.screen.ingame declared as Style Modifier and Type Field Description private StyleBookEditScreen.Line. styleprivate static StyleEnchantingPhrases. STYLEMethods in net.minecraft.client.gui.screen.ingame that return Style Modifier and Type Method Description @Nullable StyleBookScreen. getTextAt(double x, double y)Methods in net.minecraft.client.gui.screen.ingame with parameters of type Style Modifier and Type Method Description booleanBookScreen. handleTextClick(Style style)Constructors in net.minecraft.client.gui.screen.ingame with parameters of type Style Constructor Description Line(Style style, String content, int x, int y) -
Uses of Style in net.minecraft.client.resource.language
Fields in net.minecraft.client.resource.language with type parameters of type Style Modifier and Type Field Description private List<Style>TextReorderingProcessor. stylesConstructor parameters in net.minecraft.client.resource.language with type arguments of type Style Constructor Description TextReorderingProcessor(String string, List<Style> styles, Int2IntFunction reverser) -
Uses of Style in net.minecraft.item
Fields in net.minecraft.item declared as Style Modifier and Type Field Description private static StyleItemStack. LORE_STYLE -
Uses of Style in net.minecraft.scoreboard
Fields in net.minecraft.scoreboard declared as Style Modifier and Type Field Description private StyleTeam. nameStyle -
Uses of Style in net.minecraft.server.command
Fields in net.minecraft.server.command declared as Style Modifier and Type Field Description private static StyleTeamMsgCommand. STYLE -
Uses of Style in net.minecraft.text
Fields in net.minecraft.text declared as Style Modifier and Type Field Description static StyleStyle. EMPTYAn empty style.private StyleBaseText. styleMethods in net.minecraft.text that return Style Modifier and Type Method Description @Nullable StyleStyle.Serializer. deserialize(JsonElement jsonElement, Type type, JsonDeserializationContext jsonDeserializationContext)StyleBaseText. getStyle()Returns the style of this text.StyleText. getStyle()Returns the style of this text.StyleStyle. obfuscated(@Nullable Boolean obfuscated)private static StyleTexts. parseStyle(@Nullable ServerCommandSource source, Style style, @Nullable Entity sender, int depth)StyleStyle. withBold(@Nullable Boolean bold)Returns a new style with the bold attribute provided and all other attributes of this style.StyleStyle. withClickEvent(@Nullable ClickEvent clickEvent)Returns a new style with the click event provided and all other attributes of this style.StyleStyle. withColor(int rgbColor)StyleStyle. withColor(@Nullable TextColor color)Returns a new style with the color provided and all other attributes of this style.StyleStyle. withColor(@Nullable Formatting color)Returns a new style with the color provided and all other attributes of this style.StyleStyle. withExclusiveFormatting(Formatting formatting)Returns a new style with the formatting provided and some applicable attributes of this style.StyleStyle. withFont(@Nullable Identifier font)Returns a new style with the font provided and all other attributes of this style.StyleStyle. withFormatting(Formatting formatting)Returns a new style with the formatting provided and all other attributes of this style.StyleStyle. withFormatting(Formatting[] formattings)Returns a new style with the formattings provided and all other attributes of this style.StyleStyle. withHoverEvent(@Nullable HoverEvent hoverEvent)Returns a new style with the hover event provided and all other attributes of this style.StyleStyle. withInsertion(@Nullable String insertion)Returns a new style with the insertion provided and all other attributes of this style.StyleStyle. withItalic(@Nullable Boolean italic)Returns a new style with the italic attribute provided and all other attributes of this style.StyleStyle. withParent(Style parent)Returns a new style with the undefined attributes of this style filled by theparentstyle.StyleStyle. withStrikethrough(@Nullable Boolean strikethrough)StyleStyle. withUnderline(@Nullable Boolean underline)Returns a new style with the underline attribute provided and all other attributes of this style.Methods in net.minecraft.text with parameters of type Style Modifier and Type Method Description booleanCharacterVisitor. accept(int index, Style style, int codePoint)Visits a single character.Optional<T>StringVisitable.StyledVisitor. accept(Style style, String asString)Visits a string's content with a contextual style.private voidText.Serializer. addStyle(Style style, JsonObject json, JsonSerializationContext context)default MutableTextMutableText. fillStyle(Style styleOverride)Fills the absent parts of this text's style with definitions fromstyleOverride.static OrderedTextOrderedText. method_34908(String string, Style style, Int2IntFunction int2IntFunction)static OrderedTextOrderedText. method_34910(String string, Style style)default List<Text>Text. method_36136(Style style)private static StyleTexts. parseStyle(@Nullable ServerCommandSource source, Style style, @Nullable Entity sender, int depth)@Nullable JsonElementStyle.Serializer. serialize(Style style, Type type, JsonSerializationContext jsonSerializationContext)MutableTextBaseText. setStyle(Style style)Sets the style of this text.MutableTextMutableText. setStyle(Style style)Sets the style of this text.static MutableTextTexts. setStyleIfAbsent(MutableText text, Style style)static OrderedTextOrderedText. styled(int codePoint, Style style)static StringVisitableStringVisitable. styled(String string, Style style)Creates a visitable from a plain string and a root style.static OrderedTextOrderedText. styledString(String string, Style style)static OrderedTextOrderedText. styledStringMapped(String string, Style style, Int2IntFunction codePointMapper)<T> Optional<T>StringVisitable. visit(StringVisitable.StyledVisitor<T> styledVisitor, Style style)Supplies this visitable's literal content and contextual style to the visitor.default <T> Optional<T>Text. visit(StringVisitable.StyledVisitor<T> styledVisitor, Style style)Supplies this visitable's literal content and contextual style to the visitor.<T> Optional<T>KeybindText. visitSelf(StringVisitable.StyledVisitor<T> visitor, Style style)Visits the text itself.default <T> Optional<T>Text. visitSelf(StringVisitable.StyledVisitor<T> visitor, Style style)Visits the text itself.<T> Optional<T>TranslatableText. visitSelf(StringVisitable.StyledVisitor<T> visitor, Style style)Visits the text itself.StyleStyle. withParent(Style parent)Returns a new style with the undefined attributes of this style filled by theparentstyle.Method parameters in net.minecraft.text with type arguments of type Style Modifier and Type Method Description default MutableTextMutableText. styled(UnaryOperator<Style> styleUpdater)Updates the style of this text.