mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-08 10:36:02 +00:00
AK: Add Utf8View::iterator_at_byte_offset method
This implements a method to get a Utf8CodepointIterator at a specified byte offset.
This commit is contained in:
parent
c1b452f754
commit
a72bb34970
Notes:
sideshowbarker
2024-07-18 17:36:27 +09:00
Author: https://github.com/MaxWipfli
Commit: a72bb34970
Pull-request: https://github.com/SerenityOS/serenity/pull/7268
Issue: https://github.com/SerenityOS/serenity/issues/7182
Issue: https://github.com/SerenityOS/serenity/issues/7202
Reviewed-by: https://github.com/Dexesttp
2 changed files with 12 additions and 0 deletions
|
@ -54,6 +54,7 @@ public:
|
|||
|
||||
Utf8CodepointIterator begin() const;
|
||||
Utf8CodepointIterator end() const;
|
||||
Utf8CodepointIterator iterator_at_byte_offset(size_t) const;
|
||||
|
||||
const unsigned char* bytes() const { return begin_ptr(); }
|
||||
size_t byte_length() const { return m_string.length(); }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue