From 43cd4d510211d347e897651fcf391dab53d5841c Mon Sep 17 00:00:00 2001 From: Viktor Szakats Date: Thu, 16 Jul 2009 08:49:33 +0000 Subject: [PATCH] 2009-07-16 10:31 UTC+0200 Viktor Szakats (harbour.01 syenar.hu) * include/hbextern.ch * source/lang/Makefile + source/lang/msguados.c + Added Ukrainian language module for cp1125. (borrowed from xhb, work of Pavel Tsarenko.) I've made a few corrections compared to xhb: - Using the same internal name as filename for consistency with other language modules (UADOS instead of UA1125). - Fixed date format which must only contain YYYY, MM, DD regardless of the CP/language used, since it's a picture mask. - Formatting (semicolon, spaces, deleted embedded $Id$ not needed with SVN) - Added to hbextern.ch. * source/lang/msguakoi.c * source/lang/msgua866.c * Two corrections to internal name. (borrowed from xhb, work of Pavel Tsarenko.) ; QUESTION: I wonder why the texts are very much different in Harbour and xhb. Someone familiar with Ukrainian language and encodings should check this, only one of them can be right and all CPs should be synced with each other the only thing being different is the encoding. * source/codepage/msguakoi.c ! Fixed one letter. * source/codepage/cpuawin.c * source/codepage/cpua1125.c * source/codepage/cpua866.c * source/codepage/cpuakoi.c * Added "CYRILLIC LETTER GHE WITH UPTURN" letter. (borrowed from xhb, work of Pavel Tsarenko.) --- harbour/ChangeLog | 37 +++++ harbour/include/hbextern.ch | 1 + harbour/source/codepage/cpua1125.c | 6 +- harbour/source/codepage/cpua866.c | 6 +- harbour/source/codepage/cpuakoi.c | 6 +- harbour/source/codepage/cpuawin.c | 6 +- harbour/source/lang/Makefile | 1 + harbour/source/lang/msgua866.c | 2 +- harbour/source/lang/msguados.c | 218 +++++++++++++++++++++++++++++ harbour/source/lang/msguakoi.c | 14 +- 10 files changed, 277 insertions(+), 20 deletions(-) create mode 100644 harbour/source/lang/msguados.c diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 316528c746..9a16e87d48 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -17,6 +17,43 @@ past entries belonging to author(s): Viktor Szakats. */ +2009-07-16 10:31 UTC+0200 Viktor Szakats (harbour.01 syenar.hu) + * include/hbextern.ch + * source/lang/Makefile + + source/lang/msguados.c + + Added Ukrainian language module for cp1125. + (borrowed from xhb, work of Pavel Tsarenko.) + I've made a few corrections compared to xhb: + - Using the same internal name as filename for + consistency with other language modules + (UADOS instead of UA1125). + - Fixed date format which must only contain YYYY, MM, DD + regardless of the CP/language used, since it's a picture mask. + - Formatting (semicolon, spaces, deleted embedded $Id$ not + needed with SVN) + - Added to hbextern.ch. + + * source/lang/msguakoi.c + * source/lang/msgua866.c + * Two corrections to internal name. + (borrowed from xhb, work of Pavel Tsarenko.) + ; QUESTION: I wonder why the texts are very much different in + Harbour and xhb. Someone familiar with Ukrainian + language and encodings should check this, only one + of them can be right and all CPs should be synced + with each other the only thing being different is + the encoding. + + * source/codepage/msguakoi.c + ! Fixed one letter. + + * source/codepage/cpuawin.c + * source/codepage/cpua1125.c + * source/codepage/cpua866.c + * source/codepage/cpuakoi.c + * Added "CYRILLIC LETTER GHE WITH UPTURN" letter. + (borrowed from xhb, work of Pavel Tsarenko.) + 2009-07-16 10:02 UTC+0200 Viktor Szakats (harbour.01 syenar.hu) * make_gnu_os2.cmd * make_gnu.bat diff --git a/harbour/include/hbextern.ch b/harbour/include/hbextern.ch index fc6cc6e9de..08df1ffc59 100644 --- a/harbour/include/hbextern.ch +++ b/harbour/include/hbextern.ch @@ -1099,6 +1099,7 @@ EXTERNAL HB_LANG_SRWIN EXTERNAL HB_LANG_TR857 EXTERNAL HB_LANG_TRWIN EXTERNAL HB_LANG_UA866 +EXTERNAL HB_LANG_UADOS EXTERNAL HB_LANG_UAKOI8 EXTERNAL HB_LANG_UAWIN EXTERNAL HB_LANG_ZHB5 diff --git a/harbour/source/codepage/cpua1125.c b/harbour/source/codepage/cpua1125.c index 0dcd32ea63..65e768ce92 100644 --- a/harbour/source/codepage/cpua1125.c +++ b/harbour/source/codepage/cpua1125.c @@ -58,9 +58,9 @@ #include "hbapicdp.h" static HB_CODEPAGE s_codepage = { "UA1125", - HB_CPID_1125, HB_UNITB_1125, 36, - "АБВГДЕЁЇЖЗИЎ°ЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ", - "абвгдеёїжзиў∙йклмнопрстуфхцчшщъыьэюя", + HB_CPID_1125, HB_UNITB_1125, 37, + "АБВГЄДЕЁЇЖЗИЎ°ЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ", + "абвгєдеёїжзиў∙йклмнопрстуфхцчшщъыьэюя", 0,0,0,0,0,NULL,NULL,NULL,NULL,0,NULL }; HB_CODEPAGE_INIT( UA1125 ) diff --git a/harbour/source/codepage/cpua866.c b/harbour/source/codepage/cpua866.c index 5d8762a6b9..f51597c57a 100644 --- a/harbour/source/codepage/cpua866.c +++ b/harbour/source/codepage/cpua866.c @@ -58,9 +58,9 @@ #include "hbapicdp.h" static HB_CODEPAGE s_codepage = { "UA866", - HB_CPID_866,HB_UNITB_866,36, - "АБВГДЕЁЄЖЗИIЇЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ", - "абвгдеёєжзиiїйклмнопрстуфхцчшщъыьэюя", + HB_CPID_866, HB_UNITB_866, 37, + "АБВГГДЕЁЄЖЗИIЇЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ", + "абвггдеёєжзиiїйклмнопрстуфхцчшщъыьэюя", 0,0,0,0,0,NULL,NULL,NULL,NULL,0,NULL }; HB_CODEPAGE_INIT( UA866 ) diff --git a/harbour/source/codepage/cpuakoi.c b/harbour/source/codepage/cpuakoi.c index 9a735a3b22..8b1b8c0a25 100644 --- a/harbour/source/codepage/cpuakoi.c +++ b/harbour/source/codepage/cpuakoi.c @@ -58,9 +58,9 @@ #include "hbapicdp.h" static HB_CODEPAGE s_codepage = { "UAKOI8", - HB_CPID_KOI_8U, HB_UNITB_KOI_8U, 36, - "стўчфх│┤Ў·щ╢╖ъыьэюяЁЄєЇїцшу■√¤ ∙°№рё", - "┴┬╫╟─┼гд╓┌╔жз╩╦╠═╬╧╨╥╙╘╒╞╚├▐█▌▀┘╪▄└╤", + HB_CPID_KOI_8U, HB_UNITB_KOI_8U, 37, + "стўч╜фх│┤Ў·щ╢╖ъыьэюяЁЄєЇїцшу■√¤ ∙°№рё", + "┴┬╫╟н─┼гд╓┌╔жз╩╦╠═╬╧╨╥╙╘╒╞╚├▐█▌▀┘╪▄└╤", 0,0,0,0,0,NULL,NULL,NULL,NULL,0,NULL }; HB_CODEPAGE_INIT( UAKOI8 ) diff --git a/harbour/source/codepage/cpuawin.c b/harbour/source/codepage/cpuawin.c index 5eee555dc1..28a3cca06a 100644 --- a/harbour/source/codepage/cpuawin.c +++ b/harbour/source/codepage/cpuawin.c @@ -58,9 +58,9 @@ #include "hbapicdp.h" static HB_CODEPAGE s_codepage = { "UA1251", - HB_CPID_1251,HB_UNITB_1251,36, - "└┴┬├─┼ик╞╟╚▓п╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀", - "рстуфх╕║цчш│┐щъыьэюяЁёЄєЇїЎў°∙·√№¤■ ", + HB_CPID_1251, HB_UNITB_1251, 37, + "└┴┬├е─┼ик╞╟╚▓п╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀", + "рсту┤фх╕║цчш│┐щъыьэюяЁёЄєЇїЎў°∙·√№¤■ ", 0,0,0,0,0,NULL,NULL,NULL,NULL,0,NULL }; HB_CODEPAGE_INIT( UA1251 ) diff --git a/harbour/source/lang/Makefile b/harbour/source/lang/Makefile index a57b4e2f37..9603e40e03 100644 --- a/harbour/source/lang/Makefile +++ b/harbour/source/lang/Makefile @@ -66,6 +66,7 @@ C_SOURCES=\ msgtrwin.c \ msgsrwin.c \ msgua866.c \ + msguados.c \ msguakoi.c \ msguawin.c \ msgzhb5.c \ diff --git a/harbour/source/lang/msgua866.c b/harbour/source/lang/msgua866.c index a720072c7f..71948ac960 100644 --- a/harbour/source/lang/msgua866.c +++ b/harbour/source/lang/msgua866.c @@ -63,7 +63,7 @@ static HB_LANG s_lang = "UA866", /* ID */ "Ukrainian", /* Name (in English) */ - "Укра∙нська", /* Name (in native language) */ + "Українська", /* Name (in native language) */ "UA", /* RFC ID */ "866", /* Codepage */ "", /* Version */ diff --git a/harbour/source/lang/msguados.c b/harbour/source/lang/msguados.c new file mode 100644 index 0000000000..e526ae7516 --- /dev/null +++ b/harbour/source/lang/msguados.c @@ -0,0 +1,218 @@ +/* + * $Id$ + */ + +/* + * Harbour Project source code: + * Language Support Module (UADOS) + * + * Copyright 2009 Pavel Tsarenko + * www - http://www.xharbour.org + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this software; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place, Suite 330, + * Boston, MA 02111-1307 USA (or visit the web site http://www.gnu.org/). + * + * As a special exception, the Harbour Project gives permission for + * additional uses of the text contained in its release of Harbour. + * + * The exception is that, if you link the Harbour libraries with other + * files to produce an executable, this does not by itself cause the + * resulting executable to be covered by the GNU General Public License. + * Your use of that executable is in no way restricted on account of + * linking the Harbour library code into it. + * + * This exception does not however invalidate any other reasons why + * the executable file might be covered by the GNU General Public License. + * + * This exception applies only to the code released by the Harbour + * Project under the name Harbour. If you copy code from other + * Harbour Project or Free Software Foundation releases into a copy of + * Harbour, as the General Public License permits, the exception does + * not apply to the code that you add in this way. To avoid misleading + * anyone as to the status of such modified files, you must delete + * this exception notice from them. + * + * If you write modifications of your own for Harbour, it is your choice + * whether to permit this exception to apply to your modifications. + * If you do not wish that, delete this exception notice. + * + */ + +/* Language name: Ukrainian */ +/* ISO language code (2 chars): UA */ +/* Codepage: 1125 */ + +#include "hbapilng.h" + +static HB_LANG s_lang = +{ + { + /* Identification */ + + "UADOS", /* ID */ + "Ukrainian", /* Name (in English) */ + "Укра∙нська", /* Name (in native language) */ + "UA", /* RFC ID */ + "1125", /* Codepage */ + "", /* Version */ + + /* Month names */ + + "Сўчень", + "Лютий", + "Березень", + "Квўтень", + "Травень", + "Червень", + "Лютий", + "Серпень", + "Вересень", + "Жовтень", + "Листопад", + "Грудень", + + /* Day names */ + + "Недўля", + "Понедўлок", + "Вўвторок", + "Середа", + "Четвер", + "П'ятниця", + "Субота", + + /* CA-Cl*pper compatible natmsg items */ + + "Файли даних # Записи Остання зм. Розмўр", + "Потрўбнў ще приклади ?", + "Стор.N", + "** Subtotal **", + "* Subsubtotal *", + "*** Total ***", + "Ins", + " ", + "Невўрна дата", + "Диапазон: ", + " - ", + "Д/Н", + "НЕВЎРНЕ ВИРАЖЕННЯ", + + /* Error description names */ + + "Невўдома помилка", + "Невўрний аргумент", + "Переповнення масива", + "Переповнення строки", + "Переповнення числа", + "Дўлення на нуль", + "Числова помилка", + "Синтаксична помилка", + "Дуже складна операцўя", + "", + "", + "Не вистачаї пам'ятў", + "Невўдома функцўя", + "Метод не експортован", + "Змўнна не ўснуї", + "Алиас не ўснуї", + "Змўнна не експортована", + "Недопустимў символи у ўменў алиаса", + "Алиас вже використовуїться", + "", + "Помилка створення", + "Помилка вўдкриття", + "Помилка закриття", + "Помилка читання", + "Помилка записи", + "Помилка друку", + "", + "", + "", + "", + "Операцўя не пўдтримуїться", + "Лўмўт перевищен", + "Виявлено ушкодження", + "Помилка типа даних", + "Помилка розмўру даних", + "Файл не вўдкрит", + "Файл не ўндексован", + "Потрўбен ексклюзивний доступ", + "Потрўбна блокировка", + "Запис не дозволен", + "Сбой блокування при доданнў", + "Блокування не вдалося", + "", + "", + "", + "", + "Невўрна кўлькўсть аргументўв", + "Доступ до масива", + "присвоювання масива", + "не масив", + "порўвняння", + + /* Internal error names */ + + "Невиправна помилка %lu: ", + "Помилка при вўдновленнў", + "Не визначен ERRORBLOCK() для помилки", + "Перевищена межа рекурсивних визовўв обробника помилок", + "Не вдаїтся завантажити RDD", + "Невўрний тип метода %s", + "hb_xgrab не може розподўлити пам'ять", + "hb_xrealloc викликан з NULL вказўвником", + "hb_xrealloc викликан с невўрним вказўвником", + "hb_xrealloc не може перерозподўлити пам'ять", + "hb_xfree викликан с невўрним вказўвником", + "hb_xfree викликан з NULL вказўвником", + "Не знайдена стартова процедура: \'%s\'", + "Вўдсутня стартова процедура", + "VM: Невўдомий код", + "%s: очўкувався символ", + "%s: невўрний тип символа для self", + "%s: очўкувався блок коду", + "%s: невўрний тип елемента на вершинў стека", + "Вихўд за межў стека", + "%s: спроба копировати элемент на себе", + "%s: невўрне им'я змўнно∙", + "Переповнення буфера пам'ятў", + "hb_xgrab requested to allocate zero bytes", + "hb_xrealloc requested to resize to zero bytes", + "hb_xalloc requested to allocate zero bytes", + + /* Texts */ + + "DD.MM.YYYY", + "Д", + "Н" + } +}; + +HB_LANG_ANNOUNCE( UADOS ) + +HB_CALL_ON_STARTUP_BEGIN( hb_lang_Init_UADOS ) + hb_langRegister( &s_lang ); +HB_CALL_ON_STARTUP_END( hb_lang_Init_UADOS ) + +#if defined( HB_PRAGMA_STARTUP ) + #pragma startup hb_lang_Init_UADOS +#elif defined( HB_MSC_STARTUP ) + #if defined( HB_OS_WIN_64 ) + #pragma section( HB_MSC_START_SEGMENT, long, read ) + #endif + #pragma data_seg( HB_MSC_START_SEGMENT ) + static HB_$INITSYM hb_vm_auto_hb_lang_Init_UADOS = hb_lang_Init_UADOS; + #pragma data_seg() +#endif diff --git a/harbour/source/lang/msguakoi.c b/harbour/source/lang/msguakoi.c index 23bdcf6e68..c77128ee3a 100644 --- a/harbour/source/lang/msguakoi.c +++ b/harbour/source/lang/msguakoi.c @@ -63,7 +63,7 @@ static HB_LANG s_lang = "UAKOI8", /* ID */ "Ukrainian", /* Name (in English) */ - "ї╦╥┴з╬╙╪╦┴", /* Name (in native language) */ + "ї╦╥┴д╬╙╪╦┴", /* Name (in native language) */ "UA", /* RFC ID */ "KOI8U", /* Codepage */ "", /* Version */ @@ -90,7 +90,7 @@ static HB_LANG s_lang = "ўж╫╘╧╥╧╦", "є┼╥┼─┴", "■┼╘╫┼╥", - "Ё?╤╘╬╔├╤", + "Ё'╤╘╬╔├╤", "є╒┬╧╘┴", /* CA-Cl*pper compatible natmsg items */ @@ -122,7 +122,7 @@ static HB_LANG s_lang = "ю┴─═ж╥╬╧ ╙╦╠┴─╬┴ ╧╨┼╥┴├ж╤", "", "", - "т╥┴╦╒д ╨┴═?╤╘ж", + "т╥┴╦╒д ╨┴═'╤╘ж", "ю┼╫ж─╧═┴ ╞╒╬╦├ж╤", "э┼╘╧─ ╬┼ ┼╦╙╨╧╥╘╧╫┴╬╔╩", "·═ж╬╬┴ ╬┼ ж╙╬╒д", @@ -171,10 +171,10 @@ static HB_LANG s_lang = "Ё┼╥┼╫╔▌┼╬┴ ═┼╓┴ ╥┼╦╒╥╙╔╫╬╔╚ ╫╔╦╠╔╦ж╫ ╧┬╥╧┬╬╔╦┴ ╨╧═╔╠╧╦", "ю┼ ╫─┴д╘╪╙╤ ┌┴╫┴╬╘┴╓╔╘╔ RDD", "Ё╧═╔╠╦╧╫╔╩ ╘╔╨ ═┼╘╧─╒ %s", - "hb_xgrab ╬┼ ═╧╓┼ ╥╧┌╨╧─ж╠╔╘╔ ╨┴═?╤╘╪", + "hb_xgrab ╬┼ ═╧╓┼ ╥╧┌╨╧─ж╠╔╘╔ ╨┴═'╤╘╪", "hb_xrealloc ╫╔╦╠╔╦┴╬╧ ┌ NULL ╨╧╦┴╓▐╔╦╧═", "hb_xrealloc ╫╔╦╠╔╦┴╬╧ ┌ ╨╧═╔╠╦╧╫╔═ ╨╧╦┴╓▐╔╦╧═", - "hb_xrealloc ╬┼ ═╧╓┼ ╨┼╥┼╥╧┌╨╧─ж╠╔╘╔ ╨┴═?╤╘╪", + "hb_xrealloc ╬┼ ═╧╓┼ ╨┼╥┼╥╧┌╨╧─ж╠╔╘╔ ╨┴═'╤╘╪", "hb_xfree ╫╔╦╠╔╦┴╬╧ ┌ ╨╧═╔╠╦╧╫╔═ ╨╧╦┴╓▐╔╦╧═", "hb_xfree ╫╔╦╠╔╦┴╬╧ ┌ NULL ╨╧╦┴╓▐╔╦╧═", "ю┼ ┌╬┴╩─┼╬┴ ╙╘┴╥╘╧╫┴ ╨╥╧├┼─╒╥┴: \'%s\'", @@ -186,8 +186,8 @@ static HB_LANG s_lang = "%s: ╨╧═╔╠╦╧╫╔╩ ╘╔╨ ┼╠┼═┼╬╘╒ ╬┴ ╫┼╥█╔╬ж ╙╘┼╦╒", "ў╔╚ж─ ┌┴ ═┼╓ж ╙╘┼╦╒", "%s: ╙╨╥╧┬┴ ╦╧╨ж└╫┴╘╔ ┼╠┼═┼╬╘ ╬┴ ╙┼┬┼ ╓", - "%s: ╨╧═╔╠╦╧╫┼ ж═?╤ ┌═ж╬╬╧з", - "Ё┼╥┼╨╧╫╬┼╬╬╤ ┬╒╞┼╥╒ ╨┴═?╤╘ж", + "%s: ╨╧═╔╠╦╧╫┼ ж═'╤ ┌═ж╬╬╧з", + "Ё┼╥┼╨╧╫╬┼╬╬╤ ┬╒╞┼╥╒ ╨┴═'╤╘ж", "hb_xgrab requested to allocate zero bytes", "hb_xrealloc requested to resize to zero bytes", "hb_xalloc requested to allocate zero bytes",