No description
  • Emacs Lisp 78.4%
  • Python 20.9%
  • Makefile 0.6%
Find a file
Kinneyzhang 0e2ad46f70
Some checks failed
Repository structure / structure (push) Has been cancelled
fix(agenda): put every row on the sheet's grid and follow the theme
Rows, region titles and empty hints each started on a column of their own, so
nothing lined up: the mark sat left of the title it belonged to, the entry
touched the mark, and a two-digit row number wrapped in a gutter one column
wide.  The grid is the sheet's now — the key or the row number in the first
three columns, the region's title and a row's mark on the next two, the entry
one step further in — and the key always takes its three columns whatever the
cap's own width is, so a title lands on the mark's column.

The rail divider was a painted column a whole character wide.  It is a
hairline: a one-pixel border in the theme's divider colour, with the grab strip
around it invisible until the pointer is on it, which is how the rest of the
catalog separates surfaces.

A theme switch now repaints a mounted application.  Every colour is resolved
through one reader that reads Emacs' switch generation, so the render is tied
to the switch, and the provided Theme is a computed instead of a plist that
froze the palette of the theme active at mount.

Validation: make check in etaf-agenda (structure gate, compilation with
warnings as errors, 14 ERT scenarios, 10 public declarations); in a real
graphical session the layout captured in the dark theme, then `load-theme
modus-operandi` repainted it light in place, then `modus-vivendi` repainted it
dark again, with the row grid and hairline dividers unchanged.
2026-10-29 15:37:22 +08:00
.githooks feat(agenda): six pages over one model, table and key map 2026-10-29 01:04:37 +08:00
.github/workflows feat(agenda): six pages over one model, table and key map 2026-10-29 01:04:37 +08:00
lisp fix(agenda): put every row on the sheet's grid and follow the theme 2026-10-29 15:37:22 +08:00
scripts feat(agenda): six pages over one model, table and key map 2026-10-29 01:04:37 +08:00
tests fix(agenda): keep the whole application in one canvas 2026-10-29 15:06:50 +08:00
.editorconfig feat(agenda): six pages over one model, table and key map 2026-10-29 01:04:37 +08:00
.gitignore feat(agenda): rewrite the day page around regions, keys and an anchored overlay 2026-10-28 22:38:15 +08:00
CHANGELOG.md fix(agenda): put every row on the sheet's grid and follow the theme 2026-10-29 15:37:22 +08:00
etaf-agenda.el feat(agenda): six pages over one model, table and key map 2026-10-29 01:04:37 +08:00
Makefile feat(agenda): six pages over one model, table and key map 2026-10-29 01:04:37 +08:00
README.md fix(agenda): put every row on the sheet's grid and follow the theme 2026-10-29 15:37:22 +08:00

etaf-agenda

一个基于 ETAF 的个人日程应用。今天、日历、清单、 项目、习惯、回顾六页共用一份模型:条目写进本地 SQLite,每天的状态记成一条实例,配色全部取自 当前主题,界面只用 frame 自己的字号。

要求

  • Emacs 29.1 或更新版本。
  • 提供者检出:etaf、etaf-ui、ebox、ecss、etaf-db。把它们放在本仓库旁边 (../etaf 等),或放进工作区的上级目录(../../etaf 等)。

安装与运行

把本仓库根和提供者的仓库根加进 load-path,然后:

(require 'etaf-agenda)
M-x etaf-agenda-open

数据库默认在 ~/.emacs.d/etaf-agenda/agenda.sqlite3,第一次打开时自动建表;etaf-agenda-open 也可以直接收一个文件路径。旧版(schema 1)的库打开时自动迁移到 schema 2。

整个应用是一个缓冲区里的一张布局:顶栏、左右两条栏、中间的页面都是这张布局的盒子。 左右两栏的宽度存在模型里(默认 24 与 26 列),拖动栏与页面之间那条分隔线就能改宽窄, 指针落在线上时变成左右箭头。模式行保留,颜色全部取自当前主题的脸,应用自己不画背景;中途换主题(load-theme)会就地重画,不用重开。

六页

页 内容
今日 逾期、日程、待办、记录、已迁移五区,左边是领域,右边是本周
日历 整月格子加选中那天的事件与待办
清单 按时间、领域、项目或状态分组
项目 一个项目的阶段、条目和完成度
习惯 最近三周的打卡条,一格一天
回顾 这个月的完成、新建、迁移、放弃与空白日

尺寸

界面按 148×42 的 frame 设计,128 列是最窄的可用宽度。左右两栏默认 24 与 26 列,改宽会把多出来 的列给栏里的名字,改窄就先截断名字;中间列再窄会压缩留白并裁切,不会折行或重叠。习惯页的一格 一天固定两列,日历格固定九列,两者都不随窗口拉伸。

按键

页面之间用数字键切(没有区被选中时);区键是大写字母,只对当前页有效;j / k 在区里走行, 没有区选中时自动进第一个有内容的区。

键 作用
1 … 6 切到第 N 页
区键(大写) 进入这一区
j / k 下一条 / 上一条
1 … 9 进入区后直接选第 N 条
a 在区里原位新建
e 改这条的标题
x 勾完成(习惯页是给今天打卡)
m / z / d 迁移到明天 / 放弃 / 删除
RET 打开这条的详情浮层
Esc 收起浮层;再按一次退出区
h / l / t 前一天 / 后一天 / 回到今天
? 快捷键帮助

etaf-agenda-capture 也收一行自然语言:明天 15:00 看牙医 #健康 !2 @工作。

开发

make check     # 结构 + 字节编译 + 验收场景
make test      # 只跑验收场景
make clean

界面改动必须真实 GUI 验收;清单与做法见 pi-skill etaf-app-dev guide verify。 存储决策与模式见 pi-skill etaf-app-dev guide storage。