DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:refnotes:style

Back to RefNotes Plugin

RefNotes Style Reference

Every RefNotes namespace can have its own rendering style. The style is a collection of properties that define different aspects of how references and notes are rendered.

For the references the styling options are minimal: there is just the reference identifier with some additional formatting. For the notes it gets more sophisticated. A note has three major parts that can be customized: the note identifier, back references and the note text. For example:


1. ^ a, b This is the note text.

Here “1.” is the note identifier, the superscript part contains the back references that link to places on the page where this note was referenced, and the rest is the note text.

Inherit style from another namespace (inherit)

By default a namespace inherits the style from its parent. But sometimes it is convenient to override this behavior in order to get an alias to some custom-styled namespace with a long name. The inherit style serves that purpose. For example:

<refnotes t> inherit: :table:stars: </refnotes>

With this syntax you specify that references and notes in the namespace :t: should be rendered using the style of the namespace :table:stars:.

Reference/note identifier (refnote-id)

The identifier is used for rendering both references and notes. Usually this identifier is a counter that can be presented in a number of different ways. But if you plan to have a namespace with named notes where the name is more meaningful then just a counter, it is also possible to use the note name as the identifier. For example, it can be useful for bibliographical references that look like this: [Auth09a].

The following styles are supported:

  • Numeric (1) [default]
  • Latin lower case (a)
  • Latin upper case (A)
  • Roman lower case (i)
  • Roman upper case (I)
  • Stars (*)
  • Note name (name)

Reference baseline (reference-base)

The following styles are supported:

  • Superscript (sup) [default]
  • Normal text (text)

Reference font weight (reference-font-weight)

The following styles are supported:

  • Normal font (normal) [default]
  • Bold font (bold)

Reference font style (reference-font-style)

The following styles are supported:

  • Normal font (normal) [default]
  • Italic font (italic)

Reference formatting (reference-format)

This style specifies extra characters appearing around the reference identifier.

The following styles are supported:

  • Right parenthesis ()) [default]
  • Parentheses (())
  • Right bracket (])
  • Brackets ([])
  • No formatting (none)

Reference grouping (reference-group)

When multiple references are following one another (e.g. citation of multiple sources) they can be either rendered independently or grouped. In the later case the reference-format style is applied to the entire group and reference identifiers in the group are separated with comma or semicolon.

The following styles are supported:

  • Do not group references (none) [default]
  • Separate with comma (,)
  • Separate with semicolon (s)

Reference rendering (reference-render)

Selects one of available structured data renderers.

The following styles are supported:

  • Plain text (basic) [default]
  • Harvard System of Referencing (harvard)

This style will take effect only references that have structured data (defined either with structured references or in reference database). The regular references are always rendered using basic style.

Multi-reference identifier (multi-ref-id)

When multiple references to a single note are rendered, there are two ways the references can be presented. One it to assign a unique number to every reference as it is done for DokuWiki footnotes. Another one is to use the same number (the note identifier) for every reference.

The following styles are supported:

  • Reference counter (ref) [default]
  • Note counter (note)

Note that if refnote-id style is set to name this style has no effect.

Note preview (note-preview)

The note preview is a small pop-up that shows up when mouse is hovered over a reference. The pop-up can be static or follow the mouse pointer. The static pop-up is more convenient when there are clickable links in the note text, but you have to hover the mouse pointer over it to make it disappear. The dynamic tooltip disappears as soon as the mouse pointer leaves the reference.

The following styles are supported:

  • DokuWiki-style static pop-up (popup) [default]
  • A tooltip that follows the mouse pointer (tooltip)
  • No preview (none)

Notes block separator (notes-separator)

When notes are rendered, they are separated from the text above by horizontal ruler. By default the ruler width is 100% of the page but with notes-separator style you can specify the width in any CSS units (e.g. 50%, 100px, 20em, etc.)

The following styles are supported:

  • Width in CSS size units [default = 100%]
  • No separator (none)

Note text alignment (note-text-align)

The standard DokuWiki template justifies most of the text on a page, including the footnotes. It looks okay for normal text (i.e. footnotes) but not so good for book references.

The following styles are supported:

  • Justify (justify) [default]
  • Align left side only (left)

Note font size (note-font-size)

This font size is used to render all parts of a note: note identifier, back references and the note text.

The following styles are supported:

  • Normal font size, like the rest of a page (normal) [default]
  • Small font (small)

Note rendering (note-render)

Selects one of available structured data renderers.

The following styles are supported:

  • Plain text (basic) [default]
  • Harvard System of Referencing (harvard)

This style will take effect only notes that have structured data (defined either with structured references or in reference database). The regular notes are always rendered using basic style.

Note identifier baseline (note-id-base)

The following styles are supported:

  • Superscript (sup) [default]
  • Normal text (text)

Note identifier font weight (note-id-font-weight)

The following styles are supported:

  • Normal font (normal) [default]
  • Bold font (bold)

Note identifier font style (note-id-font-style)

The following styles are supported:

  • Normal font (normal) [default]
  • Italic font (italic)

Note identifier formatting (note-id-format)

Similar to the reference-format style but with an extra option to have a dot after the note identifier.

The following styles are supported:

  • Right parenthesis ()) [default]
  • Parentheses (())
  • Right bracket (])
  • Brackets ([])
  • Dot (.)
  • No formatting (none)

Back reference circumflex (back-ref-caret)

The list of back references can optionally start with a circumflex (caret) symbol. The symbol can either prefix the back references or be combined with them MediaWiki-style:

  • If there is only one back reference, use the circumflex for the link.
  • If there are many back references, prefix the back references with the circumflex.

The following styles are supported:

  • No circumflex (none) [default]
  • Prefix the back references with a circumflex (prefix)
  • Merge the circumflex with back references (merge)

Note that if back-ref-format style is set to note this style has no effect.

Back reference base line (back-ref-base)

The following styles are supported:

  • Superscript (sup) [default]
  • Normal text (text)

Back reference font weight (back-ref-font-weight)

The following styles are supported:

  • Bold font (bold) [default]
  • Normal font (normal)

Back reference font style (back-ref-font-style)

The following styles are supported:

  • Normal font (normal) [default]
  • Italic font (italic)

Back reference formatting (back-ref-format)

The back reference link can be either combined with the note identifier or rendered separately. If there are multiple references to the note, the combined approach renders multiple identifiers that are formatted according to the note-id-format style. Actual values of these identifiers are controlled by the multi-ref-id style.

When the back references are rendered separately from the note identifier, they can be presented either using the back reference counter or just as a row of symbols.

The following styles are supported:

  • Use note identifiers as back references (note) [default]
  • Latin (a)
  • Numeric (1)
  • Circumflex (caret)
  • Up arrow (arrow)
  • No back references (none)

Back reference separator (back-ref-separator)

The following styles are supported:

  • Comma (,) [default]
  • No separator (none)

Scoping behavior (scoping)

Controls whether a new scope is created after rendering the notes.

The following styles are supported:

  • Start new scope after each note block (reset) [default]
  • Use single scope (single)

See also

plugin/refnotes/style.txt · Last modified: 2019-02-09 16:30 by pan One