Opening and viewing#

How gloss starts and what it draws with: the file menu and preview pane, terminal graphics, the screen it uses, which files it finds, and what it may fetch. gloss fetches only an http(s) address you name on the command line, or one you choose inside a document with –fetch; GLOSS_NO_FETCH in the environment forbids both.

OptionArgumentDefaultDescription
--strictrequire OS confinement for supported document loads (still images, SVG, Mermaid, PDF)
-m, --menustart with the file-selection menu
-P, --previewstart with the file menu and a preview pane
-r, --renderstring"auto"terminal graphics: auto, kitty, glyph
--themestring"auto"Colors: auto, catppuccin-latte, catppuccin-mocha, dark, dracula, gruvbox-dark, gruvbox-light, light, monokai, nord, one-dark, rose-pine, solarized-dark, solarized-light, tokyo-night, or theme JSON file
--langstringlanguage of gloss’s own words and number formats (BCP 47 or POSIX, e.g. es, zh-Hans, de_DE); options stay English
-X, --no-alt-screendraw on the main screen: scrollback is kept, and the last view stays after quitting
--printprint one content viewport to stdout and exit; pictures use ANSI-colored half-blocks, no terminal required
--print-widthintwith –print, viewport columns (1–512; default terminal width or 80)
--print-heightintwith –print, viewport rows (1–256; default terminal height or 24)
--qrstringshow this text, such as a URL, as a QR code instead of a file, to scan with a phone or tablet; with –serve, on a web page; nothing is fetched
-t, --typestringforce input type: image, svg, pdf, stl, 3mf, obj, ply, docx, xlsx, grist, csv, json (or jsonl, ndjson), ipynb, html, text, markdown (or md), mermaid, video, geojson, gpx, pmtiles
--globstringArraysearch the folders named, or the current one, for files: a glob, an extension, or a kind such as images (repeatable)
--fetchallow opening a dropped URL or a table address with Enter, and the map provider named in GLOSS_MAP_TILES and GLOSS_GEOCODER; an address named on the command line needs no option, and GLOSS_NO_FETCH forbids both
--user-agentstringwhat downloads send as their User-Agent; else $GLOSS_USER_AGENT, else gloss and its version

Examples#

# Print one view into captured shell output
gloss --print --print-width 80 photo.png

# Hand a link to a phone: show it as a QR code on a web page
gloss --serve --qr https://example.com/

# Look at some files, with a menu to choose among them
gloss --menu photo.png report.pdf model.stl

# A menu with a preview pane
gloss --preview *.png

# Every image under the current folder
gloss --glob images

# A file whose name does not say what it is
gloss --type markdown notes