关于 org 属性继承的问题

org 设置的属可以继承吗?现在的情况是:

* 阅读列表
** 读《道德经》
:PROPERTIES:
:STYLE:    habit
:END:
** 读《庄子》
:PROPERTIES:
:STYLE:    habit
:END:
...

每增加一个书目,就要设置一次 STYLE 属性,比较烦。 设置成如下:

* 阅读列表
:PROPERTIES:
:STYLE:    habit
:END:
** 读《道德经》
** 读《庄子》

这种方式 STYLE 属性没有生效,是语法不对还是要额外设置什么?下级 headline 怎么继承上级 headline 的属性?

求教,谢谢。

(setq org-global-properties '(("STYLE_ALL" . "habit")))
1 个赞

org-use-property-inheritance is a variable defined in org.el.

Value nil

Toggle Set Customize

Documentation Non-nil means properties apply also for sublevels.

This setting is chiefly used during property searches. Turning it on can cause significant overhead when doing a search, which is why it is not on by default.

When nil, only the properties directly given in the current entry count. When t, every property is inherited. The value may also be a list of properties that should have inheritance, or a regular expression matching properties that should be inherited.

1 个赞