This is the official manual for the latest Org-mode release.

Table of Contents

Next: , Previous: Customization, Up: Miscellaneous


15.6 Summary of in-buffer settings

Org mode uses special lines in the buffer to define settings on a per-file basis. These lines start with a ‘#+’ followed by a keyword, a colon, and then individual words defining a setting. Several setting words can be in the same line, but you can also have multiple lines for the keyword. While these settings are described throughout the manual, here is a summary. After changing any of those lines in the buffer, press C-c C-c with the cursor still in the line to activate the changes immediately. Otherwise they become effective only when the file is visited again in a new Emacs session.

#+ARCHIVE: %s_done::
This line sets the archive location for the agenda file. It applies for all subsequent lines until the next ‘#+ARCHIVE’ line, or the end of the file. The first such line also applies to any entries before it. The corresponding variable is org-archive-location.
#+CATEGORY:
This line sets the category for the agenda file. The category applies for all subsequent lines until the next ‘#+CATEGORY’ line, or the end of the file. The first such line also applies to any entries before it.
#+COLUMNS: %25ITEM ...
Set the default format for columns view. This format applies when columns view is invoked in locations where no COLUMNS property applies.
#+CONSTANTS: name1=value1 ...
Set file-local values for constants to be used in table formulas. This line sets the local variable org-table-formula-constants-local. The global version of this variable is org-table-formula-constants.
#+FILETAGS: :tag1:tag2:tag3:
Set tags that can be inherited by any entry in the file, including the top-level entries.
#+DRAWERS: NAME1 ...
Set the file-local set of additional drawers. The corresponding global variable is org-drawers.
#+LINK: linkword replace
These lines (several are allowed) specify link abbreviations. See Link abbreviations. The corresponding variable is org-link-abbrev-alist.
#+PRIORITIES: highest lowest default
This line sets the limits and the default for the priorities. All three must be either letters A–Z or numbers 0–9. The highest priority must have a lower ASCII number than the lowest priority.
#+PROPERTY: Property_Name Value
This line sets a default inheritance value for entries in the current buffer, most useful for specifying the allowed values of a property.
#+SETUPFILE: file
This line defines a file that holds more in-buffer setup. Normally this is entirely ignored. Only when the buffer is parsed for option-setting lines (i.e., when starting Org mode for a file, when pressing C-c C-c in a settings line, or when exporting), then the contents of this file are parsed as if they had been included in the buffer. In particular, the file can be any other Org mode file with internal setup. You can visit the file the cursor is in the line with C-c '.
#+STARTUP:
This line sets options to be used at startup of Org mode, when an Org file is being visited.

The first set of options deals with the initial visibility of the outline tree. The corresponding variable for global default settings is org-startup-folded, with a default value t, which means overview.

          overview         top-level headlines only
          content          all headlines
          showall          no folding of any entries
          showeverything   show even drawer contents

Dynamic virtual indentation is controlled by the variable org-startup-indented1

          indent     start with org-indent-mode turned on
          noindent   start with org-indent-mode turned off

Then there are options for aligning tables upon visiting a file. This is useful in files containing narrowed table columns. The corresponding variable is org-startup-align-all-tables, with a default value nil.

          align      align all tables
          noalign    don't align tables on startup

When visiting a file, inline images can be automatically displayed. The corresponding variable is org-startup-with-inline-images, with a default value nil to avoid delays when visiting a file.

          inlineimages   show inline images
          noinlineimages don't show inline images on startup

When visiting a file, LaTeX fragments can be converted to images automatically. The variable org-startup-with-latex-preview which controls this behavior, is set to nil by default to avoid delays on startup.

          latexpreview   preview LaTeX fragments
          nolatexpreview don't preview LaTeX fragments

