提交 a569046e 编写于 作者: P prr

8170913: Java "1.8.0_112" on Windows 10 displays different characters for...

8170913: Java "1.8.0_112" on Windows 10 displays different characters for EUDCs from ones created in eudcedit.exe.
Reviewed-by: vadim, psadhukhan
上级 eee02e51
...@@ -93,20 +93,25 @@ public final class CompositeFont extends Font2D { ...@@ -93,20 +93,25 @@ public final class CompositeFont extends Font2D {
* better that it is handled internally to the CompositeFont class. * better that it is handled internally to the CompositeFont class.
*/ */
if (fm.getEUDCFont() != null) { if (fm.getEUDCFont() != null) {
int msCnt = numMetricsSlots;
int fbCnt = numSlots - msCnt;
numSlots++; numSlots++;
if (componentNames != null) { if (componentNames != null) {
componentNames = new String[numSlots]; componentNames = new String[numSlots];
System.arraycopy(compNames, 0, componentNames, 0, numSlots-1); System.arraycopy(compNames, 0, componentNames, 0, msCnt);
componentNames[numSlots-1] = componentNames[msCnt] = fm.getEUDCFont().getFontName(null);
fm.getEUDCFont().getFontName(null); System.arraycopy(compNames, msCnt,
componentNames, msCnt+1, fbCnt);
} }
if (componentFileNames != null) { if (componentFileNames != null) {
componentFileNames = new String[numSlots]; componentFileNames = new String[numSlots];
System.arraycopy(compFileNames, 0, System.arraycopy(compFileNames, 0,
componentFileNames, 0, numSlots-1); componentFileNames, 0, msCnt);
System.arraycopy(compFileNames, msCnt,
componentFileNames, msCnt+1, fbCnt);
} }
components = new PhysicalFont[numSlots]; components = new PhysicalFont[numSlots];
components[numSlots-1] = fm.getEUDCFont(); components[msCnt] = fm.getEUDCFont();
deferredInitialisation = new boolean[numSlots]; deferredInitialisation = new boolean[numSlots];
if (defer) { if (defer) {
for (int i=0; i<numSlots-1; i++) { for (int i=0; i<numSlots-1; i++) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册