Lines Matching refs:offset
374 void SkString::insert(size_t offset, const char text[])
376 this->insert(offset, text, text ? strlen(text) : 0);
379 void SkString::insert(size_t offset, const char text[], size_t len)
384 if (offset > length)
385 offset = length;
401 if (offset < length)
402 memmove(dst + offset + len, dst + offset, length - offset);
403 memcpy(dst + offset, text, len);
416 if (offset > 0)
417 memcpy(dst, fRec->data(), offset);
418 memcpy(dst + offset, text, len);
419 if (offset < fRec->fLength)
420 memcpy(dst + offset + len, fRec->data() + offset, fRec->fLength - offset);
427 void SkString::insertUnichar(size_t offset, SkUnichar uni)
433 this->insert(offset, buffer, len);
436 void SkString::insertS32(size_t offset, int32_t dec)
440 this->insert(offset, buffer, stop - buffer);
443 void SkString::insertHex(size_t offset, uint32_t hex, int minDigits)
461 this->insert(offset, p, buffer + sizeof(buffer) - p);
464 void SkString::insertScalar(size_t offset, SkScalar value)
468 this->insert(offset, buffer, stop - buffer);
517 void SkString::remove(size_t offset, size_t length)
521 if (offset < size)
523 if (offset + length > size)
524 length = size - offset;
532 if (offset)
534 SkASSERT(offset <= tmp.size());
535 memcpy(dst, src, offset);
537 size_t tail = size - offset - length;
541 // SkASSERT(offset + length <= tmp.size());
542 memcpy(dst + offset, src + offset + length, tail);