# What is the meaning of pdf_literal whatits mode values?

In the luatex manual, in the 'Nodes' chapter, the pdf_literal whatits node is said to have a mode field that can take three integer values that are associated with pdftex keywords:

• 0 for setorigin,
• 1 for page,
• and 2 for direct.

I can find a reference in the pdftex manual for both page and direct but not for setorigin. What does it mean?

By the way, an example showing the three different behaviors would be great!

I'd guess from the name it evaluates with the (0,0) origin at the current point and the following seems to confirm that. It corresponds to the default, no keyword use of pdfliteral: not using a setorigin keyword in the TeX syntax despite the manual hinting that might work.

\protected\def\pdfliteral        {\pdfextension literal}

1 \pdfliteral direct {0 0 m 100 100 l s}

2 \pdfliteral page {0 0 m 100 200 l s}

3 \directlua{
local nd = node .new(8,16)
nd.mode=0 % setorigin
nd.data='0 0 m 100 50 l s'
node.write(nd)
}

4 \pdfliteral  {0 0 m 200 10 l s}

\bye