From f84bebbb3023945884a98cb894d4d4b79d362f02 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Fri, 18 Aug 2017 09:41:45 -0400 Subject: [PATCH] strip / from displayed path when printing bindings to HTML --- libs/gtkmm2ext/bindings.cc | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/libs/gtkmm2ext/bindings.cc b/libs/gtkmm2ext/bindings.cc index 291cd60686..e6f26bfa2b 100644 --- a/libs/gtkmm2ext/bindings.cc +++ b/libs/gtkmm2ext/bindings.cc @@ -825,17 +825,21 @@ Bindings::save_all_bindings_as_html (ostream& ostr) for (p = paths.begin(), k = keys.begin(), l = labels.begin(); p != paths.end(); ++k, ++p, ++l) { + string print_path = *p; + /* strip / from the start */ + print_path = print_path.substr (10); + if ((*k).empty()) { - ostr << *p << " ( " << *l << " ) " << "
" << endl; + ostr << print_path << " ( " << *l << " ) " << "
" << endl; } else { - ostr << *p << " ( " << *l << " ) " << " => " << *k << "
" << endl; + ostr << print_path << " ( " << *l << " ) " << " => " << *k << "
" << endl; } } } ostr << "\n\n"; ostr << "\n\n"; ostr << "\n\n"; - + ostr << "\n"; ostr << "\n"; }