SleelaDoc API
HTML documentation for the SLeeLa standard library (/lib)
Home › Packages › user-interface

Package user-interface

This package contains 89 source unit(s) defining 90 class(es) / struct(s). Each unit below lists its fields (the values it stores) and methods (the actions it performs), with a plain explanation of each.

astrophysics #sleela 2.5 (lib/user-interface/example/science/astrophysics.sleela)

ScienceAstrophysics class

Methods — the actions this unit can perform.

MethodSignatureWhat it does
bannervoid banner(String t)No description in source.
mainvoid main()No description in source.

chemistry #sleela 2.5 (lib/user-interface/example/science/chemistry.sleela)

ScienceChemistry class

Methods — the actions this unit can perform.

MethodSignatureWhat it does
bannervoid banner(String t)No description in source.
mainvoid main()No description in source.

gui-app-demo #sleela 2.5 (lib/user-interface/gui-app-demo.sleela)

GuiAppDemo class

Runnable demonstrator for the /lib/gui support structure. It boots an SLGuiApp (application + window + DOM + reconciler + host adapter + script engine), builds a small interface in the SLeeLa DOM, binds an onClick callback, drives part of the UI from a script, refreshes once to project the DOM onto real SleelaUI widgets, and (on a display) hands control to the run loop. On a headless host boot() returns false and it exits cleanly, like gui-demo.sleela. This proves the architectural wiring end to end: DOM -> reconcile -> widgets, and widget activations -> events -> handlers. Family: user-interface. SLeeLa owns the document and dispatch; SleelaUI renders it.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
boolToStrString boolToStr(boolean b)No description in source.
bannervoid banner(String t)No description in source.
runint run()No description in source.

gui-dual-media-studio #sleela 2.5 (lib/user-interface/example/dual/gui-dual-media-studio.sleela)

GuiDualMediaStudio class

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
ALLOW_HORIZONTAL_OVERFLOWstatic final int ALLOW_HORIZONTAL_OVERFLOW = 0SLUITheme preset ordinals (mirror SLUIThemeId in the toolkit C ABI). Static build policy: default keeps the normal layout within its parent width. Set to 1 only in builds that intentionally permit horizontal overflow.
SCROLL_AUTOint SCROLL_AUTO = 0Scroll-policy ordinal (mirror the toolkit C ABI: 0=auto on overflow).
btnPlayint btnPlayLive handles the event loop reacts on/to.
btnPauseint btnPauseNo description in source.
btnStopint btnStopNo description in source.
btnRecint btnRecNo description in source.
btnRecStopint btnRecStopNo description in source.
statusLabelint statusLabelNo description in source.
wifiButtonint wifiButtonLower-right status-bar connectivity control and its dismissible menu.
wifiPanelint wifiPanelNo description in source.
wifiStatusLabelint wifiStatusLabelNo description in source.
wifiScanButtonint wifiScanButtonNo description in source.
wifiConnectButtonint wifiConnectButtonNo description in source.
wifiDisconnectButtonint wifiDisconnectButtonNo description in source.
wifiSettingsButtonint wifiSettingsButtonNo description in source.
wifiInfoButtonint wifiInfoButtonNo description in source.
wifiProfileEntryint wifiProfileEntryNo description in source.
wifiCloseButtonint wifiCloseButtonNo description in source.
openMenuIndexint openMenuIndex = -1Menubar strip and its dropdown panels (built from existing ui* widgets).
menuFileButtonint menuFileButtonNo description in source.
menuFilePanelint menuFilePanelNo description in source.
menuFileItem1int menuFileItem1No description in source.
menuFileItem2int menuFileItem2No description in source.
menuMediaButtonint menuMediaButtonNo description in source.
menuMediaPanelint menuMediaPanelNo description in source.
menuMediaItem1int menuMediaItem1No description in source.
menuMediaItem2int menuMediaItem2No description in source.
menuPlaybackButtonint menuPlaybackButtonNo description in source.
menuPlaybackPanelint menuPlaybackPanelNo description in source.
menuPlaybackItem1int menuPlaybackItem1No description in source.
menuPlaybackItem2int menuPlaybackItem2No description in source.
menuHelpButtonint menuHelpButtonNo description in source.
menuHelpPanelint menuHelpPanelNo description in source.
menuHelpItem1int menuHelpItem1No description in source.
menuHelpItem2int menuHelpItem2No description in source.
THEME_GRAYint THEME_GRAY = 7A cool "glass" studio theme for the DUAL line. Shared SLeeLa family palette: chrome/title bar #1D2025, Standard Pattern ordinal (mirror SLUIThemeId): 7=GRAY. dual uses GRAY.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
rgbaint rgba(int r, int g, int b, int a)No description in source.
rgbint rgb(int r, int g, int b)No description in source.
clampint clamp(int v, int lo, int hi)No description in source.
intToStrString intToStr(int v)No description in source.
canPlayTypeboolean canPlayType(String mime)Codec gate: the studio consults the registry before offering a control.
playMediavoid playMedia()Shared action helpers keep menu commands and transport buttons consistent.
pauseMediavoid pauseMedia()No description in source.
stopMediavoid stopMedia()No description in source.
startRecordingvoid startRecording()No description in source.
stopRecordingvoid stopRecording()No description in source.
glassThemeint glassTheme()dual is the GRAY Standard Pattern: neutral mid-gray surfaces with light text, supplied by the toolkit preset (no per-colour overrides); metrics only.
openMenuvoid openMenu(int which)Show one dropdown at a time; selecting the open menu closes it.
wifiActionUnavailablevoid wifiActionUnavailable(String action)No description in source.
mainvoid main()No description in source.

gui-events-demo #sleela 2.5 (lib/user-interface/gui-events-demo.sleela)

GuiEventsDemo class

Runnable demonstrator for the /lib/gui event + DHTML + scripting layer. It builds a small document (a window with a button and an entry), binds callbacks (onClick / onInput) the DHTML way, raises events and shows the dispatcher routing them to operations with the take-the-latch latch, demonstrates preventDefault/stopPropagation, mutates the DOM live (setText/setStyle/hide), and finally drives the SAME interface from an SLGuiScript command list — proving the UI can be authored and driven by scripting. Self-contained (inline flow + main), in the style of gui-demo.sleela. Family: user-interface. SLeeLa owns dispatch and the meaning of events; a host only raises them and mirrors the DOM onto widgets.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
boolToStrString boolToStr(boolean b)No description in source.
bannervoid banner(String t)No description in source.
mainvoid main()No description in source.

gui-gual-settings-console #sleela 2.5 (lib/user-interface/example/gual/gui-gual-settings-console.sleela)

GuiGualSettingsConsole class

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
ALLOW_HORIZONTAL_OVERFLOWstatic final int ALLOW_HORIZONTAL_OVERFLOW = 0SLUITheme preset ordinals (mirror SLUIThemeId in the toolkit C ABI). Static build policy: default keeps the normal layout within its parent width. Set to 1 only in builds that intentionally permit horizontal overflow.
SCROLL_AUTOint SCROLL_AUTO = 0Scroll-policy ordinal (mirror the toolkit C ABI: 0=auto on overflow).
btnJfxint btnJfxLive handles the event loop reacts on/to.
btnSwingint btnSwingNo description in source.
btnNativeint btnNativeNo description in source.
btnQtint btnQtNo description in source.
statusLabelint statusLabelNo description in source.
wifiButtonint wifiButtonLower-right status-bar connectivity control and its dismissible menu.
wifiPanelint wifiPanelNo description in source.
wifiStatusLabelint wifiStatusLabelNo description in source.
wifiScanButtonint wifiScanButtonNo description in source.
wifiConnectButtonint wifiConnectButtonNo description in source.
wifiDisconnectButtonint wifiDisconnectButtonNo description in source.
wifiSettingsButtonint wifiSettingsButtonNo description in source.
wifiInfoButtonint wifiInfoButtonNo description in source.
wifiProfileEntryint wifiProfileEntryNo description in source.
wifiCloseButtonint wifiCloseButtonNo description in source.
openMenuIndexint openMenuIndex = -1Menubar strip and its dropdown panels (built from existing ui* widgets).
menuFileButtonint menuFileButtonNo description in source.
menuFilePanelint menuFilePanelNo description in source.
menuFileItem1int menuFileItem1No description in source.
menuFileItem2int menuFileItem2No description in source.
menuSettingsButtonint menuSettingsButtonNo description in source.
menuSettingsPanelint menuSettingsPanelNo description in source.
menuSettingsItem1int menuSettingsItem1No description in source.
menuSettingsItem2int menuSettingsItem2No description in source.
menuBackendButtonint menuBackendButtonNo description in source.
menuBackendPanelint menuBackendPanelNo description in source.
menuBackendItem1int menuBackendItem1No description in source.
menuBackendItem2int menuBackendItem2No description in source.
menuHelpButtonint menuHelpButtonNo description in source.
menuHelpPanelint menuHelpPanelNo description in source.
menuHelpItem1int menuHelpItem1No description in source.
menuHelpItem2int menuHelpItem2No description in source.
THEME_BLACKint THEME_BLACK = 5A hardened, neutral "settings" theme. Shared SLeeLa family palette: chrome/title bar #1D2025, Standard Pattern ordinal (mirror SLUIThemeId): 5=BLACK. gual uses BLACK.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
rgbaint rgba(int r, int g, int b, int a)No description in source.
rgbint rgb(int r, int g, int b)No description in source.
selectBackendvoid selectBackend(int which)Mark one accepted backend button as selected (fail-closed: qt stays off).
clampint clamp(int v, int lo, int hi)Clamp an int into [lo, hi] — the heart of GUAL's settings discipline.
intToStrString intToStr(int v)No description in source.
settingsThemeint settingsTheme()gual is the BLACK Standard Pattern: deep black surfaces with light text, supplied by the toolkit preset (no per-colour overrides); metrics only.
openMenuvoid openMenu(int which)Show one dropdown at a time; selecting the open menu closes it.
wifiActionUnavailablevoid wifiActionUnavailable(String action)No description in source.
mainvoid main()No description in source.

gui-menubar-expandable #sleela 2.5 (lib/user-interface/example/menus/gui-menubar-expandable.sleela)

GuiMenubarExpandable class

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
PADint PAD = 10No description in source.
GAPint GAP = 6No description in source.
VERTICALint VERTICAL = 0No description in source.
HORIZONTALint HORIZONTAL = 1No description in source.
statusLabelint statusLabelNo description in source.
openMenuIndexint openMenuIndex = -1No description in source.
recentOpenboolean recentOpen = falseNo description in source.
panelsOpenboolean panelsOpen = falseNo description in source.
fileButtonint fileButtonNo description in source.
editButtonint editButtonNo description in source.
viewButtonint viewButtonNo description in source.
helpButtonint helpButtonNo description in source.
filePanelint filePanelNo description in source.
editPanelint editPanelNo description in source.
viewPanelint viewPanelNo description in source.
helpPanelint helpPanelNo description in source.
recentToggleint recentToggleNo description in source.
recentPanelint recentPanelNo description in source.
recentOneint recentOneNo description in source.
recentTwoint recentTwoNo description in source.
recentThreeint recentThreeNo description in source.
panelsToggleint panelsToggleNo description in source.
panelsPanelint panelsPanelNo description in source.
panelEditorint panelEditorNo description in source.
panelInspectorint panelInspectorNo description in source.
fileNewint fileNewNo description in source.
fileSaveint fileSaveNo description in source.
editUndoint editUndoNo description in source.
editSelectAllint editSelectAllNo description in source.
viewZoomInint viewZoomInNo description in source.
viewZoomOutint viewZoomOutNo description in source.
helpAboutint helpAboutNo description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
setStatusvoid setStatus(String message)No description in source.
openMenuvoid openMenu(int which)Exactly one top-level dropdown is open at a time. Clicking its heading again collapses it; choosing another heading switches directly to it.
toggleRecentFilesvoid toggleRecentFiles()No description in source.
togglePanelsvoid togglePanels()No description in source.
closeMenusvoid closeMenus()No description in source.
mainvoid main()No description in source.

gui-military-command-console #sleela 2.5 (lib/user-interface/example/military/gui-military-command-console.sleela)

GuiMilitaryCommandConsole class

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
THEME_CUSTOMint THEME_CUSTOM = 2SLUITheme preset ordinals (mirror SLUIThemeId in the toolkit C ABI).
SCROLL_AUTOint SCROLL_AUTO = 0Scroll-policy ordinal (mirror the toolkit C ABI: 0=auto on overflow).
btnAuthorizeint btnAuthorizeLive handles the event loop reacts on/to.
btnRunint btnRunNo description in source.
btnResetint btnResetNo description in source.
statusLabelint statusLabelNo description in source.
wifiMenuOpenboolean wifiMenuOpen = falseNo description in source.
wifiButtonint wifiButtonLower-right status-bar connectivity control and its dismissible menu.
wifiPanelint wifiPanelNo description in source.
wifiStatusLabelint wifiStatusLabelNo description in source.
wifiScanButtonint wifiScanButtonNo description in source.
wifiConnectButtonint wifiConnectButtonNo description in source.
wifiDisconnectButtonint wifiDisconnectButtonNo description in source.
wifiSettingsButtonint wifiSettingsButtonNo description in source.
wifiInfoButtonint wifiInfoButtonNo description in source.
wifiProfileEntryint wifiProfileEntryNo description in source.
wifiCloseButtonint wifiCloseButtonNo description in source.
consoleMenuIndexint consoleMenuIndex = -1Reusable menu-bar interaction state for the command console.
menuFileButtonint menuFileButtonNo description in source.
menuEditButtonint menuEditButtonNo description in source.
menuViewButtonint menuViewButtonNo description in source.
menuHelpButtonint menuHelpButtonNo description in source.
menuFilePanelint menuFilePanelNo description in source.
menuEditPanelint menuEditPanelNo description in source.
menuViewPanelint menuViewPanelNo description in source.
menuHelpPanelint menuHelpPanelNo description in source.
menuFileNewint menuFileNewNo description in source.
menuFileSaveint menuFileSaveNo description in source.
menuEditAuditint menuEditAuditNo description in source.
menuEditClearint menuEditClearNo description in source.
menuViewStatusint menuViewStatusNo description in source.
menuViewCertificatesint menuViewCertificatesNo description in source.
menuHelpAboutint menuHelpAboutNo description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
openConsoleMenuvoid openConsoleMenu(int index)No description in source.
closeConsoleMenusvoid closeConsoleMenus()No description in source.
rgbaint rgba(int r, int g, int b, int a)0xRRGGBBAA colours for the military "metal / blue-hue" palette.
rgbint rgb(int r, int g, int b)No description in source.
militaryThemeint militaryTheme()Build the hardened metal/blue military theme and return its handle. Shared SLeeLa family palette: chrome/title bar #1D2025, URL-entry surface #383C47; keep these tokens aligned across all five lines.
toggleWifiMenuvoid toggleWifiMenu()No description in source.
closeWifiMenuvoid closeWifiMenu()No description in source.
wifiActionUnavailablevoid wifiActionUnavailable(String action)No description in source.
mainvoid main()No description in source.

gui-mual-text-editor #sleela 2.5 (lib/user-interface/example/mual/gui-mual-text-editor.sleela)

GuiMualTextEditor class

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
VERTICALint VERTICAL = 0SLUITheme preset ordinals (mirror SLUIThemeId in the toolkit C ABI). Orientation + scroll-policy ordinals (mirror the toolkit C ABI).
HORIZONTALint HORIZONTAL = 1No description in source.
SCROLL_AUTOint SCROLL_AUTO = 0No description in source.
wifiButtonint wifiButtonint aboutPanel; // panel: about/help int statusLabel; // the status line text Lower-right status-bar connectivity control and its dismissible menu.
wifiPanelint wifiPanelNo description in source.
wifiStatusLabelint wifiStatusLabelNo description in source.
wifiScanButtonint wifiScanButtonNo description in source.
wifiConnectButtonint wifiConnectButtonNo description in source.
wifiDisconnectButtonint wifiDisconnectButtonNo description in source.
wifiSettingsButtonint wifiSettingsButtonNo description in source.
wifiInfoButtonint wifiInfoButtonNo description in source.
wifiProfileEntryint wifiProfileEntryNo description in source.
wifiCloseButtonint wifiCloseButtonNo description in source.
btnDocsint btnDocsNo description in source.
btnAboutint btnAboutNo description in source.
btnSaveint btnSaveNo description in source.
btnNewint btnNewNo description in source.
openMenuIndexint openMenuIndex = -1Menubar strip and its dropdown panels (built from existing ui* widgets).
menuFileButtonint menuFileButtonNo description in source.
menuFilePanelint menuFilePanelNo description in source.
menuFileItem1int menuFileItem1No description in source.
menuFileItem2int menuFileItem2No description in source.
menuEditButtonint menuEditButtonNo description in source.
menuEditPanelint menuEditPanelNo description in source.
menuEditItem1int menuEditItem1No description in source.
menuEditItem2int menuEditItem2No description in source.
menuViewButtonint menuViewButtonNo description in source.
menuViewPanelint menuViewPanelNo description in source.
menuViewItem1int menuViewItem1No description in source.
menuViewItem2int menuViewItem2No description in source.
menuHelpButtonint menuHelpButtonNo description in source.
menuHelpPanelint menuHelpPanelNo description in source.
menuHelpItem1int menuHelpItem1No description in source.
menuHelpItem2int menuHelpItem2No description in source.
THEME_WHITEint THEME_WHITE = 4Standard Pattern ordinal (mirror SLUIThemeId in the toolkit C ABI): 4=WHITE, 5=BLACK, 6=BLUE, 7=GRAY. This line (mual) uses WHITE.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
rgbaint rgba(int r, int g, int b, int a)No description in source.
rgbint rgb(int r, int g, int b)No description in source.
baselineThemeint baselineTheme()Build the baseline editor theme and return its handle. mual is the WHITE Standard Pattern: a light surface family with dark text and a blue accent, supplied by the toolkit preset (no per-colour overrides); only the family metrics are tuned here.
showPanelvoid showPanel(int which)Show exactly one panel; mark the active toolbar button as suggested.
openMenuvoid openMenu(int which)Show one dropdown at a time; selecting the open menu closes it.
wifiActionUnavailablevoid wifiActionUnavailable(String action)No description in source.
mainvoid main()No description in source.

gui-thual-effects-showcase #sleela 2.5 (lib/user-interface/example/thual/gui-thual-effects-showcase.sleela)

