groff-commit
[Top][All Lists]
Advanced

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

[groff] 09/25: [troff]: Rearrange `pev` request output.


From: G. Branden Robinson
Subject: [groff] 09/25: [troff]: Rearrange `pev` request output.
Date: Tue, 29 Oct 2024 02:26:04 -0400 (EDT)

gbranden pushed a commit to branch master
in repository groff.

commit 1f90f944822ec6cb1cda60cc9d33736477e0704d
Author: G. Branden Robinson <g.branden.robinson@gmail.com>
AuthorDate: Wed Oct 23 17:05:54 2024 -0500

    [troff]: Rearrange `pev` request output.
    
    * src/roff/troff/env.cpp (environment::print_env): Rearrange output.
      Lead with all of the troff-specific environment data (if not in nroff
      mode).  Report inter-word and inter-sentence space sizes after font
      data and before line length data.
---
 ChangeLog              |  7 +++++++
 src/roff/troff/env.cpp | 20 +++++++++-----------
 2 files changed, 16 insertions(+), 11 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index b6235fe6b..16ff148ce 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2024-10-23  G. Branden Robinson <g.branden.robinson@gmail.com>
+
+       * src/roff/troff/env.cpp (environment::print_env): Rearrange
+       output.  Lead with all of the troff-specific environment data
+       {if not in nroff mode}.  Report inter-word and inter-sentence
+       space sizes after font data and before line length data.
+
 2024-10-23  G. Branden Robinson <g.branden.robinson@gmail.com>
 
        * src/roff/troff/env.cpp (font_size::dump_size_list): Fix
diff --git a/src/roff/troff/env.cpp b/src/roff/troff/env.cpp
index aa43a543e..c3c341e21 100644
--- a/src/roff/troff/env.cpp
+++ b/src/roff/troff/env.cpp
@@ -3465,12 +3465,6 @@ void environment::print_env()
   //     tab_field_spaces, tab_precedes_field
   //   composite
   //
-  errprint("  previous line length: %1u\n",
-          prev_line_length.to_units());
-  errprint("  line length: %1u\n", line_length.to_units());
-  errprint("  previous title line length: %1u\n",
-          prev_title_length.to_units());
-  errprint("  title line length: %1u\n", title_length.to_units());
   if (!in_nroff_mode) {
     errprint("  previous type size: %1p (%2s)\n",
             prev_size.to_points(), prev_size.to_scaled_points());
@@ -3480,19 +3474,23 @@ void environment::print_env()
             prev_requested_size);
     errprint("  requested type size: %1s\n", requested_size);
     font_size::dump_size_list();
+    errprint("  previous default family: '%1'\n",
+            prev_family->nm.contents());
+    errprint("  default family: '%1'\n", family->nm.contents());
   }
   errprint("  previous font selection: %1 ('%2')\n", prev_fontno,
           get_font_name(prev_fontno, this).contents());
   errprint("  font selection: %1 ('%2')\n", fontno,
           get_font_name(fontno, this).contents());
-  if (!in_nroff_mode) {
-    errprint("  previous default family: '%1'\n",
-            prev_family->nm.contents());
-    errprint("  default family: '%1'\n", family->nm.contents());
-  }
   errprint("  space size: %1/12 of font space width\n", space_size);
   errprint("  sentence space size: %1/12 of font space width\n",
           sentence_space_size);
+  errprint("  previous line length: %1u\n",
+          prev_line_length.to_units());
+  errprint("  line length: %1u\n", line_length.to_units());
+  errprint("  previous title line length: %1u\n",
+          prev_title_length.to_units());
+  errprint("  title line length: %1u\n", title_length.to_units());
   errprint("  previous line interrupted/continued: %1\n",
           prev_line_interrupted ? "yes" : "no");
   errprint("  filling: %1\n", is_filling ? "on" : "off");



reply via email to

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