[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: @var{x_1} is funny in pdf
From: |
Gavin Smith |
Subject: |
Re: @var{x_1} is funny in pdf |
Date: |
Mon, 18 Jan 2021 21:56:40 +0000 |
User-agent: |
Mutt/1.9.4 (2018-02-28) |
On Mon, Jan 18, 2021 at 03:31:53PM -0600, Leo Butler wrote:
> Gavin Smith <gavinsmith0123@gmail.com> writes:
>
> > On Mon, Jan 18, 2021 at 9:15 PM Leo Butler <leo.butler@umanitoba.ca> wrote:
> >>
> >> Gavin Smith <gavinsmith0123@gmail.com> writes:
> >>
> >> > As it happens, there was a hook recently added to texinfo.tex to omit
> >> > the page number, which looks a lot like the patch you sent (change on
> >> > 2020-11-17). If you say "@set txiomitrefpg" the page numbers won't be
> >> > output. I've uploaded the newer texinfo.tex to ftp.gnu.org/gnu/texinfo
> >> > now. This is still not documented anywhere.
> >>
> >> Hi Gavin,
> >>
> >> That hook does not work quite the way I would like. Since you only test
> >> if txiomitrefpg is ever set, there is little discretion possible. What I
> >> would like is the ability to selectively include (or exclude) page
> >> refs. E.g. define
> >>
> >> \def\pagelessref#1{\txiomitrefpgtrue\ref{#1}}
> >> \def\pagefulref#1{\txiomitrefpgfalse\ref{#1}}
> >>
> >> and intermingle their use.
> >
> > You can clear the flag after you set it with "@clear txiomitrefpg".
> >
> >> In texinfo.tex, rather than
> >>
> >> \expandafter\ifx\csname SETtxiomitxrefpg\endcsname\relax
> >>
> >> have
> >>
> >> \iftxiomitrefpg
> >
> > Doing it with @set means we can avoid having to invent new Texinfo
> > commands like @txiomitrefpgtrue etc.
>
> Fair enough. What I want to convey is that the `value' of \txiomitrefpg
> should be tested, not whether it has been set. E.g.
>
> \def\pagelessref#1{\let\txiomitrefpg=1\ref{#1}}
> \def\pagefulref#1{\let\txiomitrefpg=0\ref{#1}}
>
> and
>
> \ifnum\txiomitrefpg=1\relax
>
> Leo
That's how other @set flags are checked in texinfo.tex. I think you
are missing the context of how @set and @clear work.