[luatex] pdfdecimaldigits < 4

David Carlisle d.p.carlisle at gmail.com
Tue Jan 19 16:58:42 CET 2016


On 19 January 2016 at 15:22, Hans Hagen <pragma at wxs.nl> wrote:

> On 1/19/2016 4:10 PM, David Carlisle wrote:
>
>> Hans wrote
>>  > unless of course you want to have worse output than possible (tex
>> itself is rather accurate)
>>
>> Well not really:-)
>>
>> I was just trying to chase down where the warning was coming from (as it
>> isn't mentioned in the manual)
>> and if we're going to ask texlive/miktex to change the default setting
>> for pdftex whether there is any documentation
>> of the minimal advisable level, rather than just documenting it as a
>> change to track changes in luatex.
>>
>> But in luatex, if there is a minimal value, I think it would be more
>> natural if pdf.setdecimaldigits(3) warned
>> (and set to 4) rather than the lua table value being set to 3 with no
>>
>
> in that case we set it to 3 and there is no need for a warning (not our
> responsibility then that users want 3 to start with; less work too)
>


But luatex 0.88 does give a warning???



$ luatex
This is LuaTeX, Version beta-0.88.0 (TeX Live 2016/dev)
 restricted system commands enabled.
**\directlua{pdf.setdecimaldigits(3)}

*x

*\bye

warning  (pdf backend): forcing decimal digits to 4
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[1{/usr/local/texlive/2015/texmf-var/fonts/map/pdftex/updmap/pdftex.map}]
(see the transcript file for additional
information)<</usr/local/texlive/2015/t
exmf-dist/fonts/type1/public/amsfonts/cm/cmr10.pfb>
Output written on texput.pdf (1 page, 8475 bytes).
Transcript written on texput.log.





>
> warning but then getting a warning from the backend
>> later (that is, it would seem more natural to me as a user: if that
>> violates an internal split between backend and main code,
>> I'll just have to re-align my expectations:-)
>>
>
> ha, you might also need to re-align you expectation that the the luatex
> backend is the same as the pdftex backend which is only partially true (we
> started out with the pdf backend but that's about it)
>
>
>

I think you misunderstood me, sorry I'll try again.

Forgetting all about pdftex,

I meant that my expectation was that if I do

pdf.setdecimaldigits(2)

and get no warning and

pdf.getdecimaldigits()

returns 2 then

2 decimal digits would be used, but actually what happens (as far as I can
see)
is that the backend (later) gives a warning and sets the effective value to
4
even though the lua value stays at 2.


If it isn't safe to set the value below 4 that's fine, I take your word for
it,
but why isn't the warning on the setter?

My reference to the backend was a guess at a possible answer that the
setdecimaldigits
could in theory be used with other backends and 2 might be acceptable so
the warning
belongs in the pdf back end as it is now.

That would also be fine if that's  case.

But since none of this is in the manual at all, I'm having to guess....





> Hans
>

David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tug.org/pipermail/luatex/attachments/20160119/fe9af937/attachment.html>


More information about the luatex mailing list