SlashBack attempts to make professional documentation easier.
If you ever wanted your text to appear exactly as you wrote it,
SlashBack is for you!
The only character you need to tell SlashBack what to do, is backslash (\
)
It's your universal tool to style your text!
- No characters that suddenly vanish (or produce unexpected text formatting)
- No cumbersome trickery to make indents or multiple spaces (like " ")
- No need for escape characters (the only character you can escape is backslash)
SlashBack's syntax is similar to the syntax of HTML.
Every text snippet that's supposed to be displayed in a given format has to be surrounded by a start and end tag.
Every tag in turn has to be surrounded by backslashes.
In other words, a tag begins with a backslash and ends with one.
Example:
Given you want to put a strong emphasis on the word "money".
You can do so by writing \b\money\b\
.
The "b
"-tag stands for bold.
To make it easier to differentiate between start and end tags, you can put spaces after start tags and before end tags, like so:
This text is \b \important\ b\.
Alternatively, tags can be prefixed with one (or multiple) of the following symbols: !#/:|+.~>_<
(i.e. these symbols can precede tag identifiers). One example could be:
This text is \+b\important\~b\.
The following tags are supported:
SlashBack supports six different header sizes:
h1
, h2
, h3
, h4
, h5
and h6
Examples:
SlashBack supports only four different types of text formatting:
b
- Bold (or strong)i
- Italics
-Strikethroughu
- Underline (may not be supported)
And any combination of them
You can put code in your documentation using the code
tag.
If you need multiline code, simply put a code
tag in the lines before and after the code segment.
For multiline code you can even specify a programming language after the initial code tag.
Example:
\code python \
import this
print("interesting...")
\ code\
becomes
import this
print("interesting...")
A list of language IDs can be found over here.
If you want to reference other websites or link to a specific section of your documentation, you can use the url
tag.
The specified target could either be a real url (or relative link), such as a useless website:
\url ismycomputeron.com \a useless website\ url\
Alternatively, it can be a link to a header in your document:
\url #hyperlinks-urls-sections \link\ url\
"To use quotes, thou must use the
quote
tag"
~ The Author
Alternatively the q
tag can be used.
Images can be embedded using the image
tag, like so:
\image https://raw.githubusercontent.com/Zuzu-Typ/SlashBack/future/Icon/SB.svg?sanitize=true \Broken Image \ image\
(in this case Broken Image will be displayed if the image couldn't be found)
You can alternatively use the img
tag.
- Need to add support for tasks
Tasks can be created using the task
tag.
Each task
tag has to be defined as checked or unchecked.
You can use task checked
, tc
or x
for checked tasks
and task unchecked
, tu
or o
for unchecked tasks.
In all of those cases, the end tag can be just task
.
-
To create lists, you have to use the
list
tag.-
A list can either be ordered or unordered.
-
The start-tag of an ordered list can be any of:
list ordered
lo
- and
ol
-
The start-tag of an unordered list can be any of:
list unordered
lu
- and
ul
-
-
A list entry can be added using dashes (
-
).- The amount of dashes translates to the indent depth (i.e. how far right the text is displayed)
- This entry for example has depth 3 - so it has three dashes (
---
).
-
You can switch between ordered and unordered lists using the
list switch
,ls
orsl
command. -
The end tag of a list can be
list
or any of the start tags.
-
Example:
\list ordered \
\-\Install Python
\list switch\
\--\Go to \url http://python.org \python.org\ url\
\list switch\
\-\Run SlashBack.py
\-\Enjoy.
\ list\
-
Install Python
- Go to python.org
-
Run SlashBack.py
-
Enjoy.
Tag | Usage |
---|---|
table |
Start and end tag for tables. |
tbl |
Same as table |
- |
Table separator |
For tables, each line of SlashBack code translates to one row in the table.
The table separator is used to separate columns of each row.
The first line of each table in SlashBack code will be used as the titles of the columns.
Example:
\table \
USB connector \-\ Typical use \-\ Flippable
A \-\ Desktop computers and laptops \-\ No
B \-\ External devices \-\ No
C \-\ Anything \-\ Yes
\ table\
USB connector | Typical use | Flippable |
---|---|---|
A | Desktop computers and laptops | No |
B | External devices | No |
C | Anything | Yes |
You can add a separator using the separator
or sep
command.
Example:
\separator\
Should you ever come across something that can't be done with SlashBack, please create a new issue.
Until the feature is added (or if it is not added), you can use the raw
tag.
Example:
\raw \<font face="verdana" color="green" size=5em>This text may be green (but not on GitHub)</font>\ raw\
This text may be green (but not on GitHub)
You can add comments to your documentation using the comment
or c
tag.
If you want your comments to also be included in your output markdown file (but not in the final HTML), you may use the icomment
or ic
tag.
For reference, look at README.sb.
This very README was composed in SlashBack (: