URL:
  <https://savannah.gnu.org/bugs/?64484>

                 Summary: [troff] .device and \X don't behave the same
                   Group: GNU roff
               Submitter: gbranden
               Submitted: Fri 28 Jul 2023 10:22:42 AM UTC
                Category: Core
                Severity: 3 - Normal
              Item Group: Incorrect behaviour
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any
         Planned Release: None


    _______________________________________________________

Follow-up Comments:


-------------------------------------------------------
Date: Fri 28 Jul 2023 10:22:42 AM UTC By: G. Branden Robinson <gbranden>
The `device` request and `X` escape sequence don't behave the same way when it
comes to encoding of things that aren't representable in the page description
language (_groff_out_(5)).

Exhibit:


$ cat EXPERIMENTS/device-vs-X.groff
.nf
foo
\X'baz: \%qux man-beast\[u1F63C]'
.device baz: \%qux man-beast\[u1F63C]
$ groff -Z EXPERIMENTS/device-vs-X.groff | grep '^x X'
x X baz: qux man-beast
x X baz: \%qux man-beast\[u1F63C]


This is _not_ a regression from _groff_ 1.22.4


$ /usr/bin/groff -Z EXPERIMENTS/device-vs-X.groff | grep '^x X'
troff: EXPERIMENTS/device-vs-X.groff:3: a special character is invalid within
\X
x X baz: qux man-beast
x X baz: \%qux man-beast\[u1F63C]


It seems likely to me that `device` was added to GNU _troff_ to provide a
request counterpart to the \X escape sequence (an AT&T device-independent
_troff_ feature), as `brp` did for `\p`.

I think we should either (1) get our story straight here (put the behavior
into parity) or (2) strongly call out the distinction in documentation and
supply use cases for why you'd employ one versus the other.

My preference is for (1) right now but I'd appreciate hearing from Deri, who
gives these features a lot of exercise in "pdf.tmac".







    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?64484>

_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/


Reply via email to