Logging the closing and reopening of TODO items and clock intervals can be configured using these options (see variables org-log-done, org-log-note-clock-out and org-log-repeat)

          logdone             record a timestamp when an item is marked DONE
          lognotedone         record timestamp and a note when DONE
          nologdone           don't record when items are marked DONE
          logrepeat           record a time when reinstating a repeating item
          lognoterepeat       record a note when reinstating a repeating item
          nologrepeat         do not record when reinstating repeating item
          lognoteclock-out    record a note when clocking out
          nolognoteclock-out  don't record a note when clocking out
          logreschedule       record a timestamp when scheduling time changes
          lognotereschedule   record a note when scheduling time changes
          nologreschedule     do not record when a scheduling date changes
          logredeadline       record a timestamp when deadline changes
          lognoteredeadline   record a note when deadline changes
          nologredeadline     do not record when a deadline date changes
          logrefile           record a timestamp when refiling
          lognoterefile       record a note when refiling
          nologrefile         do not record when refiling
          logdrawer           store log into drawer
          nologdrawer         store log outside of drawer
          logstatesreversed   reverse the order of states notes
          nologstatesreversed do not reverse the order of states notes

Here are the options for hiding leading stars in outline headings, and for indenting outlines. The corresponding variables are org-hide-leading-stars and org-odd-levels-only, both with a default setting nil (meaning showstars and oddeven).

          hidestars  make all but one of the stars starting a headline invisible.
          showstars  show all stars starting a headline
          indent     virtual indentation according to outline level
          noindent   no virtual indentation according to outline level
          odd        allow only odd outline levels (1,3,...)
          oddeven    allow all outline levels

To turn on custom format overlays over timestamps (variables org-put-time-stamp-overlays and org-time-stamp-overlay-formats), use

          customtime overlay custom time format

The following options influence the table spreadsheet (variable constants-unit-system).

          constcgs   constants.el should use the c-g-s unit system
          constSI    constants.el should use the SI unit system

To influence footnote settings, use the following keywords. The corresponding variables are org-footnote-define-inline, org-footnote-auto-label, and org-footnote-auto-adjust.

          fninline    define footnotes inline
          fnnoinline  define footnotes in separate section
          fnlocal     define footnotes near first reference, but not inline
          fnprompt    prompt for footnote labels
          fnauto      create [fn:1]-like labels automatically (default)
          fnconfirm   offer automatic label for editing or confirmation
          fnplain     create [1]-like labels automatically
          fnadjust    automatically renumber and sort footnotes
          nofnadjust  do not renumber and sort automatically

To hide blocks on startup, use these keywords. The corresponding variable is org-hide-block-startup.

          hideblocks   Hide all begin/end blocks on startup
          nohideblocks Do not hide blocks on startup

The display of entities as UTF-8 characters is governed by the variable org-pretty-entities and the keywords

          entitiespretty  Show entities as UTF-8 characters where possible
          entitiesplain   Leave entities plain

#+TAGS: TAG1(c1) TAG2(c2)
These lines (several such lines are allowed) specify the valid tags in this file, and (potentially) the corresponding fast tag selection keys. The corresponding variable is org-tag-alist.
#+TBLFM:
This line contains the formulas for the table directly above the line.

Table can have multiple lines containing ‘#+TBLFM:’. Note that only the first line of ‘#+TBLFM:’ will be applied when you recalculate the table. For more details see Using multiple #+TBLFM lines in Editing and debugging formulas.

#+TITLE:, #+AUTHOR:, #+EMAIL:, #+LANGUAGE:, #+DATE:,
#+OPTIONS:, #+BIND:,
#+DESCRIPTION:, #+KEYWORDS:,
#+LaTeX_HEADER:, #+LaTeX_HEADER_EXTRA:,
#+HTML_HEAD:, #+HTML_HEAD_EXTRA:, #+HTML_LINK_UP:, #+HTML_LINK_HOME:,
#+SELECT_TAGS:, #+EXCLUDE_TAGS:
These lines provide settings for exporting files. For more details see Export settings.
#+TODO: #+SEQ_TODO: #+TYP_TODO:
These lines set the TODO keywords and their interpretation in the current file. The corresponding variable is org-todo-keywords.

Footnotes

[1] Emacs 23 and Org mode 6.29 are required