Skip to content
View in the app

A better way to browse. Learn more.

The AVSIM Community

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

XML gauge overlay

Featured Replies

I am trying to overlay one xml gauge over another (actually an spb) for a mod I am working on, however I could not get my gauge to appear over the old one.  On further experimentation it appears that a visible customdraw - and not just fs9gps - forces the gauge to be drawn last, ie. over anything else in that patch, irrespective of order in the panel.cfg and draworder statements.

 

Anyone else seen this and/or has a workaround?  Or am I doing something wrong?

  • Moderator

Is this something for your own personal use only? If so, you could decompile the ShapePropBinary (.spb) file and then insert your additions into the existing 'raw' XML script.

Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator
  • Author

Thanks for your reply Bill.

 

That's exactly what I'm trying to avoid :)  So, no other way?

  • Moderator

None that I'm aware of, no.

Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator
  • Author

Found a solution, obvious in retrospect (aren't they all?)

 

Put a customdraw in the overlaying gauge.  Even a size of 0x0 works!

  • Moderator

Found a solution, obvious in retrospect (aren't they all?)

 

Put a customdraw in the overlaying gauge.  Even a size of 0x0 works!

Well I'll be! Now we both have learned something new. I'll have the answer handy the next time the subject is brought up. :Applause:

Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator
  • 2 weeks later...

Found a solution, obvious in retrospect (aren't they all?)

 

Put a customdraw in the overlaying gauge.  Even a size of 0x0 works!

 

Very interesting !

 

Any further details on the above method would be greatly appreciated .

 

Is this a matter of placing 2 gauges at the same x,y location in the panel cfg ?

 

How do you determine which gauge appears on top ?

 

Cheers

Karol

  • Author

Yes.  Generally the order is determined by the order in the panel.cfg but FSX sometimes takes things into its own hands, however you can use the draworder statement to force the desired draw order (the last drawn is the one that shows).

 

Even so, you cannot draw an xml gauge over a C/C++ gauge (.gau), and, as I found out, you cannot draw an xml gauge over another xml gauge that contains a customdraw statement (unless the top gauge itself contains a customdraw).

 

However it doesn't work very well even so, the lower gauge is sometimes drawn over the upper one (at a guess, if something changes in it while it doesn't change in the upper gauge) and you get a lot of unsightly flashes.  So I've more or less given up on it for the moment.


(Just to be clear in the above post, it's overlaying an xml gauge over another that has a customdraw that is the problem, xml gauges normally overlay without any problems)

Cool , it could be fun to persue .

 

So if I create a dummy xml gauge without any Custom Draw .

then

Overlay that with a second gauge that contains Custom Draw.

it might work.

 

Thanks for the ideas .

I've had a gauge for several years that has frustrated me as I have not been

able to add it as a normal panel entry.

 

Cheers

Karol

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.