Logo Search packages:      
Sourcecode: ardour version File versions  Download package

Glib::ustring Glib::Markup::escape_text ( const Glib::ustring text  ) 

Escapes text so that the markup parser will parse it verbatim. Less than, greater than, ampersand, etc. are replaced with the corresponding entities. This function would typically be used when writing out a file to be parsed with the markup parser.

Parameters:
text Some valid UTF-8 text.
Returns:
Escaped text.

Definition at line 38 of file markup.cc.

References Glib::ustring::bytes(), and Glib::ustring::data().

{
  const Glib::ScopedPtr<char> buf (g_markup_escape_text(text.data(), text.bytes()));
  return Glib::ustring(buf.get());
}


Generated by  Doxygen 1.6.0   Back to index