From mboxrd@z Thu Jan 1 00:00:00 1970 From: tsd@tsdye.com (Thomas S. Dye) Subject: Classification of Org mode elements Date: Sun, 16 Jun 2013 12:50:07 -1000 Message-ID: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:39435) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UoLm4-0000oP-Im for emacs-orgmode@gnu.org; Sun, 16 Jun 2013 18:50:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UoLm1-00052h-3j for emacs-orgmode@gnu.org; Sun, 16 Jun 2013 18:50:16 -0400 Received: from leka2.oceanic.com ([205.172.16.71]:32831) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UoLm0-00052M-No for emacs-orgmode@gnu.org; Sun, 16 Jun 2013 18:50:13 -0400 Received: from leka2.oceanic.com (localhost [127.0.0.1]) by localhost (Postfix) with SMTP id 2AA41E2108C for ; Sun, 16 Jun 2013 12:37:18 -1000 (HST) Received: from poto.local (unknown [205.172.16.70]) by leka2.oceanic.com (Postfix) with ESMTP id 82434E2109B for ; Sun, 16 Jun 2013 12:37:16 -1000 (HST) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Org-mode --=-=-= Content-Type: text/plain Aloha all, The attached Org mode document contains some notes on the classification of Org mode elements that might be a useful addition to Nicolas Goaziou's draft Org syntax document (http://orgmode.org/worg/dev/org-syntax.org). It distinguishes nine classes of element and proposes names for them. I'm hoping for some comments. The classification stuff makes sense to me, given my anthropology and archaeology background, but I'm not certain if it will be sensible to the Org mode community, which is mostly programmers. All the best, Tom --=-=-= Content-Type: text/x-org Content-Disposition: attachment; filename=org-syntax-element-table.org Content-Description: Notes on the classification of Org mode elements #+TITLE: org-syntax-element-table #+DATE: <2013-06-16 Sun> #+AUTHOR: Thomas Dye #+EMAIL: tsd@tsdye.com #+OPTIONS: ':nil *:t -:t ::t <:t H:3 \n:nil ^:t arch:headline #+OPTIONS: author:t c:nil creator:comment d:(not LOGBOOK) date:t e:t #+OPTIONS: email:nil f:t inline:t num:t p:nil pri:nil stat:t tags:t #+OPTIONS: tasks:t tex:t timestamp:t toc:t todo:t |:t #+CREATOR: Emacs 24.3.1 (Org mode 8.0.2) #+DESCRIPTION: #+EXCLUDE_TAGS: noexport #+KEYWORDS: #+LANGUAGE: en #+SELECT_TAGS: export * Org mode document An Org mode document contains headlines and sections. A section contains one or more elements, which are either paragraphs or are recognized by the parser as one of 28 Org mode constructs. Org mode does not distinguish different classes of headline. * Element table There are 26 different elements that can be classified according to four boolean properties: - greater :: an element that can contain another element - restricted :: an element that must be contained by another element - attributable :: an element that can have an affiliated keyword - direct object :: an element that can directly contain an object The four boolean properties describe a paradigmatic classification with 16 (2^4) classes, only nine of which are realized (table [[element-table]]). Five of the nine classes---2, 3, 4, 8, and 9---each comprise a single instance. These are referred to as "singleton classes." Two classes---6 and 7---comprise two instances. Class 1 comprises six instances and Class 5 comprises eleven instances. Nicolas Goaziou's draft [[http://orgmode.org/worg/dev/org-syntax.org][Org Syntax description]] classified the elements on the greater property, distinguishing Greater elements from Elements. The proposed class names in table [[element-table]] build on this distinction, keeping the name Greater element and substituting Lesser element for Element. Singleton classes are named after the element they comprise. Lesser elements that don't take an affiliated keyword are called Unattributable lesser elements, and lesser elements that can directly contain an object are called Direct object lesser elements. #+name: element-table | Element | Greater | Restricted | Attributable | Direct object | Class | NGZ | Proposed class names | |---------------------+---------+------------+--------------+---------------+-------+-----------------+-------------------------------| |---------------------+---------+------------+--------------+---------------+-------+-----------------+-------------------------------| | Drawer | true | false | true | false | 1 | Greater element | Greater element | | Dynamic block | true | false | true | false | 1 | Greater element | Greater element | | Footnote definition | true | false | true | false | 1 | Greater element | Greater element | | Greater block | true | false | true | false | 1 | Greater element | Greater element | | Plain list | true | false | true | false | 1 | Greater element | Greater element | | Table | true | false | true | false | 1 | Greater element | Greater element | |---------------------+---------+------------+--------------+---------------+-------+-----------------+-------------------------------| | Inline task | true | false | false | false | 2 | Greater element | Inline task | |---------------------+---------+------------+--------------+---------------+-------+-----------------+-------------------------------| | Property drawer | true | true | true | false | 3 | Greater element | Property drawer | |---------------------+---------+------------+--------------+---------------+-------+-----------------+-------------------------------| | Item | true | true | false | false | 4 | Greater element | List item | |---------------------+---------+------------+--------------+---------------+-------+-----------------+-------------------------------| | Babel call | false | false | true | false | 5 | Element | Lesser element | | Comment | false | false | true | false | 5 | Element | Lesser element | | Comment block | false | false | true | false | 5 | Element | Lesser element | | Diary | false | false | true | false | 5 | Element | Lesser element | | Example block | false | false | true | false | 5 | Element | Lesser element | | Fixed width area | false | false | true | false | 5 | Element | Lesser element | | Horizontal rule | false | false | true | false | 5 | Element | Lesser element | | Keyword | false | false | true | false | 5 | Element | Lesser element | | LaTeX environment | false | false | true | false | 5 | Element | Lesser element | | Sexp | false | false | true | false | 5 | Element | Lesser element | | Source block | false | false | true | false | 5 | Element | Lesser element | |---------------------+---------+------------+--------------+---------------+-------+-----------------+-------------------------------| | Paragraph | false | false | true | true | 6 | Element | Direct object lesser element | | Verse block | false | false | true | true | 6 | Element | Direct object lesser element | |---------------------+---------+------------+--------------+---------------+-------+-----------------+-------------------------------| | Clock | false | false | false | false | 7 | Element | Unattributable lesser element | | Planning (Plan?) | false | false | false | false | 7 | Element | Unattributable lesser element | |---------------------+---------+------------+--------------+---------------+-------+-----------------+-------------------------------| | Node property | false | true | false | false | 8 | Element | Node property | |---------------------+---------+------------+--------------+---------------+-------+-----------------+-------------------------------| | Table row | false | true | false | true | 9 | Element | Table row | --=-=-= Content-Type: text/plain -- Thomas S. Dye http://www.tsdye.com --=-=-=--