interface - ryzom/ryzomcore GitHub Wiki
title: Interface description: Creating user interfaces with the NeL GUI system, using XML, database, action handlers and Lua published: true editor: markdown
The NeL interface system is a data-driven GUI: windows, widgets, layout, styling, game-data bindings and most behavior are described in XML interface files, reactive state lives in an interface database, behavior hooks are action handlers and Lua scripts. The C++ engine (the NeL GUI library) parses the XML, renders everything from a texture atlas, and routes input. A complete UI, including whole mini-applications, can be authored without touching engine code.
This section is for anyone building a UI: interface authors, scripters, and programmers. The library internals and the embedding contract for new applications are documented separately under NeL GUI.

Everything on this page tree is verified against the GUI widget sample (nel/samples/gui/), a standalone showcase you can run natively or in the browser. It is the quickest way to experiment: nl_sample_gui --xml your_file.xml -d your_data_dir parses extra interface XML on top of the showcase.
- Everything on screen is an element in one tree: groups contain views (display-only), controls (interactive) and other groups. Every element has an id; full ids are colon paths like
ui:sample:editors:content:eb_text. -
Windows are groups registered on a master group (
<root id="sample">→ui:sample). Only registered windows draw; a stray group at the root parses fine and renders never. - Position is relative: each element pins one of its nine hotspots to a hotspot of its parent (or any named sibling). There is no layout engine re-flowing content; there are anchors, offsets, and size references. See Layout.
- The interface database is a tree of 64-bit values (
UI:...,SERVER:...). Widgets bind to leaves;<link>elements evaluate expressions when leaves change and write the result into element properties. See Database, links and expressions. -
Action handlers are named C++ (or script-backed) commands wired to widget events (
onclick_l="proc" params_l="proc_toggle|help"). Sequences of them are procedures. See Action handlers and procedures. -
Lua sees every element as an object with reflected properties (
ui('views').active = false) and can drive the whole interface at runtime. See Lua scripting.
- Your first window: a minimal working interface file, explained line by line
- Layout: positioning and sizing: hotspots, posref, posparent, sizeref, render layers
- Interface XML structure: files and parse order, defines, templates, vectors, styles, options blocks, feature flags
- Display widgets (views): text, bitmaps, numbers, gauges
- Interactive widgets (controls): buttons, sliders, edit boxes, combo boxes, color picker
- Windows and containers: containers, modals, menus, tabs, trees, lists, rollouts
- Database, links and expressions: reactive state and the expression language
- Action handlers and procedures: event wiring, the built-in catalog, procedures
- Lua scripting: the script API, widget reflection, building whole apps in data
- HTML groups: the embedded browser widget and tables
- Skinning and textures: the atlas, skin option blocks, fonts
- NeL GUI library: architecture and internals
- Embedding NeL GUI in an application: what a host application must provide
- GUI widget sample: the showcase these docs screenshot
- Feature flags: conditional interface XML per product flavor
Historical: the GUI Editor OVQT plugin and old UI editing notes from the Atlassian archive; the client-side /loadui reload workflow described there still exists in the Ryzom client.