How to get the width and height of the drawable area of a window in pixels?

4 vues (au cours des 30 derniers jours)
Mr M.
Mr M. le 2 Juil 2018
I can get the figure size in pixels like this:
set(gcf,'units','normalized','position',[0 0 1 1])
set(gcf,'units','pixels')
gcf_position = get(gcf,'position');
figure_width = gcf_position(3);
figure_height = gcf_position(4);
But there is a title bar and buttons area at the top of the window, and I want to get its heigh to get the usable maximal axis height. How to do this?

Réponses (0)

Community Treasure Hunt

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

Start Hunting!

Translated by