Skip to content
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

markup=False no longer working (since 0.86.0) #5468

Closed
davep opened this issue Jan 9, 2025 · 1 comment · Fixed by #5471
Closed

markup=False no longer working (since 0.86.0) #5468

davep opened this issue Jan 9, 2025 · 1 comment · Fixed by #5471

Comments

@davep
Copy link
Contributor

davep commented Jan 9, 2025

Given this code:

from rich.markup import escape
from textual.app import App, ComposeResult
from textual.widgets import Label

class MarkupApp(App[None]):

    def compose(self) -> ComposeResult:
        yield Label("Vanilla: [is this here?]")
        yield Label("markup=False: [is this here?]", markup=False)
        yield Label("Escaped: " + escape("[is this here?]"))
        yield Label("Escaped and markup=False: " + escape("[is this here?]"), markup=False)

if __name__ == "__main__":
    MarkupApp().run()

at the moment the result looks like this:

Screenshot 2025-01-09 at 16 50 30

Note that the Label with markup=False is still swallowing the markup.

If I go back to Textual 0.85 the result is as per the documentation:

Screenshot 2025-01-09 at 16 50 03

Copy link

Don't forget to star the repository!

Follow @textualizeio for Textual updates.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant