如何让对datacursormode不可见的行(How to make line invisible to datacursormode)
我有一个应用程序,在光标位置创建行。 当我输入datacursormode来创建数据datatips ,它会在光标位置datatips的行上创建。
我想知道如何将它们从datacursormode ,但不要让它们不可见。
I have an application that create lines on the cursor position. When I enter the datacursormode to create datatips, it create on the lines that follow the cursor position.
I was wondering how to remove them from being visible to the datacursormode, but don't making them invisible.
最满意答案
要解决它,请关闭HitTest句柄。
即,该行由plot或line命令创建,然后在其末尾添加以下对值:
plot(…,'HitTest','off'); line(…,'HitTest','off');这将使该行对datacursormode不可见。
To solve it, make its handle HitTest off.
I.e, the line is created by a plot or line command, then add the following pair value at its end:
plot(…,'HitTest','off'); line(…,'HitTest','off');This will make the line invisible for the datacursormode.
更多推荐
发布评论