DQMH Consortium Toolkits Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

DQMH Front Panel Pane Origin in Panel Coords

Hoping that someone can tell me why the Pane Origin when converted to Panel Coords shows a negative vertical component for my DQMH front panels? I've been trying to create a UI with multiple splitters and all of my panes are giving me negative vertical components when I use the CvtPaneToPanelCoords invoke method.  I've attact a .zip file of a Pane Origin/Coord test DQMH module (in LV 2019 and DQMH 5.0).  I also created a simply VI called Non DQMH VI Panel Coord Test...this VI gives me the expected results.  

 

I must be missing something trivial.

Best regards,
Brown

The more I know...the more I don't know
0 Kudos
Message 1 of 6
(2,004 Views)

Too add to my post from yesterday...I've looked into this some more and I'm still stumped.  

 

I found this post last night -> Christina_R post about Screen Position from 2012 which provided some clarity on the Pane vs. Panel vs. Screen coords and how they relate but I'm still seeing a discrepancy in the DQMH front panel.  I modified the BD slightly so that the Pane isn't set to 0,0 (top left corner of the panel) so that I can scroll it on purpose to see the values, and I also added an indicator for the Screen Coords (not going to re-post the VI).

 

DQMH BD w Screen Coords.PNG

 

I've tried running it with and without the Menus and Toolbars options (in VI Properties) and both show a negative value for the Panel Vertical component, however, the Menu and Toolbar heights are included in the Vertical value when they're included (but they're still negative).  It's almost like there is a fixed offset in the Vertical component.  I do not experience this issue on a Non DQMH front panel VI.  Is there a setting that I'm not aware of that's built into the module? Or is there a scripting function that's playing with the Panel coords?  The weird thing is that the Screen Coords seem to be correct or aren't out to lunch at least. 

 

Edit Time - No Menu or Toolbar in VI PropertiesEdit Time - No Menu or Toolbar in VI Properties

 

Run-Time - No Menu or Toolbar in VI PropertiesRun-Time - No Menu or Toolbar in VI Properties

 

Run-Time - with Menu and Toolbar in VI PropertiesRun-Time - with Menu and Toolbar in VI Properties

 

I'd like to be able to use Panel Coords to place certain controls and indicators and also to help with some custom scaling, but I can't do that with the current situation.

Best regards,
Brown

The more I know...the more I don't know
0 Kudos
Message 2 of 6
(1,942 Views)

Brown,

 

I am not in a place where I can run the code now, I will look into it later. 

In the meantime, what happens if you do run the code that you have currently disabled that sets the Pane origin to 0,0?

 

 

For an opportunity to learn from experienced developers / entrepeneurs (Steve, Joerg, and Brian amongst them):
Check out DSH Pragmatic Software Development Workshop!

DQMH Lead Architect * DQMH Trusted Advisor * Certified LabVIEW Architect * Certified LabVIEW Embedded Developer * Certified Professional Instructor * LabVIEW Champion * Code Janitor

Have you been nice to future you?
0 Kudos
Message 3 of 6
(1,909 Views)

Hi Fab,

 

I get the expected results for the top left corner of the panel with respect to the "Origin" of the pane, but it's still saying that the Panel Coords are (0, -184). I'm only using one pane here for simplicity but in my other UI with 3 or 4 panes (also a DQMH module Front Panel) all of my vertical coords are negative.

 

Origin enabledOrigin enabled    ResultsResults

 

I don't see this behavior if I just create a VI on it's own (i.e. not a DQMH main.vi front panel).  I don't know if there's actually a correlation or if I just have a setting wrong.

 

Just for kicks, I threw a splitter bar on that FP and opened up the Pane Relief toolkit to check the splitter position.  It is correct if you subtract the vertical components of the Panes in terms of Panel Coords so there seems to be an offset for some reason (see image).  I just tried doing this in another DQMH main.vi front panel and the Panel coords for the "origin" of the Panes are much larger (on the order of -1500 to 1800) so the offset is a mystery to me.   

 

Two PanesTwo Panes

 

Sorry for all of the images.  I can upload another .zip file with the actual VIs if that will help.

Best regards,
Brown

The more I know...the more I don't know
0 Kudos
Message 4 of 6
(1,906 Views)

Hi Brown,

 

We reached out to NI and we have no idea how the DQMH Main.vi got into that state. We have filed DQMH-694 and we will make sure that the next version of DQMH will have its Main.vi with their pane at 0,0.

 

The workaround is to create a new VI and copy/paste the contents into it. That doesn’t work well if there are multiple panes.

 

We will let you know when we release the new version of DQMH and whether we could find a fix for the existing code.

 

Thanks for reaching out and for your trust in DQMH.

 

Best regards,

Fab

For an opportunity to learn from experienced developers / entrepeneurs (Steve, Joerg, and Brian amongst them):
Check out DSH Pragmatic Software Development Workshop!

DQMH Lead Architect * DQMH Trusted Advisor * Certified LabVIEW Architect * Certified LabVIEW Embedded Developer * Certified Professional Instructor * LabVIEW Champion * Code Janitor

Have you been nice to future you?
Message 5 of 6
(1,848 Views)

Thanks for taking the time to look into it.  I can make do for the time being. 

Best regards,
Brown

The more I know...the more I don't know
Message 6 of 6
(1,831 Views)