inline Cluster::run()

Change-Id: I3d418e52df43c49a9c6b8519d47ca173f6ff3b9f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294996
Reviewed-by: Julia Lavrova <jlavrova@google.com>
Commit-Queue: Mike Reed <reed@google.com>
This commit is contained in:
Mike Reed 2020-06-08 10:28:16 -04:00 committed by Skia Commit-Bot
parent 00a96f2c99
commit f6c48c0b51
2 changed files with 4 additions and 6 deletions

View File

@ -1013,11 +1013,6 @@ Cluster& ParagraphImpl::cluster(ClusterIndex clusterIndex) {
return fClusters[clusterIndex];
}
Run& ParagraphImpl::run(RunIndex runIndex) {
SkASSERT(runIndex < fRuns.size());
return fRuns[runIndex];
}
Run& ParagraphImpl::runByCluster(ClusterIndex clusterIndex) {
auto start = cluster(clusterIndex);
return this->run(start.fRunIndex);

View File

@ -153,7 +153,10 @@ public:
SkSpan<const char> text(TextRange textRange);
SkSpan<Cluster> clusters(ClusterRange clusterRange);
Cluster& cluster(ClusterIndex clusterIndex);
Run& run(RunIndex runIndex);
Run& run(RunIndex runIndex) {
SkASSERT(runIndex < fRuns.size());
return fRuns[runIndex];
}
Run& runByCluster(ClusterIndex clusterIndex);
SkSpan<Block> blocks(BlockRange blockRange);
Block& block(BlockIndex blockIndex);