GuiThualEffectsShowcase class

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
SCROLL_AUTOint SCROLL_AUTO = 0SLUITheme preset ordinals (mirror SLUIThemeId in the toolkit C ABI). Scroll-policy ordinal (mirror the toolkit C ABI: 0=auto on overflow).
btnConfirmint btnConfirmLive handles the event loop reacts on/to.
btnFadeint btnFadeNo description in source.
statusLabelint statusLabelNo description in source.
wifiButtonint wifiButtonLower-right status-bar connectivity control and its dismissible menu.
wifiPanelint wifiPanelNo description in source.
wifiStatusLabelint wifiStatusLabelNo description in source.
wifiScanButtonint wifiScanButtonNo description in source.
wifiConnectButtonint wifiConnectButtonNo description in source.
wifiDisconnectButtonint wifiDisconnectButtonNo description in source.
wifiSettingsButtonint wifiSettingsButtonNo description in source.
wifiInfoButtonint wifiInfoButtonNo description in source.
wifiProfileEntryint wifiProfileEntryNo description in source.
wifiCloseButtonint wifiCloseButtonNo description in source.
openMenuIndexint openMenuIndex = -1Menubar strip and its dropdown panels (built from existing ui* widgets).
menuFileButtonint menuFileButtonNo description in source.
menuFilePanelint menuFilePanelNo description in source.
menuFileItem1int menuFileItem1No description in source.
menuFileItem2int menuFileItem2No description in source.
menuEffectsButtonint menuEffectsButtonNo description in source.
menuEffectsPanelint menuEffectsPanelNo description in source.
menuEffectsItem1int menuEffectsItem1No description in source.
menuEffectsItem2int menuEffectsItem2No description in source.
menuViewButtonint menuViewButtonNo description in source.
menuViewPanelint menuViewPanelNo description in source.
menuViewItem1int menuViewItem1No description in source.
menuViewItem2int menuViewItem2No description in source.
menuHelpButtonint menuHelpButtonNo description in source.
menuHelpPanelint menuHelpPanelNo description in source.
menuHelpItem1int menuHelpItem1No description in source.
menuHelpItem2int menuHelpItem2No description in source.
THEME_BLUEint THEME_BLUE = 6A bright, dimensional "studio" theme for the effects line. Shared SLeeLa family palette: chrome/title bar #1D2025, Standard Pattern ordinal (mirror SLUIThemeId): 6=BLUE. thual uses BLUE.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
rgbaint rgba(int r, int g, int b, int a)No description in source.
rgbint rgb(int r, int g, int b)No description in source.
clampint clamp(int v, int lo, int hi)Every effect knob clamps to a safe window (the THUAL discipline).
intToStrString intToStr(int v)No description in source.
studioThemeint studioTheme()thual is the BLUE Standard Pattern: blue-tinted surfaces with light text, supplied by the toolkit preset (no per-colour overrides); metrics only.
openMenuvoid openMenu(int which)Show one dropdown at a time; selecting the open menu closes it.
wifiActionUnavailablevoid wifiActionUnavailable(String action)No description in source.
mainvoid main()No description in source.

guide-chain-syntax #sleela 2.5 (lib/user-interface/example/science/guide-chain-syntax.sleela)

Perfect class

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
growthint growththe seated growth, accumulated as each Guide fires
trailString trailNo description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createvoid create()No description in source.
patchvoid patch()--- the Guides: each a zero-argument method, seated via :: ---
seedvoid seed()No description in source.
aimvoid aim()No description in source.
guidevoid guide()No description in source.
totalint total()No description in source.
chainString chain()No description in source.

GuideChainSyntax class

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
mainvoid main()No description in source.

math #sleela 2.5 (lib/user-interface/example/science/math.sleela)

ScienceMath class

Methods — the actions this unit can perform.

MethodSignatureWhat it does
bannervoid banner(String t)No description in source.
mainvoid main()No description in source.

philosophers-constructor #sleela 2.5 (lib/user-interface/example/science/philosophers-constructor.sleela)

PhilosophersConstructorExample class

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
buildOnevoid buildOne(String title, int quorum, int seconds)Build one Constructor, run it for a duration, and print its report.
mainvoid main()No description in source.

physics #sleela 2.5 (lib/user-interface/example/science/physics.sleela)

SciencePhysics class

Methods — the actions this unit can perform.

MethodSignatureWhat it does
bannervoid banner(String t)No description in source.
mainvoid main()No description in source.

SLAvatar #sleela 2.5 (lib/user-interface/SLAvatar.sleela)

SLAvatar class extends SLWidget

Defines SLAvatar — a SleelaUI round avatar: an accent disc of a fixed diameter showing a centred initial, used to represent a person or account. The constructor bottoms out in the `uiAvatar` built-in (SleelaUI C ABI slui_avatar()); the initial is updated through the inherited setText(). An SLAvatar IS an SLWidget but is non-interactive. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String initial, int diameter)Create an avatar inside `parent` with an initial and a diameter (px).
createInHandlevoid createInHandle(int parentHandle, String initial, int diameter)No description in source.

SLBadge #sleela 2.5 (lib/user-interface/SLBadge.sleela)

SLBadge class extends SLWidget

Defines SLBadge — a SleelaUI count/status pill: a small rounded accent pill with centred text, used to annotate a control with a count or short status (e.g. an unread count next to a title). The constructor bottoms out in the `uiBadge` built-in (SleelaUI C ABI slui_badge()); the text is updated through the inherited setText(). An SLBadge IS an SLWidget but is non-interactive. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String text)Create a badge inside `parent` with text (often a small number).
createInHandlevoid createInHandle(int parentHandle, String text)No description in source.

SLBox #sleela 2.5 (lib/user-interface/SLBox.sleela)

SLBox class extends SLWidget

Defines SLBox — the primary SleelaUI container: a horizontal or vertical box that lays its children out with the GTK/CSS box model (natural sizes first, surplus split among expanding children, then cross-axis alignment). Children are added by constructing control classes against this box's handle. The constructor bottoms out in the `uiBox` built-in, which calls the SleelaUI C ABI slui_box(). A box IS an SLWidget, so it carries the full margin/align/expand surface and can itself be nested inside another box to build rich layouts. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, int orientation, int spacing)Create a box inside `parent` (an SLWidget). orientation is ORIENT_VERTICAL or ORIENT_HORIZONTAL; spacing is the gap between children in pixels.
createInHandlevoid createInHandle(int parentHandle, int orientation, int spacing)No description in source.
verticalvoid vertical(SLWidget parent, int spacing)Convenience constructors for the two orientations.
horizontalvoid horizontal(SLWidget parent, int spacing)No description in source.

SLButton #sleela 2.5 (lib/user-interface/SLButton.sleela)

SLButton class extends SLWidget

Defines SLButton — a SleelaUI push button: a rounded surface with centred text, a 1px hairline, a hover/active tint, and an accent focus ring when keyboard-focused. Mark it suggested() to make it the one accent action in its group, or destructive() to turn it red on hover. The constructor bottoms out in the `uiButton` built-in (SleelaUI C ABI slui_button()); clicks (and Enter/Space while focused) raise an activate event the host polls through the application's event loop. An SLButton IS an SLWidget and is keyboard-focusable. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String label)Create a button inside `parent` with a label.
createInHandlevoid createInHandle(int parentHandle, String label)No description in source.
createInWithIconvoid createInWithIcon(SLWidget parent, String label, SLIcon icon)Create a labelled button and attach an icon descriptor in one operation.
createInHandleWithIconvoid createInHandleWithIcon(int parentHandle, String label, SLIcon icon)No description in source.
setIconvoid setIcon(SLIcon icon)Attach a JPEG icon plus a named fallback symbol (for example, Wifi).
setIconPathvoid setIconPath(String assetPath, String symbolName)No description in source.
clickedboolean clicked()True if this button has an activation pending since the last check; the VM clears the latch on read, so each click is observed exactly once.
hoveredboolean hovered()True while the pointer is over the button.
takePressedboolean takePressed()One-shot pointer press/release and hover transition events.
takeReleasedboolean takeReleased()No description in source.
takeHoverEnteredboolean takeHoverEntered()No description in source.
takeHoverLeftboolean takeHoverLeft()No description in source.

SLCalculus8 #sleela 2.5 (lib/user-interface/SLCalculus8.sleela)

SLCalculus8 class

