Functions | |
if (ischar(type)) type | |
endif | if (iscellstr(type)) look_first |
if (nargin==3) if(ischar(toplevel)&&strcmpi(toplevel | |
else | error ("ancestor: third argument must be \"toplevel\"") |
endif endif | while (true) if(isempty(h)||!ishandle(h)) break |
endif | if (any(strcmpi(get(h,"type"), type))) p |
if (look_first) break | |
endwhile else | error ("ancestor: second argument must be a string or cell array of strings") |
endif else | print_usage () |
Variables | |
function | p |
toplevel | look_first = false |
endif endif | h = get (h, "Parent") |
else error | ( | "ancestor: third argument must be \"toplevel\"" | ) |
if | ( | look_first | ) |
endif if | ( | any(strcmpi(get(h,"type"), type)) | ) |
if | ( | nargin | = = 3 |
) |
if | ( | ischar(type) | ) |
toplevel look_first = false |