VeriStand

cancel
Showing results for 
Search instead for 
Did you mean: 

How to change default color of a VeriStand control?

I would like to modify some VeriStand indicators and controls. After doing some changes in LabVIEW and using the new display templates in VeriStand the default text color for numeric input is still yellow. It is hard to read on a white background.

Where is the correct location to change that?

It would be nice if the user could still change the color with the right click menu.

 

Thanks in advance

0 Kudos
Message 1 of 11
(8,445 Views)

Hi Tobias,

 

I tried to edit some indicators and had the same problem. We found a Workaround here though:

 

1. Create a copy of the control/indicator

2. When you open the VI don't just edit the colour of the Indicator. Instead delete the indicator and create a new one of the same type and place it.

3. Save it and open it in Verystand, your changes should appear now.

 

Best Regards,

 

Lam

Message 2 of 11
(8,432 Views)

Hi Lam,

 

Thank you very much for your reply.

My objective is to save some space on the screen so i would like to use not the control in modern style, but the system style. At the picture attached you will see the differences. I followed your steps and first removed the original control input. Then I inserted a new control and saved it. When using the new control with VeriStand the new text color is yellow again yet the original color with LabVIEW was black when I saved the new control before.

 

I guess all changes you make by right-clicking on the control at VeriStand (unit, scaling, offset, format, pecision, ...) are made via the Item.Data cluster internally. Somewhere in the background there might be a default value set for this cluster. Unfortunately I cannot find it.

 

I have a workaround (placing a reference node that sets the color) but then I am not able to change it in VeriStand.

 

Do you have any ideas?

 

Thanks a lot,

 

Tobias

0 Kudos
Message 3 of 11
(8,424 Views)

Hi Tobias,

 

The built-in VeriStand controls (numerics, Graphs, etc...) can be modified to a certain extent, but will always have some things which you cannot change, such as the dialog that displays when you first drop it or right-click on it.  I haven't looked into it at all, but I guess the colour of the text in the controls is another thing that you can't change.

 

The workaround you mentioned sounds like it should work, but another option is to create a fully custom workspace object.  This allows you full control of the behavior of the object, and it won't have any default behavior set by VeriStand.  The down-side is that you need to implement all the logic for channel mappings and getting/setting data yourself using the NIVS Execution API.  However, there are some examples you can look at to help get you started, so it shouldn't be too bad.  Also, check out the "Free Label Template" section of this article: Creating Custom Workspace Objects for NI VeriStand.

0 Kudos
Message 4 of 11
(8,411 Views)

Hi Tobias,

To change the background color, I right click from the workspace and under the Format & Precision tab, I change the background color and the foreground color (which is the text). This is in VeriStand 2009 so I am not sure if it has changed for 2010.

0 Kudos
Message 5 of 11
(8,387 Views)

Hi hyog,

 

correct, that is the usual way to change the colors after placing it at the workspace. What I ment is to change the DEFAULT color.

If you drag and drop a numeric control on the workspace the text color is yellow and the background is black. I would like to modify the behavior that the the text color is black and the background is white by default. I do not want to change it at all controls and indicators (20 and more per screen) by hand.

 

Thanks for replying,

Best regards,

 

Tobias Gilbert

0 Kudos
Message 6 of 11
(8,381 Views)

Sorry, I missed the "default." Yes, I've noticed the same thing after changing it in LabVIEW. I've been trying to use the custom control framework more.

0 Kudos
Message 7 of 11
(8,374 Views)

I had a support ticket to ask about colors of the boolean control not changing and got a response that I'm told would also work for changing the default colors of the numeric control/indicator. I have not tried it yet on that, but changing the Item Data cluster is what is supposed to work.modified veristand control.png

0 Kudos
Message 8 of 11
(8,359 Views)

Thank you very much for your suggestion. I appreciate that. Unfortunately this way it does not work. The control seems not to care about what data is inlculded in "Item.Data".

I assume the color information (and any other information) must be placed in the queue that goes into the while loop but my experiences with with queue variables is very low.

 

I keep trying...

0 Kudos
Message 9 of 11
(8,349 Views)

Hi,

Yes, I tried this after I posted too and noticed that the default colors still did not change, even after restarting the workspace and the application too.

0 Kudos
Message 10 of 11
(8,341 Views)