Defines SLCalculus8 — the careful 8-stage calculus with 100 differentiable inputs that maps a SleelaUI light's control points directly into a MOOD. Each of the 100 inputs is a "differentiable" the host nudges in [0,1]; eight smooth, analytically-differentiable basis stages (identity, quadratic, smoothstep, sine, cosine, logistic, gaussian, tanh) combine them into a mood scalar in [0,1]. Because every stage is differentiable, eval returns both the mood and the slope d(mood)/d(input) so an adjuster can walk the gradient into a mood. Each method bottoms out in a `calc8*` SLVM built-in that calls the genuine C ABI (sleela_ui_mood.h). A calculus is a VM-local handle (-1 = none). Attach it to an SLMood with SLMood.setCalculus to drive where the mood's wash is sampled. Family: user-interface. Native VM/UI work crosses the explicit `calc8*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
INPUTSstatic final int INPUTS = 100the 100 differentiables
STAGESstatic final int STAGES = 8the careful 8 stages
calcint calcVM-local handle (-1 = none)

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createvoid create()No description in source.
handleint handle()No description in source.
validboolean valid()No description in source.
destroyvoid destroy()No description in source.
setvoid set(int index, double value)Set/get one of the 100 differentiables (index 0..99), each in [0,1].
getdouble get(int index)No description in source.
mooddouble mood()Evaluate: the mood scalar in [0,1].
slopedouble slope(int wrtIndex)The slope d(mood)/d(input) along a given differentiable (differentiable calculus: nudging that input moves the mood by this slope).

SLCanvasView #sleela 2.5 (lib/user-interface/SLCanvasView.sleela)

SLCanvasView class extends SLWidget

Defines SLCanvasView — a SleelaUI general animated drawing surface. It owns a double-buffered draw context sized to its bounds and, on every frame, invokes a developer draw routine that paints into that context with the comprehensive SleelaUI Draw API (see SLDrawContext), then presents and blits the result into the window. It is the host for custom visualisations and the substrate the SLThrobber is built on. The constructor bottoms out in the `uiCanvasView` built-in (SleelaUI C ABI slui_canvas_view()). The native toolkit drives the draw routine through a C function pointer each frame. From SLeeLa a draw routine is registered with the VM as a `ui*` draw handler keyed to this view's handle; the VM calls back into SLeeLa with an SLDrawContext bound to the view's per-frame surface, the animation time, and the per-frame delta. Set the refresh rate with setFps. An SLCanvasView IS an SLWidget and is an animated widget. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, int width, int height)Create a canvas view inside `parent` with an initial pixel size.
createInHandlevoid createInHandle(int parentHandle, int width, int height)No description in source.
setFpsvoid setFps(double fps)The target refresh rate (frames per second) the window loop honours while this view is visible (0 = the window's default).
setDrawHandlervoid setDrawHandler(int handlerId)Register the draw routine for this view. `handlerId` is a VM draw-handler ordinal the host has bound to a SLeeLa method; the VM invokes it each frame with an SLDrawContext, the animation time, and the per-frame delta.

SLCard #sleela 2.5 (lib/user-interface/SLCard.sleela)

SLCard class extends SLWidget

Defines SLCard — a SleelaUI raised surface panel: a rounded surface fill with a 1px hairline, padding, and a vertical stack of children. Use it to lift a related cluster of content off the window floor. The constructor bottoms out in the `uiCard` built-in (SleelaUI C ABI slui_card()); children are added by constructing control classes against this card's handle. An SLCard IS an SLWidget container. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent)Create a card inside `parent`.
createInHandlevoid createInHandle(int parentHandle)No description in source.

SLCheckBox #sleela 2.5 (lib/user-interface/SLCheckBox.sleela)

SLCheckBox class extends SLWidget

Defines SLCheckBox — a SleelaUI labelled check box: a rounded square that shows an accent tick when on, with a trailing label. Flipping it (click, or Space/Enter while focused) toggles the boolean state and raises an activate event. The constructor bottoms out in the `uiCheckBox` built-in (SleelaUI C ABI slui_check_box()); the state is read/written through isChecked()/setChecked(). An SLCheckBox IS an SLWidget and is keyboard-focusable. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String label, boolean checked)Create a check box inside `parent` with a label and initial state.
createInHandlevoid createInHandle(int parentHandle, String label, boolean checked)No description in source.
isCheckedboolean isChecked()No description in source.
setCheckedvoid setChecked(boolean checked)No description in source.
changedboolean changed()True if the check box flipped since the last check (latch cleared on read).

SLChip #sleela 2.5 (lib/user-interface/SLChip.sleela)

SLChip class extends SLWidget

Defines SLChip — a SleelaUI chip / tag: a rounded surface pill with a 1px hairline and text, used for filters, tags, or compact selections. The constructor bottoms out in the `uiChip` built-in (SleelaUI C ABI slui_chip()); the text is updated through the inherited setText(). An SLChip IS an SLWidget. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String text)Create a chip inside `parent` with a label.
createInHandlevoid createInHandle(int parentHandle, String text)No description in source.

SLColor #sleela 2.5 (lib/user-interface/SLColor.sleela)

SLColor class

Defines SLColor — a straight-alpha colour value for SleelaUI, packed as a single 0xRRGGBBAA word exactly as the toolkit's C ABI uses (SLUIColor). It provides the rgb()/rgba() builders (mirroring slui_rgb / slui_rgba) and channel accessors, so a SLeeLa program can compose a custom theme palette without touching native code. SLColor is a pure value helper — it holds no VM handle and makes no `ui*` calls; it only packs/unpacks the integer the theme built-ins consume. Family: user-interface.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
packedint packed0xRRGGBBAA

Methods — the actions this unit can perform.

MethodSignatureWhat it does
rgbvoid rgb(int r, int g, int b)Opaque colour from 8-bit channels.
rgbavoid rgba(int r, int g, int b, int a)Colour with explicit alpha. Channels are masked to 0..255.
valueint value()No description in source.
setValuevoid setValue(int word)No description in source.
redint red()No description in source.
greenint green()No description in source.
blueint blue()No description in source.
alphaint alpha()No description in source.

SLComboBox #sleela 2.5 (lib/user-interface/SLComboBox.sleela)

SLComboBox class extends SLWidget

Defines SLComboBox — a SleelaUI drop-down selection control: a rounded surface showing the current option and a chevron. Options are added with addOption(); clicking (or arrow keys while focused) advances the selection and raises an activate event. The constructor bottoms out in the `uiComboBox` built-in (SleelaUI C ABI slui_combo_box()); options are added via `uiComboBoxAdd` and the selected index is read/written through selectedIndex()/setSelectedIndex(). An SLComboBox IS an SLWidget and is keyboard-focusable. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent)Create a combo box inside `parent`; add options afterwards.
createInHandlevoid createInHandle(int parentHandle)No description in source.
addOptionvoid addOption(String option)Append a selectable option.
selectedIndexdouble selectedIndex()The currently-selected option index (0-based), as a value. The VM carries the index as a numeric; callers typically use selected() for the text.
setSelectedIndexvoid setSelectedIndex(int index)No description in source.
selectedString selected()The currently-selected option text.
changedboolean changed()True if the selection changed since the last check (latch cleared on read).

SLDrawContext #sleela 2.5 (lib/user-interface/SLDrawContext.sleela)

SLDrawContext class

Defines SLDrawContext — the SLeeLa binding of the comprehensive SleelaUI Draw API (user-interface/include/sleela_ui_draw.h). It is an owned RGBA pixel surface with an optional back buffer, giving a SLeeLa program the PIXELS: clear/present buffering, pixel-level get/set/blend, a blend mode and layer opacity, a clip stack, and the full primitive set — rects, rounded rects, lines, polylines, circles, ellipses, arcs, triangles, linear/radial gradients, text, and surface-to-surface blits. Every method bottoms out in a `draw*` SLVM built-in that calls the genuine Draw API, which renders with the toolkit's own software rasterizer (identical pixels on every OS). A draw context can be free-standing (an image you render and read back) or handed to you by an SLCanvasView's per-frame draw routine. It is a VM-local handle (-1 = none). Colours are 0xRRGGBBAA words (see SLColor). Family: user-interface. Native VM/UI work crosses the explicit `draw*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
BUFFER_SINGLEstatic final int BUFFER_SINGLE = 0Buffer-mode ordinals (mirror SLUIBufferMode).
BUFFER_DOUBLEstatic final int BUFFER_DOUBLE = 1No description in source.
BLEND_OVERstatic final int BLEND_OVER = 0Blend-mode ordinals (mirror SLUIBlendMode).
BLEND_COPYstatic final int BLEND_COPY = 1No description in source.
BLEND_ADDstatic final int BLEND_ADD = 2No description in source.
BLEND_MULTIPLYstatic final int BLEND_MULTIPLY = 3No description in source.
BLEND_SCREENstatic final int BLEND_SCREEN = 4No description in source.
BLEND_MAXstatic final int BLEND_MAX = 5No description in source.
ORIENT_VERTICALstatic final int ORIENT_VERTICAL = 0Orientation ordinals (mirror SLUIOrientation), for linear gradients.
ORIENT_HORIZONTALstatic final int ORIENT_HORIZONTAL = 1No description in source.
dcint dcVM-local draw-context handle (-1 = none)

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createvoid create(int width, int height, int bufferMode)Create a free-standing context of width x height device pixels.
adoptvoid adopt(int handle)Adopt a context handed in by an SLCanvasView draw routine.
handleint handle()No description in source.
validboolean valid()No description in source.
destroyvoid destroy()No description in source.
resizevoid resize(int width, int height)No description in source.
widthint width()No description in source.
heightint height()No description in source.
setBlendvoid setBlend(int mode)---- state --------------------------------------------------------------
setOpacityvoid setOpacity(double value)No description in source.
clipPushvoid clipPush(int x, int y, int w, int h)No description in source.
clipPopvoid clipPop()No description in source.
clipResetvoid clipReset()No description in source.
clearvoid clear(int color)---- buffering ----------------------------------------------------------
presentvoid present()No description in source.
setPixelvoid setPixel(int x, int y, int color)---- pixel-level control ------------------------------------------------
getPixelint getPixel(int x, int y)No description in source.
blendPixelvoid blendPixel(int x, int y, int color, double coverage)No description in source.
fillRectvoid fillRect(int x, int y, int w, int h, int color)---- primitives ---------------------------------------------------------
fillRoundRectvoid fillRoundRect(int x, int y, int w, int h, double radius, int color)No description in source.
strokeRectvoid strokeRect(int x, int y, int w, int h, double thickness, int color)No description in source.
strokeRoundRectvoid strokeRoundRect(int x, int y, int w, int h, double radius,No description in source.
linevoid line(double x0, double y0, double x1, double y1, double thickness,No description in source.
fillCirclevoid fillCircle(double cx, double cy, double radius, int color)No description in source.
strokeCirclevoid strokeCircle(double cx, double cy, double radius, double thickness,No description in source.
fillEllipsevoid fillEllipse(double cx, double cy, double rx, double ry, int color)No description in source.
arcvoid arc(double cx, double cy, double radius, double startRad,No description in source.
fillTrianglevoid fillTriangle(double x0, double y0, double x1, double y1, double x2,No description in source.
linearGradientvoid linearGradient(int x, int y, int w, int h, int axis, int c0, int c1)No description in source.
radialGradientvoid radialGradient(double cx, double cy, double radius, int inner, int outer)No description in source.
textvoid text(String utf8, int x, int baseline, int color)No description in source.
blitvoid blit(SLDrawContext src, int dx, int dy)No description in source.

SLEntry #sleela 2.5 (lib/user-interface/SLEntry.sleela)

SLEntry class extends SLWidget

Defines SLEntry — a SleelaUI single-line text field: a rounded surface with a hairline (accent when focused), placeholder text when empty, a blinking-free caret, and full UTF-8 editing (insert, backspace, Home/End, left/right). The constructor bottoms out in the `uiEntry` built-in (SleelaUI C ABI slui_entry()); the committed text is read/written through the inherited text()/setText(), and Enter raises an activate event. An SLEntry IS an SLWidget and is keyboard-focusable. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String placeholder)Create an entry inside `parent` with placeholder text (shown when empty).
createInHandlevoid createInHandle(int parentHandle, String placeholder)No description in source.
submittedboolean submitted()True if Enter was pressed since the last check (latch cleared on read).

SLFont #sleela 2.5 (lib/user-interface/SLFont.sleela)

SLFont class

Defines SLFont — a SleelaUI font for Sleela and her UI. A font bundles a face (family, size, weight, slant, letter spacing, line height) with an ordered stack of SLFontEffect entries — drop/inner shadows, a soft glow, a directional light sheen, an EMITTER (text that radiates light into a scene), an outline, a relief emboss/engrave, and a gradient fill — plus a QUALITY level (draft .. ultra) that trades samples for smoothness, so a program can "choose many quality effects". Each method bottoms out in a `font*` SLVM built-in that calls the SleelaUI Font C ABI (sleela_ui_font.h); the look comes from the toolkit's own rasterizer, so a styled string is pixel-identical on every OS. A font is a VM-local handle (-1 = none). Attach it to a text widget with SLWidget.setFont (uiWidgetSetFont) to render that widget's label with the font's effects, or draw directly into an SLDrawContext. Family: user-interface. Native VM/UI work crosses the explicit `font*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
THINstatic final int THIN = 100Weight ordinals (mirror SLUIFontWeight).
LIGHTstatic final int LIGHT = 300No description in source.
REGULARstatic final int REGULAR = 400No description in source.
MEDIUMstatic final int MEDIUM = 500No description in source.
SEMIBOLDstatic final int SEMIBOLD = 600No description in source.
BOLDstatic final int BOLD = 700No description in source.
BLACKstatic final int BLACK = 900No description in source.
UPRIGHTstatic final int UPRIGHT = 0Slant ordinals (mirror SLUIFontSlant).
ITALICstatic final int ITALIC = 1No description in source.
OBLIQUEstatic final int OBLIQUE = 2No description in source.
QUALITY_DRAFTstatic final int QUALITY_DRAFT = 0Quality ordinals (mirror SLUIFontQuality).
QUALITY_LOWstatic final int QUALITY_LOW = 1No description in source.
QUALITY_MEDIUMstatic final int QUALITY_MEDIUM = 2No description in source.
QUALITY_HIGHstatic final int QUALITY_HIGH = 3No description in source.
QUALITY_ULTRAstatic final int QUALITY_ULTRA = 4No description in source.
fontint fontVM-local font handle (-1 = none)

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createvoid create(String family, double sizePt)Create a font with a family ("system"/"mono"/a real face) and point size.
handleint handle()No description in source.
validboolean valid()No description in source.
destroyvoid destroy()No description in source.
setFamilyvoid setFamily(String family)---- face attributes ----------------------------------------------------
setSizevoid setSize(double sizePt)No description in source.
setWeightvoid setWeight(int weight)No description in source.
setSlantvoid setSlant(int slant)No description in source.
setLetterSpacingvoid setLetterSpacing(double px)No description in source.
setLineHeightvoid setLineHeight(double multiple)No description in source.
setQualityvoid setQuality(int quality)No description in source.
sizedouble size()No description in source.
addEffectvoid addEffect(SLFontEffect e)---- effect stack ------------------------------------------------------- Add an effect (applied back-to-front in add order).
clearEffectsvoid clearEffects()No description in source.
effectCountint effectCount()No description in source.
measuredouble measure(String utf8)---- measuring ----------------------------------------------------------
ascentdouble ascent()No description in source.
descentdouble descent()No description in source.
lineHeightdouble lineHeight()No description in source.
drawvoid draw(SLDrawContext dc, String utf8, int x, int baseline, int color)---- drawing ------------------------------------------------------------ Draw into an SLDrawContext with the full effect stack at (x, baseline).
emitIntoint emitInto(SLLightScene scene, int x, int baseline, String utf8)If this font carries an EMITTER effect, register that emission into a light scene for text drawn at (x, baseline). A pure emitter reserves nothing; an anchored one binds as a source. Returns the light index or an error.

SLFontEffect #sleela 2.5 (lib/user-interface/SLFontEffect.sleela)

SLFontEffect class

Defines SLFontEffect — one entry in an SLFont's effect stack. An effect is a drop/inner shadow, a soft glow, a directional light sheen, an EMITTER (the text radiates light into a scene — reserving nothing as an emitter, or binding as a source on an anchor), an outline, a relief emboss/engrave, or a gradient fill. It is a pure value object the host fills with the builder methods and adds to an SLFont; the font applies the stack back-to-front when drawing. Mirrors SLUIFontEffect in the SleelaUI Font C ABI (sleela_ui_font.h). Family: user-interface.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
DROP_SHADOWstatic final int DROP_SHADOW = 0Effect-type ordinals (mirror SLUIFontEffectType).
INNER_SHADOWstatic final int INNER_SHADOW = 1No description in source.
GLOWstatic final int GLOW = 2No description in source.
LIGHTstatic final int LIGHT = 3No description in source.
EMITTERstatic final int EMITTER = 4No description in source.
OUTLINEstatic final int OUTLINE = 5No description in source.
RELIEFstatic final int RELIEF = 6No description in source.
GRADIENT_FILLstatic final int GRADIENT_FILL= 7No description in source.
EMBOSSEDstatic final int EMBOSSED = 0Relief direction (mirror SLUIFontRelief).
ENGRAVEDstatic final int ENGRAVED = 1No description in source.
typeint typeNo description in source.
colorint colorshadow/glow/light/outline/emitter colour (0xRRGGBBAA)
color2int color2gradient bottom colour
blurdouble blurshadow/glow softness radius (px)
sizedouble sizeoutline width / relief depth / emitter radius (px)
intensitydouble intensity0..N strength (glow/light/emitter/relief)
opacitydouble opacity0..1 effect opacity
reliefint reliefEMBOSSED / ENGRAVED for a RELIEF effect
reservedAnchorint reservedAnchorEMITTER: -1 reserve nothing; >=0 bind as a source

Methods — the actions this unit can perform.

MethodSignatureWhat it does
basevoid base(int t)No description in source.
dropShadowvoid dropShadow(double ox, double oy, double softness, int c)An offset, blurred, dark copy behind the glyph.
innerShadowvoid innerShadow(double ox, double oy, double softness, int c)Shadow inside the glyph (a pressed-in look).
glowvoid glow(double radius, double i, int c)A soft coloured halo around the glyph.
lightvoid light(double ux, double uy, double i, int c)A directional sheen lighting the glyph face.
emittervoid emitter(double radius, double i, int c, int anchor)The text radiates light into a scene. anchor < 0 => a pure emitter (reserves nothing); anchor >= 0 => bind as a light SOURCE on that anchor.
outlinevoid outline(double width, int c)A stroked edge of a chosen width + colour.
reliefEffectvoid reliefEffect(int direction, double depth, double i)Emboss/engrave the glyph using lighting normals.
gradientFillvoid gradientFill(int top, int bottom)Fill the glyph with a vertical gradient.

SLFrame #sleela 2.5 (lib/user-interface/SLFrame.sleela)

SLFrame class extends SLWidget

Defines SLFrame — a SleelaUI titled, bordered group container: a 1px hairline rectangle with an optional dim title in the top-left, holding a vertical stack of children. Use it to visually group related controls. The constructor bottoms out in the `uiFrame` built-in (SleelaUI C ABI slui_frame()); children are added by constructing control classes against this frame's handle, and the title is updated through the inherited setText(). An SLFrame IS an SLWidget container. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String title)Create a frame inside `parent` with a title (pass "" for no title).
createInHandlevoid createInHandle(int parentHandle, String title)No description in source.

SLFrameClock #sleela 2.5 (lib/user-interface/SLFrameClock.sleela)

SLFrameClock class

Defines SLFrameClock — the SLeeLa binding of the SleelaUI Draw API's refresh-rate controller. It paces a render loop: a target rate (FPS), a per-frame delta time, an elapsed animation clock, a smoothed measured rate, a sleep hint so the loop idles instead of busy-spinning, and a fixed-timestep accumulator for deterministic field/physics updates regardless of frame rate. Every method bottoms out in a `draw*` SLVM built-in that calls the genuine frame-clock API. Typical loop: SLFrameClock fc = new SLFrameClock(); fc.create(60.0); while (running) { double dt = fc.tick(); update(dt); draw(dc); dc.present(); int ms = fc.sleepHint(); if (ms > 0) host.sleep(ms); } A frame clock is a VM-local handle (-1 = none). Family: user-interface. Native VM/UI work crosses the explicit `draw*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
fcint fcVM-local frame-clock handle (-1 = none)

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createvoid create(double targetFps)Create a frame clock with a target refresh rate (0 = unthrottled).
handleint handle()No description in source.
validboolean valid()No description in source.
destroyvoid destroy()No description in source.
setFpsvoid setFps(double targetFps)No description in source.
fpsdouble fps()No description in source.
tickdouble tick()Advance one frame; returns the delta time in seconds since the last tick.
elapseddouble elapsed()Seconds since the clock was created (monotonic animation time).
measuredFpsdouble measuredFps()The smoothed frames-per-second actually being achieved.
sleepHintint sleepHint()Milliseconds the caller should idle to hit the target rate (0 if behind).
fixedStepboolean fixedStep(double step)Fixed-timestep drain: after tick(), call repeatedly, running one fixed `step`-second update each time it returns true, until it returns false.

SLGalleryDemo #sleela 2.5 (lib/user-interface/SLGalleryDemo.sleela)

SLGalleryDemo class

Defines SLGalleryDemo — a worked, runnable example that builds a complete Slick Black window from pure SLeeLa source using the /lib/user-interface classes. It opens an application, raises a window with a header bar and the full control set (label, entry, suggested/destructive buttons, toggle, slider, separator, a disabled button, a status line), and runs the toolkit's event loop. It is the SLeeLa-source twin of the native C gallery in /user-interface/examples/gallery.c, proving the toolkit is fully usable from the language itself. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
uiSLUserInterface uiNo description in source.
winSLWindow winNo description in source.
saveSLButton saveNo description in source.
darkSLToggle darkNo description in source.
opacitySLSlider opacityNo description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
runint run()Build the whole interface and return the application exit code.

SLGrid #sleela 2.5 (lib/user-interface/SLGrid.sleela)

SLGrid class extends SLWidget

Defines SLGrid — a SleelaUI fixed row/column grid container. Children fill cells in row-major order across a fixed number of columns; the grid sizes every cell to the largest child and spreads them to fill the available width. Use it for form layouts and tiles. The constructor bottoms out in the `uiGrid` built-in (SleelaUI C ABI slui_grid()); children are added by constructing control classes against this grid's handle. An SLGrid IS an SLWidget container. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, int columns, int spacing)Create a grid inside `parent` with a column count and a spacing (px) applied between both rows and columns.
createInHandlevoid createInHandle(int parentHandle, int columns, int spacing)No description in source.

SLGuiApp #sleela 2.5 (lib/user-interface/SLGuiApp.sleela)

SLGuiApp class

Defines SLGuiApp — the top-level support structure that ties the whole /lib/gui dynamic stack together into one object: it opens a SleelaUI application and window (via /lib/user-interface), owns the SLeeLa DOM (SLGuiDom), the reconciler (SLGuiMount) that projects the DOM onto widgets, the host adapter (SLGuiHostAdapter) that raises widget activations back as events, and an optional script engine (SLGuiScript). Its run loop pumps the toolkit event loop, polls widget activations into the event bus, re-mounts any newly-created nodes, and reconciles dirty nodes each turn. This is the "basic support structure" a program (or the IDE) builds on: construct the DOM declaratively or by script, bind callbacks, and call run(). Family: user-interface. SLeeLa owns the DOM, dispatch, and script execution; SleelaUI owns presentation; this object is the wiring between them.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
uiSLUserInterface uiNo description in source.
windowSLWindow windowNo description in source.
domSLGuiDom domNo description in source.
mountSLGuiMount mountNo description in source.
hostSLGuiHostAdapter hostNo description in source.
scriptSLGuiScript scriptNo description in source.
readyint readyNo description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
bootboolean boot(String appId, String title, int width, int height)Open the application + window and stand up the DOM/mount/host wiring. Returns true when the toolkit came up (false on a headless host).
isReadyboolean isReady()No description in source.
documentSLGuiDom document()No description in source.
scriptingSLGuiScript scripting()No description in source.
hostWindowSLWindow hostWindow()No description in source.
addSLGuiNode add(String parentId, String tag, String id)Convenience: append an element to a parent in the DOM (then mount+show on the next loop turn, or immediately via refresh()).
onClickSLGuiHandler onClick(String id, String operation)Bind a click callback (DHTML onClick) by node id.
runScriptint runScript()Run a UI script against the DOM (build + bind + fire), then refresh.
runint run()Mount everything, show the window, then run the toolkit event loop: pump -> poll activations -> mount new nodes -> reconcile. Returns the process-style exit code.
refreshvoid refresh()A single synchronous refresh (mount new + reconcile) without the loop, for building a UI up front or driving it from a test/host step.
stepint step(boolean block)Pump one turn (pump + poll + refresh); returns events raised this turn.
quitvoid quit(int code)No description in source.
shutdownvoid shutdown()No description in source.

SLGuiDom #sleela 2.5 (lib/user-interface/SLGuiDom.sleela)

SLGuiDom class

Defines SLGuiDom — the DHTML-style document model for /lib/gui: a flat registry of SLGuiNode elements forming a tree, plus the manipulation API a browser DOM exposes — createElement, getElementById, appendChild, removeChild, setText/setAttribute/setStyle on an id, show/hide, and a simple getElementsByTag / querySelector-by-attribute lookup. It owns an SLGuiEventBus so handlers bind to node ids (onClick, onInput, on(type,...), addEventListener) and raised events route to SLeeLa operations. The DOM is the single SLeeLa-owned source of truth; a host walks the dirty nodes and mirrors them onto real SleelaUI widgets. Family: user-interface. SLeeLa owns the document and dispatch; the host mounts and paints it.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
MAX_NODESstatic final int MAX_NODES = 65536No description in source.
nodesSLGuiNode[] nodesNo description in source.
countint countNo description in source.
rootIdString rootIdNo description in source.
busSLGuiEventBus busNo description in source.
typesSLGuiEventType typesname<->ordinal helper
idSeqint idSeqauto-id counter for createElement without an id

Methods — the actions this unit can perform.

MethodSignatureWhat it does
initvoid init()No description in source.
eventsSLGuiEventBus events()No description in source.
sizeint size()No description in source.
createElementSLGuiNode createElement(String tag, String id)createElement(tag, id): id "" generates a stable auto id ("n<seq>").
createRootSLGuiNode createRoot(String tag, String id)The document root (the window element). Created once.
rootSLGuiNode root()No description in source.
getElementByIdSLGuiNode getElementById(String id)No description in source.
indexOfIdint indexOfId(String id)No description in source.
appendChildboolean appendChild(String parentId, String childId)appendChild(parentId, childId): link child under parent in both directions.
appendElementSLGuiNode appendElement(String parentId, String tag, String id)Convenience: create a child element already appended to a parent.
removeChildboolean removeChild(String childId)removeChild: detach from parent, remove its handlers, and drop the node (and recursively its subtree).
setTextvoid setText(String id, String text)No description in source.
setAttributevoid setAttribute(String id, String name, String value)No description in source.
setStylevoid setStyle(String id, String prop, String value)No description in source.
showvoid show(String id)No description in source.
hidevoid hide(String id)No description in source.
setEnabledvoid setEnabled(String id, boolean on)No description in source.
getElementsByTagint getElementsByTag(String tag, String[] out, int cap)Fill `out` with the ids of every node with the given tag; returns the count.
querySelectorByAttrString querySelectorByAttr(String name, String value)Return the first node id whose attribute `name` equals `value` (or null).
addEventListenerSLGuiHandler addEventListener(String id, String eventName, String operation)No description in source.
removeEventListenerboolean removeEventListener(String id, String eventName, String operation)No description in source.
onClickSLGuiHandler onClick(String id, String operation)Shorthands mirroring onclick=/oninput= style bindings.
onInputSLGuiHandler onInput(String id, String operation)No description in source.
onChangeSLGuiHandler onChange(String id, String operation)No description in source.
onKeyDownSLGuiHandler onKeyDown(String id, String operation)No description in source.
onSubmitSLGuiHandler onSubmit(String id, String operation)No description in source.
dispatchEventint dispatchEvent(SLGuiEvent event)The host raises an activation on a node; dispatch it through the bus. Returns how many handlers fired.
fireint fire(int eventType, String targetId, String value)No description in source.
dirtyCountint dirtyCount()The number of nodes needing a host re-sync (dirty), for the mount walk.
nodeAtSLGuiNode nodeAt(int i)No description in source.
autoIdString autoId()No description in source.
removeSubtreevoid removeSubtree(String id)No description in source.
removeNodevoid removeNode(String id)No description in source.

SLGuiEvent #sleela 2.5 (lib/user-interface/SLGuiEvent.sleela)

SLGuiEvent class

Defines SLGuiEvent — one dispatched GUI event, the DHTML-style event object a handler receives. It names the event type (an SLGuiEventType ordinal), the target node id it was raised on, and the payload the kind carries: a string value (entry text / changed value), a key name (for key events), pointer coordinates (for pointer events), and a toggle state. It also carries the two propagation controls a handler can set — preventDefault() and stopPropagation() — exactly like a browser event, so SLeeLa handlers can cancel the host's default action or halt bubbling. Family: user-interface. The host raises the activation; SLeeLa reads this event and decides what it means.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
typeint typeSLGuiEventType ordinal
targetIdString targetIdthe node id the event was raised on
valueString valuestring payload (entry text, changed value, custom data)
keyString keykey name for KEYDOWN/KEYUP (e.g. "Enter", "a")
xint xpointer x within the target (pointer events)
yint ypointer y within the target (pointer events)
toggleStateint toggleState1/0 for TOGGLE events
defaultPreventedint defaultPrevented1 once preventDefault() is called
propagationStoppedint propagationStopped1 once stopPropagation() is called
timestampint timestamphost-supplied monotonic tick (0 if unknown)

Methods — the actions this unit can perform.

MethodSignatureWhat it does
configurevoid configure(int eventType, String target)No description in source.
getTypeint getType()No description in source.
targetString target()No description in source.
setValuevoid setValue(String v)Payload setters (the host fills in what the kind carries).
getValueString getValue()No description in source.
setKeyvoid setKey(String k)No description in source.
getKeyString getKey()No description in source.
setPointervoid setPointer(int px, int py)No description in source.
pointerXint pointerX()No description in source.
pointerYint pointerY()No description in source.
setTogglevoid setToggle(int on)No description in source.
toggledOnboolean toggledOn()No description in source.
setTimestampvoid setTimestamp(int t)No description in source.
whenint when()No description in source.
preventDefaultvoid preventDefault()DHTML-style propagation controls.
isDefaultPreventedboolean isDefaultPrevented()No description in source.
stopPropagationvoid stopPropagation()No description in source.
isPropagationStoppedboolean isPropagationStopped()No description in source.

SLGuiEventBus #sleela 2.5 (lib/user-interface/SLGuiEventBus.sleela)

SLGuiEventBus class

Defines SLGuiEventBus — the event dispatcher and listener table for the /lib/gui event layer. It is the engine behind addEventListener / removeEventListener and the onClick/onInput shorthands: handlers register against a (type, target) pair, and dispatch(event) delivers a raised SLGuiEvent to every matching SLGuiHandler, honouring the DHTML-style phase order (capture handlers first, then target/bubble), stopPropagation() to halt delivery, and once handlers that auto-remove after firing. The bus is the SLeeLa-owned meaning layer: the host raises typed activations, the bus routes them to the bound operations. Family: user-interface. SLeeLa owns dispatch and the meaning of events; the host only raises them.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
MAX_HANDLERSstatic final int MAX_HANDLERS = 8192No description in source.
handlersSLGuiHandler[] handlersNo description in source.
countint countNo description in source.
lastDeliveredint lastDeliveredhow many handlers the last dispatch fired

Methods — the actions this unit can perform.

MethodSignatureWhat it does
initvoid init()No description in source.
sizeint size()No description in source.
addListenerSLGuiHandler addListener(String targetId, int eventType, String operation)addEventListener(target, type, operation): register a handler and return it.
addListenerExSLGuiHandler addListenerEx(String targetId, int eventType, String operation,addEventListener with options (once / capture).
removeListenerboolean removeListener(String targetId, int eventType, String operation)removeEventListener: drop the first handler matching (target, type, op).
removeTargetint removeTarget(String targetId)Remove every handler bound to a target (used when a node is destroyed).
dispatchint dispatch(SLGuiEvent event)Dispatch a raised event: capture-phase handlers first, then bubble-phase, stopping early if a handler calls stopPropagation(). once handlers are removed after they fire. Returns the number of handlers that fired.
deliverPhasevoid deliverPhase(SLGuiEvent event, boolean capturePhase)No description in source.
raiseint raise(int eventType, String targetId, String value)Convenience: build and dispatch a simple typed event with a string value.
pollboolean poll(SLGuiHandler handler)Poll a handler's latch (for hosts that poll rather than get called back).
deliveredLastint deliveredLast()No description in source.
removeAtvoid removeAt(int index)No description in source.
sweepOncevoid sweepOnce()Remove handlers flagged once that have fired at least once.

SLGuiEventType #sleela 2.5 (lib/user-interface/SLGuiEventType.sleela)

SLGuiEventType class

Defines SLGuiEventType — the catalogue of GUI event kinds the /lib/gui event layer understands. These are the SLeeLa-facing names a handler binds to (the DHTML-style "click", "input", "change", "keydown", ...). The host raises one of these on a target; SLeeLa decides what it means. Each kind has a stable ordinal (used by the dispatch tables) and a canonical lowercase name (the string an onX binding or addEventListener uses), mirroring the activation model already in SLGuiAction. Family: user-interface. Java/native raise typed activations; SLeeLa owns their meaning.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
CLICKstatic final int CLICK = 0Ordinals (stable; used as table indices). a primary activation (click / Enter / Space)
DBLCLICKstatic final int DBLCLICK = 1a double activation
INPUTstatic final int INPUT = 2live text input (per keystroke)
CHANGEstatic final int CHANGE = 3a committed value change (blur/Enter)
FOCUSstatic final int FOCUS = 4the target gained focus
BLURstatic final int BLUR = 5the target lost focus
KEYDOWNstatic final int KEYDOWN = 6a key went down while focused
KEYUPstatic final int KEYUP = 7a key came up while focused
POINTERDOWNstatic final int POINTERDOWN= 8a pointer press began on the target
POINTERUPstatic final int POINTERUP = 9a pointer press ended on the target
POINTERMOVEstatic final int POINTERMOVE=10the pointer moved over the target
SCROLLstatic final int SCROLL =11the target scrolled
SUBMITstatic final int SUBMIT =12a form-like submit (Enter in an entry)
TOGGLEstatic final int TOGGLE =13a toggle/checkbox flipped
CUSTOMstatic final int CUSTOM =14a host- or script-defined event
COUNTstatic final int COUNT =15number of defined event kinds

Methods — the actions this unit can perform.

MethodSignatureWhat it does
nameOfString nameOf(int type)The canonical lowercase name for an ordinal (the addEventListener string).
typeOfint typeOf(String name)The ordinal for a canonical name (-1 when the name is not recognised).
validboolean valid(int type)No description in source.

SLGuiHandler #sleela 2.5 (lib/user-interface/SLGuiHandler.sleela)

SLGuiHandler class

Defines SLGuiHandler — one registered event callback: the triple (event type, target node id, SLeeLa operation). It is the /lib/gui generalisation of SLGuiAction from a single click to any SLGuiEventType, and it is what addEventListener(target, type, operation) and the onClick/onInput shorthands create. When the dispatcher matches a raised SLGuiEvent to this handler it invokes the bound operation; the handler latches each fire so a host that polls (rather than calls back) still observes each activation exactly once, the same take-the-latch discipline as SLGuiAction. Family: user-interface. The host raises activations; this binding maps them to a SLeeLa operation whose meaning SLeeLa owns.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
typeint typeSLGuiEventType ordinal this handler listens for
targetIdString targetIdnode id it is bound to ("*" matches any target)
operationString operationthe SLeeLa operation invoked when it fires
onceint once1 = auto-remove after the first fire
captureint capture1 = fire during capture phase, 0 = bubble phase
enabledint enabled1 while active
pendingint pendingactivation latch (set on fire, cleared on take)
firedint firedtotal times fired
lastValueString lastValuethe value carried by the most recent matching event

Methods — the actions this unit can perform.

MethodSignatureWhat it does
configurevoid configure(int eventType, String target, String op)No description in source.
getTypeint getType()No description in source.
getTargetString getTarget()No description in source.
getOperationString getOperation()No description in source.
boundboolean bound()No description in source.
setOncevoid setOnce(boolean on)No description in source.
isOnceboolean isOnce()No description in source.
setCapturevoid setCapture(boolean on)No description in source.
isCaptureboolean isCapture()No description in source.
setEnabledvoid setEnabled(boolean on)No description in source.
isEnabledboolean isEnabled()No description in source.
matchesboolean matches(SLGuiEvent event)Does this handler match the given event? "*" target is a wildcard.
firevoid fire(SLGuiEvent event)Fire against a matching event: record it and raise the latch. The dispatcher calls this; a host that polls then reads it with take().
takeboolean take()Take-the-latch read: true once per fire, then cleared.
activationsint activations()No description in source.
valueString value()No description in source.

SLGuiHostAdapter #sleela 2.5 (lib/user-interface/SLGuiHostAdapter.sleela)

SLGuiHostAdapter class

Defines SLGuiHostAdapter — the toolkit->SLeeLa half of the loop. Where SLGuiMount pushes DOM state onto widgets, the host adapter reads the widgets back: once per frame it polls each mounted interactive node's widget activation latch (uiWidgetTakeActivated, the same latch SLButton and SLEntry expose) and, when a widget fired, builds the matching SLGuiEvent (CLICK for a button, SUBMIT for an entry, TOGGLE for a toggle — carrying the widget's current text/toggle state as the event value) and dispatches it through the DOM's SLGuiEventBus so the bound onClick/onSubmit/onToggle handlers fire. This is what turns a real user interaction into a SLeeLa event; the DOM stays authoritative for what the event means. Family: user-interface. The adapter crosses the `ui*` SLVM bridge inbound; dispatch and meaning stay SLeeLa-owned.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
domSLGuiDom domNo description in source.
mountSLGuiMount mountNo description in source.
factorySLGuiWidgetFactory factoryNo description in source.
tickint tickmonotonic frame counter stamped onto events
raisedLastint raisedLastevents raised on the last poll pass

Methods — the actions this unit can perform.

MethodSignatureWhat it does
initvoid init(SLGuiDom document, SLGuiMount mountEngine)No description in source.
pollint poll()Poll every mounted interactive node once; raise an SLGuiEvent for each that fired since the last poll. Returns the number of events dispatched.
raiseForvoid raiseFor(SLGuiNode node, int widgetHandle)Build and dispatch the event a fired widget implies.
raiseInputint raiseInput(String nodeId, String text)Also feed a synthetic input event (per-keystroke) for an entry, used by a host that wants live INPUT handlers in addition to the committed SUBMIT.
raisedCountint raisedCount()No description in source.
frameint frame()No description in source.

SLGuiMount #sleela 2.5 (lib/user-interface/SLGuiMount.sleela)

SLGuiMount class

Defines SLGuiMount — the reconciler that reflects the SLeeLa-owned DOM (SLGuiDom / SLGuiNode) onto real SleelaUI widgets. It mounts the tree depth-first (a parent is constructed before its children so each child has a real parent handle), records an id->widget-handle map, and on each pass applies every dirty node's state to its widget through the `ui*` built-ins: text (uiWidgetSetText), visibility (uiWidgetVisible), sensitivity (uiWidgetSensitive), and the style-derived accents (suggested/destructive) and minimum size. This is the one-way SLeeLa->toolkit half of the loop (SLGuiHostAdapter is the toolkit->SLeeLa half). The DOM stays the single source of truth; the widgets are its projection. Family: user-interface. The reconciler crosses the `ui*` SLVM bridge; SLeeLa owns the document it mirrors.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
MAX_NODESstatic final int MAX_NODES = 65536No description in source.
domSLGuiDom domNo description in source.
factorySLGuiWidgetFactory factoryNo description in source.
idsString[] idsid -> widget handle map (parallel arrays).
handlesint[] handlesNo description in source.
mapCountint mapCountNo description in source.
rootHandleint rootHandlethe host-supplied root container the window gives us
mountedint mountedtotal nodes mounted so far
appliedint applieddirty nodes applied on the last reconcile pass

Methods — the actions this unit can perform.

MethodSignatureWhat it does
initvoid init(SLGuiDom document, int windowRootHandle)No description in source.
handleOfint handleOf(String id)No description in source.
recordvoid record(String id, int handle)No description in source.
indexOfint indexOf(String id)No description in source.
isMountedboolean isMounted(String id)No description in source.
mountAllvoid mountAll()Mount the whole document under the window root, depth-first.
mountChildrenvoid mountChildren(SLGuiNode parent)Recursively construct and mount every child of `parent`.
mountNewvoid mountNew()Mount any nodes added since the last pass (nodes the DOM grew via script or SLeeLa after the initial mountAll).
reconcileint reconcile()Push every dirty node's state onto its widget, then clear the dirty flag. Returns how many nodes were applied this pass.
applyvoid apply(SLGuiNode node)Apply one node's state to its live widget via the `ui*` built-ins.
mountedCountint mountedCount()No description in source.
appliedLastint appliedLast()No description in source.
labelForString labelFor(SLGuiNode node)The construction label for a node: its text, or its "placeholder" attr for entries, or empty.
intAttrint intAttr(String s)Parse a non-negative integer from a decimal string ("" / null -> 0).
digitint digit(String ch)No description in source.

SLGuiNode #sleela 2.5 (lib/user-interface/SLGuiNode.sleela)

SLGuiNode class

Defines SLGuiNode — a DHTML-style element node in the /lib/gui document model. Like a DOM element it has a tag (e.g. "window", "box", "button", "label", "entry"), a unique id, text content, a parent id, an ordered list of child ids, a flat attribute map, a flat style map, and a visibility/enabled state. SLeeLa code (or a script) manipulates the tree through these — setAttribute, setStyle, show/hide, enable/disable, setText — and the host reflects the node onto a real SleelaUI widget. A node carries an optional widget handle so a change can be pushed to the live control, but the node itself is the SLeeLa-owned source of truth. Family: user-interface. The DOM is SLeeLa-owned; the host mirrors it onto widgets.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
MAX_CHILDRENstatic final int MAX_CHILDREN = 4096No description in source.
MAX_PAIRSstatic final int MAX_PAIRS = 64attributes / style entries per node
idString idNo description in source.
tagString tagNo description in source.
textContentString textContentNo description in source.
parentIdString parentId"" for the root
childIdsString[] childIdsNo description in source.
childCountint childCountNo description in source.
attrNamesString[] attrNamesAttribute map (name -> value).
attrValuesString[] attrValuesNo description in source.
attrCountint attrCountNo description in source.
stylePropsString[] stylePropsStyle map (property -> value), the DHTML inline-style equivalent.
styleValuesString[] styleValuesNo description in source.
styleCountint styleCountNo description in source.
visibleint visible1 = shown
enabledint enabled1 = sensitive
widgetint widgetlive SleelaUI widget handle (-1 = not mounted)
dirtyint dirty1 when the host must re-sync this node

Methods — the actions this unit can perform.

MethodSignatureWhat it does
configurevoid configure(String nodeId, String nodeTag, String parent)No description in source.
getIdString getId()No description in source.
getTagString getTag()No description in source.
getParentString getParent()No description in source.
setParentvoid setParent(String p)No description in source.
appendChildboolean appendChild(String childId)---- children -----------------------------------------------------------
removeChildboolean removeChild(String childId)No description in source.
childrenint children()No description in source.
childAtString childAt(int i)No description in source.
setTextvoid setText(String t)---- text ---------------------------------------------------------------
textString text()No description in source.
setAttributevoid setAttribute(String name, String value)---- attributes ---------------------------------------------------------
getAttributeString getAttribute(String name)No description in source.
hasAttributeboolean hasAttribute(String name)No description in source.
attrIndexint attrIndex(String name)No description in source.
setStylevoid setStyle(String prop, String value)---- style (DHTML inline style) -----------------------------------------
getStyleString getStyle(String prop)No description in source.
styleIndexint styleIndex(String prop)No description in source.
styleEntriesint styleEntries()No description in source.
showvoid show()---- visibility / enabled -----------------------------------------------
hidevoid hide()No description in source.
isVisibleboolean isVisible()No description in source.
setEnabledvoid setEnabled(boolean on)No description in source.
isEnabledboolean isEnabled()No description in source.
mountvoid mount(int widgetHandle)---- host mount ---------------------------------------------------------
widgetHandleint widgetHandle()No description in source.
mountedboolean mounted()No description in source.
isDirtyboolean isDirty()No description in source.
clearDirtyvoid clearDirty()No description in source.

SLGuiScript #sleela 2.5 (lib/user-interface/SLGuiScript.sleela)

SLGuiScript class

Defines SLGuiScript — the scripting engine for /lib/gui. It holds an ordered list of SLGuiScriptCommands and runs them against an SLGuiDom (and, for the `call` verb, across the native boundary via SLGuiBridge). This is the "support for scripting" layer: a UI can be described and driven by a command list rather than hand-written SLeeLa, which is what makes DHTML-style authoring and tooling (serialising a UI, replaying interactions, data-driven screens) possible. The engine is deliberately NOT a general interpreter — it is a bounded, auditable verb list that only touches the SLeeLa-owned DOM/event bus and the documented operation bridge, so a script can never do more than the DOM API already allows. Family: user-interface. SLeeLa owns execution; scripts express UI intent declaratively.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
MAX_COMMANDSstatic final int MAX_COMMANDS = 65536No description in source.
commandsSLGuiScriptCommand[] commandsNo description in source.
countint countNo description in source.
domSLGuiDom domthe document the script manipulates
bridgeSLGuiBridge bridgenative boundary for the `call` verb (may be null)
typesSLGuiEventType typesevent-name -> ordinal
pcint pcprogram counter of the last executed command
executedint executedtotal commands executed
lastErrorString lastErrorNo description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
initvoid init(SLGuiDom document)No description in source.
attachBridgevoid attachBridge(SLGuiBridge b)Attach a created native bridge so `call` can cross to a SLeeLa operation.
sizeint size()No description in source.
addSLGuiScriptCommand add(int verb, String a, String b, String c, String d)No description in source.
createvoid create(String tag, String id, String parentId)Typed builders (the common verbs) for readable script assembly.
appendvoid append(String parentId, String childId)No description in source.
textvoid text(String id, String value)No description in source.
attrvoid attr(String id, String name, String value)No description in source.
stylevoid style(String id, String prop, String value)No description in source.
showvoid show(String id)No description in source.
hidevoid hide(String id)No description in source.
enablevoid enable(String id, boolean on)No description in source.
onvoid on(String id, String eventName, String op)No description in source.
firevoid fire(String id, String eventName, String value)No description in source.
callvoid call(String operation, String arguments)No description in source.
removevoid remove(String id)No description in source.
runint run()Run the whole script top-down against the DOM. Returns the number of commands that executed successfully; stops and records lastError on the first command that fails.
stepboolean step(SLGuiScriptCommand cmd)Execute one command against the DOM / bridge. Returns false on failure.
programCounterint programCounter()No description in source.
executedCountint executedCount()No description in source.
errorString error()No description in source.
okboolean ok()No description in source.

SLGuiScriptCommand #sleela 2.5 (lib/user-interface/SLGuiScriptCommand.sleela)

SLGuiScriptCommand class

Defines SLGuiScriptCommand — one instruction of a /lib/gui UI script. The scripting support is a small, safe, declarative command list (not an arbitrary interpreter): each command is a verb plus up to four string operands. The verbs mirror the DOM/event API so a script can build and drive an interface without native code — create, append, text, attr, style, show, hide, enable, on (bind a handler), fire (raise an event), and call (cross the native bridge to a SLeeLa operation). An ordinal verb keeps dispatch cheap; the operands are interpreted per verb by SLGuiScript. Family: user-interface. Scripts describe UI intent; SLeeLa (via SLGuiScript) executes it against the SLeeLa-owned DOM and event bus.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
CREATEstatic final int CREATE = 0Verb ordinals. create <tag> <id> [parentId]
APPENDstatic final int APPEND = 1append <parentId> <childId>
TEXTstatic final int TEXT = 2text <id> <value>
ATTRstatic final int ATTR = 3attr <id> <name> <value>
STYLEstatic final int STYLE = 4style <id> <prop> <value>
SHOWstatic final int SHOW = 5show <id>
HIDEstatic final int HIDE = 6hide <id>
ENABLEstatic final int ENABLE = 7enable <id> <"1"|"0">
ONstatic final int ON = 8on <id> <eventName> <operation>
FIREstatic final int FIRE = 9fire <id> <eventName> [value]
CALLstatic final int CALL =10call <operation> [arguments]
REMOVEstatic final int REMOVE =11remove <id>
NOPstatic final int NOP =12no-op / comment
verbint verbNo description in source.
aString aoperand 1
bString boperand 2
cString coperand 3
dString doperand 4

Methods — the actions this unit can perform.

MethodSignatureWhat it does
configurevoid configure(int v, String o1, String o2, String o3, String o4)No description in source.
getVerbint getVerb()No description in source.
op1String op1()No description in source.
op2String op2()No description in source.
op3String op3()No description in source.
op4String op4()No description in source.
verbOfint verbOf(String word)Map a verb keyword to its ordinal (-1 when unknown).
validboolean valid()No description in source.

SLGuiWidgetFactory #sleela 2.5 (lib/user-interface/SLGuiWidgetFactory.sleela)

SLGuiWidgetFactory class

Defines SLGuiWidgetFactory — the single place that knows how a DOM tag maps to a real SleelaUI widget. Given a node's tag and a parent widget handle it calls the matching `ui*` built-in (uiBox / uiButton / uiLabel / uiEntry / uiToggle / uiHeaderBar / uiStatusBar / ...) and returns the new widget handle, so the reconciler (SLGuiMount) never hard-codes toolkit knowledge. Tags mirror the SleelaUI vocabulary; an unknown tag falls back to a vertical box so an unrecognised element still has a container to hold children. This is the DOM->toolkit construction seam. Family: user-interface. The factory crosses the `ui*` SLVM bridge to the real toolkit; SLeeLa still owns the node that the widget mirrors.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
ORIENT_VERTICALstatic final int ORIENT_VERTICAL = 0Orientation ordinals (mirror SLUIOrientation / SLWidget).
ORIENT_HORIZONTALstatic final int ORIENT_HORIZONTAL = 1No description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
constructint construct(int parentHandle, String tag, String label)Construct the widget for `node` inside `parentHandle`. Returns the new widget handle, or -1 when it could not be created. `label` is the node's initial text/placeholder (empty string when it has none).
interactiveboolean interactive(String tag)Is this tag an interactive control the host should poll for activations?
activationEventint activationEvent(String tag)Which SLGuiEventType an activation on this tag should raise. Buttons -> CLICK; entries -> SUBMIT (Enter); toggles -> TOGGLE.
isContainerboolean isContainer(String tag)No description in source.

SLHeaderBar #sleela 2.5 (lib/user-interface/SLHeaderBar.sleela)

SLHeaderBar class extends SLWidget

Defines SLHeaderBar — a SleelaUI title-bar strip: a horizontal box that also paints the chrome fill and a 1px bottom hairline, the quiet frame edge of a window. It is where a brand label, a spacer, and action buttons (e.g. a settings gear) typically live. The constructor bottoms out in the `uiHeaderBar` built-in, which calls the SleelaUI C ABI slui_header_bar(). An SLHeaderBar IS an SLWidget and behaves like a horizontal SLBox for the purpose of adding children. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent)Create a header bar inside `parent` (normally the window root).
createInHandlevoid createInHandle(int parentHandle)No description in source.

SLHeading #sleela 2.5 (lib/user-interface/SLHeading.sleela)

SLHeading class extends SLWidget

Defines SLHeading — a SleelaUI title label drawn at a larger point size than body text, used for section and page headings. The constructor bottoms out in the `uiHeading` built-in (SleelaUI C ABI slui_heading()); the text is updated through the inherited setText(). An SLHeading IS an SLWidget but is non-interactive. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String text, int sizePt)Create a heading inside `parent` with text at a point size (e.g. 16, 20).
createInHandlevoid createInHandle(int parentHandle, String text, int sizePt)No description in source.

SLIcon #sleela 2.5 (lib/user-interface/SLIcon.sleela)

SLIcon class

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
pathValueString pathValueNo description in source.
symbolValueString symbolValueNo description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
configurevoid configure(String assetPath, String symbolName)No description in source.
assetPathString assetPath()No description in source.
symbolNameString symbolName()No description in source.

SLImage #sleela 2.5 (lib/user-interface/SLImage.sleela)

SLImage class extends SLWidget

Defines SLImage — a SleelaUI image/icon tile: a rounded surface of a fixed size with a centred glyph, used as a picture or icon placeholder in a layout. The constructor bottoms out in the `uiImage` built-in (SleelaUI C ABI slui_image()); the glyph is updated through the inherited setText(). An SLImage IS an SLWidget but is non-interactive. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String glyph, int width, int height)Create an image tile inside `parent` with a centred glyph and a size.
createInHandlevoid createInHandle(int parentHandle, String glyph, int width, int height)No description in source.

SLInfoBar #sleela 2.5 (lib/user-interface/SLInfoBar.sleela)

SLInfoBar class extends SLWidget

Defines SLInfoBar — a SleelaUI inline notice bar: a tinted, rounded surface strip with a left severity bar and a message, used for non-modal feedback (info, warning, error). The constructor bottoms out in the `uiInfoBar` built-in (SleelaUI C ABI slui_info_bar()); the message is updated through the inherited setText(). An SLInfoBar IS an SLWidget but is non-interactive. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
INFOstatic final int INFO = 0Severity ordinals (mirror InfoBar::Severity in the toolkit).
WARNINGstatic final int WARNING = 1No description in source.
ERRORstatic final int ERROR = 2No description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String text, int severity)Create an info bar inside `parent` with a message and a severity.
createInHandlevoid createInHandle(int parentHandle, String text, int severity)No description in source.
infovoid info(SLWidget parent, String text)No description in source.
warningvoid warning(SLWidget parent, String text)No description in source.
errorvoid error(SLWidget parent, String text)No description in source.

