Add Components to a Programmatic UI
uisetfont returns the selections as a structure array:
myfont =
FontName: 'Century Schoolbook'
FontWeight: 'normal'
FontAngle: 'normal'
FontSize: 9
FontUnits: 'points'
You can use this information to set font characteristics of a component in the UI:
btn = uicontrol;
btn.FontName = myfont.FontName;
btn.FontSize = myfont.FontSize;
Alternatively, you can set all the font characteristics at once:
set(btn,myfont);