Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Third Party Harfbuzz
提交
b8b00fb3
T
Third Party Harfbuzz
项目概览
OpenHarmony
/
Third Party Harfbuzz
接近 2 年 前同步成功
通知
1
Star
18
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
Third Party Harfbuzz
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
“bb8646d8340fa7c1b66a037428e39f85f8738f0a”上不存在“arch/sparc/mm/tsb.c”
未验证
提交
b8b00fb3
编写于
11月 08, 2018
作者:
E
Ebrahim Byagowi
提交者:
GitHub
11月 08, 2018
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[aat] Support Lookup<OffsetTo<>>, needed by just and lcar (#1368)
上级
073d0a9f
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
68 addition
and
0 deletion
+68
-0
src/hb-aat-layout-common.hh
src/hb-aat-layout-common.hh
+57
-0
src/hb-open-type.hh
src/hb-open-type.hh
+11
-0
未找到文件。
src/hb-aat-layout-common.hh
浏览文件 @
b8b00fb3
...
@@ -58,6 +58,11 @@ struct LookupFormat0
...
@@ -58,6 +58,11 @@ struct LookupFormat0
TRACE_SANITIZE
(
this
);
TRACE_SANITIZE
(
this
);
return_trace
(
arrayZ
.
sanitize
(
c
,
c
->
get_num_glyphs
()));
return_trace
(
arrayZ
.
sanitize
(
c
,
c
->
get_num_glyphs
()));
}
}
inline
bool
sanitize
(
hb_sanitize_context_t
*
c
,
const
void
*
base
)
const
{
TRACE_SANITIZE
(
this
);
return_trace
(
arrayZ
.
sanitize
(
c
,
c
->
get_num_glyphs
(),
base
));
}
protected:
protected:
HBUINT16
format
;
/* Format identifier--format = 0 */
HBUINT16
format
;
/* Format identifier--format = 0 */
...
@@ -80,6 +85,11 @@ struct LookupSegmentSingle
...
@@ -80,6 +85,11 @@ struct LookupSegmentSingle
TRACE_SANITIZE
(
this
);
TRACE_SANITIZE
(
this
);
return_trace
(
c
->
check_struct
(
this
)
&&
value
.
sanitize
(
c
));
return_trace
(
c
->
check_struct
(
this
)
&&
value
.
sanitize
(
c
));
}
}
inline
bool
sanitize
(
hb_sanitize_context_t
*
c
,
const
void
*
base
)
const
{
TRACE_SANITIZE
(
this
);
return_trace
(
c
->
check_struct
(
this
)
&&
value
.
sanitize
(
c
,
base
));
}
GlyphID
last
;
/* Last GlyphID in this segment */
GlyphID
last
;
/* Last GlyphID in this segment */
GlyphID
first
;
/* First GlyphID in this segment */
GlyphID
first
;
/* First GlyphID in this segment */
...
@@ -105,6 +115,11 @@ struct LookupFormat2
...
@@ -105,6 +115,11 @@ struct LookupFormat2
TRACE_SANITIZE
(
this
);
TRACE_SANITIZE
(
this
);
return_trace
(
segments
.
sanitize
(
c
));
return_trace
(
segments
.
sanitize
(
c
));
}
}
inline
bool
sanitize
(
hb_sanitize_context_t
*
c
,
const
void
*
base
)
const
{
TRACE_SANITIZE
(
this
);
return_trace
(
segments
.
sanitize
(
c
,
base
));
}
protected:
protected:
HBUINT16
format
;
/* Format identifier--format = 2 */
HBUINT16
format
;
/* Format identifier--format = 2 */
...
@@ -135,6 +150,14 @@ struct LookupSegmentArray
...
@@ -135,6 +150,14 @@ struct LookupSegmentArray
first
<=
last
&&
first
<=
last
&&
valuesZ
.
sanitize
(
c
,
base
,
last
-
first
+
1
));
valuesZ
.
sanitize
(
c
,
base
,
last
-
first
+
1
));
}
}
template
<
typename
T2
>
inline
bool
sanitize
(
hb_sanitize_context_t
*
c
,
const
void
*
base
,
T2
user_data
)
const
{
TRACE_SANITIZE
(
this
);
return_trace
(
c
->
check_struct
(
this
)
&&
first
<=
last
&&
valuesZ
.
sanitize
(
c
,
base
,
last
-
first
+
1
,
user_data
));
}
GlyphID
last
;
/* Last GlyphID in this segment */
GlyphID
last
;
/* Last GlyphID in this segment */
GlyphID
first
;
/* First GlyphID in this segment */
GlyphID
first
;
/* First GlyphID in this segment */
...
@@ -162,6 +185,11 @@ struct LookupFormat4
...
@@ -162,6 +185,11 @@ struct LookupFormat4
TRACE_SANITIZE
(
this
);
TRACE_SANITIZE
(
this
);
return_trace
(
segments
.
sanitize
(
c
,
this
));
return_trace
(
segments
.
sanitize
(
c
,
this
));
}
}
inline
bool
sanitize
(
hb_sanitize_context_t
*
c
,
const
void
*
base
)
const
{
TRACE_SANITIZE
(
this
);
return_trace
(
segments
.
sanitize
(
c
,
this
,
base
));
}
protected:
protected:
HBUINT16
format
;
/* Format identifier--format = 4 */
HBUINT16
format
;
/* Format identifier--format = 4 */
...
@@ -183,6 +211,11 @@ struct LookupSingle
...
@@ -183,6 +211,11 @@ struct LookupSingle
TRACE_SANITIZE
(
this
);
TRACE_SANITIZE
(
this
);
return_trace
(
c
->
check_struct
(
this
)
&&
value
.
sanitize
(
c
));
return_trace
(
c
->
check_struct
(
this
)
&&
value
.
sanitize
(
c
));
}
}
inline
bool
sanitize
(
hb_sanitize_context_t
*
c
,
const
void
*
base
)
const
{
TRACE_SANITIZE
(
this
);
return_trace
(
c
->
check_struct
(
this
)
&&
value
.
sanitize
(
c
,
base
));
}
GlyphID
glyph
;
/* Last GlyphID */
GlyphID
glyph
;
/* Last GlyphID */
T
value
;
/* The lookup value (only one) */
T
value
;
/* The lookup value (only one) */
...
@@ -207,6 +240,11 @@ struct LookupFormat6
...
@@ -207,6 +240,11 @@ struct LookupFormat6
TRACE_SANITIZE
(
this
);
TRACE_SANITIZE
(
this
);
return_trace
(
entries
.
sanitize
(
c
));
return_trace
(
entries
.
sanitize
(
c
));
}
}
inline
bool
sanitize
(
hb_sanitize_context_t
*
c
,
const
void
*
base
)
const
{
TRACE_SANITIZE
(
this
);
return_trace
(
entries
.
sanitize
(
c
,
base
));
}
protected:
protected:
HBUINT16
format
;
/* Format identifier--format = 6 */
HBUINT16
format
;
/* Format identifier--format = 6 */
...
@@ -233,6 +271,11 @@ struct LookupFormat8
...
@@ -233,6 +271,11 @@ struct LookupFormat8
TRACE_SANITIZE
(
this
);
TRACE_SANITIZE
(
this
);
return_trace
(
c
->
check_struct
(
this
)
&&
valueArrayZ
.
sanitize
(
c
,
glyphCount
));
return_trace
(
c
->
check_struct
(
this
)
&&
valueArrayZ
.
sanitize
(
c
,
glyphCount
));
}
}
inline
bool
sanitize
(
hb_sanitize_context_t
*
c
,
const
void
*
base
)
const
{
TRACE_SANITIZE
(
this
);
return_trace
(
c
->
check_struct
(
this
)
&&
valueArrayZ
.
sanitize
(
c
,
glyphCount
,
base
));
}
protected:
protected:
HBUINT16
format
;
/* Format identifier--format = 8 */
HBUINT16
format
;
/* Format identifier--format = 8 */
...
@@ -328,6 +371,20 @@ struct Lookup
...
@@ -328,6 +371,20 @@ struct Lookup
default:
return_trace
(
true
);
default:
return_trace
(
true
);
}
}
}
}
inline
bool
sanitize
(
hb_sanitize_context_t
*
c
,
const
void
*
base
)
const
{
TRACE_SANITIZE
(
this
);
if
(
!
u
.
format
.
sanitize
(
c
))
return_trace
(
false
);
switch
(
u
.
format
)
{
case
0
:
return_trace
(
u
.
format0
.
sanitize
(
c
,
base
));
case
2
:
return_trace
(
u
.
format2
.
sanitize
(
c
,
base
));
case
4
:
return_trace
(
u
.
format4
.
sanitize
(
c
,
base
));
case
6
:
return_trace
(
u
.
format6
.
sanitize
(
c
,
base
));
case
8
:
return_trace
(
u
.
format8
.
sanitize
(
c
,
base
));
case
10
:
return_trace
(
false
);
/* No need to support format10 apparently */
default:
return_trace
(
true
);
}
}
protected:
protected:
union
{
union
{
...
...
src/hb-open-type.hh
浏览文件 @
b8b00fb3
...
@@ -833,6 +833,17 @@ struct VarSizedBinSearchArrayOf
...
@@ -833,6 +833,17 @@ struct VarSizedBinSearchArrayOf
return_trace
(
false
);
return_trace
(
false
);
return_trace
(
true
);
return_trace
(
true
);
}
}
template
<
typename
T
>
inline
bool
sanitize
(
hb_sanitize_context_t
*
c
,
const
void
*
base
,
T
user_data
)
const
{
TRACE_SANITIZE
(
this
);
if
(
unlikely
(
!
sanitize_shallow
(
c
)))
return_trace
(
false
);
unsigned
int
count
=
header
.
nUnits
;
for
(
unsigned
int
i
=
0
;
i
<
count
;
i
++
)
if
(
unlikely
(
!
(
*
this
)[
i
].
sanitize
(
c
,
base
,
user_data
)))
return_trace
(
false
);
return_trace
(
true
);
}
template
<
typename
T
>
template
<
typename
T
>
inline
const
Type
*
bsearch
(
const
T
&
key
)
const
inline
const
Type
*
bsearch
(
const
T
&
key
)
const
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录