This is "stitchcraft", a collection of interoperable terminal-oriented tools for generating cross-stitch patterns.
"stitchcraft" is free-as-in-mattress. It is several bits of software the author created to satisfy her own needs; if it's useful to you, great!
dune build
in the top-level directory of your cloned repository and follow any directions given in the Error
lines until the build succeeds. Once that happens, you should be able to dune exec
the individual programs from the project's top-level directory.
Pinning the package with opam pin
and then installing should work as well.
Stitchcraft is written in OCaml and uses several OCaml tools including the dune build system. See documentation there to get started.
A better user experience for such folks may come someday.
Stitchcraft bundles several subcommands under stitchcraft
, further subdivided into several categories. stitchcraft --help
should help you find what you're looking for.
If you're interested in writing your own OCaml program using these libraries, you'll probably be interested in stitchy/lib
, where core type definitions and several helpful operations are defined. Try a dune utop
in the top-level stitchcraft
directory to play around with what stitchcraft
offers.
Stitchcraft has a very limited facility for importing graphics. It understands only ASCII-mode netppm files, which you can generate via ImageMagick with magick -compress none inputfile.png outputfile.ppm
. Since that format does not support transparency, the user will probably want to invoke stitchcraft import image
with --ignore
to exclude pixels representing the background. The color matching is done against the built-in DMC color palette and uses redmean
, as described here, for finding the closest match.
This is implemented begrudgingly, and the results should not be expected to dazzle the viewer. Doing this well is difficult, and other programs do a better job.
All tools are built around the central stitchy
library and a simple JSON-based interchange format. As a tool of last resort, it is possible to hand-build patterns understandable by Stitchcraft, but I hope it's easier to use the libraries to build tools instead.
- tries its best to not fuck up when confronted with unicode
- looks cool on your terminal
- generates usable PDFs
- PDF export for large numbers of threads (currently the symbol and materials pages will overflow)
- a few included
glyphset
s for getting started - nicer
listing
preview graphics - Zoom in
stitchcraft view terminal
- vector font scaling and rasterization.
kxstitch
does this well. - backstitch support in
stitchcraft view terminal
. I anticipate any other terminal users also hating backstitch.
Most early work on this software was done at the Recurse Center, and supported financially by a fellowship from that organization. I am deeply grateful to RC for all its support in the past, present, and future.
The fonts included with this software were originally packaged by VileR and are available in their entirety at https://int10h.org. VileR has kindly packaged these fonts and provided them under a CC-BY-SA license.
This software depends heavily on notty, camlpdf, and various small and useful libraries from erratique.ch.
Lastly, the authors and maintainers of the OCaml language and its tooling have made an environment that I find joyful to work in. Thank you for helping me make things!