Skip to content
\n

However, since I'm using Rich's print function, it will always render the :tada: emoji as 🎉. I have tried using rich.markup.escape as the docs suggest, but to no avail.

\n

Is it possible to escape the shortcode in this case?

","upvoteCount":1,"answerCount":1,"acceptedAnswer":{"@type":"Answer","text":"

You can disable emojis using the Console class:

\n
from rich.console import Console\n\n# Disable all emojis\nconsole = Console(emoji=False)\n\n# Disable emojis for specific prints\nconsole.print(\"No emoji! :tada:\", emoji=False)
","upvoteCount":2,"url":"https://github.com/Textualize/rich/discussions/3541#discussioncomment-11074182"}}}
Discussion options

You must be logged in to vote

You can disable emojis using the Console class:

from rich.console import Console

# Disable all emojis
console = Console(emoji=False)

# Disable emojis for specific prints
console.print("No emoji! :tada:", emoji=False)

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@manoelpqueiroz
Comment options

Answer selected by manoelpqueiroz
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants