gbranden pushed a commit to branch master
in repository groff.

commit 781a7087ca59ec714a076bf912e3383c72391388
Author: G. Branden Robinson <[email protected]>
AuthorDate: Wed May 6 07:52:13 2026 -0500

    [troff]: Rename `.zoom` register to `.fzoom`.
    
    * src/roff/troff/env.cpp (init_env_requests): Do it.
    * tmac/troffrc: Configure alias for backward compatibility.
    
    * doc/groff.texi.in (Selecting Fonts):
    * man/groff.7.man (Read-only registers):
    * man/groff_diff.7.man (New register):
    * NEWS: Document change.
    
    Fixes <https://savannah.gnu.org/bugs/?68288>.
---
 ChangeLog              | 14 ++++++++++++++
 NEWS                   |  6 ++++++
 doc/groff.texi.in      |  4 ++--
 man/groff.7.man        | 14 ++++++--------
 man/groff_diff.7.man   | 17 +++++++----------
 src/roff/troff/env.cpp |  2 +-
 tmac/troffrc           |  3 +++
 7 files changed, 39 insertions(+), 21 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index adfe8e2e7..06f63f95b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,17 @@
+2026-05-06  G. Branden Robinson <[email protected]>
+
+       [troff]: Rename `.zoom` register to `.fzoom`.
+
+       * src/roff/troff/env.cpp (init_env_requests): Do it.
+       * tmac/troffrc: Configure alias for backward compatibility.
+
+       * doc/groff.texi.in (Selecting Fonts):
+       * man/groff.7.man (Read-only registers):
+       * man/groff_diff.7.man (New register):
+       * NEWS: Document change.
+
+       Fixes <https://savannah.gnu.org/bugs/?68288>.
+
 2026-05-06  G. Branden Robinson <[email protected]>
 
        Relocate "pdfmom" in source tree.
diff --git a/NEWS b/NEWS
index 5cab6056c..20df87a02 100644
--- a/NEWS
+++ b/NEWS
@@ -60,6 +60,12 @@ troff
    words from the current hyphenation language's list thereof.  Those
    supplied by files like "tmac/hyphenex.{cs,en,pl}" are retained.
 
+*  The built-in, read-only register `.zoom` is now named `.fzoom` for
+   consistency with other GNU troff extensions, which largely pair
+   names of request with those of read-only registers they affect.  The
+   old name remains as an alias configured by the default "troffrc"
+   file.
+
 Macro packages
 --------------
 
diff --git a/doc/groff.texi.in b/doc/groff.texi.in
index 7a34bac47..6210dd55b 100644
--- a/doc/groff.texi.in
+++ b/doc/groff.texi.in
@@ -12835,7 +12835,7 @@ request.@footnote{@xref{Debugging}.}
 @endDefreq
 
 @DefreqList {fzoom, font [@Var{zoom}]}
-@DefregListEndx {.zoom}
+@DefregListEndx {.fzoom}
 @cindex magnification, font, request (@code{fzoom})
 @cindex font magnification request(@code{fzoom})
 @cindex zoom factor of a font (@code{fzoom})
@@ -12890,7 +12890,7 @@ M\F[H]M\F[C]M\F[P]M
 
 The zoom factor of the currently selected font
 is available in the read-only register
-@samp{.zoom}.
+@samp{.fzoom}.
 It interpolates zero if there is no magnification.
 @endDefreq
 
diff --git a/man/groff.7.man b/man/groff.7.man
index 3ec6ee439..6b39aa5a5 100644
--- a/man/groff.7.man
+++ b/man/groff.7.man
@@ -7619,6 +7619,12 @@ and
 Next non-zero free font mounting position index.
 .
 .TP
+.REG .fzoom
+Magnification of the environment's selected font
+(in thousandths;
+zero if no magnification).
+.
+.TP
 .REG .g
 Always true in GNU
 .I troff \" GNU
@@ -8050,14 +8056,6 @@ formatter.
 Name of diversion (string-valued).
 .
 Empty if output is directed to the top-level diversion.
-.
-.TP
-.REG .zoom
-Magnification of the environment's selected font
-(in thousandths;
-zero if no magnification);
-see
-.request fzoom .
 .LE
 .
 .
diff --git a/man/groff_diff.7.man b/man/groff_diff.7.man
index c771bcf5f..8df251351 100644
--- a/man/groff_diff.7.man
+++ b/man/groff_diff.7.man
@@ -5195,6 +5195,13 @@ Interpolate next free non-zero font mounting position.
 .
 .
 .TP
+.B \[rs]n[.fzoom]
+Interpolate magnification of the environment's selected font,
+in thousandths,
+or\~0 if magnification unused.
+.
+.
+.TP
 .B \[rs]n[.g]
 Interpolate\~1.
 .
@@ -5549,16 +5556,6 @@ and
 above.
 .
 .
-.TP
-.B \[rs]n[.zoom]
-Interpolate magnification of the environment's selected font,
-in thousandths,
-or\~0 if magnification unused.
-.
-See
-.BR fzoom .
-.
-.
 .P
 The following (writable) registers are set by the
 .B psbb
diff --git a/src/roff/troff/env.cpp b/src/roff/troff/env.cpp
index 2e7341697..f50298367 100644
--- a/src/roff/troff/env.cpp
+++ b/src/roff/troff/env.cpp
@@ -4713,7 +4713,7 @@ void init_env_requests()
   init_int_env_reg(".ul", get_underlined_line_count);
   init_vunits_env_reg(".v", get_vertical_spacing);
   init_hunits_env_reg(".w", get_prev_char_width);
-  init_int_env_reg(".zoom", get_zoom);
+  init_int_env_reg(".fzoom", get_zoom);
   register_dictionary.define("ct", new variable_reg(&ct_reg_contents));
   register_dictionary.define("hp", new horizontal_place_reg);
   register_dictionary.define("ln", new variable_reg(&next_line_number));
diff --git a/tmac/troffrc b/tmac/troffrc
index 9c305d6b9..ea12363f4 100644
--- a/tmac/troffrc
+++ b/tmac/troffrc
@@ -74,6 +74,9 @@ troffrc!html
 .  pwh
 ..
 .
+.\" groff 1.25 renamed the '.zoom' register to '.fzoom'.
+.do aln .zoom .fzoom
+.
 .
 .\" Local Variables:
 .\" mode: nroff

_______________________________________________
groff-commit mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/groff-commit

Reply via email to