groff
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Groff] devpdf U-fonts and Russian


From: Keith Marshall
Subject: Re: [Groff] devpdf U-fonts and Russian
Date: Fri, 6 Oct 2017 10:26:36 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.4.0

On 05/10/17 20:40, Tadziu Hoffmann wrote:
>> Another strange thing is that, in case of using mixed
>> Russian/Latin symbols in pic and tbl objects, the Latin
>> letters and numbers become mis-positioned.
>> I wonder what I am possibly do wrong. The GROFF version is 1.22.2 
>> on Ubuntu 14.04. The compilation command used is:
>>
>> groff -Kutf8 -pet -Tpdf RuTest.rof > RuTest.pdf
> 
> Could this simply be a bug in gropdf and you're doing nothing wrong?

I too believe this may be the case; on my LMDE box:

  $ groff -Kutf8 -pet -Tpdf ~/tmp/RuTest.rof > ~/tmp/RuTest-0.pdf
  Invalid negative number (-1) in chr at /usr/bin/gropdf 
    line 3201, <> line 325.
  Use of uninitialized value in multiplication (*) at /usr/bin/gropdf 
    line 3035, <> line 325.
  Invalid negative number (-1) in chr at /usr/bin/gropdf 
    line 3201, <>  line 361.
  Invalid negative number (-1) in chr at /usr/bin/gropdf 
    line 3201, <> line 375.
  Invalid negative number (-1) in chr at /usr/bin/gropdf 
    line 3201, <> line 379.
  Invalid negative number (-1) in chr at /usr/bin/gropdf 
    line 3201, <>   line 391.
  Invalid negative number (-1) in chr at /usr/bin/gropdf 
    line 3201, <> line 937.
  Invalid negative number (-1) in chr at /usr/bin/gropdf 
    line 3201, <> line 939.
  Invalid negative number (-1) in chr at /usr/bin/gropdf 
    line 3201, <> line 1017.
  Wide character in compress at /usr/bin/gropdf line 1894.

(long error messages folded at line number indication), produces an 
invalid PDF; (the code for extending the .psbb request, to also handle 
PDF files, with which I've been dabbling, on and off, over the past 
three years, and am now close to having a working prototype[*], says):

  $ ./psbb ~/tmp/RuTest-0.pdf 
  psbb:t-psbb (t-psbb.cpp):194: PDF file '/home/keith/tmp/RuTest-0.pdf' 
    is malformed; no trailer found

(and sure enough, inspection reveals that not only is there no trailer 
present, there is no /Catalog object nor /Pages object either).

> I tested your file with the Postscript device (-Tps) and had no
> problems (also with groff 1.22.2).  (I had to copy U-TR, U-TI, U-TB,
> and U-TBI from devpdf to devps first, but made no other changes.)

Likewise:

  $ pdfroff --no-toc -Kutf8 -pet ~/tmp/RuTest.rof > ~/tmp/RuTest-1.pdf
  $ ./psbb ~/tmp/RuTest-1.pdf 
  /home/keith/tmp/RuTest-1.pdf: bounding box = (0,0)..(595,842)

silently produces valid PDF, with /MediaBox properties as indicated.

> Picture is attached, since Russian is all Greek to me. :-)

As it is for me; I've attached both the valid PDF from pdfroff, and the 
malformed one from gropdf.

BTW, a further gropdf bug becomes apparent with:

  $ gropdf --version
  Unknown option: version
  ^D
  Use of uninitialized value $fld in concatenation (.) or string 
    at /usr/bin/gropdf line 1923.
  ...

Neither --version nor --help options are supported, as they should be 
by *all* well behaved GNU programs ... contrast with:

  $ grops --version
  GNU grops (groff) version 1.22.2

[*]: I'll resurrect the original discussion, when I have something in 
a publicly accessible location.

-- 
Regards, Keith

Attachment: RuTest-0.pdf
Description: Adobe PDF document

Attachment: RuTest-1.pdf
Description: Adobe PDF document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]