# SleelaTerminal™ Graphical Terminal SLeeLa provides a dedicated graphical terminal window for the SleelaTerminal™ shell. ## Architecture ```text SleelaTerminal GUI │ ├── GTK 4 window ├── VTE terminal widget └── PTY │ ▼ slsh │ ▼ SLeeLa shell ``` The GUI is a terminal emulator front end, not a second shell implementation. It starts the existing `slsh` executable inside a pseudo-terminal, preserving the existing command parser, executor, builtins, pipelines, jobs, M5 features, and shell behavior. VTE supplies the virtual terminal widget and PTY integration used by GTK terminal applications. ## Settings menu The right of the title bar carries a small, quiet gear button for settings. It is flat (no loud outline — only a soft hover tint) and opens the Settings as a dedicated modal subframe window, so configuration does not require a permanent side panel or toolbar and stays on screen while the user adjusts it. The window controls — minimize, maximize, and close — are shown on the right of the title bar and are **lit for visibility**: each is a distinct rounded button carrying a bright, fully-opaque white glyph so the icons read clearly against the dark purple chrome. Close additionally lights up red on hover as an unmistakable affordance. The menu currently provides: - font family and size choices; - terminal font/foreground color choices; - input/output language orientation; - declared national/channel feed categories; - declared persons-of-interest categories; - declared parametric document/résumé categories; and - declared national-identifier categories. The terminal remains the centered primary workspace. Text selection and copy/paste remain available through the terminal's contextual right-click menu. ## Parametric Ring of Trust / Orientation The settings model treats these source categories as local, human-readable declarations. They describe an orientation between a terminal, a parameter, and a possible information source. They do **not** independently establish identity, authority, truth, provenance, legal status, or trust. The current implementation deliberately keeps source switches off by default. Enabling a switch records the user's local configuration choice; it does not silently fetch, transmit, authenticate, identify, or ingest a source. This gives future feed, document, or identity-adapter work a clear extension point without making external data acquisition part of the terminal's presentation layer. ## Configuration Settings are loaded and saved in a simple text configuration file: ```text ~/.config/sleela/sleela-terminal.conf ``` An example schema is provided in `sleela-terminal.conf.example`. The file uses straightforward `key=value` entries so it can be inspected or edited without a specialized configuration editor. Two appearance options control the UI grays (each a literal `#RRGGBB`; an invalid value falls back to the built-in default and is ignored): - `ui_gray` — the standard UI gray used for secondary chrome controls. The **"+" new-tab button** (which sits at the left of the tab strip) is painted in this gray. Default `#626262`. - `textpane_gray` — the darker gray that sits directly behind the terminal text pane (the terminal panel and the VTE surface). Default `#262626`. ## Build From `sleela-terminal`: ```sh make all-gui ``` `make gui` builds only the GUI executable (and its `slsh` dependency); `make all-gui` builds the CLI, smoke-test executable, and GUI. The executable is: ```text build/SleelaTerminal ``` The default `make` target builds the CLI shell and smoke-test executable only. The GUI is an optional target and requires GTK 4 and VTE development packages. ## Run Build the GUI first with `make gui` or `make all-gui`, then run: ```sh ./build/SleelaTerminal ``` The GUI automatically looks for `slsh` beside itself, so the development build launches `build/slsh`. An explicit shell path may also be supplied: ```sh ./build/SleelaTerminal ./build/slsh ``` ## Branding and visual frame The application window is branded: ```text SleelaTerminal™ — MEARVK LLC ``` The upper-left of the title bar carries the SleelaTerminal brand logo (the Debian/Windows-terminal mark). The asset is pre-trimmed to the logo's minimum 2D content bounding box with a transparent background, so it sits flush at the left edge with no surrounding whitespace. It is a strict image — no button outline — and is produced by `tools/logo/Trim.java` from the source artwork in `images/`. The title bar keeps its branded purple-to-blue gradient, while every interactive selection surface—the Settings subframe, software popover, and terminal right-click menu—uses the same deep-blue/light-blue family as the main frame. Menu text stays white, hover and active states brighten in blue, and keyboard focus uses a visible light-blue outline so selection states remain clear. The **"+" new-tab button** is not in the title bar; it sits at the **left of the tab strip** (the notebook's start action widget) and is painted in the standard UI gray (`ui_gray`, default `#626262`) so it reads as part of the gray chrome. Clicking it, or `Ctrl+Shift+T`, opens a new terminal tab. The bottom edge of the title bar carries a **4px green lightbar** across the terminal's full width. It rests on the project green (`#115C28`) and hosts a single pulse of light that is **logarithmically centred** on the bar: the lit glow is seeded at the centre and **grows outward in width** on a logarithmic curve — the widening is the thing observed — at a slow heartbeat (a calm ~5.5 s breath). At the **peak** of its expansion the lit glow fades back to the original green, then the cycle restarts; because the colour has returned to the base green exactly when the pulse is widest, the reset is seamless. The lightbar is a title-bar indication only and casts no colour spill onto the terminal pane. Every artistic parameter of the pulse — the base and glow greens, the pulse frequency, the start/peak widths, the logarithmic growth shape, and the peak brightness — is a conserved named constant in the `lightbar` configuration namespace at the top of `sleelaterminal-gui.cpp`, so the look can be re-tuned from one place without touching the render code. The current GUI displays version `1.0.0`, matching the project's initial SleelaTerminal version baseline. The footer also contains the clickable **CMD** image, representing CMD as the Java native launcher associated with SecureJDK 28. It is rendered as a strict image with no additional footer-button outline. ## Desktop installation The CLI-only `make install` target installs `slsh`. To install the GUI and desktop launcher together with the required shell executable, build the GUI and run: ```sh make all-gui make install-all ``` The staged paths are: ```text $(PREFIX)/bin/slsh $(PREFIX)/bin/SleelaTerminal $(PREFIX)/share/applications/SleelaTerminal.desktop ``` The desktop entry declares `Terminal=false`, so launching SleelaTerminal does not wrap the shell inside another terminal emulator. ## Runtime validation boundary CI currently verifies that the GTK4/VTE GUI compiles on Ubuntu; compilation does not validate window startup, PTY interaction, keyboard input, clipboard behavior, or close/restart lifecycle. Before calling the GUI runtime-validated on a desktop, manually test: launch and close; run a command and verify its exit status; resize the window; type/paste/select/copy text; open and dismiss Settings; close the window while a foreground child is running; and confirm the child and GUI exit cleanly. Linux/macOS CLI CI does not claim native Windows support. ## Dependencies The graphical target requires GTK 4 and the GTK 4 VTE development package. On Debian/Ubuntu systems the corresponding development packages are typically named: ```sh sudo apt install libgtk-4-dev libvte-2.91-gtk4-dev ``` The existing CLI shell remains a C++17 program and does not depend on GTK or VTE. ## Title-bar gradient presets The title-bar gradient is stored in `assets/HORIZONTAL.cfg` and `assets/VERTICAL.cfg`; each preset supplies both its direction and its own color stops. Both presets use a dark-navy palette with the former white glint replaced by a narrow blue-black center grade, blended through nearby navy stops to preserve the existing linear fade and restrained 3D bevel. The active selection in `assets/GRADIENT.cfg` is `active=HORIZONTAL.cfg`, so the gradient runs left to right. Change it to `active=VERTICAL.cfg` to run the same palette from top to bottom, then restart SleelaTerminal. ## Text pane and command-result colors The surface directly behind the terminal text pane (the terminal panel and the VTE surface) uses the darker gray `textpane_gray` (default `#262626`), with light `#f2f2f2` text. The surrounding workspace that frames the panel is the same dark gray, so no lighter backing shows behind the text. Both `ui_gray` and `textpane_gray` are configuration options (see **Configuration**) and feed named CSS tokens (`sl_ui_gray`, `sl_pane_bg`); the rest of the window's purple chrome is unchanged.