texdi.te 3.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. #Texdi
  2. ##Introducción
  3. This documentation describes how to use and detail advantages and disadvantages of Texdi.
  4. It is recommended to read Tedi reference before this document.
  5. ##Languages supported
  6. Texdi name is from a portmanteau between text and tedi. Texdi goal is supporting all markup languages possibles. Supported languages were chosen by popularity and uses.
  7. Every converter are isolated libraries. Their names come from tedi2LANG where LANG is the language to be converted with.
  8. __
  9. -- HTML: tedi2html
  10. -- Latex: tedi2tex
  11. -- Asciidoc: tedi2ad
  12. -- Markdown: tedi2md
  13. ,,
  14. ##Terminal parameters
  15. Allow different workflows for different uses.
  16. <--latex
  17. Convert to latex without author.
  18. <--html
  19. Convert to HTML with stylesheet by default.
  20. <--asciidoc
  21. Convert file to AsciiDoc.
  22. <--markdown
  23. Convert file to Markdown.
  24. <--output ARCHIVO
  25. <-o ARCHIVO
  26. Allow user choose output filename.
  27. <--own-styles
  28. Link styles.css to document when converting to HTML.
  29. <--help
  30. Print this list with the same options.
  31. ##Reference version
  32. The first implementation was Matedi. This implementation started as a function used when loading page. At first it was easy to do but when Tedi got better code (compilers and interpreters are difficult) it got development a bit slow. This implementation converted to HTML only and made the way to the first library called tedi2html.
  33. The first library led the way to create Texdi. First public version came with HTML, Latex and TXT conversion. TXT conversion later subdivided into Markdown and Asciidoc. Because similarities with definitios and development, tedi2html is the reference library of Tedi.
  34. tedi2html follows a sequential order that generates a hierarchy. Before every conversion, the whole file is preprocessed and all inserted documents are add to a single temporal file.
  35. ##Control tags
  36. Only comments, metatags and embed tags are included in this category.
  37. Because this tags must be in first tag of line it's easier.
  38. ###Comments
  39. This tags avoids saving anything to the converted file. It allows describe parts of the document.
  40. ###Embed
  41. Library detects this tag, delete it and keep the line untouched. This tag allows interpreter or compiler of the converted language read that tag easily and without fails.
  42. ###Metatag
  43. This tags keeps its capabilities from reference and it's suppose to work as intended.
  44. ##Quotes
  45. Avoid conversion of links, images and containers. Starting quotation mark must be on first character of the line and closing quotation mark must be in last character.
  46. User can add line break in quoted lines with a white space before the closing quotation mark.
  47. ##Containers, images and links
  48. A container is a piece of text (that can have more tags inside) that is isolated from the rest between brackets.
  49. Containers work like HTML div. Its conversion is like itself but with HTML syntax.
  50. Images and links work same but for img tags and a tags.
  51. ##Tables
  52. Last conversion done by code is converting Tedi tables to HTML/Latex/Markdown/Asciidoc tables.
  53. Unique part of code that needs to know previous lines and next line of file.
  54. ##Last notes
  55. Styles recomendation are highly recommended for Tedi files also for titles.