Skip to content

theLastJavaBuilder/AsciidocFX

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

213 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Asciidoc Book Editor based on JavaFX 8

Asciidoc FX is a book / document editor to build HTML, PDF, Epub or Mobi ebooks.

asciidocfx
Figure 1. AsciidocFX

Features

  • Multi-platform (Windows, Mac, Linux ..)

  • Creating Asciidoc Books

  • Creating PDF, HTML, Epub, Mobi, Docbook

  • Full-Screen & External Browser Support

  • Real-Time Preview

  • Table Generator

  • MathJax Support

  • PlantUML Support

PlantUML Support

You can fulfill your UML needs with AsciidocFX. It supports PlantUML.

PlantUML is a component that allows to quickly write :

  • Sequence diagram,

  • Usecase diagram,

  • Class diagram,

  • Activity diagram, (here is the new syntax),

  • Component diagram,

  • State diagram,

  • Object diagram.

  • wireframe graphical interface

.UML Diagram Example
[uml,file="uml-example.png"]
--
abstract class AbstractList
abstract AbstractCollection
interface List
interface Collection

List <|-- AbstractList
Collection <|-- AbstractCollection

Collection <|- List
AbstractCollection <|- AbstractList
AbstractList <|-- ArrayList

class ArrayList {
  Object[] elementData
  size()
}

enum TimeUnit {
  DAYS
  HOURS
  MINUTES
}

annotation SuppressWarnings
--
uml example
Figure 2. UML example output
Note
In some UML elements, PlantUML needs to work with Graphviz. Because of this, you should install Graphviz manually for your platform. After installing Graphviz, you should set GRAPHVIZ_DOT environment variable to dot executable in Graphviz.

MathJax Support

MathJax is an open source JavaScript display engine for mathematics that works in all browsers.

You can use Tex or MathML languages for describing mathematical formulas in AsciidocFX. AsciidocFX converts this textual formulas as png image.

For Example (Tex)
[math,file="tex-formula.png"]
--
\begin{align}
\dot{x} & = \sigma(y-x) \\
\dot{y} & = \rho x - y - xz \\
\dot{z} & = -\beta z + xyp
\end{align}
--

Tex output

tex formula
For Example (MathML)
[math,file="mathml-formula.png"]
--
<math xmlns="http://www.w3.org/1998/Math/MathML" display="block">
  <mi>x</mi>
  <mo>=</mo>
  <mrow>
    <mfrac>
      <mrow>
        <mo>&#x2212;</mo>
        <mi>b</mi>
        <mo>&#xB1;</mo>
        <msqrt>
          <msup>
            <mi>b</mi>
            <mn>2</mn>
          </msup>
          <mo>&#x2212;</mo>
          <mn>4</mn>
          <mi>a</mi>
          <mi>c</mi>
        </msqrt>
      </mrow>
      <mrow>
        <mn>2</mn>
        <mi>a</mi>
      </mrow>
    </mfrac>
  </mrow>
  <mtext>.</mtext>
</math>
--

MathML output

mathml formula
Important
Requires Internet Connection. AsciidocFX fetchs MathJax dependencies from CDN.

How to Run AsciidocFX (For Users)

  1. Firstly, install JRE 8

  2. Download the latest AsciidocFX.zip and Extract it

  3. Run

    • bin/asciidocfx.bat or bin/asciidocfx.sh

How to Build executable JAR (For Developers)

  1. Firstly, install JDK 8

  2. Download Apache Maven and set /bin directory to environment variables

  3. Enter AsciidocFX directory and run $ mvn clean install

  4. Follow to target/ directory and you will see AsciidocFX.zip

Book Written with AsciidocFX

Java 8 Ebook
AspectJ Ebook

Used Technologies

AsciidocFX uses Java, JavaScript and XML related technologies.

  • Java FX 8

  • Asciidoctor.js

  • Spring Boot

  • Spring WebSocket

  • Docbook

  • Apache Fop

  • Saxon 6.5

  • Ace editor

AsciidocFX Configuration

You can configurate AsciidocFX with config.yml file in /conf directory

You can change Ace theme, font size, font family and other sections by editing it.

Some Shortcuts

AsciidocFX has some custom shortcuts. If you suggest us any shortcut request, we can implement it.

Shortcut Detail

tblx,y+Tab

Generates asciidoc table (x=row,y=column)

tblx.y+Tab

Generates asciidoc table (x=row,y=column)

src+Tab

Generates asciidoc source block (default lang: java)

src.lang+Tab

Generates asciidoc source block by lang

src,lang+Tab

Generates asciidoc source block by lang

img+Tab

Generates image section

book+Tab

Generates book header section

uml+Tab

Generates UML block

math+Tab

Generates Math block

Ctrl+B

Bolds selection

Ctrl+I

Italices selection

Ctrl+U

Underlines selection

Ctrl+D

Duplicates selection

Ctrl+X

Removes current line

Ctrl+N

Creates new empty doc

Ctrl+S

Saves current doc

Ctrl+W

Saves and closes current doc

Ctrl+Shift+C

Surrounds backtick `` selection

Ctrl+Mouse_Scroll_Up

Zoom in

Ctrl+Mouse_Scroll_Down

Zoom out

F12

Opens Firebug Lite (Requires Internet Connection)

Support

Support AsciidocFX with pull request or open an issue for bug & feature request. You can make discussions in mail group. https://groups.google.com/d/forum/asciidocfx-discuss

Rahman USTA
[email protected]

Thanks.

About

Asciidoc Book Editor based on Java FX 8

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages

  • Java 99.5%
  • Other 0.5%