Simulink: How to display small/large text in mask using disp() (change font size)
When editing the Matlab/Simulink mask code, you can display larger or smaller text text by using disp()
with LaTeX commands and texmode
= on
.
Displaying just small text
When using texmode
, you can use {\fontsize{5} ...}
to format text as small. Modify 5
to whatever size you prefer.
disp("{\fontsize{5} text}", 'texmode', 'on')
Displaying just large text
When using texmode
, you can use {\fontsize{15} ...}
to format text as large. Modify 15
to whatever text you prefer.
disp("{\fontsize{15} text}", 'texmode', 'on')
Mixing small and large text with normal text
disp("{\fontsize{5} Small} and{\fontsize{15} Large} text", 'texmode', 'on')
Also see:
- Simulink: How to display bold text in mask using disp()
- Simulink: How to display italic text in mask using disp()
If this post helped you, please consider buying me a coffee or donating via PayPal to support research & publishing of new posts on TechOverflow