📄 format.html
字号:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>Buffalo AJAX - </title>
<style type="text/css" media="all">
@import url("./css/maven-base.css");
@import url("./css/maven-theme.css");
@import url("./css/site.css");
</style>
<link rel="stylesheet" href="./css/print.css" type="text/css" media="print" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
</head>
<body class="composite">
<div id="banner">
<a href="index.html" id="bannerLeft">
<img src="images/buffalo-title.gif" alt="" />
</a>
<a href="http://sourceforge.net" id="bannerRight">
<img src="http://sflogo.sourceforge.net/sflogo.php?group_id=178867&type=1" alt="" />
</a>
<div class="clear">
<hr/>
</div>
</div>
<div id="breadcrumbs">
<div class="xleft">
Last Published: 10/08/2006
</div>
<div class="xright"> <a href="http://www.amowa.net/buffalo/zh">Chinese Docs</a>
</div>
<div class="clear">
<hr/>
</div>
</div>
<div id="leftColumn">
<div id="navcolumn">
<h5>Quick Start</h5>
<ul>
<li class="none">
<a href="tutorial.html">1 Minute Tutorial</a>
</li>
<li class="none">
<a href="http://demo.amowa.net/buffalo-demo/">Demo</a>
</li>
<li class="none">
<a href="download.html">Download</a>
</li>
<li class="none">
<a href="features.html">Features</a>
</li>
<li class="none">
<a href="faq.html">FAQ</a>
</li>
</ul>
<h5>Mastering Buffalo</h5>
<ul>
<li class="none">
<a href="best_practice.html">Best Practise</a>
</li>
<li class="none">
<a href="howto.html">How to...</a>
</li>
</ul>
<h5>Reference</h5>
<ul>
<li class="none">
<a href="jsapi.html">JavaScript API</a>
</li>
</ul>
<a href="http://maven.apache.org/" title="Built by Maven" id="poweredBy">
<img alt="Built by Maven" src="./images/logos/maven-feather.png"></img>
</a>
</div>
</div>
<div id="bodyColumn">
<div id="contentBox">
<div class="section"><h2>The APT formahahahat</h2><p>In the following section, boxes containing text in typewriter-like font are examples of APT source.</p><div class="section"><h3>Document structure</h3><p>A short APT document is contained in a single text file. A longer document may be contained in a ordered list of text files. For instance, first text file contains section 1, second text file contains section 2, and so on.</p><dl><dt>Note:</dt><dd>Splitting the APT document in several text files on a section boundary is not mandatory. The split may occur anywhere. However doing so is recommended because a text file containing a section is by itself a valid APT document.</dd></dl><p>A file contains a sequence of paragraphs and ``displays'' (non paragraphs such as tables) separated by open lines.</p><p>A paragraph is simply a sequence of consecutive text lines.</p><div class="source"><pre> First line of first paragraph.
Second line of first paragraph.
Third line of first paragraph.
Line 1 of paragraph 2 (separated from first paragraph by an open line).
Line 2 of paragraph 2.
</pre></div><p>The indentation of the first line of a paragraph is the main method used by an APT processor to recognize the type of the paragraph. For example, a section title must not be indented at all.</p><p>A ``plain'' paragraph must be indented by a certain amount of space. For example, a plain paragraph which is not contained in a list may be indented by two spaces.</p><div class="source"><pre>My section title (not indented).
My paragraph first line (indented by 2 spaces).
</pre></div><p>Indentation is not rigid. Any amount of space will do. You don't even need to use a consistent indentation all over your document. What really matters for an APT processor is whether the paragraph is not indented at all or, when inside a list, whether a paragraph is more or less indented than the first item of the list (more about this later).</p><div class="source"><pre> First paragraph has its first line indented by four
spaces. Then the author did even bother to indent the
other lines of the paragraph.
Second paragraph contains several lines which are all
indented by two spaces. This style is much nicer than
the one used for the previous paragraph.
</pre></div><p>Note that tabs are expanded with a tab width set to 8.</p></div><div class="section"><h3>Document elements</h3><div class="section"><h4>Block level elements</h4><div class="section"><h5>Title</h5><p>A title is optional. If used, it must appear as the first block of the document.</p><div class="source"><pre> ------
Title
------
Author
------
Date
</pre></div><p>A title block is indented (centering it is nicer). It begins with a line containing at least 3 dashes (<tt>---</tt>).</p><p>After the first <tt>---</tt> line, one or several consecutive lines of text (implicit line break after each line) specify the title of the document.</p><p>This text may immediately be followed by another <tt>---</tt> line and one or several consecutive lines of text which specifies the author of the document.</p><p>The author sub-block may optionaly be followed by a date sub-block using the same syntax.</p><p>The following example is used for a document with an title and a date but with no declared author.</p><div class="source"><pre> ------
Title
------
------
Date
------
</pre></div><p>The last line is ignored. It is just there to make the block nicer.</p></div><div class="section"><h5>Paragraph</h5><p>Paragraphs other than the title block may appear before the first section.</p><div class="source"><pre> Paragraph 1, line 1.
Paragraph 1, line 2.
Paragraph 2, line 1.
Paragraph 2, line 2.
</pre></div><p>Paragraphs are indented. They have already been described in the <a href="document structure">document structure</a> section.</p></div><div class="section"><h5>Section</h5><p>Sections are created by inserting section titles into the document. Simple documents need not contain sections.</p><div class="source"><pre>Section title
* Sub-section title
** Sub-sub-section title
*** Sub-sub-sub-section title
**** Sub-sub-sub-sub-section title
</pre></div><p>Section titles are not indented. A sub-section title begins with one asterisk (<tt>*</tt>), a sub-sub-section title begins with two asterisks (<tt>**</tt>), and so forth up to four sub-section levels.</p></div><div class="section"><h5>List</h5><div class="source"><pre> * List item 1.
* List item 2.
Paragraph contained in list item 2.
* Sub-list item 1.
* Sub-list item 2.
* List item 3.
</pre></div><p>List items are indented and begin with a asterisk (<tt>*</tt>). </p><p>Plain paragraphs more indented than the first list item are nested in that list. Displays such as tables (not indented) are always nested in the current list.</p><p>To nest a list inside a list, indent its first item more than its parent list. To end a list, add a paragraph or list item less indented than the current list.</p><p>Section titles always end a list. Displays cannot end a list but the <tt>[]</tt> pseudo-element may be used to force the end of a list.</p><div class="source"><pre> * List item 3.
Force end of list:
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -