This guide describes the AsciiDoc syntax supported by Ceradoc. It covers document structure, blocks, lists, tables, and advanced features.
Document Structure
Document Title (Level 0)
The document title uses = followed by a space:
= Document Title
Author Name <author@example.com>
v1.0, 2024-01-01
Document content starts here.Lists
Unordered Lists
Use * for unordered lists:
* Item one
* Item two
** Nested item
*** Deeper nested
* Back to level 1Definition Lists
Use :: (or :::, ::::) for definition lists:
Term:: Definition of the term.
Another Term::
Extended definition that
spans multiple lines.
API:: Application Programming InterfaceList Continuation
List continuation allows attaching blocks to list items using + on its own line.
Continuation with Example Block
* Example configuration:
+
====
[source,yaml]database: host: localhost port: 5432
====
Tables
Basic Table
|===
| Header 1 | Header 2 | Header 3
| Cell 1 | Cell 2 | Cell 3
| Cell 4 | Cell 5 | Cell 6
|===Table with Attributes
[cols="1,2,1", frame="all", grid="all"]
|===
| First | Second | Third
| A | B | C
|===Cell Format Specification
Cell format is: [colspan][.rowspan][halign][valign][style][*]
Ceradoc fully supports cell format specifications including multi-row tables with complex spanning and alignment.
| Component | Syntax | Values | Example | colspan | N | digits | 2 (2 columns) | rowspan | .N | dot + digits | .3 (3 rows) | halign | char | < ^ > | ^ (center) | valign | .`char | `.< .> .^ | .> (bottom) | style | char | d s e m a l v | e (emphasis) | repeat | | asterisk | (repeat)
Blocks
Code Blocks (Listing)
Use ---- (4+ dashes) for code blocks:
[source,ruby]def hello_world puts "Hello, World!" end
With callouts:
[source,ruby]def process(data) # <1> data.transform # <2> end # <3>
<1> Method definition <2> Transform data <3> End method
Inline Formatting
Comments
Single-line comment:
// This is a commentBlock comment:
////
This is a
multi-line comment.
////Ceradoc-Specific Features
Ceradoc Extensions
Ceradoc extends AsciiDoc with:
-
Enhanced table cell formatting - Full colspan/rowspan/alignment support
-
Variable table delimiters - Tables can use
|,!,,,:,;as cell separators -
Block nesting support - "n+" delimiter pattern for nested blocks
-
CoreModel integration - Direct access to document model
Unsupported Features
The following AsciiDoc features are not fully supported:
-
Complex include hierarchies - Limited include directive support
-
Custom macros - User-defined macros not supported
-
Backend-specific features - PDF-specific features limited
-
Nested tables - Tables inside table cells limited
-
Cell style
a- AsciiDoc content inside table cells limited