From 9bc0be2978b9c87eaf111d93339378a9e3b5bbc9 Mon Sep 17 00:00:00 2001 From: Philipp Gesang Date: Thu, 2 May 2013 22:05:22 +0200 Subject: accept node as argument for function ``get_user_whatsit_name`` --- luatexbase-attr.dtx | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/luatexbase-attr.dtx b/luatexbase-attr.dtx index 7c8f5b9..54c26f7 100644 --- a/luatexbase-attr.dtx +++ b/luatexbase-attr.dtx @@ -561,8 +561,14 @@ luatexbase.get_user_whatsit_id = get_user_whatsit_id % the package identifier it was registered with. % % \begin{macrocode} ---- int -> (string, string) -local get_user_whatsit_name = function (id) +--- int | node -> (string, string) +local get_user_whatsit_name = function (asked) + local id + if type(asked) == "number" then + id = asked + else --- node + id = asked.user_id + end return tableunpack(whatsit_ids[id]) end luatexbase.get_user_whatsit_name = get_user_whatsit_name -- cgit v1.2.3