LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Using splitters while maintaining a "developer area" on the front panel

By default, splitters make it hard to have a non-viewable are of the FP to hold controls and indicators that are not part of the user interface. While developing the BundleMagic plugin, I created a VI that utilizes a labeled rightmost splitter to divide the UI portion of hte FP from a development area. This splitter has sizingset to stick bottom-right in run mode, and stick top-left in edit mode. I also resize the FP to hide the resulting right-most pane when the VI is running, and show it when not running. This area is then available for development: always visible in edit mode and hidden in run mode.

 

Check out the Splitter DEMO.vi in the attached code sample.

 

Is there a batter way to do this? There are upsides to this approach. My "prepopulate" window setup allows for window placement and resizing and other FP setup actions to occur while the FP is hidden, then "post-populate" makes the FP visible.

 

The difficulty here is that if the VI does not stop gracefully (as is often the case during development), the development area isn't shown. I may refactor this to run as an actor, to detect when the VI is no longer running.

 

Thoughts?

_____________
Creator of the BundleMagic plugin for LabVIEW!
0 Kudos
Message 1 of 5
(567 Views)

@littlesphaeroid wrote:

By default, splitters make it hard to have a non-viewable are of the FP to hold controls and indicators that are not part of the user interface. While developing the BundleMagic plugin, I created a VI that utilizes a labeled rightmost splitter to divide the UI portion of hte FP from a development area. This splitter has sizingset to stick bottom-right in run mode, and stick top-left in edit mode. I also resize the FP to hide the resulting right-most pane when the VI is running, and show it when not running. This area is then available for development: always visible in edit mode and hidden in run mode.

 

Check out the Splitter DEMO.vi in the attached code sample.

 

Is there a batter way to do this? There are upsides to this approach. My "prepopulate" window setup allows for window placement and resizing and other FP setup actions to occur while the FP is hidden, then "post-populate" makes the FP visible.

 

The difficulty here is that if the VI does not stop gracefully (as is often the case during development), the development area isn't shown. I may refactor this to run as an actor, to detect when the VI is no longer running.

 

Thoughts?


I have made a wrapper case in the main UI VI that is "reset UI" that can be toggled by a bool for dev and debug work. As a dev you can run the 'reset UI" case to put everything back as it should be for debugging. 

snip.png

 

 

______________________________________________________________
Have a pleasant day and be sure to learn Python for success and prosperity.
0 Kudos
Message 2 of 5
(485 Views)

Thanks for the response Jay.  I'm not clear on how your solution fixes the splitter issue that mine works with.

_____________
Creator of the BundleMagic plugin for LabVIEW!
0 Kudos
Message 3 of 5
(232 Views)

@littlesphaeroid wrote:

Thanks for the response Jay.  I'm not clear on how your solution fixes the splitter issue that mine works with.


I was thinking you can make a case and reset where the splitter is so you can see the debug screen. It would be like running "pre-populate" but for dev mode. 

______________________________________________________________
Have a pleasant day and be sure to learn Python for success and prosperity.
0 Kudos
Message 4 of 5
(226 Views)

Ah, I see. Well, I leave the splitter alone, as it defines the viewing area of the GUI, and change its behavior, allowing for resizing the FP to work as expected in dev mode. I'm not clear if you're suggesting an improvement, but ultimately what I am hoping to learn is if this is a "good way" to do things. Without a solution like your or mine, splitters can be frustrating for development, so I thought maybe NI thought about and provided a solution that I've overlooked. 

_____________
Creator of the BundleMagic plugin for LabVIEW!
Message 5 of 5
(211 Views)