Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell11
提交
9dbfbc21
D
dragonwell11
项目概览
openanolis
/
dragonwell11
通知
7
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
dragonwell11
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
9dbfbc21
编写于
1月 19, 2011
作者:
P
prr
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
6951501: EUDC character is not displayed on Swing
Reviewed-by: igor, jgodinez
上级
533058e4
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
12 addition
and
1 deletion
+12
-1
jdk/src/windows/classes/sun/awt/Win32FontManager.java
jdk/src/windows/classes/sun/awt/Win32FontManager.java
+5
-1
jdk/src/windows/native/sun/windows/awt_Win32GraphicsEnv.cpp
jdk/src/windows/native/sun/windows/awt_Win32GraphicsEnv.cpp
+7
-0
未找到文件。
jdk/src/windows/classes/sun/awt/Win32FontManager.java
浏览文件 @
9dbfbc21
...
...
@@ -81,6 +81,10 @@ public class Win32FontManager extends SunFontManager {
*/
private
static
native
String
getEUDCFontFile
();
public
TrueTypeFont
getEUDCFont
()
{
return
eudcFont
;
}
public
Win32FontManager
()
{
super
();
AccessController
.
doPrivileged
(
new
PrivilegedAction
()
{
...
...
@@ -198,7 +202,7 @@ public class Win32FontManager extends SunFontManager {
familyToFontListMap
,
Locale
locale
);
p
ublic
synchronized
native
String
getFontPath
(
boolean
noType1Fonts
);
p
rotected
synchronized
native
String
getFontPath
(
boolean
noType1Fonts
);
public
String
[]
getDefaultPlatformFont
()
{
...
...
jdk/src/windows/native/sun/windows/awt_Win32GraphicsEnv.cpp
浏览文件 @
9dbfbc21
...
...
@@ -214,6 +214,7 @@ Java_sun_awt_Win32FontManager_deRegisterFontWithPlatform(JNIEnv *env,
#define EUDCKEY_ZH_CN L"EUDC\\936"
#define EUDCKEY_ZH_TW L"EUDC\\950"
#define EUDCKEY_KO_KR L"EUDC\\949"
#define EUDCKEY_EN_US L"EUDC\\1252"
#define LANGID_JA_JP 0x411
#define LANGID_ZH_CN 0x0804
#define LANGID_ZH_SG 0x1004
...
...
@@ -221,6 +222,7 @@ Java_sun_awt_Win32FontManager_deRegisterFontWithPlatform(JNIEnv *env,
#define LANGID_ZH_HK 0x0c04
#define LANGID_ZH_MO 0x1404
#define LANGID_KO_KR 0x0412
#define LANGID_EN_US 0x0409
JNIEXPORT
jstring
JNICALL
...
...
@@ -237,6 +239,9 @@ Java_sun_awt_Win32FontManager_getEUDCFontFile(JNIEnv *env, jclass cl) {
LANGID
langID
=
GetSystemDefaultLangID
();
//lookup for encoding ID, EUDC only supported in
//codepage 932, 936, 949, 950 (and unicode)
// On Windows 7, at least for me, it shows up in Cp1252 if
// I create a custom font. Might as well support that as it makes
// verification easier.
if
(
langID
==
LANGID_JA_JP
)
{
eudcKey
=
EUDCKEY_JA_JP
;
}
else
if
(
langID
==
LANGID_ZH_CN
||
langID
==
LANGID_ZH_SG
)
{
...
...
@@ -246,6 +251,8 @@ Java_sun_awt_Win32FontManager_getEUDCFontFile(JNIEnv *env, jclass cl) {
eudcKey
=
EUDCKEY_ZH_TW
;
}
else
if
(
langID
==
LANGID_KO_KR
)
{
eudcKey
=
EUDCKEY_KO_KR
;
}
else
if
(
langID
==
LANGID_EN_US
)
{
eudcKey
=
EUDCKEY_EN_US
;
}
else
{
return
NULL
;
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录