Underline Text in Gui

13 visualizaciones (últimos 30 días)
nsbd
nsbd el 6 de Feb. de 2012
Comentada: Ralph el 28 de Oct. de 2020
Hi All
N.Class = uicontrol('unit','pix',...
'style','text',...
'position',[0 405 340 30],...
'string','Hello',...
'horizon','center',...
'fontwei','normal',... ****underline ???
'FontName','Verdana',...
'backg',[0 0 0],...
'fontsize',8);
How do I ?
Thnks.

Respuestas (2)

Jan
Jan el 6 de Feb. de 2012
See Yair's suggestion about customizing buttons.
H = uicontrol('Style', 'PushButton', ...
'String', '<u>Underline</u>');
  1 comentario
Ralph
Ralph el 28 de Oct. de 2020
For anyone reading this in 2020 (or perhaps other versions):
You need to include the <html> tags in the string for this mechanism to work. So its:
H.String = '<html><u>control label</u></html>';

Iniciar sesión para comentar.


Sean de Wolski
Sean de Wolski el 6 de Feb. de 2012
text(3,10,'\underline{Hello World}','interp','latex')
axis([0 20 0 20])
I can't seem to find a way to to this for a uicontrol string, though I'm sure there is a way.

Categorías

Más información sobre Environment and Settings en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by