ChristopherHaws / mc-text-utilities

Adds buttons to set the color and formatting of text
GNU Lesser General Public License v3.0
2 stars 3 forks source link

Anvil-renamed items ignore #104

Open Mosscairn opened 5 months ago

Mosscairn commented 5 months ago

image ie, the string for this item is §k§b§lBasic §rTape The text displays properly in the anvil editor, but when the finished item is collected it reverts to italics again. image not exactly sure what's going on there but it would be lovely if that could be fixed. Thank you!

(using 1.6.1+1.20.1)

Hi-ImKyle commented 1 week ago

By default all custom named items are Italic. The reset code does not change that in this case because that's just how Minecraft displays custom names. The anvil showing you the correct formatting for what you would like is unaffected by the Italic part of a custom name.

I have only fixed this in my own colour mod, unfortunately I don't have a PR for this mod to fix it for you.

The fix is just explicitly making the Style of the MutableText/Text always use .withItalic(false) by default.. but I'm unsure if this will fix it for this mod.