Can I use MetaPost lettrine-generator 0.1.0a created by Sergey Slyusarev in LuaLaTeX? If so, how?
lettrines.mp takes a list from
lettrineslist.txt file, like this and produces .mps (or you can change it to, say, svg or png) files which can then be linked to your document. To produce the images you have to run
In case of my rendition of Byrne's book, there's a macro in ConTeXt, which produces
lettrineslist.txt file and places the images. In LuaLaTeX you can do something similar or you can do it by hand.
There are two reasons i didn't embed
lettrines.mp into the document itself for the images to be placed there directly. First, i found no way to use metapost's
glyph function in rhe LuaTeX's mplib, i. e. i couldn't find a way to get glyph outlines from the font glyphs. Second,
lettrines.mp algorithm is way too slow and you don't want to run it every time you produce your pdf.
As Henri Menke points out below, the first reason not to embed
lettrines.mp code does not hold, since in ConTeXt you can actually obtain glyph outlines easily and it's possible to do in LuaLaTeX as well. So in the future i'll try to modify the code for it to be more portable and more easily embeddable, but with the version 0.1.0a, unfortunately, you'd have to use standalone metapost compiler.