Canvas widgets: Difference between revisions

Jump to navigation Jump to search
m
no edit summary
m (Link to special directory articles)
mNo edit summary
Line 3: Line 3:
As of 07/2012, there's a general consensus to replace the current FlightGear GUI (based on PLIB/PUI) by using the new Canvas system.
As of 07/2012, there's a general consensus to replace the current FlightGear GUI (based on PLIB/PUI) by using the new Canvas system.


Canvas widgets are dynamically created GUI widgets that use the [[Canvas]] subsystem to create custom, owner-drawn, GUI widgets in a scripted fashion using [[Nasal]]. The textures are conventional canvas textures, however they are rendered by the GUI system, so that scripted handlers can be implemented which respond to GUI events, such as keyboard/mouse input or other events (resize, update, redraw etc).  
Canvas widgets are dynamically created GUI widgets that use the [[Canvas]] subsystem to create custom, owner-drawn, GUI widgets in a scripted fashion using [[Nasal]]. The textures are conventional canvas textures, however they are rendered by the GUI system, so that scripted event handlers can be implemented which respond to GUI events, such as keyboard/mouse input or other events (resize, update, redraw etc).  


Using canvas widgets, it will be possible to create your own GUI styles and even completely new, fully interactive, GUI controls (buttons, text boxes, list views, tree views etc) just using Nasal, without touching any C++ code and without rebuilding FlightGear. The Canvas system supports loading SVG files, so that canvas elements and GUI widgets can be assembled from SVG elements, meaning that you'll  be able to use a conventional SVG editor like Inkscape to create/edit FlightGear GUI widgets.
Using canvas widgets, it will be possible to create your own GUI styles and even completely new, fully interactive, GUI controls (buttons, text boxes, list views, tree views etc) just by using Nasal, without touching any C++ code and without rebuilding FlightGear. The Canvas system supports loading SVG files and raster images, so that canvas elements and GUI widgets can be assembled from SVG elements, meaning that you'll  be able to use a conventional SVG editor like Inkscape to create/edit FlightGear GUI widgets.




Navigation menu