From bfe5f4a2ec6af4d1c7ea8df48b1859effd6d4528 Mon Sep 17 00:00:00 2001 From: Charles Dang Date: Mon, 19 Mar 2018 10:35:30 +1100 Subject: [PATCH] Some build fixups to reflect changes since the help commits were originally made --- data/gui/widget/toggle_button_help_topic.cfg | 3 --- src/gui/dialogs/help_browser.cpp | 2 +- src/help/help_impl.cpp | 5 ++--- 3 files changed, 3 insertions(+), 7 deletions(-) diff --git a/data/gui/widget/toggle_button_help_topic.cfg b/data/gui/widget/toggle_button_help_topic.cfg index 36dac6895659..81bffb69b560 100644 --- a/data/gui/widget/toggle_button_help_topic.cfg +++ b/data/gui/widget/toggle_button_help_topic.cfg @@ -19,9 +19,6 @@ description = "This toggle button is meant to be used in topic tree in the help browser" [resolution] - - {GUI_NORMAL__RESOLUTION} - min_width = 26 min_height = 26 diff --git a/src/gui/dialogs/help_browser.cpp b/src/gui/dialogs/help_browser.cpp index 7ba80ce52016..4de8ae75c087 100644 --- a/src/gui/dialogs/help_browser.cpp +++ b/src/gui/dialogs/help_browser.cpp @@ -128,7 +128,7 @@ static std::string format_help_text(const config& cfg) throw help::parse_error(msg.str()); }; // TODO: Get the proper link shade from somewhere - ss << font::format_as_link(font::escape_text(item.cfg["text"]), "#ffff00"); + ss << font::format_as_link(font::escape_text(item.cfg["text"]), color_t::from_hex_string("ffff00")); } else if(item.key == "img") { if(item.cfg["src"].empty()) { throw help::parse_error("Img markup must have src attribute."); diff --git a/src/help/help_impl.cpp b/src/help/help_impl.cpp index eb59c3691548..9a5e3574b8f4 100644 --- a/src/help/help_impl.cpp +++ b/src/help/help_impl.cpp @@ -45,7 +45,6 @@ #include "units/types.hpp" // for unit_type, unit_type_data, etc #include "serialization/unicode.hpp" // for iterator #include "color.hpp" -#include "config_assign.hpp" #include // for assert #include // for sort, find, transform, etc @@ -1190,7 +1189,7 @@ config parse_text(const std::string &text) ss << c; } else { - res.add_child("text", config_of("text", ss.str())); + res.add_child("text", config{ "text", ss.str() }); ss.str(""); state = ELEMENT_NAME; } @@ -1246,7 +1245,7 @@ config parse_text(const std::string &text) } if (!ss.str().empty()) { // Add the last string. - res.add_child("text", config_of("text", ss.str())); + res.add_child("text", config{ "text", ss.str() }); } return res; }