Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(172)

Side by Side Diff: fpdfsdk/src/pdfwindow/PWL_FontMap.cpp

Issue 301263002: In linux and mac, use Arial to replace Tahoma for displaying east europe characters (Closed) Base URL: https://pdfium.googlesource.com/pdfium@master
Patch Set: Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 PDFium Authors. All rights reserved. 1 // Copyright 2014 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 6
7 #include "../../include/pdfwindow/PDFWindow.h" 7 #include "../../include/pdfwindow/PDFWindow.h"
8 #include "../../include/pdfwindow/PWL_Wnd.h" 8 #include "../../include/pdfwindow/PWL_Wnd.h"
9 #include "../../include/pdfwindow/PWL_FontMap.h" 9 #include "../../include/pdfwindow/PWL_FontMap.h"
10 10
(...skipping 490 matching lines...) Expand 10 before | Expand all | Expand 10 after
501 return nCharset; 501 return nCharset;
502 } 502 }
503 503
504 const CPWL_FontMap::CharsetFontMap CPWL_FontMap::defaultTTFMap[] = { 504 const CPWL_FontMap::CharsetFontMap CPWL_FontMap::defaultTTFMap[] = {
505 { ANSI_CHARSET, "Helvetica" }, 505 { ANSI_CHARSET, "Helvetica" },
506 { GB2312_CHARSET, "SimSun" }, 506 { GB2312_CHARSET, "SimSun" },
507 { CHINESEBIG5_CHARSET, "MingLiU" }, 507 { CHINESEBIG5_CHARSET, "MingLiU" },
508 { SHIFTJIS_CHARSET, "MS Gothic" }, 508 { SHIFTJIS_CHARSET, "MS Gothic" },
509 { HANGUL_CHARSET, "Batang" }, 509 { HANGUL_CHARSET, "Batang" },
510 { RUSSIAN_CHARSET, "Arial" }, 510 { RUSSIAN_CHARSET, "Arial" },
511 #if _FXM_PLATFORM_ == _FXM_PLATFORM_LINUX_ || _FXM_PLATFORM_ == _FXM_PLATFORM_AP PLE_
512 { EASTEUROPE_CHARSET, "Arial" },
513 #else
511 { EASTEUROPE_CHARSET, "Tahoma" }, 514 { EASTEUROPE_CHARSET, "Tahoma" },
515 #endif
512 { ARABIC_CHARSET, "Arial" }, 516 { ARABIC_CHARSET, "Arial" },
513 { -1, NULL } 517 { -1, NULL }
514 }; 518 };
515 519
516 CFX_ByteString CPWL_FontMap::GetDefaultFontByCharset(FX_INT32 nCharset) 520 CFX_ByteString CPWL_FontMap::GetDefaultFontByCharset(FX_INT32 nCharset)
517 { 521 {
518 int i = 0; 522 int i = 0;
519 while (defaultTTFMap[i].charset != -1) { 523 while (defaultTTFMap[i].charset != -1) {
520 if (nCharset == defaultTTFMap[i].charset) 524 if (nCharset == defaultTTFMap[i].charset)
521 return defaultTTFMap[i].fontname; 525 return defaultTTFMap[i].fontname;
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
592 } 596 }
593 597
594 CPWL_DocFontMap::~CPWL_DocFontMap() 598 CPWL_DocFontMap::~CPWL_DocFontMap()
595 { 599 {
596 } 600 }
597 601
598 CPDF_Document* CPWL_DocFontMap::GetDocument() 602 CPDF_Document* CPWL_DocFontMap::GetDocument()
599 { 603 {
600 return m_pAttachedDoc; 604 return m_pAttachedDoc;
601 } 605 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698