SLLabel #sleela 2.5 (lib/user-interface/SLLabel.sleela)

SLLabel class extends SLWidget

Defines SLLabel — a SleelaUI text label: a non-interactive run of text drawn in the theme's primary (or dim, when insensitive) colour. The constructor bottoms out in the `uiLabel` built-in, which calls the SleelaUI C ABI slui_label(); the text is updated through the inherited setText(). An SLLabel IS an SLWidget, so it carries margin and alignment; set its horizontal alignment to START/CENTER/END to place the text within its cell. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String text)Create a label inside `parent` with initial text.
createInHandlevoid createInHandle(int parentHandle, String text)No description in source.

SLLayout #sleela 2.5 (lib/user-interface/SLLayout.sleela)

SLLayout class

Defines SLLayout — a flow/layout manager for the SleelaUI. It treats a UI as an ORTHOGONAL CONFLATION of unit parts (what each item measures) and organizations (how items are grouped and flowed): items have NAMES, groups have NAMES, and you adjust a single named item, a whole named group, or an N-ARY selection (any subset of a group of some size). Several flow solutions arrange a group: STACK, WRAP, GRID, DOCK, and CENTRAL (weight/mass packing). Placement is Named for the ergonomics of publics — MEDIUM implies CENTER and CENTRAL implies weight/mass — and named ergonomic presets tune a group for a common public use. Each method bottoms out in a `layout*` SLVM built-in calling the C ABI (sleela_ui_layout.h). A layout is a VM-local handle (-1 = none). Sizes are SLMeasure values (US/metric/px). After adjustment call arrange(), then read item rects. Family: user-interface. Native VM/UI work crosses the explicit `layout*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
FLOW_STACKstatic final int FLOW_STACK = 0Flow ordinals (mirror SLUIFlowKind) — several layout solutions. one row/column (the box model)
FLOW_WRAPstatic final int FLOW_WRAP = 1wraps to new lines when full
FLOW_GRIDstatic final int FLOW_GRID = 2fixed-column grid
FLOW_DOCKstatic final int FLOW_DOCK = 3edges dock, centre fills
FLOW_CENTRALstatic final int FLOW_CENTRAL = 4weight/mass packing
AXIS_HORIZONTALstatic final int AXIS_HORIZONTAL = 0Axis ordinals (mirror SLUIAxis).
AXIS_VERTICALstatic final int AXIS_VERTICAL = 1No description in source.
STARTstatic final int START = 0Placement ordinals (mirror SLUIPlacement). The ergonomics of publics, Named: MEDIUM is center; CENTRAL is weight/mass.
MEDIUMstatic final int MEDIUM = 1implies CENTER
ENDstatic final int END = 2No description in source.
FILLstatic final int FILL = 3No description in source.
CENTRALstatic final int CENTRAL = 4implies weight/mass
ERGO_READINGstatic final int ERGO_READING = 0Named ergonomic presets (mirror SLUIErgonomics).
ERGO_GALLERYstatic final int ERGO_GALLERY = 1No description in source.
ERGO_DASHBOARDstatic final int ERGO_DASHBOARD = 2No description in source.
ERGO_CONSOLEstatic final int ERGO_CONSOLE = 3No description in source.
ERGO_PORTRAITstatic final int ERGO_PORTRAIT = 4No description in source.
ERGO_TOOLBARstatic final int ERGO_TOOLBAR = 5No description in source.
layoutint layoutVM-local handle (-1 = none)

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createvoid create()No description in source.
handleint handle()No description in source.
validboolean valid()No description in source.
destroyvoid destroy()No description in source.
setDpivoid setDpi(double dpi)No description in source.
setEmvoid setEm(double emPx)No description in source.
groupint group(String groupName, int flow, int axis)---- groups (named) -----------------------------------------------------
groupCountint groupCount()No description in source.
setFlowvoid setFlow(String groupName, int flow, int axis)No description in source.
setSpacingvoid setSpacing(String groupName, SLMeasure spacing)No description in source.
setPaddingvoid setPadding(String groupName, SLMeasure padding)No description in source.
setAlignvoid setAlign(String groupName, int mainAlign, int crossAlign)No description in source.
setColumnsvoid setColumns(String groupName, int columns)No description in source.
setErgonomicsvoid setErgonomics(String groupName, int ergo)A named ergonomic preset for the ergonomics of publics.
itemint item(String groupName, String itemName, int widgetHandle, SLMeasure size)---- items (named) ------------------------------------------------------ Add a named item (an optional widget handle, -1 for a pure placeholder) into a named group, with a main-axis size (fr makes it flexible).
itemCountint itemCount(String groupName)No description in source.
setItemSizevoid setItemSize(String itemName, SLMeasure size)---- adjustment: single ------------------------------------------------
setItemMassvoid setItemMass(String itemName, double mass)No description in source.
setItemAlignvoid setItemAlign(String itemName, int crossAlign)No description in source.
setGroupSizevoid setGroupSize(String groupName, SLMeasure size)---- adjustment: whole group -------------------------------------------
setGroupMassvoid setGroupMass(String groupName, double mass)No description in source.
setNarySizevoid setNarySize(String[] itemNames, int count, SLMeasure size)---- adjustment: n-ary (a subset of a group of some size) -------------- `itemNames` is an array of the names to adjust; count its length.
setNaryMassvoid setNaryMass(String[] itemNames, int count, double mass)No description in source.
setNaryAlignvoid setNaryAlign(String[] itemNames, int count, int crossAlign)No description in source.
arrangevoid arrange(String groupName, int x, int y, int w, int h)---- resolution --------------------------------------------------------- Lay a named group out within a device-pixel rectangle; then read item rects with itemX/itemY/itemWidth/itemHeight.
itemXint itemX(String itemName)No description in source.
itemYint itemY(String itemName)No description in source.
itemWidthint itemWidth(String itemName)No description in source.
itemHeightint itemHeight(String itemName)No description in source.

SLLevelBar #sleela 2.5 (lib/user-interface/SLLevelBar.sleela)

SLLevelBar class extends SLWidget

Defines SLLevelBar — a SleelaUI segmented level indicator (battery/volume style): a row of ten segments, the leading ones lit in the accent colour in proportion to a fraction in [0,1]. Use it for a discrete "how full / how strong" reading. The constructor bottoms out in the `uiLevelBar` built-in (SleelaUI C ABI slui_level_bar()); the fraction is read/written through level()/setLevel(). An SLLevelBar IS an SLWidget but is non-interactive. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, double level)Create a level bar inside `parent` with an initial level in [0,1].
createInHandlevoid createInHandle(int parentHandle, double level)No description in source.
leveldouble level()No description in source.
setLevelvoid setLevel(double level)No description in source.

SLLight #sleela 2.5 (lib/user-interface/SLLight.sleela)

SLLight class

Defines SLLight — a SleelaUI light descriptor used to light and relieve Canvas-aware objects. A light has a KIND (point, directional, ambient), a ROLE, a POLARITY, a position/direction, a reach, an intensity, a softness (penumbra width), and a colour. It is a pure value object the host fills and hands to an SLLightScene; the scene decides whether it is a SOURCE (reserves an anchor object — the object is used as the light) or an EMITTER (reserves nothing, reusable). Both light and shadow come from either a source or an emitter: the POLARITY decides whether the emission brightens (light) or darkens (shadow/umbra). Family: user-interface. Mirrors SLUILight in the SleelaUI Lighting C ABI (sleela_ui_light.h).

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
POINTstatic final int POINT = 0Kind ordinals (mirror SLUILightKind).
DIRECTIONALstatic final int DIRECTIONAL = 1No description in source.
AMBIENTstatic final int AMBIENT = 2No description in source.
SOURCEstatic final int SOURCE = 0Role ordinals (mirror SLUILightRole). reserves its anchor object (object USED)
EMITTERstatic final int EMITTER = 1reserves nothing; reusable
LIGHTstatic final int LIGHT = 0Polarity ordinals (mirror SLUIPolarity). brightens
SHADOWstatic final int SHADOW = 1darkens (umbra emission)
kindint kindNo description in source.
roleint roleNo description in source.
polarityint polarityNo description in source.
radiusdouble radiuspoint reach in px (0 = infinite)
intensitydouble intensity0..N emission multiplier
softnessdouble softness0..1 penumbra width for cast shadows
colorint color0xRRGGBBAA emission (shadow colour if SHADOW)
anchorint anchorfor a SOURCE: the reserved anchor id

Methods — the actions this unit can perform.

MethodSignatureWhat it does
pointvoid point(double px, double py, double reach, double i, int c)A point light at (x,y) reaching `radius` px, with an intensity + colour.
directionalvoid directional(double ux, double uy, double i, int c)A directional "sun" travelling along (ux,uy).
ambientvoid ambient(double i, int c)A uniform ambient fill.
asShadowvoid asShadow()Turn this light into a shadow (negative-polarity) emission.
asLightvoid asLight()Turn this light into a light (positive-polarity) emission.

SLLightScene #sleela 2.5 (lib/user-interface/SLLightScene.sleela)

SLLightScene class

Defines SLLightScene — a collection of SleelaUI lights applied to a draw context to light and relieve Canvas-aware objects. The scene owns the SOURCE RESERVATION table: an anchor object can be used as a source at most once (addSource refuses a second), while EMITTERS reserve nothing and may be added freely and reused. It also holds the base ambient illumination so even an unlit object is not pure black. Each method bottoms out in a `light*` SLVM built-in that calls the SleelaUI Lighting C ABI (sleela_ui_light.h). A scene is a VM-local handle (-1 = none). An SLLight is passed by its descriptor fields through the built-ins. Family: user-interface. Native VM/UI work crosses the explicit `light*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
sceneint sceneVM-local scene handle (-1 = none)

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createvoid create()No description in source.
handleint handle()No description in source.
validboolean valid()No description in source.
destroyvoid destroy()No description in source.
clearvoid clear()No description in source.
countint count()No description in source.
addEmitterint addEmitter(SLLight l)Add an EMITTER (reserves nothing). Returns its index (>=0), reusable.
addSourceint addSource(int anchor, SLLight l)Add a SOURCE bound to `anchor` (reserves it; the object is USED as a source). Returns the light index (>=0), or a negative error if `anchor` is already reserved by another source in this scene.
anchorReservedboolean anchorReserved(int anchor)True if `anchor` is currently reserved as a source in this scene.
releaseSourcevoid releaseSource(int anchor)Release a source's reservation so the anchor can be a source again.
setAmbientvoid setAmbient(double intensity, int color)The base ambient illumination applied before any light.

