Global Position of Docked Figures window - MATLAB Answers - MATLAB Central
% create a dock figure
fig = figure;
set(fig,'WindowStyle','docked')
get(fig,'Position')
% get the Figure editor
desktop = com.mathworks.mde.desk.MLDesktop.getInstance;
container = desktop.getGroupContainer('Figures').getTopLevelAncestor;
% get the dimensions
width = get(container.getSize,'width');
height = get(container.getSize,'height');
% get the origin
Location = get(container.getAccessibleContext,'Location');
Xorigin = get(Location,'X');
Yorigin = get(Location,'Y');
% display
disp([Xorigin Yorigin width height])