From de673d0b39bff8d8da3d3818de7c79bf0143eb2c Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Sun, 31 Jan 2016 07:53:54 +0200 Subject: Include (1) in foo(1) into bold --- cli/context.cxx | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/cli/context.cxx b/cli/context.cxx index 11c9ecf..506c8fa 100644 --- a/cli/context.cxx +++ b/cli/context.cxx @@ -799,12 +799,10 @@ format_line (output_type ot, string& r, const char* s, size_t n) if (color) r += "\033[1m"; - r += link_target; + r += link_target + "(" + link_section + ")"; if (color) r += "\033[0m"; - - r += "(" + link_section + ")"; } if (!link_empty) @@ -840,10 +838,9 @@ format_line (output_type ot, string& r, const char* s, size_t n) r += link_target; else { - r += ""; - r += "" + link_target + ""; - r += "(" + link_section + ")"; - r += ""; + r += ""; + r += link_target + "(" + link_section + ")"; + r += ""; } } @@ -873,10 +870,7 @@ format_line (output_type ot, string& r, const char* s, size_t n) if (link_section.empty ()) r += link_target; else - { - r += "\\fB" + link_target + "\\fP"; - r += "(" + link_section + ")"; - } + r += "\\fB" + link_target + "(" + link_section + ")\\fP"; if (!link_empty) r += ")"; -- cgit v1.1