Skip to content

Commit

Permalink
Update documentation [ci skip]
Browse files Browse the repository at this point in the history
  • Loading branch information
Joel Håkansson committed Nov 3, 2017
1 parent 21ffa26 commit ac011a2
Show file tree
Hide file tree
Showing 10 changed files with 158 additions and 142 deletions.
36 changes: 11 additions & 25 deletions docs/Convert.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
[Table of Contents](toc.md)

## Convert ##
# Convert #
Converts a document into braille.

Dotify requires two arguments to run:
* path to an input file
* path to the output file

### Input File Requirements ###
## Input File Requirements ##
The input file should, of course, be something that Dotify understands. Because Dotify has been developed for and funded by [Swedish Agency for Accessible Media, MTM](http://www.mtm.se), the current capabilities may seem odd to an average user. Dotify supports:
* DTBook
* HTML
Expand All @@ -26,7 +26,7 @@ A plain text can also be used, with similar capabilities as for general XML, i.e

OBFL is the intermediary format used by Dotify, and is likely only of interest to developers.

### Output File Formats ###
## Output File Formats ##
The output format is determined by examining the extension of the specified output file name. Supported extensions are:
* pef
* txt
Expand All @@ -43,15 +43,9 @@ The following optional arguments are available:
* preset
* locale
* outputFormat
* identifier
* writeTempFiles
* tempFilesDirectory
* date
* dateFormat
* table
* watch
* listOptions
* configs

### preset ###
The preset specifies some key properties of the finished product, such as row spacing, characters/line, rows/page and sheets/volume. Each of these can be set
Expand All @@ -69,36 +63,28 @@ The locale is very important, because it determines the fall-back language used
### outputFormat ###
If specified, the output format is determined by the value of this parameter, instead of from the file name extension.

### identifier ###
Sets the identifier in the output file (if supported).

### writeTempFiles ###
Set to true to write temp files.

### tempFilesDirectory ###
Sets the directory to write temp data. If not specified, the user default is used.

### date ###
Sets the date in the output file (if supported).

### dateFormat ###
Sets the date format to use when writing the current date in meta data (if supported). The syntax is as specified by [SimpleDateFormat](http://docs.oracle.com/javase/6/docs/api/java/text/SimpleDateFormat.html)

### table ###
If specified, an ASCII-braille file is generated in addition to the PEF-file (requires that the output format is PEF).

## Switches ##
The following switches are available:
* watch
* listOptions
* configs

### watch ###
If present, watches the input file for changes and runs the conversion when changes occur
If present, watches the input file for changes and runs the conversion when changes occur.

### listOptions ##
If present, lists additional options available in the context of the current job. Due to the dynamic
design of the system, the options are listed *after* the conversion has finished running. To use these options,
append them to the options list of the job just finished and run again.

### configs ###
If present, lists the available combinations of locale and braille translators

# Example Workflow #
1. Markup using a format of choice
1. Process format into PEF (with Dotify)
1. Emboss using Dotify or [Dotify Studio](https://github.com/brailleapps/dotify-studio)
If present, lists the available combinations of locale and braille translators.
39 changes: 29 additions & 10 deletions docs/Emboss.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[Table of Contents](toc.md)

# Emboss #
Send a PEF-file to an embosser for embossing.
Sends a PEF-file to an embosser for embossing.

One argument is required, and can be one of the following:
* path to a file
Expand All @@ -13,23 +13,42 @@ Upon the first run, the application will ask the user for the required setup:
* embosser model
* embosser table (if applicable)
* paper size
* paper orientation

The file will be sent directly to the embosser on subsequent runs. To change settings, use either `--setup` or `--clear`.

## Setup ##
Setup will ask all the user to verify all settings.
## Change settings ##
When changing settings, the CLI will ask some questions about the device, model, braille table and paper size. See below for more information.

## Clear ##
Clear will delete the current settings. The next time the application is started, it runs as on the first run.
When using `--setup` all setup details will be collected from the user interactively. If setup has already been performed, previous values will be used as defaults (if applicable).
When using `--clear`, the current settings are deleted. The next time the application is started, it runs as on the first run.

## Device ##
### Device ###
The device is the address where the embosser can be contacted. In most cases this should be intuitive. If your device does not show up, make sure that the embosser is turned on.

## Embosser Model ##
### Embosser Model ###
Note that the same embosser model may communicate differently depending on firmware or hardware version. Make sure that the embosser version is correct.

## Embosser Table ##
### Embosser Table ###
Some embossers require that a table is chosen by the user for the purpose of communication. Make sure that the table chosen in the user interface matches the value expected by the embosser.

## Paper Size ##
Verify that the paper in the embosser matches the value in the user interface. Some embossers uses rolls of paper. In this case, select a paper size that matches the intended paper size once cut.
### Paper Size ###
Verify that the paper in the embosser matches the value in the user interface. Some embossers uses rolls of paper. In this case, select a paper size that matches the intended paper size once cut.

### Paper orientation ###
...

## Optional Arguments ##
The following optional arguments are available:
- range
- copies
- dir

### range ###
Specifies the range of pages to emboss, for example `--range=1-3`.

### copies ###
Specifies the number of copies.

### dir ###
Specifies an output directory for the embosser data. If this is set, no data will be sent to the embosser. Instead, the files will be saved to this folder. The contents of the files are exactly what the embosser would have received if this option was not set.
92 changes: 50 additions & 42 deletions docs/GeneratePef.md
Original file line number Diff line number Diff line change
@@ -1,65 +1,73 @@
[Table of Contents](toc.md)

# Generate a PEF-file #
Generate a random PEF-file for testing purposes.
Generates a random PEF-file for testing purposes.

One argument is required: _path to output file_

<pre>
Example:<br>
dotify generate output.pef<br>
</pre>
Example:

Optional arguments include:
`dotify generate output.pef`

## Optional Arguments ##
The following optional arguments are available:
* volumes
* sections
* pages
* eightdot
* rows
* cols
* duplex

## Volumes ##
### volumes ###
Set the number of volumes to generate.

<pre>
Example:<br>
dotify generate output.pef -volumes=3<br>
</pre>
Example:

## Pages ##
Set the number of pages in each volume.
`dotify generate output.pef --volumes=3`

<pre>
Example:<br>
dotify generate output.pef -pages=50<br>
</pre>
### sections ###
Sets the number of sections in each volume.

## Eight dot ##
Set to true to include 8-dot patterns.
Example:

`dotify generate output.pef --sections=3`

### pages ###
Set the number of pages in each volume.

Example:

<pre>
Example:<br>
dotify generate output.pef -eightdot=true<br>
</pre>
`dotify generate output.pef --pages=50`

## Rows ##
### rows ###
Set the maximum numbers of rows on a page.

<pre>
Example:<br>
dotify generate output.pef -rows=29<br>
</pre>
Example:

`dotify generate output.pef --rows=29`

## Cols ##
### cols ###
Set the maximum number of characters on a row.
<pre>
Example:<br>
dotify generate output.pef -cols=28<br>
</pre>

## Duplex ##
Set the duplex property.
<pre>
Example:<br>
dotify generate output.pef -duplex=true<br>
</pre>

Example:

`dotify generate output.pef --cols=28`

## Switches ##
The following switches are available:
* full-range (-f)
* simplex (-s)

### full-range ###
Set to true to include 8-dot patterns.

Example:

`dotify generate output.pef -f`


### simplex ###
Creates a single sided PEF-file.

Example:

`dotify generate output.pef -s`
13 changes: 9 additions & 4 deletions docs/MergePef.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,19 @@
[Table of Contents](toc.md)

# Merge several PEF-files #
Merge several PEF files into one.
Merges several PEF files into one.

The purpose is to facilitating the use of PEF-files with braille editors that do not support multi volume files.

Three arguments are required: _path to input folder_, _path to output file_ and identifier.

Optional arguments include:
## Optional Arguments ##
The following optional arguments are available:
* sort

## Sort ##
Set the sorting method to use when ordering files in the input folder.
### Sort ###
Set the sorting method to use when ordering files in the input folder.

Example:

`dotify merge /path/to/input /path/to/output identifier --sort=alpha`
15 changes: 8 additions & 7 deletions docs/PefToText.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,32 @@
[Table of Contents](toc.md)

# PEF to Text #
Convert a PEF-file document into a text braille file.
Converts a PEF-file document into a text braille file.

Two arguments are required _path to input file_ and _path to output file_.

Optional arguments include:
## Optional Arguments ##
The following optional arguments are available:
* range
* table
* breaks
* fallback
* replacement

## Range ##
### Range ###
Output a range of pages.

## Table ##
### Table ###
Set the table (character mapping) to use.

## Breaks ##
### Breaks ###
Set the line break style. Most braille applications use DOS line breaks.

## Fallback ##
### Fallback ###
Set the action to use if an eight dot pattern is encountered and the current table does not support eight dot:
* mask
* replace
* remove

## Replacement ##
### Replacement ###
Set the replacement character to use if an eight dot pattern is encountered and fallback is set to "replace".
2 changes: 1 addition & 1 deletion docs/SplitPef.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[Table of Contents](toc.md)

# Split a PEF-file #
Split a PEF file into several files, one file per volume.
Splits a PEF file into several files, one file per volume.

The purpose is to facilitating the use of PEF files with braille editors that do not support multi volume files.

Expand Down
Loading

0 comments on commit ac011a2

Please sign in to comment.