PageRenderTime 64ms CodeModel.GetById 54ms app.highlight 5ms RepoModel.GetById 1ms app.codeStats 0ms

/samples/sample.xhtmls

http://txt2tags.googlecode.com/
Unknown | 461 lines | 407 code | 54 blank | 0 comment | 0 complexity | 9f78b2486a67552483f85c3b7c51dc37 MD5 | raw file
  1<?xml version="1.0"
  2      encoding="UTF-8"
  3?>
  4<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
  5<html xmlns="http://www.w3.org/1999/xhtml">
  6<head>
  7<title>TXT2TAGS SAMPLE</title>
  8<meta name="generator" content="http://txt2tags.org" />
  9<style type="text/css">body {background-color:#FFFFFF ; color:#000000}</style>
 10</head>
 11<body>
 12<div style="text-align:center">
 13<h1>TXT2TAGS SAMPLE</h1>
 14<h2>Aurelio Jargas</h2>
 15<h3>04/08/2012</h3>
 16</div>
 17
 18<p>
 19This text is before the introduction.
 20</p>
 21<p>
 22But it's OK.
 23</p>
 24
 25<h1>Introduction</h1>
 26
 27<p>
 28Welcome to the txt2tags sample file.
 29</p>
 30<p>
 31Here you have examples and a brief explanation of all
 32marks.
 33</p>
 34<p>
 35The first 3 lines of the this file are used as headers,
 36on the following format:
 37</p>
 38
 39<pre>
 40  line1: document title
 41  line2: author name, email
 42  line3: date, version
 43</pre>
 44
 45<p>
 46Lines with balanced equal signs = around are titles.
 47</p>
 48
 49<h1>Fonts and Beautifiers</h1>
 50
 51<p>
 52We have two sets of fonts:
 53</p>
 54<p>
 55The NORMAL type that can be improved with beautifiers.
 56</p>
 57<p>
 58The TYPEWRITER type that uses monospaced font for
 59pre-formatted text.
 60</p>
 61<p>
 62We will now enter on a subtitle...
 63</p>
 64
 65<h2>Beautifiers</h2>
 66
 67<p>
 68The text marks for beautifiers are simple, just as you
 69type on a plain text email message.
 70</p>
 71<p>
 72We use double *, /, - and _ to represent <strong>bold</strong>,
 73<em>italic</em>, <span style="text-decoration:line-through">strike</span> and <span style="text-decoration:underline">underline</span>.
 74</p>
 75<p>
 76The <strong><em>bold italic</em></strong> style is also supported as a
 77combination.
 78</p>
 79
 80<h2>Pre-Formatted Text</h2>
 81
 82<p>
 83We can put a code sample or other pre-formatted text:
 84</p>
 85
 86<pre>
 87    here    is     pre-formatted
 88  //marks// are  **not**  ``interpreted``
 89</pre>
 90
 91<p>
 92And also, it's easy to put a one line pre-formatted
 93text:
 94</p>
 95
 96<pre>
 97  prompt$ ls /etc
 98</pre>
 99
100<p>
101Or use <code>pre-formatted</code> inside sentences.
102</p>
103
104<h2>More Cosmetics</h2>
105
106<p>
107Special entities like email (<a href="mailto:duh@somewhere.com">duh@somewhere.com</a>) and
108URL (<a href="http://www.duh.com">http://www.duh.com</a>) are detected automagically,
109as long as the horizontal line:
110</p>
111
112<hr class="light" />
113
114<p>
115^ thin or large v
116</p>
117
118<hr class="heavy" />
119
120<p>
121You can also specify an <a href="http://duh.org">explicit link</a>
122or an <a href="mailto:duh@somewhere.com">explicit email</a> with label.
123</p>
124<p>
125And remember,
126</p>
127	<blockquote>
128	A TAB in front of the line does a quotation.
129		<blockquote>
130		More TABs, more depth (if allowed).
131		</blockquote>
132	</blockquote>
133<p>
134Nice.
135</p>
136
137<h1>Lists</h1>
138
139<p>
140A list of items is natural, just putting a <strong>dash</strong> or
141a <strong>plus</strong> at the beginning of the line.
142</p>
143
144<h2>Plain List</h2>
145
146<p>
147The dash is the default list identifier. For sublists,
148just add <strong>spaces</strong> at the beginning of the line. More
149spaces, more sublists.
150</p>
151
152<ul>
153<li>Earth
154  <ul>
155  <li>America
156    <ul>
157    <li>South America
158      <ul>
159      <li>Brazil
160        <ul>
161        <li>How deep can I go?
162        </li>
163        </ul>
164      </li>
165      </ul>
166    </li>
167    </ul>
168  </li>
169  <li>Europe
170    <ul>
171    <li>Lots of countries
172    </li>
173    </ul>
174  </li>
175  </ul>
176</li>
177<li>Mars
178  <ul>
179  <li>Who knows?
180  </li>
181  </ul>
182</li>
183</ul>
184
185<p>
186The list ends with <strong>two</strong> consecutive blank lines.
187</p>
188
189<h2>Numbered List</h2>
190
191<p>
192The same rules as the plain list, just a different
193identifier (plus).
194</p>
195
196<ol>
197<li>one
198</li>
199<li>two
200</li>
201<li>three
202  <ul>
203  <li>mixed lists!
204  </li>
205  <li>what a mess
206    <ol>
207    <li>counting again
208    </li>
209    <li>...
210    </li>
211    </ol>
212  </li>
213  </ul>
214</li>
215<li>four
216</li>
217</ol>
218
219<h2>Definition List</h2>
220
221<p>
222The definition list identifier is a colon, followed by
223the term. The term contents is placed on the next line.
224</p>
225
226<dl>
227<dt>orange</dt><dd>
228  a yellow fruit
229</dd>
230<dt>apple</dt><dd>
231  a green or red fruit
232</dd>
233<dt>other fruits</dt><dd>
234  <ul>
235  <li>wee!
236  </li>
237  <li>mixing lists
238    <ol>
239    <li>again!
240    </li>
241    <li>and again!
242    </li>
243    </ol>
244  </li>
245  </ul>
246</dd>
247</dl>
248
249<h1>Tables</h1>
250
251<p>
252Use pipes to compose table rows and cells.
253Double pipe at the line beginning starts a heading row.
254Natural spaces specify each cell alignment.
255</p>
256
257<table style="text-align:center" border="1" cellpadding="4">
258<tr>
259<td>cell 1.1</td>
260<td style="text-align:center">cell 1.2</td>
261<td style="text-align:right">cell 1.3</td>
262</tr>
263<tr>
264<td>cell 2.1</td>
265<td style="text-align:center">cell 2.2</td>
266<td style="text-align:right">cell 2.3</td>
267</tr>
268<tr>
269<td>cell 3.1</td>
270<td style="text-align:center">cell 3.2</td>
271<td style="text-align:right">cell 3.3</td>
272</tr>
273</table>
274
275<table border="1" cellpadding="4">
276<tr>
277<th>heading 1</th>
278<th>heading 2</th>
279<th>heading 3</th>
280</tr>
281<tr>
282<td>cell 1.1</td>
283<td style="text-align:center">cell 1.2</td>
284<td style="text-align:right">cell 1.3</td>
285</tr>
286<tr>
287<td>cell 2.1</td>
288<td style="text-align:center">cell 2.2</td>
289<td style="text-align:right">cell 2.3</td>
290</tr>
291</table>
292
293<table style="text-align:center" border="1" cellpadding="4">
294<tr>
295<th>heading 1</th>
296<td style="text-align:center">cell 1.1</td>
297<td style="text-align:right">cell 1.2</td>
298</tr>
299<tr>
300<th>heading 2</th>
301<td style="text-align:center">cell 2.1</td>
302<td style="text-align:right">cell 2.2</td>
303</tr>
304<tr>
305<th>heading 3</th>
306<td style="text-align:center">cell 3.1</td>
307<td style="text-align:right">cell 3.2</td>
308</tr>
309</table>
310
311<table border="1" cellpadding="4">
312<tr>
313<th>heading</th>
314<th>heading 1</th>
315<th>heading 2</th>
316</tr>
317<tr>
318<th>heading 1</th>
319<td style="text-align:center">cell 1.1</td>
320<td style="text-align:right">cell 1.2</td>
321</tr>
322<tr>
323<th>heading 2</th>
324<td style="text-align:center">cell 2.1</td>
325<td style="text-align:right">cell 2.2</td>
326</tr>
327</table>
328
329<p>
330Without the last pipe, no border:
331</p>
332
333<table style="text-align:center" cellpadding="4">
334<tr>
335<td>cell 1.1</td>
336<td style="text-align:center">cell 1.2</td>
337<td style="text-align:right">cell 1.3</td>
338</tr>
339<tr>
340<td>cell 2.1</td>
341<td style="text-align:center">cell 2.2</td>
342<td style="text-align:right">cell 2.3</td>
343</tr>
344<tr>
345<td>cell 3.1</td>
346<td style="text-align:center">cell 3.2</td>
347<td style="text-align:right">cell 3.3</td>
348</tr>
349</table>
350
351<table cellpadding="4">
352<tr>
353<th>heading 1</th>
354<th>heading 2</th>
355<th>heading 3</th>
356</tr>
357<tr>
358<td>cell 1.1</td>
359<td style="text-align:center">cell 1.2</td>
360<td style="text-align:right">cell 1.3</td>
361</tr>
362<tr>
363<td>cell 2.1</td>
364<td style="text-align:center">cell 2.2</td>
365<td style="text-align:right">cell 2.3</td>
366</tr>
367</table>
368
369<table style="text-align:center" cellpadding="4">
370<tr>
371<th>heading 1</th>
372<td style="text-align:center">cell 1.1</td>
373<td style="text-align:right">cell 1.2</td>
374</tr>
375<tr>
376<th>heading 2</th>
377<td style="text-align:center">cell 2.1</td>
378<td style="text-align:right">cell 2.2</td>
379</tr>
380<tr>
381<th>heading 3</th>
382<td style="text-align:center">cell 3.1</td>
383<td style="text-align:right">cell 3.2</td>
384</tr>
385</table>
386
387<table cellpadding="4">
388<tr>
389<th>heading</th>
390<th>heading 1</th>
391<th>heading 2</th>
392</tr>
393<tr>
394<th>heading 1</th>
395<td style="text-align:center">cell 1.1</td>
396<td style="text-align:right">cell 1.2</td>
397</tr>
398<tr>
399<th>heading 2</th>
400<td style="text-align:center">cell 2.1</td>
401<td style="text-align:right">cell 2.2</td>
402</tr>
403</table>
404
405<h1>Special Entities</h1>
406
407<p>
408Because things were too simple.
409</p>
410
411<h2>Images</h2>
412
413<p>
414The image mark is as simple as it can be: <code>[filename]</code>.
415</p>
416<p>
417                      <img style="text-align:center" src="img/photo.jpg" alt=""/>  
418</p>
419<p>
420And with some targets the image is linkable :
421</p>
422<p>
423                      <a href="http://www.txt2tags.org"><img style="text-align:center" src="img/photo.jpg" alt=""/></a>  
424</p>
425
426<ul>
427<li>The filename must end in PNG, JPG, GIF, or similar.
428</li>
429<li>No spaces inside the brackets!
430</li>
431</ul>
432
433<h2>Other</h2>
434
435<p>
436When the target needs, special chars like &lt;, &gt; and &amp;
437are escaped.
438</p>
439<p>
440The handy <code>%%date</code> macro expands to the current date.
441</p>
442<p>
443So today is 20120408 on the ISO <code>YYYYMMDD</code> format.
444</p>
445<p>
446You can also specify the date format with the %? flags,
447as <code>%%date(%m-%d-%Y)</code> which gives: 04-08-2012.
448</p>
449<p>
450That's all for now.
451</p>
452
453<hr class="light" />
454
455<p>
456<img style="text-align:left" src="img/t2tpowered.png" alt=""/> (<a href="sample.t2t">sample.t2t</a>)
457</p>
458
459<!-- xhtmls code generated by txt2tags 2.6.880 (http://txt2tags.org) -->
460<!-- cmdline: txt2tags -t xhtmls sample.t2t -->
461</body></html>