limn
    ↑↓ ChooseEnter OpenEsc Close
    GitHub

    Documentation/limn documentation

    limn documentation

    limn is a native UI library for Rust. An application describes its window as a tree of elements; the library lays it out, keeps the state of every control, and produces drawing commands for a backend to paint.

    The pages are organized by what you are trying to do.

    Learn

    Start here if you have never used the library.

    PageWhat you get from it
    Getting startedA window with a working counter, built step by step.

    Understand

    Background that explains why the library behaves as it does.

    PageWhat it explains
    ConceptsElements, the tree, frames, IDs, and who owns state.
    AnimationWhat moves, for how long, and how it is switched off.

    Do a specific task

    PageTask
    LayoutArrange, size, center and wrap elements.
    ThemingChoose colors, corner radii and pace.
    Guided toursPoint at existing controls and explain them step by step.
    TestingTest a component or a screen without a window.
    AccessibilityWhat a screen reader is told, and what you have to name.
    Hot reloadEdit your application while it runs, with its state kept.
    Gallery and hot reloadBrowse components, edit them live, capture screenshots.
    Contributing a componentAdd a component, its test, its demo and its documentation.

    Look something up

    PageContents
    TokensEvery radius and duration, with defaults.
    ComponentsEvery component, by category, with its purpose.
    Backend contractDraw commands, events and fonts, for writing a renderer.
    API referencecargo doc -p limn --open lists every type and method.

    Conventions used in these pages

    • Sizes are logical pixels. The backend applies the display’s scale factor.
    • Durations are milliseconds.
    • “The host” is the application that owns a UiTree.
    • Code samples assume use limn::*; unless they show their own imports.