Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
weixin_43355755
engine
提交
71da3d79
E
engine
项目概览
weixin_43355755
/
engine
与 Fork 源项目一致
从无法访问的项目Fork
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
E
engine
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
71da3d79
编写于
6月 01, 2017
作者:
C
Chinmay Garde
提交者:
GitHub
6月 01, 2017
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Ensure that gradient tile mode enum values in Dart match SkShader::TileMode. (#3721)
上级
a808ab9f
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
16 addition
and
10 deletion
+16
-10
lib/ui/painting.dart
lib/ui/painting.dart
+16
-10
未找到文件。
lib/ui/painting.dart
浏览文件 @
71da3d79
...
@@ -272,6 +272,7 @@ enum FilterQuality {
...
@@ -272,6 +272,7 @@ enum FilterQuality {
/// Styles to use for line endings.
/// Styles to use for line endings.
///
///
/// See [Paint.strokeCap].
/// See [Paint.strokeCap].
// These enum values must be kept in sync with SkPaint::Cap.
enum
StrokeCap
{
enum
StrokeCap
{
/// Begin and end contours with a flat edge and no extension.
/// Begin and end contours with a flat edge and no extension.
butt
,
butt
,
...
@@ -288,6 +289,7 @@ enum StrokeCap {
...
@@ -288,6 +289,7 @@ enum StrokeCap {
/// Strategies for painting shapes and paths on a canvas.
/// Strategies for painting shapes and paths on a canvas.
///
///
/// See [Paint.style].
/// See [Paint.style].
// These enum values must be kept in sync with SkPaint::Style.
enum
PaintingStyle
{
enum
PaintingStyle
{
// This list comes from Skia's SkPaint.h and the values (order) should be kept
// This list comes from Skia's SkPaint.h and the values (order) should be kept
// in sync.
// in sync.
...
@@ -833,6 +835,7 @@ class Path extends NativeFieldWrapperClass2 {
...
@@ -833,6 +835,7 @@ class Path extends NativeFieldWrapperClass2 {
}
}
/// Styles to use for blurs in [MaskFilter] objects.
/// Styles to use for blurs in [MaskFilter] objects.
// These enum values must be kept in sync with SkBlurStyle.
enum
BlurStyle
{
enum
BlurStyle
{
// These mirror SkBlurStyle and must be kept in sync.
// These mirror SkBlurStyle and must be kept in sync.
...
@@ -968,6 +971,7 @@ abstract class Shader extends NativeFieldWrapperClass2 { }
...
@@ -968,6 +971,7 @@ abstract class Shader extends NativeFieldWrapperClass2 { }
/// * [dart:ui.Gradient], the low-level class used when dealing with the
/// * [dart:ui.Gradient], the low-level class used when dealing with the
/// [Paint.shader] property directly, with its [new Gradient.linear] and [new
/// [Paint.shader] property directly, with its [new Gradient.linear] and [new
/// Gradient.radial] constructors.
/// Gradient.radial] constructors.
// These enum values must be kept in sync with SkShader::TileMode.
enum
TileMode
{
enum
TileMode
{
/// Edge is clamped to the final color.
/// Edge is clamped to the final color.
///
///
...
@@ -978,6 +982,16 @@ enum TileMode {
...
@@ -978,6 +982,16 @@ enum TileMode {
/// ![](https://flutter.github.io/assets-for-api-docs/dart-ui/tile_mode_clamp_radial.png)
/// ![](https://flutter.github.io/assets-for-api-docs/dart-ui/tile_mode_clamp_radial.png)
clamp
,
clamp
,
/// Edge is repeated from first color to last.
///
/// This is as if the stop points from 0.0 to 1.0 were then repeated from 1.0
/// to 2.0, 2.0 to 3.0, and so forth (and for linear gradients, similarly from
/// -1.0 to 0.0, -2.0 to -1.0, etc).
///
/// ![](https://flutter.github.io/assets-for-api-docs/dart-ui/tile_mode_repeated_linear.png)
/// ![](https://flutter.github.io/assets-for-api-docs/dart-ui/tile_mode_repeated_radial.png)
repeated
,
/// Edge is mirrored from last color to first.
/// Edge is mirrored from last color to first.
///
///
/// This is as if the stop points from 0.0 to 1.0 were then repeated backwards
/// This is as if the stop points from 0.0 to 1.0 were then repeated backwards
...
@@ -988,16 +1002,6 @@ enum TileMode {
...
@@ -988,16 +1002,6 @@ enum TileMode {
/// ![](https://flutter.github.io/assets-for-api-docs/dart-ui/tile_mode_mirror_linear.png)
/// ![](https://flutter.github.io/assets-for-api-docs/dart-ui/tile_mode_mirror_linear.png)
/// ![](https://flutter.github.io/assets-for-api-docs/dart-ui/tile_mode_mirror_radial.png)
/// ![](https://flutter.github.io/assets-for-api-docs/dart-ui/tile_mode_mirror_radial.png)
mirror
,
mirror
,
/// Edge is repeated from first color to last.
///
/// This is as if the stop points from 0.0 to 1.0 were then repeated from 1.0
/// to 2.0, 2.0 to 3.0, and so forth (and for linear gradients, similarly from
/// -1.0 to 0.0, -2.0 to -1.0, etc).
///
/// ![](https://flutter.github.io/assets-for-api-docs/dart-ui/tile_mode_repeated_linear.png)
/// ![](https://flutter.github.io/assets-for-api-docs/dart-ui/tile_mode_repeated_radial.png)
repeated
,
}
}
Int32List
_encodeColorList
(
List
<
Color
>
colors
)
{
Int32List
_encodeColorList
(
List
<
Color
>
colors
)
{
...
@@ -1146,6 +1150,7 @@ class ImageShader extends Shader {
...
@@ -1146,6 +1150,7 @@ class ImageShader extends Shader {
/// Defines how a list of points is interpreted when drawing a set of triangles.
/// Defines how a list of points is interpreted when drawing a set of triangles.
///
///
/// Used by [Canvas.drawVertices].
/// Used by [Canvas.drawVertices].
// These enum values must be kept in sync with SkVertices::VertexMode.
enum
VertexMode
{
enum
VertexMode
{
/// Draw each sequence of three points as the vertices of a triangle.
/// Draw each sequence of three points as the vertices of a triangle.
triangles
,
triangles
,
...
@@ -1214,6 +1219,7 @@ class Vertices extends NativeFieldWrapperClass2 {
...
@@ -1214,6 +1219,7 @@ class Vertices extends NativeFieldWrapperClass2 {
///
///
// ignore: deprecated_member_use
// ignore: deprecated_member_use
/// Used by [Canvas.drawPoints].
/// Used by [Canvas.drawPoints].
// These enum values must be kept in sync with SkCanvas::PointMode.
enum
PointMode
{
enum
PointMode
{
/// Draw each point separately.
/// Draw each point separately.
///
///
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录