Skip to content


Subversion checkout URL

You can clone with
Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

160 lines (107 sloc) 4.706 kb
[chapter *.afc format syntax]
This a short introduction to the *.afc format syntax.
[section Chapters, sections and other chunks]
**Chapter:** This tag creates a chapter in your textbook.
[code][chapter chapter name][/code]
**Section:** The %%section%% tag builds a section in a chapter. It also adds a reference on the Table of
[code][section section name][/code]
**Unimportant section:** Title works quite alike sections, but it neither add a reference on the Table of
Contents nor make a new webpage in HTML mode -- it belongs to the previous section .
[code][title unimportant section][/code]
**Quotations:** This tag adjust the quotation layout, ::italizing:: the quote and placing its author
on the next line. Both quotation and author are aligned to the right.
[code][quote <quotation> --<author>][/code]
**Label:** Adds a footnote, on Latex, and a alt box, on HTML, on the text inside the tag. Be aware to the
fact that no other tags are allowed on the label text.
[code][label the label] what is beeing labeled [/label][/code]
**Box:** The %%box%% tag places its content in a new environment slightly indented and appart from the
rest of the text.
[code][box <box title>] <content> [/box][/code]
**Exercises:** The exercise tag creates an new environment in which you must place questions. Each
question might have an answer and it can be added by using the tag answer.
[question] The question [/question]
[question] The question
[answer] The answer [/answer]
**Instructors' Note:** in case you need your teacher's textbook to have extra information, you might
use the %%note%% tag. It adds Instructor Notes to the textbook when compiling with instructors option on.
[code][note]Note to the instructor[/note][/code]
[section Basic text definition]
**Bold:** [code]**bold text**[/code]
**Italic:** [code]::italic text::[/code]
**Underlined:** [code]__underlined text__[/code]
**Inline code:** [code] %% code text in common text paragraph %% [/code]
[section Code chunk tags]
**Java:** [code][code java]Java code[/code][/code]
**Java from file:** [code][code java filename=path/][/code][/code]
You can replace %%java%% with any other language supported by Pygments in order to highlight properly your code.
Check the available languages at
In order to emphasize code lines, use the option: %%h=line1,line2,...%% like this:
[code][code java h=1,2,3]....[/code][/code]
If you want to number the lines of the output code, use the parameter %%#%%, like this:
[code][code java #]...[/code][/code]
[section Special tags]
**Link:** Tubaina automatically adds links whenever you use "http://"
**Anchor for indexing:** This tag creates an anchor to be added in the index.
[code][index anchor name][/code]
**To do:** The tag %%todo%% allows you making reminders of those edits you must do on your textbook,
but have not enough time or material to work on. It builds a log of all the open tasks in your book.
[code][todo task reminder][/code]
[section Lists]
**Circular bulleted list:**
* item
* item
**Numbered list:**
[code][list number]
* item
**Roman counter list:**
[code][list roman]
* item
**Letter counter list:**
[code][list letter]
* item
[section Images]
**Images:** in order to add images to your textbook, you must use the tag %%img%%. This tag has two
specialties: you may choose the percentage of the width of the page your image must fill by using the
tag %%w%% and you can add a comment about the image on a floating tab.
[code][img path/image.png w=scale% "tab comment"][/code]
[section Tables]
**Tables:** the structure of tags used to create a table is similar to that of the HTML language. First,
to start a table, you use the tag %%table%%. This tag may specify two parameters: a title and the
keyword %%noborder%%, which specifies that the generated table will not have borders. The title must
be inside double quotation marks ("). Inside the %%table%% tag, use a %%row%% tag to start a line and, inside
a row, use a %%col%% tag to add a cell to the table. Inside a %%col%% tag, you can type text, code and/or
put images.
[table "An example"]
First cell of first line
Second cell of first line
First cell of second line
An image:
[img images/example.png]
Jump to Line
Something went wrong with that request. Please try again.