Check out our User Interface Code Repository Files or visit the LabVIEW Wiki User Interface Portal
Tags |
(This content has not been tagged yet)
|
![]() |
May 22 2007, 02:12 AM
Post
#1
|
||||
![]() Very Active Member Posts: 58 Joined: 26-April 06 From: Adelaide Member No.: 4848 Using LabVIEW Since:2002 LV:8.5 ,8.2.1 ,7.1.1
|
Hi all,
I am trying to allow a user to interact with a special XY plot. The goal is to have them click on the XY-plot and draw (plot) a point where the user clicks and maintain the position of the point on the XY plot under the mouse until they click again. The problem is that this XY-plot has labels on it that interfere with the mouse. A cursor appears in the plot area but the "operate" cursor appears when the mouse is over the labels and I can't trap a mouse event. I can turn off/on the labels with a mouse enter/leave event but that makes the labels invisible while the mouse is in the plot area which it will be for most of the time. The labels must be in front of the plot area to be visible. I am looking for some fresh ideas to help circumvent this problem. Here is a pic of the plot for assistance.
|
|||
|
|
||||
| Ad |
May 22 2007, 02:12 AM
Post
#
|
||
|
|
|
||
|
|
|||
May 22 2007, 04:23 AM
Post
#2
|
|||
![]() CCT It Premium Member ![]() Posts: 1331 Joined: 13-June 05 From: Woerden, Netherlands Member No.: 2399 Using LabVIEW Since:2001 LV:8.5.1 ,6.1 ,8.2.1
My Blog
My Gallery
|
Hi Phil,
In LabVIEW 8 you can add an image in front of the plotted data in graphs, I don't know if this goes for XY as well, but I think so. Maybe that is your way to got (and I think it can reduce your code as well). Ton --------------------
|
||
|
|
|||
May 22 2007, 04:39 AM
Post
#3
|
|||
![]() Confucius say: Crowded elevator always smell different to midget Admin ![]() Posts: 2363 Joined: 13-October 02 From: Planet Earth Member No.: 2 Using LabVIEW Since:1994 LV:8.5 ,8.2.1 ,7.1.1
My Blog
My Gallery
|
Can you attach a new VI with your graph on the panel and a constant with data fed to it? I want to try a few things.
--------------------
|
||
|
|
|||
May 22 2007, 05:20 AM
Post
#4
|
|||
![]() Very Active Member Posts: 58 Joined: 26-April 06 From: Adelaide Member No.: 4848 Using LabVIEW Since:2002 LV:8.5 ,8.2.1 ,7.1.1
|
Can you attach a new VI with your graph on the panel and a constant with data fed to it? I want to try a few things. Sure, here is a stripped down version that should help. Cheers & Beers
Course_display_demo.vi ( 93.32K )
Number of downloads: 105
|
||
|
|
|||
May 22 2007, 12:51 PM
Post
#5
|
|||
|
More Active Member Posts: 30 Joined: 3-July 03 From: Long Island, NY Member No.: 133 Using LabVIEW Since:1993 LV:8.20 ,. ,.
|
Phil,
Nice looking plot. See if this works for you: 1) move your labels to the back 2) color the black part and the silver frame of your plot transparent 3) color the background of the front panel black The plot labels now show and don't interfere. This now looks almost like your original except the other controls are surrounded by black. You could put the other controls on a decoration or a cluster as a background.
Course_display_demo_JBS.vi ( 78.26K )
Number of downloads: 100Or, as an alternative to coloring the front panel black, put the plot on a black decoration and move the labels forward so they are between the decoration and the plot. Jon This post has been edited by Jon Sweeney: May 22 2007, 01:00 PM -------------------- Jon Sweeney
|
||
|
|
|||
May 23 2007, 12:39 AM
Post
#6
|
|||
![]() Very Active Member Posts: 58 Joined: 26-April 06 From: Adelaide Member No.: 4848 Using LabVIEW Since:2002 LV:8.5 ,8.2.1 ,7.1.1
|
Or, as an alternative to coloring the front panel black, put the plot on a black decoration and move the labels forward so they are between the decoration and the plot. Jon Thanks for your suggestions Jon, I like the second option with a black decoration under the XY plot. Unfortunately, plotted data covers up the labels because they are behind the data. The first picture in this thread represents a typical data set to be plotted and as you can imagine, with the labels sitting behind the data I can't see some of them. I guess I need a way of having the labels in front of the data but tell LabVIEW to ignore them as an interactive item. So we are back where we started. Cheers & Beers
|
||
|
|
|||
May 23 2007, 06:39 AM
Post
#7
|
|||
|
Extremely Active Member Posts: 369 Joined: 24-August 06 Member No.: 5958 Using LabVIEW Since:1995 LV:8.5 ,8.2.1 ,7.1.1
|
Thanks for your suggestions Jon, I like the second option with a black decoration under the XY plot. Unfortunately, plotted data covers up the labels because they are behind the data. The first picture in this thread represents a typical data set to be plotted and as you can imagine, with the labels sitting behind the data I can't see some of them. I guess I need a way of having the labels in front of the data but tell LabVIEW to ignore them as an interactive item. So we are back where we started. Cheers & Beers Phil, maybe this is a long shot, but have you tried using annotations to programmatically set the labels? This way the "labels" would be part of the plot itself. /J -------------------- Wired but not weird...
|
||
|
|
|||
May 23 2007, 11:48 AM
Post
#8
|
|||
|
More Active Member Posts: 30 Joined: 3-July 03 From: Long Island, NY Member No.: 133 Using LabVIEW Since:1993 LV:8.20 ,. ,.
|
The labels must be in front of the plot area to be visible. oops, sorry, I missed that part. Jon -------------------- Jon Sweeney
|
||
|
|
|||
May 24 2007, 08:35 AM
Post
#9
|
|||
![]() Very Active Member Posts: 58 Joined: 26-April 06 From: Adelaide Member No.: 4848 Using LabVIEW Since:2002 LV:8.5 ,8.2.1 ,7.1.1
|
Phil, maybe this is a long shot, but have you tried using annotations to programmatically set the labels? This way the "labels" would be part of the plot itself. /J Fantastic! That did the trick. I had to disable "Allow dragging" but now the annotations sit over the data and don't interfere with the user clicking on the XY-plot. Thank you very much Cheers & Beers
|
||
|
|
|||
May 24 2007, 09:32 AM
Post
#10
|
|||
|
Extremely Active Member Posts: 369 Joined: 24-August 06 Member No.: 5958 Using LabVIEW Since:1995 LV:8.5 ,8.2.1 ,7.1.1
|
Fantastic! That did the trick. I had to disable "Allow dragging" but now the annotations sit over the data and don't interfere with the user clicking on the XY-plot. Thank you very much Cheers & Beers You're welcome. Would you mind uploading the version using the annotations, to help others facing the same problem? /J -------------------- Wired but not weird...
|
||
|
|
|||
![]() ![]() |
| Time is now: 22nd November 2008 - 02:11 AM |