SLLinkButton #sleela 2.5 (lib/user-interface/SLLinkButton.sleela)

SLLinkButton class extends SLWidget

Defines SLLinkButton — a SleelaUI hyperlink-style button: accent-coloured text that underlines on hover/focus and activates like a button (click, or Enter/Space while focused). Use it for navigation and "learn more" affordances where a full button would be too heavy. The constructor bottoms out in the `uiLinkButton` built-in (SleelaUI C ABI slui_link_button()); the text is updated through the inherited setText(). An SLLinkButton IS an SLWidget and is keyboard-focusable. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String label)Create a link button inside `parent` with a label.
createInHandlevoid createInHandle(int parentHandle, String label)No description in source.
clickedboolean clicked()True if the link was activated since the last check (latch cleared on read).

SLLoadingDemo #sleela 2.5 (lib/user-interface/SLLoadingDemo.sleela)

SLLoadingDemo class

Defines SLLoadingDemo — a worked, runnable example that builds a Slick Black window from pure SLeeLa source showing the activity family: a flowing SLThrobber, an arc SLSpinner, a determinate SLProgressBar, and the unified SLLoadingIndicator stepping from an indeterminate "Resolving…" phase into a determinate "Compiling… NN%" phase and finally done(). It is the SLeeLa-source twin of the gallery, proving the loading indicators are fully usable from the language itself. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
uiSLUserInterface uiNo description in source.
winSLWindow winNo description in source.
loaderSLLoadingIndicator loaderNo description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
runint run()No description in source.

