Howto:Prototyping a new NavDisplay Style: Difference between revisions

Jump to navigation Jump to search
m
→‎Approach: use gallery tag
m (→‎Approach: use gallery tag)
Line 4: Line 4:
{{See also|FGCanvas}}
{{See also|FGCanvas}}
Demonstrate how a simple PUI/XML dialog can be used to easily prototype new [[NavDisplay]] styles, showing two instances for each pilot, which can be controlled/tested independently (using different settings for range, modes, traffic etc). Once the dialog is closed/reopened, the underlying navdisplay.mfd/styles files are also automatically reloaded from disk, so that you don't need to exist/restart fgfs to test your cchanges.
Demonstrate how a simple PUI/XML dialog can be used to easily prototype new [[NavDisplay]] styles, showing two instances for each pilot, which can be controlled/tested independently (using different settings for range, modes, traffic etc). Once the dialog is closed/reopened, the underlying navdisplay.mfd/styles files are also automatically reloaded from disk, so that you don't need to exist/restart fgfs to test your cchanges.
== Gallery ==
<gallery mode="packed">
Nd-ide.png|Screenshot showing two independent [[NavDisplay]] instances rendered in a [[PUI]] widget via [[Canvas]]
NDPrototypingDialog.png|[[PUI]] dialog with 3 embedded [[NavDisplay]] instances controlled via checkboxes (i.e. no property browser needed)
ND-dialog-with-3-ND-instances.png|Screenshot showing a PUI dialog with 3 NDs and different settings applied for each instance
ND dialog with wxr layer.png|ND dialog with WXR layer shown
ND-dialog-airbus-style.png|ND dialog showing the Airbus style of the [[NavDisplay]] module
ND dialog allowing styles to be changed at runtime.png|[[PUI]] dialog showing 3 independent [[NavDisplay]] instances with styling being customizable at runtime.
ND-Dialog-with-DisplayMode-support.png|[[PUI]] dialog showing two independent [[NavDisplay]] instances with different styles applied and support for toggling display modes separately
Updated-NDStyles-Dialog.png|Updated [[PUI]]/XML dialog showing different ND styles in use.
NDStylesDialog-with-ADF-VOR-Selection.png|Dialog with VOR/ADF selelection support
</gallery>


== Approach ==
== Approach ==
[[File:Nd-ide.png|thumb|Screenshot showing two independent [[NavDisplay]] instances rendered in a [[PUI]] widget via [[Canvas]]]]
[[File:NDPrototypingDialog.png|thumb|[[PUI]] dialog with 3 embedded [[NavDisplay]] instances controlled via checkboxes (i.e. no property browser needed)]]
[[File:ND-dialog-with-3-ND-instances.png|thumb|Screenshot showing a PUI dialog with 3 NDs and different settings applied for each instance]]
[[File:ND dialog with wxr layer.png|thumb|ND dialog with WXR layer shown]]
[[File:ND-dialog-airbus-style.png|thumb|ND dialog showing the Airbus style of the [[NavDisplay]] module]]
[[File:ND dialog allowing styles to be changed at runtime.png|thumb|[[PUI]] dialog showing 3 independent [[NavDisplay]] instances with styling being customizable at runtime.]]
[[File:ND-Dialog-with-DisplayMode-support.png|thumb|[[PUI]] dialog showing two independent [[NavDisplay]] instances with different styles applied and support for toggling display modes separately]]
[[File:Updated-NDStyles-Dialog.png|thumb|Updated [[PUI]]/XML dialog showing different ND styles in use.]]
[[File:NDStylesDialog-with-ADF-VOR-Selection.png|thumb|Dialog with VOR/ADF selelection support]]


This is a PUI/XML dialog with two embedded CanvasWidget areas that instantiate independent ND instances using a subset of the code commonly found in the aircraft specific ND.nas file, adapted to use the embedded Canvas region for rendering the two NDs and GUI buttons/widgets added to control the whole thing without necessarily requiring a fully developed cockpit.
This is a PUI/XML dialog with two embedded CanvasWidget areas that instantiate independent ND instances using a subset of the code commonly found in the aircraft specific ND.nas file, adapted to use the embedded Canvas region for rendering the two NDs and GUI buttons/widgets added to control the whole thing without necessarily requiring a fully developed cockpit.

Navigation menu