Flutter Engine
The Flutter Engine
third_party
skia
modules
skplaintexteditor
src
shape.h
Go to the documentation of this file.
1
// Copyright 2019 Google LLC.
2
// Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.
3
4
#include "
include/core/SkFont.h
"
5
#include "
include/core/SkTextBlob.h
"
6
7
#include <cstddef>
8
#include <vector>
9
10
namespace
SkPlainTextEditor
{
11
12
struct
ShapeResult
{
13
sk_sp<SkTextBlob>
blob
;
14
std::vector<std::size_t>
lineBreakOffsets
;
15
std::vector<SkRect>
glyphBounds
;
16
std::vector<bool>
wordBreaks
;
17
int
verticalAdvance
;
18
};
19
20
ShapeResult
Shape
(
const
char
* ut8text,
21
size_t
textByteLen,
22
const
SkFont
&
font
,
23
sk_sp<SkFontMgr>
fontMgr
,
24
const
char
* locale,
25
float
width
);
26
27
}
// namespace SkPlainTextEditor
SkFont.h
SkTextBlob.h
SkFont
Definition:
SkFont.h:35
sk_sp< SkTextBlob >
fontMgr
sk_sp< SkFontMgr > fontMgr
Definition:
examples.cpp:32
SkPlainTextEditor
Definition:
editor.h:24
SkPlainTextEditor::Shape
ShapeResult Shape(const char *ut8text, size_t textByteLen, const SkFont &font, sk_sp< SkFontMgr > fontMgr, const char *locale, float width)
Definition:
shape.cpp:301
gen_test_font.font
font
Font Metadata and Metrics.
Definition:
gen_test_font.py:26
width
int32_t width
Definition:
serialization_callbacks.cc:0
SkPlainTextEditor::ShapeResult
Definition:
shape.h:12
SkPlainTextEditor::ShapeResult::verticalAdvance
int verticalAdvance
Definition:
shape.h:17
SkPlainTextEditor::ShapeResult::wordBreaks
std::vector< bool > wordBreaks
Definition:
shape.h:16
SkPlainTextEditor::ShapeResult::glyphBounds
std::vector< SkRect > glyphBounds
Definition:
shape.h:15
SkPlainTextEditor::ShapeResult::blob
sk_sp< SkTextBlob > blob
Definition:
shape.h:13
SkPlainTextEditor::ShapeResult::lineBreakOffsets
std::vector< std::size_t > lineBreakOffsets
Definition:
shape.h:14
Generated on Sun Jun 23 2024 21:56:07 for Flutter Engine by
1.9.4