SLLoadingIndicator #sleela 2.5 (lib/user-interface/SLLoadingIndicator.sleela)

SLLoadingIndicator class extends SLWidget

Defines SLLoadingIndicator — a SleelaUI composite "loading" widget that unifies the three activity primitives behind one caption, with no new C ABI. It is a horizontal row of {activity visual, caption label} that switches between two modes: - INDETERMINATE (unknown length): shows an SLThrobber (the water-flow field) or an SLSpinner (the accent arc), advanced each frame by the window loop / a host phase; - DETERMINATE (known length): shows an SLProgressBar filled to a fraction in [0,1], with the caption optionally carrying a percentage. A task begins indeterminate ("Resolving…"), may switch to determinate once a total is known ("Compiling… 60%"), and ends with done()/fail() which hide the activity visual and set a final caption. This is the IDE-friendly loading indicator built from SLThrobber + SLSpinner + SLProgressBar. An SLLoadingIndicator IS an SLWidget container (its handle is the row box). Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
MODE_IDLEstatic final int MODE_IDLE = 0Mode ordinals.
MODE_INDETERMINATEstatic final int MODE_INDETERMINATE = 1No description in source.
MODE_DETERMINATEstatic final int MODE_DETERMINATE = 2No description in source.
MODE_DONEstatic final int MODE_DONE = 3No description in source.
MODE_FAILEDstatic final int MODE_FAILED = 4No description in source.
STYLE_THROBBERstatic final int STYLE_THROBBER = 0Which indeterminate visual to use. the water-flow field (default)
STYLE_SPINNERstatic final int STYLE_SPINNER = 1the accent arc on a ring
rowSLBox rowhorizontal: [visual] [caption]
throbberSLThrobber throbberindeterminate (STYLE_THROBBER)
spinnerSLSpinner spinnerindeterminate (STYLE_SPINNER)
barSLProgressBar bardeterminate
captionSLLabel captionthe status text
styleint styleSTYLE_THROBBER | STYLE_SPINNER
modeint modeNo description in source.
fractiondouble fractioncurrent determinate fraction [0,1]
phasedouble phasecurrent indeterminate phase [0,1]
showPercentboolean showPercentappend " NN%" to the caption in determinate mode
baseCaptionString baseCaptionthe caption text without any appended percentage

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, int style0, int visualWidth)Create the indicator inside `parent`. style picks the indeterminate visual; visualWidth sizes the throbber (ignored for the spinner).
beginIndeterminatevoid beginIndeterminate(String text)Begin an indeterminate task of unknown length.
beginDeterminatevoid beginDeterminate(String text, double initial)Begin (or switch to) a determinate task; `initial` is the starting [0,1].
setFractionvoid setFraction(double value)Update determinate progress; clamps to [0,1] and refreshes the caption.
getFractiondouble getFraction()No description in source.
tickvoid tick(double delta)Advance the indeterminate visual (host calls this each frame; phase wraps).
donevoid done(String text)Finish successfully: hide the activity visual, set a final caption.
failvoid fail(String text)Finish with an error: hide the activity visual, set a failure caption.
resetvoid reset()Reset to idle (hidden).
currentModeint currentMode()No description in source.
busyboolean busy()No description in source.
finishedboolean finished()No description in source.
failedboolean failed()No description in source.
setStylevoid setStyle(int style0)Choose the indeterminate visual (throbber vs spinner) at any time.
setShowPercentvoid setShowPercent(boolean on)Whether to append a percentage to the determinate caption.
setCaptionvoid setCaption(String text)Set the base caption text (without any appended percentage).
applyModevoid applyMode()Show exactly the visual the current mode needs; hide the rest.
refreshCaptionvoid refreshCaption()Rebuild the caption, appending " NN%" in determinate mode when enabled.
percentTextString percentText(double f)fraction[0,1] -> integer percent 0..100 without a float->int cast.
clamp01double clamp01(double v)No description in source.

SLMaterial #sleela 2.5 (lib/user-interface/SLMaterial.sleela)

SLMaterial class

Defines SLMaterial — how a Canvas-aware object catches light. The RELIEF profile is a height model the lighting uses to compute surface normals, which is what produces the raised/recessed "quality relief": a smooth dome (ROUNDED), a crisp chamfer (BEVEL), an inset the shape reads as pressed INTO the floor (ENGRAVED), or a raised plateau standing OFF the floor (EMBOSSED). It also carries depth (how pronounced), gloss (specular sheen), occlusion (how much darkness pools in the creases), and the edge band width. It is a pure value object passed to SLLightScene painting helpers and to a canvas widget's light attachment. Family: user-interface. Mirrors SLUIMaterial in the SleelaUI Lighting C ABI.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
FLATstatic final int FLAT = 0Relief-profile ordinals (mirror SLUIReliefProfile).
ROUNDEDstatic final int ROUNDED = 1No description in source.
BEVELstatic final int BEVEL = 2No description in source.
ENGRAVEDstatic final int ENGRAVED = 3No description in source.
EMBOSSEDstatic final int EMBOSSED = 4No description in source.
profileint profileNo description in source.
depthdouble depthrelief height in px
glossdouble gloss0 matte .. 1 mirror (specular sheen)
occlusiondouble occlusion0..1 ambient-occlusion darkening in the creases
edgePxdouble edgePxbevel/edge band width in px

Methods — the actions this unit can perform.

MethodSignatureWhat it does
ofvoid of(int reliefProfile, double reliefDepth)Fill a material for a profile at a given relief depth, with sensible defaults for gloss/occlusion/edge the host may then tune.
roundedvoid rounded(double depth)Common relief shorthands.
bevelvoid bevel(double depth)No description in source.
engravedvoid engraved(double depth)No description in source.
embossedvoid embossed(double depth)No description in source.

SLMeasure #sleela 2.5 (lib/user-interface/SLMeasure.sleela)

SLMeasure class

Defines SLMeasure — a standardized unit of measurement for the SleelaUI layout system, spanning US customary (inch, foot, point, pica), Eurasian metric (mm, cm, m), device pixels (px), and relative units (percent, flexible fraction fr, em). A measure is a (value, unit) pair that resolves to device pixels at a DPI — one vocabulary across US and Eurasian countries, with px available of course. It is a pure value helper mirroring SLUIMeasure in the SleelaUI Layout C ABI (sleela_ui_layout.h). Family: user-interface.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
PXstatic final int PX = 0Unit ordinals (mirror SLUIUnitKind). device pixels
MMstatic final int MM = 1millimetre (metric)
CMstatic final int CM = 2centimetre (metric)
Mstatic final int M = 3metre (metric)
INstatic final int IN = 4inch (US)
FTstatic final int FT = 5foot (US)
PTstatic final int PT = 6typographic point (US, 1/72in)
PICAstatic final int PICA = 7pica (US, 12pt)
PCTstatic final int PCT = 8percent of the reference extent
FRstatic final int FR = 9flexible fraction / weight share
EMstatic final int EM = 10multiples of the base font size
valuedouble valueNo description in source.
unitint unitNo description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
ofvoid of(double v, int u)No description in source.
pxvoid px(double v)US customary + metric + device + relative builders.
mmvoid mm(double v)No description in source.
cmvoid cm(double v)No description in source.
metersvoid meters(double v)No description in source.
inchvoid inch(double v)No description in source.
feetvoid feet(double v)No description in source.
pointsvoid points(double v)No description in source.
picavoid pica(double v)No description in source.
percentvoid percent(double v)No description in source.
fractionvoid fraction(double v)No description in source.
emvoid em(double v)No description in source.
toPixelsdouble toPixels(double dpi, double referencePx, double emPx)Resolve to device pixels at `dpi`, with a reference extent (for percent) and em size (for em).
isFlexibleboolean isFlexible()No description in source.

SLMm #sleela 2.5 (lib/user-interface/SLMm.sleela)

SLMm class

Defines SLMm — a millimetre placement for a SleelaUI light/dark/ shadow emitter, relative to the text's font-paint location. It holds a left/right offset, an up/down offset, and a HEIGHT the light shines down from, all in millimetres, and converts to device pixels at a DPI. This is the mm-precise placement the lighting design calls for: the light shines down from some mm of height, and left/right/up/down are all supported. Mirrors SLUIMm in the SleelaUI Mood/Light C ABI (sleela_ui_mood.h). SLMm is a pure value helper (no VM handle); feed it to SLMood.placeLight or the `light*` built-ins. Family: user-interface.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
rightMmdouble rightMm+right, -left
downMmdouble downMm+down, -up
heightMmdouble heightMmabove the plane the light shines down from

Methods — the actions this unit can perform.

MethodSignatureWhat it does
ofvoid of(double right, double down, double height)No description in source.
leftvoid left(double mm, double height)No description in source.
rightvoid right(double mm, double height)No description in source.
upvoid up(double mm, double height)No description in source.
downvoid down(double mm, double height)No description in source.
toPixelsdouble toPixels(double mm, double dpi)Millimetres to device pixels at `dpi` (25.4 mm per inch).

SLMood #sleela 2.5 (lib/user-interface/SLMood.sleela)

SLMood class

