Hi, the samepage option for xtables doesn’t work because of bugs in the Lua code. 1. On line 895 the value has to be taken from the rp-variable itself. 2. On line 905 the second index to get the value for the samepage option is missing. function xtables.construct() ... result[nofr] = { hbox, size, i < nofrange and rowdistance > 0 and rowdistance or false, -- might move false, - rp and rp.samepage or false, + rp or false, } end end if nofr > 0 then -- the [5] slot gets the after break result[1] [5] = false result[nofr][5] = false for i=2,nofr-1 do - local r = result[i] + local r = result[i][5] if r == v_both or r == v_before then result[i-1][5] = true elseif r == v_after then result[i][5] = true end end end return result end ... end Wolfgang