Home | History | Annotate | Download | only in accelerators

Lines Matching refs:label

17 std::string ConvertAmpersandsTo(const std::string& label,
20 ret.reserve(label.length() * 2);
21 for (size_t i = 0; i < label.length(); ++i) {
22 if ('_' == label[i]) {
25 } else if ('&' == label[i]) {
26 if (i + 1 < label.length() && '&' == label[i + 1]) {
33 ret.push_back(label[i]);
44 std::string ConvertAcceleratorsFromWindowsStyle(const std::string& label) {
45 return ConvertAmpersandsTo(label, "_");
48 std::string RemoveWindowsStyleAccelerators(const std::string& label) {
49 return ConvertAmpersandsTo(label, std::string());
52 // Replaces all ampersands in |label| with two ampersands. This effectively
56 std::string EscapeWindowsStyleAccelerators(const std::string& label) {
58 ReplaceChars(label, "&", "&&", &ret);