Chapter 9. Configuration Files
Chapter 9. Configuration Files
All wxreader user data lives in one directory, fully separated from wxterm / wxeditor:
| Platform | Data directory |
|---|---|
| Linux / FreeBSD | ~/.wxreader/ |
| macOS | ~/Library/Application Support/wxreader/ |
| Windows | %APPDATA%\wxreader\ |
9.1 Files
| File | Purpose |
|---|---|
data.dat |
library SQLite database (WAL mode): shelf / books / notes / mark tables |
cover/{book-id}.png |
cover cache (240×320) |
settings.json |
all settings: options (theme/language/UI font/theme switching/background) + editor (reader style under the reader node) |
logs/app_{date}.log |
rolling run logs (check when troubleshooting) |
9.2 data.dat schema
| Table | Columns |
|---|---|
| shelf | id, name (unique), added_time, sort_order (drag order) |
| books | id, shelf_id (0 = ungrouped), title, path (unique, de-dup key), cover, added_time, last_read, read_seconds, progress, favorite, author, format, note |
| notes | id, book_id, page, selected_text, note_content, added_time |
| mark | id, book_id, page, selected_text, added_time |
format values: pdf / epub / mobi (incl. azw3, prc) / md / txt / chm /
img (comic folder).
9.3 settings.json structure
{
"options": {
"theme": "Tokyo Night",
"lang": "en",
"themeFontFamily": "Inter",
"themeFontSize": 12,
"themeSwitchMode": "by-time",
"uiDarkTheme": "Dark",
"uiLightTheme": "Light",
"darkThemeStartTime": "19:00",
"lightThemeStartTime": "07:00",
"backgroundImage": "/path/to/img.jpg",
"backgroundImageMode": 2,
"backgroundImageOpacity": 0.3
},
"editor": {
"reader": {
"fontSize": 18,
"lineHeight": 1.5,
"paraSpacing": 1.0,
"textAlign": 0,
"invert": false,
"brightness": 1.0,
"autoScroll": false,
"scrollInterval": 3,
"viewMode": 0
}
}
}
9.4 Progress semantics
books.progress (1-based) means different things per format:
| format | progress meaning |
|---|---|
| epub / mobi / md / txt | chapter number |
| page number | |
| img | image index in recursive reading order |
| chm | always 1 |
read_seconds is accumulated reading time (+60 every 60 seconds while
a reader window is alive).