Hi Hans, assume we fixed between "\definelayer" and "\flushlayer" a whole ensemble of layers on a page. And by calculating per luacode we determined the leftmost and the rightmost edge of the ensemble and would now like to horizontally centre the ensemble. We don't know the rightmost edge before we placed the last layer. By luacode we can calculate how much the centring movement should be, because we know "\textwidth", but we cannot save the calculated centring value in the context program for another run. Saving the luacode values of hundred of pages in flattened lua tables would be possible, but rather awkward; the problem of relating pages to tables would arise, especially when pages are taken out or additional pages are inserted. Do you know a way to settle the centring in the same context run in which the layers are placed? Could "\flushlayer" perform it somehow? Rudolf