From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to set frame colors of an object?

LV2013, Win7

 

I'm looking for a way to (programmatically) set the frame color of an ENUM (or any object in general).

 

What I want is for everything to be transparent except the text itself.

 

The frame color seems to be a weird property - if you pop up on the frame with the PAINTBRUSH tool, you get a F | B color selection box.

 

Setting the background color has no effect on anything.

 

Setting the foreground color does nothing UNLESS you choose TRANSPARENT, in which case the frame becomes transparent.  Any other color has no effect.

 

So, how do I do that from a property node?  I have hundreds to do, and I already have references to them, but I can't figure out what properties to use.

 

 

Colors.PNG

 

Notice that the green color has no effect on anything.  The red is the inner text box BG, the blue is the control's BG outside of the text box, and the yellow sets the color of the text itself..  The green is ignored.

 

I can set all four of those to TRANSPARENT, but what I get is the box with a shadow frame around it.

 

I only see four properties related to color, as listed above.  So how do I make the frame transparent?

Steve Bird
Culverson Software - Elegant software that is a pleasure to use.
Culverson.com


Blog for (mostly LabVIEW) programmers: Tips And Tricks

0 Kudos
Message 1 of 7
(4,391 Views)

It looks like you are using an Enum from the Modern palette.  I dont' think you can change the colors of those frames.

 

Try picking in an enum from the classic palette.  There you can fully color the frame as transparent.

0 Kudos
Message 2 of 7
(4,379 Views)

I dont' think you can change the colors of those frames.

 

If I can do it with the toolbox, I OUGHT to be able to do it with properties...

 

 

 

Try picking in an enum from the classic palette. 

 

I did.  It's even worse:

 

Colors 2.PNG

Steve Bird
Culverson Software - Elegant software that is a pleasure to use.
Culverson.com


Blog for (mostly LabVIEW) programmers: Tips And Tricks

0 Kudos
Message 3 of 7
(4,367 Views)

It's better because with the classic style, you can now change the frame manually to another color or transparent that you can't do with the modern style.

 

But so far, I don't see where those properties have been exposed so that you can change them with a property node.

0 Kudos
Message 4 of 7
(4,358 Views)

The "Frame" as a control part, resides behind the "Ring Text" Control Part.  There is no way to programatically set unless you edit the control, that I know of.  In Theory, you could use scripting to edit the Control type def to replace the frame's image


"Should be" isn't "Is" -Jay
0 Kudos
Message 5 of 7
(4,346 Views)

From a VI server view.....

 

The Text object (when you retrieve a reference) has two different colour properties, one on the decoration level and one on the decoration.text level.

 

I dont have a LabVIEW here but I think on the control abject level for the control itself there is also a colour property.  That makes three pairs of fg and bg colours.

0 Kudos
Message 6 of 7
(4,344 Views)

I think on the control abject level for the control itself there is also a colour property.  That makes three pairs of fg and bg colours.

 

I think I know what you mean, but it just isn't so.

 

For an enum, I see nothing in the top-level properties dealing with color.

One of the top-level properties is the RING TEXT, which has the two sets of properties I mentioned above.

 

 

Steve Bird
Culverson Software - Elegant software that is a pleasure to use.
Culverson.com


Blog for (mostly LabVIEW) programmers: Tips And Tricks

0 Kudos
Message 7 of 7
(4,320 Views)