Defines SLMood — a named, adjustable SleelaUI mood: an Excellent Wash + a natural tanor + a Calculus-8, together. The mood's colour is the wash sampled at the calculus's mood scalar, freshened over time by the tanor's refresh and its gentle "a little left" bias. A tanor is a soft, portrait-quality ambient glow for "lightless bulbs" (light-of-effect with no hard source). Applying a mood to a light sets its colour and folds in the tanor's portrait softness/depth — so inputs flow into direct moods in one call. Each method bottoms out in a `mood*`/`light*` SLVM built-in calling the C ABI (sleela_ui_mood.h). A mood is a VM-local handle (-1 = none). Family: user-interface. Native VM/UI work crosses the explicit `mood*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
CALMstatic final int CALM = 0Mood-kind ordinals (mirror SLUIMoodKind).
WARMstatic final int WARM = 1No description in source.
COOLstatic final int COOL = 2No description in source.
VIVIDstatic final int VIVID = 3No description in source.
SOMBERstatic final int SOMBER = 4No description in source.
TENDERstatic final int TENDER = 5No description in source.
RADIANTstatic final int RADIANT = 6No description in source.
CUSTOMstatic final int CUSTOM = 7No description in source.
SOURCEstatic final int SOURCE = 0Role/polarity ordinals (mirror the Lighting C ABI) for placeLight.
EMITTERstatic final int EMITTER = 1No description in source.
LIGHTstatic final int LIGHT = 0No description in source.
SHADOWstatic final int SHADOW = 1No description in source.
moodint moodVM-local handle (-1 = none)

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createvoid create(int kind)Create a mood from a built-in kind (pre-filled tasteful wash + tanor) or CUSTOM to set your own.
handleint handle()No description in source.
validboolean valid()No description in source.
destroyvoid destroy()No description in source.
setWashvoid setWash(SLWash wash)Give the mood an Excellent Wash and a Calculus-8 (borrowed).
setCalculusvoid setCalculus(SLCalculus8 calc)No description in source.
setTanorvoid setTanor(double warmth, double diffusion, double refreshHz,Configure the natural tanor (lightless-bulb glow): warmth 0 cool..1 warm, diffusion 0..1 portrait softness, refreshHz pattern refresh, leftBias "a little left", depth 0..1, tone 0xRRGGBBAA.
colorint color(double timeS)The mood's current colour, freshened at time_s seconds (0xRRGGBBAA).
placeLightint placeLight(SLLightScene scene, double fontX, double fontBaseline,Build a mm-placed, mood-coloured light for text painted at (fontX, fontBaseline). mm places it (height it shines down from, plus left/right/up/down); dpi resolves mm to pixels; role/polarity choose source vs emitter and light vs shadow. Adds it to `scene` and returns the light index (or a negative error).

SLNotebook #sleela 2.5 (lib/user-interface/SLNotebook.sleela)

SLNotebook class extends SLWidget

Defines SLNotebook — a browser-style horizontal tab strip and page stack. It uses themed native buttons, selected accent, quiet inactive tabs, a compact strip, and a clearly separated content region. A dirty marker can be shown per tab (e.g. an unsaved editor). Pointer hover/press visuals are provided by the native Button widget; clicked() is the one-shot release-on- target activation latch. This stays in SLeeLa over SleelaUI primitives. An SLNotebook IS an SLWidget container. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
MAX_PAGESstatic final int MAX_PAGES = 4096No description in source.
columnSLBox columnvertical: tab strip over the content area
stripSLBox striphorizontal tab strip
stackSLBox stackthe content area (one page visible at a time)
tabsSLButton[] tabsone tab button per page
pagesSLBox[] pagesone content container per page
titlesString[] titlesbase tab titles (without the dirty marker)
dirtyboolean[] dirtyper-page dirty flag (adds a '*' to the tab)
countint countNo description in source.
activeint activeactive page index, -1 when empty

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent)No description in source.
addPageint addPage(String title)Add a page with a tab title; returns the page index. The returned page's content() is the container child widgets attach to.
pageContentSLWidget pageContent(int index)The content container for page `index` (attach children with createIn).
selectvoid select(int index)Show page `index`, hide the rest, accent its tab.
activeIndexint activeIndex()No description in source.
selectPreviousvoid selectPrevious()Browser-style convenience: activate the previous or next tab.
selectNextvoid selectNext()No description in source.
takeClickedTabint takeClickedTab()Poll the tab strip: if a tab was clicked since the last check, make it active and return its index; otherwise return -1.
setDirtyvoid setDirty(int index, boolean isDirty)Mark a page dirty/clean; refreshes its tab label with a '*' suffix.
isDirtyboolean isDirty(int index)No description in source.
setTitlevoid setTitle(int index, String title)Rename a tab (keeps the current dirty marker).
pageCountint pageCount()No description in source.

SLPackage #sleela 2.5 (lib/user-interface/SLPackage.sleela)

SLPackage class

Defines the SLeeLa standard-library package for user-interface.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
packageNameString packageNameNo description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
configurevoid configure(String name)No description in source.
nameString name()No description in source.
availableboolean available()No description in source.

SLPasswordEntry #sleela 2.5 (lib/user-interface/SLPasswordEntry.sleela)

SLPasswordEntry class extends SLWidget

Defines SLPasswordEntry — a SleelaUI password field: a single-line entry that renders a bullet dot for each character instead of the character itself, used for secret input. It behaves like SLEntry otherwise (UTF-8 editing, caret, Enter raises an activate event); the underlying text is still readable through text() so the host can submit it. The constructor bottoms out in the `uiPasswordEntry` built-in (SleelaUI C ABI slui_password_entry()). An SLPasswordEntry IS an SLWidget and is keyboard-focusable. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String placeholder)Create a password entry inside `parent` (placeholder defaults to "Password").
createInHandlevoid createInHandle(int parentHandle, String placeholder)No description in source.
submittedboolean submitted()True if Enter was pressed since the last check (latch cleared on read).

SLProgressBar #sleela 2.5 (lib/user-interface/SLProgressBar.sleela)

SLProgressBar class extends SLWidget

Defines SLProgressBar — a SleelaUI determinate progress bar: a rounded trough with an accent fill proportional to a fraction in [0,1]. Use it to show how far a known-length task has advanced. The constructor bottoms out in the `uiProgressBar` built-in (SleelaUI C ABI slui_progress_bar()); the fraction is read/written through fraction()/setFraction(). An SLProgressBar IS an SLWidget but is non-interactive. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, double fraction)Create a progress bar inside `parent` with an initial fraction in [0,1].
createInHandlevoid createInHandle(int parentHandle, double fraction)No description in source.
fractiondouble fraction()No description in source.
setFractionvoid setFraction(double fraction)No description in source.

SLRadioButton #sleela 2.5 (lib/user-interface/SLRadioButton.sleela)

SLRadioButton class extends SLWidget

Defines SLRadioButton — a SleelaUI labelled radio button: a circle with an accent dot when selected. Radio buttons that share a group ordinal AND the same parent are mutually exclusive — selecting one clears the others in its group. Selecting (click, or Space/Enter while focused) raises an activate event. The constructor bottoms out in the `uiRadioButton` built-in (SleelaUI C ABI slui_radio_button()); the state is read through isSelected(). An SLRadioButton IS an SLWidget and is keyboard-focusable. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String label, int group, boolean selected)Create a radio inside `parent`, in exclusivity `group`, with a label and initial selected state.
createInHandlevoid createInHandle(int parentHandle, String label, int group,No description in source.
isSelectedboolean isSelected()No description in source.
selectvoid select()No description in source.
changedboolean changed()True if this radio was just selected since the last check (latch cleared).

SLScrollBar #sleela 2.5 (lib/user-interface/SLScrollBar.sleela)

SLScrollBar class extends SLWidget

Defines SLScrollBar — a SleelaUI scroll bar indicator: a thin rounded track with a draggable thumb. The thumb covers a `page` fraction of the track and sits at a `value` position in [0,1]; dragging it reports a new value. The constructor bottoms out in the `uiScrollBar` built-in (SleelaUI C ABI slui_scroll_bar()); the position is read/written through position()/setPosition(). An SLScrollBar IS an SLWidget and is keyboard-focusable. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, int orientation, double value, double page)Create a scroll bar inside `parent`. orientation is ORIENT_VERTICAL or ORIENT_HORIZONTAL; value is the initial position in [0,1]; page is the visible fraction the thumb covers (0..1).
createInHandlevoid createInHandle(int parentHandle, int orientation, double value,No description in source.
positiondouble position()No description in source.
setPositionvoid setPosition(double value)No description in source.
changedboolean changed()True if the position changed since the last check (latch cleared on read).

SLScrollView #sleela 2.5 (lib/user-interface/SLScrollView.sleela)

SLScrollView class extends SLWidget

Defines SLScrollView — a SleelaUI scrollable viewport. It is a composite SleelaUI widget (it adds no new C ABI): a vertical content box held inside a clipping frame, with an SLScrollBar on the needed axes. The content box is the parent handle children attach to; the view tracks the content's natural extent against the viewport extent and only shows a bar when the content overflows. Scroll position is reported in [0,1] by the bars and converted to a pixel offset the toolkit applies to the content. An SLScrollView IS an SLWidget container built from SLFrame + SLBox + SLScrollBar, so any widget set (a tree, a list, a text view) becomes scrollable by being built into its content(). Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
clipSLFrame clipthe clipping viewport
layoutSLBox layouthorizontal: content column + vertical scrollbar
contentSLBox contentthe vertical content column children attach to
vbarSLScrollBar vbarvertical scrollbar (shown only when overflowing)
hbarSLScrollBar hbarhorizontal scrollbar (optional)
contentExtentint contentExtentnatural content height in pixels
viewportExtentint viewportExtentvisible viewport height in pixels
horizontalboolean horizontalwhether a horizontal bar is enabled

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, boolean horizontalBar)Create a scroll view inside `parent`. horizontalBar enables the x-axis bar.
contentAreaSLWidget contentArea()The container children attach to (via createIn(scroll.content(), ...)).
setExtentsvoid setExtents(int content_px, int viewport_px)Tell the view how tall its content and viewport are so it can size the thumb (page fraction) and decide whether the bar is needed.
overflowingboolean overflowing()Whether the content currently overflows the viewport (bar is meaningful).
scrollOffsetint scrollOffset()Current vertical scroll offset in pixels, derived from the bar position. The position is a [0,1] double; we convert through a permille integer so the result stays in integer pixel space with no float->int cast.
positionPermilleint positionPermille()The bar position in integer permille (0..1000), i.e. floor(position*1000).
scrollToPixelvoid scrollToPixel(int y)Scroll so the pixel row `y` is visible (used by tree/list/text to follow the caret or selection).
scrolledboolean scrolled()True if the user moved either bar since the last check.
clamp01double clamp01(double v)No description in source.

SLSearchEntry #sleela 2.5 (lib/user-interface/SLSearchEntry.sleela)

SLSearchEntry class extends SLWidget

Defines SLSearchEntry — a SleelaUI search field: a single-line entry with a leading magnifier glyph and a "Search" placeholder, used for filter/search inputs. It behaves like SLEntry otherwise (UTF-8 editing, caret, Enter raises an activate event). The constructor bottoms out in the `uiSearchEntry` built-in (SleelaUI C ABI slui_search_entry()); the committed text is read/written through the inherited text()/setText(). An SLSearchEntry IS an SLWidget and is keyboard-focusable. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String placeholder)Create a search entry inside `parent` (placeholder defaults to "Search").
createInHandlevoid createInHandle(int parentHandle, String placeholder)No description in source.
submittedboolean submitted()True if Enter was pressed since the last check (latch cleared on read).

SLSeparator #sleela 2.5 (lib/user-interface/SLSeparator.sleela)

SLSeparator class extends SLWidget

Defines SLSeparator — a SleelaUI 1px hairline rule in the theme's border colour, used to divide sections of a layout. It can be horizontal (a full-width rule in a vertical box) or vertical (a full-height rule in a horizontal box). The constructor bottoms out in the `uiSeparator` built-in, which calls the SleelaUI C ABI slui_separator(). An SLSeparator IS an SLWidget but is non-interactive and non-focusable. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, int orientation)Create a separator inside `parent`. orientation is ORIENT_HORIZONTAL (a horizontal rule) or ORIENT_VERTICAL (a vertical rule).
createInHandlevoid createInHandle(int parentHandle, int orientation)No description in source.
horizontalvoid horizontal(SLWidget parent)No description in source.
verticalvoid vertical(SLWidget parent)No description in source.

SLSlider #sleela 2.5 (lib/user-interface/SLSlider.sleela)

SLSlider class extends SLWidget

Defines SLSlider — a SleelaUI horizontal slider: a thin trough with an accent fill up to the current value and a round knob, draggable with the pointer or nudgeable with the arrow keys when focused. The constructor bottoms out in the `uiSlider` built-in (SleelaUI C ABI slui_slider()); the value is read/written through value()/setValue(), clamped to the [min, max] range given at construction. An SLSlider IS an SLWidget and is keyboard-focusable. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, double min, double max, double value)Create a slider inside `parent` spanning [min, max] with an initial value.
createInHandlevoid createInHandle(int parentHandle, double min, double max, double value)No description in source.
valuedouble value()No description in source.
setValuevoid setValue(double value)No description in source.
changedboolean changed()True if the value changed since the last check (latch cleared on read).

SLSpacer #sleela 2.5 (lib/user-interface/SLSpacer.sleela)

SLSpacer class extends SLWidget

Defines SLSpacer — a SleelaUI flexible gap: an invisible, zero-natural-size child that expands to absorb surplus space along its box's main axis. It is the idiom for pushing a control to the far edge of a box (e.g. a settings gear to the right of a header bar). The constructor bottoms out in the `uiSpacer` built-in, which calls the SleelaUI C ABI slui_spacer(). An SLSpacer IS an SLWidget but has no painted content; it only consumes space. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent)Create a flexible spacer inside `parent`.
createInHandlevoid createInHandle(int parentHandle)No description in source.

SLSpinButton #sleela 2.5 (lib/user-interface/SLSpinButton.sleela)

SLSpinButton class extends SLWidget

Defines SLSpinButton — a SleelaUI numeric spin button: a value between two steppers (minus / plus) that increment by a fixed step, clamped to a [min, max] range (arrow keys also step while focused). Use it for bounded numeric input. The constructor bottoms out in the `uiSpinButton` built-in (SleelaUI C ABI slui_spin_button()); the value is read/written through value()/setValue(). An SLSpinButton IS an SLWidget and is keyboard-focusable. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, double min, double max, double step,Create a spin button inside `parent` spanning [min, max], stepping by `step`, with an initial value.
createInHandlevoid createInHandle(int parentHandle, double min, double max, double step,No description in source.
valuedouble value()No description in source.
setValuevoid setValue(double value)No description in source.
changedboolean changed()True if the value changed since the last check (latch cleared on read).

SLSpinner #sleela 2.5 (lib/user-interface/SLSpinner.sleela)

SLSpinner class extends SLWidget

Defines SLSpinner — a SleelaUI indeterminate activity spinner: an accent arc riding a faint ring, used while a task of unknown length runs. The host advances the arc by setting a phase in [0,1] each frame (the toolkit draws the arc at that position). The constructor bottoms out in the `uiSpinner` built-in (SleelaUI C ABI slui_spinner()); the phase is set through setPhase(). An SLSpinner IS an SLWidget but is non-interactive. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent)Create a spinner inside `parent`.
createInHandlevoid createInHandle(int parentHandle)No description in source.
setPhasevoid setPhase(double phase)Advance the bright arc; phase wraps over [0,1].
phasedouble phase()No description in source.

SLStatusBar #sleela 2.5 (lib/user-interface/SLStatusBar.sleela)

SLStatusBar class extends SLWidget

Defines SLStatusBar — a SleelaUI footer status strip: a chrome band with a 1px top hairline that lays its children out horizontally. Use it for a resting status line (e.g. "Ready", a spacer, the version). The constructor bottoms out in the `uiStatusBar` built-in (SleelaUI C ABI slui_status_bar()); children are added by constructing control classes against this status bar's handle. An SLStatusBar IS an SLWidget container (horizontal). Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent)Create a status bar inside `parent` (normally the window root).
createInHandlevoid createInHandle(int parentHandle)No description in source.

SLTabBar #sleela 2.5 (lib/user-interface/SLTabBar.sleela)

SLTabBar class extends SLWidget

A reusable horizontal browser-style tab bar. It uses the existing native SLButton visual states and current window theme, with a clear selected accent, consistent inactive tabs, compact spacing, and one-shot click activation. Page content is deliberately left to the caller. Family: user-interface.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
MAX_TABSstatic final int MAX_TABS = 512No description in source.
stripSLBox stripNo description in source.
tabsSLButton[] tabsNo description in source.
titlesString[] titlesNo description in source.
dirtyboolean[] dirtyNo description in source.
countint countNo description in source.
activeint activeNo description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent)No description in source.
addTabint addTab(String title)No description in source.
selectvoid select(int index)No description in source.
selectedIndexint selectedIndex()No description in source.
tabCountint tabCount()No description in source.
takeClickedTabint takeClickedTab()Poll after the UI event loop has dispatched input. Returns index or -1.
selectPreviousvoid selectPrevious()No description in source.
selectNextvoid selectNext()No description in source.
setTitlevoid setTitle(int index, String title)No description in source.
setDirtyvoid setDirty(int index, boolean value)No description in source.
isDirtyboolean isDirty(int index)No description in source.
refreshTitlevoid refreshTitle(int index)No description in source.

SLTextView #sleela 2.5 (lib/user-interface/SLTextView.sleela)

SLTextView class extends SLWidget

Defines SLTextView — a competent SleelaUI multi-line editable text / code editor, written entirely in SLeeLa. It owns the text model (a line buffer, a caret at line/column, and an optional selection span) and renders it onto an SLCanvasView via the SleelaUI Draw API: a gutter with 1-based line numbers, the text lines in a monospace metric, the current-line highlight, the selection band, and a block caret. It exposes real editing operations — insert text, newline, backspace, delete, and caret movement — and a dirty flag that distinguishes a load from user edits. This is the code editor an IDE needs, with no new C ABI: it composes SLCanvasView + SLDrawContext. An SLTextView IS an SLWidget (its handle is the canvas view's handle). Family: user-interface. Native VM/UI work crosses the explicit `ui*`/`draw*` SLVM bridges.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
MAX_LINESstatic final int MAX_LINES = 1048576No description in source.
LINE_HEIGHTstatic final int LINE_HEIGHT = 18px per text row
CHAR_WIDTHstatic final int CHAR_WIDTH = 9px per monospace cell
GUTTER_Wstatic final int GUTTER_W = 52px line-number gutter
PAD_Xstatic final int PAD_X = 8px left padding inside the text area
COL_BGstatic final int COL_BG = 0x151515FFSlick Black palette (0xRRGGBBAA), consistent with the SleelaUI theme.
COL_GUTTER_BGstatic final int COL_GUTTER_BG = 0x1E1E1EFFNo description in source.
COL_GUTTER_FGstatic final int COL_GUTTER_FG = 0x6A6A6AFFNo description in source.
COL_TEXTstatic final int COL_TEXT = 0xE6E6E6FFNo description in source.
COL_CARETstatic final int COL_CARET = 0x3BE07AFFbrand green
COL_SELECTstatic final int COL_SELECT = 0x294C38FFNo description in source.
COL_CURLINEstatic final int COL_CURLINE = 0x1C1C1CFFNo description in source.
canvasSLCanvasView canvasNo description in source.
linesString[] linesText model.
lineCountint lineCountNo description in source.
caretLineint caretLineCaret and selection (line/column are 0-based).
caretColint caretColNo description in source.
anchorLineint anchorLineselection anchor; equal to caret when there is no selection
anchorColint anchorColNo description in source.
dirtyboolean dirtyNo description in source.
topLineint topLinefirst visible line (vertical scroll in lines)
viewportRowsint viewportRowsvisible text rows (set from the canvas height)

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, int width, int height)No description in source.
setDrawHandlervoid setDrawHandler(int handlerId)Register the SLeeLa draw-handler ordinal the VM calls each frame; the handler body should call render(ctx) with its SLDrawContext.
loadLinesvoid loadLines(String[] newLines, int n)Replace the whole buffer from a list of lines (a load, not an edit).
getLineCountint getLineCount()No description in source.
lineAtString lineAt(int i)No description in source.
isDirtyboolean isDirty()No description in source.
markSavedvoid markSaved()No description in source.
clearSelectionvoid clearSelection()No description in source.
hasSelectionboolean hasSelection()No description in source.
moveTovoid moveTo(int line, int col, boolean extend)No description in source.
moveLeftvoid moveLeft(boolean extend)No description in source.
moveRightvoid moveRight(boolean extend)No description in source.
moveUpvoid moveUp(boolean extend)No description in source.
moveDownvoid moveDown(boolean extend)No description in source.
moveHomevoid moveHome(boolean extend)No description in source.
moveEndvoid moveEnd(boolean extend)No description in source.
clickAtvoid clickAt(int px, int py, boolean extend)Map a pixel click inside the text area to a caret position.
insertvoid insert(String s)Insert a run of text with no newlines at the caret.
newlinevoid newline()Split the current line at the caret (Enter).
backspacevoid backspace()Backspace: delete the selection, else the char before the caret, else join with the previous line.
deleteForwardvoid deleteForward()Forward delete.
deleteSelectionvoid deleteSelection()Delete the current selection and place the caret at its start. Only the single-line and whole-line-span common cases are modeled here; a full multi-line splice is a host-assisted operation.
rendervoid render(SLDrawContext ctx)Paint the editor into `ctx` (an SLDrawContext bound to the canvas frame).
paintSelectionBandvoid paintSelectionBand(SLDrawContext ctx, int line, int y, int w)No description in source.
paintCaretvoid paintCaret(SLDrawContext ctx)No description in source.
followCaretvoid followCaret()No description in source.
insertLineAtvoid insertLineAt(int index, String value)No description in source.
removeLineAtvoid removeLineAt(int index)No description in source.
clampLineint clampLine(int line)No description in source.
clampColint clampCol(int line, int col)No description in source.
selectionForwardboolean selectionForward()Normalized selection bounds (start precedes end in document order).
selStartLineint selStartLine()No description in source.
selStartColint selStartCol()No description in source.
selEndLineint selEndLine()No description in source.
selEndColint selEndCol()No description in source.
lenint len(String s)No description in source.
substrString substr(String s, int from, int to)No description in source.

SLTheme #sleela 2.5 (lib/user-interface/SLTheme.sleela)

SLTheme class

Defines SLTheme — a SleelaUI palette handle. A theme is the single source of truth for a window's look: a flat set of named role colours plus a corner radius, spacing unit, control height, and font. This class wraps the toolkit's theme built-ins: uiThemePreset (fill from a built-in preset), the role setters (uiThemeSet*), metric/font setters, and the base-colour hooks. Each bottoms out in the SleelaUI C ABI (slui_theme_preset + the SLUITheme fields). The DEFAULT is a cool graphite/charcoal palette with a steel-blue accent. White, blue, black and gray are selectable named presets. Apps may choose a preset directly in source or explicitly load a named theme from a key=value configuration file. Configuration is never silently auto-loaded. A theme is a VM-local handle (-1 = none). Pass handle() to SLUserInterface.openWindow() or SLWindow.setTheme(); pass -1 anywhere a theme is expected to get the default. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
SLICK_BLACKstatic final int SLICK_BLACK = 0Preset ordinals mirror SLUIThemeId in the toolkit C ABI.
GRAPHITEstatic final int GRAPHITE = 1No description in source.
CUSTOMstatic final int CUSTOM = 2No description in source.
SLEELA_BASEstatic final int SLEELA_BASE = 3DEFAULT is the coordinated graphite/charcoal + steel-blue palette.
DEFAULTstatic final int DEFAULT = 3No description in source.
WHITEstatic final int WHITE = 4No description in source.
BLACKstatic final int BLACK = 5No description in source.
BLUEstatic final int BLUE = 6No description in source.
GRAYstatic final int GRAY = 7No description in source.
BASE_COLOR_DEFAULTstatic final int BASE_COLOR_DEFAULT = 0x1D2025FFNo description in source.
themeint themeVM-local theme handle (-1 = none)

Methods — the actions this unit can perform.

MethodSignatureWhat it does
presetvoid preset(int presetId)Select one preset directly in source: DEFAULT, WHITE, BLUE, BLACK, or GRAY.
sleelaBasevoid sleelaBase()No description in source.
defaultThemevoid defaultTheme()No description in source.
whitevoid white()No description in source.
bluevoid blue()No description in source.
blackvoid black()No description in source.
grayvoid gray()No description in source.
slickBlackvoid slickBlack()No description in source.
handleint handle()No description in source.
validboolean valid()No description in source.
setBaseColorvoid setBaseColor(int baseColor)Re-derive a neutral/cool palette from a custom base colour (0xRRGGBBAA).
loadConfigboolean loadConfig(String path)Load theme=default|white|blue|black|gray plus optional overrides from a key=value config file. Returns true on success. Config is never auto-loaded.
setBackgroundvoid setBackground(int color)---- Role colours (each takes an SLColor word, 0xRRGGBBAA) -------------
setSurfacevoid setSurface(int color)No description in source.
setSurfaceHivoid setSurfaceHi(int color)No description in source.
setChromevoid setChrome(int color)No description in source.
setBordervoid setBorder(int color)No description in source.
setForegroundvoid setForeground(int color)No description in source.
setForegroundDimvoid setForegroundDim(int color)No description in source.
setAccentvoid setAccent(int color)No description in source.
setAccentForegroundvoid setAccentForeground(int color)No description in source.
setDangervoid setDanger(int color)No description in source.
setRadiusvoid setRadius(int px)---- Metrics and typography --------------------------------------------
setControlHeightvoid setControlHeight(int px)No description in source.
setFontvoid setFont(String family, int sizePt)No description in source.
setAccentColorvoid setAccentColor(SLColor c)Convenience: set a role colour from an SLColor object.
closevoid close()No description in source.

SLThrobber #sleela 2.5 (lib/user-interface/SLThrobber.sleela)

SLThrobber class extends SLWidget

Defines SLThrobber — a SleelaUI width-adjustable, full-motion, colour-predictive, water-like flowing activity throbber. Unlike a spinning ring, it is a fluid field: crests travel, disperse, and recombine like ripples on water, their colour arriving slightly AHEAD of the motion (the hue leads the local velocity), with latent hues surfacing on the brightest crests under strong flow and receding as it calms. The width is adjustable at any time and the field rescales while keeping the same physical feel. The constructor bottoms out in the `uiThrobber` built-in (SleelaUI C ABI slui_throbber()); it is an animated widget — while visible the window's frame loop advances it and repaints it at its refresh rate. An SLThrobber IS an SLWidget. Height follows setSizeRequest (a slim seam by default); set the width with setWidth, the flow vigour with setIntensity, and the base hue with setHue. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, int widthPx)Create a throbber inside `parent` with an initial pixel width.
createInHandlevoid createInHandle(int parentHandle, int widthPx)No description in source.
setWidthvoid setWidth(int widthPx)Adjust the width in pixels; the water field rescales to fit.
setIntensityvoid setIntensity(double intensity)Flow vigour in [0,1]: 0 = a calm trickle, 1 = vigorous flow. Drives both the speed and the colour spread of the field.
setHuevoid setHue(double hueDegrees)Base hue in degrees the predictive colouring flows around (205 ~ water; 150 ~ green water; 30 ~ warm). The actual rendered hue leads this by the local flow velocity.

SLToggle #sleela 2.5 (lib/user-interface/SLToggle.sleela)

SLToggle class extends SLWidget

Defines SLToggle — a SleelaUI toggle switch: a pill track with a sliding knob and a trailing label. On uses the theme accent; off uses a neutral surface with a hairline. Flipping it (click, or Enter/Space while focused) raises an activate event and updates the boolean state. The constructor bottoms out in the `uiToggle` built-in (SleelaUI C ABI slui_toggle()); the state is read/written through isOn()/setOn(). An SLToggle IS an SLWidget and is keyboard-focusable. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String label, boolean initialOn)Create a toggle inside `parent` with a label and initial state.
createInHandlevoid createInHandle(int parentHandle, String label, boolean initialOn)No description in source.
isOnboolean isOn()No description in source.
setOnvoid setOn(boolean on)No description in source.
changedboolean changed()True if the toggle flipped since the last check (latch cleared on read).

SLTooltip #sleela 2.5 (lib/user-interface/SLTooltip.sleela)

SLTooltip class extends SLWidget

Defines SLTooltip — a SleelaUI tooltip bubble: a small raised surface with a 1px hairline and short explanatory text, used to annotate a control. The constructor bottoms out in the `uiTooltip` built-in (SleelaUI C ABI slui_tooltip()); the text is updated through the inherited setText(). An SLTooltip IS an SLWidget but is non-interactive. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, String text)Create a tooltip inside `parent` with a message.
createInHandlevoid createInHandle(int parentHandle, String text)No description in source.

SLTreeView #sleela 2.5 (lib/user-interface/SLTreeView.sleela)

SLTreeView class extends SLWidget

Defines SLTreeView — a competent SleelaUI hierarchical tree. It is a composite widget (no new C ABI): an SLScrollView whose content column holds one SLLabel row per *visible* node, indented by depth and prefixed with a disclosure marker. Nodes carry a stable id, a display label, a parent id, a depth, an expanded flag, and a leaf flag. Expanding/collapsing a branch recomputes the visible row set; clicking a row selects it and reports the selected node id. This is the data widget an IDE project explorer needs, written entirely in SLeeLa over the SleelaUI primitives. An SLTreeView IS an SLWidget (its handle is the scroll view's frame). Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
MAX_NODESstatic final int MAX_NODES = 65536No description in source.
ROW_HEIGHTstatic final int ROW_HEIGHT = 22pixels per row (for scroll math)
scrollSLScrollView scrollNo description in source.
idsString[] idsNode model (parallel arrays keyed by node index).
labelsString[] labelsNo description in source.
parentsint[] parentsindex of parent node, -1 for a root
depthsint[] depthsNo description in source.
expandedboolean[] expandedNo description in source.
leafboolean[] leafNo description in source.
countint countNo description in source.
visibleint[] visibleVisible-row projection (indices into the node arrays, in display order).
visibleCountint visibleCountNo description in source.
rowsSLLabel[] rowsOne reusable label row per visible slot.
rowCapacityint rowCapacityNo description in source.
selectedRowint selectedRowindex into `visible`, -1 when nothing selected

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent, int visibleRows)No description in source.
addNodeint addNode(String id, String label, String parentId, boolean isLeaf)Add a node under `parentId` ("" / null for a root). Returns its index.
indexOfIdint indexOfId(String id)No description in source.
rebuildvoid rebuild()Recompute the visible rows: a node is visible when every ancestor is expanded. Walks nodes in insertion order (parents precede children).
ancestorsExpandedboolean ancestorsExpanded(int node)No description in source.
paintvoid paint()Repaint the visible slice into the reusable row labels.
firstVisibleRowint firstVisibleRow()No description in source.
rowTextString rowText(int node)" > Branch" / " file.sleela" — indent by depth, disclosure marker.
indentString indent(int depth)No description in source.
togglevoid toggle(String id)Toggle a branch open/closed by node id; leaves are ignored.
selectRowvoid selectRow(int visibleIndex)Select a visible row (0-based into the visible projection).
selectedIdString selectedId()The selected node id, or null when nothing is selected.
selectionIsLeafboolean selectionIsLeaf()No description in source.
nodeCountint nodeCount()No description in source.
visibleRowCountint visibleRowCount()No description in source.

SLUserInterface #sleela 2.5 (lib/user-interface/SLUserInterface.sleela)

SLUserInterface class

Defines SLUserInterface — the capstone facade of the /lib/user-interface family. It is the single object a developer reaches for to open a window and build a graphical interface from SLeeLa source using SleelaUI™, SLeeLa's OWN original cross-platform UI toolkit (not GTK/Qt). Every method bottoms out in a `ui*` SLVM built-in that calls the GENUINE SleelaUI C ABI (include/sleela_ui.h) — which in turn drives the real host window system: X11 on Linux/Unix, Cocoa on macOS, Win32 on Windows 10+. So the same SLeeLa program raises a real window on whichever platform runs it, with the signature Slick Black look identical on all three. This is the general entry point: create the application, open a window, hand back its root container, then run the toolkit's event loop. The individual widget classes (SLButton, SLLabel, …) build on the same `ui*` built-ins. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge, the same discipline as /lib/os's `os*` bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
BACKEND_UNKNOWNstatic final int BACKEND_UNKNOWN = 0Backend ordinals (mirror SLUIBackend in the toolkit C ABI).
BACKEND_WIN32static final int BACKEND_WIN32 = 1No description in source.
BACKEND_COCOAstatic final int BACKEND_COCOA = 2No description in source.
BACKEND_X11static final int BACKEND_X11 = 3No description in source.
appIdString appIdapplication identifier, e.g. "com.mearvk.App"
appint appVM-local application handle (-1 = none)

Methods — the actions this unit can perform.

MethodSignatureWhat it does
configurevoid configure(String id)No description in source.
openboolean open()Create the SleelaUI application connection (opens the host display). Returns true if the toolkit came up (false if, e.g., no display on X11).
activeboolean active()No description in source.
backendString backend()The window-system backend driving this process: "x11" / "cocoa" / "win32".
backendIdint backendId()No description in source.
versionString version()No description in source.
isLinuxboolean isLinux()No description in source.
isMacboolean isMac()No description in source.
isWindowsboolean isWindows()No description in source.
screenWidthint screenWidth()The primary screen / display size in pixels, straight from the host window system (uiScreenWidth / uiScreenHeight bottom out in slui_screen_size). Returns 0 when the toolkit cannot report a size — e.g. a headless host, or before open() has connected the display — so callers can fall back to a modeled resolution (see SLGuiScreenFit). Needs an open application.
screenHeightint screenHeight()No description in source.
screenKnownboolean screenKnown()No description in source.
openWindowSLWindow openWindow(String title, int width, int height, int themeHandle)Open a window on this application. title/width/height describe the content area; theme is an SLTheme handle (pass -1 for the Slick Black default). Returns an SLWindow bound to the new native window.
runint run()Run the toolkit's own event loop until every window closes (or quit()). Returns the process-style exit code.
pumpint pump(boolean block)Process pending host events once; block != 0 waits for at least one. Returns the number of events dispatched, or a negative error.
quitvoid quit(int exitCode)Ask the event loop to stop; run() returns exitCode.
closevoid close()Release the application and all its windows.

SLVerticalTabs #sleela 2.5 (lib/user-interface/SLVerticalTabs.sleela)

SLVerticalTabs class extends SLWidget

A vertical navigation-tabs composite for settings, tool panels, and application sections. A narrow themed button rail sits beside a page stack; selecting a rail item reveals exactly one content container. Uses existing native button states and the active theme without fixed colors. Family: user-interface.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
MAX_PAGESstatic final int MAX_PAGES = 512No description in source.
layoutSLBox layoutNo description in source.
railSLBox railNo description in source.
stackSLBox stackNo description in source.
tabsSLButton[] tabsNo description in source.
pagesSLBox[] pagesNo description in source.
titlesString[] titlesNo description in source.
dirtyboolean[] dirtyNo description in source.
countint countNo description in source.
activeint activeNo description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
createInvoid createIn(SLWidget parent)No description in source.
addPageint addPage(String title)No description in source.
pageContentSLWidget pageContent(int index)No description in source.
selectvoid select(int index)No description in source.
selectedIndexint selectedIndex()No description in source.
pageCountint pageCount()No description in source.
takeClickedTabint takeClickedTab()Poll after the UI event loop has dispatched input. Returns index or -1.
setTitlevoid setTitle(int index, String title)No description in source.
setDirtyvoid setDirty(int index, boolean value)No description in source.
isDirtyboolean isDirty(int index)No description in source.
refreshTitlevoid refreshTitle(int index)No description in source.

SLWash #sleela 2.5 (lib/user-interface/SLWash.sleela)

SLWash class

Defines SLWash — an "Excellent Wash": a soft, multi-stop graded colour field (up to 8 stops) that paints a SleelaUI mood. Stops are sampled with smoothstep so the wash reads as a gentle gradient, not hard bands. Light colours are known and adjustable; the wash is how a mood colours the light. It is a VM-local handle built up stop by stop and handed to an SLMood. Each method bottoms out in a `wash*` SLVM built-in calling the C ABI (sleela_ui_mood.h). Family: user-interface. Native VM/UI work crosses the explicit `wash*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
washint washVM-local handle (-1 = none)

