groff
[Top][All Lists]
Advanced

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

Re: [groff] UTF8 characters to pdf


From: Colin Watson
Subject: Re: [groff] UTF8 characters to pdf
Date: Thu, 24 Jan 2019 13:30:18 +0000
User-agent: NeoMutt/20170113 (1.7.2)

On Thu, Jan 24, 2019 at 05:05:25AM +0000, jonathan ahumada wrote:
> I’m trying to get into groff  with the hopes that I could print my own
> literary drafts. However, I write in spanish and have had problems
> with accented characters such as (á, é, ó , etc). I have been
> searching and apparently groff doesn’t support utf-8, which is the
> format my files are written in. I have seen some people use a
> `preconv`command or a `-k` flag to convert their files for utf-8 into
> latin1 within the groff command.

Sort of; it preprocesses UTF-8 into ASCII plus \[uXXXX] escapes.  Using
preprocessors to transform the input in various ways is a routine
practice in groff.

On the phrasing in your last couple of sentences, I would rather say
that groff supports UTF-8, but only via preconv (which is part of
groff).

> But the build I have on my Mac computer doesn’t seem to have this
> (version 1.19.2).

Yeah, that is pretty prehistoric; groff 1.20 was released a full ten
years ago, and the current release is 1.22.4.  I'd really recommend you
try upgrading.

I'm not a Mac user so I don't know which you might prefer or what the
tradeoffs are, but MacPorts has 1.22.3 and Homebrew has 1.22.4.  Perhaps
you might try installing a newer version of groff from one of those?

> I know you can use escape sequences in order to tell the troff
> formatter to use certain characters, but modifying my files with a
> sort of tailored script to replace all my accents seems burdensome. 

You wouldn't actually modify your files, but just have the build script
you use to render them add the -k option.

-- 
Colin Watson                                       address@hidden



reply via email to

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