Index: media/fonts/cjk/CMakeLists.txt =================================================================== --- media/fonts/cjk/CMakeLists.txt (revision 0) +++ media/fonts/cjk/CMakeLists.txt (working copy) @@ -0,0 +1,92 @@ +# CMake file to include CJK fonts extracted from Windows or otherwise + +if(CJK_FONT_USE_TTC) + message(AUTHOR_WARNING "Using .ttc CJK fonts may not be completely supported under ReactOS.") + # Chinese (Traditional): MingLiU (細明體) + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/mingliu.ttc) + list(APPEND CJK_FONT_FILES mingliu.ttc) + endif() + + # Chinese (Simplified): SimSun (宋体) + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/simsun.ttc) + list(APPEND CJK_FONT_FILES simsun.ttc) + endif() + + # Japanese: MS Gothic + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/msgothic.ttc) + list(APPEND CJK_FONT_FILES msgothic.ttc) + endif() + + # Korean: Gulim (굴림) + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/gulim.ttc) + list(APPEND CJK_FONT_FILES gulim.ttc) + endif() +else() + # Chinese (Traditional): MingLiU (細明體) + # - MingLiU + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/mingliu001.ttf) + list(APPEND CJK_FONT_FILES mingliu001.ttf) + endif() + # - PMingLiU + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/mingliu002.ttf) + list(APPEND CJK_FONT_FILES mingliu002.ttf) + endif() + # - MingLiU-HKSCS (not available in any Windows XP by default) + # Included with "Windows XP Font Pack for ISO 10646:2003 + + # Amendment 1 Traditional Chinese Support" support pack + # https://www.microsoft.com/en-US/download/details.aspx?id=10109 + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/mingliu003.ttf) + list(APPEND CJK_FONT_FILES mingliu003.ttf) + endif() + + # Chinese (Simplified): SimSun (宋体) + # - SimSun + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/simsun001.ttf) + list(APPEND CJK_FONT_FILES simsun001.ttf) + endif() + # - NSimSun + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/simsun002.ttf) + list(APPEND CJK_FONT_FILES simsun002.ttf) + endif() + # - SimSun-PUA + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/simsun003.ttf) + list(APPEND CJK_FONT_FILES simsun003.ttf) + endif() + + # Japanese: MS Gothic + # - MS Gothic + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/msgothic001.ttf) + list(APPEND CJK_FONT_FILES msgothic001.ttf) + endif() + # - MS PGothic + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/msgothic002.ttf) + list(APPEND CJK_FONT_FILES msgothic002.ttf) + endif() + # - MS UI Gothic + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/msgothic003.ttf) + list(APPEND CJK_FONT_FILES msgothic003.ttf) + endif() + + # Korean: Gulim (굴림) + # - Gulim + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/gulim001.ttf) + list(APPEND CJK_FONT_FILES gulim001.ttf) + endif() + # - GulimChe + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/gulim002.ttf) + list(APPEND CJK_FONT_FILES gulim002.ttf) + endif() + # - Dotum + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/gulim003.ttf) + list(APPEND CJK_FONT_FILES gulim003.ttf) + endif() + # - DotumChe + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/gulim004.ttf) + list(APPEND CJK_FONT_FILES gulim004.ttf) + endif() +endif() + +foreach(item ${CJK_FONT_FILES}) + message(STATUS "Including CJK font file ${item}") + add_cd_file(FILE "${CMAKE_CURRENT_SOURCE_DIR}/${item}" DESTINATION reactos/Fonts FOR all) +endforeach(item) Index: media/fonts/cjk/README.txt =================================================================== --- media/fonts/cjk/README.txt (revision 0) +++ media/fonts/cjk/README.txt (working copy) @@ -0,0 +1,42 @@ +File: media/fonts/cjk/README.txt + +# File Revision History +## 2015-04-28 +- Initial writeup by Alvin Wong (alvinhochun). + + +# Information + +This directory is for including CJK fonts extracted from Windows. + +Since there currently aren't any suitable direct substitution for the CJK +fonts used in Windows, developers may have to extract them from Windows for +testing. + +** IMPORTANT NOTE 1 **: Since the fonts extracted from Windows are copyrighted +materials, builds containing them must **NOT** be distrubuted to *any* users +or developers in *any* forms. Developers who included these fonts in any +previous builds **must** perform a **clean rebuild** to ensure that they are +not included in the build. + +** IMPORTANT NOTE 2 **: Extracting those fonts from Windows and using them +within ReactOS may **NOT** be legal in some places in the world. Please be +careful before doing that! + + +# Instructions + +1. Extract the needed CJK font(s) from Windows. + - mingliu.ttc for Chinese (Traditional) + - simsun.ttc for Chinese (Simplified) + - msgothic.ttc for Japanese + - gulim.ttc for Korean +2. Split the .ttc file(s) into .ttf files. + (TTC support is currently not complete in ReactOS.) + There is a tool called "UniteTTC" to do that: + http://yozvox.web.fc2.com/556E697465545443.html +3. Make sure the output filenames are in lowercase. +4. Place the files under this directory. +5. (Optional) Edit `base/setup/usetup/muifonts.h` to use the specified font. + (See [CORE-9615](https://jira.reactos.org/browse/CORE-9615)) + Index: media/fonts/CMakeLists.txt =================================================================== --- media/fonts/CMakeLists.txt (revision 67463) +++ media/fonts/CMakeLists.txt (working copy) @@ -82,3 +82,5 @@ foreach(item ${FONT_FILES}) add_cd_file(FILE "${CMAKE_CURRENT_SOURCE_DIR}/${item}" DESTINATION reactos/Fonts FOR all) endforeach(item) + +add_subdirectory(cjk)