With OrgMark, you can use iPad to draw figures and insert them into Org files. You can also edit these figures later.
- Open the workspace with Xcode, you will see two projects, Build Org Mark for iPad and orgmark for Mac.
- Put the orgmark executable under PATH.
- Install the Org Mark app to your iPad (by whatever means).
- Put orgmark.el under your
load-pathand require it.
From Org mode:
M-x orgmark-insert, or
Alternately, you can use orgmark from command line. The extension has to be “pkdrawing”.
$ orgmark --help OVERVIEW: Send drawing to iPad to edit. USAGE: command <file-path> [--width <width>] [--height <height>] [--new] ARGUMENTS: <file-path> The drawing file. If --new option is set, this is the file that we save to. OPTIONS: -w, --width <width> Max width of the exported image in pixels. -h, --height <height> Max height of the exported image in pixels. -n, --new Create new drawing. -h, --help Show help information.
How does it work
- Draw on iPad and iPad saves the drawing to a binary data.
- iPad sends the data and a generated png file to cli.
- Cli sends the binary data to iPad for edit, iPad sends the edited binary data and png to cli.
A better way would be using an open drawing library, so we can export the drawing to some open formats, like SVG. I just went with the most trivial route.
- Only support pkdrawing files (which is an extension I made up for storing Apple’s PencilKit binary drawing data).
- Crashes and hangs, this is really just a quick hack on top of existing solutions (PencilKit).
- Only works on WiFi. I tried with BLE, but the bandwidth is too low for the data we are transferring.