GitXplorerGitXplorer
c

ob-blockdiag.el

public
10 stars
4 forks
0 issues

Commits

List of commits on branch master.
Verified
c3794bf7bdb8fdb3db90db41619dda4e7d3dd7b9

Merge pull request #6 from weirdvic/master

ccorpix committed 4 years ago
Unverified
1a1fe95d40c4976d3d9abe02c6ab23f803953c5e

Updated customization section

wweirdvic committed 4 years ago
Verified
e997644e81cc67a7092e6e9bb13c66f160491efb

Merge pull request #5 from weirdvic/master

ccorpix committed 4 years ago
Unverified
bc1da5975ddadebd5bd168f727e2add4d2a85613

Fix font parameter. Separate transparency and antialias parameter.

wweirdvic committed 4 years ago
Verified
86c28f258736af07a849a19b931d4de434fd3985

Merge pull request #4 from weirdvic/master

ccorpix committed 4 years ago
Unverified
c907a2bbf89b3a2bf75773f584790bf49cdb4b4f

Support :options parameter

wweirdvic committed 4 years ago

README

The README file for this repository.

ob-blockdiag.el

An extension for org-babel to support blockdiag.

Installation

This package is availaple in MELPA.

How to enable MELPA.

With "MELPA enabled emacs" you could install this package by typing this sequence:

M-x
package-install
ob-blockdiag
⏎

Now you could enable this package in your Emacs config with:

(org-babel-do-load-languages 'org-babel-load-languages
 '((blockdiag . t))
)

Example

Blockdiag in Fedora installed from python3-blockdiag package which has unusual executable name. Output file name is ololo.png

#+BEGIN_SRC blockdiag :tool blockdiag-3.5 :file ololo.png
blockdiag {
   A [label = "foo"];
   B [label = "bar"];
   C [label = "baz"];
   A -> B [label = "click bar", textcolor="red"];
   B -> C [label = "click baz"];
   C -> A;
}
#+END_SRC

Arguments

There are some things you could customize:

- `:tool` if you have blockdiag in unusual location or want to use seqdiag or [others](http://blockdiag.com/en/#table-of-contents)
- `:transparency t` to make transparent background of diagram (PNG only)
- `:antialias t` pass diagram image to anti-alias filter
- `:font` if you want the `:tool` to use provided font
- `:size` if you want the `:tool` to use custom size
- `:type` if you want the `:tool` to use different file format type, e.g. pdf, svg

Errors and output

It recreates a buffer with name *ob-blockdiag* every time you evaluating something.

There will be errors and output.