LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Aligning Boolean Control to Plot Legend

Any ideas on how best to align an array of tick boxes against a plot legend?

I have a 1D array of Boolean controls and I want to use them to enable/disable the plots on a XY graph but I'm having problems getting the controls to line up with the legend text.

I've tried using element gaps in the array but there seems to be little control of the gap that is used. I've also tried creating a custom control and modifying the control height but I still can't get an exact alignment of the control to the legend text. I've also tried using different fonts for the legend text but it doesn't help.

I don't really want to use individual controls and would prefer to continue using an array if possible but I can't help thinking I'm missing something obvious!?

I've attached and example of the problem and would welcome any suggestions....
0 Kudos
Message 1 of 10
(5,211 Views)
Sorry the attachment seemed not to be on my first posting
0 Kudos
Message 2 of 10
(5,199 Views)
You can customize the control to a larger size. (See attached modification).

Basically: (1) Right-click the control, select "customize...". (2) In the control editor switch from edit mode to customize mode. Select the sqaure and use the sizing tool.
0 Kudos
Message 3 of 10
(5,187 Views)
Sorry, apparently the resize operation does not survive a save operation. 😞 Weird! It looks just fine until closed and reopened.

Here's an approach that actually works: Just use a plain boolean button and import the appropriate checkbox graphics into the true and false cases, again using the control editor.

See if this suits your needs!
Message 4 of 10
(5,182 Views)
Well, I did not really like these huge checkboxes, they look too dominant.

A slightly more appealing approach would be to import "regulation size" checkboxes padded a bit on top and bottom to give them the correct height. In the attached example, I placed them in a transparent array container. See for yourself. 🙂
Message 5 of 10
(5,172 Views)
Great solution and thanks for your help. Like you I prefer the regular checkbox size with the spacing.

So I was on the right track with using a custom control after all which makes me feel a little better.

Thanks again

Tony
0 Kudos
Message 6 of 10
(5,165 Views)
HI there, can you please post a copy of the vi in labview 7.0. thanks.
0 Kudos
Message 7 of 10
(5,135 Views)
Here is a copy of the last program in version 7.0
0 Kudos
Message 8 of 10
(5,128 Views)
Hi,

I had the same problem. I wanted to do as you enabling/disabling a plot and placing the switch next to the legend. I checked the proposed solution using pictures on the controls but in this case the color of array element do not changeable programmatically or by the op. system. (General I prefer using colors from the op.system, supposed all the user sets the windows appearance to their "spirit")

I found an other work-around to position an element in a cell of array. Enabling the label and caption (or boolean text) of the element and position them to reach the desired position of control. Feed them by empty string or space. Then send them behind the control.


Tomi
0 Kudos
Message 9 of 10
(5,103 Views)

My workaround was an array of cluster, where I size the cluster. Involve two extra subvis for the UI, but is quite flexible.

Greetings from Germany
Henrik

LV since v3.1

“ground” is a convenient fantasy

'˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'


0 Kudos
Message 10 of 10
(4,450 Views)