Flutter Engine Uber Docs
Docs for the entire Flutter Engine repo.
 
Loading...
Searching...
No Matches
paragraph_builder_builtin_icu.cc
Go to the documentation of this file.
1// Copyright 2013 The Flutter Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
9#include "modules/skunicode/include/SkUnicode_icu.h"
10#include "third_party/skia/modules/skparagraph/include/ParagraphBuilder.h"
11
13 return true;
14}
15
20 std::vector<flutter::DlPaint> paints;
21 style->text_style.PopulatePaintIds(paints);
22 style->skia_paragraph_style.setTextStyle(style->text_style.skia_style);
23 return new Skwasm::ParagraphBuilder{
24 skia::textlayout::ParagraphBuilder::make(style->skia_paragraph_style,
25 collection->collection,
26 SkUnicodes::ICU::Make()),
27 std::move(paints)};
28}
29
36
39 std::vector<SkUnicode::Position>* breaks) {
40 emscripten_console_warn(
41 "warning: setGraphemeBreaksUtf16 not implemented in skwasm_heavy\n");
42}
43
46 std::vector<SkUnicode::Position>* breaks) {
47 emscripten_console_warn(
48 "warning: setWordBreaksUtf16 not implemented in skwasm_heavy\n");
49}
50
53 std::vector<SkUnicode::LineBreakBefore>* breaks) {
54 emscripten_console_warn(
55 "warning: setLineBreaksUtf16 not implemented in skwasm_heavy\n");
56}
uint32_t live_paragraph_builder_count
uint32_t live_paragraph_count
SKWASM_EXPORT void paragraphBuilder_setGraphemeBreaksUtf16(Skwasm::ParagraphBuilder *builder, std::vector< SkUnicode::Position > *breaks)
SKWASM_EXPORT Skwasm::Paragraph * paragraphBuilder_build(Skwasm::ParagraphBuilder *builder)
SKWASM_EXPORT Skwasm::ParagraphBuilder * paragraphBuilder_create(Skwasm::ParagraphStyle *style, Skwasm::FlutterFontCollection *collection)
SKWASM_EXPORT void paragraphBuilder_setWordBreaksUtf16(Skwasm::ParagraphBuilder *builder, std::vector< SkUnicode::Position > *breaks)
SKWASM_EXPORT bool skwasm_isHeavy()
SKWASM_EXPORT void paragraphBuilder_setLineBreaksUtf16(Skwasm::ParagraphBuilder *builder, std::vector< SkUnicode::LineBreakBefore > *breaks)
#define SKWASM_EXPORT
Definition export.h:10
sk_sp< skia::textlayout::FontCollection > collection
Definition wrappers.h:37
std::vector< flutter::DlPaint > paints
Definition text_types.h:45
std::unique_ptr< skia::textlayout::ParagraphBuilder > skia_paragraph_builder
Definition text_types.h:44
skia::textlayout::ParagraphStyle skia_paragraph_style
Definition text_types.h:39
void PopulatePaintIds(std::vector< flutter::DlPaint > &paints)
Definition text_types.h:21
skia::textlayout::TextStyle skia_style
Definition text_types.h:17