groff-commit
[Top][All Lists]
Advanced

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

[groff] 19/60: [troff]: Slightly refactor.


From: G. Branden Robinson
Subject: [groff] 19/60: [troff]: Slightly refactor.
Date: Wed, 11 Sep 2024 03:38:30 -0400 (EDT)

gbranden pushed a commit to branch master
in repository groff.

commit f3684d2c49ce204995354fc964ca3d65f44462ba
Author: G. Branden Robinson <g.branden.robinson@gmail.com>
AuthorDate: Sun Sep 8 18:57:48 2024 -0500

    [troff]: Slightly refactor.
    
    * src/roff/troff/node.cpp (troff_output_file::start_device_extension):
      Call `flush_tbuf()` before any other function that may write to
      device-independent output.
---
 ChangeLog               | 7 +++++++
 src/roff/troff/node.cpp | 2 +-
 2 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/ChangeLog b/ChangeLog
index e37021d04..d6c0381ae 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2024-09-08  G. Branden Robinson <g.branden.robinson@gmail.com>
+
+       * src/roff/troff/node.cpp
+       (troff_output_file::start_device_extension): Call `flush_tbuf()`
+       before any other function that may write to device-independent
+       output.
+
 2024-09-08  G. Branden Robinson <g.branden.robinson@gmail.com>
 
        * src/roff/troff/node.cpp
diff --git a/src/roff/troff/node.cpp b/src/roff/troff/node.cpp
index 4082a3eef..dba92132e 100644
--- a/src/roff/troff/node.cpp
+++ b/src/roff/troff/node.cpp
@@ -890,10 +890,10 @@ void troff_output_file::start_device_extension(tfont *tf, 
color *gcol,
                                               color *fcol,
                                               bool omit_command_prefix)
 {
+  flush_tbuf();
   set_font(tf);
   stroke_color(gcol);
   fill_color(fcol);
-  flush_tbuf();
   do_motion();
   if (!omit_command_prefix)
     put("x X ");



reply via email to

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