comparison m-toolbox/classes/+utils/@plottools/allgrid.m @ 0:f0afece42f48

Import.
author Daniele Nicolodi <nicolodi@science.unitn.it>
date Wed, 23 Nov 2011 19:22:13 +0100
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:f0afece42f48
1 % ALLGRID Set all the grids to 'state'
2 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3 %
4 % DESCRIPTION: ALLGRID Set all the grids to 'state'
5 %
6 % CALL: allgrid('state')
7 %
8 % VERSION: $Id: allgrid.m,v 1.1 2008/08/05 17:51:32 ingo Exp $
9 %
10 % HISTORY: 17-11-2002 M Hewitson
11 % Creation.
12 %
13 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
14
15 function allgrid(state)
16
17 if (strcmp(state,'on') || strcmp(state,'off'))
18
19 c = get(gcf, 'children');
20
21 for k=1:length(c)
22
23 t = get(c(k), 'Tag');
24 if t==''
25 set(c(k), 'XGrid', state);
26 set(c(k), 'YGrid', state);
27 end
28
29 end
30 else
31 error('state must be on or off');
32 end
33
34 end
35