Actions passing mouse over objects...

조회 수: 11 (최근 30일)
Jethro
Jethro 2011년 12월 11일
Hi everybody!
I'm looking for, if it's possible in Matlab gui, a code or a method to bring up something when mouse passes over an object...
It's possible to set it???
Thanks a lot!
=====
EDIT 11/12/2011 13.04 (European Time)
I explain in details what I want. I'd like to have a "popup window", if I can define it in this way. This window is defined as "text", and it has to appear when I pass with the mouse over a specific location in my interface: this "location" is a text too... Functions that Jan Simon proposed to me almost what I want, but I can not change them the way I need...
There are other ideas about that?

답변 (2개)

Walter Roberson
Walter Roberson 2011년 12월 11일
Items of type text do not have built in tooltip strings, and there is no mouse-over callback defined for items of type text.
If datacursormode is not able to do what you want, then you will have to go all the way up to the figure WindowButtonMotionFcn callback, have it decide whether you are over the target or not and display or hide your tooltips.
If you could switch your target objects from being of type text to being uicontrol('style','text') then this all would be easier, and you could use the helper user contribution http://www.mathworks.com/matlabcentral/fileexchange/26283-tooltip-gui-modeless-feedback

Jan
Jan 2011년 12월 11일

카테고리

Help CenterFile Exchange에서 Migrate GUIDE Apps에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by