第 10 章 設定檔說明

Last Updated: 2026-10-24 02:51 Views: 7

第 10 章 設定檔說明

WxArc 的全部使用者資料集中在一個資料夾,不寫登錄檔、不留散落檔案。

10.1 資料夾結構

~/.wxarc/
├── settings.json      # 全部設定(主題/語言/整合/背景等)
├── keymap.json        # 使用者鍵位映射(有自訂時存在)
├── themes/            # 自訂主題(有自訂時存在)
└── logs/              # 按日輪替的日誌
    └── app_YYYY-MM-DD.log

Windows 上位於 %APPDATA%\wxarc\,macOS 上位於 ~/Library/Application Support/wxarc/。

10.2 settings.json

JSON 格式,主要設定區段:

鍵 說明
options.language 介面語言代碼
options.themeSwitchMode 主題切換方式(followSystem / byTime / disabled)
options.uiDarkTheme / options.uiLightTheme 自動切換的深/淺主題名
options.darkThemeStartTime / options.lightThemeStartTime 時段切換起止時刻
options.themeFontFamily / options.themeFontSize 主題字型與字型大小
options.backgroundImageMode / backgroundImagePath / backgroundImageOpacity 背景圖片(模式/路徑/透明度)

設定對話框儲存時會重寫此檔案;手動修改後重啟生效。檔案損壞時 自動回退預設設定。

10.3 日誌

日誌按日輪替,release 版預設只記錄 Error 等級;排查問題時用 wxarc --debug 啟動可提升至 Debug 等級(或 --log-level trace)。 遇到問題回報時,附上 ~/.wxarc/logs/ 當天日誌最有幫助。

10.4 重設

離開 WxArc 後刪除 ~/.wxarc/ 資料夾即恢復出廠狀態(壓縮檔本身 不受影響)。

← Previous Article 第 9 章 快速鍵與命令列 Next Article → 第 11 章 常見問題

Comments

No comments yet