Lines Matching refs:clusters
36 std::vector<uint32_t>& clusters) {
40 if (clusters[clusterIndex] >= lastUtf8Index) {
43 size_t utf8ClusterSize = lastUtf8Index - clusters[clusterIndex];
44 if (SkUTF::CountUTF8(&utf8[clusters[clusterIndex]], utf8ClusterSize) != 1) {
47 lastUtf8Index = clusters[clusterIndex];
51 if (clusters.front() <= clusters.back()) {
52 // left-to-right clusters
53 size_t clusterCursor = clusters.size();
58 // right-to-left clusters
60 while (clusterCursor < clusters.size()) {
95 fJSONWriter->beginArray("clusters", false);
131 SkSpan<const uint32_t> clusters,
134 if (clusters.front() <= clusters.back()) {
137 for (size_t glyphEndIndex = 0; glyphEndIndex < clusters.size(); glyphEndIndex++) {
139 if (clusters[glyphStartIndex] == clusters[glyphEndIndex]) { continue; }
142 clusters[glyphStartIndex], clusters[glyphEndIndex]);
147 processMToN(glyphStartIndex, clusters.size(), clusters[glyphStartIndex], utf8End);
151 SkASSERT(clusters.size() >= 2);
154 for (size_t glyphEndIndex = 0; glyphEndIndex < clusters.size(); glyphEndIndex++) {
156 if (clusters[glyphStartIndex] == clusters[glyphEndIndex]) { continue; }
159 clusters[glyphStartIndex], utf8EndIndex);
161 utf8EndIndex = clusters[glyphStartIndex];
164 processMToN(glyphStartIndex, clusters.size(), utf8Begin, clusters[glyphStartIndex-1]);
170 SkSpan<const uint32_t> clusters,
217 BreakupClusters(utf8Begin, utf8End, clusters, gatherRuns);