Board index FlightGear Development

How To make parts of a PUI/XML dialog invisible

FlightGear is opensource, so you can be the developer. In the need for help on anything? We are here to help you.
Forum rules
Core development is discussed on the official FlightGear-Devel development mailing list.

Bugs can be reported in the bug tracker.

How To make parts of a PUI/XML dialog invisible

Postby mhab » Sat Jun 02, 2018 11:52 am

Hello

I would like to hide some parts of a PUI/XML dialog depending on some condition.
While there is a TAG <enable> there is no TAG <visible> or the like.

In Wiki I found for PUI/XML dialogs:

Widgets can be conditionally hidden/shown using a wrapper for SGCondition in props.nas


Can anyone shed some light on what this is supposed to mean, or how to use it in an example ?

Thanks
Michael
mhab
 
Posts: 418
Joined: Thu Apr 18, 2013 11:59 pm
Callsign: D-MIKE
Version: 2020.3.4
OS: Win10

Re: How To make parts of a PUI/XML dialog invisible

Postby Thorsten » Sat Jun 02, 2018 12:12 pm

While there is a TAG <enable> there is no TAG <visible> or the like.


Oh yes, there is. It's called... ta-da... <visible> and encloses a condition.

But generally I'd advise you to move to canvas for creating new aircraft dialogs - much more powerful and future-proof.
Thorsten
 
Posts: 12490
Joined: Mon Nov 02, 2009 9:33 am


Return to Development

Who is online

Users browsing this forum: No registered users and 5 guests