LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How can I use text as a button?

I am looking to use text as a button or event trigger.  I want to place the text over a picture and trigger an event if the user clicks the text, but I do not want to obstruct the picture with a button.  I'd also like to be able to modify the text color depending on whether it has been selected by the use.  Does anybosy know an easy way to do this?
0 Kudos
Message 1 of 14
(4,090 Views)
You can use a flat button from the classic palette and make it transpared so only the text shows.
 
You can modify the text colors with property nodes.
 
You can also use a picture indocator for the image and draw appropriate text according to mouse events, etc..
0 Kudos
Message 2 of 14
(4,087 Views)
Thanks for the input ..one question though.  How do you make the button transparent?  I don't see that as an option on the colors palette or in the properties node.
0 Kudos
Message 3 of 14
(4,081 Views)
The transparent color is the little [T] in the upper right corner of the color palette (see image).
 

Message Edited by altenbach on 03-26-200610:44 PM

0 Kudos
Message 4 of 14
(4,080 Views)
Thanks, that is helpful
0 Kudos
Message 5 of 14
(4,059 Views)
I just want to add that the boolean text of control is clickable and can be detached from the graphic elements. It is an alternative to make the button transparent.


Message Edité par JeanPierre le 03-27-2006 10:30 AM



LabVIEW, C'est LabVIEW

Message 6 of 14
(4,055 Views)


@JeanPierre wrote:
I just want to add that the boolean text of control is clickable and can be detached from the graphic elements. It is an alternative to make the button transparent.


Hey, that's pretty cool! 🙂

(Just to clarify, "clickable" above means that the boolean control can be operated by clicking on the boolean text, even if the boolean text is located outside the button area).

0 Kudos
Message 7 of 14
(4,033 Views)

Yup, this feature is most commonly used in our LabVIEW-based GUIs with Radio Button controls, since, if you look at any native Windows dialog (IE options, Control Panel, etc.) with radio buttons, you can click their text to activate that option.  We use the clickable boolean text on radio buttons in LabVIEW UIs to accomplish the same behavior.

-D

0 Kudos
Message 8 of 14
(4,022 Views)
If I don't have the "T" in the upper right-hand corner and have an "X" instead, what do I have configured wrong?
0 Kudos
Message 9 of 14
(3,997 Views)
You only get the [T] if the control actually supports transparent color. Could it be you are trying to color the VI background transparent??
 
Make sure you right-click on the desired control when popping up the color palette.
0 Kudos
Message 10 of 14
(3,987 Views)