Howto:Creating a Canvas GUI Widget: Difference between revisions

Jump to navigation Jump to search
Line 190: Line 190:
{{Main article|MapStructure}}
{{Main article|MapStructure}}
{{WIP}}
{{WIP}}
The most minimal snippet of code to display a layered MapStructure map is the following:
<syntaxhighlight lang="nasal">
</syntaxhighlight>
Next, we need to wrap this in a Widget.nas child class:


To approximate the appearance of the legacy [[Map]] dialog, we will be using a hbox layout with two columns, with the left column containing a vbox layout with checkboxes added for each layer to control visibility of the layer, and the right hbox cell containing the actual MapStructure map:
To approximate the appearance of the legacy [[Map]] dialog, we will be using a hbox layout with two columns, with the left column containing a vbox layout with checkboxes added for each layer to control visibility of the layer, and the right hbox cell containing the actual MapStructure map:

Navigation menu