Can I have multi-line column headings for uitables?
-
16-04-2021 - |
Domanda
I am using MATLAB Student Version R2011a. I am creating a GUI-table to compare data easier, but I end up in complicated abbreviations, because I don't know how to make multi-line column headings.
I create the table like this (minimal example):
myFigure = figure('Position', [100, 200, 400, 100]);
tableData = magic(3);
cnames = {'convPrice/y', 'rechEn', 'priceRechEn'};
myTable = uitable('Parent', myFigure, ...
'Data', tableData, ...
'ColumnName', cnames, ...
'Position',[10 10 380 80]);
I took a screenshot and I will upload it, when I reach reputation 10. Thank you for your answers.
Soluzione
You can create multiline column headings using a vertical slash (|) to separate lines. For example:
cnames = {'conv|price', 'rech|en', 'price|rechEn'};
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow