Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2006 The Android Open Source Project | 3 * Copyright 2006 The Android Open Source Project |
| 4 * | 4 * |
| 5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
| 6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
| 7 */ | 7 */ |
| 8 | 8 |
| 9 | 9 |
| 10 #ifndef SkString_DEFINED | 10 #ifndef SkString_DEFINED |
| (...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 184 | 184 |
| 185 void prepend(const SkString& str) { this->insert(0, str); } | 185 void prepend(const SkString& str) { this->insert(0, str); } |
| 186 void prepend(const char text[]) { this->insert(0, text); } | 186 void prepend(const char text[]) { this->insert(0, text); } |
| 187 void prepend(const char text[], size_t len) { this->insert(0, text, len); } | 187 void prepend(const char text[], size_t len) { this->insert(0, text, len); } |
| 188 void prependUnichar(SkUnichar uni) { this->insertUnichar(0, uni); } | 188 void prependUnichar(SkUnichar uni) { this->insertUnichar(0, uni); } |
| 189 void prependS32(int32_t value) { this->insertS32(0, value); } | 189 void prependS32(int32_t value) { this->insertS32(0, value); } |
| 190 void prependS64(int32_t value, int minDigits = 0) { this->insertS64(0, value , minDigits); } | 190 void prependS64(int32_t value, int minDigits = 0) { this->insertS64(0, value , minDigits); } |
| 191 void prependHex(uint32_t value, int minDigits = 0) { this->insertHex(0, valu e, minDigits); } | 191 void prependHex(uint32_t value, int minDigits = 0) { this->insertHex(0, valu e, minDigits); } |
| 192 void prependScalar(SkScalar value) { this->insertScalar((size_t)-1, value); } | 192 void prependScalar(SkScalar value) { this->insertScalar((size_t)-1, value); } |
| 193 | 193 |
| 194 void replaceChar(char oldChar, char newChar); | |
|
reed1
2014/08/13 19:13:36
ick -- are we logically trying to replace a byte,
| |
| 195 | |
| 194 void printf(const char format[], ...) SK_PRINTF_LIKE(2, 3); | 196 void printf(const char format[], ...) SK_PRINTF_LIKE(2, 3); |
| 195 void appendf(const char format[], ...) SK_PRINTF_LIKE(2, 3); | 197 void appendf(const char format[], ...) SK_PRINTF_LIKE(2, 3); |
| 196 void appendVAList(const char format[], va_list); | 198 void appendVAList(const char format[], va_list); |
| 197 void prependf(const char format[], ...) SK_PRINTF_LIKE(2, 3); | 199 void prependf(const char format[], ...) SK_PRINTF_LIKE(2, 3); |
| 198 | 200 |
| 199 void remove(size_t offset, size_t length); | 201 void remove(size_t offset, size_t length); |
| 200 | 202 |
| 201 SkString& operator+=(const SkString& s) { this->append(s); return *this; } | 203 SkString& operator+=(const SkString& s) { this->append(s); return *this; } |
| 202 SkString& operator+=(const char text[]) { this->append(text); return *this; } | 204 SkString& operator+=(const char text[]) { this->append(text); return *this; } |
| 203 SkString& operator+=(const char c) { this->append(&c, 1); return *this; } | 205 SkString& operator+=(const char c) { this->append(&c, 1); return *this; } |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 238 // Specialized to take advantage of SkString's fast swap path. The unspecialized function is | 240 // Specialized to take advantage of SkString's fast swap path. The unspecialized function is |
| 239 // declared in SkTypes.h and called by SkTSort. | 241 // declared in SkTypes.h and called by SkTSort. |
| 240 template <> inline void SkTSwap(SkString& a, SkString& b) { | 242 template <> inline void SkTSwap(SkString& a, SkString& b) { |
| 241 a.swap(b); | 243 a.swap(b); |
| 242 } | 244 } |
| 243 | 245 |
| 244 // Split str on any characters in delimiters into out. (Think, strtok with a sa ne API.) | 246 // Split str on any characters in delimiters into out. (Think, strtok with a sa ne API.) |
| 245 void SkStrSplit(const char* str, const char* delimiters, SkTArray<SkString>* out ); | 247 void SkStrSplit(const char* str, const char* delimiters, SkTArray<SkString>* out ); |
| 246 | 248 |
| 247 #endif | 249 #endif |
| OLD | NEW |