aboutsummaryrefslogtreecommitdiffstats
path: root/epan/print_stream.c
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2018-01-08 10:04:18 -0800
committerMichael Mann <mmann78@netscape.net>2018-01-08 19:45:50 +0000
commita6a5b552ece22737d04cdd92b05edacc0a3accf6 (patch)
treed8bf0c1518a9d37d5c8e19084fd1e4d8fc68126f /epan/print_stream.c
parent15746e5922159265468e3d5d19b2feb7b769a57a (diff)
Update a comment about Windows Console color support.
Change-Id: I39171a3c95ca48a39fbbc90ceadb9b1436f2402c Reviewed-on: https://code.wireshark.org/review/25196 Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/print_stream.c')
-rw-r--r--epan/print_stream.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/epan/print_stream.c b/epan/print_stream.c
index 44ed34e0a3..f85c87dace 100644
--- a/epan/print_stream.c
+++ b/epan/print_stream.c
@@ -43,9 +43,16 @@ print_color_escape(FILE *fh, const color_t *fg, const color_t *bg)
WORD win_fg_color = FOREGROUND_RED|FOREGROUND_BLUE|FOREGROUND_GREEN;
WORD win_bg_color = 0;
- /* Windows seems to offer 1-bit color, so you can't set the red, green, or blue intensities,
- * you can only set "{foreground, background} contains {red, green, blue}".
- * So include red, green or blue if the numeric intensity is high enough
+ /* The classic Windows Console offers 1-bit color, so you can't set
+ * the red, green, or blue intensities, you can only set
+ * "{foreground, background} contains {red, green, blue}". So
+ * include red, green or blue if the numeric intensity is high
+ * enough.
+ *
+ * The console in Windows 10 builds 14931 and later supports SGR RGB
+ * sequences. We might want to print those instead depending on the
+ * version of Windows or just remove the SetConsoleTextAttribute
+ * calls and only print SGR sequences.
*/
if (fg) {
if (((fg->red >> 8) & 0xff) >= 0x80)