%   This odd "function" is to be left lying around as it is nominated by GnashPlot.m
%to be invoked when the plot's window is being resized. Its purpose is to specify
%smaller borders on plots, because matlab's default arrangements are profligate.
%The fiddles are odd and the context unclear, but it is better than nothing.
%   The "global" statement seems to work, even though its named variable is not visible
%from the command prompt. Perhaps because the declaration was made withn a "function",
%and outside the function (at the command prompt) it becomes a ghost...  The available
%documentation is hopelessly vague on this, as on so much else.
%   Concocted by R.N.McLean (whom God preserve), April MMX.

function GnashPlotResqueeze	%No parameters, damnit.
 global GnashPlotXlabelXbase;			%But I need this value!
 evalin('base','global GnashPlotXlabelXbase;');	%And this incantation makes the variable not a ghost, it seems.
 %disp(GnashPlotXlabelXbase); disp('G~P~R');
 set(gcf,'Units','points'); hf = get(gcf,'Position');
 set(gca,'Units','points'); %ha = get(gca,'Position');
 xtop = hf(4) - GnashPlotXlabelXbase - 17;	%The x-axis top, up from the x-axis base level.
 set(gca,'Position',[38 GnashPlotXlabelXbase (hf(3) - 56) xtop]);	%[lmargin ybase rmargin +ytop].
endfunction;  %Damnit, no name can be specified!
