function print_compare_tsplot(cruiseid,fh)
% PRINT_COMPARE_TSPLOT - print output figures from compare_tsplot.m
% 
% fh - figure handles (default=gcf)
%

% 
% VERSION: 
%	$Revision: 1.4 $
%	$Date: 2008/02/18 19:42:31 $
%	$Id: print_compare_tsplot.m,v 1.4 2008/02/18 19:42:31 duncombe Exp duncombe $
%
% CREATED BY: CMDR  2008/01/27
%	from print_compare_ctd_sensors.m
% 
% CHANGELOG: 
%  2008/02/04 CMDR
%	* be sure to print the correct figure
%

if nargin==0, cruiseid=getcruiseid; end;
if isempty(cruiseid), cruiseid=getcruiseid; end;

%% default - print the current figure
if ~exist('fh'), fh=[]; end;
if isempty(fh), fh=gcf; end;

p=pwd; dir_del=p(1);
c_path=['figures' dir_del ];

for i=1:length(fh), 
	figure(fh(i));
	disp(['Paused to edit figure(' num2str(fh(i)) ')']);
	disp('Press any key to continue');
	pause; % to edit the figure
%% CMDR sometimes the figure with focus gets changed by the windowing 
%% application! So after we come back from editing the figure, be sure
%% we have the focus on the correct figure...
	figure(fh(i));
	eval(['print -depsc ',c_path,'tsplot_',num2str(i) ' ;']);
end;

return;

