On 2012-09-04 Wolfgang Schuster
What prevents you from setting the dimen value in Lua?
Some background: The code is part of a smarter float placement. It takes the size of the float into account and decides for a location. For example, it positions the float in the margin if it fits or it prints the caption underneath the float if the float spans the margin as well (captions are in the margin by default in this layout). Most of the code is written in TeX and I don't feel it's necessary to rewrite it in Lua. I am more fluent in TeX than in Lua. In this case a TeX helper function computes the size and saves the results in dimen registers. I use Lua for calculations especially when it comes to dimensions. It's a nightmare in TeX and hard to find errors easily creep in. Marco