Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Third Party Harfbuzz
提交
5d4b0377
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看板
提交
5d4b0377
编写于
1月 22, 2019
作者:
B
Behdad Esfahbod
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Convert unsigned enum class consts to static constexpr
Part of
https://github.com/harfbuzz/harfbuzz/issues/1553
上级
ef006549
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
11 addition
and
11 deletion
+11
-11
src/hb-aat-layout-common.hh
src/hb-aat-layout-common.hh
+3
-3
src/hb-aat-layout-kerx-table.hh
src/hb-aat-layout-kerx-table.hh
+1
-1
src/hb-buffer.hh
src/hb-buffer.hh
+1
-1
src/hb-open-type.hh
src/hb-open-type.hh
+1
-1
src/hb-ot-kern-table.hh
src/hb-ot-kern-table.hh
+2
-2
src/hb-ot-layout-common.hh
src/hb-ot-layout-common.hh
+1
-1
src/hb-ot-layout.cc
src/hb-ot-layout.cc
+2
-2
未找到文件。
src/hb-aat-layout-common.hh
浏览文件 @
5d4b0377
...
@@ -77,7 +77,7 @@ struct LookupFormat0
...
@@ -77,7 +77,7 @@ struct LookupFormat0
template
<
typename
T
>
template
<
typename
T
>
struct
LookupSegmentSingle
struct
LookupSegmentSingle
{
{
enum
{
TerminationWordCount
=
2u
}
;
static
constexpr
unsigned
TerminationWordCount
=
2u
;
int
cmp
(
hb_codepoint_t
g
)
const
int
cmp
(
hb_codepoint_t
g
)
const
{
return
g
<
first
?
-
1
:
g
<=
last
?
0
:
+
1
;
}
{
return
g
<
first
?
-
1
:
g
<=
last
?
0
:
+
1
;
}
...
@@ -136,7 +136,7 @@ struct LookupFormat2
...
@@ -136,7 +136,7 @@ struct LookupFormat2
template
<
typename
T
>
template
<
typename
T
>
struct
LookupSegmentArray
struct
LookupSegmentArray
{
{
enum
{
TerminationWordCount
=
2u
}
;
static
constexpr
unsigned
TerminationWordCount
=
2u
;
const
T
*
get_value
(
hb_codepoint_t
glyph_id
,
const
void
*
base
)
const
const
T
*
get_value
(
hb_codepoint_t
glyph_id
,
const
void
*
base
)
const
{
{
...
@@ -207,7 +207,7 @@ struct LookupFormat4
...
@@ -207,7 +207,7 @@ struct LookupFormat4
template
<
typename
T
>
template
<
typename
T
>
struct
LookupSingle
struct
LookupSingle
{
{
enum
{
TerminationWordCount
=
1u
}
;
static
constexpr
unsigned
TerminationWordCount
=
1u
;
int
cmp
(
hb_codepoint_t
g
)
const
{
return
glyph
.
cmp
(
g
);
}
int
cmp
(
hb_codepoint_t
g
)
const
{
return
glyph
.
cmp
(
g
);
}
...
...
src/hb-aat-layout-kerx-table.hh
浏览文件 @
5d4b0377
...
@@ -980,7 +980,7 @@ struct kerx : KerxTable<kerx>
...
@@ -980,7 +980,7 @@ struct kerx : KerxTable<kerx>
friend
struct
KerxTable
<
kerx
>
;
friend
struct
KerxTable
<
kerx
>
;
static
constexpr
hb_tag_t
tableTag
=
HB_AAT_TAG_kerx
;
static
constexpr
hb_tag_t
tableTag
=
HB_AAT_TAG_kerx
;
enum
{
minVersion
=
2u
}
;
static
constexpr
unsigned
minVersion
=
2u
;
typedef
KerxSubTableHeader
SubTableHeader
;
typedef
KerxSubTableHeader
SubTableHeader
;
typedef
SubTableHeader
::
Types
Types
;
typedef
SubTableHeader
::
Types
Types
;
...
...
src/hb-buffer.hh
浏览文件 @
5d4b0377
...
@@ -119,7 +119,7 @@ struct hb_buffer_t
...
@@ -119,7 +119,7 @@ struct hb_buffer_t
/* Text before / after the main buffer contents.
/* Text before / after the main buffer contents.
* Always in Unicode, and ordered outward.
* Always in Unicode, and ordered outward.
* Index 0 is for "pre-context", 1 for "post-context". */
* Index 0 is for "pre-context", 1 for "post-context". */
enum
{
CONTEXT_LENGTH
=
5u
}
;
static
constexpr
unsigned
CONTEXT_LENGTH
=
5u
;
hb_codepoint_t
context
[
2
][
CONTEXT_LENGTH
];
hb_codepoint_t
context
[
2
][
CONTEXT_LENGTH
];
unsigned
int
context_len
[
2
];
unsigned
int
context_len
[
2
];
...
...
src/hb-open-type.hh
浏览文件 @
5d4b0377
...
@@ -159,7 +159,7 @@ typedef HBUINT16 GlyphID;
...
@@ -159,7 +159,7 @@ typedef HBUINT16 GlyphID;
/* Script/language-system/feature index */
/* Script/language-system/feature index */
struct
Index
:
HBUINT16
{
struct
Index
:
HBUINT16
{
enum
{
NOT_FOUND_INDEX
=
0xFFFFu
}
;
static
constexpr
unsigned
NOT_FOUND_INDEX
=
0xFFFFu
;
};
};
DECLARE_NULL_NAMESPACE_BYTES
(
OT
,
Index
);
DECLARE_NULL_NAMESPACE_BYTES
(
OT
,
Index
);
...
...
src/hb-ot-kern-table.hh
浏览文件 @
5d4b0377
...
@@ -198,7 +198,7 @@ struct KernOT : AAT::KerxTable<KernOT>
...
@@ -198,7 +198,7 @@ struct KernOT : AAT::KerxTable<KernOT>
friend
struct
AAT
::
KerxTable
<
KernOT
>
;
friend
struct
AAT
::
KerxTable
<
KernOT
>
;
static
constexpr
hb_tag_t
tableTag
=
HB_OT_TAG_kern
;
static
constexpr
hb_tag_t
tableTag
=
HB_OT_TAG_kern
;
enum
{
minVersion
=
0u
}
;
static
constexpr
unsigned
minVersion
=
0u
;
typedef
KernOTSubTableHeader
SubTableHeader
;
typedef
KernOTSubTableHeader
SubTableHeader
;
typedef
SubTableHeader
::
Types
Types
;
typedef
SubTableHeader
::
Types
Types
;
...
@@ -253,7 +253,7 @@ struct KernAAT : AAT::KerxTable<KernAAT>
...
@@ -253,7 +253,7 @@ struct KernAAT : AAT::KerxTable<KernAAT>
friend
struct
AAT
::
KerxTable
<
KernAAT
>
;
friend
struct
AAT
::
KerxTable
<
KernAAT
>
;
static
constexpr
hb_tag_t
tableTag
=
HB_OT_TAG_kern
;
static
constexpr
hb_tag_t
tableTag
=
HB_OT_TAG_kern
;
enum
{
minVersion
=
0x00010000u
}
;
static
constexpr
unsigned
minVersion
=
0x00010000u
;
typedef
KernAATSubTableHeader
SubTableHeader
;
typedef
KernAATSubTableHeader
SubTableHeader
;
typedef
SubTableHeader
::
Types
Types
;
typedef
SubTableHeader
::
Types
Types
;
...
...
src/hb-ot-layout-common.hh
浏览文件 @
5d4b0377
...
@@ -1949,7 +1949,7 @@ struct FeatureVariationRecord
...
@@ -1949,7 +1949,7 @@ struct FeatureVariationRecord
struct
FeatureVariations
struct
FeatureVariations
{
{
enum
{
NOT_FOUND_INDEX
=
0xFFFFFFFFu
}
;
static
constexpr
unsigned
NOT_FOUND_INDEX
=
0xFFFFFFFFu
;
bool
find_index
(
const
int
*
coords
,
unsigned
int
coord_len
,
bool
find_index
(
const
int
*
coords
,
unsigned
int
coord_len
,
unsigned
int
*
index
)
const
unsigned
int
*
index
)
const
...
...
src/hb-ot-layout.cc
浏览文件 @
5d4b0377
...
@@ -1299,7 +1299,7 @@ hb_ot_layout_feature_get_characters (hb_face_t *face,
...
@@ -1299,7 +1299,7 @@ hb_ot_layout_feature_get_characters (hb_face_t *face,
struct
GSUBProxy
struct
GSUBProxy
{
{
enum
{
table_index
=
0u
}
;
static
constexpr
unsigned
table_index
=
0u
;
static
constexpr
bool
inplace
=
false
;
static
constexpr
bool
inplace
=
false
;
typedef
OT
::
SubstLookup
Lookup
;
typedef
OT
::
SubstLookup
Lookup
;
...
@@ -1313,7 +1313,7 @@ struct GSUBProxy
...
@@ -1313,7 +1313,7 @@ struct GSUBProxy
struct
GPOSProxy
struct
GPOSProxy
{
{
enum
{
table_index
=
1u
}
;
static
constexpr
unsigned
table_index
=
1u
;
static
constexpr
bool
inplace
=
true
;
static
constexpr
bool
inplace
=
true
;
typedef
OT
::
PosLookup
Lookup
;
typedef
OT
::
PosLookup
Lookup
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录