imsd-messages/interfaces
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Jorijn van der Graaf dd1108da58
main: show the window; --screenshot and --quit-after
The executable shows the window at start unless --daemon (which
--headless and --send imply), on Activate and Open from a second launch
or a notification (of the URIs an Open carries, its first sms: link),
and on an sms: link, which opens the conversation of its first recipient
at once (Number's SmsUriRecipient: the scheme in any case, the fields
after '?' dropped, percent-escapes decoded; then ConversationKey with
the country code known at that moment — --country's, else the one imsd's
status gave once it is in, else what the number itself carries — which
takes NormalizeNumber's result as a phone number — E.164, or digits: a
short code, a national number no country code completed — and nothing
else), or just the window when it names no phone number; the
conversation remembers the address as dialled and the plan of the SIM it
was typed under, and that SIM's statuses move its key (Number's
AfterStatus, one step, applied in App::Status: another SIM's status —
another operator's, or without operators another own number's code,
Number's SameSim — changes nothing, so a SIM change leaves the key and
the plan the address was typed under; the same SIM's fills in what the
plan lacks, and the key follows from its digits to the centre's stand-in
and from any key to the own number's code once the plan has it, never
from one stand-in's key to another's and not while the code is lost, the
conversation it moves to shown at its latest message — and only while
nothing is stored under the key: a text stored before the code arrived
keeps the conversation on the key its rows carry). The shell forwards
Sync's events to the window and the notifier closes a conversation's
notification when it is opened (one closed while its Notify is on its
way goes when the answer comes). --screenshot renders one frame outside
the compositor's pacing 2.5 s after start — 600 ms later where it has to
make the window first — and saves it as a PNG before quitting, or ends
with exit 1 when no frame was captured — with a line when no window
could render it or another instance is running (a flag that acts on the
window finds none there: the run forwards nothing), and without one when
the run ended before the capture (the display gone, a close that quits);
a PNG the library cannot write is not noticed at this commit, and a
capture that throws ends the process — the verification path for a
machine without eyes, which must not depend on a desktop that repaints —
and --quit-after ends a bench on its own clock (a number of seconds its
timer can take: anything else is refused); a --send errand ended by
anything but its final state — that clock — exits 2, as it does on a
signal, its end latched before the loop stops; --screenshot beside
--send or --quit is refused, neither having a window. The window is torn
down in order before the bus client stops, and when the compositor's
connection breaks the process ends, so the next launch starts afresh. A
window the library cannot make (no display, no Vulkan driver) is logged
by Ui's Show and the start ends with exit 1, as a start without its
database does; a resident instance logs it and runs on without one, and
a later Activate or Open logs the same at once, the device's set-up
running only once.

Tested: tests/Number, the sms: links (a query, an escape, a list, the
scheme in capitals, no number), the keys of typed addresses, SameSim
(the same operator, another operator of one country, a status without
its operator, nothing known, own numbers' codes without operators) and
AfterStatus through the statuses a typed address meets: the stand-in
completing its digits while the plan learns the operator; another
stand-in, a lost code and another operator's status — its own number's
code the stand-in's or not — changing nothing; rows keeping the key
while the plan learns the code; the own number's code moving the
stand-in's key, at once or once nothing is stored; a key the own
number's code made, and its plan, staying under another SIM and under
its own SIM's stand-in; an own code that makes the stand-in's key; a
short code; --country before the operator; no operators; no address; an
international address, under another SIM and under its own; and the
address as dialled making the key the address as typed made.
2026-11-18 01:12:27 +01:00
..
ImsdMessages-Gesture.cppm Gesture: taps, long presses, drags and flings from pointer phases 2026-11-18 01:12:27 +01:00
ImsdMessages-Model.cppm Model: messages, conversations and the banner 2026-11-17 22:24:23 +01:00
ImsdMessages-Number.cppm main: show the window; --screenshot and --quit-after 2026-11-18 01:12:27 +01:00
ImsdMessages-Store.cppm Store: the message database on Crafter.DB 2026-11-18 01:12:27 +01:00
ImsdMessages-Sync.cppm main: the resident daemon mode, the send errand and one instance 2026-11-18 01:12:27 +01:00
ImsdMessages-Time.cppm Time: ISO 8601 stamps, civil dates and the captions 2026-11-17 06:14:18 +01:00
ImsdMessages-Wrap.cppm Wrap: word wrap and ellipsis over a measure function 2026-11-17 06:14:18 +01:00
ImsdMessages.Bus-Client.cppm Bus: the GDBus client, imsd's dictionaries, the notifier and the owned name 2026-11-18 01:12:27 +01:00
ImsdMessages.Bus-Instance.cppm Bus: the GDBus client, imsd's dictionaries, the notifier and the owned name 2026-11-18 01:12:27 +01:00
ImsdMessages.Bus-Notifier.cppm main: show the window; --screenshot and --quit-after 2026-11-18 01:12:27 +01:00
ImsdMessages.Bus-Variant.cppm Bus: the GDBus client, imsd's dictionaries, the notifier and the owned name 2026-11-18 01:12:27 +01:00
ImsdMessages.Bus.cppm Bus: the GDBus client, imsd's dictionaries, the notifier and the owned name 2026-11-18 01:12:27 +01:00
ImsdMessages.cppm Ui: the window on Crafter.Graphics, driven from the GLib main loop 2026-11-18 01:12:27 +01:00
ImsdMessages.Ui-App.cppm main: show the window; --screenshot and --quit-after 2026-11-18 01:12:27 +01:00
ImsdMessages.Ui-Canvas.cppm Ui: the window on Crafter.Graphics, driven from the GLib main loop 2026-11-18 01:12:27 +01:00
ImsdMessages.Ui-Loop.cppm Ui: the window on Crafter.Graphics, driven from the GLib main loop 2026-11-18 01:12:27 +01:00
ImsdMessages.Ui-Screens.cppm main: show the window; --screenshot and --quit-after 2026-11-18 01:12:27 +01:00
ImsdMessages.Ui.cppm Ui: the window on Crafter.Graphics, driven from the GLib main loop 2026-11-18 01:12:27 +01:00