LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Waveform graph label positions change in an undesired manner when resizing with pane.

I have a simple test VI with 3 panes (pane 1 stretches as needed while pane 0 and pane 2 are fixed width, each pane has its origin in the top left corner):

 

3PaneFP.png

 

The block diagram just reports the position of the Time/Amplitude labels and polls for the stop button to be pushed:

 

3PanelBD.png

 

 

 

The graph has the Scale Object with Pane option set to TRUE and the center pane has the Scale Objects when Resizing property set to TRUE as well.

 

 

Anyway... when resizing the pane the axis labels march all over the place.  After about a minute of resizing the pane while the VI was running I ended up with the labels looking like this:

 

3PaneTestFail.png

 

 

Luckily the properties for axis label position are not read only, so I already have my workaround.

 

 

If there's a better way to configure resizing graphs / panes I'm all ears, or perhaps this issue is fixed in a more recent LabVIEW? (we're still using LV 2011 on this project for the time being)

 

 

Best Regards,

John Passiak
0 Kudos
Message 1 of 9
(4,672 Views)

Hi,

I downloaded the 3DPaneTest.vi and ran it in LV 2014. No problems - the axis labels stay in the center no matter how many times I resided the Front Panel.

Then I opened the same vi in LV 2011 service pack 1. Ran it. No problems here as well. The axis labels stay dead center no matter how many times I resized things.

So yeah, I didn't see the same thing that you saw in either LV 2011 SP1 or LV 2014.

-Tanim T

Tanim
National Instruments
0 Kudos
Message 2 of 9
(4,601 Views)

Thanks for looking into it.  To reproduce, try the following:

 

1.  Run the VI (3PaneTest.vi from my last post)

 

2.  Maximize the VI

 

3.  Note the positions of each label, for example:

Label Positions 1.png

 

3.  Restore the VI to its smaller size.

 

4.  Stretch the Window to a new size by dragging the corner of the window.

 

5.  Maximize the VI again

 

6.  Note that the positions of each label have changed, for example:

Label Positions 2.png

 

 

The difference might by subtle in one iteration (though in my example 13-16 pixels is definitely noticeable), but if I resize the Window enough I can get the labels to march completely off the screen.  Maximizing isn't actually necessary for me to reproduce the issue but it is useful since I can ensure the front panel is the same size when I am making comparisons.  Simply maximizing/restoring without resizing via dragging the window does not reproduce the issue.

 

Anyway, if you are following these steps and it doesn't reproduce on your end maybe there is something else going on.  I am indeed running LV 2011 SP1 (11.0.1f2), though it is the 32-bit version (on Windows 7 64-bit OS).

 

 

Best Regards,

John Passiak
0 Kudos
Message 3 of 9
(4,593 Views)

LV14:

 

3PaneTest.png

Message 4 of 9
(4,585 Views)

I saw the label wind up in different positions in the Maximized state, but the values were generally in the neighborhood of each other, up and down, within about 15-20 pixes.  I never saw the labels walking away like that.

Message 5 of 9
(4,575 Views)

I see it move up to about 100 pixels then start moving around, although I did not run it too many times after that.  LV2014, 64-bit on Mac OS X 10.9.5. 

 

The motion is only in the axis of the panel size change. When I change only the vertical size of the panel, only the Y-axis label moves.

 

It is possible to move the label completely off the visible part of the panel. After several moves, compressing the panel to ~100 pixels high leaves the label invisible off the bottom of the panel.  The bottom edge of the graph remains visible.

 

The movement occurs during editing, not at run time.

 

Lynn

 

0 Kudos
Message 6 of 9
(4,562 Views)

Thank you everybody for verifying the behavior.  For now I have put the following inside the Panel Resize event handler as a workaround:

 

GraphResize.png

 

 

Best Regards,

John Passiak
Message 7 of 9
(4,549 Views)

I am unable to find the property controls for "Plot Area Top" and "Height". Using Labview 2017. Could it be that the properties are now labelled as something else? How did you nagtivate under properties structure to get to Plot Area Top and Height? 

0 Kudos
Message 8 of 9
(3,484 Views)

I couldn't find Plot Area Top by itself, but I found Plot Bounds, which you can unbundle (by name, optionally) to get the Top.

Height can be found under Plot Area > Size > {Height, Width} (width is also there).

 

Edit: As suspected based on the brown shading of the property node (and my ability to find the other nodes) the Plot Area Top, Left nodes are "private", which is to say, you need an ini key to access them and they may not be stable. Brief testing seems to show that they're the same as the Plot Bounds values (which are public) though...


GCentral
0 Kudos
Message 9 of 9
(3,466 Views)