store history using sqlite, add suggestion with open

This commit is contained in:
2026-10-15 23:22:32 +02:00
parent a841178cf7
commit 13c1488b0e
12 changed files with 435 additions and 5 deletions
+14 -2
View File
@@ -67,6 +67,11 @@ Like qutebrowser, keys mean different things depending on the mode:
The command line keeps a history (`Up`/`Down`) and aborts on `Escape`, `Ctrl-c`,
or if you delete the leading `:`.
While typing `:open` (or `:o`), a completion list of previously visited pages
appears above it, most recent first. Every word you type must appear in the URL
or the title. `Tab` / `Shift-Tab` cycle through the list and put the selected URL
on the command line; `Enter` opens it.
## Hint mode
`f` labels every clickable element in the viewport with home-row letters
@@ -82,7 +87,12 @@ shadow DOM yet.
## Browsing data
Cookies, local storage and history are kept in a persistent QtWebEngine profile
Browsing history is kept in `~/.local/share/att/att/history.sqlite` (tables
`visits`, one row per page load, and `urls`, one row per URL for completion).
A page is recorded once it finishes loading, so redirect hops and in-page
`#anchor` jumps don't create entries. `:history-clear` empties it.
Cookies, local storage and Chromium's own state are kept in a persistent QtWebEngine profile
under `~/.local/share/att/att/QtWebEngine/default` (the cache is in
`~/.cache/att/att/`). Session cookies are saved too, like qutebrowser's
`content.cookies.store`, so you stay logged in across restarts. Delete that
@@ -104,7 +114,7 @@ on, for when a site breaks.
## Commands
`:open <url|query>` (alias `:o`), `:quit` (alias `:q`), `:reload`, `:back`,
`:forward`, `:stop`, `:adblock-update`, `:adblock-toggle`.
`:forward`, `:stop`, `:history-clear`, `:adblock-update`, `:adblock-toggle`.
`:open` accepts a full URL, a bare host (`example.com` → `https://example.com`),
an existing local path, or free text, which goes to DuckDuckGo.
@@ -118,6 +128,8 @@ an existing local path, or free text, which goes to DuckDuckGo.
| `src/main.cpp` | `QApplication`, CLI parsing, stylesheet |
| `src/browserwindow` | the window, mode state machine, key dispatch, commands |
| `src/commandline` | the `:` prompt |
| `src/history` | SQLite browsing history |
| `src/completionview`| the `:open` completion list |
| `src/statusbar` | mode / URL / progress line |
| `src/adblock` | request interceptor around the adblock engine |
| `adblock/` | Rust crate: C API over adblock-rust, built by Corrosion |