groff-commit
[Top][All Lists]
Advanced

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

[groff] 21/28: [grops,troff]: Migrate to term "scaling unit".


From: G. Branden Robinson
Subject: [groff] 21/28: [grops,troff]: Migrate to term "scaling unit".
Date: Mon, 14 Feb 2022 01:47:04 -0500 (EST)

gbranden pushed a commit to branch master
in repository groff.

commit a3e8e4c545aa6d58601d5c23406c27bdda49a6a5
Author: G. Branden Robinson <g.branden.robinson@gmail.com>
AuthorDate: Sat Feb 12 18:00:47 2022 +1100

    [grops,troff]: Migrate to term "scaling unit".
    
    ...in diagnostics.
    
    * src/devices/grops/ps.cpp (ps_printer::do_import):
    * src/roff/troff/input.cpp (warnscale_request):
    * src/roff/troff/number.cpp (parse_term): Do it.
    
    Much of our documentation remains to be updated.
---
 ChangeLog                 | 8 ++++++++
 src/devices/grops/ps.cpp  | 2 +-
 src/roff/troff/input.cpp  | 2 +-
 src/roff/troff/number.cpp | 8 ++++----
 4 files changed, 14 insertions(+), 6 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 7407ff62..46ed6d86 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2022-02-12  G. Branden Robinson <g.branden.robinson@gmail.com>
+
+       [grops,troff]: Migrate to term "scaling unit" in diagnostics.
+
+       * src/devices/grops/ps.cpp (ps_printer::do_import):
+       * src/roff/troff/input.cpp (warnscale_request):
+       * src/roff/troff/number.cpp (parse_term): Do it.
+
 2022-02-12  G. Branden Robinson <g.branden.robinson@gmail.com>
 
        [me]: Add nroff mode fallback for `u` macro.
diff --git a/src/devices/grops/ps.cpp b/src/devices/grops/ps.cpp
index 83acb111..f762cb70 100644
--- a/src/devices/grops/ps.cpp
+++ b/src/devices/grops/ps.cpp
@@ -1693,7 +1693,7 @@ void ps_printer::do_import(char *arg, const environment 
*env)
     p = end;
   }
   if (csalpha(*p) && (p[1] == '\0' || p[1] == ' ' || p[1] == '\n')) {
-    error("scaling indicators not allowed in arguments for X import command");
+    error("scaling units not allowed in arguments for X import command");
     return;
   }
   while (*p == ' ' || *p == '\n')
diff --git a/src/roff/troff/input.cpp b/src/roff/troff/input.cpp
index 03d8dea3..8a3d61b1 100644
--- a/src/roff/troff/input.cpp
+++ b/src/roff/troff/input.cpp
@@ -6893,7 +6893,7 @@ void warnscale_request()
       warn_scale = (double)units_per_inch / 6.0;
     else {
       warning(WARN_SCALE,
-             "invalid scaling indicator '%1', using 'i' instead", c);
+             "scaling unit '%1' invalid; using 'i' instead", c);
       c = 'i';
     }
     warn_scaling_indicator = c;
diff --git a/src/roff/troff/number.cpp b/src/roff/troff/number.cpp
index 8e999912..aec446d0 100644
--- a/src/roff/troff/number.cpp
+++ b/src/roff/troff/number.cpp
@@ -460,7 +460,7 @@ static int parse_term(units *v, int scaling_indicator,
        scaling_indicator = c;
       }
       else {
-       error("expected ';' after scaling indicator (got %1)",
+       error("expected ';' after scaling unit (got %1)",
              tok.description());
        return 0;
       }
@@ -553,11 +553,11 @@ static int parse_term(units *v, int scaling_indicator,
   if ((c = tok.ch()) != 0 && strchr(SCALE_INDICATOR_CHARS, c) != 0) {
     switch (scaling_indicator) {
     case 0:
-      warning(WARN_SCALE, "scaling indicator invalid in context");
+      warning(WARN_SCALE, "scaling unit invalid in context");
       break;
     case 'z':
       if (c != 'u' && c != 'z') {
-       warning(WARN_SCALE, "'%1' scaling indicator invalid in context;"
+       warning(WARN_SCALE, "'%1' scaling unit invalid in context;"
                " convert to 'z' or 'u'", c);
        break;
       }
@@ -568,7 +568,7 @@ static int parse_term(units *v, int scaling_indicator,
       break;
     default:
       if (c == 'z') {
-       warning(WARN_SCALE, "'z' scaling indicator invalid in context");
+       warning(WARN_SCALE, "'z' scaling unit invalid in context");
        break;
       }
       si = c;



reply via email to

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