From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-io0-x231.google.com (mail-io0-x231.google.com [IPv6:2607:f8b0:4001:c06::231]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 8F23421A16EED for ; Tue, 30 May 2017 17:02:40 -0700 (PDT) Received: by mail-io0-x231.google.com with SMTP id f102so2702803ioi.2 for ; Tue, 30 May 2017 17:03:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=UjZVamBU5n6pP2yVswjstD+WrJpjV7oC2ykgJeK05rI=; b=iCu3GBm75Tq/U9YBUFcDKH7sUvdz8FDgSypUrcSacZJjKoKI5Rpyt+XWWbWfuA5Qy5 vIP3kBqFQLiANHC/F+Bh6/4VbQRuqmfPXRIGnhkcXR/CAtK9DF4cyU2saVl9uH9zJl89 wkKyZz20OzwbmS83NlYAXoydYk6cIARQ191kFAIcl5b17SkCFhIBGQU0/fhooVlSXlEx MdM74ut4HXYUD9eqesussIWvVuIh/KYbDaUnVq6JpKvBMo2KXD2pUEWYmDbbjxxHJ/m8 ktqhH3k6RndKhRpp01oAcnudCA6PY6Rd7OplBoHqpf85gFG7Ad03u04mVifWTy7/lECv qLUw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=UjZVamBU5n6pP2yVswjstD+WrJpjV7oC2ykgJeK05rI=; b=Wm+9UvHysLzEFnzlkr0YEp0QVLLjlKlG7LeKbk6LoGnn+zDO/N9OjSSI84gT5rJEL6 YNzTwGJoKiIqzrHjsM8QENH6Uu994ShThSR3W3KeYX6T/GrrWDyAbITWrWd7j41IVZ9/ q0ytu+e/aqes5ZQR77XssgaP/M9U+ma1jbParDFUBYxfMej1/rK4UVs7Yb1PuvFQ2QZs gXp5Ex7Zk1h9li35leLwExpA9pHxW4rEO+2JC1HcufKZxKbnBrsS2GKwo+32VgNPWCZk EkcphbknxYffgIZZhg/wc6yXLmG9CXCAt5YpnlZQCjgp+AXT5nitiFbEdgkg/kMOFY+6 mkNA== X-Gm-Message-State: AODbwcB5Wtyp/wf4bsUkqxcU91vKpwrsKR0BQCWp6+PIjkNLI1LTuTe0 efm+LHXMIvTcnp423WZtGUwxPn0CxhmgOYg= X-Received: by 10.107.136.17 with SMTP id k17mr21701100iod.89.1496189019308; Tue, 30 May 2017 17:03:39 -0700 (PDT) MIME-Version: 1.0 Received: by 10.107.138.154 with HTTP; Tue, 30 May 2017 17:03:38 -0700 (PDT) From: Nikolay Bodunov Date: Wed, 31 May 2017 03:03:38 +0300 Message-ID: To: edk2-devel@lists.01.org X-Content-Filtered-By: Mailman/MimeDel 2.1.22 Subject: Localization help need: national symbols are not displayed on BIOS screen after adding a new language X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 31 May 2017 00:02:40 -0000 Content-Type: text/plain; charset="UTF-8" Hello I added 3 new languages in MdeModulePks/Application/UiApp example from EDK2 and I got a problem with strings output. Using Nt32Pkg emulator with Win 7. My problem is: when I add Russian language, I also add new string on that language to existing token, but I can't see that string shown on screen. Specifically, I can see English part of the string only. I mean, if I write the first half of the string on English and the second half on Russian, I can see only English half of the string on BIOS screen. Here are my problem on the screenshot: https://yadi.sk/i/mgh_-dBH3JbYtp I didn't added corresponding Russian strings to any other tokens, so displaying "!" instead for them is ok. If I switch back to English or French, correct strings are shown again. What I did: 1. Added new languages in MdePkg.dec: gEfiMdePkgTokenSpaceGuid.PcdUefiVariableDefaultPlatform LangCodes|"en;fr;en-US;fr-FR;ru;de;zh-cn"|VOID*|0x0000001e 2. Opened UNI file in Notepad++ and added new languages, after English and French: #langdef en-US "English" #langdef fr-FR "Francais" #langdef en "Standard English" #langdef fr "Standard Francais" #langdef ru "Russian" //#langdef ru-RU "Russian" #langdef de "German" #langdef zh-cn "Chinese (PRC)" 3. Switched (in Windows 7) on Russian codepage and added new string for "ru" locale that token "STR_LANGUAGE_SELECT" https://yadi.sk/i/quf2Gd003JbZez I also located my string in .efi output file in HEX to investigate what could be wrong, but I see exactly what I expected: codepage 04 and symbol codes which conforms corresponding Russian symbols in UCS-2: 2004 4304 4104 4104 3A04 3804 3904 (and English symbols, too): https://yadi.sk/i/QIEqcqKg3JbaiL >>From the other side, I got support for German locale in that way, having typical German symbols in string attached ot that token. Any suggestions, what I did wrong or what I should do else? I suppose there should be some "magical" function call that adds more than one locale, but I don't know what it is. Maybe default font just does not support Russian locale? Which font should I use instead and where I can read about it? Text search in EDK2 source tree does't find string "ru-RU" I cannot diagnose it in programming way: when I add non-existing locale "xz" to MdePkg.dec, I have no error during compilation and I can see this pseudo-locale in PlatformLangCodes variable then. With best regards, Nikolay Bodunov