Lines Matching defs:const

26 SkRect ComputeBlobBounds(const sk_sp<SkTextBlob>& blob) {
53 BlobMaker(const Shaper::TextDesc& desc, const SkRect& box, const sk_sp<SkFontMgr>& fontmgr)
79 void runInfo(const RunInfo& info) override {
92 Buffer runBuffer(const RunInfo& info) override {
93 const auto run_start_index = fLineGlyphCount;
112 void commitRunBuffer(const RunInfo& info) override {
121 const auto commit_proc = (fDesc.fFlags & Shaper::Flags::kFragmentGlyphs)
126 for (const auto& rec : fLineRuns) {
147 const auto ascent = this->ascent();
164 const auto typographical_top = fBox.fTop + ascent,
217 void shapeLine(const char* start, const char* end) {
234 const auto max_offset = fBox.height() + this->ascent(); // NB: ascent is negative
240 const auto shape_width = fDesc.fLinebreak == Shaper::LinebreakPolicy::kExplicit
243 const auto shape_ltr = fDesc.fDirection == Shaper::Direction::kLTR;
256 void commitFragementedRun(const RunRec& rec,
257 const SkGlyphID* glyphs,
258 const SkPoint* pos,
259 const uint32_t* clusters,
262 static const auto is_whitespace = [](char c) {
284 const auto& blob_buffer = fBuilder.allocRunPos(rec.fFont, 1);
288 const auto advance = (fDesc.fFlags & Shaper::Flags::kTrackFragmentAdvanceAscent)
303 void commitConsolidatedRun(const RunRec& rec,
304 const SkGlyphID* glyphs,
305 const SkPoint* pos,
306 const uint32_t*,
311 const auto& blob_buffer = fBuilder.allocRunPos(rec.fFont, rec.fGlyphCount);
328 SkScalar ascent() const {
336 const Shaper::TextDesc& fDesc;
337 const SkRect& fBox;
338 const float fHAlignFactor;
359 const char* fUTF8 = nullptr; // only valid during shapeLine() calls
364 Shaper::Result ShapeImpl(const SkString& txt, const Shaper::TextDesc& desc,
365 const SkRect& box, const sk_sp<SkFontMgr>& fontmgr,
367 const auto& is_line_break = [](SkUnichar uch) {
372 const char* ptr = txt.c_str();
373 const char* line_start = ptr;
374 const char* end = ptr + txt.size();
388 Shaper::Result ShapeToFit(const SkString& txt, const Shaper::TextDesc& orig_desc,
389 const SkRect& box, const sk_sp<SkFontMgr>& fontmgr) {
398 const auto min_scale = std::max(desc.fMinTextSize / desc.fTextSize, 0.0f),
421 const auto prev_scale = try_scale;
454 AdjustedText(const SkString& txt, const Shaper::TextDesc& desc)
469 operator const SkString&() const { return *fText; }
477 Shaper::Result Shaper::Shape(const SkString& orig_txt, const TextDesc& desc, const SkPoint& point,
478 const sk_sp<SkFontMgr>& fontmgr) {
479 const AdjustedText txt(orig_txt, desc);
487 Shaper::Result Shaper::Shape(const SkString& orig_txt, const TextDesc& desc, const SkRect& box,
488 const sk_sp<SkFontMgr>& fontmgr) {
489 const AdjustedText txt(orig_txt, desc);
509 SkRect Shaper::Result::computeVisualBounds() const {
512 for (const auto& fragment : fFragments) {