Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Third Party Harfbuzz
提交
6a9be5bd
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看板
提交
6a9be5bd
编写于
4月 23, 2012
作者:
B
Behdad Esfahbod
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Rename hb_glyph_map_t to hb_set_t
上级
a4385f0b
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
20 addition
and
20 deletion
+20
-20
src/hb-ot-layout-common-private.hh
src/hb-ot-layout-common-private.hh
+8
-8
src/hb-ot-layout-gsubgpos-private.hh
src/hb-ot-layout-gsubgpos-private.hh
+6
-6
src/hb-ot-layout-private.hh
src/hb-ot-layout-private.hh
+1
-1
src/hb-ot-layout.cc
src/hb-ot-layout.cc
+1
-1
src/hb-ot-layout.h
src/hb-ot-layout.h
+2
-2
src/hb-ot-map-private.hh
src/hb-ot-map-private.hh
+1
-1
src/hb-ot-map.cc
src/hb-ot-map.cc
+1
-1
未找到文件。
src/hb-ot-layout-common-private.hh
浏览文件 @
6a9be5bd
...
@@ -131,7 +131,7 @@ struct RangeRecord
...
@@ -131,7 +131,7 @@ struct RangeRecord
return
c
->
check_struct
(
this
);
return
c
->
check_struct
(
this
);
}
}
inline
bool
intersects
(
const
hb_
glyph_map
_t
*
glyphs
)
const
{
inline
bool
intersects
(
const
hb_
set
_t
*
glyphs
)
const
{
return
glyphs
->
intersects
(
start
,
end
);
return
glyphs
->
intersects
(
start
,
end
);
}
}
...
@@ -358,7 +358,7 @@ struct CoverageFormat1
...
@@ -358,7 +358,7 @@ struct CoverageFormat1
return
glyphArray
.
sanitize
(
c
);
return
glyphArray
.
sanitize
(
c
);
}
}
inline
bool
intersects_coverage
(
const
hb_
glyph_map
_t
*
glyphs
,
unsigned
int
index
)
const
{
inline
bool
intersects_coverage
(
const
hb_
set
_t
*
glyphs
,
unsigned
int
index
)
const
{
return
glyphs
->
has
(
glyphArray
[
index
]);
return
glyphs
->
has
(
glyphArray
[
index
]);
}
}
...
@@ -402,7 +402,7 @@ struct CoverageFormat2
...
@@ -402,7 +402,7 @@ struct CoverageFormat2
return
rangeRecord
.
sanitize
(
c
);
return
rangeRecord
.
sanitize
(
c
);
}
}
inline
bool
intersects_coverage
(
const
hb_
glyph_map
_t
*
glyphs
,
unsigned
int
index
)
const
{
inline
bool
intersects_coverage
(
const
hb_
set
_t
*
glyphs
,
unsigned
int
index
)
const
{
unsigned
int
i
;
unsigned
int
i
;
unsigned
int
count
=
rangeRecord
.
len
;
unsigned
int
count
=
rangeRecord
.
len
;
for
(
i
=
0
;
i
<
count
;
i
++
)
{
for
(
i
=
0
;
i
<
count
;
i
++
)
{
...
@@ -476,7 +476,7 @@ struct Coverage
...
@@ -476,7 +476,7 @@ struct Coverage
}
}
}
}
inline
bool
intersects
(
const
hb_
glyph_map
_t
*
glyphs
)
const
{
inline
bool
intersects
(
const
hb_
set
_t
*
glyphs
)
const
{
/* TODO speed this up */
/* TODO speed this up */
Coverage
::
Iter
iter
;
Coverage
::
Iter
iter
;
for
(
iter
.
init
(
*
this
);
iter
.
more
();
iter
.
next
())
{
for
(
iter
.
init
(
*
this
);
iter
.
more
();
iter
.
next
())
{
...
@@ -486,7 +486,7 @@ struct Coverage
...
@@ -486,7 +486,7 @@ struct Coverage
return
false
;
return
false
;
}
}
inline
bool
intersects_coverage
(
const
hb_
glyph_map
_t
*
glyphs
,
unsigned
int
index
)
const
{
inline
bool
intersects_coverage
(
const
hb_
set
_t
*
glyphs
,
unsigned
int
index
)
const
{
switch
(
u
.
format
)
{
switch
(
u
.
format
)
{
case
1
:
return
u
.
format1
.
intersects_coverage
(
glyphs
,
index
);
case
1
:
return
u
.
format1
.
intersects_coverage
(
glyphs
,
index
);
case
2
:
return
u
.
format2
.
intersects_coverage
(
glyphs
,
index
);
case
2
:
return
u
.
format2
.
intersects_coverage
(
glyphs
,
index
);
...
@@ -574,7 +574,7 @@ struct ClassDefFormat1
...
@@ -574,7 +574,7 @@ struct ClassDefFormat1
&&
classValue
.
sanitize
(
c
);
&&
classValue
.
sanitize
(
c
);
}
}
inline
bool
intersects_class
(
const
hb_
glyph_map
_t
*
glyphs
,
unsigned
int
klass
)
const
{
inline
bool
intersects_class
(
const
hb_
set
_t
*
glyphs
,
unsigned
int
klass
)
const
{
unsigned
int
count
=
classValue
.
len
;
unsigned
int
count
=
classValue
.
len
;
for
(
unsigned
int
i
=
0
;
i
<
count
;
i
++
)
for
(
unsigned
int
i
=
0
;
i
<
count
;
i
++
)
if
(
classValue
[
i
]
==
klass
&&
glyphs
->
has
(
startGlyph
+
i
))
if
(
classValue
[
i
]
==
klass
&&
glyphs
->
has
(
startGlyph
+
i
))
...
@@ -608,7 +608,7 @@ struct ClassDefFormat2
...
@@ -608,7 +608,7 @@ struct ClassDefFormat2
return
rangeRecord
.
sanitize
(
c
);
return
rangeRecord
.
sanitize
(
c
);
}
}
inline
bool
intersects_class
(
const
hb_
glyph_map
_t
*
glyphs
,
unsigned
int
klass
)
const
{
inline
bool
intersects_class
(
const
hb_
set
_t
*
glyphs
,
unsigned
int
klass
)
const
{
unsigned
int
count
=
rangeRecord
.
len
;
unsigned
int
count
=
rangeRecord
.
len
;
for
(
unsigned
int
i
=
0
;
i
<
count
;
i
++
)
for
(
unsigned
int
i
=
0
;
i
<
count
;
i
++
)
if
(
rangeRecord
[
i
].
value
==
klass
&&
rangeRecord
[
i
].
intersects
(
glyphs
))
if
(
rangeRecord
[
i
].
value
==
klass
&&
rangeRecord
[
i
].
intersects
(
glyphs
))
...
@@ -647,7 +647,7 @@ struct ClassDef
...
@@ -647,7 +647,7 @@ struct ClassDef
}
}
}
}
inline
bool
intersects_class
(
const
hb_
glyph_map
_t
*
glyphs
,
unsigned
int
klass
)
const
{
inline
bool
intersects_class
(
const
hb_
set
_t
*
glyphs
,
unsigned
int
klass
)
const
{
switch
(
u
.
format
)
{
switch
(
u
.
format
)
{
case
1
:
return
u
.
format1
.
intersects_class
(
glyphs
,
klass
);
case
1
:
return
u
.
format1
.
intersects_class
(
glyphs
,
klass
);
case
2
:
return
u
.
format2
.
intersects_class
(
glyphs
,
klass
);
case
2
:
return
u
.
format2
.
intersects_class
(
glyphs
,
klass
);
...
...
src/hb-ot-layout-gsubgpos-private.hh
浏览文件 @
6a9be5bd
...
@@ -58,13 +58,13 @@ static inline uint8_t allocate_lig_id (hb_buffer_t *buffer) {
...
@@ -58,13 +58,13 @@ static inline uint8_t allocate_lig_id (hb_buffer_t *buffer) {
struct
hb_closure_context_t
struct
hb_closure_context_t
{
{
hb_face_t
*
face
;
hb_face_t
*
face
;
hb_
glyph_map
_t
*
glyphs
;
hb_
set
_t
*
glyphs
;
unsigned
int
nesting_level_left
;
unsigned
int
nesting_level_left
;
unsigned
int
debug_depth
;
unsigned
int
debug_depth
;
hb_closure_context_t
(
hb_face_t
*
face_
,
hb_closure_context_t
(
hb_face_t
*
face_
,
hb_
glyph_map
_t
*
glyphs_
,
hb_
set
_t
*
glyphs_
,
unsigned
int
nesting_level_left_
=
MAX_NESTING_LEVEL
)
:
unsigned
int
nesting_level_left_
=
MAX_NESTING_LEVEL
)
:
face
(
face_
),
glyphs
(
glyphs_
),
face
(
face_
),
glyphs
(
glyphs_
),
nesting_level_left
(
nesting_level_left_
),
nesting_level_left
(
nesting_level_left_
),
...
@@ -227,7 +227,7 @@ struct hb_apply_context_t
...
@@ -227,7 +227,7 @@ struct hb_apply_context_t
typedef
bool
(
*
intersects_func_t
)
(
hb_
glyph_map
_t
*
glyphs
,
const
USHORT
&
value
,
const
void
*
data
);
typedef
bool
(
*
intersects_func_t
)
(
hb_
set
_t
*
glyphs
,
const
USHORT
&
value
,
const
void
*
data
);
typedef
bool
(
*
match_func_t
)
(
hb_codepoint_t
glyph_id
,
const
USHORT
&
value
,
const
void
*
data
);
typedef
bool
(
*
match_func_t
)
(
hb_codepoint_t
glyph_id
,
const
USHORT
&
value
,
const
void
*
data
);
typedef
bool
(
*
closure_lookup_func_t
)
(
hb_closure_context_t
*
c
,
unsigned
int
lookup_index
);
typedef
bool
(
*
closure_lookup_func_t
)
(
hb_closure_context_t
*
c
,
unsigned
int
lookup_index
);
typedef
bool
(
*
apply_lookup_func_t
)
(
hb_apply_context_t
*
c
,
unsigned
int
lookup_index
);
typedef
bool
(
*
apply_lookup_func_t
)
(
hb_apply_context_t
*
c
,
unsigned
int
lookup_index
);
...
@@ -243,16 +243,16 @@ struct ContextApplyFuncs
...
@@ -243,16 +243,16 @@ struct ContextApplyFuncs
apply_lookup_func_t
apply
;
apply_lookup_func_t
apply
;
};
};
static
inline
bool
intersects_glyph
(
hb_
glyph_map
_t
*
glyphs
,
const
USHORT
&
value
,
const
void
*
data
HB_UNUSED
)
static
inline
bool
intersects_glyph
(
hb_
set
_t
*
glyphs
,
const
USHORT
&
value
,
const
void
*
data
HB_UNUSED
)
{
{
return
glyphs
->
has
(
value
);
return
glyphs
->
has
(
value
);
}
}
static
inline
bool
intersects_class
(
hb_
glyph_map
_t
*
glyphs
,
const
USHORT
&
value
,
const
void
*
data
)
static
inline
bool
intersects_class
(
hb_
set
_t
*
glyphs
,
const
USHORT
&
value
,
const
void
*
data
)
{
{
const
ClassDef
&
class_def
=
*
reinterpret_cast
<
const
ClassDef
*>
(
data
);
const
ClassDef
&
class_def
=
*
reinterpret_cast
<
const
ClassDef
*>
(
data
);
return
class_def
.
intersects_class
(
glyphs
,
value
);
return
class_def
.
intersects_class
(
glyphs
,
value
);
}
}
static
inline
bool
intersects_coverage
(
hb_
glyph_map
_t
*
glyphs
,
const
USHORT
&
value
,
const
void
*
data
)
static
inline
bool
intersects_coverage
(
hb_
set
_t
*
glyphs
,
const
USHORT
&
value
,
const
void
*
data
)
{
{
const
OffsetTo
<
Coverage
>
&
coverage
=
(
const
OffsetTo
<
Coverage
>&
)
value
;
const
OffsetTo
<
Coverage
>
&
coverage
=
(
const
OffsetTo
<
Coverage
>&
)
value
;
return
(
data
+
coverage
).
intersects
(
glyphs
);
return
(
data
+
coverage
).
intersects
(
glyphs
);
...
...
src/hb-ot-layout-private.hh
浏览文件 @
6a9be5bd
...
@@ -95,7 +95,7 @@ _hb_ot_layout_destroy (hb_ot_layout_t *layout);
...
@@ -95,7 +95,7 @@ _hb_ot_layout_destroy (hb_ot_layout_t *layout);
struct
_hb_
glyph_map
_t
struct
_hb_
set
_t
{
{
void
clear
(
void
)
{
void
clear
(
void
)
{
memset
(
elts
,
0
,
sizeof
elts
);
memset
(
elts
,
0
,
sizeof
elts
);
...
...
src/hb-ot-layout.cc
浏览文件 @
6a9be5bd
...
@@ -472,7 +472,7 @@ hb_ot_layout_substitute_finish (hb_buffer_t *buffer HB_UNUSED)
...
@@ -472,7 +472,7 @@ hb_ot_layout_substitute_finish (hb_buffer_t *buffer HB_UNUSED)
hb_bool_t
hb_bool_t
hb_ot_layout_substitute_closure_lookup
(
hb_face_t
*
face
,
hb_ot_layout_substitute_closure_lookup
(
hb_face_t
*
face
,
hb_
glyph_map
_t
*
glyphs
,
hb_
set
_t
*
glyphs
,
unsigned
int
lookup_index
)
unsigned
int
lookup_index
)
{
{
hb_closure_context_t
c
(
face
,
glyphs
);
hb_closure_context_t
c
(
face
,
glyphs
);
...
...
src/hb-ot-layout.h
浏览文件 @
6a9be5bd
...
@@ -183,11 +183,11 @@ void
...
@@ -183,11 +183,11 @@ void
hb_ot_layout_substitute_finish
(
hb_buffer_t
*
buffer
);
hb_ot_layout_substitute_finish
(
hb_buffer_t
*
buffer
);
typedef
struct
_hb_
glyph_map_t
hb_glyph_map
_t
;
typedef
struct
_hb_
set_t
hb_set
_t
;
hb_bool_t
hb_bool_t
hb_ot_layout_substitute_closure_lookup
(
hb_face_t
*
face
,
hb_ot_layout_substitute_closure_lookup
(
hb_face_t
*
face
,
hb_
glyph_map
_t
*
glyphs
,
hb_
set
_t
*
glyphs
,
unsigned
int
lookup_index
);
unsigned
int
lookup_index
);
/*
/*
...
...
src/hb-ot-map-private.hh
浏览文件 @
6a9be5bd
...
@@ -126,7 +126,7 @@ struct hb_ot_map_t
...
@@ -126,7 +126,7 @@ struct hb_ot_map_t
hb_buffer_t
*
buffer
)
const
;
hb_buffer_t
*
buffer
)
const
;
HB_INTERNAL
void
substitute_closure
(
hb_face_t
*
face
,
HB_INTERNAL
void
substitute_closure
(
hb_face_t
*
face
,
hb_
glyph_map
_t
*
glyphs
)
const
;
hb_
set
_t
*
glyphs
)
const
;
hb_mask_t
global_mask
;
hb_mask_t
global_mask
;
...
...
src/hb-ot-map.cc
浏览文件 @
6a9be5bd
...
@@ -96,7 +96,7 @@ void hb_ot_map_t::apply (unsigned int table_index,
...
@@ -96,7 +96,7 @@ void hb_ot_map_t::apply (unsigned int table_index,
}
}
void
hb_ot_map_t
::
substitute_closure
(
hb_face_t
*
face
,
void
hb_ot_map_t
::
substitute_closure
(
hb_face_t
*
face
,
hb_
glyph_map
_t
*
glyphs
)
const
hb_
set
_t
*
glyphs
)
const
{
{
unsigned
int
table_index
=
0
;
unsigned
int
table_index
=
0
;
unsigned
int
i
=
0
;
unsigned
int
i
=
0
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录