How can I use subscripts in a Tkinter Label?
I found a lot of posts like this, but that does not help me…
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
For rich formatting, use a small text widget rather than a label. You then have the ability to add all kinds of formatting to the information. You can, for example, use the
offsetattribute on a text tag to create superscripts and subscripts.Just set state to
disabledafter configuring the widget, and for all intents and purposes it will look like a label. The main difference is that you have to manually set the size since a text widget won’t expand to fit its contents like a label does.For example: