GUI uitable header text rotation

8 Ansichten (letzte 30 Tage)
RomanB
RomanB am 1 Feb. 2018
Kommentiert: RomanB am 2 Feb. 2018
Hello everybody,
I have created a uitable and would like to rotate the text of my header in order to reduce the width of the header column.
I am using for general formatting within the table html code as I find it very handy:
'<html><tr align=center><td width=%d><font color=black><b> Hi all!'
However, when I try to apply html rotation code I am rather unsuccessful and it seems to me that text rotation within the header is quite difficult.
Ideally the header of my table should be rotated by 45 deg as following example:
Has anybody of you dealt with such an issue and have you been able to find a solution?
Thanks a lot in advance,
Roman

Akzeptierte Antwort

Walter Roberson
Walter Roberson am 1 Feb. 2018
You will not be able to do this at the HTML level.
You might be able to do it at the Java level; I am not at all sure of that. uipanel() is based upon java objects.
Otherwise you would have to resort to
h = annotation('textbox', ...)
h.NodeChildren(10).Rotation = 45
  1 Kommentar
RomanB
RomanB am 2 Feb. 2018
Yeah that's probably a good idea. I'll try to create a jTable into an existing GUI and hope I will have more luck.
Thanks for the idea with the text box, the problem I see there is that it won't resize when changing window size.

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu App Building finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by