NI Home > Community > NI Discussion Forums

LabVIEW

Reply
Member
smcclana
Posts: 15
0 Kudos

Transparent Front Panel Position

I'm attempting to fade in/out a front panel pop-up window at a configurable position on the monitor screen.  However, if I have a negative value for the Y Position and I programmatically change the Front Panel Transparency, the Front Panel jumps to a positive Y Position location.

 

I've attached a simple VI which demonstrates this anomaly.  Note that after the fade in, I configure the front panel position again to a negative Y Position, which does work, but as soon as the Transparency control is manipulated again, it jumps the Front Panel Y Position to a positive value again.

Knight of NI
Knight of NI
tst
Posts: 10,795
0 Kudos

Re: Transparent Front Panel Position

There are certain things which cause the window to be moved into the display if it's outside the display. This is supposed to help you in cases where you had a second monitor and disconnected it or accidentally moved the window off screen and you can't get it back. I'm guessing that setting the transparency is one of those things. I'm also guessing that this is done by the OS, not by LV. Your demo VI is displayed fine if I configure Windows to place my secondary screen above my main screen.

 

If you want not to show the window, just set the FP state to hidden.


___________________
Try to take over the world!
Member
smcclana
Posts: 15
0 Kudos

Re: Transparent Front Panel Position

I can configure the Y Position for 0 and the X Position for -100 and it does move it off the screen for a single monitor display.  I'm assuming that since the windows titlebar is on the top, that Windows OS doesn't want that to be unaccessable and force corrects when the transparency is changed.

Active Participant zou
Active Participant
zou
Posts: 1,967
0 Kudos

Re: Transparent Front Panel Position

No.  It's not Window OS problem.  Works just fine when set transparent with Windows API.SemiTransparentWnd.png

Tested with LabVIEW 2010 on XP.

 

So it's a LabVIEW problem.  To get around this problem, try this:

1. disable redraw front panel

2. set transparent

3. set window position

4. force redraw