[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug #64957] [troff] commit 429723c3ec broke `device` and `output` reque
From: |
G. Branden Robinson |
Subject: |
[bug #64957] [troff] commit 429723c3ec broke `device` and `output` requests, and `pdfbackground` |
Date: |
Fri, 1 Dec 2023 14:44:11 -0500 (EST) |
URL:
<https://savannah.gnu.org/bugs/?64957>
Summary: [troff] commit 429723c3ec broke `device` and
`output` requests, and `pdfbackground`
Group: GNU roff
Submitter: gbranden
Submitted: Fri 01 Dec 2023 07:44:09 PM UTC
Category: Core
Severity: 3 - Normal
Item Group: Incorrect behaviour
Status: In Progress
Privacy: Public
Assigned to: gbranden
Open/Closed: Open
Discussion Lock: Any
Planned Release: None
_______________________________________________________
Follow-up Comments:
-------------------------------------------------------
Date: Fri 01 Dec 2023 07:44:09 PM UTC By: G. Branden Robinson <gbranden>
This problem
[https://git.savannah.gnu.org/cgit/groff.git/commit/?id=429723c3ec773a36313001ba70862fa6a7408984
arose on 10 November], but took a little while to notice.
The GNU _troff_(1) internal function `has_arg()` has a side effect of
advancing the token pointer (a sort of cursor into the input stream). So when
I changed `device_request()` and `output_request()` to use `has_arg()`, the
first character of the argument got stripped, making it unintelligible to the
output driver (_gropdf_(1)).
In other words,
.device pdf: niftyfeature arg1 arg2 arg3
became this.
.device df: niftyfeature arg1 arg2 arg3
The visible effect of this is that the background colors and box borders in
_msboxes.pdf_ went missing.
Nothing else broke (as far as I can tell) because (A) pretty much no part of
_groff_ appears to use the `output` request and (B) in most places where
device control commands are issued, it is done with `\X` escape sequences
which are not effected.
This isn't a problem with most other users of `has_arg()` because they proceed
to _use_ the token pointer. But these functions don't, because they gather
input with `get_copy()` instead.
I have a patch in preparation.
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?64957>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
- [bug #64957] [troff] commit 429723c3ec broke `device` and `output` requests, and `pdfbackground`,
G. Branden Robinson <=