How to add subscript in labels in App Designer Matlab

조회 수: 30 (최근 30일)
Shankar Dutt
Shankar Dutt 2018년 11월 7일
편집: Cris LaPierre 2024년 4월 10일
Hey, I want to add subscript/superscript in label text. Being new in the community, kindly help as I don't know much.
  댓글 수: 1
Allen
Allen 2021년 12월 13일
Shankar,
I would not consider may recommendation as an answer. However, until MathWorks adds all text elements to 'tex' and 'latex' interpreters for App Designer labels, I have been stacking labels to create the appearance of subscript and/or superscript text in my labels.
My primary label with spacing included:
My stacked labels. I reduced the font size for the labels displaying "min" and "max", then placed them over my primarly labels.
Hopefully this techinique or something similar will suffice until the interpreters can handle sub- and superscripts.

댓글을 달려면 로그인하십시오.

답변 (2개)

Cris LaPierre
Cris LaPierre 2018년 12월 26일
App designer does not yet support an interpreter in all text elements. This post contains details on which elements supported the 'tex' and 'latex' interpreters as of 18a.
  댓글 수: 8
Xingwang Yong
Xingwang Yong 2024년 1월 12일
편집: Xingwang Yong 2024년 1월 12일
@Cris LaPierre Using label to fake a sucscripted text is an awkward solution. For checkbox, you can click the text to make the checkbox checked, in addition to click the box itself. However, if you use label to fake the text, the only option is to click the box itself. This inconsistent user experience between different checkboxes would apparently make the user confused. Not to mention how difficult it might be to locate a small box in a large UI.
Cris LaPierre
Cris LaPierre 2024년 1월 12일
That is the nature of workarounds.

댓글을 달려면 로그인하십시오.


Allen
Allen 2024년 1월 11일
I am not sure what version it was introduced, but R2023b now includes an interpreter property for labels in App Designer.
Use the link below for information on how to use interpreters.
  댓글 수: 2
Jonas Rosengren
Jonas Rosengren 2024년 4월 10일
Thanks Allen. I discovered however does the font looks awful and can't be changed.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Develop uifigure-Based Apps에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by