Continues the build order past Options/Scheduler/Speed Limiter/Batch/ Grabber/tray. - DropTargetWidget: frameless always-on-top drop target (docs/03-gui-spec.md §5), position persisted, accepts a dropped http(s) URL or link text and opens FileInfoDialog directly (skipping Add URL, since the URL is already known). Shown/hidden from general.showDropTarget, live via event.settings.changed, same pattern MainWindow already used for general.minimizeToTray. - Clipboard, explicit path #2 (docs/06-risks-and-spikes.md R2): GlobalShortcut wraps org.freedesktop.portal.GlobalShortcuts (CreateSession -> BindShortcuts -> Activated), triggering the same Add URL flow. Guarded end-to-end on `if(TARGET Qt6::DBus)` / VELOX_GUI_HAVE_DBUS so a build without the component degrades to "feature skipped," not broken (gui/docs/pkg-qa-requests-m1.md R4). Best-effort by design per the risk doc: fails silent, never advertised. Verified live against the real portal (a real Wayland session, not just offscreen): `CreateSession` refuses every caller with "An app id is required" — reproduced identically via a bare `busctl` call with no Qt involved at all, so this is the portal requiring a sandboxed caller identity, not something fixable from an unconfined process. Recorded as a partial Spike S2 answer in docs/06-risks-and-spikes.md: this explicit path likely doesn't work for Velox as a traditionally-packaged app on stock GNOME, only if/when it ships confined. Also fixed a real leak this verification caught: QDBusInterface's introspection cache reads as a LeakSanitizer leak the first time anything touches D-Bus (tst_rtl went red under ASan) — switched to QDBusMessage::createMethodCall, which needs no introspection. - Theming (docs/03-gui-spec.md §7): gui/resources/qss/{idm-like,dark}.qss, each with a documented palette block up top (QSS itself has no variable syntax), applied by ThemeManager and kept live via QStyleHints::colorSchemeChanged. util/Theme.hpp gives the handful of inline C++ styles (status dot, offline banner, the eleven identical error-label styles across dialogs) named constants instead of a twelfth copy of the same hex. - UiThreadWatchdog: the M1 DoD's 200 ms debug-build watchdog. A background std::thread pings the UI thread every 50 ms via a queued invokeMethod and warns once (not per-poll) if a ping goes unanswered past 200 ms; no QThread, no Qt event loop of its own, so the watchdog itself can never be what blocks the thread it watches. No-op in a release build. Proven both ways in tst_uithreadwatchdog: fires on a genuinely blocked UI thread (synchronous sleep, no processEvents) and stays silent on a responsive one. Full non-conformance suite (55 tests across every lane, `ctest -LE conformance`) passes clean at this point, including the whole gui label under ASan+UBSan. Co-Authored-By: Claude Sonnet 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01NSCdCWFXBTSBBK3MzWtJiC
120 lines
2.9 KiB
Plaintext
120 lines
2.9 KiB
Plaintext
/* Velox — light theme. Lane GUI.
|
|
*
|
|
* docs/agents/AGENT-GUI.md build order step 8: "colours in one variables block at the
|
|
* top of the QSS; no hard-coded hex scattered through widget code." QSS itself has no
|
|
* variable syntax (Qt has never added one), so this block is the actual palette, kept in
|
|
* one place and referenced from every rule below by comment rather than repeated ad hoc —
|
|
* every hex value that appears more than once below is listed here first. dark.qss is
|
|
* structured identically with its own values, so the two stay easy to diff against each
|
|
* other when one changes.
|
|
*
|
|
* --- palette -----------------------------------------------------------------------
|
|
* --bg #f4f5f7 window and dialog background
|
|
* --surface #ffffff table/tree, input field backgrounds
|
|
* --surface-alt #eef0f3 alternating row colour
|
|
* --border #d3d7dc panel/header/input borders
|
|
* --text #202225 primary text
|
|
* --text-muted #6b7078 secondary text (headers, disabled)
|
|
* --accent #2f7dd1 selection, focus ring, progress fill
|
|
* --accent-hover #3f8ce0 hovered accent (buttons, tabs)
|
|
* -------------------------------------------------------------------------------------
|
|
*/
|
|
|
|
QMainWindow, QDialog {
|
|
background: #f4f5f7;
|
|
color: #202225;
|
|
}
|
|
|
|
QTreeView, QTableView, QListView {
|
|
background: #ffffff;
|
|
alternate-background-color: #eef0f3;
|
|
color: #202225;
|
|
border: 1px solid #d3d7dc;
|
|
selection-background-color: #2f7dd1;
|
|
selection-color: #ffffff;
|
|
}
|
|
|
|
QHeaderView::section {
|
|
background: #eef0f3;
|
|
color: #6b7078;
|
|
border: none;
|
|
border-right: 1px solid #d3d7dc;
|
|
border-bottom: 1px solid #d3d7dc;
|
|
padding: 4px 6px;
|
|
}
|
|
|
|
QLineEdit, QPlainTextEdit, QSpinBox, QComboBox {
|
|
background: #ffffff;
|
|
border: 1px solid #d3d7dc;
|
|
border-radius: 3px;
|
|
padding: 2px 4px;
|
|
color: #202225;
|
|
}
|
|
|
|
QLineEdit:focus, QPlainTextEdit:focus, QSpinBox:focus, QComboBox:focus {
|
|
border: 1px solid #2f7dd1;
|
|
}
|
|
|
|
QPushButton {
|
|
background: #ffffff;
|
|
border: 1px solid #d3d7dc;
|
|
border-radius: 3px;
|
|
padding: 4px 12px;
|
|
color: #202225;
|
|
}
|
|
|
|
QPushButton:hover {
|
|
border-color: #3f8ce0;
|
|
}
|
|
|
|
QPushButton:default {
|
|
background: #2f7dd1;
|
|
border-color: #2f7dd1;
|
|
color: #ffffff;
|
|
}
|
|
|
|
QPushButton:default:hover {
|
|
background: #3f8ce0;
|
|
}
|
|
|
|
QTabWidget::pane {
|
|
border: 1px solid #d3d7dc;
|
|
background: #ffffff;
|
|
}
|
|
|
|
QTabBar::tab {
|
|
background: #eef0f3;
|
|
border: 1px solid #d3d7dc;
|
|
border-bottom: none;
|
|
padding: 4px 12px;
|
|
color: #6b7078;
|
|
}
|
|
|
|
QTabBar::tab:selected {
|
|
background: #ffffff;
|
|
color: #202225;
|
|
}
|
|
|
|
QProgressBar {
|
|
border: 1px solid #d3d7dc;
|
|
border-radius: 3px;
|
|
background: #eef0f3;
|
|
text-align: center;
|
|
color: #202225;
|
|
}
|
|
|
|
QProgressBar::chunk {
|
|
background: #2f7dd1;
|
|
}
|
|
|
|
QMenu {
|
|
background: #ffffff;
|
|
border: 1px solid #d3d7dc;
|
|
color: #202225;
|
|
}
|
|
|
|
QMenu::item:selected {
|
|
background: #2f7dd1;
|
|
color: #ffffff;
|
|
}
|