MATLAB: How to remove buttons on the figure toolbar within MATLAB

addbarbuttonschangecustomizeguiguideiconsMATLABremovetoolundocumented

I would like to be able to remove buttons such as the "new file" or "new figure" button from the toolbar.

Best Answer

For MATLAB 7.0 (R14) and all subsequent releases, refer to the Related Solution linked at the bottom of the page.
For product releases prior to MATLAB 7.0 (R14):
If you would like to remove the entire figure toolbar (all buttons), execute the following commands to open a new figure window and remove the toolbar:
fig = figure
set(fig,'Toolbar','none')
This removes the entire toolbar and not specific buttons.