-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TextFormat: Add colors and harmonize class #6483
Conversation
Sadly I believe this has the same blocker as #5838 |
The unique blocked is the BC on removing underline and strikethrough |
Yup my bad I tought this was a more recent thing (the color update) so I didn't checked PR that's old.
So what's next ? Basically his PR is more detailed than mine (and does not forget the whole terminal stuff and regexes).. |
First, when you need to add an and word in your PR it mean that you need to create multiple PRs. But for now, if we want to include the new colour, feel free to add only the colours and not to remove the underline and strikethrough, which are BC (not until PM6). But each time the PRs do everything at the same time, which blocks the merge. |
You mean an "and" word? |
This still creates problems for terminal usage, since people using the new colour constants will get unexpected text effects on the terminal. There's a reason no one added these already. It's BC-breaking no matter what change is made. |
I mean, is it really an issue that the old underline and strikethrough change to a color ? No one is using it anymore since it's not usable in game.. The BC break seems "acceptable" to me |
No BC breaks on minor or patch versions. Those are the rules. |
Can we even qualify a color change on a console (so an administrator tool) a BC break ? |
Alternatively, why not block colors directly in the terminal by resetting the color with |
Closing this as #5838 is more complete and doesn't contain unrelated changes. |
Introduction
The new bedrock colors in chat are not usable on server side (console and command/chat parsing) due to TextFormat not being up to date.
The class was mixing self:: and TextFormat:: use reference the class itself. I opted to harmonize it to self::
Relevant issues
None
Changes
API changes
None
Behavioural changes
The colors will now be parsed and be shown correctly server side.
Backwards compatibility
None
The names and specific colors where extract from the "semi-official" wiki https://minecraft.wiki/w/Formatting_codes