Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F102269207
isTargetChart.m
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Tue, Feb 18, 23:03
Size
870 B
Mime Type
text/html
Expires
Thu, Feb 20, 23:03 (2 d)
Engine
blob
Format
Raw Data
Handle
24320488
Attached To
rINSTCONTROL Instrument Control
isTargetChart.m
View Options
function
tf
=
isTargetChart
(
hThis
,
hTarget
)
%
ISTARGETCHART
Is
the
Target
a
permitted
chart
object
%
%
See
also:
graphics
.
Cursorbar
.
isTargetAxes
,
graphics
.
Cursorbar
.
%
%
Thanks
to
<
a
href
=
"http://www.mathworks.com/matlabcentral/profile/authors/3354683-yaroslav"
>
Yaroslav
Don
</
a
>
for
his
assistance
in
updating
cursorbar
for
%
MATLAB
Graphics
and
for
his
contribution
of
new
functionality
.
%
Copyright
2015
-
2016
The
MathWorks
,
Inc
.
%
set
the
target
if
nargin
<
2
hTarget
=
hThis
.
Target
;
end
%
return
empty
if
there
is
no
Target
if
isempty
(
hTarget
)
tf
=
[];
return
end
%
if
~
all
(
ishandle
(
hTarget
))
tf
=
false
(
size
(
hTarget
));
return
end
%
check
tf
=
arrayfun
(
@
isChart
,
hTarget
);
function
tf
=
isChart
(
hTarget
)
switch
class
(
hTarget
)
%
fastest
comparison
with
switch
case
graphics
.
Cursorbar
.
PermittedChartTargets
tf
=
true
;
otherwise
tf
=
false
;
end
Event Timeline
Log In to Comment