Hello, values of number and title of the current (sub...)section can be received by \structurenumber and \structuretitle commands. Is there a way how to get these values by Lua? Suppose: ---- \starttext \section{Sec 1} % Now "\structurenumber" yields "1" and "\structuretitle" gives "Sec 1" % How to get "1" and "Sec 1" from Lua? \startluacode print(0, context["structuretitle"]) print(1, context["structuretitle"]()) print(2, context.getvalue("structuretitle")) print(3, context.constants("structuretitle")) print(4, context.variables("structuretitle")) \stopluacode \stoptext ---- My attempts don't give any useful value (or some of them are even erroneous). I have no idea how to get the texts "1" and "Sec 1". Any hints would be appreciated... Best regards, Lukas -- Ing. Lukáš Procházka [mailto:LPr@pontex.cz] Pontex s. r. o. [mailto:pontex@pontex.cz] [http://www.pontex.cz] Bezová 1658 147 14 Praha 4 Tel: +420 244 062 238 Fax: +420 244 461 038