Methods — the actions this unit can perform.

MethodSignatureWhat it does
beginvoid begin()No description in source.
handleint handle()No description in source.
validboolean valid()No description in source.
destroyvoid destroy()No description in source.
stopvoid stop(double position, int color)Add a colour stop at position in [0,1]. Softness (0..1) extra-blurs between stops for a gentler wash.
setSoftnessvoid setSoftness(double softness)No description in source.
linearvoid linear(int a, int b)Two- and three-stop shortcuts for the common washes.
triadvoid triad(int a, int b, int c)No description in source.
sampleint sample(double t)Sample the wash at t in [0,1] -> colour (0xRRGGBBAA).

SLWidget #sleela 2.5 (lib/user-interface/SLWidget.sleela)

SLWidget class

Defines SLWidget — the base class for every SleelaUI control and container reached from SLeeLa source. It holds the VM-local widget handle and the common configuration the toolkit exposes on all widgets: margins, alignment, expansion, a minimum size request, sensitivity (grey-out), visibility, text, and the suggested/destructive accents. Each setter bottoms out in a `ui*` built-in that calls the SleelaUI C ABI. Subclasses (SLBox, SLHeaderBar, SLLabel, SLButton, SLToggle, SLEntry, SLSlider, SLSeparator, SLSpacer) are constructed against a parent handle and then inherit all of this common configuration surface. Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
ALIGN_STARTstatic final int ALIGN_START = 0Alignment ordinals (mirror SLUIAlign in the toolkit C ABI).
ALIGN_CENTERstatic final int ALIGN_CENTER = 1No description in source.
ALIGN_ENDstatic final int ALIGN_END = 2No description in source.
ALIGN_FILLstatic final int ALIGN_FILL = 3No description in source.
ORIENT_VERTICALstatic final int ORIENT_VERTICAL = 0Orientation ordinals (mirror SLUIOrientation).
ORIENT_HORIZONTALstatic final int ORIENT_HORIZONTAL = 1No description in source.
widgetint widgetVM-local widget handle (-1 = none)

Methods — the actions this unit can perform.

MethodSignatureWhat it does
adoptvoid adopt(int handle)Adopt an existing handle (used for the window's root container).
handleint handle()No description in source.
validboolean valid()No description in source.
setMarginvoid setMargin(int top, int right, int bottom, int left)---- Box model: margin, alignment, expansion, minimum size -------------
setMarginAllvoid setMarginAll(int all)No description in source.
setAlignvoid setAlign(int horizontal, int vertical)No description in source.
setExpandvoid setExpand(boolean horizontal, boolean vertical)No description in source.
setSizeRequestvoid setSizeRequest(int minWidth, int minHeight)No description in source.
setSensitivevoid setSensitive(boolean sensitive)---- State -------------------------------------------------------------
setVisiblevoid setVisible(boolean visible)No description in source.
setTextvoid setText(String text)---- Text (label / button / entry) -------------------------------------
textString text()No description in source.
createPopupPanelint createPopupPanel()---- Accents ----------------------------------------------------------- Create a reusable hidden popup panel within a parent layout. The caller should place it in a stack/overlay-capable container and manage visibility.
setPopupOpenvoid setPopupOpen(int popupHandle, boolean open)No description in source.
isPopupOpenboolean isPopupOpen(int popupHandle)No description in source.
wifiScanint wifiScan()---- Native Wi-Fi provider (shared wifi-common C/C++ core) ------------- Scan returns WIFI_STATUS_OK on success; query the bounded result cache with wifiNetworkCount/SSID/BSSID/signal/security. Indexes are zero-based.
wifiNetworkCountint wifiNetworkCount()No description in source.
wifiNetworkSsidString wifiNetworkSsid(int index)No description in source.
wifiNetworkBssidString wifiNetworkBssid(int index)No description in source.
wifiNetworkSignalint wifiNetworkSignal(int index)No description in source.
wifiNetworkSecurityString wifiNetworkSecurity(int index)No description in source.
wifiConnectint wifiConnect(int index, String profileName)Connect through OS-managed authentication or a trusted saved profile. The bridge never accepts raw passwords from Sleela source or places credentials on command lines.
wifiDisconnectint wifiDisconnect()No description in source.
wifiStatusNameString wifiStatusName(int status)No description in source.
setSuggestedvoid setSuggested(boolean suggested)Mark this as the SINGLE suggested (accent) action in its group.
setDestructivevoid setDestructive(boolean destructive)Mark this as destructive (uses the danger colour on hover).
setFontvoid setFont(SLFont font)Give this text widget a styled SLFont so its label renders with the font's effects (shadows, glow, outline, relief, gradient). The widget borrows the font. Pass null to revert to plain theme text.

SLWindow #sleela 2.5 (lib/user-interface/SLWindow.sleela)

SLWindow class

Defines SLWindow — a top-level SleelaUI window opened from SLeeLa source. It wraps the toolkit's window built-ins: uiWindowCreate (bound to an application + theme), uiWindowShow/Hide, uiWindowSetTitle, uiWindowRoot (the root container to add widgets to), uiWindowSetTheme, and uiWindowRedraw. Underneath, the VM calls the SleelaUI C ABI, which creates a real native window (X11/Cocoa/Win32) and paints it with the toolkit's own software rasterizer, so the window looks identical on every platform. Lifecycle: configureOn(app, title, w, h, theme) is called by SLUserInterface; then show(), set the title, add widgets to root(), and the application's run loop drives it. A window is a VM-local handle (-1 = none). Family: user-interface. Native VM/UI work crosses the explicit `ui*` SLVM bridge.

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
windowint windowVM-local window handle (-1 = none)
rootint rootVM-local handle of the window's root container widget
titleString titleNo description in source.
MIN_WINDOW_Wstatic final int MIN_WINDOW_W = 160---- assumed starting size + full-screen intent ------------------------- Absolute assumed floor for a usable native window, mirroring the pure-SLeeLa lib/ui/SLLayoutFrame floor so both UI systems agree on "at least so large".
MIN_WINDOW_Hstatic final int MIN_WINDOW_H = 120No description in source.
FULLSCREENstatic final int FULLSCREEN = 100000A very large extent treated as "fill the screen" when a real screen size is not known. A native host that knows its monitor passes the true pixels to configureFullscreen() instead of relying on this sentinel.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
configureOnvoid configureOn(int app, String windowTitle, int width, int height,Called by SLUserInterface.openWindow(). themeHandle -1 selects the built-in Slick Black default theme.
validboolean valid()No description in source.
rootWidgetSLWidget rootWidget()The root container widget. Add boxes/controls to this to build the UI.
rootHandleint rootHandle()Raw root handle, for widget constructors that attach to a parent handle.
showvoid show()No description in source.
hidevoid hide()No description in source.
setTitlevoid setTitle(String t)No description in source.
windowTitleString windowTitle()No description in source.
setThemevoid setTheme(int themeHandle)Swap the whole palette live (pass an SLTheme handle).
requestRedrawvoid requestRedraw()Ask the toolkit to repaint this window on the next turn.
setBufferingvoid setBuffering(int mode)Presentation buffering: how a painted frame reaches the screen. 0 = single (direct blit; may tear on resize) 1 = double (one off-screen back buffer; frame lands atomically) 2 = triple (two back buffers; default for SLeeLa GUI setup) Programs can override this with setBuffering(mode).
bufferingint buffering()No description in source.
setMinSizeint setMinSize(int width, int height)No description in source.
setMaxSizeint setMaxSize(int width, int height)No description in source.
setSizeLimitsint setSizeLimits(int minWidth, int minHeight, int maxWidth, int maxHeight)No description in source.
minWidthint minWidth()No description in source.
minHeightint minHeight()No description in source.
maxWidthint maxWidth()Maximum getters return 0 for unbounded and -1 when the window is invalid.
maxHeightint maxHeight()No description in source.
assumeSizeint assumeSize(int assumedW, int assumedH)No description in source.
configureAssumedvoid configureAssumed(int app, String windowTitle, int assumedW, int assumedH,No description in source.
configureFullscreenvoid configureFullscreen(int app, String windowTitle, int screenW, int screenH,No description in source.
handleint handle()No description in source.

sociology #sleela 2.5 (lib/user-interface/example/science/sociology.sleela)

ScienceSociology class

Methods — the actions this unit can perform.

MethodSignatureWhat it does
bannervoid banner(String t)No description in source.
mainvoid main()No description in source.