diff --git a/include/mapnik/text_placements.hpp b/include/mapnik/text_placements.hpp index c765b6a8c..bb6ee9df4 100644 --- a/include/mapnik/text_placements.hpp +++ b/include/mapnik/text_placements.hpp @@ -95,7 +95,7 @@ struct text_symbolizer_properties { text_symbolizer_properties(); /** Load all values and also the ```processor``` object from XML ptree. */ - void set_values_from_xml(boost::property_tree::ptree const &sym, std::map const & fontsets); + void from_xml(boost::property_tree::ptree const &sym, std::map const & fontsets); /** Save all values to XML ptree (but does not create a new parent node!). */ void to_xml(boost::property_tree::ptree &node, bool explicit_defaults, text_symbolizer_properties const &dfl=text_symbolizer_properties()) const; diff --git a/include/mapnik/text_processing.hpp b/include/mapnik/text_processing.hpp index 9c9306c05..8bc4dcc1d 100644 --- a/include/mapnik/text_processing.hpp +++ b/include/mapnik/text_processing.hpp @@ -53,7 +53,7 @@ struct char_properties { char_properties(); /** Construct object from XML. */ - void set_values_from_xml(boost::property_tree::ptree const &sym, std::map const & fontsets); + void from_xml(boost::property_tree::ptree const &sym, std::map const & fontsets); /** Write object to XML ptree. */ void to_xml(boost::property_tree::ptree &node, bool explicit_defaults, char_properties const &dfl=char_properties()) const; std::string face_name; diff --git a/src/load_map.cpp b/src/load_map.cpp index c6e3f47e8..311a2c66f 100644 --- a/src/load_map.cpp +++ b/src/load_map.cpp @@ -1282,7 +1282,7 @@ void map_parser::parse_text_symbolizer( rule & rule, ptree const & sym ) } text_symbolizer text_symbol = text_symbolizer(placement_finder); - placement_finder->properties.set_values_from_xml(sym, fontsets_); + placement_finder->properties.from_xml(sym, fontsets_); if (strict_) ensure_font_face(placement_finder->properties.processor.defaults.face_name); if (list) { ptree::const_iterator symIter = sym.begin(); @@ -1296,7 +1296,7 @@ void map_parser::parse_text_symbolizer( rule & rule, ptree const & sym ) } ensure_attrs(symIter->second, "TextSymbolizer/Placement", s_common.str()); text_symbolizer_properties & p = list->add(); - p.set_values_from_xml(symIter->second, fontsets_); + p.from_xml(symIter->second, fontsets_); if (strict_) ensure_font_face(p.processor.defaults.face_name); } } @@ -1419,7 +1419,7 @@ void map_parser::parse_shield_symbolizer( rule & rule, ptree const & sym ) } } text_placements_ptr placement_finder = shield_symbol.get_placement_options(); - placement_finder->properties.set_values_from_xml(sym, fontsets_); + placement_finder->properties.from_xml(sym, fontsets_); rule.append(shield_symbol); } catch (const config_error & ex) diff --git a/src/text_placements.cpp b/src/text_placements.cpp index b6865f2cd..2ea18f63a 100644 --- a/src/text_placements.cpp +++ b/src/text_placements.cpp @@ -63,7 +63,7 @@ text_symbolizer_properties::text_symbolizer_properties() : } -void text_symbolizer_properties::set_values_from_xml(boost::property_tree::ptree const &sym, std::map const & fontsets) +void text_symbolizer_properties::from_xml(boost::property_tree::ptree const &sym, std::map const & fontsets) { optional placement_ = get_opt_attr(sym, "placement"); if (placement_) label_placement = *placement_; @@ -204,7 +204,7 @@ char_properties::char_properties() : } -void char_properties::set_values_from_xml(boost::property_tree::ptree const &sym, std::map const & fontsets) +void char_properties::from_xml(boost::property_tree::ptree const &sym, std::map const & fontsets) { optional text_size_ = get_opt_attr(sym, "size"); if (text_size_) text_size = *text_size_; diff --git a/src/text_processing.cpp b/src/text_processing.cpp index 5bd389e1e..8f65cbce9 100644 --- a/src/text_processing.cpp +++ b/src/text_processing.cpp @@ -363,7 +363,7 @@ formating::node_ptr text_processor::get_format_tree() const void text_processor::from_xml(const boost::property_tree::ptree &pt, std::map const &fontsets) { - defaults.set_values_from_xml(pt, fontsets); + defaults.from_xml(pt, fontsets); formating::node_ptr n = formating::node::from_xml(pt); if (n) set_format_tree(n); }