File Exchange

image thumbnail

undecorateFig - remove/restore figure border and title bar

version 1.1.0.0 (31.8 KB) by Yair Altman
Removes/restores the border and title bar of Matlab figures

16 Downloads

Updated 20 Mar 2015

View License

Description:
undecorateFig removes the border, title bar, menu bar and toolbar of a Matlab figure.
redecorateFig restores the figure to its previous (decorated) state.

Syntax:
undecorateFig(hFig) % hFig is a figure handle or any other GUI handle (default: current figure)
redecorateFig(hFig)

Technical details:
http://undocumentedmatlab.com/blog/frameless-undecorated-figure-windows

Warning:
This code heavily relies on undocumented and unsupported Matlab functionality. It is expected to work on Matlab 7 and higher, but use at your own risk!

Cite As

Yair Altman (2019). undecorateFig - remove/restore figure border and title bar (https://www.mathworks.com/matlabcentral/fileexchange/50111-undecoratefig-remove-restore-figure-border-and-title-bar), MATLAB Central File Exchange. Retrieved .

Comments and Ratings (6)

Mingfeng Li

Yair, Great work. However, if I create an edit box, edit box won't work anymore after I used undecorateFig function to the GUI.

KAE

Note this is reversible: You can also *add* the bar to the top after you remove it, which is necessary if you need to drag or resize the figure window. It works great on R2018a.

KAE

So simple to use. So useful.

Mathieu

Excellent function ! The good thing for my launcher too ! (Matlab R2015b => the tag of the axes of the figure disappear after the opening of the GUI but not a problem)

I have wondered so many times how to create an undecorated figure (for a launcher figure for example), so thanks for this code !!

Very nice piece of code!!! I've been looking at this for a long time for my splash screens.
Thanks!

Updates

1.1.0.0

Removed annoying Matlab warning that "figure JavaFrame property will be obsoleted in a future release"

MATLAB Release Compatibility
Created with R2014b
Compatible with any release
Platform Compatibility
Windows macOS Linux