Compare commits
140 Commits
ver/2.0-be
...
ver/2.0
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f65634e285 | ||
|
|
62a67b6be7 | ||
|
|
5304402ec5 | ||
|
|
f14fa2911d | ||
|
|
db391d7023 | ||
|
|
0b5a6a7016 | ||
|
|
5cc72a6a96 | ||
|
|
4138f6a5a3 | ||
|
|
2b2b2656b3 | ||
|
|
6253f2c267 | ||
|
|
c9779c3772 | ||
|
|
f6019e361c | ||
|
|
3fd0aef27d | ||
|
|
49c9d33b97 | ||
|
|
b01d1c5409 | ||
|
|
b0b434fec2 | ||
|
|
d46557a367 | ||
|
|
0180cb6306 | ||
|
|
4ce3213b1a | ||
|
|
75b2758797 | ||
|
|
2e14bcf1ec | ||
|
|
cf49e3e401 | ||
|
|
0ed0cf8c49 | ||
|
|
38a77ca51b | ||
|
|
891bd624fc | ||
|
|
affe7b06a2 | ||
|
|
f51c4dbbec | ||
|
|
650ad13a30 | ||
|
|
f53779dbad | ||
|
|
a45115d5e7 | ||
|
|
b5ba1290f9 | ||
|
|
52689653d0 | ||
|
|
8d9af61d5e | ||
|
|
5f339d0d51 | ||
|
|
641d178248 | ||
|
|
67d3c6f3ac | ||
|
|
060ed729b3 | ||
|
|
f8eead6835 | ||
|
|
15693f643f | ||
|
|
916b466909 | ||
|
|
a112a46755 | ||
|
|
fba2181b32 | ||
|
|
d9bf31897e | ||
|
|
65b92f017b | ||
|
|
dddc2d5794 | ||
|
|
e4e8609a00 | ||
|
|
cee1ea7dbc | ||
|
|
87c41451ab | ||
|
|
ecefcecfd8 | ||
|
|
ba8254c097 | ||
|
|
dacca1409e | ||
|
|
8a3a539d5b | ||
|
|
bb2e5e256b | ||
|
|
6828887308 | ||
|
|
186bc61723 | ||
|
|
19a9d9c26d | ||
|
|
cca084be7d | ||
|
|
6710e0a21c | ||
|
|
b5cc0b8f2c | ||
|
|
ded987e4f8 | ||
|
|
957d530801 | ||
|
|
4c716f2ba3 | ||
|
|
7e3cf0bce7 | ||
|
|
7f97a20ba0 | ||
|
|
4b4bc1b371 | ||
|
|
f0b573f1a8 | ||
|
|
c2887f77b0 | ||
|
|
f056a4b0ec | ||
|
|
181778c981 | ||
|
|
ffb887b306 | ||
|
|
515a994ece | ||
|
|
ab28678227 | ||
|
|
b90ff2977f | ||
|
|
eab7bcb35f | ||
|
|
a7c6f2967f | ||
|
|
2316e5906c | ||
|
|
1866ace76f | ||
|
|
48d97742b1 | ||
|
|
96bde4740f | ||
|
|
333a415a66 | ||
|
|
26e81ac0a0 | ||
|
|
2b610e2804 | ||
|
|
ea4f85223c | ||
|
|
aff96d1efe | ||
|
|
f5eaf3c74b | ||
|
|
6e167b7344 | ||
|
|
acaae141de | ||
|
|
4a32a4b40c | ||
|
|
902fcf92a4 | ||
|
|
424a6762f7 | ||
|
|
41aa04abad | ||
|
|
8ae98bfb12 | ||
|
|
41dfe0c892 | ||
|
|
5cd454a757 | ||
|
|
a75b649f8b | ||
|
|
174f117770 | ||
|
|
19d1daf099 | ||
|
|
c4fe7c4370 | ||
|
|
7a7135ea81 | ||
|
|
2d97afded3 | ||
|
|
01e8ca5338 | ||
|
|
02f69e332c | ||
|
|
5ce2d209d2 | ||
|
|
088abe062b | ||
|
|
f264fdb211 | ||
|
|
0e9c6ab66e | ||
|
|
040109c36f | ||
|
|
d130888753 | ||
|
|
e81b0f772d | ||
|
|
750cab5370 | ||
|
|
213425fd11 | ||
|
|
689c72e7e7 | ||
|
|
fbd60a53dc | ||
|
|
e3475ef48d | ||
|
|
86d512e752 | ||
|
|
665b6c3564 | ||
|
|
173d9c77af | ||
|
|
a6088c3028 | ||
|
|
ff0354474e | ||
|
|
33f0cbea0d | ||
|
|
c39aa9f97e | ||
|
|
45530b23f3 | ||
|
|
cb17f06927 | ||
|
|
ac3b44de2b | ||
|
|
c839d5f50d | ||
|
|
22be76bec5 | ||
|
|
e5b246a4f0 | ||
|
|
3f64aef58d | ||
|
|
2dc6b2d4f5 | ||
|
|
c938320c45 | ||
|
|
d7968f539c | ||
|
|
beabeb17aa | ||
|
|
155f12f44e | ||
|
|
d46a1d4041 | ||
|
|
c195a07982 | ||
|
|
6c82b6333f | ||
|
|
1178406aa9 | ||
|
|
1e09407742 | ||
|
|
a7b5e1a573 | ||
|
|
d70b72b0c1 |
27
.gitmodules
vendored
@@ -1,21 +1,24 @@
|
||||
[submodule "lib/wxExtend"]
|
||||
path = lib/wxExtend
|
||||
url = https://github.com/Amebis/wxExtend.git
|
||||
[submodule "lib/stdex"]
|
||||
path = lib/stdex
|
||||
url = https://github.com/Amebis/stdex.git
|
||||
[submodule "MSI/MSIBuild"]
|
||||
path = MSI/MSIBuild
|
||||
url = https://github.com/Amebis/MSIBuild.git
|
||||
[submodule "MSI/MSICA"]
|
||||
path = MSI/MSICA
|
||||
url = https://github.com/Amebis/MSICA.git
|
||||
[submodule "lib/atlex"]
|
||||
path = lib/atlex
|
||||
url = https://github.com/Amebis/atlex.git
|
||||
[submodule "lib/MSICALib"]
|
||||
path = lib/MSICALib
|
||||
url = https://github.com/Amebis/MSICALib.git
|
||||
[submodule "lib/stdex"]
|
||||
path = lib/stdex
|
||||
url = https://github.com/Amebis/stdex.git
|
||||
[submodule "lib/WinStd"]
|
||||
path = lib/WinStd
|
||||
url = https://github.com/Amebis/WinStd.git
|
||||
[submodule "lib/wxExtend"]
|
||||
path = lib/wxExtend
|
||||
url = https://github.com/Amebis/wxExtend.git
|
||||
[submodule "MSI/MSIBuild"]
|
||||
path = MSI/MSIBuild
|
||||
url = https://github.com/Amebis/MSIBuild.git
|
||||
[submodule "MSI/MSICA"]
|
||||
path = MSI/MSICA
|
||||
url = https://github.com/Amebis/MSICA.git
|
||||
[submodule "Updater"]
|
||||
path = Updater
|
||||
url = https://github.com/Amebis/Updater.git
|
||||
|
||||
BIN
MSI/ZRCola/Main/Binary/fontsubst.bmp
Normal file
|
After Width: | Height: | Size: 23 KiB |
BIN
MSI/ZRCola/Main/Binary/fontsubst.png
Normal file
|
After Width: | Height: | Size: 51 KiB |
BIN
MSI/ZRCola/Main/Icon/PDF.ico
Normal file
|
After Width: | Height: | Size: 23 KiB |
BIN
MSILocal.mak
Normal file
440
Makefile
@@ -36,16 +36,6 @@ Clean ::
|
||||
cd "MSI\MSIBuild\Version"
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) Clean
|
||||
cd "$(MAKEDIR)"
|
||||
cd "MSI\ZRCola"
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) Clean LANG=En PLAT=Win32 CFG=Release
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) Clean LANG=En PLAT=Win32 CFG=Debug
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) Clean LANG=En PLAT=x64 CFG=Release
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) Clean LANG=En PLAT=x64 CFG=Debug
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) Clean LANG=Sl PLAT=Win32 CFG=Release
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) Clean LANG=Sl PLAT=Win32 CFG=Debug
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) Clean LANG=Sl PLAT=x64 CFG=Release
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) Clean LANG=Sl PLAT=x64 CFG=Debug
|
||||
cd "$(MAKEDIR)"
|
||||
devenv.com "ZRCola.sln" /clean "Release|Win32"
|
||||
devenv.com "ZRCola.sln" /clean "Debug|Win32"
|
||||
devenv.com "ZRCola.sln" /clean "Release|x64"
|
||||
@@ -60,15 +50,29 @@ Clean ::
|
||||
devenv.com "Updater\Updater.sln" /clean "Debug|Win32"
|
||||
devenv.com "Updater\Updater.sln" /clean "Release|x64"
|
||||
devenv.com "Updater\Updater.sln" /clean "Debug|x64"
|
||||
-if exist "$(OUTPUT_DIR)\Setup\ZRColaEn32.msi" del /f /q "$(OUTPUT_DIR)\Setup\ZRColaEn32.msi"
|
||||
-if exist "$(OUTPUT_DIR)\Setup\ZRColaEn32D.msi" del /f /q "$(OUTPUT_DIR)\Setup\ZRColaEn32D.msi"
|
||||
-if exist "$(OUTPUT_DIR)\Setup\ZRColaEn64.msi" del /f /q "$(OUTPUT_DIR)\Setup\ZRColaEn64.msi"
|
||||
-if exist "$(OUTPUT_DIR)\Setup\ZRColaEn64D.msi" del /f /q "$(OUTPUT_DIR)\Setup\ZRColaEn64D.msi"
|
||||
-if exist "$(OUTPUT_DIR)\Setup\ZRColaSl32.msi" del /f /q "$(OUTPUT_DIR)\Setup\ZRColaSl32.msi"
|
||||
-if exist "$(OUTPUT_DIR)\Setup\ZRColaSl32D.msi" del /f /q "$(OUTPUT_DIR)\Setup\ZRColaSl32D.msi"
|
||||
-if exist "$(OUTPUT_DIR)\Setup\ZRColaSl64.msi" del /f /q "$(OUTPUT_DIR)\Setup\ZRColaSl64.msi"
|
||||
-if exist "$(OUTPUT_DIR)\Setup\ZRColaSl64D.msi" del /f /q "$(OUTPUT_DIR)\Setup\ZRColaSl64D.msi"
|
||||
-if exist "$(OUTPUT_DIR)\catalog.xml" del /f /q "$(OUTPUT_DIR)\catalog.xml"
|
||||
-if exist "$(OUTPUT_DIR)\locale\de_DE\wxstd.mo" del /f /q "$(OUTPUT_DIR)\locale\de_DE\wxstd.mo"
|
||||
-if exist "$(OUTPUT_DIR)\locale\ru_RU\wxstd.mo" del /f /q "$(OUTPUT_DIR)\locale\ru_RU\wxstd.mo"
|
||||
-if exist "$(OUTPUT_DIR)\locale\sl_SI\wxstd.mo" del /f /q "$(OUTPUT_DIR)\locale\sl_SI\wxstd.mo"
|
||||
-if exist "$(OUTPUT_DIR)\locale\de_DE\ZRCola-zrcdb.mo" del /f /q "$(OUTPUT_DIR)\locale\de_DE\ZRCola-zrcdb.mo"
|
||||
-if exist "$(OUTPUT_DIR)\locale\ru_RU\ZRCola-zrcdb.mo" del /f /q "$(OUTPUT_DIR)\locale\ru_RU\ZRCola-zrcdb.mo"
|
||||
-if exist "$(OUTPUT_DIR)\locale\sl_SI\ZRCola-zrcdb.mo" del /f /q "$(OUTPUT_DIR)\locale\sl_SI\ZRCola-zrcdb.mo"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola32.ddf" del /f /q "$(OUTPUT_DIR)\ZRCola32.ddf"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola32D.ddf" del /f /q "$(OUTPUT_DIR)\ZRCola32D.ddf"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola64.ddf" del /f /q "$(OUTPUT_DIR)\ZRCola64.ddf"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola64D.ddf" del /f /q "$(OUTPUT_DIR)\ZRCola64D.ddf"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola32.cab" del /f /q "$(OUTPUT_DIR)\ZRCola32.cab"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola32.inf" del /f /q "$(OUTPUT_DIR)\ZRCola32.inf"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola32.rpt" del /f /q "$(OUTPUT_DIR)\ZRCola32.rpt"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola32D.cab" del /f /q "$(OUTPUT_DIR)\ZRCola32D.cab"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola32D.inf" del /f /q "$(OUTPUT_DIR)\ZRCola32D.inf"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola32D.rpt" del /f /q "$(OUTPUT_DIR)\ZRCola32D.rpt"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola64.cab" del /f /q "$(OUTPUT_DIR)\ZRCola64.cab"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola64.inf" del /f /q "$(OUTPUT_DIR)\ZRCola64.inf"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola64.rpt" del /f /q "$(OUTPUT_DIR)\ZRCola64.rpt"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola64D.cab" del /f /q "$(OUTPUT_DIR)\ZRCola64D.cab"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola64D.inf" del /f /q "$(OUTPUT_DIR)\ZRCola64D.inf"
|
||||
-if exist "$(OUTPUT_DIR)\ZRCola64D.rpt" del /f /q "$(OUTPUT_DIR)\ZRCola64D.rpt"
|
||||
-if exist "$(OUTPUT_DIR)\catalog.xml" del /f /q "$(OUTPUT_DIR)\catalog.xml"
|
||||
|
||||
!IFNDEF HAS_VERSION
|
||||
|
||||
@@ -82,6 +86,7 @@ Setup \
|
||||
SetupDebug \
|
||||
Register \
|
||||
Unregister \
|
||||
Localization \
|
||||
PublishPre \
|
||||
Publish :: "MSI\MSIBuild\Version\Version.mak"
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) HAS_VERSION=1 $@
|
||||
@@ -104,12 +109,6 @@ Publish :: "MSI\MSIBuild\Version\Version.mak"
|
||||
PUBLISH_PACKAGE_DIR=$(PUBLISH_DIR)\$(MSIBUILD_VERSION_STR)
|
||||
PUBLISH_PACKAGE_URL=http://www.amebis.si/prenos/ZRCola/$(MSIBUILD_VERSION_STR)
|
||||
|
||||
REDIST_EN_WIN32="$(PUBLISH_PACKAGE_DIR)\ZRColaEn32.msi"
|
||||
REDIST_EN_X64="$(PUBLISH_PACKAGE_DIR)\ZRColaEn64.msi"
|
||||
REDIST_SL_WIN32="$(PUBLISH_PACKAGE_DIR)\ZRColaSl32.msi"
|
||||
REDIST_SL_X64="$(PUBLISH_PACKAGE_DIR)\ZRColaSl64.msi"
|
||||
|
||||
|
||||
######################################################################
|
||||
# Main targets
|
||||
######################################################################
|
||||
@@ -118,18 +117,54 @@ All :: \
|
||||
Setup
|
||||
|
||||
Setup :: \
|
||||
"$(OUTPUT_DIR)\Setup" \
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaEn32.msi" \
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaEn64.msi" \
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaSl32.msi" \
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaSl64.msi"
|
||||
# "$(OUTPUT_DIR)\ZRColaDe32.msi" \
|
||||
# "$(OUTPUT_DIR)\ZRColaDe64.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaEn32.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaEn64.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaRu32.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaRu64.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl32.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl64.msi"
|
||||
|
||||
SetupDebug :: \
|
||||
"$(OUTPUT_DIR)\Setup" \
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaEn32D.msi" \
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaEn64D.msi" \
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaSl32D.msi" \
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaSl64D.msi"
|
||||
# "$(OUTPUT_DIR)\ZRColaDe32D.msi" \
|
||||
# "$(OUTPUT_DIR)\ZRColaDe64D.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaEn32D.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaEn64D.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaRu32D.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaRu64D.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl32D.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl64D.msi"
|
||||
|
||||
|
||||
######################################################################
|
||||
# Publishing
|
||||
######################################################################
|
||||
|
||||
PublishPre :: \
|
||||
"$(PUBLISH_PACKAGE_DIR)" \
|
||||
# "$(PUBLISH_PACKAGE_DIR)\ZRColaDe32.msi" \
|
||||
# "$(PUBLISH_PACKAGE_DIR)\ZRColaDe64.msi" \
|
||||
"$(PUBLISH_PACKAGE_DIR)\ZRColaEn32.msi" \
|
||||
"$(PUBLISH_PACKAGE_DIR)\ZRColaEn64.msi" \
|
||||
"$(PUBLISH_PACKAGE_DIR)\ZRColaRu32.msi" \
|
||||
"$(PUBLISH_PACKAGE_DIR)\ZRColaRu64.msi" \
|
||||
"$(PUBLISH_PACKAGE_DIR)\ZRColaSl32.msi" \
|
||||
"$(PUBLISH_PACKAGE_DIR)\ZRColaSl64.msi" \
|
||||
"$(PUBLISH_DIR)" \
|
||||
# "$(PUBLISH_DIR)\ZRColaInstallDe.exe" \
|
||||
"$(PUBLISH_DIR)\ZRColaInstallEn.exe" \
|
||||
"$(PUBLISH_DIR)\ZRColaInstallRu.exe" \
|
||||
"$(PUBLISH_DIR)\ZRColaInstallSl.exe"
|
||||
|
||||
Publish :: \
|
||||
PublishPre \
|
||||
"$(PUBLISH_DIR)\catalog-0000.xml"
|
||||
|
||||
|
||||
######################################################################
|
||||
# Registration
|
||||
######################################################################
|
||||
|
||||
Register :: \
|
||||
RegisterSettings \
|
||||
@@ -158,24 +193,26 @@ UnregisterSettings ::
|
||||
!ENDIF
|
||||
|
||||
InstallFonts :: \
|
||||
"$(WINDIR)\Fonts\00_ZRCola_Re.ttf" \
|
||||
"$(WINDIR)\Fonts\00_ZRCola_It.ttf" \
|
||||
"$(WINDIR)\Fonts\00_ZRCola_Bd.ttf" \
|
||||
"$(WINDIR)\Fonts\00_ZRCola_BI.ttf"
|
||||
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "00 ZRCola (TrueType)" /t REG_SZ /d "00_ZRCola_Re.ttf" $(REG_FLAGS) > NUL
|
||||
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "00 ZRCola Italic (TrueType)" /t REG_SZ /d "00_ZRCola_It.ttf" $(REG_FLAGS) > NUL
|
||||
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "00 ZRCola Bold (TrueType)" /t REG_SZ /d "00_ZRCola_Bd.ttf" $(REG_FLAGS) > NUL
|
||||
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "00 ZRCola Bold Italic (TrueType)" /t REG_SZ /d "00_ZRCola_BI.ttf" $(REG_FLAGS) > NUL
|
||||
"$(WINDIR)\Fonts\ZRCola_Re.otf" \
|
||||
"$(WINDIR)\Fonts\ZRCola_It.otf" \
|
||||
"$(WINDIR)\Fonts\ZRCola_Bd.otf" \
|
||||
"$(WINDIR)\Fonts\ZRCola_BI.otf"
|
||||
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "ZRCola (TrueType)" /t REG_SZ /d "ZRCola_Re.otf" $(REG_FLAGS) > NUL
|
||||
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "ZRCola Italic (TrueType)" /t REG_SZ /d "ZRCola_It.otf" $(REG_FLAGS) > NUL
|
||||
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "ZRCola Bold (TrueType)" /t REG_SZ /d "ZRCola_Bd.otf" $(REG_FLAGS) > NUL
|
||||
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "ZRCola Bold Italic (TrueType)" /t REG_SZ /d "ZRCola_BI.otf" $(REG_FLAGS) > NUL
|
||||
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\FontSubstitutes" /v "00 ZRCola" /t REG_SZ /d "ZRCola" $(REG_FLAGS) > NUL
|
||||
|
||||
UninstallFonts::
|
||||
-reg.exe delete "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "00 ZRCola (TrueType)" $(REG_FLAGS) > NUL
|
||||
-reg.exe delete "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "00 ZRCola Italic (TrueType)" $(REG_FLAGS) > NUL
|
||||
-reg.exe delete "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "00 ZRCola Bold (TrueType)" $(REG_FLAGS) > NUL
|
||||
-reg.exe delete "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "00 ZRCola Bold Italic (TrueType)" $(REG_FLAGS) > NUL
|
||||
-if exist "$(WINDIR)\Fonts\00_ZRCola_Re.ttf" rd /s /q "$(WINDIR)\Fonts\00_ZRCola_Re.ttf"
|
||||
-if exist "$(WINDIR)\Fonts\00_ZRCola_It.ttf" rd /s /q "$(WINDIR)\Fonts\00_ZRCola_It.ttf"
|
||||
-if exist "$(WINDIR)\Fonts\00_ZRCola_Bd.ttf" rd /s /q "$(WINDIR)\Fonts\00_ZRCola_Bd.ttf"
|
||||
-if exist "$(WINDIR)\Fonts\00_ZRCola_BI.ttf" rd /s /q "$(WINDIR)\Fonts\00_ZRCola_BI.ttf"
|
||||
-reg.exe delete "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "ZRCola (TrueType)" $(REG_FLAGS) > NUL
|
||||
-reg.exe delete "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "ZRCola Italic (TrueType)" $(REG_FLAGS) > NUL
|
||||
-reg.exe delete "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "ZRCola Bold (TrueType)" $(REG_FLAGS) > NUL
|
||||
-reg.exe delete "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "ZRCola Bold Italic (TrueType)" $(REG_FLAGS) > NUL
|
||||
-reg.exe delete "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\FontSubstitutes" /v "00 ZRCola" $(REG_FLAGS) > NUL
|
||||
-if exist "$(WINDIR)\Fonts\ZRCola_Re.otf" rd /s /q "$(WINDIR)\Fonts\ZRCola_Re.otf"
|
||||
-if exist "$(WINDIR)\Fonts\ZRCola_It.otf" rd /s /q "$(WINDIR)\Fonts\ZRCola_It.otf"
|
||||
-if exist "$(WINDIR)\Fonts\ZRCola_Bd.otf" rd /s /q "$(WINDIR)\Fonts\ZRCola_Bd.otf"
|
||||
-if exist "$(WINDIR)\Fonts\ZRCola_BI.otf" rd /s /q "$(WINDIR)\Fonts\ZRCola_BI.otf"
|
||||
|
||||
RegisterShortcuts :: \
|
||||
"$(PROGRAMDATA)\Microsoft\Windows\Start Menu\Programs\ZRCola" \
|
||||
@@ -184,21 +221,20 @@ RegisterShortcuts :: \
|
||||
UnregisterShortcuts ::
|
||||
-if exist "$(PROGRAMDATA)\Microsoft\Windows\Start Menu\Programs\ZRCola" rd /s /q "$(PROGRAMDATA)\Microsoft\Windows\Start Menu\Programs\ZRCola"
|
||||
|
||||
PublishPre :: \
|
||||
"$(PUBLISH_PACKAGE_DIR)" \
|
||||
$(REDIST_EN_WIN32) \
|
||||
$(REDIST_EN_X64) \
|
||||
$(REDIST_SL_WIN32) \
|
||||
$(REDIST_SL_X64) \
|
||||
"$(PUBLISH_DIR)" \
|
||||
"$(PUBLISH_DIR)\ZRColaInstallDe.exe" \
|
||||
"$(PUBLISH_DIR)\ZRColaInstallEn.exe" \
|
||||
"$(PUBLISH_DIR)\ZRColaInstallRu.exe" \
|
||||
"$(PUBLISH_DIR)\ZRColaInstallSl.exe"
|
||||
######################################################################
|
||||
# Localization
|
||||
######################################################################
|
||||
|
||||
Publish :: \
|
||||
PublishPre \
|
||||
"$(PUBLISH_DIR)\catalog-0000.xml"
|
||||
Localization :: \
|
||||
"$(OUTPUT_DIR)\locale\de_DE" \
|
||||
"$(OUTPUT_DIR)\locale\de_DE\wxstd.mo" \
|
||||
"$(OUTPUT_DIR)\locale\de_DE\ZRCola-zrcdb.mo" \
|
||||
"$(OUTPUT_DIR)\locale\ru_RU" \
|
||||
"$(OUTPUT_DIR)\locale\ru_RU\wxstd.mo" \
|
||||
"$(OUTPUT_DIR)\locale\ru_RU\ZRCola-zrcdb.mo" \
|
||||
"$(OUTPUT_DIR)\locale\sl_SI" \
|
||||
"$(OUTPUT_DIR)\locale\sl_SI\wxstd.mo" \
|
||||
"$(OUTPUT_DIR)\locale\sl_SI\ZRCola-zrcdb.mo"
|
||||
|
||||
|
||||
######################################################################
|
||||
@@ -207,14 +243,21 @@ Publish :: \
|
||||
|
||||
"$(OUTPUT_DIR)" \
|
||||
"$(OUTPUT_DIR)\Keys" \
|
||||
"$(OUTPUT_DIR)\Setup" \
|
||||
"$(OUTPUT_DIR)\locale" \
|
||||
"$(OUTPUT_DIR)\locale\de_DE" \
|
||||
"$(OUTPUT_DIR)\locale\ru_RU" \
|
||||
"$(OUTPUT_DIR)\locale\sl_SI" \
|
||||
"$(PUBLISH_DIR)" \
|
||||
"$(PUBLISH_PACKAGE_DIR)" \
|
||||
"$(PROGRAMDATA)\Microsoft\Windows\Start Menu\Programs\ZRCola" :
|
||||
if not exist $@ md $@
|
||||
|
||||
"$(OUTPUT_DIR)\Keys" \
|
||||
"$(OUTPUT_DIR)\Setup" : "$(OUTPUT_DIR)"
|
||||
"$(OUTPUT_DIR)\locale" : "$(OUTPUT_DIR)"
|
||||
|
||||
"$(OUTPUT_DIR)\locale\de_DE" \
|
||||
"$(OUTPUT_DIR)\locale\ru_RU" \
|
||||
"$(OUTPUT_DIR)\locale\sl_SI" : "$(OUTPUT_DIR)\locale"
|
||||
|
||||
"$(PUBLISH_PACKAGE_DIR)" : "$(PUBLISH_DIR)"
|
||||
|
||||
@@ -223,56 +266,16 @@ Publish :: \
|
||||
# File copy
|
||||
######################################################################
|
||||
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaEn32.msi" \
|
||||
$(REDIST_EN_WIN32) : "$(OUTPUT_DIR)\ZRColaEn32.3.msi"
|
||||
"$(WINDIR)\Fonts\ZRCola_Re.otf" : "$(OUTPUT_DIR)\ZRCola_Re.otf"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaEn32D.msi" : "$(OUTPUT_DIR)\ZRColaEn32D.3.msi"
|
||||
"$(WINDIR)\Fonts\ZRCola_It.otf" : "$(OUTPUT_DIR)\ZRCola_It.otf"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaEn64.msi" \
|
||||
$(REDIST_EN_X64) : "$(OUTPUT_DIR)\ZRColaEn64.3.msi"
|
||||
"$(WINDIR)\Fonts\ZRCola_Bd.otf" : "$(OUTPUT_DIR)\ZRCola_Bd.otf"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaEn64D.msi" : "$(OUTPUT_DIR)\ZRColaEn64D.3.msi"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaSl32.msi" \
|
||||
$(REDIST_SL_WIN32) : "$(OUTPUT_DIR)\ZRColaSl32.3.msi"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaSl32D.msi" : "$(OUTPUT_DIR)\ZRColaSl32D.3.msi"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaSl64.msi" \
|
||||
$(REDIST_SL_X64) : "$(OUTPUT_DIR)\ZRColaSl64.3.msi"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(OUTPUT_DIR)\Setup\ZRColaSl64D.msi" : "$(OUTPUT_DIR)\ZRColaSl64D.3.msi"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(WINDIR)\Fonts\00_ZRCola_Re.ttf" : "$(OUTPUT_DIR)\00_ZRCola_Re.ttf"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(WINDIR)\Fonts\00_ZRCola_It.ttf" : "$(OUTPUT_DIR)\00_ZRCola_It.ttf"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(WINDIR)\Fonts\00_ZRCola_Bd.ttf" : "$(OUTPUT_DIR)\00_ZRCola_Bd.ttf"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(WINDIR)\Fonts\00_ZRCola_BI.ttf" : "$(OUTPUT_DIR)\00_ZRCola_BI.ttf"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(PUBLISH_DIR)\ZRColaInstallDe.exe" : "$(OUTPUT_DIR)\Win32.Release\ZRColaInstallDe.exe"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(PUBLISH_DIR)\ZRColaInstallEn.exe" : "$(OUTPUT_DIR)\Win32.Release\ZRColaInstallEn.exe"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(PUBLISH_DIR)\ZRColaInstallRu.exe" : "$(OUTPUT_DIR)\Win32.Release\ZRColaInstallRu.exe"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(PUBLISH_DIR)\ZRColaInstallSl.exe" : "$(OUTPUT_DIR)\Win32.Release\ZRColaInstallSl.exe"
|
||||
"$(WINDIR)\Fonts\ZRCola_BI.otf" : "$(OUTPUT_DIR)\ZRCola_BI.otf"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
|
||||
@@ -288,130 +291,177 @@ $(REDIST_SL_X64) : "$(OUTPUT_DIR)\ZRColaSl64.3.msi"
|
||||
# Building
|
||||
######################################################################
|
||||
|
||||
"$(OUTPUT_DIR)\locale\de_DE\wxstd.mo" : "$(WXWIN)\locale\de.po"
|
||||
msgfmt.exe --output-file=$@ --alignment=1 --endianness=little $**
|
||||
|
||||
"$(OUTPUT_DIR)\locale\ru_RU\wxstd.mo" : "$(WXWIN)\locale\ru.po"
|
||||
msgfmt.exe --output-file=$@ --alignment=1 --endianness=little $**
|
||||
|
||||
"$(OUTPUT_DIR)\locale\sl_SI\wxstd.mo" : "$(WXWIN)\locale\sl.po"
|
||||
msgfmt.exe --output-file=$@ --alignment=1 --endianness=little $**
|
||||
|
||||
"$(OUTPUT_DIR)\locale\de_DE\ZRCola-zrcdb.mo" : "$(OUTPUT_DIR)\locale\de_DE\ZRCola-zrcdb.po"
|
||||
msgfmt.exe --output-file=$@ --alignment=1 --endianness=little $**
|
||||
|
||||
"$(OUTPUT_DIR)\locale\ru_RU\ZRCola-zrcdb.mo" : "$(OUTPUT_DIR)\locale\ru_RU\ZRCola-zrcdb.po"
|
||||
msgfmt.exe --output-file=$@ --alignment=1 --endianness=little $**
|
||||
|
||||
"$(OUTPUT_DIR)\locale\sl_SI\ZRCola-zrcdb.mo" : "$(OUTPUT_DIR)\locale\sl_SI\ZRCola-zrcdb.po"
|
||||
msgfmt.exe --output-file=$@ --alignment=1 --endianness=little $**
|
||||
|
||||
"$(OUTPUT_DIR)\Win32.Release\libZRCola10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Release\libZRColaUI10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Release\stdex10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Release\wxExtend10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Release\ZRCola.exe" \
|
||||
"$(OUTPUT_DIR)\ZRColaEn32.3.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl32.3.msi" ::
|
||||
"$(OUTPUT_DIR)\Win32.Release\ZRCola.exe" :: Localization
|
||||
|
||||
"$(OUTPUT_DIR)\Win32.Debug\libZRCola10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Debug\libZRColaUI10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Debug\stdex10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Debug\wxExtend10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Debug\ZRCola.exe" :: Localization
|
||||
|
||||
"$(OUTPUT_DIR)\x64.Release\libZRCola10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Release\libZRColaUI10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Release\stdex10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Release\wxExtend10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Release\ZRCola.exe" :: Localization
|
||||
|
||||
"$(OUTPUT_DIR)\x64.Debug\libZRCola10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Debug\libZRColaUI10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Debug\stdex10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Debug\wxExtend10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Debug\ZRCola.exe" :: Localization
|
||||
|
||||
"$(OUTPUT_DIR)\Win32.Release\libZRCola10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Release\libZRColaUI10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Release\stdex10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Release\wxExtend10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Release\ZRCola.exe" ::
|
||||
devenv.com "ZRCola.sln" /build "Release|Win32"
|
||||
|
||||
"$(OUTPUT_DIR)\Win32.Debug\libZRCola10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Debug\libZRColaUI10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Debug\stdex10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Debug\wxExtend10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\Win32.Debug\ZRCola.exe" \
|
||||
"$(OUTPUT_DIR)\ZRColaEn32D.3.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl32D.3.msi" ::
|
||||
"$(OUTPUT_DIR)\Win32.Debug\ZRCola.exe" ::
|
||||
devenv.com "ZRCola.sln" /build "Debug|Win32"
|
||||
|
||||
"$(OUTPUT_DIR)\x64.Release\libZRCola10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Release\libZRColaUI10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Release\stdex10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Release\wxExtend10u_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Release\ZRCola.exe" \
|
||||
"$(OUTPUT_DIR)\ZRColaEn64.3.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl64.3.msi" ::
|
||||
"$(OUTPUT_DIR)\x64.Release\ZRCola.exe" ::
|
||||
devenv.com "ZRCola.sln" /build "Release|x64"
|
||||
|
||||
"$(OUTPUT_DIR)\x64.Debug\libZRCola10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Debug\libZRColaUI10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Debug\stdex10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Debug\wxExtend10ud_vc100.dll" \
|
||||
"$(OUTPUT_DIR)\x64.Debug\ZRCola.exe" \
|
||||
"$(OUTPUT_DIR)\ZRColaEn64D.3.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl64D.3.msi" ::
|
||||
"$(OUTPUT_DIR)\x64.Debug\ZRCola.exe" ::
|
||||
devenv.com "ZRCola.sln" /build "Debug|x64"
|
||||
|
||||
"$(OUTPUT_DIR)\Win32.Release\ZRColaInstallDe.exe" \
|
||||
"$(OUTPUT_DIR)\Win32.Release\ZRColaInstallEn.exe" \
|
||||
"$(OUTPUT_DIR)\Win32.Release\ZRColaInstallRu.exe" \
|
||||
"$(OUTPUT_DIR)\Win32.Release\ZRColaInstallSl.exe" ::
|
||||
devenv.com "ZRColaUtils.sln" /build "Release|Win32"
|
||||
"$(OUTPUT_DIR)\ZRCola32.ddf" : \
|
||||
# "$(OUTPUT_DIR)\ZRCola.de_DE.32.2.msi" \
|
||||
"$(OUTPUT_DIR)\ZRCola.en_US.32.2.msi" \
|
||||
"$(OUTPUT_DIR)\ZRCola.ru_RU.32.2.msi" \
|
||||
"$(OUTPUT_DIR)\ZRCola.sl_SI.32.2.msi"
|
||||
-if exist $@ del /f /q $@
|
||||
-if exist "$(@:"=).tmp" del /f /q "$(@:"=).tmp"
|
||||
cscript.exe "MSI\MSIBuild\MSI.wsf" //Job:MakeDDF //Nologo "$(@:"=).tmp" $** /O:"$(OUTPUT_DIR)\ZRCola32" /C:LZX
|
||||
move /y "$(@:"=).tmp" $@ > NUL
|
||||
|
||||
"$(OUTPUT_DIR)\Win32.Debug\ZRColaInstallDe.exe" \
|
||||
"$(OUTPUT_DIR)\Win32.Debug\ZRColaInstallEn.exe" \
|
||||
"$(OUTPUT_DIR)\Win32.Debug\ZRColaInstallRu.exe" \
|
||||
"$(OUTPUT_DIR)\Win32.Debug\ZRColaInstallSl.exe" ::
|
||||
devenv.com "ZRColaUtils.sln" /build "Debug|Win32"
|
||||
"$(OUTPUT_DIR)\ZRCola32D.ddf" : \
|
||||
# "$(OUTPUT_DIR)\ZRCola.de_DE.32D.2.msi" \
|
||||
"$(OUTPUT_DIR)\ZRCola.en_US.32D.2.msi" \
|
||||
"$(OUTPUT_DIR)\ZRCola.ru_RU.32D.2.msi" \
|
||||
"$(OUTPUT_DIR)\ZRCola.sl_SI.32D.2.msi"
|
||||
-if exist $@ del /f /q $@
|
||||
-if exist "$(@:"=).tmp" del /f /q "$(@:"=).tmp"
|
||||
cscript.exe "MSI\MSIBuild\MSI.wsf" //Job:MakeDDF //Nologo "$(@:"=).tmp" $** /O:"$(OUTPUT_DIR)\ZRCola32D" /C:LZX
|
||||
move /y "$(@:"=).tmp" $@ > NUL
|
||||
|
||||
"$(OUTPUT_DIR)\ZRColaEn32.3.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl32.3.msi" ::
|
||||
devenv.com "MSI\MSICA\MSICA.sln" /build "Release|Win32"
|
||||
devenv.com "Updater\Updater.sln" /build "Release|Win32"
|
||||
"$(OUTPUT_DIR)\ZRCola64.ddf" : \
|
||||
# "$(OUTPUT_DIR)\ZRCola.de_DE.64.2.msi" \
|
||||
"$(OUTPUT_DIR)\ZRCola.en_US.64.2.msi" \
|
||||
"$(OUTPUT_DIR)\ZRCola.ru_RU.64.2.msi" \
|
||||
"$(OUTPUT_DIR)\ZRCola.sl_SI.64.2.msi"
|
||||
-if exist $@ del /f /q $@
|
||||
-if exist "$(@:"=).tmp" del /f /q "$(@:"=).tmp"
|
||||
cscript.exe "MSI\MSIBuild\MSI.wsf" //Job:MakeDDF //Nologo "$(@:"=).tmp" $** /O:"$(OUTPUT_DIR)\ZRCola64" /C:LZX
|
||||
move /y "$(@:"=).tmp" $@ > NUL
|
||||
|
||||
"$(OUTPUT_DIR)\ZRColaEn32D.3.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl32D.3.msi" ::
|
||||
devenv.com "MSI\MSICA\MSICA.sln" /build "Debug|Win32"
|
||||
devenv.com "Updater\Updater.sln" /build "Debug|Win32"
|
||||
"$(OUTPUT_DIR)\ZRCola64D.ddf" : \
|
||||
# "$(OUTPUT_DIR)\ZRCola.de_DE.64D.2.msi" \
|
||||
"$(OUTPUT_DIR)\ZRCola.en_US.64D.2.msi" \
|
||||
"$(OUTPUT_DIR)\ZRCola.ru_RU.64D.2.msi" \
|
||||
"$(OUTPUT_DIR)\ZRCola.sl_SI.64D.2.msi"
|
||||
-if exist $@ del /f /q $@
|
||||
-if exist "$(@:"=).tmp" del /f /q "$(@:"=).tmp"
|
||||
cscript.exe "MSI\MSIBuild\MSI.wsf" //Job:MakeDDF //Nologo "$(@:"=).tmp" $** /O:"$(OUTPUT_DIR)\ZRCola64D" /C:LZX
|
||||
move /y "$(@:"=).tmp" $@ > NUL
|
||||
|
||||
"$(OUTPUT_DIR)\ZRColaEn64.3.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl64.3.msi" ::
|
||||
devenv.com "MSI\MSICA\MSICA.sln" /build "Release|x64"
|
||||
devenv.com "Updater\Updater.sln" /build "Release|x64"
|
||||
"$(OUTPUT_DIR)\ZRCola32.cab" \
|
||||
"$(OUTPUT_DIR)\ZRCola32.inf" \
|
||||
"$(OUTPUT_DIR)\ZRCola32.rpt" : "$(OUTPUT_DIR)\ZRCola32.ddf"
|
||||
makecab.exe /F $**
|
||||
|
||||
"$(OUTPUT_DIR)\ZRColaEn64D.3.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl64D.3.msi" ::
|
||||
devenv.com "MSI\MSICA\MSICA.sln" /build "Debug|x64"
|
||||
devenv.com "Updater\Updater.sln" /build "Debug|x64"
|
||||
"$(OUTPUT_DIR)\ZRCola32D.cab" \
|
||||
"$(OUTPUT_DIR)\ZRCola32D.inf" \
|
||||
"$(OUTPUT_DIR)\ZRCola32D.rpt" : "$(OUTPUT_DIR)\ZRCola32D.ddf"
|
||||
makecab.exe /F $**
|
||||
|
||||
"$(OUTPUT_DIR)\ZRColaEn32.3.msi" ::
|
||||
cd "MSI\ZRCola"
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) LANG=En PLAT=Win32 CFG=Release
|
||||
cd "$(MAKEDIR)"
|
||||
"$(OUTPUT_DIR)\ZRCola64.cab" \
|
||||
"$(OUTPUT_DIR)\ZRCola64.inf" \
|
||||
"$(OUTPUT_DIR)\ZRCola64.rpt" : "$(OUTPUT_DIR)\ZRCola64.ddf"
|
||||
makecab.exe /F $**
|
||||
|
||||
"$(OUTPUT_DIR)\ZRColaEn32D.3.msi" ::
|
||||
cd "MSI\ZRCola"
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) LANG=En PLAT=Win32 CFG=Debug
|
||||
cd "$(MAKEDIR)"
|
||||
|
||||
"$(OUTPUT_DIR)\ZRColaEn64.3.msi" ::
|
||||
cd "MSI\ZRCola"
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) LANG=En PLAT=x64 CFG=Release
|
||||
cd "$(MAKEDIR)"
|
||||
|
||||
"$(OUTPUT_DIR)\ZRColaEn64D.3.msi" ::
|
||||
cd "MSI\ZRCola"
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) LANG=En PLAT=x64 CFG=Debug
|
||||
cd "$(MAKEDIR)"
|
||||
|
||||
"$(OUTPUT_DIR)\ZRColaSl32.3.msi" ::
|
||||
cd "MSI\ZRCola"
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) LANG=Sl PLAT=Win32 CFG=Release
|
||||
cd "$(MAKEDIR)"
|
||||
|
||||
"$(OUTPUT_DIR)\ZRColaSl32D.3.msi" ::
|
||||
cd "MSI\ZRCola"
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) LANG=Sl PLAT=Win32 CFG=Debug
|
||||
cd "$(MAKEDIR)"
|
||||
|
||||
"$(OUTPUT_DIR)\ZRColaSl64.3.msi" ::
|
||||
cd "MSI\ZRCola"
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) LANG=Sl PLAT=x64 CFG=Release
|
||||
cd "$(MAKEDIR)"
|
||||
|
||||
"$(OUTPUT_DIR)\ZRColaSl64D.3.msi" ::
|
||||
cd "MSI\ZRCola"
|
||||
$(MAKE) /f "Makefile" /$(MAKEFLAGS) LANG=Sl PLAT=x64 CFG=Debug
|
||||
cd "$(MAKEDIR)"
|
||||
"$(OUTPUT_DIR)\ZRCola64D.cab" \
|
||||
"$(OUTPUT_DIR)\ZRCola64D.inf" \
|
||||
"$(OUTPUT_DIR)\ZRCola64D.rpt" : "$(OUTPUT_DIR)\ZRCola64D.ddf"
|
||||
makecab.exe /F $**
|
||||
|
||||
"$(PUBLISH_DIR)\catalog-0000.xml" : "$(OUTPUT_DIR)\catalog.xml"
|
||||
if exist $@ del /f /q $@
|
||||
output\$(PLAT).Release\UpdSignXML.exe $** $@
|
||||
|
||||
"$(OUTPUT_DIR)\catalog.xml" : \
|
||||
"$(OUTPUT_DIR)\ZRColaEn32.3.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaEn64.3.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl32.3.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl64.3.msi"
|
||||
# "$(OUTPUT_DIR)\ZRColaDe32.msi" \
|
||||
# "$(OUTPUT_DIR)\ZRColaDe64.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaEn32.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaEn64.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaRu32.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaRu64.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl32.msi" \
|
||||
"$(OUTPUT_DIR)\ZRColaSl64.msi"
|
||||
-if exist $@ del /f /q $@
|
||||
-if exist "$(@:"=).tmp" del /f /q "$(@:"=).tmp"
|
||||
copy /y "$(PUBLISH_DIR)\catalog-0000.xml" "$(@:"=).tmp" > NUL
|
||||
output\$(PLAT).Release\UpdPublish.exe "$(@:"=).tmp" "$(@:"=).tmp" win-x86 en_US "$(PUBLISH_PACKAGE_URL)/ZRColaEn32.msi" -f "$(OUTPUT_DIR)\ZRColaEn32.3.msi"
|
||||
output\$(PLAT).Release\UpdPublish.exe "$(@:"=).tmp" "$(@:"=).tmp" win-amd64 en_US "$(PUBLISH_PACKAGE_URL)/ZRColaEn64.msi" -f "$(OUTPUT_DIR)\ZRColaEn64.3.msi"
|
||||
output\$(PLAT).Release\UpdPublish.exe "$(@:"=).tmp" "$(@:"=).tmp" win-x86 sl_SI "$(PUBLISH_PACKAGE_URL)/ZRColaSl32.msi" -f "$(OUTPUT_DIR)\ZRColaSl32.3.msi"
|
||||
output\$(PLAT).Release\UpdPublish.exe "$(@:"=).tmp" "$(@:"=).tmp" win-amd64 sl_SI "$(PUBLISH_PACKAGE_URL)/ZRColaSl64.msi" -f "$(OUTPUT_DIR)\ZRColaSl64.3.msi"
|
||||
# output\$(PLAT).Release\UpdPublish.exe "$(@:"=).tmp" "$(@:"=).tmp" win-x86 de_DE "$(PUBLISH_PACKAGE_URL)/ZRColaDe32.msi" -f "$(OUTPUT_DIR)\ZRColaDe32.msi"
|
||||
# output\$(PLAT).Release\UpdPublish.exe "$(@:"=).tmp" "$(@:"=).tmp" win-amd64 de_DE "$(PUBLISH_PACKAGE_URL)/ZRColaDe64.msi" -f "$(OUTPUT_DIR)\ZRColaDe64.msi"
|
||||
output\$(PLAT).Release\UpdPublish.exe "$(@:"=).tmp" "$(@:"=).tmp" win-x86 en_US "$(PUBLISH_PACKAGE_URL)/ZRColaEn32.msi" -f "$(OUTPUT_DIR)\ZRColaEn32.msi"
|
||||
output\$(PLAT).Release\UpdPublish.exe "$(@:"=).tmp" "$(@:"=).tmp" win-amd64 en_US "$(PUBLISH_PACKAGE_URL)/ZRColaEn64.msi" -f "$(OUTPUT_DIR)\ZRColaEn64.msi"
|
||||
output\$(PLAT).Release\UpdPublish.exe "$(@:"=).tmp" "$(@:"=).tmp" win-x86 ru_RU "$(PUBLISH_PACKAGE_URL)/ZRColaRu32.msi" -f "$(OUTPUT_DIR)\ZRColaRu32.msi"
|
||||
output\$(PLAT).Release\UpdPublish.exe "$(@:"=).tmp" "$(@:"=).tmp" win-amd64 ru_RU "$(PUBLISH_PACKAGE_URL)/ZRColaRu64.msi" -f "$(OUTPUT_DIR)\ZRColaRu64.msi"
|
||||
output\$(PLAT).Release\UpdPublish.exe "$(@:"=).tmp" "$(@:"=).tmp" win-x86 sl_SI "$(PUBLISH_PACKAGE_URL)/ZRColaSl32.msi" -f "$(OUTPUT_DIR)\ZRColaSl32.msi"
|
||||
output\$(PLAT).Release\UpdPublish.exe "$(@:"=).tmp" "$(@:"=).tmp" win-amd64 sl_SI "$(PUBLISH_PACKAGE_URL)/ZRColaSl64.msi" -f "$(OUTPUT_DIR)\ZRColaSl64.msi"
|
||||
move /y "$(@:"=).tmp" $@ > NUL
|
||||
|
||||
!ENDIF
|
||||
|
||||
|
||||
#LANG=de_DE
|
||||
#LANG_OUT=De
|
||||
#!INCLUDE "MSILocal.mak"
|
||||
|
||||
LANG=en_US
|
||||
LANG_OUT=En
|
||||
!INCLUDE "MSILocal.mak"
|
||||
|
||||
LANG=ru_RU
|
||||
LANG_OUT=Ru
|
||||
!INCLUDE "MSILocal.mak"
|
||||
|
||||
LANG=sl_SI
|
||||
LANG_OUT=Sl
|
||||
!INCLUDE "MSILocal.mak"
|
||||
|
||||
45
README.md
@@ -1 +1,44 @@
|
||||
# ZRCola
|
||||
# ZRCola
|
||||
|
||||
A Microsoft Windows application for composing texts using a wide range of Slavic (and general) letters from or beyond Unicode.
|
||||
|
||||
## Project Website
|
||||
http://zrcola.zrc-sazu.si/en/
|
||||
|
||||
## Binaries for Download
|
||||
https://www.amebis.si/prenos/ZRCola/
|
||||
|
||||
## Building
|
||||
|
||||
### Building Environment Requirements
|
||||
- Microsoft Windows Vista or later
|
||||
- Microsoft Visual Studio 2010 SP1
|
||||
- _sed.exe_ and _grep.exe_
|
||||
- Command line utilities from Microsoft Windows SDK Bin folder: distributed with Visual Studio, add Bin folder to path manually.
|
||||
- Additional command line utilities from project’s bin folder: add bin folder to path. The source code is provided on request.
|
||||
|
||||
### Digital Signing of Build Outputs
|
||||
In order to have the build process digitally sign output files, one should provide the following:
|
||||
|
||||
1. A signing certificate installed in the current user’s certificate store.
|
||||
2. The following variables in the environment:
|
||||
- `ManifestCertificateThumbprint` - set the value to certificate’s SHA1 thumbprint (hexadecimal, without spaces, i.e. `bc0d8da45f9eeefcbe4e334e1fc262804df88d7e`).
|
||||
- `ManifestTimestampUrl` - set the value to URL used to perform timestamp signature (i.e. `http://timestamp.verisign.com/scripts/timstamp.dll`). In order to perform timestamp signing successfully, the computer running the build should be online and able to access this URL.
|
||||
|
||||
Please note that only Release builds are configured for timestamp signing. Debug configurations do not attempt to timestamp sign the resulting DLL and EXE files in order to speed up the building process and enable offline building.
|
||||
|
||||
### Building
|
||||
Use Microsoft NMAKE to build the project. The resulting files can be found in output subfolder.
|
||||
|
||||
- `nmake Clean` Delete all intermediate and output files.
|
||||
- `nmake Setup` Build a release version of project and release MSI setup files.
|
||||
- `nmake SetupDebug` Build a debug version of project and debug MSI setup files.
|
||||
- `nmake Register` Build a debug version of project, install fonts (reboot required), and Start Menu shortcuts. For development purposes only!
|
||||
- `nmake Unregister` Remove Start Menu shortcuts, and fonts. For development purposes only!
|
||||
|
||||
The `/ls` flag can be appended to the commands above to reduce NMAKE’s verbosity. You can combine multiple targets (i.e. nmake Unregister Clean). Please, see NMAKE reference for further reading.
|
||||
|
||||
## Contact Information
|
||||
Please contact the following addressee for further information and help:
|
||||
- ZRC SAZU, ZRCola@zrc-sazu.si
|
||||
- Amebis, info@amebis.si
|
||||
|
||||
2
Updater
15
ZRCola.sln
@@ -5,11 +5,11 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ZRCola", "ZRCola\ZRCola.vcx
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Libraries", "Libraries", "{6D85AD6A-69D6-40EB-BF0C-7495479DDCE5}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "wxExtend", "lib\wxExtend\build\wxExtend.vcxproj", "{A3A36689-AC35-4026-93DA-A3BA0C0E767C}"
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "wxExtend", "lib\wxExtend\build\wxExtendDll.vcxproj", "{A3A36689-AC35-4026-93DA-A3BA0C0E767C}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{CFEBC17E-C840-4507-BDE6-1EF5B52DDCC5}"
|
||||
ProjectSection(SolutionItems) = preProject
|
||||
include\zrcola.h = include\zrcola.h
|
||||
include\version.h = include\version.h
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libZRCola", "lib\libZRCola\build\libZRCola.vcxproj", "{3C61929E-7289-4101-8D0A-DA22D6E1AEA8}"
|
||||
@@ -20,6 +20,8 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "stdex", "lib\stdex\build\st
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Updater", "Updater\Updater\build\Updater.vcxproj", "{990D8CF9-4457-4DC0-AA18-4968EF434741}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "WinStd", "lib\WinStd\build\WinStd.vcxproj", "{47399D91-7EB9-41DE-B521-514BA5DB0C43}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Win32 = Debug|Win32
|
||||
@@ -76,6 +78,14 @@ Global
|
||||
{990D8CF9-4457-4DC0-AA18-4968EF434741}.Release|Win32.Build.0 = Release|Win32
|
||||
{990D8CF9-4457-4DC0-AA18-4968EF434741}.Release|x64.ActiveCfg = Release|x64
|
||||
{990D8CF9-4457-4DC0-AA18-4968EF434741}.Release|x64.Build.0 = Release|x64
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Debug|x64.Build.0 = Debug|x64
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Release|Win32.Build.0 = Release|Win32
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Release|x64.ActiveCfg = Release|x64
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Release|x64.Build.0 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
@@ -86,5 +96,6 @@ Global
|
||||
{C0A84BD2-3870-4CD6-B281-0AB322E3C579} = {6D85AD6A-69D6-40EB-BF0C-7495479DDCE5}
|
||||
{518777CC-0A59-4415-A12A-82751ED75343} = {6D85AD6A-69D6-40EB-BF0C-7495479DDCE5}
|
||||
{990D8CF9-4457-4DC0-AA18-4968EF434741} = {6D85AD6A-69D6-40EB-BF0C-7495479DDCE5}
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43} = {6D85AD6A-69D6-40EB-BF0C-7495479DDCE5}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
||||
|
||||
BIN
ZRCola/MSIBuild/Binary/tutorial1.bmp
Normal file
|
After Width: | Height: | Size: 3.6 KiB |
BIN
ZRCola/MSIBuild/Binary/tutorial1.psd
Normal file
BIN
ZRCola/MSIBuild/Binary/tutorial2.bmp
Normal file
|
After Width: | Height: | Size: 19 KiB |
BIN
ZRCola/MSIBuild/Binary/tutorial2.png
Normal file
|
After Width: | Height: | Size: 22 KiB |
BIN
ZRCola/MSIBuild/Binary/tutorial3.bmp
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
ZRCola/MSIBuild/Binary/tutorial3.png
Normal file
|
After Width: | Height: | Size: 11 KiB |
@@ -19,6 +19,10 @@
|
||||
|
||||
!INCLUDE "..\..\include\MSIBuildCfg.mak"
|
||||
|
||||
!IFNDEF MSIBUILD_LANGID
|
||||
!ERROR Parameter MSIBUILD_LANGID is undefined.
|
||||
!ENDIF
|
||||
|
||||
MSIBUILD_IS_LOCALIZEABLE=1
|
||||
|
||||
|
||||
@@ -37,6 +41,36 @@ OLDZRCOLADIR clZRCola.exe.$(PLAT)
|
||||
<<NOKEEP
|
||||
|
||||
|
||||
######################################################################
|
||||
# Binary
|
||||
|
||||
All :: \
|
||||
"$(LANG).$(PLAT).$(CFG).Binary-1.idt" \
|
||||
"$(LANG).$(PLAT).$(CFG).Binary-1\tutorial1.bmp" \
|
||||
"$(LANG).$(PLAT).$(CFG).Binary-1\tutorial2.bmp" \
|
||||
"$(LANG).$(PLAT).$(CFG).Binary-1\tutorial3.bmp"
|
||||
|
||||
"$(LANG).$(PLAT).$(CFG).Binary-1.idt" : "Makefile" "..\..\include\MSIBuildCfg.mak" "$(LANG).$(PLAT).$(CFG).Binary-1"
|
||||
-if exist $@ del /f /q $@
|
||||
move /y << $@ > NUL
|
||||
Name Data
|
||||
s$(MSIBUILD_LENGTH_ID) v0
|
||||
Binary Name
|
||||
bintutorial1.bmp tutorial1.bmp
|
||||
bintutorial2.bmp tutorial2.bmp
|
||||
bintutorial3.bmp tutorial3.bmp
|
||||
<<NOKEEP
|
||||
|
||||
"$(LANG).$(PLAT).$(CFG).Binary-1\tutorial1.bmp" : "Binary\tutorial1.bmp"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(LANG).$(PLAT).$(CFG).Binary-1\tutorial2.bmp" : "Binary\tutorial2.bmp"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"$(LANG).$(PLAT).$(CFG).Binary-1\tutorial3.bmp" : "Binary\tutorial3.bmp"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
|
||||
######################################################################
|
||||
# CompLocator
|
||||
|
||||
@@ -74,18 +108,110 @@ compZRCola.exe.Win32 {F30B6545-6203-4B7D-8575-85245A0F90E5} ZRCOLABINDIR 0 file
|
||||
!IF "$(PLAT)" == "x64"
|
||||
compZRCola.exe.x64 {D45B105D-2303-459A-AF4B-52AC3AAD5510} ZRCOLABINDIR 256 fileZRCola.exe.x64
|
||||
!ENDIF
|
||||
!IF "$(LANG)" == "Sl"
|
||||
!IF "$(LANG)" == "ru_RU"
|
||||
compZRCola.mo.ru_RU {DEA5D11C-2B0E-4B85-ACE3-D76334866F50} ZRCOLALOCRURUDIR $(MSIBUILD_COMPONENT_ATTRIB_FILE) fileZRCola.mo.ru_RU
|
||||
!ENDIF
|
||||
!IF "$(LANG)" == "sl_SI"
|
||||
compZRCola.mo.sl_SI {7FF95C71-D8DE-4D2B-A26D-FEB5A1F54D63} ZRCOLALOCSLSIDIR $(MSIBUILD_COMPONENT_ATTRIB_FILE) fileZRCola.mo.sl_SI
|
||||
!ENDIF
|
||||
<<NOKEEP
|
||||
|
||||
|
||||
######################################################################
|
||||
# Control
|
||||
|
||||
All :: "$(LANG).$(PLAT).$(CFG).Control-2.idt"
|
||||
|
||||
"en_US.$(PLAT).$(CFG).Control-2.idtx" : "Makefile" "..\..\include\MSIBuildCfg.mak"
|
||||
-if exist $@ del /f /q $@
|
||||
move /y << $@ > NUL
|
||||
Dialog_ Control Type X Y Width Height Attributes Property Text Control_Next Help
|
||||
s$(MSIBUILD_LENGTH_ID) s50 s20 i2 i2 i2 i2 I4 S50 L0 S50 L$(MSIBUILD_LENGTH_HELP)
|
||||
1252 Control Dialog_ Control
|
||||
dlgTutorial1 ctlBannerBitmap Bitmap 0 0 400 45 1 binUIHeader.bmp ctlTitle
|
||||
dlgTutorial1 ctlTitle Text 15 15 320 15 196611 [DlgTitleFont][SimpleProductName] Tutorial : Starting ctlScreenshot
|
||||
dlgTutorial1 ctlScreenshot Bitmap 154 60 92 54 5 bintutorial1.bmp ctlText1
|
||||
dlgTutorial1 ctlText1 Text 15 119 370 24 196611 When configured, ZRCola starts at system startup and runs in the background. If needed, it can be brought up by pressing the combination Win+F5. ctlText2
|
||||
dlgTutorial1 ctlText2 Text 15 148 370 36 196611 IMPORTANT: Upon pressing the combination Win+F5 the program memorises the location of the cursor in the text. If ZRCola is brought to the foreground without using the aforementioned combination of keys, the program won't know where to insert the special characters! ctlContinue
|
||||
dlgTutorial1 ctlContinue PushButton 325 265 60 20 3 &Continue ctlBannerBitmap
|
||||
dlgTutorial2 ctlBannerBitmap Bitmap 0 0 400 45 1 binUIHeader.bmp ctlTitle
|
||||
dlgTutorial2 ctlTitle Text 15 15 320 15 196611 [DlgTitleFont][SimpleProductName] Tutorial : Composition ctlScreenshot
|
||||
dlgTutorial2 ctlScreenshot Bitmap 81 60 238 137 5 bintutorial2.bmp ctlText1
|
||||
dlgTutorial2 ctlText1 Text 15 202 370 36 196611 The string of basic and substitute characters is entered into the upper input window of the program. In the window below the resulted special characters are displayed. To insert them in the text, the F5 key is used. ctlContinue
|
||||
dlgTutorial2 ctlContinue PushButton 325 265 60 20 3 &Continue ctlBannerBitmap
|
||||
dlgTutorial3 ctlBannerBitmap Bitmap 0 0 400 45 1 binUIHeader.bmp ctlTitle
|
||||
dlgTutorial3 ctlTitle Text 15 15 320 15 196611 [DlgTitleFont][SimpleProductName] Tutorial : Entering Characters ctlScreenshot
|
||||
dlgTutorial3 ctlScreenshot Bitmap 147 60 106 112 5 bintutorial3.bmp ctlText1
|
||||
dlgTutorial3 ctlText1 Text 15 177 370 24 196611 Characters can be entered using keyboard shortcuts, the character catalogue (F4) or the character finding tool (F8). ctlContinue
|
||||
dlgTutorial3 ctlContinue PushButton 325 265 60 20 3 &Continue ctlBannerBitmap
|
||||
<<NOKEEP
|
||||
|
||||
!IF "$(LANG)" == "en_US"
|
||||
"en_US.$(PLAT).$(CFG).Control-2.idt" : "en_US.$(PLAT).$(CFG).Control-2.idtx"
|
||||
copy /y $** $@ > NUL
|
||||
!ELSE
|
||||
"$(LANG).$(PLAT).$(CFG).Control-2.idt" : "en_US.$(PLAT).$(CFG).Control-2.idtx" "..\locale\$(LANG).po"
|
||||
cscript.exe "..\..\MSI\MSIBuild\MSI.wsf" //Job:IDTTranslate //Nologo $@ $** /CP:$(MSIBUILD_CODEPAGE)
|
||||
!ENDIF
|
||||
|
||||
|
||||
######################################################################
|
||||
# ControlEvent
|
||||
|
||||
All :: "$(LANG).$(PLAT).$(CFG).ControlEvent-1.idt"
|
||||
|
||||
"$(LANG).$(PLAT).$(CFG).ControlEvent-1.idt" : "Makefile" "..\..\include\MSIBuildCfg.mak"
|
||||
-if exist $@ del /f /q $@
|
||||
move /y << $@ > NUL
|
||||
Dialog_ Control_ Event Argument Condition Ordering
|
||||
s$(MSIBUILD_LENGTH_ID) s50 s50 s255 S255 I2
|
||||
ControlEvent Dialog_ Control_ Event Argument Condition
|
||||
dlgTutorial1 ctlContinue EndDialog Return 1 1000
|
||||
dlgTutorial2 ctlContinue EndDialog Return 1 1000
|
||||
dlgTutorial3 ctlContinue EndDialog Return 1 1000
|
||||
<<NOKEEP
|
||||
|
||||
|
||||
######################################################################
|
||||
# Dialog
|
||||
|
||||
All :: "$(LANG).$(PLAT).$(CFG).Dialog-1.idt"
|
||||
|
||||
"$(LANG).$(PLAT).$(CFG).Dialog-1.idt" : "Makefile" "..\..\include\MSIBuildCfg.mak"
|
||||
-if exist $@ del /f /q $@
|
||||
move /y << $@ > NUL
|
||||
Dialog HCentering VCentering Width Height Attributes Title Control_First Control_Default Control_Cancel
|
||||
s$(MSIBUILD_LENGTH_ID) i2 i2 i2 i2 I4 L128 s50 S50 S50
|
||||
Dialog Dialog
|
||||
dlgTutorial1 50 50 400 300 3 [Setup] [SimpleProductName] [DisplayVersion] ctlTitle ctlContinue ctlContinue
|
||||
dlgTutorial2 50 50 400 300 3 [Setup] [SimpleProductName] [DisplayVersion] ctlTitle ctlContinue ctlContinue
|
||||
dlgTutorial3 50 50 400 300 3 [Setup] [SimpleProductName] [DisplayVersion] ctlTitle ctlContinue ctlContinue
|
||||
<<NOKEEP
|
||||
|
||||
|
||||
######################################################################
|
||||
# InstallUISequence
|
||||
|
||||
All :: "$(LANG).$(PLAT).$(CFG).InstallUISequence-1.idt"
|
||||
|
||||
"$(LANG).$(PLAT).$(CFG).InstallUISequence-1.idt" : "Makefile" "..\..\include\MSIBuildCfg.mak"
|
||||
-if exist $@ del /f /q $@
|
||||
move /y << $@ > NUL
|
||||
Action Condition Sequence
|
||||
s$(MSIBUILD_LENGTH_ID) S255 I2
|
||||
InstallUISequence Action
|
||||
dlgTutorial1 NOT Installed 1400
|
||||
dlgTutorial2 NOT Installed 1401
|
||||
dlgTutorial3 NOT Installed 1402
|
||||
<<NOKEEP
|
||||
|
||||
|
||||
######################################################################
|
||||
# Feature
|
||||
|
||||
All :: "$(LANG).$(PLAT).$(CFG).Feature-2.idt"
|
||||
|
||||
"En.$(PLAT).$(CFG).Feature-2.idtx" : "Makefile" "..\..\include\MSIBuildCfg.mak"
|
||||
"en_US.$(PLAT).$(CFG).Feature-2.idtx" : "Makefile" "..\..\include\MSIBuildCfg.mak"
|
||||
-if exist $@ del /f /q $@
|
||||
move /y << $@ > NUL
|
||||
Feature Feature_Parent Title Description Display Level Directory_ Attributes
|
||||
@@ -94,17 +220,13 @@ s$(MSIBUILD_LENGTH_ID) S$(MSIBUILD_LENGTH_ID) L64 L255 I2 i2 S$(MSIBUILD_LENGTH_
|
||||
featZRCola ZRCola Input system for linguistic use 1 1 ZRCOLADIR 8
|
||||
<<NOKEEP
|
||||
|
||||
"De.$(PLAT).$(CFG).Feature-2.idt" : "En.$(PLAT).$(CFG).Feature-2.idtx" "..\locale\de_DE.po"
|
||||
rcxgettext.exe idtp $@ $**
|
||||
|
||||
"En.$(PLAT).$(CFG).Feature-2.idt" : "En.$(PLAT).$(CFG).Feature-2.idtx"
|
||||
!IF "$(LANG)" == "en_US"
|
||||
"en_US.$(PLAT).$(CFG).Feature-2.idt" : "en_US.$(PLAT).$(CFG).Feature-2.idtx"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"It.$(PLAT).$(CFG).Feature-2.idt" : "En.$(PLAT).$(CFG).Feature-2.idtx" "..\locale\it_IT.po"
|
||||
rcxgettext.exe idtp $@ $**
|
||||
|
||||
"Sl.$(PLAT).$(CFG).Feature-2.idt" : "En.$(PLAT).$(CFG).Feature-2.idtx" "..\locale\sl_SI.po"
|
||||
rcxgettext.exe idtp $@ $**
|
||||
!ELSE
|
||||
"$(LANG).$(PLAT).$(CFG).Feature-2.idt" : "en_US.$(PLAT).$(CFG).Feature-2.idtx" "..\locale\$(LANG).po"
|
||||
cscript.exe "..\..\MSI\MSIBuild\MSI.wsf" //Job:IDTTranslate //Nologo $@ $** /CP:$(MSIBUILD_CODEPAGE)
|
||||
!ENDIF
|
||||
|
||||
|
||||
######################################################################
|
||||
@@ -127,14 +249,14 @@ featZRCola compLocalizationRepositoryPath
|
||||
featZRCola compLanguage
|
||||
featZRCola compDatabasePath
|
||||
featZRCola compZRCola.zrcdb
|
||||
featZRCola comp00_ZRCola_Re.ttf
|
||||
!IF "$(LANG)" == "Sl"
|
||||
featZRCola compZRCola.mo.sl_SI
|
||||
featZRCola compZRCola.zrcdb.mo.sl_SI
|
||||
featZRCola complibZRColaUI.mo.sl_SI
|
||||
featZRCola compwxExtend.mo.sl_SI
|
||||
featZRCola compUpdater.mo.sl_SI
|
||||
featZRCola compwxstd.mo.sl_SI
|
||||
featZRCola compZRCola_Re.otf
|
||||
!IF "$(LANG)" != "en_US"
|
||||
featZRCola compZRCola.mo.$(LANG)
|
||||
featZRCola compZRCola.zrcdb.mo.$(LANG)
|
||||
featZRCola complibZRColaUI.mo.$(LANG)
|
||||
featZRCola compwxExtend.mo.$(LANG)
|
||||
featZRCola compUpdater.mo.$(LANG)
|
||||
featZRCola compwxstd.mo.$(LANG)
|
||||
!ENDIF
|
||||
<<NOKEEP
|
||||
|
||||
@@ -151,8 +273,8 @@ File Component_ FileName FileSize Version Language Attributes Sequence
|
||||
s$(MSIBUILD_LENGTH_ID) s$(MSIBUILD_LENGTH_ID) l255 i4 S$(MSIBUILD_LENGTH_ID) S20 I2 i2
|
||||
File File
|
||||
fileZRCola.exe.$(PLAT) compZRCola.exe.$(PLAT) ZRCola.exe 0 0 1536 1
|
||||
!IF "$(LANG)" == "Sl"
|
||||
fileZRCola.mo.sl_SI compZRCola.mo.sl_SI ZRCola.mo 0 1060 0 1
|
||||
!IF "$(LANG)" != "en_US"
|
||||
fileZRCola.mo.$(LANG) compZRCola.mo.$(LANG) ZRCola.mo 0 $(MSIBUILD_LANGID) 0 1
|
||||
!ENDIF
|
||||
<<NOKEEP
|
||||
|
||||
@@ -197,7 +319,7 @@ rmfiZRCola compZRCola.exe.$(PLAT) ZRColaShortcutDir 2
|
||||
|
||||
All :: "$(LANG).$(PLAT).$(CFG).Shortcut-2.idt"
|
||||
|
||||
"En.$(PLAT).$(CFG).Shortcut-2.idtx" : "Makefile" "..\..\include\MSIBuildCfg.mak"
|
||||
"en_US.$(PLAT).$(CFG).Shortcut-2.idtx" : "Makefile" "..\..\include\MSIBuildCfg.mak"
|
||||
-if exist $@ del /f /q $@
|
||||
move /y << $@ > NUL
|
||||
Shortcut Directory_ Name Component_ Target Arguments Description Hotkey Icon_ IconIndex ShowCmd WkDir
|
||||
@@ -206,17 +328,13 @@ s$(MSIBUILD_LENGTH_ID) s$(MSIBUILD_LENGTH_ID) l128 s$(MSIBUILD_LENGTH_ID) s$(MSI
|
||||
shctZRCola ZRColaShortcutDir ZRCola compZRCola.exe.$(PLAT) featZRCola Input system for linguistic use iconZRCola.ico ZRCOLABINDIR
|
||||
<<NOKEEP
|
||||
|
||||
"De.$(PLAT).$(CFG).Shortcut-2.idt" : "En.$(PLAT).$(CFG).Shortcut-2.idtx" "..\locale\de_DE.po"
|
||||
rcxgettext.exe idtp $@ $**
|
||||
|
||||
"En.$(PLAT).$(CFG).Shortcut-2.idt" : "En.$(PLAT).$(CFG).Shortcut-2.idtx"
|
||||
!IF "$(LANG)" == "en_US"
|
||||
"en_US.$(PLAT).$(CFG).Shortcut-2.idt" : "en_US.$(PLAT).$(CFG).Shortcut-2.idtx"
|
||||
copy /y $** $@ > NUL
|
||||
|
||||
"It.$(PLAT).$(CFG).Shortcut-2.idt" : "En.$(PLAT).$(CFG).Shortcut-2.idtx" "..\locale\it_IT.po"
|
||||
rcxgettext.exe idtp $@ $**
|
||||
|
||||
"Sl.$(PLAT).$(CFG).Shortcut-2.idt" : "En.$(PLAT).$(CFG).Shortcut-2.idtx" "..\locale\sl_SI.po"
|
||||
rcxgettext.exe idtp $@ $**
|
||||
!ELSE
|
||||
"$(LANG).$(PLAT).$(CFG).Shortcut-2.idt" : "en_US.$(PLAT).$(CFG).Shortcut-2.idtx" "..\locale\$(LANG).po"
|
||||
cscript.exe "..\..\MSI\MSIBuild\MSI.wsf" //Job:IDTTranslate //Nologo $@ $** /CP:$(MSIBUILD_CODEPAGE)
|
||||
!ENDIF
|
||||
|
||||
|
||||
######################################################################
|
||||
|
||||
1871
ZRCola/ZRCola.fbp
@@ -7,7 +7,7 @@
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup>
|
||||
<ClCompile>
|
||||
<AdditionalIncludeDirectories>..\lib\wxExtend\include;..\Updater\Updater\include;..\lib\stdex\include;..\lib\libZRCola\include;..\lib\libZRColaUI\include</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\lib\wxExtend\include;..\Updater\Updater\include;..\lib\stdex\include;..\lib\WinStd\include;..\lib\libZRCola\include;..\lib\libZRColaUI\include</AdditionalIncludeDirectories>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup />
|
||||
|
||||
BIN
ZRCola/ZRCola.rc
@@ -84,6 +84,7 @@
|
||||
<ClCompile Include="zrcolaapp.cpp" />
|
||||
<ClCompile Include="zrcolachrcatpnl.cpp" />
|
||||
<ClCompile Include="zrcolachrgrid.cpp" />
|
||||
<ClCompile Include="zrcolachrreq.cpp" />
|
||||
<ClCompile Include="zrcolachrslct.cpp" />
|
||||
<ClCompile Include="zrcolacomppnl.cpp" />
|
||||
<ClCompile Include="zrcolafrm.cpp" />
|
||||
@@ -98,6 +99,7 @@
|
||||
<ClInclude Include="zrcolaapp.h" />
|
||||
<ClInclude Include="zrcolachrcatpnl.h" />
|
||||
<ClInclude Include="zrcolachrgrid.h" />
|
||||
<ClInclude Include="zrcolachrreq.h" />
|
||||
<ClInclude Include="zrcolachrslct.h" />
|
||||
<ClInclude Include="zrcolacomppnl.h" />
|
||||
<ClInclude Include="zrcolafrm.h" />
|
||||
@@ -113,7 +115,10 @@
|
||||
<ProjectReference Include="..\lib\libZRCola\build\libZRCola.vcxproj">
|
||||
<Project>{3c61929e-7289-4101-8d0a-da22d6e1aea8}</Project>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\lib\wxExtend\build\wxExtend.vcxproj">
|
||||
<ProjectReference Include="..\lib\WinStd\build\WinStd.vcxproj">
|
||||
<Project>{47399d91-7eb9-41de-b521-514ba5db0c43}</Project>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\lib\wxExtend\build\wxExtendDll.vcxproj">
|
||||
<Project>{a3a36689-ac35-4026-93da-a3ba0c0e767c}</Project>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\Updater\Updater\build\Updater.vcxproj">
|
||||
@@ -126,6 +131,8 @@
|
||||
<None Include="res\edit_copy.ico" />
|
||||
<None Include="res\edit_cut.ico" />
|
||||
<None Include="res\edit_paste.ico" />
|
||||
<None Include="res\navigate_back.ico" />
|
||||
<None Include="res\navigate_forward.ico" />
|
||||
<None Include="res\send_abort.ico" />
|
||||
<None Include="res\send_composed.ico" />
|
||||
<None Include="res\send_decomposed.ico" />
|
||||
|
||||
@@ -55,6 +55,9 @@
|
||||
<ClCompile Include="zrcolaupdater.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="zrcolachrreq.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="stdafx.h">
|
||||
@@ -93,6 +96,9 @@
|
||||
<ClInclude Include="zrcolaupdater.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="zrcolachrreq.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="res\zrcola.ico">
|
||||
@@ -125,6 +131,12 @@
|
||||
<None Include="locale\ZRCola.pot">
|
||||
<Filter>Resource Files\Localization</Filter>
|
||||
</None>
|
||||
<None Include="res\navigate_back.ico">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="res\navigate_forward.ico">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="ZRCola.rc">
|
||||
|
||||
@@ -1,15 +1,15 @@
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: ZRCola\n"
|
||||
"POT-Creation-Date: 2016-05-24 16:27+0200\n"
|
||||
"PO-Revision-Date: 2016-05-24 16:27+0200\n"
|
||||
"POT-Creation-Date: 2016-10-18 10:10+0200\n"
|
||||
"PO-Revision-Date: 2016-10-18 10:10+0200\n"
|
||||
"Last-Translator: Simon Rozman <simon.rozman@amebis.si>\n"
|
||||
"Language-Team: Amebis, d. o. o., Kamnik <info@amebis.si>\n"
|
||||
"Language: de_DE\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Generator: Poedit 1.8.7\n"
|
||||
"X-Generator: Poedit 1.8.10\n"
|
||||
"X-Poedit-Basepath: .\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-Poedit-SourceCharset: UTF-8\n"
|
||||
@@ -20,39 +20,74 @@ msgstr ""
|
||||
msgid "© 2004-%s ZRC SAZU"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolaapp.cpp:78 zrcolafrm.cpp:90 zrcolagui.cpp:758 zrcolagui.h:101
|
||||
#: MSIBuild/En.Win32.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/En.Win32.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/En.Win32.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/En.Win32.Release.Shortcut-2.idtx:4
|
||||
#: MSIBuild/En.x64.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/En.x64.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/En.x64.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/En.x64.Release.Shortcut-2.idtx:4
|
||||
#, fuzzy
|
||||
#: zrcolaapp.cpp:71 zrcolafrm.cpp:90 zrcolagui.cpp:874 zrcolagui.h:104
|
||||
#: MSIBuild/en_US.Win32.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Release.Shortcut-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Release.Shortcut-2.idtx:4
|
||||
msgid "ZRCola"
|
||||
msgstr "ZRCola:."
|
||||
msgstr "ZRCola"
|
||||
|
||||
#: zrcolafrm.cpp:108
|
||||
#: zrcolachrreq.cpp:49 zrcolagui.cpp:1004
|
||||
#, fuzzy
|
||||
msgid "Character"
|
||||
msgstr "Eingabe eines Zeichenstils"
|
||||
|
||||
#: zrcolachrreq.cpp:58 zrcolagui.cpp:1025
|
||||
#, fuzzy
|
||||
msgid "Context"
|
||||
msgstr "Konnte den Kontext auf dem überlagerten Fenster nicht initialisieren."
|
||||
|
||||
#: zrcolachrreq.cpp:64 zrcolagui.h:363
|
||||
msgid "Request a New Character"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolachrslct.cpp:46 zrcolachrslct.cpp:226 zrcolachrslct.cpp:677
|
||||
msgid "▸ Search Options"
|
||||
msgstr ""
|
||||
|
||||
# Recitation separator
|
||||
#: zrcolachrslct.cpp:164
|
||||
#, fuzzy
|
||||
msgid ", "
|
||||
msgstr ", "
|
||||
|
||||
#: zrcolachrslct.cpp:229 zrcolachrslct.cpp:674
|
||||
msgid "▾ Search Options"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolafrm.cpp:141
|
||||
msgid ""
|
||||
"ZRCola keyboard shortcut Win+F5 could not be registered. Some functionality "
|
||||
"will not be available."
|
||||
msgstr ""
|
||||
|
||||
#: zrcolafrm.cpp:108 zrcolafrm.cpp:110
|
||||
#: zrcolafrm.cpp:141 zrcolafrm.cpp:143
|
||||
#, fuzzy
|
||||
msgid "Warning"
|
||||
msgstr "Warnung: "
|
||||
|
||||
#: zrcolafrm.cpp:110
|
||||
#: zrcolafrm.cpp:143
|
||||
msgid ""
|
||||
"ZRCola keyboard shortcut Win+F6 could not be registered. Some functionality "
|
||||
"will not be available."
|
||||
msgstr ""
|
||||
|
||||
#: zrcolafrm.cpp:336
|
||||
msgid "http://zrcola-2.amebis.si/en/contact/"
|
||||
#: zrcolafrm.cpp:351
|
||||
msgid "http://zrcola.zrc-sazu.si/en/info/instructions/"
|
||||
msgstr "http://zrcola.zrc-sazu.si/de/info/instructions/"
|
||||
|
||||
#: zrcolafrm.cpp:375
|
||||
msgid ""
|
||||
"http://zrcola.zrc-sazu.si/wp-content/uploads/2016/06/"
|
||||
"ZRCola_tipkovnica_Jun2016.pdf"
|
||||
msgstr ""
|
||||
"http://zrcola.zrc-sazu.si/wp-content/uploads/2016/06/"
|
||||
"ZRCola_tipkovnica_Jun2016.pdf"
|
||||
|
||||
#: zrcolagui.cpp:36
|
||||
msgid "E&xit"
|
||||
@@ -66,7 +101,7 @@ msgstr "Dieses Programm beenden"
|
||||
#: zrcolagui.cpp:39
|
||||
#, fuzzy
|
||||
msgid "&Program"
|
||||
msgstr "Konnte das Hildon Programm nicht initialisieren"
|
||||
msgstr "Samodejno zaženi ta program ob prijavi"
|
||||
|
||||
#: zrcolagui.cpp:72
|
||||
#, fuzzy
|
||||
@@ -78,26 +113,29 @@ msgid "Select all text"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:78
|
||||
msgid "C&haracter Selector..."
|
||||
msgstr ""
|
||||
#, fuzzy
|
||||
msgid "Find C&haracter..."
|
||||
msgstr "Eingabe eines Zeichenstils"
|
||||
|
||||
#: zrcolagui.cpp:78 zrcolagui.cpp:170
|
||||
msgid "Display character selector to select character to insert into text"
|
||||
#: zrcolagui.cpp:78 zrcolagui.cpp:180
|
||||
msgid "Display character search to select character to insert into text"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:89
|
||||
#, fuzzy
|
||||
msgid "&Send Composed"
|
||||
msgstr ""
|
||||
msgstr "Pošlji sestavljeno (F5)"
|
||||
|
||||
#: zrcolagui.cpp:89 zrcolagui.cpp:172
|
||||
#: zrcolagui.cpp:89 zrcolagui.cpp:182
|
||||
msgid "Send composed text to source window"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:98
|
||||
#, fuzzy
|
||||
msgid "Send &Decomposed"
|
||||
msgstr ""
|
||||
msgstr "Pošlji razstavljeno (F6)"
|
||||
|
||||
#: zrcolagui.cpp:98 zrcolagui.cpp:174
|
||||
#: zrcolagui.cpp:98 zrcolagui.cpp:184
|
||||
msgid "Send decomposed text to source window"
|
||||
msgstr ""
|
||||
|
||||
@@ -152,184 +190,380 @@ msgid "&View"
|
||||
msgstr "&Ansicht..."
|
||||
|
||||
#: zrcolagui.cpp:142
|
||||
msgid "&Request a new character..."
|
||||
msgid "&Instructions..."
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:142
|
||||
msgid "Open a web site with product instructions"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:146
|
||||
msgid "Keyboard &Shortcuts..."
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:146
|
||||
msgid "Open a list of keyboard shortcuts"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:152
|
||||
msgid "&Request a new character..."
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:152
|
||||
msgid "Submit a request to ZRC to add a new character"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:146
|
||||
#: zrcolagui.cpp:156
|
||||
msgid "Check for &Updates..."
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:146
|
||||
#: zrcolagui.cpp:156
|
||||
msgid "Check online for product update"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:155
|
||||
#: zrcolagui.cpp:162
|
||||
msgid "&About..."
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:165
|
||||
#, fuzzy
|
||||
msgid "&Help"
|
||||
msgstr "&Hilfe"
|
||||
|
||||
#: zrcolagui.cpp:160
|
||||
#: zrcolagui.cpp:170
|
||||
#, fuzzy
|
||||
msgid "Cut"
|
||||
msgstr "Ausschneiden"
|
||||
|
||||
#: zrcolagui.cpp:160
|
||||
#: zrcolagui.cpp:170
|
||||
#, fuzzy
|
||||
msgid "Cut selection"
|
||||
msgstr "Auswahl ausschneiden"
|
||||
|
||||
#: zrcolagui.cpp:162
|
||||
#: zrcolagui.cpp:172
|
||||
#, fuzzy
|
||||
msgid "Copy"
|
||||
msgstr "Kopieren"
|
||||
|
||||
#: zrcolagui.cpp:162
|
||||
#: zrcolagui.cpp:172
|
||||
#, fuzzy
|
||||
msgid "Copy selection"
|
||||
msgstr "Auswahl kopieren"
|
||||
|
||||
#: zrcolagui.cpp:164
|
||||
#: zrcolagui.cpp:174
|
||||
#, fuzzy
|
||||
msgid "Paste"
|
||||
msgstr "Einfügen"
|
||||
|
||||
#: zrcolagui.cpp:164
|
||||
#: zrcolagui.cpp:174
|
||||
#, fuzzy
|
||||
msgid "Paste selection"
|
||||
msgstr "Auswahl einfügen"
|
||||
|
||||
#: zrcolagui.cpp:167
|
||||
#: zrcolagui.cpp:177
|
||||
#, fuzzy
|
||||
msgid "Edit"
|
||||
msgstr "Bearbeiten"
|
||||
|
||||
#: zrcolagui.cpp:170 zrcolagui.h:225
|
||||
msgid "Character Selector"
|
||||
msgstr ""
|
||||
#: zrcolagui.cpp:180
|
||||
#, fuzzy
|
||||
msgid "Find Character"
|
||||
msgstr "Eingabe eines Zeichenstils"
|
||||
|
||||
#: zrcolagui.cpp:172
|
||||
#: zrcolagui.cpp:182
|
||||
#, fuzzy
|
||||
msgid "Send Composed"
|
||||
msgstr ""
|
||||
msgstr "Pošlji sestavljeno (F5)"
|
||||
|
||||
#: zrcolagui.cpp:174
|
||||
#: zrcolagui.cpp:184
|
||||
#, fuzzy
|
||||
msgid "Send Decomposed"
|
||||
msgstr ""
|
||||
msgstr "Pošlji razstavljeno (F6)"
|
||||
|
||||
#: zrcolagui.cpp:177
|
||||
#: zrcolagui.cpp:187
|
||||
msgid "Compose"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:181
|
||||
#: zrcolagui.cpp:191
|
||||
msgid "Character Catalog"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:185
|
||||
#: zrcolagui.cpp:195
|
||||
msgid "(De)Composer"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:222
|
||||
#: zrcolagui.cpp:234
|
||||
msgid "Decomposed Text"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:242
|
||||
#: zrcolagui.cpp:254
|
||||
msgid "Decomposed Unicode Dump"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:269
|
||||
#: zrcolagui.cpp:281
|
||||
msgid "Composed Text"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:289
|
||||
#: zrcolagui.cpp:301
|
||||
msgid "Composed Unicode Dump"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:409
|
||||
#: zrcolagui.cpp:355
|
||||
msgid "Select category to display"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:389
|
||||
#, fuzzy
|
||||
msgid "Show &All"
|
||||
msgstr "Alles zeigen"
|
||||
|
||||
#: zrcolagui.cpp:390
|
||||
msgid "Toggle display of less frequent characters"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:430
|
||||
#, fuzzy
|
||||
msgid "&Browse"
|
||||
msgstr "Durchsuchen"
|
||||
|
||||
#: zrcolagui.cpp:457
|
||||
#: zrcolagui.cpp:437
|
||||
msgid ""
|
||||
"Full or partial terms from Unicode character description (in English) to "
|
||||
"search for"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:441
|
||||
msgid "Search Options"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:442
|
||||
msgid "Shows/hides additional search options"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:454
|
||||
msgid "List of Unicode character categories to search in"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:461
|
||||
#, fuzzy
|
||||
msgid "All"
|
||||
msgstr "Alle"
|
||||
|
||||
#: zrcolagui.cpp:462
|
||||
msgid "Select all categories"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:466
|
||||
#, fuzzy
|
||||
msgid "None"
|
||||
msgstr "Kein"
|
||||
|
||||
#: zrcolagui.cpp:467
|
||||
#, fuzzy
|
||||
msgid "Clear category selection"
|
||||
msgstr "Auswahl kopieren"
|
||||
|
||||
#: zrcolagui.cpp:471
|
||||
msgid "Invert"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:472
|
||||
#, fuzzy
|
||||
msgid "Invert category selection"
|
||||
msgstr "Auswahl einfügen"
|
||||
|
||||
#: zrcolagui.cpp:511
|
||||
#, fuzzy
|
||||
msgid "Character search results"
|
||||
msgstr "Skupine &znakov"
|
||||
|
||||
#: zrcolagui.cpp:521
|
||||
msgid "Re¢ly Used"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:498
|
||||
#: zrcolagui.cpp:549
|
||||
msgid "List of recently inserted characters"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:563
|
||||
#, fuzzy
|
||||
msgid "Preview"
|
||||
msgstr " Vorschau"
|
||||
|
||||
#: zrcolagui.cpp:503
|
||||
#, fuzzy
|
||||
#: zrcolagui.cpp:568
|
||||
msgid "U+"
|
||||
msgstr "Hilfeverzeichnis %u nicht gefunden."
|
||||
msgstr "U+"
|
||||
|
||||
#: zrcolagui.cpp:554
|
||||
msgid "Re&lated"
|
||||
#: zrcolagui.cpp:573
|
||||
msgid "Unicode hexadecimal code"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:578
|
||||
msgid "Keyboard shortcut in Composer window"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:613
|
||||
#, fuzzy
|
||||
msgid "Character preview"
|
||||
msgstr "Skupine &znakov"
|
||||
|
||||
#: zrcolagui.cpp:618
|
||||
msgid "Unicode character description"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:623
|
||||
#, fuzzy
|
||||
msgid "Character tags"
|
||||
msgstr "Eingabe eines Zeichenstils"
|
||||
|
||||
#: zrcolagui.cpp:628
|
||||
msgid "Unicode character category"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:635
|
||||
#, fuzzy
|
||||
msgid "« Back"
|
||||
msgstr "< &Zurück"
|
||||
|
||||
#: zrcolagui.cpp:637
|
||||
msgid "To previously viewed character"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:641
|
||||
#, fuzzy
|
||||
msgid "Forward »"
|
||||
msgstr "&Vorwärts"
|
||||
|
||||
#: zrcolagui.cpp:643
|
||||
msgid "To following viewed character"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:654
|
||||
msgid "Re&lated"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:681
|
||||
msgid "List of related characters"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:770
|
||||
msgid ""
|
||||
"Some character native to specific language you are working with should not "
|
||||
"decompose to primitives.\n"
|
||||
"For optimal decomposition you should set the language correctly."
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:658
|
||||
#: zrcolagui.cpp:774
|
||||
msgid "Select language &automatically according to selected keyboard"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:661
|
||||
#: zrcolagui.cpp:777
|
||||
msgid "&Manually select the language from the list below:"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:673
|
||||
#: zrcolagui.cpp:789
|
||||
msgid "Text Language"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:678
|
||||
#: zrcolagui.cpp:794
|
||||
msgid ""
|
||||
"ZRCola can be launched every time you log in to your computer.\n"
|
||||
"It will be available on the system tray and via registered shortcuts Win+F5 "
|
||||
"and Win+F6."
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:682
|
||||
#: zrcolagui.cpp:798
|
||||
msgid "Start ZRCola &automatically on logon"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:689
|
||||
#: zrcolagui.cpp:805
|
||||
msgid "Startup"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:768
|
||||
#: zrcolagui.cpp:885
|
||||
msgid ""
|
||||
"Editor: Janoš Ježovnik\n"
|
||||
"Development: Amebis d. o. o.\n"
|
||||
"Development and maintenance (2004-2015): dr. Peter Weiss"
|
||||
"Program and Website Editor: Janoš Ježovnik\n"
|
||||
"Development: Amebis, d. o. o., Kamnik\n"
|
||||
"Translation into English: Janoš Ježovnik\n"
|
||||
"Translation into Russian language: Domen Krvina, Silvo Torkar, Anastasia "
|
||||
"Plotnikova\n"
|
||||
"Development and maintenance of the original program (2004–2015): Peter Weiss"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:776
|
||||
msgid "www.zrc-sazu.si"
|
||||
#: zrcolagui.cpp:893
|
||||
msgid "zrcola.zrc-sazu.si"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:815
|
||||
#: zrcolagui.cpp:899
|
||||
msgid ""
|
||||
"Texts made using ZRCola have to include in a footnote or some other "
|
||||
"appropriate part of the publication the note below:"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:903
|
||||
msgid ""
|
||||
"This text was written using the ZRCola input system (http://zrcola.zrc-sazu."
|
||||
"si), developed at the Science and Research Centre of SAZU in Ljubljana "
|
||||
"(http://www.zrc-sazu.si) by Peter Weiss."
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:944
|
||||
#, fuzzy
|
||||
msgid "Log"
|
||||
msgstr "&Log"
|
||||
|
||||
#: zrcolagui.cpp:831
|
||||
#: zrcolagui.cpp:960
|
||||
#, fuzzy
|
||||
msgid "&Update"
|
||||
msgid "Quit and &Update..."
|
||||
msgstr "Kann Benutzer-Konfigurationsdatei nicht aktualisieren."
|
||||
|
||||
#: zrcolagui.cpp:836
|
||||
#: zrcolagui.cpp:962
|
||||
msgid "Exit this program and launch product update"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:966
|
||||
#, fuzzy
|
||||
msgid "&Close"
|
||||
msgstr "&Schließen"
|
||||
|
||||
#: zrcolagui.cpp:967
|
||||
#, fuzzy
|
||||
msgid "Close this window"
|
||||
msgstr "Fenster schließen"
|
||||
|
||||
#: zrcolagui.cpp:1006
|
||||
msgid "Enter the &character you would like to request:"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:1013
|
||||
msgid "Decomposed character to request"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:1017
|
||||
msgid ""
|
||||
"Please, use the decomposed form.\n"
|
||||
"You can use ZRCola keyboard shortcuts to enter the character or Copy&&Paste "
|
||||
"it from the Decomposed window."
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:1027
|
||||
msgid ""
|
||||
"The &context, examples or description why and where the character is "
|
||||
"required:"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:1033
|
||||
msgid "Additional notes for character request"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:1040
|
||||
msgid ""
|
||||
"After clicking OK button, your e-mail application should open allowing you "
|
||||
"to submit the new character request to ZRCola Editor.\n"
|
||||
"Your e-mail application might not display all the characters correctly, but "
|
||||
"the Editor will be able to read them correctly anyway."
|
||||
msgstr ""
|
||||
|
||||
#: zrcolakeyhndlr.cpp:44
|
||||
msgid ""
|
||||
"INS key is pressed. Type the Unicode code of desired character now (up to "
|
||||
@@ -340,286 +574,148 @@ msgstr ""
|
||||
msgid "Start ZRCola automatically on logon"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.h:262
|
||||
msgid "Settings"
|
||||
#: zrcolaupdater.cpp:94
|
||||
msgid ""
|
||||
"This program will now close and the upgrade will be launched.\n"
|
||||
"Are you sure?"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.h:286
|
||||
msgid "About ZRCola"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.h:309
|
||||
#: zrcolaupdater.cpp:94 zrcolagui.h:334
|
||||
msgid "Product Update"
|
||||
msgstr ""
|
||||
|
||||
# Windows charset for this language (decimal)
|
||||
#: MSIBuild/En.Win32.Debug.Feature-2.idtx:3
|
||||
#: MSIBuild/En.Win32.Debug.Shortcut-2.idtx:3
|
||||
#: MSIBuild/En.Win32.Release.Feature-2.idtx:3
|
||||
#: MSIBuild/En.Win32.Release.Shortcut-2.idtx:3
|
||||
#: MSIBuild/En.x64.Debug.Feature-2.idtx:3
|
||||
#: MSIBuild/En.x64.Debug.Shortcut-2.idtx:3
|
||||
#: MSIBuild/En.x64.Release.Feature-2.idtx:3
|
||||
#: MSIBuild/En.x64.Release.Shortcut-2.idtx:3
|
||||
#: zrcolagui.h:246
|
||||
#, fuzzy
|
||||
msgid "1252"
|
||||
msgstr "1252"
|
||||
msgid "Character Search"
|
||||
msgstr "Skupine &znakov"
|
||||
|
||||
#: MSIBuild/En.Win32.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/En.Win32.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/En.Win32.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/En.Win32.Release.Shortcut-2.idtx:4
|
||||
#: MSIBuild/En.x64.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/En.x64.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/En.x64.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/En.x64.Release.Shortcut-2.idtx:4
|
||||
msgid "Input system for linguistic use"
|
||||
#: zrcolagui.h:283
|
||||
msgid "Settings"
|
||||
msgstr ""
|
||||
|
||||
#~ msgid "Auto Start"
|
||||
#~ msgstr "Samodejni zagon"
|
||||
|
||||
#~ msgid "Select %s language for decomposition"
|
||||
#~ msgstr "Izberi jezik %s za razstavljanje"
|
||||
|
||||
#~ msgid "&Start on Logon"
|
||||
#~ msgstr "Z&aženi ob prijavi"
|
||||
|
||||
#~ msgid "Start this program automatically on logon"
|
||||
#~ msgstr "Samodejno zaženi ta program ob prijavi"
|
||||
|
||||
#~ msgid "Set language according to keyboard layout automatically"
|
||||
#~ msgstr "Samodejno nastavi jezik glede na izbrano tipkovnico"
|
||||
|
||||
#~ msgid "&Unicode"
|
||||
#~ msgstr "&Unicode"
|
||||
|
||||
#~ msgid "Esc"
|
||||
#~ msgstr "Esc"
|
||||
|
||||
#~ msgid "F1"
|
||||
#~ msgstr "F1"
|
||||
|
||||
#~ msgid "F2"
|
||||
#~ msgstr "F2"
|
||||
|
||||
#~ msgid "F3"
|
||||
#~ msgstr "F3"
|
||||
|
||||
#~ msgid "F4"
|
||||
#~ msgstr "F4"
|
||||
|
||||
#~ msgid "F5"
|
||||
#~ msgstr "F5"
|
||||
|
||||
#~ msgid "F6"
|
||||
#~ msgstr "F6"
|
||||
|
||||
#~ msgid "F7"
|
||||
#~ msgstr "F7"
|
||||
|
||||
#~ msgid "F8"
|
||||
#~ msgstr "F8"
|
||||
|
||||
#~ msgid "F9"
|
||||
#~ msgstr "F9"
|
||||
|
||||
#~ msgid "F10"
|
||||
#~ msgstr "F10"
|
||||
|
||||
#~ msgid "F11"
|
||||
#~ msgstr "F11"
|
||||
|
||||
#~ msgid "F12"
|
||||
#~ msgstr "F12"
|
||||
|
||||
#~ msgid "Print Screen"
|
||||
#~ msgstr "Print Screen"
|
||||
|
||||
#~ msgid "Scroll Lock"
|
||||
#~ msgstr "Scroll Lock"
|
||||
|
||||
#~ msgid "Pause"
|
||||
#~ msgstr "Pause"
|
||||
|
||||
#~ msgid "Backspace"
|
||||
#~ msgstr "Backspace"
|
||||
|
||||
#~ msgid "Tab"
|
||||
#~ msgstr "Tab"
|
||||
|
||||
#~ msgid "Caps Lock"
|
||||
#~ msgstr "Caps Lock"
|
||||
|
||||
#~ msgid "Return"
|
||||
#~ msgstr "Return"
|
||||
|
||||
#~ msgid "Space"
|
||||
#~ msgstr "preslednica"
|
||||
|
||||
#~ msgid "Shift"
|
||||
#~ msgstr "Shift"
|
||||
|
||||
#~ msgid "Alt"
|
||||
#~ msgstr "Alt"
|
||||
|
||||
#~ msgid "Ctrl"
|
||||
#~ msgstr "Ctrl"
|
||||
|
||||
#~ msgid "Menu"
|
||||
#~ msgstr "Menu"
|
||||
|
||||
#~ msgid "Insert"
|
||||
#~ msgstr "Insert"
|
||||
|
||||
#~ msgid "Delete"
|
||||
#~ msgstr "Delete"
|
||||
|
||||
#~ msgid "Page Up"
|
||||
#~ msgstr "Page Up"
|
||||
|
||||
#~ msgid "Page Down"
|
||||
#~ msgstr "Page Down"
|
||||
|
||||
#~ msgid "Home"
|
||||
#~ msgstr "Home"
|
||||
|
||||
#~ msgid "End"
|
||||
#~ msgstr "End"
|
||||
|
||||
#~ msgid "Left"
|
||||
#~ msgstr "Left"
|
||||
|
||||
#~ msgid "Up"
|
||||
#~ msgstr "Up"
|
||||
|
||||
#~ msgid "Right"
|
||||
#~ msgstr "Right"
|
||||
|
||||
#~ msgid "Down"
|
||||
#~ msgstr "Down"
|
||||
|
||||
#~ msgid "Num Lock"
|
||||
#~ msgstr "Num Lock"
|
||||
|
||||
#~ msgid "`"
|
||||
#~ msgstr "`"
|
||||
|
||||
#~ msgid "-"
|
||||
#~ msgstr "-"
|
||||
|
||||
#~ msgid "["
|
||||
#~ msgstr "["
|
||||
|
||||
#~ msgid "]"
|
||||
#~ msgstr "]"
|
||||
|
||||
#~ msgid ":"
|
||||
#~ msgstr ":"
|
||||
|
||||
#~ msgid "'"
|
||||
#~ msgstr "'"
|
||||
|
||||
#~ msgid "\\"
|
||||
#~ msgstr "\\"
|
||||
|
||||
#~ msgid ","
|
||||
#~ msgstr ","
|
||||
|
||||
#~ msgid "."
|
||||
#~ msgstr "."
|
||||
|
||||
#~ msgid "/"
|
||||
#~ msgstr "/"
|
||||
|
||||
#~ msgid "INS"
|
||||
#~ msgstr "INS"
|
||||
|
||||
#~ msgid "Character &Groups"
|
||||
#~ msgstr "Skupine &znakov"
|
||||
|
||||
#~ msgid "Language:"
|
||||
#~ msgstr "Jezik:"
|
||||
|
||||
#~ msgid "&About"
|
||||
#~ msgstr "O progr&amu"
|
||||
|
||||
#~ msgid "Cuts selected text and puts it on the clipboard"
|
||||
#~ msgstr "Izreže izbrano besedilo in ga shrani na odložišče"
|
||||
|
||||
#~ msgid "Copies selected text to the clipboard"
|
||||
#~ msgstr "Kopira izbrano besedilo na odložišče"
|
||||
|
||||
#~ msgid "Inserts text from the clipboard"
|
||||
#~ msgstr "Vstavi besedilo z odložišča"
|
||||
|
||||
#~ msgid "&Copy"
|
||||
#~ msgstr "&Kopiraj"
|
||||
|
||||
#~ msgid "&Paste"
|
||||
#~ msgstr "&Prilepi"
|
||||
|
||||
#~ msgid "&File"
|
||||
#~ msgstr "&Datoteka"
|
||||
|
||||
#~ msgid "Send Decomposed (F6)"
|
||||
#~ msgstr "Pošlji razstavljeno (F6)"
|
||||
|
||||
#~ msgid "Send Composed (F5)"
|
||||
#~ msgstr "Pošlji sestavljeno (F5)"
|
||||
|
||||
#~ msgid ""
|
||||
#~ "ZRCola keyboard shortcut Win+Shift+Z could not be registered. Some "
|
||||
#~ "functionality will not be available."
|
||||
#~ msgstr ""
|
||||
#~ "ZRColine bližnjice na tipkovnici Win+Shift+Z ni mogoče registrirati. "
|
||||
#~ "Nekaj funkcionalnosti ne bo na voljo."
|
||||
|
||||
#: zrcolagui.h:309
|
||||
msgid "About ZRCola"
|
||||
msgstr ""
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:10
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:15
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:10
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:15
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:10
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:15
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:10
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:15
|
||||
msgid "binUIHeader.bmp"
|
||||
msgstr "binUIHeader.bmp"
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:5
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:5
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:5
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:5
|
||||
msgid "[DlgTitleFont][SimpleProductName] Tutorial : Starting"
|
||||
msgstr ""
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:6
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:6
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:6
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:6
|
||||
msgid "bintutorial1.bmp"
|
||||
msgstr "bintutorial1.bmp"
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:7
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:7
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:7
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:7
|
||||
msgid ""
|
||||
"When configured, ZRCola starts at system startup and runs in the background. "
|
||||
"If needed, it can be brought up by pressing the combination Win+F5."
|
||||
msgstr ""
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:8
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:8
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:8
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:8
|
||||
msgid ""
|
||||
"IMPORTANT: Upon pressing the combination Win+F5 the program memorises the "
|
||||
"location of the cursor in the text. If ZRCola is brought to the foreground "
|
||||
"without using the aforementioned combination of keys, the program won't know "
|
||||
"where to insert the special characters!"
|
||||
msgstr ""
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:9
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:14
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:19
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:9
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:14
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:19
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:9
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:14
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:19
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:9
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:14
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:19
|
||||
#, fuzzy
|
||||
#~ msgid "Authentication progress real time monitor"
|
||||
#~ msgstr "Nadzira postopek overovljanja v realnem času"
|
||||
msgid "&Continue"
|
||||
msgstr "Konnte den Kontext auf dem überlagerten Fenster nicht initialisieren."
|
||||
|
||||
#~ msgid "Grave\t&7"
|
||||
#~ msgstr "Krativec\t&7"
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:11
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:11
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:11
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:11
|
||||
msgid "[DlgTitleFont][SimpleProductName] Tutorial : Composition"
|
||||
msgstr ""
|
||||
|
||||
#~ msgid "Acute\t&9"
|
||||
#~ msgstr "Ostrivec\t&9"
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:12
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:12
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:12
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:12
|
||||
msgid "bintutorial2.bmp"
|
||||
msgstr "bintutorial2.bmp"
|
||||
|
||||
#~ msgid "Circumflex\t&3"
|
||||
#~ msgstr "Cirkumfleks\t&3"
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:13
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:13
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:13
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:13
|
||||
msgid ""
|
||||
"The string of basic and substitute characters is entered into the upper "
|
||||
"input window of the program. In the window below the resulted special "
|
||||
"characters are displayed. To insert them in the text, the F5 key is used."
|
||||
msgstr ""
|
||||
|
||||
#~ msgid "Inverted &breve"
|
||||
#~ msgstr "O&brnjen polkrog"
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:16
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:16
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:16
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:16
|
||||
msgid "[DlgTitleFont][SimpleProductName] Tutorial : Entering Characters"
|
||||
msgstr ""
|
||||
|
||||
#~ msgid "&Accents"
|
||||
#~ msgstr "N&aglasi"
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:17
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:17
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:17
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:17
|
||||
msgid "bintutorial3.bmp"
|
||||
msgstr "bintutorial3.bmp"
|
||||
|
||||
#~ msgid ""
|
||||
#~ "There is already an auto hidden bar on this edge.\n"
|
||||
#~ "Only one auto hidden bar is allowed on each edge.\n"
|
||||
#~ "Auto-hide feature is now off."
|
||||
#~ msgstr ""
|
||||
#~ "Ob tem robu je že samodejno skrita pasica.\n"
|
||||
#~ "Na vsakem robu je lahko samo ena samodejno skrita pasica.\n"
|
||||
#~ "Samodejno skrivanje je zdaj izklopljeno."
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:18
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:18
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:18
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:18
|
||||
msgid ""
|
||||
"Characters can be entered using keyboard shortcuts, the character catalogue "
|
||||
"(F4) or the character finding tool (F8)."
|
||||
msgstr ""
|
||||
|
||||
#~ msgid "Hello World"
|
||||
#~ msgstr "Zdravo svet"
|
||||
|
||||
#~ msgid "&Hello...\tCtrl+H"
|
||||
#~ msgstr "&Pozdrav ...\tCtrl+H"
|
||||
|
||||
#~ msgid "Help string shown in status bar for this menu item"
|
||||
#~ msgstr "Niz s pomočjo prikazan v statusni vrstici za to točko menija"
|
||||
|
||||
#~ msgid "This is a wxWidgets' Hello world sample"
|
||||
#~ msgstr "To je primer Zdravo svet v wxWidgets"
|
||||
|
||||
#~ msgid "About Hello World"
|
||||
#~ msgstr "O Zdravo svet"
|
||||
|
||||
#~ msgid "Hello world from wxWidgets!"
|
||||
#~ msgstr "Zdravo svet iz wxWidgets!"
|
||||
|
||||
#~ msgid "Welcome to wxWidgets!"
|
||||
#~ msgstr "Dobrodošli v wxWidgets!"
|
||||
#: MSIBuild/en_US.Win32.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Release.Shortcut-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Release.Shortcut-2.idtx:4
|
||||
msgid "Input system for linguistic use"
|
||||
msgstr ""
|
||||
|
||||
@@ -1,15 +1,15 @@
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: ZRCola\n"
|
||||
"POT-Creation-Date: 2016-05-24 16:27+0200\n"
|
||||
"PO-Revision-Date: 2016-05-24 16:27+0200\n"
|
||||
"POT-Creation-Date: 2016-10-18 10:09+0200\n"
|
||||
"PO-Revision-Date: 2016-10-18 10:10+0200\n"
|
||||
"Last-Translator: Simon Rozman <simon.rozman@amebis.si>\n"
|
||||
"Language-Team: Amebis, d. o. o., Kamnik <info@amebis.si>\n"
|
||||
"Language: ru_RU\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Generator: Poedit 1.8.7\n"
|
||||
"X-Generator: Poedit 1.8.10\n"
|
||||
"X-Poedit-Basepath: .\n"
|
||||
"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
|
||||
"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
|
||||
@@ -19,343 +19,726 @@ msgstr ""
|
||||
#: zrcolaabout.cpp:31
|
||||
#, c-format
|
||||
msgid "© 2004-%s ZRC SAZU"
|
||||
msgstr ""
|
||||
msgstr "© 2004–%s ZRC SAZU"
|
||||
|
||||
#: zrcolaapp.cpp:78 zrcolafrm.cpp:90 zrcolagui.cpp:758 zrcolagui.h:101
|
||||
#: MSIBuild/En.Win32.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/En.Win32.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/En.Win32.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/En.Win32.Release.Shortcut-2.idtx:4
|
||||
#: MSIBuild/En.x64.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/En.x64.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/En.x64.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/En.x64.Release.Shortcut-2.idtx:4
|
||||
#, fuzzy
|
||||
#: zrcolaapp.cpp:71 zrcolafrm.cpp:90 zrcolagui.cpp:874 zrcolagui.h:104
|
||||
#: MSIBuild/en_US.Win32.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Release.Shortcut-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Release.Shortcut-2.idtx:4
|
||||
msgid "ZRCola"
|
||||
msgstr "ZRCola:."
|
||||
msgstr "ZRCola"
|
||||
|
||||
#: zrcolafrm.cpp:108
|
||||
#: zrcolachrreq.cpp:49 zrcolagui.cpp:1004
|
||||
msgid "Character"
|
||||
msgstr "Знак"
|
||||
|
||||
#: zrcolachrreq.cpp:58 zrcolagui.cpp:1025
|
||||
msgid "Context"
|
||||
msgstr "Контекст"
|
||||
|
||||
#: zrcolachrreq.cpp:64 zrcolagui.h:363
|
||||
msgid "Request a New Character"
|
||||
msgstr "Запрос нового знака"
|
||||
|
||||
#: zrcolachrslct.cpp:46 zrcolachrslct.cpp:226 zrcolachrslct.cpp:677
|
||||
msgid "▸ Search Options"
|
||||
msgstr "▸ Опции поиска"
|
||||
|
||||
# Recitation separator
|
||||
#: zrcolachrslct.cpp:164
|
||||
msgid ", "
|
||||
msgstr ", "
|
||||
|
||||
#: zrcolachrslct.cpp:229 zrcolachrslct.cpp:674
|
||||
msgid "▾ Search Options"
|
||||
msgstr "▾ Опции поиска"
|
||||
|
||||
#: zrcolafrm.cpp:141
|
||||
msgid ""
|
||||
"ZRCola keyboard shortcut Win+F5 could not be registered. Some functionality "
|
||||
"will not be available."
|
||||
msgstr ""
|
||||
"Сочетание клавиш Win+F5 \n"
|
||||
"регистрировать. Некоторые функциональности не будут доступны."
|
||||
|
||||
#: zrcolafrm.cpp:108 zrcolafrm.cpp:110
|
||||
#: zrcolafrm.cpp:141 zrcolafrm.cpp:143
|
||||
msgid "Warning"
|
||||
msgstr ""
|
||||
msgstr "Предупреждение"
|
||||
|
||||
#: zrcolafrm.cpp:110
|
||||
#: zrcolafrm.cpp:143
|
||||
msgid ""
|
||||
"ZRCola keyboard shortcut Win+F6 could not be registered. Some functionality "
|
||||
"will not be available."
|
||||
msgstr ""
|
||||
"Сочетание клавиш Win+F6 невозможно регистрировать. Некоторые "
|
||||
"функциональности не будут доступны."
|
||||
|
||||
#: zrcolafrm.cpp:336
|
||||
msgid "http://zrcola-2.amebis.si/en/contact/"
|
||||
#: zrcolafrm.cpp:351
|
||||
msgid "http://zrcola.zrc-sazu.si/en/info/instructions/"
|
||||
msgstr "http://zrcola.zrc-sazu.si/ru/info/instructions/"
|
||||
|
||||
#: zrcolafrm.cpp:375
|
||||
msgid ""
|
||||
"http://zrcola.zrc-sazu.si/wp-content/uploads/2016/06/"
|
||||
"ZRCola_tipkovnica_Jun2016.pdf"
|
||||
msgstr ""
|
||||
"http://zrcola.zrc-sazu.si/wp-content/uploads/2016/06/"
|
||||
"ZRCola_tipkovnica_Jun2016.pdf"
|
||||
|
||||
#: zrcolagui.cpp:36
|
||||
msgid "E&xit"
|
||||
msgstr ""
|
||||
msgstr "Вы&ход"
|
||||
|
||||
#: zrcolagui.cpp:36
|
||||
msgid "Quit this program"
|
||||
msgstr ""
|
||||
msgstr "Выйти из программы"
|
||||
|
||||
#: zrcolagui.cpp:39
|
||||
msgid "&Program"
|
||||
msgstr ""
|
||||
msgstr "П&рограмма"
|
||||
|
||||
#: zrcolagui.cpp:72
|
||||
msgid "Select &All"
|
||||
msgstr ""
|
||||
msgstr "Выделить в&се"
|
||||
|
||||
#: zrcolagui.cpp:72
|
||||
msgid "Select all text"
|
||||
msgstr ""
|
||||
msgstr "Выделить весь текст"
|
||||
|
||||
#: zrcolagui.cpp:78
|
||||
msgid "C&haracter Selector..."
|
||||
msgstr ""
|
||||
msgid "Find C&haracter..."
|
||||
msgstr "Поиск &знака ..."
|
||||
|
||||
#: zrcolagui.cpp:78 zrcolagui.cpp:170
|
||||
msgid "Display character selector to select character to insert into text"
|
||||
msgstr ""
|
||||
#: zrcolagui.cpp:78 zrcolagui.cpp:180
|
||||
msgid "Display character search to select character to insert into text"
|
||||
msgstr "Показать браузер знаков для вставления выбранного знака"
|
||||
|
||||
#: zrcolagui.cpp:89
|
||||
msgid "&Send Composed"
|
||||
msgstr ""
|
||||
msgstr "&Послать составленное"
|
||||
|
||||
#: zrcolagui.cpp:89 zrcolagui.cpp:172
|
||||
#: zrcolagui.cpp:89 zrcolagui.cpp:182
|
||||
msgid "Send composed text to source window"
|
||||
msgstr ""
|
||||
msgstr "Послать составленный текст в исходное окно"
|
||||
|
||||
#: zrcolagui.cpp:98
|
||||
msgid "Send &Decomposed"
|
||||
msgstr ""
|
||||
msgstr "Послать &разобранное"
|
||||
|
||||
#: zrcolagui.cpp:98 zrcolagui.cpp:174
|
||||
#: zrcolagui.cpp:98 zrcolagui.cpp:184
|
||||
msgid "Send decomposed text to source window"
|
||||
msgstr ""
|
||||
msgstr "Послать разобранный текст в исходное окно"
|
||||
|
||||
#: zrcolagui.cpp:107
|
||||
msgid "Abort (De)composition"
|
||||
msgstr ""
|
||||
msgstr "Прервать составление/разборку"
|
||||
|
||||
#: zrcolagui.cpp:107
|
||||
msgid "Abort composition and return focus to source window"
|
||||
msgstr ""
|
||||
msgstr "Прервать составление и возвратить фокус в исходное окно"
|
||||
|
||||
#: zrcolagui.cpp:118
|
||||
msgid "&Settings..."
|
||||
msgstr ""
|
||||
msgstr "&Настройки ..."
|
||||
|
||||
#: zrcolagui.cpp:118
|
||||
msgid "Open program configuration dialog"
|
||||
msgstr ""
|
||||
msgstr "Открыть диалог конфигурации программы"
|
||||
|
||||
#: zrcolagui.cpp:121
|
||||
msgid "&Edit"
|
||||
msgstr ""
|
||||
msgstr "&Правка"
|
||||
|
||||
#: zrcolagui.cpp:125
|
||||
msgid "&Edit Toolbar"
|
||||
msgstr ""
|
||||
msgstr "Панель инструментов для &правки"
|
||||
|
||||
#: zrcolagui.cpp:125
|
||||
msgid "Toggle edit toolbar"
|
||||
msgstr ""
|
||||
msgstr "Переключить панель инструментов для правки"
|
||||
|
||||
#: zrcolagui.cpp:129
|
||||
msgid "&Compose Toolbar"
|
||||
msgstr ""
|
||||
msgstr "Панель инструментов для &составления"
|
||||
|
||||
#: zrcolagui.cpp:129
|
||||
msgid "Toggle compose toolbar"
|
||||
msgstr ""
|
||||
msgstr "Переключить панель инструментов для составления"
|
||||
|
||||
#: zrcolagui.cpp:135
|
||||
msgid "Character Catalo&g"
|
||||
msgstr ""
|
||||
msgstr "Список &знаков"
|
||||
|
||||
#: zrcolagui.cpp:135
|
||||
msgid "Toggle character catalog panel"
|
||||
msgstr ""
|
||||
msgstr "Переключить список знаков"
|
||||
|
||||
#: zrcolagui.cpp:138
|
||||
msgid "&View"
|
||||
msgstr ""
|
||||
msgstr "&Вид"
|
||||
|
||||
#: zrcolagui.cpp:142
|
||||
msgid "&Instructions..."
|
||||
msgstr "&Инструкции ..."
|
||||
|
||||
#: zrcolagui.cpp:142
|
||||
msgid "Open a web site with product instructions"
|
||||
msgstr "Открыть сайт с инструкциями по продукту"
|
||||
|
||||
#: zrcolagui.cpp:146
|
||||
msgid "Keyboard &Shortcuts..."
|
||||
msgstr "Сочетания &клавиш ..."
|
||||
|
||||
#: zrcolagui.cpp:146
|
||||
msgid "Open a list of keyboard shortcuts"
|
||||
msgstr "Открыть список сочетаний клавиш"
|
||||
|
||||
#: zrcolagui.cpp:152
|
||||
msgid "&Request a new character..."
|
||||
msgstr ""
|
||||
msgstr "&Запрос нового знака ..."
|
||||
|
||||
#: zrcolagui.cpp:142
|
||||
#: zrcolagui.cpp:152
|
||||
msgid "Submit a request to ZRC to add a new character"
|
||||
msgstr ""
|
||||
msgstr "Отправить запрос нового знака"
|
||||
|
||||
#: zrcolagui.cpp:146
|
||||
#: zrcolagui.cpp:156
|
||||
msgid "Check for &Updates..."
|
||||
msgstr ""
|
||||
msgstr "Проверить наличие &обновлений ..."
|
||||
|
||||
#: zrcolagui.cpp:146
|
||||
#: zrcolagui.cpp:156
|
||||
msgid "Check online for product update"
|
||||
msgstr ""
|
||||
msgstr "Проверить наличие обновлений онлайн"
|
||||
|
||||
#: zrcolagui.cpp:155
|
||||
#: zrcolagui.cpp:162
|
||||
msgid "&About..."
|
||||
msgstr "О прогр&амме ..."
|
||||
|
||||
#: zrcolagui.cpp:165
|
||||
msgid "&Help"
|
||||
msgstr ""
|
||||
msgstr "&Справка"
|
||||
|
||||
#: zrcolagui.cpp:160
|
||||
#: zrcolagui.cpp:170
|
||||
msgid "Cut"
|
||||
msgstr ""
|
||||
msgstr "Вырезать"
|
||||
|
||||
#: zrcolagui.cpp:160
|
||||
#: zrcolagui.cpp:170
|
||||
msgid "Cut selection"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:162
|
||||
msgid "Copy"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:162
|
||||
msgid "Copy selection"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:164
|
||||
msgid "Paste"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:164
|
||||
msgid "Paste selection"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:167
|
||||
msgid "Edit"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.cpp:170 zrcolagui.h:225
|
||||
msgid "Character Selector"
|
||||
msgstr ""
|
||||
msgstr "Вырезать выбор"
|
||||
|
||||
#: zrcolagui.cpp:172
|
||||
msgid "Send Composed"
|
||||
msgstr ""
|
||||
msgid "Copy"
|
||||
msgstr "Копировать"
|
||||
|
||||
#: zrcolagui.cpp:172
|
||||
msgid "Copy selection"
|
||||
msgstr "Копировать выбор"
|
||||
|
||||
#: zrcolagui.cpp:174
|
||||
msgid "Send Decomposed"
|
||||
msgstr ""
|
||||
msgid "Paste"
|
||||
msgstr "Вставить"
|
||||
|
||||
#: zrcolagui.cpp:174
|
||||
msgid "Paste selection"
|
||||
msgstr "Вставить выбор"
|
||||
|
||||
#: zrcolagui.cpp:177
|
||||
msgid "Edit"
|
||||
msgstr "Правка"
|
||||
|
||||
#: zrcolagui.cpp:180
|
||||
msgid "Find Character"
|
||||
msgstr "Поиск знака"
|
||||
|
||||
#: zrcolagui.cpp:182
|
||||
msgid "Send Composed"
|
||||
msgstr "Послать составленное (F5)"
|
||||
|
||||
#: zrcolagui.cpp:184
|
||||
msgid "Send Decomposed"
|
||||
msgstr "Послать разобранное (F6)"
|
||||
|
||||
#: zrcolagui.cpp:187
|
||||
msgid "Compose"
|
||||
msgstr ""
|
||||
msgstr "Составить"
|
||||
|
||||
#: zrcolagui.cpp:181
|
||||
#: zrcolagui.cpp:191
|
||||
msgid "Character Catalog"
|
||||
msgstr ""
|
||||
msgstr "Список знаков"
|
||||
|
||||
#: zrcolagui.cpp:185
|
||||
#: zrcolagui.cpp:195
|
||||
msgid "(De)Composer"
|
||||
msgstr ""
|
||||
msgstr "(Де)Композитор"
|
||||
|
||||
#: zrcolagui.cpp:222
|
||||
#: zrcolagui.cpp:234
|
||||
msgid "Decomposed Text"
|
||||
msgstr ""
|
||||
msgstr "Разобранний текст"
|
||||
|
||||
#: zrcolagui.cpp:242
|
||||
#: zrcolagui.cpp:254
|
||||
msgid "Decomposed Unicode Dump"
|
||||
msgstr ""
|
||||
msgstr "Дамп разобранного Юнукода"
|
||||
|
||||
#: zrcolagui.cpp:269
|
||||
#: zrcolagui.cpp:281
|
||||
msgid "Composed Text"
|
||||
msgstr ""
|
||||
msgstr "Составленный текст"
|
||||
|
||||
#: zrcolagui.cpp:289
|
||||
#: zrcolagui.cpp:301
|
||||
msgid "Composed Unicode Dump"
|
||||
msgstr ""
|
||||
msgstr "Дамп составленного Юникода"
|
||||
|
||||
#: zrcolagui.cpp:409
|
||||
#: zrcolagui.cpp:355
|
||||
msgid "Select category to display"
|
||||
msgstr "Выделить категории для отображения"
|
||||
|
||||
#: zrcolagui.cpp:389
|
||||
msgid "Show &All"
|
||||
msgstr "Показать &все"
|
||||
|
||||
#: zrcolagui.cpp:390
|
||||
msgid "Toggle display of less frequent characters"
|
||||
msgstr "Переключить отображение редко использованных знаков"
|
||||
|
||||
#: zrcolagui.cpp:430
|
||||
msgid "&Browse"
|
||||
msgstr ""
|
||||
msgstr "&Обзор"
|
||||
|
||||
#: zrcolagui.cpp:457
|
||||
#: zrcolagui.cpp:437
|
||||
msgid ""
|
||||
"Full or partial terms from Unicode character description (in English) to "
|
||||
"search for"
|
||||
msgstr "Полное либо частичное описание знака Юникод (на английском) для поиска"
|
||||
|
||||
#: zrcolagui.cpp:441
|
||||
msgid "Search Options"
|
||||
msgstr "Опции поиска"
|
||||
|
||||
#: zrcolagui.cpp:442
|
||||
msgid "Shows/hides additional search options"
|
||||
msgstr "Показать/скрыть дополнительные опции поиска"
|
||||
|
||||
#: zrcolagui.cpp:454
|
||||
msgid "List of Unicode character categories to search in"
|
||||
msgstr "Список категории Юникод для проведения поиска"
|
||||
|
||||
#: zrcolagui.cpp:461
|
||||
msgid "All"
|
||||
msgstr "Все"
|
||||
|
||||
#: zrcolagui.cpp:462
|
||||
msgid "Select all categories"
|
||||
msgstr "Выбрать все категории"
|
||||
|
||||
#: zrcolagui.cpp:466
|
||||
msgid "None"
|
||||
msgstr "Ничего"
|
||||
|
||||
#: zrcolagui.cpp:467
|
||||
msgid "Clear category selection"
|
||||
msgstr "Очистить выбор категории"
|
||||
|
||||
#: zrcolagui.cpp:471
|
||||
msgid "Invert"
|
||||
msgstr "Обратить"
|
||||
|
||||
#: zrcolagui.cpp:472
|
||||
msgid "Invert category selection"
|
||||
msgstr "Обратить выбор категории"
|
||||
|
||||
#: zrcolagui.cpp:511
|
||||
msgid "Character search results"
|
||||
msgstr "Результаты поиска знаков"
|
||||
|
||||
#: zrcolagui.cpp:521
|
||||
msgid "Re¢ly Used"
|
||||
msgstr ""
|
||||
msgstr "&Недавно использованное"
|
||||
|
||||
#: zrcolagui.cpp:498
|
||||
#: zrcolagui.cpp:549
|
||||
msgid "List of recently inserted characters"
|
||||
msgstr "Список недавно вставленных знаков"
|
||||
|
||||
#: zrcolagui.cpp:563
|
||||
msgid "Preview"
|
||||
msgstr ""
|
||||
msgstr "Просмотр"
|
||||
|
||||
#: zrcolagui.cpp:503
|
||||
#: zrcolagui.cpp:568
|
||||
msgid "U+"
|
||||
msgstr ""
|
||||
msgstr "U+"
|
||||
|
||||
#: zrcolagui.cpp:554
|
||||
msgid "Re&lated"
|
||||
msgstr ""
|
||||
#: zrcolagui.cpp:573
|
||||
msgid "Unicode hexadecimal code"
|
||||
msgstr "Шестнадцатеричный код Юникод"
|
||||
|
||||
#: zrcolagui.cpp:578
|
||||
msgid "Keyboard shortcut in Composer window"
|
||||
msgstr "Сочетание клавиш в окне композитора"
|
||||
|
||||
#: zrcolagui.cpp:613
|
||||
msgid "Character preview"
|
||||
msgstr "Просмотр знака"
|
||||
|
||||
#: zrcolagui.cpp:618
|
||||
msgid "Unicode character description"
|
||||
msgstr "Описание знака Юникод"
|
||||
|
||||
#: zrcolagui.cpp:623
|
||||
msgid "Character tags"
|
||||
msgstr "Ключевые слова"
|
||||
|
||||
#: zrcolagui.cpp:628
|
||||
msgid "Unicode character category"
|
||||
msgstr "Категория знака Юникод"
|
||||
|
||||
#: zrcolagui.cpp:635
|
||||
msgid "« Back"
|
||||
msgstr "« Назад"
|
||||
|
||||
#: zrcolagui.cpp:637
|
||||
msgid "To previously viewed character"
|
||||
msgstr "К предыдущему знаку"
|
||||
|
||||
#: zrcolagui.cpp:641
|
||||
msgid "Forward »"
|
||||
msgstr "Далее »"
|
||||
|
||||
#: zrcolagui.cpp:643
|
||||
msgid "To following viewed character"
|
||||
msgstr "К следующему знаку"
|
||||
|
||||
#: zrcolagui.cpp:654
|
||||
msgid "Re&lated"
|
||||
msgstr "&Связанное"
|
||||
|
||||
#: zrcolagui.cpp:681
|
||||
msgid "List of related characters"
|
||||
msgstr "Список связанных знаков"
|
||||
|
||||
#: zrcolagui.cpp:770
|
||||
msgid ""
|
||||
"Some character native to specific language you are working with should not "
|
||||
"decompose to primitives.\n"
|
||||
"For optimal decomposition you should set the language correctly."
|
||||
msgstr ""
|
||||
"Некоторые знаки использованного языка нельзя разбирать.\n"
|
||||
"Для оптимальной разборки вы должны настроить правильный язык."
|
||||
|
||||
#: zrcolagui.cpp:658
|
||||
#: zrcolagui.cpp:774
|
||||
msgid "Select language &automatically according to selected keyboard"
|
||||
msgstr ""
|
||||
msgstr "&Автоматически установить язык на основе выбранной клавиатуры"
|
||||
|
||||
#: zrcolagui.cpp:661
|
||||
#: zrcolagui.cpp:777
|
||||
msgid "&Manually select the language from the list below:"
|
||||
msgstr ""
|
||||
msgstr "&Вручную выбрать язык со списка:"
|
||||
|
||||
#: zrcolagui.cpp:673
|
||||
#: zrcolagui.cpp:789
|
||||
msgid "Text Language"
|
||||
msgstr ""
|
||||
msgstr "Язык текста"
|
||||
|
||||
#: zrcolagui.cpp:678
|
||||
#: zrcolagui.cpp:794
|
||||
msgid ""
|
||||
"ZRCola can be launched every time you log in to your computer.\n"
|
||||
"It will be available on the system tray and via registered shortcuts Win+F5 "
|
||||
"and Win+F6."
|
||||
msgstr ""
|
||||
"Запуск системы ZRCola возможен при каждом запуске компьютера.\n"
|
||||
"После запуска система ZRCola доступна на панели задач либо через нажатие "
|
||||
"сочетания клавиш Win+F5 и Win+F6."
|
||||
|
||||
#: zrcolagui.cpp:682
|
||||
#: zrcolagui.cpp:798
|
||||
msgid "Start ZRCola &automatically on logon"
|
||||
msgstr ""
|
||||
msgstr "&Автоматически запустить систему ZRCola при запуске компьютера"
|
||||
|
||||
#: zrcolagui.cpp:689
|
||||
#: zrcolagui.cpp:805
|
||||
msgid "Startup"
|
||||
msgstr ""
|
||||
msgstr "Запуск"
|
||||
|
||||
#: zrcolagui.cpp:768
|
||||
#: zrcolagui.cpp:885
|
||||
msgid ""
|
||||
"Editor: Janoš Ježovnik\n"
|
||||
"Development: Amebis d. o. o.\n"
|
||||
"Development and maintenance (2004-2015): dr. Peter Weiss"
|
||||
"Program and Website Editor: Janoš Ježovnik\n"
|
||||
"Development: Amebis, d. o. o., Kamnik\n"
|
||||
"Translation into English: Janoš Ježovnik\n"
|
||||
"Translation into Russian language: Domen Krvina, Silvo Torkar, Anastasia "
|
||||
"Plotnikova\n"
|
||||
"Development and maintenance of the original program (2004–2015): Peter Weiss"
|
||||
msgstr ""
|
||||
"Администратор программы и сайта: Янош Ежовник (Janoš Ježovnik)\n"
|
||||
"Разработка: Amebis, d. o. o., Kamnik\n"
|
||||
"Перевод на английский яазык: Янош Ежовник (Janoš Ježovnik)\n"
|
||||
"Перевод на русский язык: Домен Крвина (Domen Krvina), Силво Торкар (Silvo "
|
||||
"Torkar), Анастасия Плотникова\n"
|
||||
"Разработка in техническая поддержка первоначальной программы (2004–2015): "
|
||||
"Петер Вейсс (Peter Weiss)"
|
||||
|
||||
#: zrcolagui.cpp:776
|
||||
msgid "www.zrc-sazu.si"
|
||||
#: zrcolagui.cpp:893
|
||||
msgid "zrcola.zrc-sazu.si"
|
||||
msgstr "zrcola.zrc-sazu.si"
|
||||
|
||||
#: zrcolagui.cpp:899
|
||||
msgid ""
|
||||
"Texts made using ZRCola have to include in a footnote or some other "
|
||||
"appropriate part of the publication the note below:"
|
||||
msgstr ""
|
||||
"Текст, созданный с помощью системы ZRCola, должен в примечании или другом "
|
||||
"соответствующем месте в публикации сопровождаться следующей записью:"
|
||||
|
||||
#: zrcolagui.cpp:815
|
||||
#: zrcolagui.cpp:903
|
||||
msgid ""
|
||||
"This text was written using the ZRCola input system (http://zrcola.zrc-sazu."
|
||||
"si), developed at the Science and Research Centre of SAZU in Ljubljana "
|
||||
"(http://www.zrc-sazu.si) by Peter Weiss."
|
||||
msgstr ""
|
||||
"Текст подготовлен с помощью системы ввода ZRCola (http://zrcola.zrc-sazu."
|
||||
"si), разработанной в Научно-исследовательском центре Словенской академии "
|
||||
"наук и искусств в Любляне (http://www.zrc-sazu.si) Петром Вейссoм."
|
||||
|
||||
#: zrcolagui.cpp:944
|
||||
msgid "Log"
|
||||
msgstr ""
|
||||
msgstr "Журнал"
|
||||
|
||||
#: zrcolagui.cpp:831
|
||||
msgid "&Update"
|
||||
msgstr ""
|
||||
#: zrcolagui.cpp:960
|
||||
msgid "Quit and &Update..."
|
||||
msgstr "Выйти и &обновить ..."
|
||||
|
||||
#: zrcolagui.cpp:836
|
||||
#: zrcolagui.cpp:962
|
||||
msgid "Exit this program and launch product update"
|
||||
msgstr "Выйти из программы и запустить обновление"
|
||||
|
||||
#: zrcolagui.cpp:966
|
||||
msgid "&Close"
|
||||
msgstr "&Закрыть"
|
||||
|
||||
#: zrcolagui.cpp:967
|
||||
msgid "Close this window"
|
||||
msgstr "Закрыть это окно"
|
||||
|
||||
#: zrcolagui.cpp:1006
|
||||
msgid "Enter the &character you would like to request:"
|
||||
msgstr "Ввести запрашиваемый &знак:"
|
||||
|
||||
#: zrcolagui.cpp:1013
|
||||
msgid "Decomposed character to request"
|
||||
msgstr "Запрашиваемый разобранный знак"
|
||||
|
||||
#: zrcolagui.cpp:1017
|
||||
msgid ""
|
||||
"Please, use the decomposed form.\n"
|
||||
"You can use ZRCola keyboard shortcuts to enter the character or Copy&&Paste "
|
||||
"it from the Decomposed window."
|
||||
msgstr ""
|
||||
"Пожалуйста, используйте разобранный формат.\n"
|
||||
"Для ввода запрашиваемого знака можно использовать сочетания клавиш системы "
|
||||
"ZRCola либо копировать и вставить знаки из окна для разборки."
|
||||
|
||||
#: zrcolagui.cpp:1027
|
||||
msgid ""
|
||||
"The &context, examples or description why and where the character is "
|
||||
"required:"
|
||||
msgstr ""
|
||||
"&Контекст, примеры либо описание запрашиваемого знака или объяснение, зачем "
|
||||
"он нужен:"
|
||||
|
||||
#: zrcolagui.cpp:1033
|
||||
msgid "Additional notes for character request"
|
||||
msgstr "Дополнительные примечания"
|
||||
|
||||
#: zrcolagui.cpp:1040
|
||||
msgid ""
|
||||
"After clicking OK button, your e-mail application should open allowing you "
|
||||
"to submit the new character request to ZRCola Editor.\n"
|
||||
"Your e-mail application might not display all the characters correctly, but "
|
||||
"the Editor will be able to read them correctly anyway."
|
||||
msgstr ""
|
||||
"После нажатия на кнопку «OK» ваша почтовая программа должна открытся для "
|
||||
"отправки запроса нового знака администратору системы ZRCola.\n"
|
||||
"Возможно, не все знаки будут отображены правильно, но все информации будут "
|
||||
"закодированны таким образом, что администратор сможет их правильно прочитать."
|
||||
|
||||
#: zrcolakeyhndlr.cpp:44
|
||||
msgid ""
|
||||
"INS key is pressed. Type the Unicode code of desired character now (up to "
|
||||
"four hexadecimal digits: 0-9, A-F), then release INS."
|
||||
msgstr ""
|
||||
"Нажата клавиша INS. Введите код Юникод желаемого знака (максимум четыре "
|
||||
"шестнадцатеричныe цифры: 0-9, A-F), затем отпустите клавишу INS."
|
||||
|
||||
#: zrcolasettings.cpp:93
|
||||
msgid "Start ZRCola automatically on logon"
|
||||
msgstr ""
|
||||
msgstr "Автоматически запустить систему ZRCola при запуске компьютера"
|
||||
|
||||
#: zrcolagui.h:262
|
||||
#: zrcolaupdater.cpp:94
|
||||
msgid ""
|
||||
"This program will now close and the upgrade will be launched.\n"
|
||||
"Are you sure?"
|
||||
msgstr ""
|
||||
"Программа будет закрыта и обновлена.\n"
|
||||
"Вы уверены?"
|
||||
|
||||
#: zrcolaupdater.cpp:94 zrcolagui.h:334
|
||||
msgid "Product Update"
|
||||
msgstr "Обновление продукта"
|
||||
|
||||
#: zrcolagui.h:246
|
||||
msgid "Character Search"
|
||||
msgstr "Поиск знака"
|
||||
|
||||
#: zrcolagui.h:283
|
||||
msgid "Settings"
|
||||
msgstr ""
|
||||
|
||||
#: zrcolagui.h:286
|
||||
msgid "About ZRCola"
|
||||
msgstr ""
|
||||
msgstr "Настройки"
|
||||
|
||||
#: zrcolagui.h:309
|
||||
msgid "Product Update"
|
||||
msgid "About ZRCola"
|
||||
msgstr "О системе ZRCola"
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:10
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:15
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:10
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:15
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:10
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:15
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:10
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:15
|
||||
msgid "binUIHeader.bmp"
|
||||
msgstr "binUIHeader.bmp"
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:5
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:5
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:5
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:5
|
||||
msgid "[DlgTitleFont][SimpleProductName] Tutorial : Starting"
|
||||
msgstr "[DlgTitleFont][SimpleProductName] Руководство по запуску системы"
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:6
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:6
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:6
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:6
|
||||
msgid "bintutorial1.bmp"
|
||||
msgstr "bintutorial1.bmp"
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:7
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:7
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:7
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:7
|
||||
msgid ""
|
||||
"When configured, ZRCola starts at system startup and runs in the background. "
|
||||
"If needed, it can be brought up by pressing the combination Win+F5."
|
||||
msgstr ""
|
||||
"Если так настроено, система ZRCola запускается при запуске компьютера и "
|
||||
"работает в фоновом режиме. Если потребуется, пользователь может вывести "
|
||||
"программу на экран, нажав на сочетание клавиш Win+F5."
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:8
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:8
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:8
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:8
|
||||
msgid ""
|
||||
"IMPORTANT: Upon pressing the combination Win+F5 the program memorises the "
|
||||
"location of the cursor in the text. If ZRCola is brought to the foreground "
|
||||
"without using the aforementioned combination of keys, the program won't know "
|
||||
"where to insert the special characters!"
|
||||
msgstr ""
|
||||
"Внимание: При нажатии сочетание клавиш Win+F5 программа запомнить "
|
||||
"местонахождение курсора в тексте. Если система ZRCola выведена на экран без "
|
||||
"использования упомянутого сочетания клавиш, программа не знает, куда ввести "
|
||||
"желаемые знаки!"
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:9
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:14
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:19
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:9
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:14
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:19
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:9
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:14
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:19
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:9
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:14
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:19
|
||||
msgid "&Continue"
|
||||
msgstr "&Продолжить"
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:11
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:11
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:11
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:11
|
||||
msgid "[DlgTitleFont][SimpleProductName] Tutorial : Composition"
|
||||
msgstr "[DlgTitleFont][SimpleProductName] Руководство по составлению"
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:12
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:12
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:12
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:12
|
||||
msgid "bintutorial2.bmp"
|
||||
msgstr "bintutorial2.bmp"
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:13
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:13
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:13
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:13
|
||||
msgid ""
|
||||
"The string of basic and substitute characters is entered into the upper "
|
||||
"input window of the program. In the window below the resulted special "
|
||||
"characters are displayed. To insert them in the text, the F5 key is used."
|
||||
msgstr ""
|
||||
"Строка основных и замещающих знаков вводится в верхнее окно для ввода. После "
|
||||
"того, в нижнем окне появляются соответствующие специальные знаки. Для их "
|
||||
"ввода в текст нужно нажать клавишу F5."
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:16
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:16
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:16
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:16
|
||||
msgid "[DlgTitleFont][SimpleProductName] Tutorial : Entering Characters"
|
||||
msgstr "[DlgTitleFont][SimpleProductName] Руководство по вводу знаков"
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:17
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:17
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:17
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:17
|
||||
msgid "bintutorial3.bmp"
|
||||
msgstr "bintutorial3.bmp"
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Control-2.idtx:18
|
||||
#: MSIBuild/en_US.Win32.Release.Control-2.idtx:18
|
||||
#: MSIBuild/en_US.x64.Debug.Control-2.idtx:18
|
||||
#: MSIBuild/en_US.x64.Release.Control-2.idtx:18
|
||||
msgid ""
|
||||
"Characters can be entered using keyboard shortcuts, the character catalogue "
|
||||
"(F4) or the character finding tool (F8)."
|
||||
msgstr ""
|
||||
"Знак можно ввести, употребляя сочетания клавиш на клавиатуре, список знаков "
|
||||
"(F4) или функцию \"Поиск знака\" (F8)."
|
||||
|
||||
#: MSIBuild/en_US.Win32.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.Win32.Release.Shortcut-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/en_US.x64.Release.Shortcut-2.idtx:4
|
||||
msgid "Input system for linguistic use"
|
||||
msgstr "Система ввода ZRCola для лингвистического применения"
|
||||
|
||||
#~ msgid "http://zrcola-2.amebis.si/en/info/instructions/"
|
||||
#~ msgstr "http://zrcola.zrc-sazu.si/ru/info/instructions/"
|
||||
|
||||
#~ msgid ""
|
||||
#~ "http://zrcola-2.amebis.si/wp-content/uploads/2016/04/5_ZRCola-"
|
||||
#~ "Tipkovnica_2009-06-21.pdf"
|
||||
#~ msgstr ""
|
||||
#~ "http://zrcola.zrc-sazu.si/wp-content/uploads/2016/08/"
|
||||
#~ "ZRCola_tipkovnica_20160801.pdf"
|
||||
|
||||
# Windows charset for this language (decimal)
|
||||
#: MSIBuild/En.Win32.Debug.Feature-2.idtx:3
|
||||
#: MSIBuild/En.Win32.Debug.Shortcut-2.idtx:3
|
||||
#: MSIBuild/En.Win32.Release.Feature-2.idtx:3
|
||||
#: MSIBuild/En.Win32.Release.Shortcut-2.idtx:3
|
||||
#: MSIBuild/En.x64.Debug.Feature-2.idtx:3
|
||||
#: MSIBuild/En.x64.Debug.Shortcut-2.idtx:3
|
||||
#: MSIBuild/En.x64.Release.Feature-2.idtx:3
|
||||
#: MSIBuild/En.x64.Release.Shortcut-2.idtx:3
|
||||
#, fuzzy
|
||||
msgid "1252"
|
||||
msgstr "1251"
|
||||
|
||||
#: MSIBuild/En.Win32.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/En.Win32.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/En.Win32.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/En.Win32.Release.Shortcut-2.idtx:4
|
||||
#: MSIBuild/En.x64.Debug.Feature-2.idtx:4
|
||||
#: MSIBuild/En.x64.Debug.Shortcut-2.idtx:4
|
||||
#: MSIBuild/En.x64.Release.Feature-2.idtx:4
|
||||
#: MSIBuild/En.x64.Release.Shortcut-2.idtx:4
|
||||
msgid "Input system for linguistic use"
|
||||
msgstr ""
|
||||
#~ msgid "1252"
|
||||
#~ msgstr "1251"
|
||||
|
||||
#~ msgid "Auto Start"
|
||||
#~ msgstr "Samodejni zagon"
|
||||
@@ -441,6 +824,7 @@ msgstr ""
|
||||
#~ msgid "Shift"
|
||||
#~ msgstr "Shift"
|
||||
|
||||
#, fuzzy
|
||||
#~ msgid "Alt"
|
||||
#~ msgstr "Alt"
|
||||
|
||||
@@ -504,9 +888,6 @@ msgstr ""
|
||||
#~ msgid "\\"
|
||||
#~ msgstr "\\"
|
||||
|
||||
#~ msgid ","
|
||||
#~ msgstr ","
|
||||
|
||||
#~ msgid "."
|
||||
#~ msgstr "."
|
||||
|
||||
@@ -516,15 +897,13 @@ msgstr ""
|
||||
#~ msgid "INS"
|
||||
#~ msgstr "INS"
|
||||
|
||||
#, fuzzy
|
||||
#~ msgid "Character &Groups"
|
||||
#~ msgstr "Skupine &znakov"
|
||||
|
||||
#~ msgid "Language:"
|
||||
#~ msgstr "Jezik:"
|
||||
|
||||
#~ msgid "&About"
|
||||
#~ msgstr "O progr&amu"
|
||||
|
||||
#~ msgid "Cuts selected text and puts it on the clipboard"
|
||||
#~ msgstr "Izreže izbrano besedilo in ga shrani na odložišče"
|
||||
|
||||
@@ -534,18 +913,22 @@ msgstr ""
|
||||
#~ msgid "Inserts text from the clipboard"
|
||||
#~ msgstr "Vstavi besedilo z odložišča"
|
||||
|
||||
#, fuzzy
|
||||
#~ msgid "&Copy"
|
||||
#~ msgstr "&Kopiraj"
|
||||
|
||||
#, fuzzy
|
||||
#~ msgid "&Paste"
|
||||
#~ msgstr "&Prilepi"
|
||||
|
||||
#~ msgid "&File"
|
||||
#~ msgstr "&Datoteka"
|
||||
|
||||
#, fuzzy
|
||||
#~ msgid "Send Decomposed (F6)"
|
||||
#~ msgstr "Pošlji razstavljeno (F6)"
|
||||
|
||||
#, fuzzy
|
||||
#~ msgid "Send Composed (F5)"
|
||||
#~ msgstr "Pošlji sestavljeno (F5)"
|
||||
|
||||
|
||||
BIN
ZRCola/res/navigate_back.ico
Normal file
|
After Width: | Height: | Size: 52 KiB |
1936
ZRCola/res/navigate_back.pdf
Normal file
BIN
ZRCola/res/navigate_forward.ico
Normal file
|
After Width: | Height: | Size: 52 KiB |
1947
ZRCola/res/navigate_forward.pdf
Normal file
@@ -19,11 +19,12 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "../include/zrcola.h"
|
||||
#include "../include/version.h"
|
||||
#include "zrcolaabout.h"
|
||||
#include "zrcolaapp.h"
|
||||
#include "zrcolachrgrid.h"
|
||||
#include "zrcolachrcatpnl.h"
|
||||
#include "zrcolachrgrid.h"
|
||||
#include "zrcolachrreq.h"
|
||||
#include "zrcolacomppnl.h"
|
||||
#include "zrcolafrm.h"
|
||||
#include "zrcolakeyhndlr.h"
|
||||
@@ -33,6 +34,7 @@
|
||||
#include <Updater/chkthread.h>
|
||||
|
||||
#include <wxex/common.h>
|
||||
#include <wxex/url.h>
|
||||
#include <wxex/persist/auimanager.h>
|
||||
|
||||
#include <wx/ffile.h>
|
||||
@@ -43,6 +45,8 @@
|
||||
#include <wx/valtext.h>
|
||||
#include <wx/socket.h>
|
||||
|
||||
#include <WinStd/MSI.h>
|
||||
|
||||
#include <fstream>
|
||||
#include <string>
|
||||
#include <utility>
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
|
||||
wxZRColaAbout::wxZRColaAbout(wxWindow* parent) : wxZRColaAboutBase(parent)
|
||||
{
|
||||
m_staticTextVersion->SetLabelText(wxT(ZRCOLA_VERSION_STR));
|
||||
m_staticTextVersion->SetLabelText(wxT(PRODUCT_VERSION_STR));
|
||||
|
||||
m_staticTextCopyright->SetLabelText(wxString::Format(_("© 2004-%s ZRC SAZU"), wxT(ZRCOLA_BUILD_YEAR_STR)));
|
||||
m_staticTextCopyright->SetLabelText(wxString::Format(_("© 2004-%s ZRC SAZU"), wxT(PRODUCT_BUILD_YEAR_STR)));
|
||||
}
|
||||
|
||||
@@ -32,9 +32,7 @@ wxIMPLEMENT_APP(ZRColaApp);
|
||||
|
||||
ZRColaApp::ZRColaApp() :
|
||||
m_mainWnd(NULL),
|
||||
#ifdef __WXMSW__
|
||||
m_running(NULL),
|
||||
#endif
|
||||
m_lang_ui(wxLANGUAGE_DEFAULT),
|
||||
wxApp()
|
||||
{
|
||||
}
|
||||
@@ -46,25 +44,21 @@ bool ZRColaApp::OnInit()
|
||||
// To compensate migration to non-advertised shortcut, do the Microsoft Installer's feature completeness check manually.
|
||||
// If execution got this far in the first place (EXE and dependent DLLs are present and loadable).
|
||||
// Furthermore, this increments program usage counter.
|
||||
if (::MsiQueryFeatureState(_T(ZRCOLA_VERSION_GUID), _T("featZRCola")) != INSTALLSTATE_UNKNOWN)
|
||||
::MsiUseFeature(_T(ZRCOLA_VERSION_GUID), _T("featZRCola"));
|
||||
if (::MsiQueryFeatureState(_T(PRODUCT_VERSION_GUID), _T("featZRCola")) != INSTALLSTATE_UNKNOWN)
|
||||
::MsiUseFeature(_T(PRODUCT_VERSION_GUID), _T("featZRCola"));
|
||||
#endif
|
||||
|
||||
wxConfigBase *cfgPrev = wxConfigBase::Set(new wxConfig(wxT(ZRCOLA_CFG_APPLICATION), wxT(ZRCOLA_CFG_VENDOR)));
|
||||
// Initialize configuration.
|
||||
wxConfigBase *cfgPrev = wxConfigBase::Set(new wxConfig(wxT(PRODUCT_CFG_APPLICATION), wxT(PRODUCT_CFG_VENDOR)));
|
||||
if (cfgPrev) wxDELETE(cfgPrev);
|
||||
|
||||
if (!wxApp::OnInit())
|
||||
return false;
|
||||
|
||||
// Set desired locale.
|
||||
wxLanguage language = (wxLanguage)wxConfigBase::Get()->Read(wxT("Language"), wxLANGUAGE_DEFAULT);
|
||||
if (wxLocale::IsAvailable(language)) {
|
||||
wxString sPath;
|
||||
if (wxConfigBase::Get()->Read(wxT("LocalizationRepositoryPath"), &sPath))
|
||||
m_locale.AddCatalogLookupPathPrefix(sPath);
|
||||
wxVERIFY(m_locale.Init(language));
|
||||
// Initialize locale.
|
||||
if (wxInitializeLocale(m_locale, &m_lang_ui)) {
|
||||
wxVERIFY(m_locale.AddCatalog(wxT("wxExtend") wxT(wxExtendVersion)));
|
||||
wxVERIFY(m_locale.AddCatalog(wxT("Updater") wxT(wxUpdaterVersion)));
|
||||
wxVERIFY(m_locale.AddCatalog(wxT("UpdaterZRCola")));
|
||||
wxVERIFY(m_locale.AddCatalog(wxT("libZRColaUI")));
|
||||
wxVERIFY(m_locale.AddCatalog(wxT("ZRCola")));
|
||||
wxVERIFY(m_locale.AddCatalog(wxT("ZRCola-zrcdb")));
|
||||
@@ -72,8 +66,7 @@ bool ZRColaApp::OnInit()
|
||||
|
||||
#ifdef __WXMSW__
|
||||
// Create global event.
|
||||
m_running = ::CreateEvent(NULL, FALSE, FALSE, _T(ZRCOLA_CFG_APPLICATION) _T("{BBDE7AAD-29B6-4B83-ADA1-92AFA81A0883}"));
|
||||
wxASSERT(m_running);
|
||||
m_running.attach(::CreateEvent(NULL, FALSE, FALSE, _T(PRODUCT_CFG_APPLICATION) _T("{BBDE7AAD-29B6-4B83-ADA1-92AFA81A0883}")));
|
||||
if (::GetLastError() == ERROR_ALREADY_EXISTS) {
|
||||
// ZRCola is already running. Find its window.
|
||||
HWND okno = ::FindWindow(_T("wxWindowNR"), _("ZRCola"));
|
||||
@@ -89,7 +82,7 @@ bool ZRColaApp::OnInit()
|
||||
}
|
||||
#endif
|
||||
|
||||
std::fstream dat((LPCTSTR)GetDatabasePath(), std::ios_base::in | std::ios_base::binary);
|
||||
std::fstream dat((LPCTSTR)GetDatabaseFilePath(), std::ios_base::in | std::ios_base::binary);
|
||||
if (dat.good()) {
|
||||
if (stdex::idrec::find<ZRCola::recordid_t, ZRCola::recordsize_t, ZRCOLA_RECORD_ALIGN>(dat, ZRCOLA_DB_ID, sizeof(ZRCola::recordid_t))) {
|
||||
ZRCola::recordsize_t size;
|
||||
@@ -107,49 +100,49 @@ bool ZRColaApp::OnInit()
|
||||
has_translation_data = true;
|
||||
} else {
|
||||
wxFAIL_MSG(wxT("Error reading translation data from ZRCola.zrcdb."));
|
||||
m_t_db.idxComp .clear();
|
||||
m_t_db.idxDecomp.clear();
|
||||
m_t_db.data .clear();
|
||||
m_t_db.clear();
|
||||
}
|
||||
} else if (id == ZRCola::langchar_rec::id) {
|
||||
dat >> ZRCola::langchar_rec(m_lc_db);
|
||||
if (!dat.good()) {
|
||||
wxFAIL_MSG(wxT("Error reading language character data from ZRCola.zrcdb."));
|
||||
m_lc_db.idxChr.clear();
|
||||
#ifdef ZRCOLA_LANGCHAR_LANG_IDX
|
||||
m_lc_db.idxLng.clear();
|
||||
#endif
|
||||
m_lc_db.data .clear();
|
||||
m_lc_db.clear();
|
||||
}
|
||||
} else if (id == ZRCola::language_rec::id) {
|
||||
dat >> ZRCola::language_rec(m_lang_db);
|
||||
if (!dat.good()) {
|
||||
wxFAIL_MSG(wxT("Error reading language character data from ZRCola.zrcdb."));
|
||||
m_lang_db.idxLng.clear();
|
||||
m_lang_db.data .clear();
|
||||
m_lang_db.clear();
|
||||
}
|
||||
} else if (id == ZRCola::keyseq_rec::id) {
|
||||
dat >> ZRCola::keyseq_rec(m_ks_db);
|
||||
if (!dat.good()) {
|
||||
wxFAIL_MSG(wxT("Error reading key sequences data from ZRCola.zrcdb."));
|
||||
m_ks_db.idxChr.clear();
|
||||
m_ks_db.idxKey.clear();
|
||||
m_ks_db.data .clear();
|
||||
m_ks_db.clear();
|
||||
}
|
||||
} else if (id == ZRCola::character_rec::id) {
|
||||
dat >> ZRCola::character_rec(m_chr_db);
|
||||
if (!dat.good()) {
|
||||
wxFAIL_MSG(wxT("Error reading character data from ZRCola.zrcdb."));
|
||||
m_chr_db.idxChr.clear();
|
||||
m_chr_db.data .clear();
|
||||
m_chr_db.clear();
|
||||
}
|
||||
} else if (id == ZRCola::chrcat_rec::id) {
|
||||
dat >> ZRCola::chrcat_rec(m_cc_db);
|
||||
if (!dat.good()) {
|
||||
wxFAIL_MSG(wxT("Error reading character category data from ZRCola.zrcdb."));
|
||||
m_cc_db.idxChrCat.clear();
|
||||
m_cc_db.idxRnk .clear();
|
||||
m_cc_db.data .clear();
|
||||
m_cc_db.clear();
|
||||
}
|
||||
} else if (id == ZRCola::chrtag_rec::id) {
|
||||
dat >> ZRCola::chrtag_rec(m_ct_db);
|
||||
if (!dat.good()) {
|
||||
wxFAIL_MSG(wxT("Error reading character tag data from ZRCola.zrcdb."));
|
||||
m_ct_db.clear();
|
||||
}
|
||||
} else if (id == ZRCola::tagname_rec::id) {
|
||||
dat >> ZRCola::tagname_rec(m_tn_db);
|
||||
if (!dat.good()) {
|
||||
wxFAIL_MSG(wxT("Error reading tag name data from ZRCola.zrcdb."));
|
||||
m_tn_db.clear();
|
||||
}
|
||||
} else
|
||||
stdex::idrec::ignore<ZRCola::recordsize_t, ZRCOLA_RECORD_ALIGN>(dat);
|
||||
@@ -180,10 +173,7 @@ int ZRColaApp::OnExit()
|
||||
int res = wxApp::OnExit();
|
||||
|
||||
#ifdef __WXMSW__
|
||||
if (m_running) {
|
||||
wxVERIFY(::CloseHandle(m_running));
|
||||
m_running = NULL;
|
||||
}
|
||||
m_running.free();
|
||||
#endif
|
||||
|
||||
return res;
|
||||
|
||||
@@ -26,12 +26,14 @@ class ZRColaApp;
|
||||
#pragma once
|
||||
|
||||
#include "zrcolafrm.h"
|
||||
#include <WinStd/Win.h>
|
||||
#include <wx/app.h>
|
||||
#include <wx/config.h>
|
||||
#include <wx/intl.h>
|
||||
#include <zrcola/character.h>
|
||||
#include <zrcola/language.h>
|
||||
#include <zrcola/translate.h>
|
||||
#include <zrcola/tag.h>
|
||||
#include <zrcolaui/keyboard.h>
|
||||
|
||||
|
||||
@@ -60,10 +62,15 @@ public:
|
||||
virtual int OnExit();
|
||||
|
||||
///
|
||||
/// \returns Path to ZRCola.zrcdb file
|
||||
/// \returns Path to database files
|
||||
///
|
||||
inline wxString GetDatabasePath() const;
|
||||
|
||||
///
|
||||
/// \returns Path to ZRCola.zrcdb file
|
||||
///
|
||||
inline wxString GetDatabaseFilePath() const;
|
||||
|
||||
public:
|
||||
ZRCola::translation_db m_t_db; ///< Translation database
|
||||
ZRCola::langchar_db m_lc_db; ///< Language character database
|
||||
@@ -71,14 +78,17 @@ public:
|
||||
ZRCola::keyseq_db m_ks_db; ///< Key sequence database
|
||||
ZRCola::character_db m_chr_db; ///< Character database
|
||||
ZRCola::chrcat_db m_cc_db; ///< Characted category database
|
||||
ZRCola::chrtag_db m_ct_db; ///< Character tag database
|
||||
ZRCola::tagname_db m_tn_db; ///< Tag name database
|
||||
|
||||
wxZRColaFrame *m_mainWnd; ///< Main window
|
||||
|
||||
wxLocale m_locale; ///< Current locale
|
||||
wxLanguage m_lang_ui; ///< Translation language (language of User Interface, wxLANGUAGE_DEFAULT = English)
|
||||
|
||||
protected:
|
||||
#ifdef __WXMSW__
|
||||
HANDLE m_running; ///< Global Win32 event to determine if another instance of ZRCola is already running
|
||||
winstd::win_handle m_running; ///< Global Win32 event to determine if another instance of ZRCola is already running
|
||||
#endif
|
||||
};
|
||||
|
||||
@@ -91,12 +101,17 @@ inline wxString ZRColaApp::GetDatabasePath() const
|
||||
wxString sPath;
|
||||
if (wxConfigBase::Get()->Read(wxT("DatabasePath"), &sPath)) {
|
||||
if (!wxEndsWithPathSeparator(sPath))
|
||||
sPath << wxFILE_SEP_PATH;
|
||||
sPath += wxFILE_SEP_PATH;
|
||||
} else {
|
||||
sPath = wxPathOnly(argv[0]);
|
||||
sPath << wxT("\\..\\data\\");
|
||||
sPath += wxT("\\..\\data\\");
|
||||
}
|
||||
sPath << wxT("ZRCola.zrcdb");
|
||||
|
||||
return sPath;
|
||||
}
|
||||
|
||||
|
||||
inline wxString ZRColaApp::GetDatabaseFilePath() const
|
||||
{
|
||||
return GetDatabasePath() + wxT("ZRCola.zrcdb");
|
||||
}
|
||||
|
||||
@@ -31,7 +31,7 @@ END_EVENT_TABLE()
|
||||
|
||||
wxZRColaCharacterCatalogPanel::wxZRColaCharacterCatalogPanel(wxWindow* parent) : wxZRColaCharacterCatalogPanelBase(parent)
|
||||
{
|
||||
std::fstream dat((LPCTSTR)((ZRColaApp*)wxTheApp)->GetDatabasePath(), std::ios_base::in | std::ios_base::binary);
|
||||
std::fstream dat((LPCTSTR)dynamic_cast<ZRColaApp*>(wxTheApp)->GetDatabaseFilePath(), std::ios_base::in | std::ios_base::binary);
|
||||
if (dat.good()) {
|
||||
if (stdex::idrec::find<ZRCola::recordid_t, ZRCola::recordsize_t, ZRCOLA_RECORD_ALIGN>(dat, ZRCOLA_DB_ID, sizeof(ZRCola::recordid_t))) {
|
||||
ZRCola::recordsize_t size;
|
||||
@@ -64,10 +64,7 @@ wxZRColaCharacterCatalogPanel::wxZRColaCharacterCatalogPanel(wxWindow* parent) :
|
||||
m_cg_id = m_cg_db.idxRnk[0].id;
|
||||
m_choice->Select(0);
|
||||
|
||||
// Update grid by simulating wxEVT_COMMAND_CHOICE_SELECTED event.
|
||||
wxCommandEvent e(wxEVT_COMMAND_CHOICE_SELECTED, m_grid->GetId());
|
||||
e.SetInt(0);
|
||||
OnChoice(e);
|
||||
Update();
|
||||
}
|
||||
|
||||
// Register frame specific hotkey(s).
|
||||
@@ -86,13 +83,12 @@ wxZRColaCharacterCatalogPanel::~wxZRColaCharacterCatalogPanel()
|
||||
|
||||
void wxZRColaCharacterCatalogPanel::OnChoice(wxCommandEvent& event)
|
||||
{
|
||||
ZRCola::chrgrp_db::chrgrp &cg = m_cg_db.idxRnk[event.GetSelection()];
|
||||
const ZRCola::chrgrp_db::chrgrp &cg = m_cg_db.idxRnk[event.GetSelection()];
|
||||
|
||||
m_cg_id = cg.id;
|
||||
m_grid->SetCharacters(wxString(cg.data + cg.name_len, cg.char_len));
|
||||
|
||||
// As size of the grid might have changed, relayout the panel.
|
||||
Layout();
|
||||
if (m_cg_id != cg.id) {
|
||||
m_cg_id = cg.id;
|
||||
Update();
|
||||
}
|
||||
|
||||
event.Skip();
|
||||
}
|
||||
@@ -100,7 +96,7 @@ void wxZRColaCharacterCatalogPanel::OnChoice(wxCommandEvent& event)
|
||||
|
||||
void wxZRColaCharacterCatalogPanel::OnGridClick(wxGridEvent& event)
|
||||
{
|
||||
ZRColaApp *app = (ZRColaApp*)wxTheApp;
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
if (app->m_mainWnd) {
|
||||
app->m_mainWnd->m_panel->m_decomposed->WriteText(m_grid->GetCellValue(event.GetRow(), event.GetCol()));
|
||||
app->m_mainWnd->m_panel->m_decomposed->SetFocus();
|
||||
@@ -115,7 +111,7 @@ void wxZRColaCharacterCatalogPanel::OnGridKeyDown(wxKeyEvent& event)
|
||||
switch (event.GetKeyCode()) {
|
||||
case WXK_RETURN:
|
||||
case WXK_NUMPAD_ENTER:
|
||||
ZRColaApp *app = (ZRColaApp*)wxTheApp;
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
if (app->m_mainWnd) {
|
||||
app->m_mainWnd->m_panel->m_decomposed->WriteText(m_grid->GetCellValue(m_grid->GetCursorRow(), m_grid->GetCursorColumn()));
|
||||
app->m_mainWnd->m_panel->m_decomposed->SetFocus();
|
||||
@@ -129,9 +125,19 @@ void wxZRColaCharacterCatalogPanel::OnGridKeyDown(wxKeyEvent& event)
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharacterCatalogPanel::OnShowAll(wxCommandEvent& event)
|
||||
{
|
||||
UNREFERENCED_PARAMETER(event);
|
||||
|
||||
Update();
|
||||
|
||||
event.Skip();
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharacterCatalogPanel::OnFocusDecomposed(wxCommandEvent& event)
|
||||
{
|
||||
ZRColaApp *app = (ZRColaApp*)wxTheApp;
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
if (app->m_mainWnd) {
|
||||
app->m_mainWnd->m_panel->m_decomposed->SetFocus();
|
||||
|
||||
@@ -143,6 +149,33 @@ void wxZRColaCharacterCatalogPanel::OnFocusDecomposed(wxCommandEvent& event)
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharacterCatalogPanel::Update()
|
||||
{
|
||||
const ZRCola::chrgrp_db::chrgrp &cg = m_cg_db.idxRnk[m_choice->GetSelection()];
|
||||
|
||||
if (m_show_all->GetValue()) {
|
||||
m_grid->SetCharacters(
|
||||
wxString(cg.get_chars(), cg.char_len),
|
||||
wxArrayShort((const short*)cg.get_char_shown(), (const short*)cg.get_char_shown() + (cg.char_len + 15)/16));
|
||||
} else {
|
||||
// Select frequently used characters only.
|
||||
const wchar_t *src = cg.get_chars();
|
||||
const unsigned __int16 *shown = cg.get_char_shown();
|
||||
wxString chars;
|
||||
for (unsigned __int16 i = 0, j = 0; i < cg.char_len; j++) {
|
||||
for (unsigned __int16 k = 0, mask = shown[j]; k < 16 && i < cg.char_len; k++, mask >>= 1, i++) {
|
||||
if (mask & 1)
|
||||
chars += src[i];
|
||||
}
|
||||
}
|
||||
m_grid->SetCharacters(chars);
|
||||
}
|
||||
|
||||
// As size of the grid might have changed, relayout the panel.
|
||||
Layout();
|
||||
}
|
||||
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
// wxPersistentZRColaCharacterCatalogPanel
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
@@ -160,15 +193,17 @@ wxString wxPersistentZRColaCharacterCatalogPanel::GetKind() const
|
||||
|
||||
void wxPersistentZRColaCharacterCatalogPanel::Save() const
|
||||
{
|
||||
const wxZRColaCharacterCatalogPanel * const wnd = static_cast<const wxZRColaCharacterCatalogPanel*>(GetWindow());
|
||||
auto wnd = static_cast<const wxZRColaCharacterCatalogPanel*>(GetWindow()); // dynamic_cast is not reliable as we are typically called late in the wxTopLevelWindowMSW destructor.
|
||||
|
||||
SaveValue(wxT("charGroup"), wnd->m_cg_id);
|
||||
SaveValue(wxT("showAll" ), wnd->m_show_all->GetValue());
|
||||
}
|
||||
|
||||
|
||||
bool wxPersistentZRColaCharacterCatalogPanel::Restore()
|
||||
{
|
||||
wxZRColaCharacterCatalogPanel * const wnd = static_cast<wxZRColaCharacterCatalogPanel*>(GetWindow());
|
||||
auto wnd = dynamic_cast<wxZRColaCharacterCatalogPanel*>(GetWindow());
|
||||
bool update = false;
|
||||
|
||||
// Restore selected character group.
|
||||
int cg_id;
|
||||
@@ -176,18 +211,27 @@ bool wxPersistentZRColaCharacterCatalogPanel::Restore()
|
||||
for (size_t i = 0, n = wnd->m_cg_db.idxRnk.size(); i < n; i++) {
|
||||
const ZRCola::chrgrp_db::chrgrp &cg = wnd->m_cg_db.idxRnk[i];
|
||||
if (cg.id == cg_id) {
|
||||
wnd->m_cg_id = cg.id;
|
||||
wnd->m_choice->Select(i);
|
||||
|
||||
// Update grid by simulating wxEVT_COMMAND_CHOICE_SELECTED event.
|
||||
wxCommandEvent e(wxEVT_COMMAND_CHOICE_SELECTED, wnd->m_grid->GetId());
|
||||
e.SetInt(i);
|
||||
wnd->OnChoice(e);
|
||||
if (wnd->m_cg_id != cg.id) {
|
||||
wnd->m_cg_id = cg.id;
|
||||
wnd->m_choice->Select(i);
|
||||
update = true;
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
bool show_all;
|
||||
if (RestoreValue(wxT("showAll"), &show_all)) {
|
||||
if (wnd->m_show_all->GetValue() != show_all) {
|
||||
wnd->m_show_all->SetValue(show_all);
|
||||
update = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (update)
|
||||
wnd->Update();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -50,9 +50,12 @@ protected:
|
||||
virtual void OnChoice(wxCommandEvent& event);
|
||||
virtual void OnGridClick(wxGridEvent& event);
|
||||
virtual void OnGridKeyDown(wxKeyEvent& event);
|
||||
virtual void OnShowAll(wxCommandEvent& event);
|
||||
void OnFocusDecomposed(wxCommandEvent& event);
|
||||
DECLARE_EVENT_TABLE()
|
||||
|
||||
void Update();
|
||||
|
||||
protected:
|
||||
ZRCola::chrgrp_db m_cg_db; ///< Character group database
|
||||
int m_cg_id; ///< Selected character group ID
|
||||
|
||||
@@ -68,8 +68,22 @@ void wxZRColaCharGrid::Init()
|
||||
|
||||
|
||||
void wxZRColaCharGrid::SetCharacters(const wxString &chars)
|
||||
{
|
||||
m_chars = chars;
|
||||
m_relevance.Clear();
|
||||
m_regenerate = true;
|
||||
|
||||
// Invoke OnSize(), which will populate the grid.
|
||||
wxSizeEvent e(GetSize(), m_windowId);
|
||||
e.SetEventObject(this);
|
||||
HandleWindowEvent(e);
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharGrid::SetCharacters(const wxString &chars, const wxArrayShort &relevance)
|
||||
{
|
||||
m_chars = chars;
|
||||
m_relevance = relevance;
|
||||
m_regenerate = true;
|
||||
|
||||
// Invoke OnSize(), which will populate the grid.
|
||||
@@ -83,16 +97,13 @@ wxString wxZRColaCharGrid::GetToolTipText(int idx)
|
||||
{
|
||||
wxASSERT_MSG(idx < (int)m_chars.Length(), wxT("index out of bounds"));
|
||||
|
||||
ZRColaApp *app = (ZRColaApp*)wxTheApp;
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
|
||||
// See if this character has a key sequence registered.
|
||||
ZRCola::keyseq_db::indexKey::size_type start;
|
||||
bool found;
|
||||
char ks[sizeof(ZRCola::keyseq_db::keyseq)] = {};
|
||||
((ZRCola::keyseq_db::keyseq*)ks)->chr = m_chars[idx];
|
||||
found = app->m_ks_db.idxChr.find(*(ZRCola::keyseq_db::keyseq*)ks, start);
|
||||
|
||||
if (found) {
|
||||
ZRCola::keyseq_db::indexKey::size_type start;
|
||||
if (app->m_ks_db.idxChr.find(*(ZRCola::keyseq_db::keyseq*)ks, start)) {
|
||||
ZRCola::keyseq_db::keyseq &seq = app->m_ks_db.idxChr[start];
|
||||
wxString ks_str;
|
||||
if (ZRCola::keyseq_db::GetSequenceAsText(seq.seq, seq.seq_len, ks_str))
|
||||
@@ -137,6 +148,17 @@ void wxZRColaCharGrid::OnSize(wxSizeEvent& event)
|
||||
for (int c = 0; c < cols; c++, i++)
|
||||
table->SetValue(r, c, i < (int)char_len ? wxString(1, m_chars[i]) : wxEmptyString);
|
||||
SetTable(table, true);
|
||||
if (!m_relevance.IsEmpty()) {
|
||||
const wxColour colour_def;
|
||||
const wxColour colour_irr = wxSystemSettings::GetColour(wxSYS_COLOUR_BTNHIGHLIGHT);
|
||||
for (int r = 0, i = 0; r < rows; r++)
|
||||
for (int c = 0; c < cols; c++, i++)
|
||||
SetCellBackgroundColour(r, c, i >= (int)char_len || ((unsigned short)(m_relevance[i/16]) & (1<<(i%16))) ? colour_def : colour_irr);
|
||||
} else {
|
||||
for (int r = 0, i = 0; r < rows; r++)
|
||||
for (int c = 0; c < cols; c++, i++)
|
||||
SetAttr(r, c, NULL);
|
||||
}
|
||||
m_regenerate = false;
|
||||
}
|
||||
|
||||
|
||||
@@ -58,6 +58,14 @@ public:
|
||||
///
|
||||
void SetCharacters(const wxString &chars);
|
||||
|
||||
///
|
||||
/// Sets new array of characters to display
|
||||
///
|
||||
/// \param[in] chars The string containing characters to display
|
||||
/// \param[in] relevance Bit-array of \p chars relevance (1=more relevant, 0=less relevant)
|
||||
///
|
||||
void SetCharacters(const wxString &chars, const wxArrayShort &relevance);
|
||||
|
||||
///
|
||||
/// Returns displayed characters
|
||||
///
|
||||
@@ -91,14 +99,15 @@ protected:
|
||||
DECLARE_EVENT_TABLE()
|
||||
|
||||
private:
|
||||
void Init(); // common part of all ctors
|
||||
void Init(); // common part of all ctors
|
||||
|
||||
protected:
|
||||
wxString m_chars; ///< Array of Unicode characters to display in the grid
|
||||
wxString m_chars; ///< Array of Unicode characters to display in the grid
|
||||
wxArrayShort m_relevance; ///< Bit-array of `m_chars` relevance
|
||||
|
||||
private:
|
||||
bool m_regenerate; ///< Force regenerate grid table
|
||||
bool m_isResizing; ///< Prevents nesting of OnSize() method.
|
||||
wxTimer m_timerToolTip; ///< Timer for displaying tooltip
|
||||
size_t m_toolTipIdx; ///< Index of cell for tooltip display
|
||||
bool m_regenerate; ///< Force regenerate grid table
|
||||
bool m_isResizing; ///< Prevents nesting of OnSize() method.
|
||||
wxTimer m_timerToolTip; ///< Timer for displaying tooltip
|
||||
size_t m_toolTipIdx; ///< Index of cell for tooltip display
|
||||
};
|
||||
|
||||
101
ZRCola/zrcolachrreq.cpp
Normal file
@@ -0,0 +1,101 @@
|
||||
/*
|
||||
Copyright 2015-2016 Amebis
|
||||
|
||||
This file is part of ZRCola.
|
||||
|
||||
ZRCola 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 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
ZRCola 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 ZRCola. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include "stdafx.h"
|
||||
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
// wxZRColaCharRequest
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
|
||||
wxZRColaCharRequest::wxZRColaCharRequest(wxWindow* parent) : wxZRColaCharRequestBase(parent)
|
||||
{
|
||||
m_character->PushEventHandler(new wxZRColaKeyHandler());
|
||||
m_context->PushEventHandler(new wxZRColaKeyHandler());
|
||||
}
|
||||
|
||||
|
||||
wxZRColaCharRequest::~wxZRColaCharRequest()
|
||||
{
|
||||
m_context->PopEventHandler(true);
|
||||
m_character->PopEventHandler(true);
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharRequest::OnOKButtonClick(wxCommandEvent& event)
|
||||
{
|
||||
event.Skip();
|
||||
|
||||
const wxString chr = m_character->GetValue();
|
||||
const wxString ctx = m_context->GetValue();
|
||||
wxString body;
|
||||
|
||||
body += _("Character") + wxT(": ");
|
||||
for (size_t i = 0, i_end = chr.Length(); i < i_end; i++) {
|
||||
if (chr[i] < 0x7f)
|
||||
body += chr[i];
|
||||
else
|
||||
body += wxString::Format(wxT("(U+%04X)"), chr[i]);
|
||||
}
|
||||
body += wxT('\n');
|
||||
if (!ctx.IsEmpty()) {
|
||||
body += _("Context") + wxT(": ");
|
||||
body += ctx;
|
||||
body += wxT('\n');
|
||||
}
|
||||
|
||||
wxLaunchDefaultBrowser(wxString::Format(wxT("mailto:janos.jezovnik@zrc-sazu.si&subject=%s&body=%s"),
|
||||
wxURLEncode(wxString((wxString(wxT("[ZRCola] ")) + _("Request a New Character")).ToUTF8())),
|
||||
wxURLEncode(body.ToUTF8())
|
||||
));
|
||||
}
|
||||
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
// wxPersistentZRColaCharRequest
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
|
||||
wxPersistentZRColaCharRequest::wxPersistentZRColaCharRequest(wxZRColaCharRequest *wnd) : wxPersistentDialog(wnd)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
void wxPersistentZRColaCharRequest::Save() const
|
||||
{
|
||||
wxPersistentDialog::Save();
|
||||
|
||||
auto wnd = static_cast<const wxZRColaCharRequest*>(GetWindow()); // dynamic_cast is not reliable as we are typically called late in the wxTopLevelWindowMSW destructor.
|
||||
|
||||
SaveValue(wxT("character"), wnd->m_character->GetValue());
|
||||
SaveValue(wxT("context"), wnd->m_context->GetValue());
|
||||
}
|
||||
|
||||
|
||||
bool wxPersistentZRColaCharRequest::Restore()
|
||||
{
|
||||
auto wnd = dynamic_cast<wxZRColaCharRequest*>(GetWindow());
|
||||
|
||||
wxString str;
|
||||
if (RestoreValue(wxT("character"), &str))
|
||||
wnd->m_character->SetValue(str);
|
||||
if (RestoreValue(wxT("context"), &str))
|
||||
wnd->m_context->SetValue(str);
|
||||
|
||||
return wxPersistentDialog::Restore();
|
||||
}
|
||||
65
ZRCola/zrcolachrreq.h
Normal file
@@ -0,0 +1,65 @@
|
||||
/*
|
||||
Copyright 2015-2016 Amebis
|
||||
|
||||
This file is part of ZRCola.
|
||||
|
||||
ZRCola 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 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
ZRCola 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 ZRCola. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
///
|
||||
/// Forward declarations
|
||||
///
|
||||
class wxZRColaCharRequest;
|
||||
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "zrcolagui.h"
|
||||
#include "zrcolakeyhndlr.h"
|
||||
|
||||
|
||||
///
|
||||
/// ZRCola New Character Request dialog
|
||||
///
|
||||
class wxZRColaCharRequest : public wxZRColaCharRequestBase
|
||||
{
|
||||
public:
|
||||
wxZRColaCharRequest(wxWindow* parent);
|
||||
virtual ~wxZRColaCharRequest();
|
||||
|
||||
friend class wxPersistentZRColaCharRequest; // Allow saving/restoring window state.
|
||||
|
||||
protected:
|
||||
virtual void OnOKButtonClick(wxCommandEvent& event);
|
||||
};
|
||||
|
||||
|
||||
|
||||
///
|
||||
/// Supports saving/restoring wxZRColaCharRequest state
|
||||
///
|
||||
class wxPersistentZRColaCharRequest : public wxPersistentDialog
|
||||
{
|
||||
public:
|
||||
wxPersistentZRColaCharRequest(wxZRColaCharRequest *wnd);
|
||||
|
||||
virtual void Save() const;
|
||||
virtual bool Restore();
|
||||
};
|
||||
|
||||
|
||||
inline wxPersistentObject *wxCreatePersistentObject(wxZRColaCharRequest *wnd)
|
||||
{
|
||||
return new wxPersistentZRColaCharRequest(wnd);
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
/*
|
||||
/*
|
||||
Copyright 2015-2016 Amebis
|
||||
|
||||
This file is part of ZRCola.
|
||||
@@ -34,20 +34,36 @@ wxZRColaCharSelect::wxZRColaCharSelect(wxWindow* parent) :
|
||||
m_searchThread(NULL),
|
||||
wxZRColaCharSelectBase(parent)
|
||||
{
|
||||
// Set tag lookup locale.
|
||||
wxLanguage language = dynamic_cast<ZRColaApp*>(wxTheApp)->m_lang_ui;
|
||||
if (wxLANGUAGE_DEFAULT == language ||
|
||||
wxLANGUAGE_ENGLISH <= language && language <= wxLANGUAGE_ENGLISH_ZIMBABWE) m_locale = MAKELCID(MAKELANGID(LANG_ENGLISH , SUBLANG_DEFAULT), SORT_DEFAULT);
|
||||
else if (wxLANGUAGE_RUSSIAN <= language && language <= wxLANGUAGE_RUSSIAN_UKRAINE ) m_locale = MAKELCID(MAKELANGID(LANG_RUSSIAN , SUBLANG_DEFAULT), SORT_DEFAULT);
|
||||
else if (wxLANGUAGE_SLOVENIAN == language ) m_locale = MAKELCID(MAKELANGID(LANG_SLOVENIAN, SUBLANG_DEFAULT), SORT_DEFAULT);
|
||||
else m_locale = MAKELCID(MAKELANGID(LANG_ENGLISH , SUBLANG_DEFAULT), SORT_DEFAULT);
|
||||
|
||||
Connect(wxID_ANY, wxEVT_SEARCH_COMPLETE, wxThreadEventHandler(wxZRColaCharSelect::OnSearchComplete), NULL, this);
|
||||
|
||||
m_search_more->SetLabel(_(L"▸ Search Options"));
|
||||
|
||||
m_unicode->SetValidator(wxHexValidator<wchar_t>(&m_char, wxNUM_VAL_DEFAULT, 4));
|
||||
|
||||
// Fill categories.
|
||||
ZRColaApp *app = (ZRColaApp*)wxTheApp;
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
for (size_t i = 0, n = app->m_cc_db.idxRnk.size(); i < n; i++) {
|
||||
const ZRCola::chrcat_db::chrcat &cc = app->m_cc_db.idxRnk[i];
|
||||
const auto &cc = app->m_cc_db.idxRnk[i];
|
||||
int idx = m_categories->Insert(wxGetTranslation(wxString(cc.name, cc.name_len), wxT("ZRCola-zrcdb")), i);
|
||||
m_categories->Check(idx);
|
||||
m_ccOrder.insert(std::make_pair(cc.id, idx));
|
||||
}
|
||||
|
||||
ResetResults();
|
||||
|
||||
NavigationState state;
|
||||
state.m_char = m_char;
|
||||
state.m_related.m_selected.SetCol(m_gridRelated->GetGridCursorCol());
|
||||
state.m_related.m_selected.SetRow(m_gridRelated->GetGridCursorRow());
|
||||
m_historyCursor = m_history.insert(m_history.end(), state);
|
||||
}
|
||||
|
||||
|
||||
@@ -66,7 +82,7 @@ void wxZRColaCharSelect::OnIdle(wxIdleEvent& event)
|
||||
|
||||
if (m_unicodeChanged) {
|
||||
if (m_unicode->GetValidator()->TransferFromWindow()) {
|
||||
ZRColaApp *app = (ZRColaApp*)wxTheApp;
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
|
||||
m_gridPreview->SetCellValue(wxString(1, m_char), 0, 0);
|
||||
|
||||
@@ -74,16 +90,31 @@ void wxZRColaCharSelect::OnIdle(wxIdleEvent& event)
|
||||
((ZRCola::character_db::character*)chr)->chr = m_char;
|
||||
size_t start;
|
||||
if (app->m_chr_db.idxChr.find(*(ZRCola::character_db::character*)chr, start)) {
|
||||
const ZRCola::character_db::character &chr = app->m_chr_db.idxChr[start];
|
||||
// Update characted rescription.
|
||||
const auto &chr = app->m_chr_db.idxChr[start];
|
||||
// Update character description.
|
||||
m_description->SetValue(wxString(chr.data, chr.desc_len));
|
||||
{
|
||||
// See if this character has a key sequence registered.
|
||||
char ks[sizeof(ZRCola::keyseq_db::keyseq)] = {};
|
||||
((ZRCola::keyseq_db::keyseq*)ks)->chr = m_char;
|
||||
ZRCola::keyseq_db::indexKey::size_type start;
|
||||
if (app->m_ks_db.idxChr.find(*(ZRCola::keyseq_db::keyseq*)ks, start)) {
|
||||
ZRCola::keyseq_db::keyseq &seq = app->m_ks_db.idxChr[start];
|
||||
wxString ks_str;
|
||||
if (ZRCola::keyseq_db::GetSequenceAsText(seq.seq, seq.seq_len, ks_str))
|
||||
m_shortcut->SetValue(ks_str);
|
||||
else
|
||||
m_shortcut->SetValue(wxEmptyString);
|
||||
} else
|
||||
m_shortcut->SetValue(wxEmptyString);
|
||||
}
|
||||
{
|
||||
char cc[sizeof(ZRCola::chrcat_db::chrcat)] = {};
|
||||
((ZRCola::chrcat_db::chrcat*)cc)->id = chr.cat;
|
||||
size_t start;
|
||||
// Update character category.
|
||||
if (app->m_cc_db.idxChrCat.find(*((ZRCola::chrcat_db::chrcat*)cc), start)) {
|
||||
const ZRCola::chrcat_db::chrcat &cat = app->m_cc_db.idxChrCat[start];
|
||||
const auto &cat = app->m_cc_db.idxChrCat[start];
|
||||
m_category->SetValue(wxGetTranslation(wxString(cat.name, cat.name_len), wxT("ZRCola-zrcdb")));
|
||||
} else
|
||||
m_category->SetValue(wxEmptyString);
|
||||
@@ -92,10 +123,51 @@ void wxZRColaCharSelect::OnIdle(wxIdleEvent& event)
|
||||
m_gridRelated->SetCharacters(wxString(chr.data + chr.desc_len, chr.rel_len));
|
||||
} else {
|
||||
m_description->SetValue(wxEmptyString);
|
||||
m_shortcut->SetValue(wxEmptyString);
|
||||
m_category->SetValue(wxEmptyString);
|
||||
m_gridRelated->ClearGrid();
|
||||
}
|
||||
m_gridRelated->Scroll(0, 0);
|
||||
|
||||
// Find character tags.
|
||||
std::list<std::wstring> tag_names;
|
||||
ZRCola::chrtag_db::chrtag ct = { m_char };
|
||||
size_t end;
|
||||
if (app->m_ct_db.idxChr.find(ct, start, end)) {
|
||||
for (size_t i = start; i < end; i++) {
|
||||
const ZRCola::chrtag_db::chrtag &ct = app->m_ct_db.idxChr[i];
|
||||
|
||||
// Find tag names.
|
||||
char tn[sizeof(ZRCola::tagname_db::tagname)] = {};
|
||||
((ZRCola::tagname_db::tagname*)tn)->locale = m_locale;
|
||||
((ZRCola::tagname_db::tagname*)tn)->tag = ct.tag;
|
||||
size_t start, end;
|
||||
if (app->m_tn_db.idxTag.find(*((ZRCola::tagname_db::tagname*)tn), start, end)) {
|
||||
for (size_t i = start; i < end; i++) {
|
||||
const ZRCola::tagname_db::tagname &tn = app->m_tn_db.idxTag[i];
|
||||
|
||||
// Add tag name to the list (prevent duplicates).
|
||||
for (auto name = tag_names.cbegin(), name_end = tag_names.cend();; ++name) {
|
||||
if (name == name_end) {
|
||||
// Add name to the list.
|
||||
tag_names.push_back(std::wstring(tn.name, tn.name + tn.name_len));
|
||||
break;
|
||||
} else if (ZRCola::tagname_db::tagname::CompareName(m_locale, name->data(), (unsigned __int16)name->length(), tn.name, tn.name_len) == 0)
|
||||
// Name is already on the list.
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
wxString tags;
|
||||
for (auto name = tag_names.cbegin(), name_end = tag_names.cend(); name != name_end; ++name) {
|
||||
if (!tags.empty())
|
||||
tags += _(", ");
|
||||
tags += *name;
|
||||
}
|
||||
m_tags->SetValue(tags);
|
||||
|
||||
m_gridRelated->GoToCell(m_historyCursor->m_related.m_selected);
|
||||
|
||||
wxGridCellCoords coord(m_gridResults->GetCharacterCoords(m_char));
|
||||
if (coord.GetRow() != -1 && coord.GetCol() != -1) {
|
||||
@@ -112,7 +184,7 @@ void wxZRColaCharSelect::OnIdle(wxIdleEvent& event)
|
||||
|
||||
wxString val(m_search->GetValue());
|
||||
if (!val.IsEmpty()) {
|
||||
ZRColaApp *app = (ZRColaApp*)wxTheApp;
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
|
||||
m_searchThread = new SearchThread(this);
|
||||
|
||||
@@ -120,7 +192,7 @@ void wxZRColaCharSelect::OnIdle(wxIdleEvent& event)
|
||||
|
||||
// Select categories.
|
||||
for (size_t i = 0, n = app->m_cc_db.idxRnk.size(); i < n; i++) {
|
||||
const ZRCola::chrcat_db::chrcat &cc = app->m_cc_db.idxRnk[i];
|
||||
const auto &cc = app->m_cc_db.idxRnk[i];
|
||||
if (m_categories->IsChecked(i))
|
||||
m_searchThread->m_cats.insert(cc.id);
|
||||
}
|
||||
@@ -146,6 +218,58 @@ void wxZRColaCharSelect::OnSearchText(wxCommandEvent& event)
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharSelect::OnSearchMore(wxHyperlinkEvent& event)
|
||||
{
|
||||
event.StopPropagation();
|
||||
|
||||
if (m_search_panel->IsShown()) {
|
||||
m_search_panel->Show(false);
|
||||
m_search_more->SetLabel(_(L"▸ Search Options"));
|
||||
} else {
|
||||
m_search_panel->Show(true);
|
||||
m_search_more->SetLabel(_(L"▾ Search Options"));
|
||||
}
|
||||
|
||||
this->Layout();
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharSelect::OnCategoriesAll(wxHyperlinkEvent& event)
|
||||
{
|
||||
event.StopPropagation();
|
||||
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
for (size_t i = 0, n = app->m_cc_db.idxRnk.size(); i < n; i++)
|
||||
m_categories->Check(i, true);
|
||||
|
||||
m_searchChanged = true;
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharSelect::OnCategoriesNone(wxHyperlinkEvent& event)
|
||||
{
|
||||
event.StopPropagation();
|
||||
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
for (size_t i = 0, n = app->m_cc_db.idxRnk.size(); i < n; i++)
|
||||
m_categories->Check(i, false);
|
||||
|
||||
m_searchChanged = true;
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharSelect::OnCategoriesInvert(wxHyperlinkEvent& event)
|
||||
{
|
||||
event.StopPropagation();
|
||||
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
for (size_t i = 0, n = app->m_cc_db.idxRnk.size(); i < n; i++)
|
||||
m_categories->Check(i, !m_categories->IsChecked(i));
|
||||
|
||||
m_searchChanged = true;
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharSelect::OnCategoriesToggle(wxCommandEvent& event)
|
||||
{
|
||||
event.Skip();
|
||||
@@ -162,7 +286,7 @@ void wxZRColaCharSelect::OnSearchComplete(wxThreadEvent& event)
|
||||
// Display results.
|
||||
wxString chars;
|
||||
chars.reserve(m_searchThread->m_hits.size());
|
||||
for (std::vector< std::pair<unsigned long, wchar_t> >::const_iterator i = m_searchThread->m_hits.cbegin(), i_end = m_searchThread->m_hits.cend(); i != i_end; ++i)
|
||||
for (auto i = m_searchThread->m_hits.cbegin(), i_end = m_searchThread->m_hits.cend(); i != i_end; ++i)
|
||||
chars += i->second;
|
||||
m_gridResults->SetCharacters(chars);
|
||||
|
||||
@@ -176,12 +300,11 @@ void wxZRColaCharSelect::OnSearchComplete(wxThreadEvent& event)
|
||||
|
||||
void wxZRColaCharSelect::OnResultSelectCell(wxGridEvent& event)
|
||||
{
|
||||
if (m_unicodeChanged) return;
|
||||
|
||||
wxString val(m_gridResults->GetCellValue(event.GetRow(), event.GetCol()));
|
||||
wchar_t c = val.IsEmpty() ? 0 : val[0];
|
||||
if (m_char != c) {
|
||||
m_char = c;
|
||||
m_unicode->GetValidator()->TransferToWindow();
|
||||
}
|
||||
if (!val.IsEmpty())
|
||||
NavigateTo(val[0]);
|
||||
}
|
||||
|
||||
|
||||
@@ -191,7 +314,7 @@ void wxZRColaCharSelect::OnResultCellDClick(wxGridEvent& event)
|
||||
|
||||
wxString val(m_gridResults->GetCellValue(event.GetRow(), event.GetCol()));
|
||||
if (!val.IsEmpty()) {
|
||||
m_char = val[0];
|
||||
NavigateTo(val[0]);
|
||||
wxCommandEvent e(wxEVT_COMMAND_BUTTON_CLICKED, wxID_OK);
|
||||
m_sdbSizerButtonsOK->GetEventHandler()->ProcessEvent(e);
|
||||
}
|
||||
@@ -205,7 +328,7 @@ void wxZRColaCharSelect::OnResultsKeyDown(wxKeyEvent& event)
|
||||
case WXK_NUMPAD_ENTER:
|
||||
wxString val(m_gridResults->GetCellValue(m_gridResults->GetCursorRow(), m_gridResults->GetCursorColumn()));
|
||||
if (!val.IsEmpty()) {
|
||||
m_char = val[0];
|
||||
NavigateTo(val[0]);
|
||||
wxCommandEvent e(wxEVT_COMMAND_BUTTON_CLICKED, wxID_OK);
|
||||
m_sdbSizerButtonsOK->GetEventHandler()->ProcessEvent(e);
|
||||
|
||||
@@ -220,9 +343,11 @@ void wxZRColaCharSelect::OnResultsKeyDown(wxKeyEvent& event)
|
||||
|
||||
void wxZRColaCharSelect::OnRecentSelectCell(wxGridEvent& event)
|
||||
{
|
||||
if (m_unicodeChanged) return;
|
||||
|
||||
wxString val(m_gridRecent->GetCellValue(event.GetRow(), event.GetCol()));
|
||||
m_char = val.IsEmpty() ? 0 : val[0];
|
||||
m_unicode->GetValidator()->TransferToWindow();
|
||||
if (!val.IsEmpty())
|
||||
NavigateTo(val[0]);
|
||||
}
|
||||
|
||||
|
||||
@@ -232,7 +357,7 @@ void wxZRColaCharSelect::OnRecentCellDClick(wxGridEvent& event)
|
||||
|
||||
wxString val(m_gridRecent->GetCellValue(event.GetRow(), event.GetCol()));
|
||||
if (!val.IsEmpty()) {
|
||||
m_char = val[0];
|
||||
NavigateTo(val[0]);
|
||||
wxCommandEvent e(wxEVT_COMMAND_BUTTON_CLICKED, wxID_OK);
|
||||
m_sdbSizerButtonsOK->GetEventHandler()->ProcessEvent(e);
|
||||
}
|
||||
@@ -246,7 +371,7 @@ void wxZRColaCharSelect::OnRecentKeyDown(wxKeyEvent& event)
|
||||
case WXK_NUMPAD_ENTER:
|
||||
wxString val(m_gridRecent->GetCellValue(m_gridRecent->GetCursorRow(), m_gridRecent->GetCursorColumn()));
|
||||
if (!val.IsEmpty()) {
|
||||
m_char = val[0];
|
||||
NavigateTo(val[0]);
|
||||
wxCommandEvent e(wxEVT_COMMAND_BUTTON_CLICKED, wxID_OK);
|
||||
m_sdbSizerButtonsOK->GetEventHandler()->ProcessEvent(e);
|
||||
|
||||
@@ -259,14 +384,6 @@ void wxZRColaCharSelect::OnRecentKeyDown(wxKeyEvent& event)
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharSelect::OnRelatedSelectCell(wxGridEvent& event)
|
||||
{
|
||||
wxString val(m_gridRelated->GetCellValue(event.GetRow(), event.GetCol()));
|
||||
m_char = val.IsEmpty() ? 0 : val[0];
|
||||
m_unicode->GetValidator()->TransferToWindow();
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharSelect::OnUnicodeText(wxCommandEvent& event)
|
||||
{
|
||||
event.Skip();
|
||||
@@ -275,6 +392,49 @@ void wxZRColaCharSelect::OnUnicodeText(wxCommandEvent& event)
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharSelect::OnPreviewKeyDown(wxKeyEvent& event)
|
||||
{
|
||||
int key_code = event.GetKeyCode();
|
||||
if (key_code == WXK_TAB != NULL) {
|
||||
wxNavigationKeyEvent eventNav;
|
||||
eventNav.SetDirection(!event.ShiftDown());
|
||||
eventNav.SetWindowChange(event.ControlDown());
|
||||
eventNav.SetEventObject(this);
|
||||
|
||||
if (HandleWindowEvent(eventNav))
|
||||
return;
|
||||
}
|
||||
|
||||
event.Skip();
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharSelect::OnNavigateBack(wxHyperlinkEvent& event)
|
||||
{
|
||||
event.StopPropagation();
|
||||
|
||||
NavigateBy(-1);
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharSelect::OnNavigateForward(wxHyperlinkEvent& event)
|
||||
{
|
||||
event.StopPropagation();
|
||||
|
||||
NavigateBy(+1);
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharSelect::OnRelatedSelectCell(wxGridEvent& event)
|
||||
{
|
||||
if (m_unicodeChanged) return;
|
||||
|
||||
wxString val(m_gridRelated->GetCellValue(event.GetRow(), event.GetCol()));
|
||||
if (!val.IsEmpty())
|
||||
NavigateTo(val[0]);
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharSelect::OnOKButtonClick(wxCommandEvent& event)
|
||||
{
|
||||
event.Skip();
|
||||
@@ -295,13 +455,13 @@ void wxZRColaCharSelect::OnOKButtonClick(wxCommandEvent& event)
|
||||
void wxZRColaCharSelect::ResetResults()
|
||||
{
|
||||
// Fill the results.
|
||||
ZRColaApp *app = (ZRColaApp*)wxTheApp;
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
size_t i, n = app->m_chr_db.idxChr.size();
|
||||
wxString val;
|
||||
val.reserve(n);
|
||||
for (i = 0; i < n; i++) {
|
||||
const ZRCola::character_db::character &chr = app->m_chr_db.idxChr[i];
|
||||
std::map<ZRCola::chrcatid_t, int>::const_iterator idx = m_ccOrder.find(chr.cat);
|
||||
const auto &chr = app->m_chr_db.idxChr[i];
|
||||
auto idx = m_ccOrder.find(chr.cat);
|
||||
if (idx == m_ccOrder.end() || m_categories->IsChecked(idx->second))
|
||||
val += chr.chr;
|
||||
}
|
||||
@@ -309,6 +469,73 @@ void wxZRColaCharSelect::ResetResults()
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharSelect::NavigateBy(int offset)
|
||||
{
|
||||
if (offset != 0) {
|
||||
// Update history state
|
||||
m_historyCursor->m_related.m_selected.SetCol(m_gridRelated->GetGridCursorCol());
|
||||
m_historyCursor->m_related.m_selected.SetRow(m_gridRelated->GetGridCursorRow());
|
||||
|
||||
if (offset < 0) {
|
||||
while (m_historyCursor != m_history.begin() && offset) {
|
||||
--m_historyCursor; offset++;
|
||||
m_char = m_historyCursor->m_char;
|
||||
m_unicodeChanged = true;
|
||||
}
|
||||
} else {
|
||||
while (offset) {
|
||||
++m_historyCursor;
|
||||
if (m_historyCursor == m_history.end()) {
|
||||
// We're past the last history entry.
|
||||
--m_historyCursor;
|
||||
break;
|
||||
}
|
||||
offset--;
|
||||
m_char = m_historyCursor->m_char;
|
||||
m_unicodeChanged = true;
|
||||
}
|
||||
}
|
||||
|
||||
m_navigateBack->Enable(m_historyCursor != m_history.begin());
|
||||
auto cursor_next = m_historyCursor;
|
||||
++cursor_next;
|
||||
m_navigateForward->Enable(cursor_next != m_history.end());
|
||||
|
||||
if (m_unicodeChanged)
|
||||
m_unicode->GetValidator()->TransferToWindow();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaCharSelect::NavigateTo(wchar_t c)
|
||||
{
|
||||
if (m_char != c) {
|
||||
// Update history state
|
||||
m_historyCursor->m_related.m_selected.SetCol(m_gridRelated->GetGridCursorCol());
|
||||
m_historyCursor->m_related.m_selected.SetRow(m_gridRelated->GetGridCursorRow());
|
||||
|
||||
++m_historyCursor;
|
||||
|
||||
// Create new state.
|
||||
NavigationState state;
|
||||
state.m_char = m_char = c;
|
||||
state.m_related.m_selected.SetCol(0);
|
||||
state.m_related.m_selected.SetRow(0);
|
||||
m_historyCursor = m_history.insert(m_historyCursor, state);
|
||||
|
||||
// Purge the history's tail.
|
||||
auto cursor_next = m_historyCursor;
|
||||
++cursor_next;
|
||||
m_history.erase(cursor_next, m_history.end());
|
||||
|
||||
m_unicode->GetValidator()->TransferToWindow();
|
||||
|
||||
m_navigateBack->Enable(true);
|
||||
m_navigateForward->Enable(false);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
wxZRColaCharSelect::SearchThread::SearchThread(wxZRColaCharSelect *parent) :
|
||||
m_parent(parent),
|
||||
wxThread(wxTHREAD_JOINABLE)
|
||||
@@ -320,18 +547,25 @@ wxZRColaCharSelect::SearchThread::SearchThread(wxZRColaCharSelect *parent) :
|
||||
|
||||
wxThread::ExitCode wxZRColaCharSelect::SearchThread::Entry()
|
||||
{
|
||||
ZRColaApp *app = (ZRColaApp*)wxTheApp;
|
||||
std::map<wchar_t, unsigned long> hits;
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
std::map<wchar_t, ZRCola::charrank_t> hits;
|
||||
|
||||
if (TestDestroy()) return (wxThread::ExitCode)1;
|
||||
|
||||
{
|
||||
// Search by indexes and merge results.
|
||||
std::map<wchar_t, unsigned long> hits_sub;
|
||||
// Search by tags: Get tags with given names. Then, get characters of found tags.
|
||||
std::map<ZRCola::tagid_t, unsigned __int16> hits_tag;
|
||||
if (!app->m_tn_db.Search(m_search.c_str(), m_parent->m_locale, hits_tag, TestDestroyS, this)) return (wxThread::ExitCode)1;
|
||||
if (!app->m_ct_db.Search(hits_tag, app->m_chr_db, m_cats, hits, TestDestroyS, this)) return (wxThread::ExitCode)1;
|
||||
}
|
||||
|
||||
{
|
||||
// Search by description and merge results.
|
||||
std::map<wchar_t, ZRCola::charrank_t> hits_sub;
|
||||
if (!app->m_chr_db.Search(m_search.c_str(), m_cats, hits, hits_sub, TestDestroyS, this)) return (wxThread::ExitCode)1;
|
||||
for (std::map<wchar_t, unsigned long>::const_iterator i = hits_sub.cbegin(), i_end = hits_sub.cend(); i != i_end; ++i) {
|
||||
for (auto i = hits_sub.cbegin(), i_end = hits_sub.cend(); i != i_end; ++i) {
|
||||
if (TestDestroy()) return (wxThread::ExitCode)1;
|
||||
std::map<wchar_t, unsigned long>::iterator idx = hits.find(i->first);
|
||||
auto idx = hits.find(i->first);
|
||||
if (idx == hits.end())
|
||||
hits.insert(std::make_pair(i->first, i->second / 4));
|
||||
else
|
||||
@@ -339,13 +573,23 @@ wxThread::ExitCode wxZRColaCharSelect::SearchThread::Entry()
|
||||
}
|
||||
}
|
||||
|
||||
// Now sort the characters by rank.
|
||||
m_hits.reserve(hits.size());
|
||||
for (std::map<wchar_t, unsigned long>::const_iterator i = hits.cbegin(), i_end = hits.cend(); i != i_end; ++i) {
|
||||
// Get best rank.
|
||||
ZRCola::charrank_t rank_ref = 0;
|
||||
for (auto i = hits.cbegin(), i_end = hits.cend(); i != i_end; ++i) {
|
||||
if (TestDestroy()) return (wxThread::ExitCode)1;
|
||||
m_hits.push_back(std::make_pair(i->second, i->first));
|
||||
if (i->second > rank_ref)
|
||||
rank_ref = i->second;
|
||||
}
|
||||
std::qsort(m_hits.data(), m_hits.size(), sizeof(std::pair<unsigned long, wchar_t>), CompareHits);
|
||||
|
||||
// Now sort the characters by rank (taking only top 3/4 by rank).
|
||||
ZRCola::charrank_t rank_threshold = rank_ref*3/4;
|
||||
m_hits.reserve(hits.size());
|
||||
for (auto i = hits.cbegin(), i_end = hits.cend(); i != i_end; ++i) {
|
||||
if (TestDestroy()) return (wxThread::ExitCode)1;
|
||||
if (i->second > rank_threshold)
|
||||
m_hits.push_back(std::make_pair(i->second, i->first));
|
||||
}
|
||||
std::qsort(m_hits.data(), m_hits.size(), sizeof(std::pair<ZRCola::charrank_t, wchar_t>), CompareHits);
|
||||
|
||||
// Signal the event handler that this thread is going to be destroyed.
|
||||
// NOTE: here we assume that using the m_parent pointer is safe,
|
||||
@@ -358,8 +602,8 @@ wxThread::ExitCode wxZRColaCharSelect::SearchThread::Entry()
|
||||
|
||||
int __cdecl wxZRColaCharSelect::SearchThread::CompareHits(const void *a, const void *b)
|
||||
{
|
||||
const std::pair<unsigned long, wchar_t> *_a = (const std::pair<unsigned long, wchar_t>*)a;
|
||||
const std::pair<unsigned long, wchar_t> *_b = (const std::pair<unsigned long, wchar_t>*)b;
|
||||
const std::pair<ZRCola::charrank_t, wchar_t> *_a = (const std::pair<ZRCola::charrank_t, wchar_t>*)a;
|
||||
const std::pair<ZRCola::charrank_t, wchar_t> *_b = (const std::pair<ZRCola::charrank_t, wchar_t>*)b;
|
||||
|
||||
if (_a->first > _b->first) return -1;
|
||||
else if (_a->first < _b->first) return 1;
|
||||
@@ -390,37 +634,51 @@ void wxPersistentZRColaCharSelect::Save() const
|
||||
{
|
||||
wxPersistentDialog::Save();
|
||||
|
||||
const wxZRColaCharSelect * const wnd = static_cast<const wxZRColaCharSelect*>(GetWindow());
|
||||
auto wnd = static_cast<const wxZRColaCharSelect*>(GetWindow()); // dynamic_cast is not reliable as we are typically called late in the wxTopLevelWindowMSW destructor.
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
|
||||
SaveValue(wxT("recentChars"), wnd->m_gridRecent->GetCharacters());
|
||||
|
||||
ZRColaApp *app = (ZRColaApp*)wxTheApp;
|
||||
for (size_t i = 0, n = app->m_cc_db.idxRnk.size(); i < n; i++) {
|
||||
const ZRCola::chrcat_db::chrcat &cc = app->m_cc_db.idxRnk[i];
|
||||
const auto &cc = app->m_cc_db.idxRnk[i];
|
||||
wxString name(wxT("category"));
|
||||
name.Append(cc.id.data, _countof(cc.id.data));
|
||||
SaveValue(name, wnd->m_categories->IsChecked(i));
|
||||
}
|
||||
|
||||
SaveValue(wxT("searchPanel"), wnd->m_search_panel->IsShown());
|
||||
}
|
||||
|
||||
|
||||
bool wxPersistentZRColaCharSelect::Restore()
|
||||
{
|
||||
wxZRColaCharSelect * const wnd = static_cast<wxZRColaCharSelect*>(GetWindow());
|
||||
auto wnd = dynamic_cast<wxZRColaCharSelect*>(GetWindow());
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
|
||||
wxString recent;
|
||||
if (RestoreValue(wxT("recentChars"), &recent))
|
||||
wnd->m_gridRecent->SetCharacters(recent);
|
||||
|
||||
ZRColaApp *app = (ZRColaApp*)wxTheApp;
|
||||
for (size_t i = 0, n = app->m_cc_db.idxRnk.size(); i < n; i++) {
|
||||
const ZRCola::chrcat_db::chrcat &cc = app->m_cc_db.idxRnk[i];
|
||||
const auto &cc = app->m_cc_db.idxRnk[i];
|
||||
wxString name(wxT("category"));
|
||||
name.Append(cc.id.data, _countof(cc.id.data));
|
||||
bool val;
|
||||
if (RestoreValue(name, &val))
|
||||
wnd->m_categories->Check(i, val);
|
||||
}
|
||||
|
||||
bool search_panel;
|
||||
if (RestoreValue(wxT("searchPanel"), &search_panel)) {
|
||||
if (search_panel) {
|
||||
wnd->m_search_panel->Show(true);
|
||||
wnd->m_search_more->SetLabel(_(L"▾ Search Options"));
|
||||
} else {
|
||||
wnd->m_search_panel->Show(false);
|
||||
wnd->m_search_more->SetLabel(_(L"▸ Search Options"));
|
||||
}
|
||||
}
|
||||
|
||||
wnd->ResetResults();
|
||||
|
||||
return wxPersistentDialog::Restore();
|
||||
|
||||
@@ -32,7 +32,9 @@ class wxPersistentZRColaCharSelect;
|
||||
#include <wxex/persist/dialog.h>
|
||||
#include <wx/event.h>
|
||||
#include <wx/thread.h>
|
||||
#include <list>
|
||||
#include <map>
|
||||
#include <vector>
|
||||
|
||||
|
||||
wxDECLARE_EVENT(wxEVT_SEARCH_COMPLETE, wxThreadEvent);
|
||||
@@ -53,6 +55,10 @@ public:
|
||||
protected:
|
||||
virtual void OnIdle(wxIdleEvent& event);
|
||||
virtual void OnSearchText(wxCommandEvent& event);
|
||||
virtual void OnSearchMore(wxHyperlinkEvent& event);
|
||||
virtual void OnCategoriesAll(wxHyperlinkEvent& event);
|
||||
virtual void OnCategoriesNone(wxHyperlinkEvent& event);
|
||||
virtual void OnCategoriesInvert(wxHyperlinkEvent& event);
|
||||
virtual void OnCategoriesToggle(wxCommandEvent& event);
|
||||
void OnSearchComplete(wxThreadEvent& event);
|
||||
virtual void OnResultSelectCell(wxGridEvent& event);
|
||||
@@ -61,16 +67,22 @@ protected:
|
||||
virtual void OnRecentSelectCell(wxGridEvent& event);
|
||||
virtual void OnRecentCellDClick(wxGridEvent& event);
|
||||
virtual void OnRecentKeyDown(wxKeyEvent& event);
|
||||
virtual void OnRelatedSelectCell(wxGridEvent& event);
|
||||
virtual void OnNavigateBack(wxHyperlinkEvent& event);
|
||||
virtual void OnNavigateForward(wxHyperlinkEvent& event);
|
||||
virtual void OnUnicodeText(wxCommandEvent& event);
|
||||
virtual void OnPreviewKeyDown(wxKeyEvent& event);
|
||||
virtual void OnRelatedSelectCell(wxGridEvent& event);
|
||||
virtual void OnOKButtonClick(wxCommandEvent& event);
|
||||
|
||||
void ResetResults();
|
||||
void NavigateBy(int offset);
|
||||
void NavigateTo(wchar_t c);
|
||||
|
||||
public:
|
||||
wchar_t m_char; ///< Currently selected character (0 when none)
|
||||
|
||||
protected:
|
||||
LCID m_locale; ///< Locale for tag lookup
|
||||
bool m_searchChanged; ///< Did Search field or category selection change?
|
||||
std::map<ZRCola::chrcatid_t, int> m_ccOrder; ///< Character category order
|
||||
bool m_unicodeChanged; ///< Did Unicode field change?
|
||||
@@ -92,11 +104,25 @@ protected:
|
||||
public:
|
||||
std::wstring m_search; ///< Search phrase
|
||||
std::set<ZRCola::chrcatid_t> m_cats; ///< Search categories
|
||||
std::vector< std::pair<unsigned long, wchar_t> > m_hits; ///< Search results
|
||||
std::vector<std::pair<ZRCola::charrank_t, wchar_t> > m_hits; ///< Search results
|
||||
|
||||
protected:
|
||||
wxZRColaCharSelect *m_parent; ///< Thread owner
|
||||
} *m_searchThread; ///< Search thread
|
||||
|
||||
|
||||
///
|
||||
/// Navigation state
|
||||
///
|
||||
struct NavigationState
|
||||
{
|
||||
wchar_t m_char;
|
||||
struct {
|
||||
wxGridCellCoords m_selected;
|
||||
} m_related;
|
||||
};
|
||||
std::list<NavigationState> m_history; ///< Navigation history
|
||||
std::list<NavigationState>::iterator m_historyCursor; ///< Navigation history cursor
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -86,14 +86,15 @@ void wxZRColaComposerPanel::SynchronizePanels()
|
||||
if (m_decomposedChanged) {
|
||||
m_timerSave.Stop();
|
||||
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
wxString src;
|
||||
size_t len = GetValue(m_decomposed, src);
|
||||
|
||||
std::wstring norm;
|
||||
((ZRColaApp*)wxTheApp)->m_t_db.Decompose(src.data(), len, norm, &m_mapping1);
|
||||
app->m_t_db.Decompose(src.data(), len, norm, &m_mapping1);
|
||||
|
||||
std::wstring dst;
|
||||
((ZRColaApp*)wxTheApp)->m_t_db.Compose(norm.data(), norm.size(), dst, &m_mapping2);
|
||||
app->m_t_db.Compose(norm.data(), norm.size(), dst, &m_mapping2);
|
||||
|
||||
m_decomposed->GetSelection(&m_selDecomposed.first, &m_selDecomposed.second);
|
||||
|
||||
@@ -115,7 +116,7 @@ void wxZRColaComposerPanel::SynchronizePanels()
|
||||
wxString src;
|
||||
size_t len = GetValue(m_composed, src);
|
||||
|
||||
ZRColaApp *app = (ZRColaApp*)wxTheApp;
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
std::wstring dst;
|
||||
wxZRColaFrame *mainWnd = dynamic_cast<wxZRColaFrame*>(wxGetActiveWindow());
|
||||
if (mainWnd)
|
||||
@@ -382,7 +383,7 @@ wxString wxPersistentZRColaComposerPanel::GetKind() const
|
||||
|
||||
void wxPersistentZRColaComposerPanel::Save() const
|
||||
{
|
||||
const wxZRColaComposerPanel * const wnd = static_cast<const wxZRColaComposerPanel*>(GetWindow());
|
||||
auto const wnd = static_cast<const wxZRColaComposerPanel*>(GetWindow()); // dynamic_cast is not reliable as we are typically called late in the wxTopLevelWindowMSW destructor.
|
||||
|
||||
SaveValue(wxT("splitDecomposed"), wnd->m_splitterDecomposed->GetSashPosition());
|
||||
SaveValue(wxT("splitComposed" ), wnd->m_splitterComposed ->GetSashPosition());
|
||||
@@ -391,7 +392,7 @@ void wxPersistentZRColaComposerPanel::Save() const
|
||||
|
||||
bool wxPersistentZRColaComposerPanel::Restore()
|
||||
{
|
||||
wxZRColaComposerPanel * const wnd = static_cast<wxZRColaComposerPanel*>(GetWindow());
|
||||
auto wnd = dynamic_cast<wxZRColaComposerPanel*>(GetWindow());
|
||||
|
||||
int sashVal;
|
||||
|
||||
|
||||
@@ -49,6 +49,9 @@ wxBEGIN_EVENT_TABLE(wxZRColaFrame, wxZRColaFrameBase)
|
||||
EVT_MENU (wxID_PANEL_CHRGRPS , wxZRColaFrame::OnPanelCharacterCatalog )
|
||||
EVT_MENU (wxID_FOCUS_CHARACTER_CATALOG , wxZRColaFrame::OnPanelCharacterCatalogFocus )
|
||||
|
||||
EVT_MENU (wxID_HELP_INSTRUCTIONS , wxZRColaFrame::OnHelpInstructions )
|
||||
EVT_MENU (wxID_HELP_SHORTCUTS , wxZRColaFrame::OnHelpShortcuts )
|
||||
|
||||
EVT_MENU (wxID_HELP_REQCHAR , wxZRColaFrame::OnHelpReqChar )
|
||||
EVT_MENU (wxID_HELP_UPDATE , wxZRColaFrame::OnHelpUpdate )
|
||||
EVT_MENU (wxID_ABOUT , wxZRColaFrame::OnHelpAbout )
|
||||
@@ -59,6 +62,7 @@ wxZRColaFrame::wxZRColaFrame() :
|
||||
m_hWndSource(NULL),
|
||||
m_chrSelect(NULL),
|
||||
m_settings(NULL),
|
||||
m_chrReq(NULL),
|
||||
wxZRColaFrameBase(NULL)
|
||||
{
|
||||
{
|
||||
@@ -96,15 +100,12 @@ wxZRColaFrame::wxZRColaFrame() :
|
||||
m_chrSelect = new wxZRColaCharSelect(this);
|
||||
wxPersistentRegisterAndRestore<wxZRColaCharSelect>(m_chrSelect);
|
||||
|
||||
m_chrReq = new wxZRColaCharRequest(this);
|
||||
wxPersistentRegisterAndRestore<wxZRColaCharRequest>(m_chrReq);
|
||||
|
||||
// Set focus.
|
||||
m_panel->m_decomposed->SetFocus();
|
||||
|
||||
// Register global hotkey(s).
|
||||
if (!RegisterHotKey(wxZRColaHKID_INVOKE_COMPOSE, wxMOD_WIN, VK_F5))
|
||||
wxMessageBox(_("ZRCola keyboard shortcut Win+F5 could not be registered. Some functionality will not be available."), _("Warning"), wxOK | wxICON_WARNING);
|
||||
if (!RegisterHotKey(wxZRColaHKID_INVOKE_DECOMPOSE, wxMOD_WIN, VK_F6))
|
||||
wxMessageBox(_("ZRCola keyboard shortcut Win+F6 could not be registered. Some functionality will not be available."), _("Warning"), wxOK | wxICON_WARNING);
|
||||
|
||||
#if defined(__WXMSW__)
|
||||
// Register notification sink for language detection.
|
||||
m_ulRefCount = 1;
|
||||
@@ -134,11 +135,21 @@ wxZRColaFrame::wxZRColaFrame() :
|
||||
|
||||
// Restore persistent state of wxAuiManager manually, since m_mgr is not on the heap.
|
||||
wxPersistentAuiManager(&m_mgr).Restore();
|
||||
|
||||
// Register global hotkey(s).
|
||||
if (!RegisterHotKey(wxZRColaHKID_INVOKE_COMPOSE, wxMOD_WIN, VK_F5))
|
||||
wxMessageBox(_("ZRCola keyboard shortcut Win+F5 could not be registered. Some functionality will not be available."), _("Warning"), wxOK | wxICON_WARNING);
|
||||
if (!RegisterHotKey(wxZRColaHKID_INVOKE_DECOMPOSE, wxMOD_WIN, VK_F6))
|
||||
wxMessageBox(_("ZRCola keyboard shortcut Win+F6 could not be registered. Some functionality will not be available."), _("Warning"), wxOK | wxICON_WARNING);
|
||||
}
|
||||
|
||||
|
||||
wxZRColaFrame::~wxZRColaFrame()
|
||||
{
|
||||
// Unregister global hotkey(s).
|
||||
UnregisterHotKey(wxZRColaHKID_INVOKE_DECOMPOSE);
|
||||
UnregisterHotKey(wxZRColaHKID_INVOKE_COMPOSE);
|
||||
|
||||
#if defined(__WXMSW__)
|
||||
if (m_tfSource) {
|
||||
m_tfSource->UnadviseSink(m_dwCookie);
|
||||
@@ -146,9 +157,8 @@ wxZRColaFrame::~wxZRColaFrame()
|
||||
}
|
||||
#endif
|
||||
|
||||
// Unregister global hotkey(s).
|
||||
UnregisterHotKey(wxZRColaHKID_INVOKE_DECOMPOSE);
|
||||
UnregisterHotKey(wxZRColaHKID_INVOKE_COMPOSE);
|
||||
if (m_chrReq)
|
||||
delete m_chrReq;
|
||||
|
||||
if (m_chrSelect)
|
||||
delete m_chrSelect;
|
||||
@@ -336,9 +346,39 @@ void wxZRColaFrame::OnPanelCharacterCatalogFocus(wxCommandEvent& event)
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaFrame::OnHelpInstructions(wxCommandEvent& event)
|
||||
{
|
||||
wxLaunchDefaultBrowser(_("http://zrcola.zrc-sazu.si/en/info/instructions/"));
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaFrame::OnHelpShortcuts(wxCommandEvent& event)
|
||||
{
|
||||
winstd::tstring pdf_path;
|
||||
|
||||
#ifdef __WXMSW__
|
||||
// Search and try to launch installed PDF.
|
||||
INSTALLSTATE pdf_is = ::MsiGetComponentPath(_T(PRODUCT_VERSION_GUID), _T("{68AC2C38-10E2-41A3-B92C-844C03FFDF6A}"), pdf_path);
|
||||
if ((pdf_is == INSTALLSTATE_LOCAL || pdf_is == INSTALLSTATE_SOURCE) &&
|
||||
wxFileExists(pdf_path) &&
|
||||
(int)::ShellExecute(GetHWND(), NULL, pdf_path.c_str(), NULL, NULL, SW_SHOWNORMAL) > 32) return;
|
||||
#endif
|
||||
|
||||
// Search and try to launch local PDF copy.
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
pdf_path = app->GetDatabasePath();
|
||||
pdf_path += _T("ZRCola_keyboard.pdf");
|
||||
if (wxFileExists(pdf_path) &&
|
||||
(int)::ShellExecute(GetHWND(), NULL, pdf_path.c_str(), NULL, NULL, SW_SHOWNORMAL) > 32) return;
|
||||
|
||||
// When everything else fail, try the online version.
|
||||
wxLaunchDefaultBrowser(_("http://zrcola.zrc-sazu.si/wp-content/uploads/2016/06/ZRCola_tipkovnica_Jun2016.pdf"));
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaFrame::OnHelpReqChar(wxCommandEvent& event)
|
||||
{
|
||||
wxLaunchDefaultBrowser(_("http://zrcola-2.amebis.si/en/contact/"));
|
||||
m_chrReq->ShowModal();
|
||||
}
|
||||
|
||||
|
||||
@@ -419,7 +459,7 @@ void wxZRColaFrame::DoSend(const wxString& str)
|
||||
{
|
||||
// Prepare the INPUT table.
|
||||
wxString::size_type n = str.length();
|
||||
wxString::const_iterator i_str = str.begin();
|
||||
auto i_str = str.begin();
|
||||
std::vector<INPUT> input;
|
||||
input.reserve(n*2);
|
||||
for (std::vector<INPUT>::size_type i = 0; i < n; i++, i_str++) {
|
||||
@@ -509,23 +549,21 @@ wxPersistentZRColaFrame::wxPersistentZRColaFrame(wxZRColaFrame *wnd) : wxPersist
|
||||
|
||||
void wxPersistentZRColaFrame::Save() const
|
||||
{
|
||||
const wxZRColaFrame * const wnd = static_cast<const wxZRColaFrame*>(GetWindow());
|
||||
wxPersistentTLW::Save();
|
||||
|
||||
auto wnd = static_cast<const wxZRColaFrame*>(GetWindow()); // dynamic_cast is not reliable as we are typically called late in the wxTopLevelWindowMSW destructor.
|
||||
|
||||
wxPersistentZRColaComposerPanel(wnd->m_panel).Save();
|
||||
wxPersistentZRColaCharacterCatalogPanel(wnd->m_panelChrCat).Save();
|
||||
|
||||
wxPersistentTLW::Save();
|
||||
}
|
||||
|
||||
|
||||
bool wxPersistentZRColaFrame::Restore()
|
||||
{
|
||||
const bool r = wxPersistentTLW::Restore();
|
||||
|
||||
wxZRColaFrame * const wnd = static_cast<wxZRColaFrame*>(GetWindow());
|
||||
auto wnd = dynamic_cast<wxZRColaFrame*>(GetWindow());
|
||||
|
||||
wxPersistentZRColaCharacterCatalogPanel(wnd->m_panelChrCat).Restore();
|
||||
wxPersistentZRColaComposerPanel(wnd->m_panel).Restore();
|
||||
|
||||
return r;
|
||||
return wxPersistentTLW::Restore();
|
||||
}
|
||||
|
||||
@@ -27,6 +27,7 @@ class wxZRColaFrame;
|
||||
|
||||
#include "zrcolagui.h"
|
||||
#include "zrcolachrslct.h"
|
||||
#include "zrcolachrreq.h"
|
||||
#include "zrcolasettings.h"
|
||||
#include <zrcola/language.h>
|
||||
#include <wx/taskbar.h>
|
||||
@@ -85,6 +86,8 @@ protected:
|
||||
void OnPanelCharacterCatalogUpdate(wxUpdateUIEvent& event);
|
||||
void OnPanelCharacterCatalog(wxCommandEvent& event);
|
||||
void OnPanelCharacterCatalogFocus(wxCommandEvent& event);
|
||||
void OnHelpInstructions(wxCommandEvent& event);
|
||||
void OnHelpShortcuts(wxCommandEvent& event);
|
||||
void OnHelpReqChar(wxCommandEvent& event);
|
||||
void OnHelpUpdate(wxCommandEvent& event);
|
||||
void OnHelpAbout(wxCommandEvent& event);
|
||||
@@ -118,6 +121,7 @@ protected:
|
||||
WXHWND m_hWndSource; ///< Handle of the active window, when the ZRCola hotkey was pressed
|
||||
wxTaskBarIcon *m_taskBarIcon; ///< Taskbar icon
|
||||
wxZRColaCharSelect *m_chrSelect; ///< Character selection dialog
|
||||
wxZRColaCharRequest *m_chrReq; ///< Request a New Character dialog
|
||||
wxZRColaSettings *m_settings; ///< Configuration dialog
|
||||
};
|
||||
|
||||
|
||||
@@ -75,7 +75,7 @@ wxZRColaFrameBase::wxZRColaFrameBase( wxWindow* parent, wxWindowID id, const wxS
|
||||
m_menuEdit->AppendSeparator();
|
||||
|
||||
wxMenuItem* m_menuCharSelect;
|
||||
m_menuCharSelect = new wxMenuItem( m_menuEdit, wxID_CHARACTER_SELECTOR, wxString( _("C&haracter Selector...") ) + wxT('\t') + wxT("F8"), _("Display character selector to select character to insert into text"), wxITEM_NORMAL );
|
||||
m_menuCharSelect = new wxMenuItem( m_menuEdit, wxID_CHARACTER_SELECTOR, wxString( _("Find C&haracter...") ) + wxT('\t') + wxT("F8"), _("Display character search to select character to insert into text"), wxITEM_NORMAL );
|
||||
#ifdef __WXMSW__
|
||||
m_menuCharSelect->SetBitmaps( wxIcon( wxT("char_select.ico"), wxBITMAP_TYPE_ICO_RESOURCE, 16, 16 ) );
|
||||
#elif (defined( __WXGTK__ ) || defined( __WXOSX__ ))
|
||||
@@ -138,6 +138,16 @@ wxZRColaFrameBase::wxZRColaFrameBase( wxWindow* parent, wxWindowID id, const wxS
|
||||
m_menubar->Append( m_menuView, _("&View") );
|
||||
|
||||
m_menuHelp = new wxMenu();
|
||||
wxMenuItem* m_menuHelpInstructions;
|
||||
m_menuHelpInstructions = new wxMenuItem( m_menuHelp, wxID_HELP_INSTRUCTIONS, wxString( _("&Instructions...") ) + wxT('\t') + wxT("F1"), _("Open a web site with product instructions"), wxITEM_NORMAL );
|
||||
m_menuHelp->Append( m_menuHelpInstructions );
|
||||
|
||||
wxMenuItem* m_menuHelpShortcuts;
|
||||
m_menuHelpShortcuts = new wxMenuItem( m_menuHelp, wxID_HELP_SHORTCUTS, wxString( _("Keyboard &Shortcuts...") ) , _("Open a list of keyboard shortcuts"), wxITEM_NORMAL );
|
||||
m_menuHelp->Append( m_menuHelpShortcuts );
|
||||
|
||||
m_menuHelp->AppendSeparator();
|
||||
|
||||
wxMenuItem* m_menuHelpReqChar;
|
||||
m_menuHelpReqChar = new wxMenuItem( m_menuHelp, wxID_HELP_REQCHAR, wxString( _("&Request a new character...") ) , _("Submit a request to ZRC to add a new character"), wxITEM_NORMAL );
|
||||
m_menuHelp->Append( m_menuHelpReqChar );
|
||||
@@ -149,7 +159,7 @@ wxZRColaFrameBase::wxZRColaFrameBase( wxWindow* parent, wxWindowID id, const wxS
|
||||
m_menuHelp->AppendSeparator();
|
||||
|
||||
wxMenuItem* m_menuHelpAbout;
|
||||
m_menuHelpAbout = new wxMenuItem( m_menuHelp, wxID_ABOUT, wxString( wxEmptyString ) , wxEmptyString, wxITEM_NORMAL );
|
||||
m_menuHelpAbout = new wxMenuItem( m_menuHelp, wxID_ABOUT, wxString( _("&About...") ) , wxEmptyString, wxITEM_NORMAL );
|
||||
m_menuHelp->Append( m_menuHelpAbout );
|
||||
|
||||
m_menubar->Append( m_menuHelp, _("&Help") );
|
||||
@@ -167,7 +177,7 @@ wxZRColaFrameBase::wxZRColaFrameBase( wxWindow* parent, wxWindowID id, const wxS
|
||||
m_mgr.AddPane( m_toolbarEdit, wxAuiPaneInfo().Name( wxT("toolbarEdit") ).Top().Caption( _("Edit") ).PinButton( true ).Dock().Resizable().FloatingSize( wxSize( -1,-1 ) ).LeftDockable( false ).RightDockable( false ).Row( 0 ).Layer( 1 ).ToolbarPane() );
|
||||
|
||||
m_toolbarCompose = new wxAuiToolBar( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxAUI_TB_HORZ_LAYOUT );
|
||||
m_toolCharSelect = m_toolbarCompose->AddTool( wxID_CHARACTER_SELECTOR, _("Character Selector"), wxIcon( wxT("char_select.ico"), wxBITMAP_TYPE_ICO_RESOURCE, 24, 24 ), wxNullBitmap, wxITEM_NORMAL, _("Character Selector"), _("Display character selector to select character to insert into text"), NULL );
|
||||
m_toolCharSelect = m_toolbarCompose->AddTool( wxID_CHARACTER_SELECTOR, _("Find Character"), wxIcon( wxT("char_select.ico"), wxBITMAP_TYPE_ICO_RESOURCE, 24, 24 ), wxNullBitmap, wxITEM_NORMAL, _("Find Character"), _("Display character search to select character to insert into text"), NULL );
|
||||
|
||||
m_toolSendComposed = m_toolbarCompose->AddTool( wxID_SEND_COMPOSED, _("Send Composed"), wxIcon( wxT("send_composed.ico"), wxBITMAP_TYPE_ICO_RESOURCE, 24, 24 ), wxNullBitmap, wxITEM_NORMAL, _("Send Composed"), _("Send composed text to source window"), NULL );
|
||||
|
||||
@@ -224,7 +234,7 @@ wxZRColaComposerPanelBase::wxZRColaComposerPanelBase( wxWindow* parent, wxWindow
|
||||
bSizerDecomposedEdit2 = new wxStaticBoxSizer( new wxStaticBox( m_panelDecomposedEdit, wxID_ANY, _("Decomposed Text") ), wxVERTICAL );
|
||||
|
||||
m_decomposed = new wxTextCtrl( bSizerDecomposedEdit2->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE );
|
||||
m_decomposed->SetFont( wxFont( 20, 70, 90, 90, false, wxT("00 ZRCola") ) );
|
||||
m_decomposed->SetFont( wxFont( 20, 70, 90, 90, false, wxT("ZRCola") ) );
|
||||
m_decomposed->SetMinSize( wxSize( 100,25 ) );
|
||||
|
||||
bSizerDecomposedEdit2->Add( m_decomposed, 1, wxEXPAND, 5 );
|
||||
@@ -271,7 +281,7 @@ wxZRColaComposerPanelBase::wxZRColaComposerPanelBase( wxWindow* parent, wxWindow
|
||||
bSizerComposedEdit2 = new wxStaticBoxSizer( new wxStaticBox( m_panelComposedEdit, wxID_ANY, _("Composed Text") ), wxVERTICAL );
|
||||
|
||||
m_composed = new wxTextCtrl( bSizerComposedEdit2->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE );
|
||||
m_composed->SetFont( wxFont( 20, 70, 90, 90, false, wxT("00 ZRCola") ) );
|
||||
m_composed->SetFont( wxFont( 20, 70, 90, 90, false, wxT("ZRCola") ) );
|
||||
m_composed->SetMinSize( wxSize( 100,25 ) );
|
||||
|
||||
bSizerComposedEdit2->Add( m_composed, 1, wxEXPAND, 5 );
|
||||
@@ -342,6 +352,8 @@ wxZRColaCharacterCatalogPanelBase::wxZRColaCharacterCatalogPanelBase( wxWindow*
|
||||
wxArrayString m_choiceChoices;
|
||||
m_choice = new wxChoice( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, m_choiceChoices, 0 );
|
||||
m_choice->SetSelection( 0 );
|
||||
m_choice->SetToolTip( _("Select category to display") );
|
||||
|
||||
bSizer->Add( m_choice, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_grid = new wxZRColaCharGrid( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
@@ -368,12 +380,17 @@ wxZRColaCharacterCatalogPanelBase::wxZRColaCharacterCatalogPanelBase( wxWindow*
|
||||
|
||||
// Cell Defaults
|
||||
m_grid->SetDefaultCellBackgroundColour( wxSystemSettings::GetColour( wxSYS_COLOUR_BTNFACE ) );
|
||||
m_grid->SetDefaultCellFont( wxFont( 20, 70, 90, 90, false, wxT("00 ZRCola") ) );
|
||||
m_grid->SetDefaultCellFont( wxFont( 20, 70, 90, 90, false, wxT("ZRCola") ) );
|
||||
m_grid->SetDefaultCellAlignment( wxALIGN_CENTRE, wxALIGN_CENTRE );
|
||||
m_grid->SetMinSize( wxSize( 35,35 ) );
|
||||
|
||||
bSizer->Add( m_grid, 1, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_show_all = new wxCheckBox( this, wxID_ANY, _("Show &All"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_show_all->SetToolTip( _("Toggle display of less frequent characters") );
|
||||
|
||||
bSizer->Add( m_show_all, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
|
||||
this->SetSizer( bSizer );
|
||||
this->Layout();
|
||||
@@ -383,6 +400,7 @@ wxZRColaCharacterCatalogPanelBase::wxZRColaCharacterCatalogPanelBase( wxWindow*
|
||||
m_choice->Connect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( wxZRColaCharacterCatalogPanelBase::OnChoice ), NULL, this );
|
||||
m_grid->Connect( wxEVT_GRID_CELL_LEFT_CLICK, wxGridEventHandler( wxZRColaCharacterCatalogPanelBase::OnGridClick ), NULL, this );
|
||||
m_grid->Connect( wxEVT_KEY_DOWN, wxKeyEventHandler( wxZRColaCharacterCatalogPanelBase::OnGridKeyDown ), NULL, this );
|
||||
m_show_all->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( wxZRColaCharacterCatalogPanelBase::OnShowAll ), NULL, this );
|
||||
}
|
||||
|
||||
wxZRColaCharacterCatalogPanelBase::~wxZRColaCharacterCatalogPanelBase()
|
||||
@@ -391,6 +409,7 @@ wxZRColaCharacterCatalogPanelBase::~wxZRColaCharacterCatalogPanelBase()
|
||||
m_choice->Disconnect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( wxZRColaCharacterCatalogPanelBase::OnChoice ), NULL, this );
|
||||
m_grid->Disconnect( wxEVT_GRID_CELL_LEFT_CLICK, wxGridEventHandler( wxZRColaCharacterCatalogPanelBase::OnGridClick ), NULL, this );
|
||||
m_grid->Disconnect( wxEVT_KEY_DOWN, wxKeyEventHandler( wxZRColaCharacterCatalogPanelBase::OnGridKeyDown ), NULL, this );
|
||||
m_show_all->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( wxZRColaCharacterCatalogPanelBase::OnShowAll ), NULL, this );
|
||||
|
||||
}
|
||||
|
||||
@@ -415,11 +434,53 @@ wxZRColaCharSelectBase::wxZRColaCharSelectBase( wxWindow* parent, wxWindowID id,
|
||||
m_search->ShowSearchButton( true );
|
||||
#endif
|
||||
m_search->ShowCancelButton( true );
|
||||
m_search->SetToolTip( _("Full or partial terms from Unicode character description (in English) to search for") );
|
||||
|
||||
sbSizerBrowse->Add( m_search, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_search_more = new wxHyperlinkCtrl( sbSizerBrowse->GetStaticBox(), wxID_ANY, _("Search Options"), wxEmptyString, wxDefaultPosition, wxDefaultSize, wxHL_DEFAULT_STYLE );
|
||||
m_search_more->SetToolTip( _("Shows/hides additional search options") );
|
||||
|
||||
sbSizerBrowse->Add( m_search_more, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_search_panel = new wxPanel( sbSizerBrowse->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
|
||||
m_search_panel->Hide();
|
||||
|
||||
wxBoxSizer* sbSizerSearch;
|
||||
sbSizerSearch = new wxBoxSizer( wxVERTICAL );
|
||||
|
||||
wxArrayString m_categoriesChoices;
|
||||
m_categories = new wxCheckListBox( sbSizerBrowse->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxSize( -1,60 ), m_categoriesChoices, 0 );
|
||||
sbSizerBrowse->Add( m_categories, 0, wxALL|wxEXPAND, 5 );
|
||||
m_categories = new wxCheckListBox( m_search_panel, wxID_ANY, wxDefaultPosition, wxSize( -1,60 ), m_categoriesChoices, 0 );
|
||||
m_categories->SetToolTip( _("List of Unicode character categories to search in") );
|
||||
|
||||
sbSizerSearch->Add( m_categories, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
wxBoxSizer* bSizerCategoriesCtrl;
|
||||
bSizerCategoriesCtrl = new wxBoxSizer( wxHORIZONTAL );
|
||||
|
||||
m_categoriesAll = new wxHyperlinkCtrl( m_search_panel, wxID_ANY, _("All"), wxEmptyString, wxDefaultPosition, wxDefaultSize, wxHL_DEFAULT_STYLE );
|
||||
m_categoriesAll->SetToolTip( _("Select all categories") );
|
||||
|
||||
bSizerCategoriesCtrl->Add( m_categoriesAll, 0, wxALL, 5 );
|
||||
|
||||
m_categoriesNone = new wxHyperlinkCtrl( m_search_panel, wxID_ANY, _("None"), wxEmptyString, wxDefaultPosition, wxDefaultSize, wxHL_DEFAULT_STYLE );
|
||||
m_categoriesNone->SetToolTip( _("Clear category selection") );
|
||||
|
||||
bSizerCategoriesCtrl->Add( m_categoriesNone, 0, wxALL, 5 );
|
||||
|
||||
m_categoriesInvert = new wxHyperlinkCtrl( m_search_panel, wxID_ANY, _("Invert"), wxEmptyString, wxDefaultPosition, wxDefaultSize, wxHL_DEFAULT_STYLE );
|
||||
m_categoriesInvert->SetToolTip( _("Invert category selection") );
|
||||
|
||||
bSizerCategoriesCtrl->Add( m_categoriesInvert, 0, wxALL, 5 );
|
||||
|
||||
|
||||
sbSizerSearch->Add( bSizerCategoriesCtrl, 0, wxALIGN_RIGHT, 5 );
|
||||
|
||||
|
||||
m_search_panel->SetSizer( sbSizerSearch );
|
||||
m_search_panel->Layout();
|
||||
sbSizerSearch->Fit( m_search_panel );
|
||||
sbSizerBrowse->Add( m_search_panel, 0, wxEXPAND, 5 );
|
||||
|
||||
m_gridResults = new wxZRColaCharGrid( sbSizerBrowse->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxSize( -1,-1 ), wxSTATIC_BORDER );
|
||||
|
||||
@@ -444,9 +505,10 @@ wxZRColaCharSelectBase::wxZRColaCharSelectBase( wxWindow* parent, wxWindowID id,
|
||||
// Label Appearance
|
||||
|
||||
// Cell Defaults
|
||||
m_gridResults->SetDefaultCellFont( wxFont( 20, 70, 90, 90, false, wxT("00 ZRCola") ) );
|
||||
m_gridResults->SetDefaultCellFont( wxFont( 20, 70, 90, 90, false, wxT("ZRCola") ) );
|
||||
m_gridResults->SetDefaultCellAlignment( wxALIGN_CENTRE, wxALIGN_CENTRE );
|
||||
m_gridResults->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), 70, 90, 90, false, wxEmptyString ) );
|
||||
m_gridResults->SetToolTip( _("Character search results") );
|
||||
m_gridResults->SetMinSize( wxSize( 560,35 ) );
|
||||
m_gridResults->SetMaxSize( wxSize( 560,-1 ) );
|
||||
|
||||
@@ -481,9 +543,10 @@ wxZRColaCharSelectBase::wxZRColaCharSelectBase( wxWindow* parent, wxWindowID id,
|
||||
// Label Appearance
|
||||
|
||||
// Cell Defaults
|
||||
m_gridRecent->SetDefaultCellFont( wxFont( 20, 70, 90, 90, false, wxT("00 ZRCola") ) );
|
||||
m_gridRecent->SetDefaultCellFont( wxFont( 20, 70, 90, 90, false, wxT("ZRCola") ) );
|
||||
m_gridRecent->SetDefaultCellAlignment( wxALIGN_CENTRE, wxALIGN_CENTRE );
|
||||
m_gridRecent->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), 70, 90, 90, false, wxEmptyString ) );
|
||||
m_gridRecent->SetToolTip( _("List of recently inserted characters") );
|
||||
|
||||
sbSizerRecent->Add( m_gridRecent, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
@@ -504,13 +567,20 @@ wxZRColaCharSelectBase::wxZRColaCharSelectBase( wxWindow* parent, wxWindowID id,
|
||||
|
||||
m_labelUnicode = new wxStaticText( sbSizerPreview->GetStaticBox(), wxID_ANY, _("U+"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_labelUnicode->Wrap( -1 );
|
||||
bSizerUnicode->Add( m_labelUnicode, 0, wxALIGN_CENTER, 5 );
|
||||
bSizerUnicode->Add( m_labelUnicode, 0, wxALIGN_CENTER|wxBOTTOM|wxLEFT|wxTOP, 5 );
|
||||
|
||||
m_unicode = new wxTextCtrl( sbSizerPreview->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxSize( 50,-1 ), 0 );
|
||||
bSizerUnicode->Add( m_unicode, 0, wxALIGN_CENTER, 5 );
|
||||
m_unicode->SetToolTip( _("Unicode hexadecimal code") );
|
||||
|
||||
bSizerUnicode->Add( m_unicode, 0, wxALIGN_CENTER|wxBOTTOM|wxRIGHT|wxTOP, 5 );
|
||||
|
||||
m_shortcut = new wxTextCtrl( sbSizerPreview->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_CENTRE|wxTE_READONLY );
|
||||
m_shortcut->SetToolTip( _("Keyboard shortcut in Composer window") );
|
||||
|
||||
bSizerUnicode->Add( m_shortcut, 1, wxALL|wxEXPAND, 5 );
|
||||
|
||||
|
||||
sbSizerPreview->Add( bSizerUnicode, 0, wxALIGN_CENTER|wxALL, 5 );
|
||||
sbSizerPreview->Add( bSizerUnicode, 0, wxEXPAND, 5 );
|
||||
|
||||
m_gridPreview = new wxGrid( sbSizerPreview->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSTATIC_BORDER );
|
||||
|
||||
@@ -537,18 +607,46 @@ wxZRColaCharSelectBase::wxZRColaCharSelectBase( wxWindow* parent, wxWindowID id,
|
||||
// Label Appearance
|
||||
|
||||
// Cell Defaults
|
||||
m_gridPreview->SetDefaultCellFont( wxFont( 96, 70, 90, 90, false, wxT("00 ZRCola") ) );
|
||||
m_gridPreview->SetDefaultCellFont( wxFont( 96, 70, 90, 90, false, wxT("ZRCola") ) );
|
||||
m_gridPreview->SetDefaultCellAlignment( wxALIGN_CENTRE, wxALIGN_CENTRE );
|
||||
m_gridPreview->SetBackgroundColour( wxSystemSettings::GetColour( wxSYS_COLOUR_WINDOW ) );
|
||||
m_gridPreview->SetToolTip( _("Character preview") );
|
||||
|
||||
sbSizerPreview->Add( m_gridPreview, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_description = new wxTextCtrl( sbSizerPreview->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_CENTRE|wxTE_MULTILINE|wxTE_READONLY );
|
||||
m_description->SetToolTip( _("Unicode character description") );
|
||||
|
||||
sbSizerPreview->Add( m_description, 1, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_tags = new wxTextCtrl( sbSizerPreview->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_CENTRE|wxTE_MULTILINE|wxTE_READONLY );
|
||||
m_tags->SetToolTip( _("Character tags") );
|
||||
|
||||
sbSizerPreview->Add( m_tags, 1, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_category = new wxTextCtrl( sbSizerPreview->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_CENTRE|wxTE_READONLY );
|
||||
m_category->SetToolTip( _("Unicode character category") );
|
||||
|
||||
sbSizerPreview->Add( m_category, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
wxBoxSizer* bSizerNavigateButtons;
|
||||
bSizerNavigateButtons = new wxBoxSizer( wxHORIZONTAL );
|
||||
|
||||
m_navigateBack = new wxHyperlinkCtrl( sbSizerPreview->GetStaticBox(), wxID_ANY, _("« Back"), wxEmptyString, wxDefaultPosition, wxDefaultSize, wxHL_DEFAULT_STYLE );
|
||||
m_navigateBack->Enable( false );
|
||||
m_navigateBack->SetToolTip( _("To previously viewed character") );
|
||||
|
||||
bSizerNavigateButtons->Add( m_navigateBack, 0, wxALL, 5 );
|
||||
|
||||
m_navigateForward = new wxHyperlinkCtrl( sbSizerPreview->GetStaticBox(), wxID_ANY, _("Forward »"), wxEmptyString, wxDefaultPosition, wxDefaultSize, wxHL_DEFAULT_STYLE );
|
||||
m_navigateForward->Enable( false );
|
||||
m_navigateForward->SetToolTip( _("To following viewed character") );
|
||||
|
||||
bSizerNavigateButtons->Add( m_navigateForward, 0, wxALL, 5 );
|
||||
|
||||
|
||||
sbSizerPreview->Add( bSizerNavigateButtons, 0, wxALIGN_RIGHT, 5 );
|
||||
|
||||
|
||||
bSizerRight->Add( sbSizerPreview, 70, wxALL|wxEXPAND, 5 );
|
||||
|
||||
@@ -578,8 +676,10 @@ wxZRColaCharSelectBase::wxZRColaCharSelectBase( wxWindow* parent, wxWindowID id,
|
||||
// Label Appearance
|
||||
|
||||
// Cell Defaults
|
||||
m_gridRelated->SetDefaultCellFont( wxFont( 20, 70, 90, 90, false, wxT("00 ZRCola") ) );
|
||||
m_gridRelated->SetDefaultCellFont( wxFont( 20, 70, 90, 90, false, wxT("ZRCola") ) );
|
||||
m_gridRelated->SetDefaultCellAlignment( wxALIGN_CENTRE, wxALIGN_CENTRE );
|
||||
m_gridRelated->SetToolTip( _("List of related characters") );
|
||||
|
||||
sbSizerRelated->Add( m_gridRelated, 1, wxALL|wxEXPAND, 5 );
|
||||
|
||||
|
||||
@@ -611,7 +711,11 @@ wxZRColaCharSelectBase::wxZRColaCharSelectBase( wxWindow* parent, wxWindowID id,
|
||||
// Connect Events
|
||||
this->Connect( wxEVT_IDLE, wxIdleEventHandler( wxZRColaCharSelectBase::OnIdle ) );
|
||||
m_search->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( wxZRColaCharSelectBase::OnSearchText ), NULL, this );
|
||||
m_search_more->Connect( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEventHandler( wxZRColaCharSelectBase::OnSearchMore ), NULL, this );
|
||||
m_categories->Connect( wxEVT_COMMAND_CHECKLISTBOX_TOGGLED, wxCommandEventHandler( wxZRColaCharSelectBase::OnCategoriesToggle ), NULL, this );
|
||||
m_categoriesAll->Connect( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEventHandler( wxZRColaCharSelectBase::OnCategoriesAll ), NULL, this );
|
||||
m_categoriesNone->Connect( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEventHandler( wxZRColaCharSelectBase::OnCategoriesNone ), NULL, this );
|
||||
m_categoriesInvert->Connect( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEventHandler( wxZRColaCharSelectBase::OnCategoriesInvert ), NULL, this );
|
||||
m_gridResults->Connect( wxEVT_GRID_CELL_LEFT_DCLICK, wxGridEventHandler( wxZRColaCharSelectBase::OnResultCellDClick ), NULL, this );
|
||||
m_gridResults->Connect( wxEVT_GRID_SELECT_CELL, wxGridEventHandler( wxZRColaCharSelectBase::OnResultSelectCell ), NULL, this );
|
||||
m_gridResults->Connect( wxEVT_KEY_DOWN, wxKeyEventHandler( wxZRColaCharSelectBase::OnResultsKeyDown ), NULL, this );
|
||||
@@ -619,6 +723,9 @@ wxZRColaCharSelectBase::wxZRColaCharSelectBase( wxWindow* parent, wxWindowID id,
|
||||
m_gridRecent->Connect( wxEVT_GRID_SELECT_CELL, wxGridEventHandler( wxZRColaCharSelectBase::OnRecentSelectCell ), NULL, this );
|
||||
m_gridRecent->Connect( wxEVT_KEY_DOWN, wxKeyEventHandler( wxZRColaCharSelectBase::OnRecentKeyDown ), NULL, this );
|
||||
m_unicode->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( wxZRColaCharSelectBase::OnUnicodeText ), NULL, this );
|
||||
m_gridPreview->Connect( wxEVT_KEY_DOWN, wxKeyEventHandler( wxZRColaCharSelectBase::OnPreviewKeyDown ), NULL, this );
|
||||
m_navigateBack->Connect( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEventHandler( wxZRColaCharSelectBase::OnNavigateBack ), NULL, this );
|
||||
m_navigateForward->Connect( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEventHandler( wxZRColaCharSelectBase::OnNavigateForward ), NULL, this );
|
||||
m_gridRelated->Connect( wxEVT_GRID_SELECT_CELL, wxGridEventHandler( wxZRColaCharSelectBase::OnRelatedSelectCell ), NULL, this );
|
||||
m_sdbSizerButtonsOK->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( wxZRColaCharSelectBase::OnOKButtonClick ), NULL, this );
|
||||
}
|
||||
@@ -628,7 +735,11 @@ wxZRColaCharSelectBase::~wxZRColaCharSelectBase()
|
||||
// Disconnect Events
|
||||
this->Disconnect( wxEVT_IDLE, wxIdleEventHandler( wxZRColaCharSelectBase::OnIdle ) );
|
||||
m_search->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( wxZRColaCharSelectBase::OnSearchText ), NULL, this );
|
||||
m_search_more->Disconnect( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEventHandler( wxZRColaCharSelectBase::OnSearchMore ), NULL, this );
|
||||
m_categories->Disconnect( wxEVT_COMMAND_CHECKLISTBOX_TOGGLED, wxCommandEventHandler( wxZRColaCharSelectBase::OnCategoriesToggle ), NULL, this );
|
||||
m_categoriesAll->Disconnect( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEventHandler( wxZRColaCharSelectBase::OnCategoriesAll ), NULL, this );
|
||||
m_categoriesNone->Disconnect( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEventHandler( wxZRColaCharSelectBase::OnCategoriesNone ), NULL, this );
|
||||
m_categoriesInvert->Disconnect( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEventHandler( wxZRColaCharSelectBase::OnCategoriesInvert ), NULL, this );
|
||||
m_gridResults->Disconnect( wxEVT_GRID_CELL_LEFT_DCLICK, wxGridEventHandler( wxZRColaCharSelectBase::OnResultCellDClick ), NULL, this );
|
||||
m_gridResults->Disconnect( wxEVT_GRID_SELECT_CELL, wxGridEventHandler( wxZRColaCharSelectBase::OnResultSelectCell ), NULL, this );
|
||||
m_gridResults->Disconnect( wxEVT_KEY_DOWN, wxKeyEventHandler( wxZRColaCharSelectBase::OnResultsKeyDown ), NULL, this );
|
||||
@@ -636,6 +747,9 @@ wxZRColaCharSelectBase::~wxZRColaCharSelectBase()
|
||||
m_gridRecent->Disconnect( wxEVT_GRID_SELECT_CELL, wxGridEventHandler( wxZRColaCharSelectBase::OnRecentSelectCell ), NULL, this );
|
||||
m_gridRecent->Disconnect( wxEVT_KEY_DOWN, wxKeyEventHandler( wxZRColaCharSelectBase::OnRecentKeyDown ), NULL, this );
|
||||
m_unicode->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( wxZRColaCharSelectBase::OnUnicodeText ), NULL, this );
|
||||
m_gridPreview->Disconnect( wxEVT_KEY_DOWN, wxKeyEventHandler( wxZRColaCharSelectBase::OnPreviewKeyDown ), NULL, this );
|
||||
m_navigateBack->Disconnect( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEventHandler( wxZRColaCharSelectBase::OnNavigateBack ), NULL, this );
|
||||
m_navigateForward->Disconnect( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEventHandler( wxZRColaCharSelectBase::OnNavigateForward ), NULL, this );
|
||||
m_gridRelated->Disconnect( wxEVT_GRID_SELECT_CELL, wxGridEventHandler( wxZRColaCharSelectBase::OnRelatedSelectCell ), NULL, this );
|
||||
m_sdbSizerButtonsOK->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( wxZRColaCharSelectBase::OnOKButtonClick ), NULL, this );
|
||||
|
||||
@@ -743,7 +857,7 @@ wxZRColaSettingsBase::~wxZRColaSettingsBase()
|
||||
|
||||
wxZRColaAboutBase::wxZRColaAboutBase( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style, const wxString& name ) : wxDialog( parent, id, title, pos, size, style, name )
|
||||
{
|
||||
this->SetSizeHints( wxDefaultSize, wxDefaultSize );
|
||||
this->SetSizeHints( wxDefaultSize, wxSize( -1,-1 ) );
|
||||
|
||||
wxBoxSizer* bSizerContent;
|
||||
bSizerContent = new wxBoxSizer( wxVERTICAL );
|
||||
@@ -759,7 +873,8 @@ wxZRColaAboutBase::wxZRColaAboutBase( wxWindow* parent, wxWindowID id, const wxS
|
||||
|
||||
m_staticTextZRCola = new wxStaticText( this, wxID_ANY, _("ZRCola"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticTextZRCola->Wrap( -1 );
|
||||
m_staticTextZRCola->SetFont( wxFont( 20, 70, 90, 90, false, wxT("00 ZRCola") ) );
|
||||
m_staticTextZRCola->SetFont( wxFont( 20, 70, 90, 90, false, wxT("ZRCola") ) );
|
||||
m_staticTextZRCola->SetMaxSize( wxSize( 400,-1 ) );
|
||||
|
||||
bSizerText->Add( m_staticTextZRCola, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
@@ -767,18 +882,30 @@ wxZRColaAboutBase::wxZRColaAboutBase( wxWindow* parent, wxWindowID id, const wxS
|
||||
m_staticTextVersion->Wrap( -1 );
|
||||
bSizerText->Add( m_staticTextVersion, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_staticTextColophone = new wxStaticText( this, wxID_ANY, _("Editor: Janoš Ježovnik\nDevelopment: Amebis d. o. o.\nDevelopment and maintenance (2004-2015): dr. Peter Weiss"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticTextColophone->Wrap( -1 );
|
||||
m_staticTextColophone = new wxStaticText( this, wxID_ANY, _("Program and Website Editor: Janoš Ježovnik\nDevelopment: Amebis, d. o. o., Kamnik\nTranslation into English: Janoš Ježovnik\nTranslation into Russian language: Domen Krvina, Silvo Torkar, Anastasia Plotnikova\nDevelopment and maintenance of the original program (2004–2015): Peter Weiss"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticTextColophone->Wrap( 400 );
|
||||
bSizerText->Add( m_staticTextColophone, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_staticTextCopyright = new wxStaticText( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticTextCopyright->Wrap( -1 );
|
||||
bSizerText->Add( m_staticTextCopyright, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_hyperlink = new wxHyperlinkCtrl( this, wxID_ANY, _("www.zrc-sazu.si"), wxT("http://www.zrc-sazu.si/"), wxDefaultPosition, wxDefaultSize, wxHL_DEFAULT_STYLE );
|
||||
m_hyperlink = new wxHyperlinkCtrl( this, wxID_ANY, _("zrcola.zrc-sazu.si"), wxT("http://zrcola.zrc-sazu.si/"), wxDefaultPosition, wxDefaultSize, wxHL_DEFAULT_STYLE );
|
||||
bSizerText->Add( m_hyperlink, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
|
||||
bSizerText->Add( 0, 0, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_staticTextDeclaration = new wxStaticText( this, wxID_ANY, _("Texts made using ZRCola have to include in a footnote or some other appropriate part of the publication the note below:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticTextDeclaration->Wrap( 400 );
|
||||
bSizerText->Add( m_staticTextDeclaration, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_declaration = new wxTextCtrl( this, wxID_ANY, _("This text was written using the ZRCola input system (http://zrcola.zrc-sazu.si), developed at the Science and Research Centre of SAZU in Ljubljana (http://www.zrc-sazu.si) by Peter Weiss."), wxDefaultPosition, wxSize( -1,80 ), wxTE_MULTILINE|wxTE_READONLY );
|
||||
m_declaration->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), 70, 93, 90, false, wxEmptyString ) );
|
||||
|
||||
bSizerText->Add( m_declaration, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
|
||||
bSizerColumns->Add( bSizerText, 1, wxEXPAND, 5 );
|
||||
|
||||
|
||||
@@ -830,12 +957,15 @@ wxZRColaUpdaterBase::wxZRColaUpdaterBase( wxWindow* parent, wxWindowID id, const
|
||||
wxBoxSizer* bSizerButtons;
|
||||
bSizerButtons = new wxBoxSizer( wxHORIZONTAL );
|
||||
|
||||
m_buttonUpdate = new wxButton( this, wxID_ANY, _("&Update"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_buttonUpdate = new wxButton( this, wxID_ANY, _("Quit and &Update..."), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_buttonUpdate->Enable( false );
|
||||
m_buttonUpdate->SetToolTip( _("Exit this program and launch product update") );
|
||||
|
||||
bSizerButtons->Add( m_buttonUpdate, 0, wxALL, 5 );
|
||||
|
||||
m_buttonClose = new wxButton( this, wxID_OK, _("&Close"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_buttonClose->SetToolTip( _("Close this window") );
|
||||
|
||||
bSizerButtons->Add( m_buttonClose, 0, wxALL, 5 );
|
||||
|
||||
|
||||
@@ -849,12 +979,94 @@ wxZRColaUpdaterBase::wxZRColaUpdaterBase( wxWindow* parent, wxWindowID id, const
|
||||
this->Centre( wxBOTH );
|
||||
|
||||
// Connect Events
|
||||
this->Connect( wxEVT_IDLE, wxIdleEventHandler( wxZRColaUpdaterBase::OnIdle ) );
|
||||
m_buttonUpdate->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( wxZRColaUpdaterBase::OnUpdate ), NULL, this );
|
||||
m_buttonClose->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( wxZRColaUpdaterBase::OnClose ), NULL, this );
|
||||
}
|
||||
|
||||
wxZRColaUpdaterBase::~wxZRColaUpdaterBase()
|
||||
{
|
||||
// Disconnect Events
|
||||
this->Disconnect( wxEVT_IDLE, wxIdleEventHandler( wxZRColaUpdaterBase::OnIdle ) );
|
||||
m_buttonUpdate->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( wxZRColaUpdaterBase::OnUpdate ), NULL, this );
|
||||
m_buttonClose->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( wxZRColaUpdaterBase::OnClose ), NULL, this );
|
||||
|
||||
}
|
||||
|
||||
wxZRColaCharRequestBase::wxZRColaCharRequestBase( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style, const wxString& name ) : wxDialog( parent, id, title, pos, size, style, name )
|
||||
{
|
||||
this->SetSizeHints( wxDefaultSize, wxDefaultSize );
|
||||
|
||||
wxBoxSizer* bSizerContent;
|
||||
bSizerContent = new wxBoxSizer( wxVERTICAL );
|
||||
|
||||
wxStaticBoxSizer* sbSizerCharacter;
|
||||
sbSizerCharacter = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Character") ), wxVERTICAL );
|
||||
|
||||
m_characterLbl = new wxStaticText( sbSizerCharacter->GetStaticBox(), wxID_ANY, _("Enter the &character you would like to request:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_characterLbl->Wrap( 400 );
|
||||
sbSizerCharacter->Add( m_characterLbl, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_character = new wxTextCtrl( sbSizerCharacter->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_character->SetMaxLength( 20 );
|
||||
m_character->SetFont( wxFont( 20, 70, 90, 90, false, wxT("ZRCola") ) );
|
||||
m_character->SetToolTip( _("Decomposed character to request") );
|
||||
|
||||
sbSizerCharacter->Add( m_character, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_characterNote = new wxStaticText( sbSizerCharacter->GetStaticBox(), wxID_ANY, _("Please, use the decomposed form.\nYou can use ZRCola keyboard shortcuts to enter the character or Copy&&Paste it from the Decomposed window."), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_characterNote->Wrap( 400 );
|
||||
sbSizerCharacter->Add( m_characterNote, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
|
||||
bSizerContent->Add( sbSizerCharacter, 40, wxALL|wxEXPAND, 5 );
|
||||
|
||||
wxStaticBoxSizer* sbSizerContext;
|
||||
sbSizerContext = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Context") ), wxVERTICAL );
|
||||
|
||||
m_contextLbl = new wxStaticText( sbSizerContext->GetStaticBox(), wxID_ANY, _("The &context, examples or description why and where the character is required:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_contextLbl->Wrap( 400 );
|
||||
sbSizerContext->Add( m_contextLbl, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_context = new wxTextCtrl( sbSizerContext->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE );
|
||||
m_context->SetFont( wxFont( 16, 70, 90, 90, false, wxT("ZRCola") ) );
|
||||
m_context->SetToolTip( _("Additional notes for character request") );
|
||||
|
||||
sbSizerContext->Add( m_context, 1, wxALL|wxEXPAND, 5 );
|
||||
|
||||
|
||||
bSizerContent->Add( sbSizerContext, 60, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_note = new wxStaticText( this, wxID_ANY, _("After clicking OK button, your e-mail application should open allowing you to submit the new character request to ZRCola Editor.\nYour e-mail application might not display all the characters correctly, but the Editor will be able to read them correctly anyway."), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_note->Wrap( 400 );
|
||||
bSizerContent->Add( m_note, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
|
||||
bSizerContent->Add( 0, 0, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_sdbSizerButtons = new wxStdDialogButtonSizer();
|
||||
m_sdbSizerButtonsOK = new wxButton( this, wxID_OK );
|
||||
m_sdbSizerButtons->AddButton( m_sdbSizerButtonsOK );
|
||||
m_sdbSizerButtonsCancel = new wxButton( this, wxID_CANCEL );
|
||||
m_sdbSizerButtons->AddButton( m_sdbSizerButtonsCancel );
|
||||
m_sdbSizerButtons->Realize();
|
||||
|
||||
bSizerContent->Add( m_sdbSizerButtons, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
|
||||
this->SetSizer( bSizerContent );
|
||||
this->Layout();
|
||||
bSizerContent->Fit( this );
|
||||
|
||||
this->Centre( wxBOTH );
|
||||
|
||||
// Connect Events
|
||||
m_sdbSizerButtonsOK->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( wxZRColaCharRequestBase::OnOKButtonClick ), NULL, this );
|
||||
}
|
||||
|
||||
wxZRColaCharRequestBase::~wxZRColaCharRequestBase()
|
||||
{
|
||||
// Disconnect Events
|
||||
m_sdbSizerButtonsOK->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( wxZRColaCharRequestBase::OnOKButtonClick ), NULL, this );
|
||||
|
||||
}
|
||||
|
||||
@@ -37,18 +37,18 @@ class wxZRColaComposerPanel;
|
||||
#include <wx/timer.h>
|
||||
#include <wx/choice.h>
|
||||
#include <wx/grid.h>
|
||||
#include <wx/checkbox.h>
|
||||
#include <wx/srchctrl.h>
|
||||
#include <wx/hyperlink.h>
|
||||
#include <wx/checklst.h>
|
||||
#include <wx/stattext.h>
|
||||
#include <wx/button.h>
|
||||
#include <wx/dialog.h>
|
||||
#include <wx/radiobut.h>
|
||||
#include <wx/listbox.h>
|
||||
#include <wx/checkbox.h>
|
||||
#include <wx/listbook.h>
|
||||
#include <wx/listctrl.h>
|
||||
#include <wx/statbmp.h>
|
||||
#include <wx/hyperlink.h>
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
|
||||
@@ -70,6 +70,8 @@ class wxZRColaFrameBase : public wxFrame
|
||||
wxID_TOOLBAR_EDIT,
|
||||
wxID_TOOLBAR_COMPOSE,
|
||||
wxID_PANEL_CHRGRPS,
|
||||
wxID_HELP_INSTRUCTIONS,
|
||||
wxID_HELP_SHORTCUTS,
|
||||
wxID_HELP_REQCHAR,
|
||||
wxID_HELP_UPDATE
|
||||
};
|
||||
@@ -170,11 +172,13 @@ class wxZRColaCharacterCatalogPanelBase : public wxPanel
|
||||
protected:
|
||||
wxChoice* m_choice;
|
||||
wxZRColaCharGrid* m_grid;
|
||||
wxCheckBox* m_show_all;
|
||||
|
||||
// Virtual event handlers, overide them in your derived class
|
||||
virtual void OnChoice( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnGridClick( wxGridEvent& event ) { event.Skip(); }
|
||||
virtual void OnGridKeyDown( wxKeyEvent& event ) { event.Skip(); }
|
||||
virtual void OnShowAll( wxCommandEvent& event ) { event.Skip(); }
|
||||
|
||||
|
||||
public:
|
||||
@@ -193,14 +197,23 @@ class wxZRColaCharSelectBase : public wxDialog
|
||||
|
||||
protected:
|
||||
wxSearchCtrl* m_search;
|
||||
wxHyperlinkCtrl* m_search_more;
|
||||
wxPanel* m_search_panel;
|
||||
wxCheckListBox* m_categories;
|
||||
wxHyperlinkCtrl* m_categoriesAll;
|
||||
wxHyperlinkCtrl* m_categoriesNone;
|
||||
wxHyperlinkCtrl* m_categoriesInvert;
|
||||
wxZRColaCharGrid* m_gridResults;
|
||||
wxZRColaCharGrid* m_gridRecent;
|
||||
wxStaticText* m_labelUnicode;
|
||||
wxTextCtrl* m_unicode;
|
||||
wxTextCtrl* m_shortcut;
|
||||
wxGrid* m_gridPreview;
|
||||
wxTextCtrl* m_description;
|
||||
wxTextCtrl* m_tags;
|
||||
wxTextCtrl* m_category;
|
||||
wxHyperlinkCtrl* m_navigateBack;
|
||||
wxHyperlinkCtrl* m_navigateForward;
|
||||
wxZRColaCharGrid* m_gridRelated;
|
||||
wxStdDialogButtonSizer* m_sdbSizerButtons;
|
||||
wxButton* m_sdbSizerButtonsOK;
|
||||
@@ -209,7 +222,11 @@ class wxZRColaCharSelectBase : public wxDialog
|
||||
// Virtual event handlers, overide them in your derived class
|
||||
virtual void OnIdle( wxIdleEvent& event ) { event.Skip(); }
|
||||
virtual void OnSearchText( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnSearchMore( wxHyperlinkEvent& event ) { event.Skip(); }
|
||||
virtual void OnCategoriesToggle( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnCategoriesAll( wxHyperlinkEvent& event ) { event.Skip(); }
|
||||
virtual void OnCategoriesNone( wxHyperlinkEvent& event ) { event.Skip(); }
|
||||
virtual void OnCategoriesInvert( wxHyperlinkEvent& event ) { event.Skip(); }
|
||||
virtual void OnResultCellDClick( wxGridEvent& event ) { event.Skip(); }
|
||||
virtual void OnResultSelectCell( wxGridEvent& event ) { event.Skip(); }
|
||||
virtual void OnResultsKeyDown( wxKeyEvent& event ) { event.Skip(); }
|
||||
@@ -217,13 +234,16 @@ class wxZRColaCharSelectBase : public wxDialog
|
||||
virtual void OnRecentSelectCell( wxGridEvent& event ) { event.Skip(); }
|
||||
virtual void OnRecentKeyDown( wxKeyEvent& event ) { event.Skip(); }
|
||||
virtual void OnUnicodeText( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnPreviewKeyDown( wxKeyEvent& event ) { event.Skip(); }
|
||||
virtual void OnNavigateBack( wxHyperlinkEvent& event ) { event.Skip(); }
|
||||
virtual void OnNavigateForward( wxHyperlinkEvent& event ) { event.Skip(); }
|
||||
virtual void OnRelatedSelectCell( wxGridEvent& event ) { event.Skip(); }
|
||||
virtual void OnOKButtonClick( wxCommandEvent& event ) { event.Skip(); }
|
||||
|
||||
|
||||
public:
|
||||
|
||||
wxZRColaCharSelectBase( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Character Selector"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize, long style = wxDEFAULT_DIALOG_STYLE, const wxString& name = wxT("ZRColaCharSelect") );
|
||||
wxZRColaCharSelectBase( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Character Search"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize, long style = wxDEFAULT_DIALOG_STYLE, const wxString& name = wxT("ZRColaCharSelect") );
|
||||
~wxZRColaCharSelectBase();
|
||||
|
||||
};
|
||||
@@ -279,6 +299,8 @@ class wxZRColaAboutBase : public wxDialog
|
||||
wxStaticText* m_staticTextColophone;
|
||||
wxStaticText* m_staticTextCopyright;
|
||||
wxHyperlinkCtrl* m_hyperlink;
|
||||
wxStaticText* m_staticTextDeclaration;
|
||||
wxTextCtrl* m_declaration;
|
||||
wxStdDialogButtonSizer* m_sdbSizerButtons;
|
||||
wxButton* m_sdbSizerButtonsOK;
|
||||
|
||||
@@ -302,7 +324,9 @@ class wxZRColaUpdaterBase : public wxDialog
|
||||
wxButton* m_buttonClose;
|
||||
|
||||
// Virtual event handlers, overide them in your derived class
|
||||
virtual void OnIdle( wxIdleEvent& event ) { event.Skip(); }
|
||||
virtual void OnUpdate( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnClose( wxCommandEvent& event ) { event.Skip(); }
|
||||
|
||||
|
||||
public:
|
||||
@@ -312,4 +336,33 @@ class wxZRColaUpdaterBase : public wxDialog
|
||||
|
||||
};
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
/// Class wxZRColaCharRequestBase
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
class wxZRColaCharRequestBase : public wxDialog
|
||||
{
|
||||
private:
|
||||
|
||||
protected:
|
||||
wxStaticText* m_characterLbl;
|
||||
wxTextCtrl* m_character;
|
||||
wxStaticText* m_characterNote;
|
||||
wxStaticText* m_contextLbl;
|
||||
wxTextCtrl* m_context;
|
||||
wxStaticText* m_note;
|
||||
wxStdDialogButtonSizer* m_sdbSizerButtons;
|
||||
wxButton* m_sdbSizerButtonsOK;
|
||||
wxButton* m_sdbSizerButtonsCancel;
|
||||
|
||||
// Virtual event handlers, overide them in your derived class
|
||||
virtual void OnOKButtonClick( wxCommandEvent& event ) { event.Skip(); }
|
||||
|
||||
|
||||
public:
|
||||
|
||||
wxZRColaCharRequestBase( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Request a New Character"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize, long style = wxDEFAULT_DIALOG_STYLE, const wxString& name = wxT("ZRColaCharRequest") );
|
||||
~wxZRColaCharRequestBase();
|
||||
|
||||
};
|
||||
|
||||
#endif //__ZRCOLAGUI_H__
|
||||
|
||||
@@ -39,12 +39,17 @@ bool wxZRColaKeyHandler::ProcessEvent(wxEvent& event)
|
||||
if (e.GetKeyCode() == WXK_INSERT) {
|
||||
// Insert key has been pressed.
|
||||
m_is_insert = true;
|
||||
wxFrame *pFrame = wxDynamicCast(((ZRColaApp*)wxTheApp)->m_mainWnd, wxFrame);
|
||||
wxFrame *pFrame = wxDynamicCast(dynamic_cast<ZRColaApp*>(wxTheApp)->m_mainWnd, wxFrame);
|
||||
if (pFrame && pFrame->GetStatusBar())
|
||||
pFrame->SetStatusText(_("INS key is pressed. Type the Unicode code of desired character now (up to four hexadecimal digits: 0-9, A-F), then release INS."));
|
||||
} else if (m_is_insert) {
|
||||
wxChar chr = e.GetUnicodeKey();
|
||||
wxFrame *pFrame = wxDynamicCast(((ZRColaApp*)wxTheApp)->m_mainWnd, wxFrame);
|
||||
if (!chr) {
|
||||
int key = e.GetKeyCode();
|
||||
if (WXK_NUMPAD0 <= key && key <= WXK_NUMPAD9)
|
||||
chr = '0' + (key - WXK_NUMPAD0);
|
||||
}
|
||||
wxFrame *pFrame = wxDynamicCast(dynamic_cast<ZRColaApp*>(wxTheApp)->m_mainWnd, wxFrame);
|
||||
if (('0' <= chr && chr <= '9' || 'A' <= chr && chr <= 'F') && m_insert_seq.size() < 4) {
|
||||
// A hex-digit pressed. Save it.
|
||||
m_insert_seq.push_back((char)chr);
|
||||
@@ -68,7 +73,7 @@ bool wxZRColaKeyHandler::ProcessEvent(wxEvent& event)
|
||||
#endif
|
||||
)
|
||||
{
|
||||
ZRColaApp *app = (ZRColaApp*)wxTheApp;
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
ZRCola::keyseq_db::indexKey::size_type start;
|
||||
bool found;
|
||||
wxFrame *pFrame = wxDynamicCast(app->m_mainWnd, wxFrame);
|
||||
@@ -91,7 +96,7 @@ bool wxZRColaKeyHandler::ProcessEvent(wxEvent& event)
|
||||
(e.AltDown() ? ZRCola::keyseq_db::keyseq::ALT : 0);
|
||||
m_seq.push_back(key);
|
||||
|
||||
std::vector<ZRCola::keyseq_db::keyseq::key_t>::size_type n = m_seq.size();
|
||||
auto n = m_seq.size();
|
||||
ZRCola::keyseq_db::keyseq *ks = (ZRCola::keyseq_db::keyseq*)new char[sizeof(ZRCola::keyseq_db::keyseq) + sizeof(ZRCola::keyseq_db::keyseq::key_t)*n];
|
||||
ks->chr = 0;
|
||||
ks->seq_len = n;
|
||||
@@ -138,11 +143,11 @@ bool wxZRColaKeyHandler::ProcessEvent(wxEvent& event)
|
||||
wxKeyEvent &e = (wxKeyEvent&)event;
|
||||
if (m_is_insert && e.GetKeyCode() == WXK_INSERT) {
|
||||
// Insert key has been depressed.
|
||||
wxFrame *pFrame = wxDynamicCast(((ZRColaApp*)wxTheApp)->m_mainWnd, wxFrame);
|
||||
wxFrame *pFrame = wxDynamicCast(dynamic_cast<ZRColaApp*>(wxTheApp)->m_mainWnd, wxFrame);
|
||||
if (pFrame && pFrame->GetStatusBar())
|
||||
pFrame->SetStatusText(wxEmptyString);
|
||||
|
||||
std::vector<char>::size_type count = m_insert_seq.size();
|
||||
auto count = m_insert_seq.size();
|
||||
if (count) {
|
||||
// Zero terminate sequence and parse the Unicode value.
|
||||
m_insert_seq.push_back(0);
|
||||
|
||||
@@ -25,6 +25,8 @@ class wxZRColaKeyHandler;
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <zrcolaui/keyboard.h>
|
||||
|
||||
#include <wx/event.h>
|
||||
#include <vector>
|
||||
|
||||
|
||||
@@ -26,13 +26,13 @@
|
||||
|
||||
wxZRColaSettings::wxZRColaSettings(wxWindow* parent) :
|
||||
m_lang_auto(true),
|
||||
m_lang(ZRCola::langid_t_blank),
|
||||
m_lang(ZRCola::langid_t::blank),
|
||||
wxZRColaSettingsBase(parent)
|
||||
{
|
||||
ZRColaApp *app = ((ZRColaApp*)wxTheApp);
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
m_languages->Clear();
|
||||
for (size_t i = 0, n = app->m_lang_db.idxLng.size(); i < n; i++) {
|
||||
const ZRCola::language_db::language &lang = app->m_lang_db.idxLng[i];
|
||||
const auto &lang = app->m_lang_db.idxLng[i];
|
||||
wxString
|
||||
label(lang.name, lang.name_len),
|
||||
label_tran(wxGetTranslation(label, wxT("ZRCola-zrcdb")));
|
||||
@@ -57,7 +57,7 @@ void wxZRColaSettings::OnInitDialog(wxInitDialogEvent& event)
|
||||
m_languages->Enable(!m_lang_auto);
|
||||
(m_lang_auto ? m_langAuto : m_langManual)->SetValue(true);
|
||||
|
||||
ZRColaApp *app = ((ZRColaApp*)wxTheApp);
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
char l[sizeof(ZRCola::language_db::language)] = {};
|
||||
((ZRCola::language_db::language*)l)->id = m_lang;
|
||||
ZRCola::language_db::indexLang::size_type start;
|
||||
@@ -121,8 +121,8 @@ void wxZRColaSettings::OnApplyButtonClick(wxCommandEvent& event)
|
||||
} else {
|
||||
m_lang_auto = false;
|
||||
|
||||
ZRColaApp *app = ((ZRColaApp*)wxTheApp);
|
||||
const ZRCola::language_db::language &lang = app->m_lang_db.idxLng[m_languages->GetSelection()];
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
const auto &lang = app->m_lang_db.idxLng[m_languages->GetSelection()];
|
||||
|
||||
if (m_lang != lang.id) {
|
||||
m_lang = lang.id;
|
||||
@@ -155,7 +155,7 @@ void wxPersistentZRColaSettings::Save() const
|
||||
{
|
||||
wxPersistentDialog::Save();
|
||||
|
||||
const wxZRColaSettings * const wnd = static_cast<const wxZRColaSettings*>(GetWindow());
|
||||
auto wnd = static_cast<const wxZRColaSettings*>(GetWindow()); // dynamic_cast is not reliable as we are typically called late in the wxTopLevelWindowMSW destructor.
|
||||
|
||||
SaveValue(wxT("langAuto"), wnd->m_lang_auto);
|
||||
SaveValue(wxT("lang" ), wxString::FromAscii(wnd->m_lang.data, _countof(wnd->m_lang.data)));
|
||||
@@ -164,9 +164,8 @@ void wxPersistentZRColaSettings::Save() const
|
||||
|
||||
bool wxPersistentZRColaSettings::Restore()
|
||||
{
|
||||
wxZRColaSettings * const wnd = static_cast<wxZRColaSettings*>(GetWindow());
|
||||
|
||||
ZRColaApp *app = ((ZRColaApp*)wxTheApp);
|
||||
auto wnd = dynamic_cast<wxZRColaSettings*>(GetWindow());
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
wxString lang;
|
||||
|
||||
// Restore automatic language detection setting first.
|
||||
@@ -181,10 +180,10 @@ bool wxPersistentZRColaSettings::Restore()
|
||||
// The language was read from configuration.
|
||||
wnd->m_lang = lang.c_str();
|
||||
} else if (!app->m_lang_db.idxLng.empty()) {
|
||||
const ZRCola::language_db::language &lang = app->m_lang_db.idxLng[0];
|
||||
const auto &lang = app->m_lang_db.idxLng[0];
|
||||
wnd->m_lang = lang.id;
|
||||
} else
|
||||
wnd->m_lang = ZRCola::langid_t_blank;
|
||||
wnd->m_lang = ZRCola::langid_t::blank;
|
||||
|
||||
return wxPersistentDialog::Restore();
|
||||
}
|
||||
|
||||
@@ -28,6 +28,7 @@ wxZRColaUpdater::wxZRColaUpdater(wxWindow* parent) :
|
||||
m_logLevelOrig(wxLOG_Warning),
|
||||
m_logOrig(NULL),
|
||||
m_updater(NULL),
|
||||
m_finished(false),
|
||||
wxZRColaUpdaterBase(parent)
|
||||
{
|
||||
// Setup logging.
|
||||
@@ -35,17 +36,17 @@ wxZRColaUpdater::wxZRColaUpdater(wxWindow* parent) :
|
||||
m_logLevelOrig = wxLog::GetLogLevel();
|
||||
wxLog::SetLogLevel(wxLOG_Info);
|
||||
|
||||
// Connect events.
|
||||
Connect(wxID_ANY, wxEVT_UPDATER_CHECK_COMPLETE, wxThreadEventHandler(wxZRColaUpdater::OnCheckComplete), NULL, this);
|
||||
//// Connect events.
|
||||
//Connect(wxID_ANY, wxEVT_UPDATER_CHECK_COMPLETE, wxThreadEventHandler(wxZRColaUpdater::OnCheckComplete), NULL, this);
|
||||
|
||||
// Launch Updater thread.
|
||||
ZRColaApp *app = (ZRColaApp*)wxTheApp;
|
||||
m_updater = new wxUpdCheckThread(app->m_locale.GetCanonicalName(), this);
|
||||
if (m_updater->Run() != wxTHREAD_NO_ERROR) {
|
||||
wxFAIL_MSG(wxT("Can't create the thread!"));
|
||||
delete m_updater;
|
||||
m_updater = NULL;
|
||||
}
|
||||
// Prepare Updater.
|
||||
auto app = dynamic_cast<ZRColaApp*>(wxTheApp);
|
||||
m_updater = new wxUpdCheckThread(app->m_lang_ui == wxLANGUAGE_DEFAULT ? wxT("en_US") : wxLocale::GetLanguageCanonicalName(app->m_lang_ui), this);
|
||||
//if (m_updater->Run() != wxTHREAD_NO_ERROR) {
|
||||
// wxFAIL_MSG(wxT("Can't create the thread!"));
|
||||
// delete m_updater;
|
||||
// m_updater = NULL;
|
||||
//}
|
||||
}
|
||||
|
||||
|
||||
@@ -53,11 +54,12 @@ wxZRColaUpdater::~wxZRColaUpdater()
|
||||
{
|
||||
if (m_updater) {
|
||||
// Terminate the Updater thread.
|
||||
m_updater->Delete();
|
||||
//m_updater->Delete();
|
||||
delete m_updater;
|
||||
}
|
||||
|
||||
// Disconnect events.
|
||||
Disconnect(wxID_ANY, wxEVT_UPDATER_CHECK_COMPLETE, wxThreadEventHandler(wxZRColaUpdater::OnCheckComplete), NULL, this);
|
||||
//// Disconnect events.
|
||||
//Disconnect(wxID_ANY, wxEVT_UPDATER_CHECK_COMPLETE, wxThreadEventHandler(wxZRColaUpdater::OnCheckComplete), NULL, this);
|
||||
|
||||
wxLog::SetLogLevel(m_logLevelOrig);
|
||||
if (m_logOrig) {
|
||||
@@ -67,11 +69,20 @@ wxZRColaUpdater::~wxZRColaUpdater()
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaUpdater::OnCheckComplete(wxThreadEvent& event)
|
||||
{
|
||||
event.Skip();
|
||||
//void wxZRColaUpdater::OnCheckComplete(wxThreadEvent& event)
|
||||
//{
|
||||
// event.Skip();
|
||||
//
|
||||
// m_buttonUpdate->Enable(event.GetInt() == wxUpdCheckThread::wxUpdUpdateAvailable);
|
||||
//}
|
||||
|
||||
m_buttonUpdate->Enable(event.GetInt() == wxUpdCheckThread::wxUpdUpdateAvailable);
|
||||
|
||||
void wxZRColaUpdater::OnIdle(wxIdleEvent& event)
|
||||
{
|
||||
if (!m_finished) {
|
||||
m_buttonUpdate->Enable(m_updater->CheckForUpdate() == wxUpdCheckThread::wxUpdUpdateAvailable);
|
||||
m_finished = true;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -79,6 +90,21 @@ void wxZRColaUpdater::OnUpdate(wxCommandEvent& event)
|
||||
{
|
||||
event.Skip();
|
||||
|
||||
if (m_updater)
|
||||
m_updater->LaunchUpdate();
|
||||
if (m_updater) {
|
||||
if (wxMessageBox(_("This program will now close and the upgrade will be launched.\nAre you sure?"), _("Product Update"), wxICON_QUESTION | wxYES_NO | wxNO_DEFAULT, this) == wxYES) {
|
||||
m_updater->LaunchUpdate();
|
||||
|
||||
Close(true);
|
||||
dynamic_cast<ZRColaApp*>(wxTheApp)->m_mainWnd->Close();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void wxZRColaUpdater::OnClose(wxCommandEvent& event)
|
||||
{
|
||||
if (m_updater)
|
||||
m_updater->Abort();
|
||||
|
||||
event.Skip();
|
||||
}
|
||||
|
||||
@@ -42,11 +42,14 @@ public:
|
||||
virtual ~wxZRColaUpdater();
|
||||
|
||||
protected:
|
||||
void OnCheckComplete(wxThreadEvent& event);
|
||||
//void OnCheckComplete(wxThreadEvent& event);
|
||||
virtual void OnIdle(wxIdleEvent& event);
|
||||
virtual void OnUpdate(wxCommandEvent& event);
|
||||
virtual void OnClose(wxCommandEvent& event);
|
||||
|
||||
protected:
|
||||
wxLogLevel m_logLevelOrig; ///< Original log level
|
||||
wxLog *m_logOrig; ///< Original log
|
||||
wxUpdCheckThread *m_updater; ///< Updater thread
|
||||
bool m_finished; ///< Is Updater finished?
|
||||
};
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup>
|
||||
<ClCompile>
|
||||
<AdditionalIncludeDirectories>..\lib\wxExtend\include;..\lib\stdex\include;..\lib\libZRCola\include;..\lib\libZRColaUI\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\lib\wxExtend\include;..\lib\WinStd\include;..\lib\stdex\include;..\lib\libZRCola\include;..\lib\libZRColaUI\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
|
||||
@@ -19,14 +19,12 @@
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
<UseOfAtl>Dynamic</UseOfAtl>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
<UseOfAtl>Dynamic</UseOfAtl>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
@@ -63,7 +61,10 @@
|
||||
<ProjectReference Include="..\lib\libZRCola\build\libZRCola.vcxproj">
|
||||
<Project>{3c61929e-7289-4101-8d0a-da22d6e1aea8}</Project>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\lib\wxExtend\build\wxExtend.vcxproj">
|
||||
<ProjectReference Include="..\lib\WinStd\build\WinStd.vcxproj">
|
||||
<Project>{47399d91-7eb9-41de-b521-514ba5db0c43}</Project>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\lib\wxExtend\build\wxExtendDll.vcxproj">
|
||||
<Project>{a3a36689-ac35-4026-93da-a3ba0c0e767c}</Project>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
|
||||
@@ -22,9 +22,14 @@
|
||||
#include <zrcola/character.h>
|
||||
#include <zrcola/common.h>
|
||||
|
||||
#include <atlbase.h>
|
||||
#include <WinStd/COM.h>
|
||||
#include <WinStd/Win.h>
|
||||
|
||||
#include <adoint.h>
|
||||
#include <list>
|
||||
#include <map>
|
||||
#include <memory>
|
||||
#include <set>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
@@ -36,14 +41,46 @@ namespace ZRCola {
|
||||
class DBSource
|
||||
{
|
||||
public:
|
||||
///
|
||||
/// Character sequence
|
||||
///
|
||||
class charseq {
|
||||
public:
|
||||
int rank; ///< Sequence rank
|
||||
std::wstring str; ///< Sequence string
|
||||
|
||||
inline charseq()
|
||||
{
|
||||
}
|
||||
|
||||
inline charseq(_In_ int _rank, _In_z_ const wchar_t *_str) :
|
||||
rank(_rank),
|
||||
str (_str)
|
||||
{
|
||||
}
|
||||
|
||||
///
|
||||
/// Functor to compare two sequences by `rank`, and `str` members respectively
|
||||
///
|
||||
struct less_rank_str {
|
||||
inline bool operator()(_In_ const charseq& a, _In_ const charseq& b) const
|
||||
{
|
||||
if (a.rank < b.rank) return true;
|
||||
else if (a.rank > b.rank) return false;
|
||||
else if (a.str < b.str ) return true;
|
||||
else return false;
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
///
|
||||
/// Translation
|
||||
///
|
||||
class translation {
|
||||
public:
|
||||
wchar_t chr; ///< Composed character
|
||||
std::wstring str; ///< Decomposed string
|
||||
int rank; ///< Decomposition rank
|
||||
charseq decomp; ///< Decomposed sequence
|
||||
};
|
||||
|
||||
|
||||
@@ -107,10 +144,11 @@ namespace ZRCola {
|
||||
///
|
||||
class chrgrp {
|
||||
public:
|
||||
int id; ///< Character group ID
|
||||
int rank; ///< Character group rank
|
||||
std::wstring name; ///< Character group name
|
||||
std::wstring chars; ///< Character group characters
|
||||
int id; ///< Character group ID
|
||||
int rank; ///< Character group rank
|
||||
std::wstring name; ///< Character group name
|
||||
std::wstring chars; ///< Character group characters
|
||||
std::vector<unsigned __int16> show; ///< Bit vector if particular character is displayed initially
|
||||
};
|
||||
|
||||
|
||||
@@ -119,11 +157,85 @@ namespace ZRCola {
|
||||
///
|
||||
class character {
|
||||
public:
|
||||
wchar_t chr; ///< Character
|
||||
ZRCola::chrcatid_t cat; ///> Category ID
|
||||
std::wstring desc; ///< Character description
|
||||
std::wstring keywords; ///< Additional keywords
|
||||
std::wstring rel; ///< Related characters
|
||||
inline character()
|
||||
{
|
||||
chr = 0;
|
||||
cat.data[0] = 0;
|
||||
cat.data[1] = 0;
|
||||
}
|
||||
|
||||
inline character(_In_ const character &othr) :
|
||||
chr (othr.chr),
|
||||
cat (othr.cat),
|
||||
desc (othr.desc),
|
||||
terms(othr.terms),
|
||||
rel (othr.rel)
|
||||
{
|
||||
}
|
||||
|
||||
inline bool operator==(_In_ const character &othr) const
|
||||
{
|
||||
return
|
||||
chr == othr.chr &&
|
||||
cat == othr.cat &&
|
||||
desc == othr.desc &&
|
||||
terms == othr.terms &&
|
||||
rel == othr.rel;
|
||||
}
|
||||
|
||||
inline bool operator!=(_In_ const character &othr) const
|
||||
{
|
||||
return !operator==(othr);
|
||||
}
|
||||
|
||||
wchar_t chr; ///< Character
|
||||
ZRCola::chrcatid_t cat; ///< Category ID
|
||||
std::wstring desc; ///< Character description
|
||||
std::set<std::wstring> terms; ///< Search terms
|
||||
std::wstring rel; ///< Related characters
|
||||
};
|
||||
|
||||
|
||||
///
|
||||
/// Character bank
|
||||
///
|
||||
class character_bank : public std::vector<std::unique_ptr<character> >
|
||||
{
|
||||
public:
|
||||
character_bank();
|
||||
void build_related();
|
||||
|
||||
protected:
|
||||
class build_related_worker : public winstd::win_handle
|
||||
{
|
||||
public:
|
||||
build_related_worker(_In_ const character_bank *cb, _In_ size_type from, _In_ size_type to);
|
||||
|
||||
inline void join()
|
||||
{
|
||||
if (m_h)
|
||||
WaitForSingleObject(m_h, INFINITE);
|
||||
}
|
||||
|
||||
private:
|
||||
// This class is non-copyable AND non-movable
|
||||
build_related_worker(_Inout_ build_related_worker &othr);
|
||||
build_related_worker(_Inout_ build_related_worker &&othr);
|
||||
build_related_worker& operator=(_Inout_ build_related_worker &othr);
|
||||
build_related_worker& operator=(_Inout_ build_related_worker &&othr);
|
||||
|
||||
protected:
|
||||
unsigned int process();
|
||||
static unsigned int __stdcall process(_In_ void *param);
|
||||
|
||||
protected:
|
||||
const character_bank *m_cb;
|
||||
size_type m_from, m_to;
|
||||
winstd::heap m_heap;
|
||||
};
|
||||
|
||||
protected:
|
||||
std::set<std::wstring> m_ignore;
|
||||
};
|
||||
|
||||
|
||||
@@ -153,7 +265,14 @@ namespace ZRCola {
|
||||
class character_desc_idx : public std::map<std::wstring, std::vector<wchar_t>, character_desc_idx_less>
|
||||
{
|
||||
public:
|
||||
bool add_keywords(const wchar_t *str, wchar_t chr, size_t sub = 0);
|
||||
static void parse_keywords(const wchar_t *str, std::set<std::wstring> &terms);
|
||||
void add_keywords(const std::set<std::wstring> &terms, wchar_t chr, size_t sub = 0);
|
||||
inline void add_keywords(const wchar_t *str, wchar_t chr, size_t sub = 0)
|
||||
{
|
||||
std::set<std::wstring> terms;
|
||||
parse_keywords(str, terms);
|
||||
add_keywords(terms, chr, sub);
|
||||
}
|
||||
|
||||
void save(ZRCola::textindex<wchar_t, wchar_t, unsigned __int32> &idx) const;
|
||||
|
||||
@@ -167,7 +286,7 @@ namespace ZRCola {
|
||||
} else {
|
||||
// Append to existing keyword.
|
||||
std::vector<wchar_t> &val = idx->second;
|
||||
for (std::vector<wchar_t>::iterator i = val.begin(), i_end = val.end(); ; ++i) {
|
||||
for (auto i = val.cbegin(), i_end = val.cend(); ; ++i) {
|
||||
if (i == i_end) {
|
||||
// End-of-values reached. Append character.
|
||||
val.push_back(chr);
|
||||
@@ -193,11 +312,30 @@ namespace ZRCola {
|
||||
};
|
||||
|
||||
|
||||
///
|
||||
/// Character tag
|
||||
///
|
||||
class chrtag {
|
||||
public:
|
||||
wchar_t chr; ///> Character
|
||||
int tag; ///< Tag ID
|
||||
};
|
||||
|
||||
|
||||
///
|
||||
/// Tag name
|
||||
///
|
||||
class tagname {
|
||||
public:
|
||||
int tag; ///< Tag ID
|
||||
std::map<LCID, std::list<std::wstring> > names; ///< Names
|
||||
};
|
||||
|
||||
|
||||
public:
|
||||
DBSource();
|
||||
virtual ~DBSource();
|
||||
|
||||
|
||||
///
|
||||
/// Opens the database
|
||||
///
|
||||
@@ -209,13 +347,11 @@ namespace ZRCola {
|
||||
///
|
||||
bool Open(LPCTSTR filename);
|
||||
|
||||
|
||||
///
|
||||
/// Logs errors in database connections
|
||||
///
|
||||
void LogErrors() const;
|
||||
|
||||
|
||||
///
|
||||
/// Is recordset at end
|
||||
///
|
||||
@@ -225,13 +361,12 @@ namespace ZRCola {
|
||||
/// - true when at end
|
||||
/// - false otherwise
|
||||
///
|
||||
static inline bool IsEOF(const ATL::CComPtr<ADORecordset>& rs)
|
||||
static inline bool IsEOF(const winstd::com_obj<ADORecordset>& rs)
|
||||
{
|
||||
VARIANT_BOOL eof = VARIANT_TRUE;
|
||||
return FAILED(rs->get_EOF(&eof)) || eof ? true : false;
|
||||
}
|
||||
|
||||
|
||||
///
|
||||
/// Gets number of records in a recordset
|
||||
///
|
||||
@@ -239,13 +374,12 @@ namespace ZRCola {
|
||||
///
|
||||
/// \returns Number of records
|
||||
///
|
||||
static inline size_t GetRecordsetCount(const ATL::CComPtr<ADORecordset>& rs)
|
||||
static inline size_t GetRecordsetCount(const winstd::com_obj<ADORecordset>& rs)
|
||||
{
|
||||
ADO_LONGPTR count;
|
||||
return SUCCEEDED(rs->get_RecordCount(&count)) ? count : (size_t)-1;
|
||||
}
|
||||
|
||||
|
||||
///
|
||||
/// Splits string to individual keywords
|
||||
///
|
||||
@@ -258,7 +392,6 @@ namespace ZRCola {
|
||||
///
|
||||
static bool GetKeywords(const wchar_t *str, std::vector< std::wstring > &keywords);
|
||||
|
||||
|
||||
///
|
||||
/// Gets boolean from ZRCola.zrc database
|
||||
///
|
||||
@@ -269,8 +402,7 @@ namespace ZRCola {
|
||||
/// - true when successful
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetValue(const ATL::CComPtr<ADOField>& f, bool& val) const;
|
||||
|
||||
bool GetValue(const winstd::com_obj<ADOField>& f, bool& val) const;
|
||||
|
||||
///
|
||||
/// Gets integer from ZRCola.zrc database
|
||||
@@ -282,8 +414,7 @@ namespace ZRCola {
|
||||
/// - true when successful
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetValue(const ATL::CComPtr<ADOField>& f, int& val) const;
|
||||
|
||||
bool GetValue(const winstd::com_obj<ADOField>& f, int& val) const;
|
||||
|
||||
///
|
||||
/// Gets string from ZRCola.zrc database
|
||||
@@ -295,8 +426,7 @@ namespace ZRCola {
|
||||
/// - true when successful
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetValue(const ATL::CComPtr<ADOField>& f, std::wstring& val) const;
|
||||
|
||||
bool GetValue(const winstd::com_obj<ADOField>& f, std::wstring& val) const;
|
||||
|
||||
///
|
||||
/// Gets encoded Unicode character from ZRCola.zrc database
|
||||
@@ -308,8 +438,7 @@ namespace ZRCola {
|
||||
/// - true when successful
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetUnicodeCharacter(const ATL::CComPtr<ADOField>& f, wchar_t& chr) const;
|
||||
|
||||
bool GetUnicodeCharacter(const winstd::com_obj<ADOField>& f, wchar_t& chr) const;
|
||||
|
||||
///
|
||||
/// Gets encoded Unicode string from ZRCola.zrc database
|
||||
@@ -321,8 +450,7 @@ namespace ZRCola {
|
||||
/// - true when successful
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetUnicodeString(const ATL::CComPtr<ADOField>& f, std::wstring& str) const;
|
||||
|
||||
bool GetUnicodeString(const winstd::com_obj<ADOField>& f, std::wstring& str) const;
|
||||
|
||||
///
|
||||
/// Gets language ID from ZRCola.zrc database
|
||||
@@ -334,8 +462,7 @@ namespace ZRCola {
|
||||
/// - true when successful
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetLanguage(const ATL::CComPtr<ADOField>& f, langid_t& lang) const;
|
||||
|
||||
bool GetLanguage(const winstd::com_obj<ADOField>& f, langid_t& lang) const;
|
||||
|
||||
///
|
||||
/// Gets character category ID from ZRCola.zrc database
|
||||
@@ -347,8 +474,19 @@ namespace ZRCola {
|
||||
/// - true when successful
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetChrCat(const ATL::CComPtr<ADOField>& f, chrcatid_t& cc) const;
|
||||
bool GetChrCat(const winstd::com_obj<ADOField>& f, chrcatid_t& cc) const;
|
||||
|
||||
///
|
||||
/// Gets tag names from ZRCola.zrc database
|
||||
///
|
||||
/// \param[in] f Data field
|
||||
/// \param[out] names Output names
|
||||
///
|
||||
/// \returns
|
||||
/// - true when successful
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetTagNames(const winstd::com_obj<ADOField>& f, LCID lcid, std::list<std::wstring>& names) const;
|
||||
|
||||
///
|
||||
/// Returns character translations
|
||||
@@ -359,8 +497,7 @@ namespace ZRCola {
|
||||
/// - true when query succeeds
|
||||
/// - false otherwise
|
||||
///
|
||||
bool SelectTranslations(ATL::CComPtr<ADORecordset>& rs) const;
|
||||
|
||||
bool SelectTranslations(winstd::com_obj<ADORecordset>& rs) const;
|
||||
|
||||
///
|
||||
/// Returns translation data
|
||||
@@ -372,8 +509,7 @@ namespace ZRCola {
|
||||
/// - true when succeeded
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetTranslation(const ATL::CComPtr<ADORecordset>& rs, translation& t) const;
|
||||
|
||||
bool GetTranslation(const winstd::com_obj<ADORecordset>& rs, translation& t) const;
|
||||
|
||||
///
|
||||
/// Returns key sequences
|
||||
@@ -384,8 +520,7 @@ namespace ZRCola {
|
||||
/// - true when query succeeds
|
||||
/// - false otherwise
|
||||
///
|
||||
bool SelectKeySequences(ATL::CComPtr<ADORecordset>& rs) const;
|
||||
|
||||
bool SelectKeySequences(winstd::com_obj<ADORecordset>& rs) const;
|
||||
|
||||
///
|
||||
/// Returns key sequence data
|
||||
@@ -397,8 +532,7 @@ namespace ZRCola {
|
||||
/// - true when succeeded
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetKeySequence(const ATL::CComPtr<ADORecordset>& rs, keyseq& ks) const;
|
||||
|
||||
bool GetKeySequence(const winstd::com_obj<ADORecordset>& rs, keyseq& ks) const;
|
||||
|
||||
///
|
||||
/// Returns languages
|
||||
@@ -409,8 +543,7 @@ namespace ZRCola {
|
||||
/// - true when query succeeds
|
||||
/// - false otherwise
|
||||
///
|
||||
bool SelectLanguages(ATL::CComPtr<ADORecordset>& rs) const;
|
||||
|
||||
bool SelectLanguages(winstd::com_obj<ADORecordset>& rs) const;
|
||||
|
||||
///
|
||||
/// Returns language data
|
||||
@@ -422,8 +555,7 @@ namespace ZRCola {
|
||||
/// - true when succeeded
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetLanguage(const ATL::CComPtr<ADORecordset>& rs, language& lang) const;
|
||||
|
||||
bool GetLanguage(const winstd::com_obj<ADORecordset>& rs, language& lang) const;
|
||||
|
||||
///
|
||||
/// Returns language character
|
||||
@@ -434,8 +566,7 @@ namespace ZRCola {
|
||||
/// - true when query succeeds
|
||||
/// - false otherwise
|
||||
///
|
||||
bool SelectLanguageCharacters(ATL::CComPtr<ADORecordset>& rs) const;
|
||||
|
||||
bool SelectLanguageCharacters(winstd::com_obj<ADORecordset>& rs) const;
|
||||
|
||||
///
|
||||
/// Returns language character data
|
||||
@@ -447,8 +578,7 @@ namespace ZRCola {
|
||||
/// - true when succeeded
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetLanguageCharacter(const ATL::CComPtr<ADORecordset>& rs, langchar& lc) const;
|
||||
|
||||
bool GetLanguageCharacter(const winstd::com_obj<ADORecordset>& rs, langchar& lc) const;
|
||||
|
||||
///
|
||||
/// Returns character groups
|
||||
@@ -459,8 +589,7 @@ namespace ZRCola {
|
||||
/// - true when query succeeds
|
||||
/// - false otherwise
|
||||
///
|
||||
bool SelectCharacterGroups(ATL::CComPtr<ADORecordset>& rs) const;
|
||||
|
||||
bool SelectCharacterGroups(winstd::com_obj<ADORecordset>& rs) const;
|
||||
|
||||
///
|
||||
/// Returns character group data
|
||||
@@ -472,7 +601,7 @@ namespace ZRCola {
|
||||
/// - true when succeeded
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetCharacterGroup(const ATL::CComPtr<ADORecordset>& rs, chrgrp& cg) const;
|
||||
bool GetCharacterGroup(const winstd::com_obj<ADORecordset>& rs, chrgrp& cg) const;
|
||||
|
||||
///
|
||||
/// Returns characters
|
||||
@@ -483,8 +612,7 @@ namespace ZRCola {
|
||||
/// - true when query succeeds
|
||||
/// - false otherwise
|
||||
///
|
||||
bool SelectCharacters(ATL::CComPtr<ADORecordset>& rs) const;
|
||||
|
||||
bool SelectCharacters(winstd::com_obj<ADORecordset>& rs) const;
|
||||
|
||||
///
|
||||
/// Returns character data
|
||||
@@ -496,7 +624,7 @@ namespace ZRCola {
|
||||
/// - true when succeeded
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetCharacter(const ATL::CComPtr<ADORecordset>& rs, character& chr) const;
|
||||
bool GetCharacter(const winstd::com_obj<ADORecordset>& rs, character& chr) const;
|
||||
|
||||
///
|
||||
/// Returns character categories
|
||||
@@ -507,8 +635,7 @@ namespace ZRCola {
|
||||
/// - true when query succeeds
|
||||
/// - false otherwise
|
||||
///
|
||||
bool SelectCharacterCategories(ATL::CComPtr<ADORecordset>& rs) const;
|
||||
|
||||
bool SelectCharacterCategories(winstd::com_obj<ADORecordset>& rs) const;
|
||||
|
||||
///
|
||||
/// Returns character category data
|
||||
@@ -520,14 +647,60 @@ namespace ZRCola {
|
||||
/// - true when succeeded
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetCharacterCategory(const ATL::CComPtr<ADORecordset>& rs, chrcat& cc) const;
|
||||
bool GetCharacterCategory(const winstd::com_obj<ADORecordset>& rs, chrcat& cc) const;
|
||||
|
||||
///
|
||||
/// Returns character tags
|
||||
///
|
||||
/// \param[out] rs Recordset with results
|
||||
///
|
||||
/// \returns
|
||||
/// - true when query succeeds
|
||||
/// - false otherwise
|
||||
///
|
||||
bool SelectCharacterTags(winstd::com_obj<ADORecordset>& rs) const;
|
||||
|
||||
///
|
||||
/// Returns character tag data
|
||||
///
|
||||
/// \param[in] rs Recordset with results
|
||||
/// \param[out] cc Character tag
|
||||
///
|
||||
/// \returns
|
||||
/// - true when succeeded
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetCharacterTag(const winstd::com_obj<ADORecordset>& rs, chrtag& tc) const;
|
||||
|
||||
///
|
||||
/// Returns tag names
|
||||
///
|
||||
/// \param[out] rs Recordset with results
|
||||
///
|
||||
/// \returns
|
||||
/// - true when query succeeds
|
||||
/// - false otherwise
|
||||
///
|
||||
bool SelectTagNames(winstd::com_obj<ADORecordset>& rs) const;
|
||||
|
||||
///
|
||||
/// Returns tag name data
|
||||
///
|
||||
/// \param[in] rs Recordset with results
|
||||
/// \param[out] tn Tag name
|
||||
///
|
||||
/// \returns
|
||||
/// - true when succeeded
|
||||
/// - false otherwise
|
||||
///
|
||||
bool GetTagName(const winstd::com_obj<ADORecordset>& rs, tagname& tn) const;
|
||||
|
||||
protected:
|
||||
std::basic_string<TCHAR> m_filename; ///< Database filename
|
||||
ATL::CComPtr<ADOConnection> m_db; ///< Database
|
||||
winstd::com_obj<ADOConnection> m_db; ///< Database
|
||||
_locale_t m_locale; ///< Database locale
|
||||
|
||||
ATL::CComPtr<ADOCommand> m_comCharacterGroup; ///< ADO Command for GetCharacterGroup subquery
|
||||
ATL::CComPtr<ADOParameter> m_pCharacterGroup1; ///< \c m_comCharacterGroup parameter
|
||||
winstd::com_obj<ADOCommand> m_comCharacterGroup; ///< ADO Command for GetCharacterGroup subquery
|
||||
winstd::com_obj<ADOParameter> m_pCharacterGroup1; ///< \c m_comCharacterGroup parameter
|
||||
};
|
||||
};
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: ZRColaCompile\n"
|
||||
"POT-Creation-Date: 2016-05-13 20:00+0200\n"
|
||||
"POT-Creation-Date: 2016-10-13 11:49+0200\n"
|
||||
"PO-Revision-Date: 2016-04-13 18:11+0200\n"
|
||||
"Last-Translator: Simon Rozman <simon.rozman@amebis.si>\n"
|
||||
"Language-Team: Amebis, d. o. o., Kamnik <info@amebis.si>\n"
|
||||
@@ -10,7 +10,7 @@ msgstr ""
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Generator: Poedit 1.8.7\n"
|
||||
"X-Generator: Poedit 1.8.9\n"
|
||||
"X-Poedit-Basepath: ..\n"
|
||||
"Plural-Forms: nplurals=4; plural=(n%100==1 ? 0 : n%100==2 ? 1 : n%100==3 || n"
|
||||
"%100==4 ? 2 : 3);\n"
|
||||
@@ -18,22 +18,18 @@ msgstr ""
|
||||
"X-Poedit-KeywordsList: _\n"
|
||||
"X-Poedit-SearchPath-0: .\n"
|
||||
|
||||
#: main.cpp:53
|
||||
#, fuzzy
|
||||
#: main.cpp:102
|
||||
msgid "Show this help message"
|
||||
msgstr "Pokaži to sporočilo pomoči"
|
||||
msgstr ""
|
||||
|
||||
#: main.cpp:54
|
||||
#, fuzzy
|
||||
#: main.cpp:103
|
||||
msgid "<input file>"
|
||||
msgstr "<vhodna datoteka>"
|
||||
msgstr ""
|
||||
|
||||
#: main.cpp:55
|
||||
#, fuzzy
|
||||
#: main.cpp:104
|
||||
msgid "<output file>"
|
||||
msgstr "<izhodna datoteka>"
|
||||
msgstr ""
|
||||
|
||||
#: main.cpp:56
|
||||
#, fuzzy
|
||||
#: main.cpp:105
|
||||
msgid "<output POT catalog>"
|
||||
msgstr "<izhodni katalog POT>"
|
||||
msgstr ""
|
||||
|
||||
@@ -1,33 +1,32 @@
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: ZRColaCompile\n"
|
||||
"POT-Creation-Date: 2016-05-13 20:01+0200\n"
|
||||
"PO-Revision-Date: 2016-05-13 20:01+0200\n"
|
||||
"POT-Creation-Date: 2016-10-05 10:59+0200\n"
|
||||
"PO-Revision-Date: 2016-10-05 10:59+0200\n"
|
||||
"Last-Translator: Simon Rozman <simon.rozman@amebis.si>\n"
|
||||
"Language-Team: Amebis, d. o. o., Kamnik <info@amebis.si>\n"
|
||||
"Language: de_DE\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Generator: Poedit 1.8.7\n"
|
||||
"X-Generator: Poedit 1.8.9\n"
|
||||
"X-Poedit-Basepath: .\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-Poedit-SourceCharset: UTF-8\n"
|
||||
"X-Poedit-KeywordsList: _\n"
|
||||
|
||||
#: main.cpp:53
|
||||
#, fuzzy
|
||||
#: main.cpp:56
|
||||
msgid "Show this help message"
|
||||
msgstr "Zeige diesen Hilfstext"
|
||||
|
||||
#: main.cpp:54
|
||||
#: main.cpp:57
|
||||
msgid "<input file>"
|
||||
msgstr ""
|
||||
|
||||
#: main.cpp:55
|
||||
#: main.cpp:58
|
||||
msgid "<output file>"
|
||||
msgstr ""
|
||||
|
||||
#: main.cpp:56
|
||||
#: main.cpp:59
|
||||
msgid "<output POT catalog>"
|
||||
msgstr ""
|
||||
|
||||
@@ -1,33 +1,33 @@
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: ZRColaCompile\n"
|
||||
"POT-Creation-Date: 2016-05-13 20:01+0200\n"
|
||||
"PO-Revision-Date: 2016-05-13 20:01+0200\n"
|
||||
"POT-Creation-Date: 2016-10-05 11:00+0200\n"
|
||||
"PO-Revision-Date: 2016-10-05 11:00+0200\n"
|
||||
"Last-Translator: Simon Rozman <simon.rozman@amebis.si>\n"
|
||||
"Language-Team: Amebis, d. o. o., Kamnik <info@amebis.si>\n"
|
||||
"Language: ru_RU\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Generator: Poedit 1.8.7\n"
|
||||
"X-Generator: Poedit 1.8.9\n"
|
||||
"X-Poedit-Basepath: .\n"
|
||||
"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
|
||||
"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
|
||||
"X-Poedit-SourceCharset: UTF-8\n"
|
||||
"X-Poedit-KeywordsList: _\n"
|
||||
|
||||
#: main.cpp:53
|
||||
#: main.cpp:56
|
||||
msgid "Show this help message"
|
||||
msgstr ""
|
||||
|
||||
#: main.cpp:54
|
||||
#: main.cpp:57
|
||||
msgid "<input file>"
|
||||
msgstr ""
|
||||
|
||||
#: main.cpp:55
|
||||
#: main.cpp:58
|
||||
msgid "<output file>"
|
||||
msgstr ""
|
||||
|
||||
#: main.cpp:56
|
||||
#: main.cpp:59
|
||||
msgid "<output POT catalog>"
|
||||
msgstr ""
|
||||
|
||||
@@ -1,33 +1,33 @@
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: ZRColaCompile\n"
|
||||
"POT-Creation-Date: 2016-05-13 20:00+0200\n"
|
||||
"PO-Revision-Date: 2016-05-13 20:00+0200\n"
|
||||
"POT-Creation-Date: 2016-10-05 10:59+0200\n"
|
||||
"PO-Revision-Date: 2016-10-05 11:00+0200\n"
|
||||
"Last-Translator: Simon Rozman <simon.rozman@amebis.si>\n"
|
||||
"Language-Team: Amebis, d. o. o., Kamnik <info@amebis.si>\n"
|
||||
"Language: sl_SI\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Generator: Poedit 1.8.7\n"
|
||||
"X-Generator: Poedit 1.8.9\n"
|
||||
"X-Poedit-Basepath: .\n"
|
||||
"Plural-Forms: nplurals=4; plural=(n%100==1 ? 0 : n%100==2 ? 1 : n%100==3 || n"
|
||||
"%100==4 ? 2 : 3);\n"
|
||||
"X-Poedit-SourceCharset: UTF-8\n"
|
||||
"X-Poedit-KeywordsList: _\n"
|
||||
|
||||
#: main.cpp:53
|
||||
#: main.cpp:56
|
||||
msgid "Show this help message"
|
||||
msgstr "Pokaži to sporočilo pomoči"
|
||||
|
||||
#: main.cpp:54
|
||||
#: main.cpp:57
|
||||
msgid "<input file>"
|
||||
msgstr "<vhodna datoteka>"
|
||||
|
||||
#: main.cpp:55
|
||||
#: main.cpp:58
|
||||
msgid "<output file>"
|
||||
msgstr "<izhodna datoteka>"
|
||||
|
||||
#: main.cpp:56
|
||||
#: main.cpp:59
|
||||
msgid "<output POT catalog>"
|
||||
msgstr "<izhodni katalog POT>"
|
||||
|
||||
@@ -20,6 +20,57 @@
|
||||
#include "stdafx.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace stdex;
|
||||
using namespace winstd;
|
||||
|
||||
|
||||
typedef map<wchar_t, set<ZRCola::DBSource::charseq, ZRCola::DBSource::charseq::less_rank_str> > translation_db;
|
||||
|
||||
|
||||
static set<wstring> decompose(_In_ const translation_db &db, _In_z_ const wchar_t *str, _Inout_ set<wchar_t> &path)
|
||||
{
|
||||
set<wstring> res;
|
||||
|
||||
if (*str) {
|
||||
// Decompose remainder first.
|
||||
auto rem = decompose(db, str + 1, path);
|
||||
if (rem.empty())
|
||||
return res;
|
||||
|
||||
auto const t = db.find(*str);
|
||||
if (t != db.end()) {
|
||||
// Current characted decomposed. Iterate all possible decompositions and combine them with the remainder.
|
||||
auto p = path.insert(*str);
|
||||
if (!p.second) {
|
||||
// Path already contains this character: Cycle detected!
|
||||
return res;
|
||||
}
|
||||
for (auto d = t->second.cbegin(), d_end = t->second.cend(); d != d_end; ++d) {
|
||||
auto dec = decompose(db, d->str.c_str(), path);
|
||||
if (!dec.empty()) {
|
||||
for (auto dd = dec.cbegin(), dd_end = dec.cend(); dd != dd_end; ++dd) {
|
||||
for (auto r = rem.cbegin(), r_end = rem.cend(); r != r_end; ++r)
|
||||
res.insert(*dd + *r);
|
||||
}
|
||||
} else {
|
||||
// Cycle detected. Do not continue decomposition.
|
||||
for (auto r = rem.cbegin(), r_end = rem.cend(); r != r_end; ++r)
|
||||
res.insert(wstring(1, *str) + *r);
|
||||
}
|
||||
}
|
||||
path.erase(p.first);
|
||||
} else {
|
||||
// Current character is non-decomposable. Combine it with the remainder(s).
|
||||
for (auto r = rem.cbegin(), r_end = rem.cend(); r != r_end; ++r)
|
||||
res.insert(wstring(1, *str) + *r);
|
||||
}
|
||||
} else {
|
||||
// Empty string results in empty decomposition.
|
||||
res.insert(L"");
|
||||
}
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
|
||||
///
|
||||
@@ -29,25 +80,21 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
{
|
||||
wxApp::CheckBuildOptions(WX_BUILD_OPTIONS_SIGNATURE, "program");
|
||||
|
||||
// Inizialize wxWidgets.
|
||||
// Initialize wxWidgets.
|
||||
wxInitializer initializer;
|
||||
if (!initializer) {
|
||||
_ftprintf(stderr, wxT("Failed to initialize the wxWidgets library, aborting.\n"));
|
||||
return -1;
|
||||
}
|
||||
|
||||
wxConfig config(wxT(ZRCOLA_CFG_APPLICATION), wxT(ZRCOLA_CFG_VENDOR));
|
||||
// Initialize configuration.
|
||||
wxConfigBase *cfgPrev = wxConfigBase::Set(new wxConfig(wxT(PRODUCT_CFG_APPLICATION), wxT(PRODUCT_CFG_VENDOR)));
|
||||
if (cfgPrev) wxDELETE(cfgPrev);
|
||||
|
||||
// Set desired locale.
|
||||
// Initialize locale.
|
||||
wxLocale locale;
|
||||
wxLanguage language = (wxLanguage)config.Read(wxT("Language"), wxLANGUAGE_DEFAULT);
|
||||
if (wxLocale::IsAvailable(language)) {
|
||||
wxString sPath;
|
||||
if (config.Read(wxT("LocalizationRepositoryPath"), &sPath))
|
||||
locale.AddCatalogLookupPathPrefix(sPath);
|
||||
wxVERIFY(locale.Init(language));
|
||||
if (wxInitializeLocale(locale))
|
||||
wxVERIFY(locale.AddCatalog(wxT("ZRColaCompile")));
|
||||
}
|
||||
|
||||
// Parse command line.
|
||||
static const wxCmdLineEntryDesc cmdLineDesc[] =
|
||||
@@ -102,15 +149,56 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
set<wstring> pot;
|
||||
|
||||
// Open file ID.
|
||||
streamoff dst_start = stdex::idrec::open<ZRCola::recordid_t, ZRCola::recordsize_t>(dst, ZRCOLA_DB_ID);
|
||||
streamoff dst_start = idrec::open<ZRCola::recordid_t, ZRCola::recordsize_t>(dst, ZRCOLA_DB_ID);
|
||||
|
||||
{
|
||||
// Get translations.
|
||||
ATL::CComPtr<ADORecordset> rs;
|
||||
com_obj<ADORecordset> rs;
|
||||
if (src.SelectTranslations(rs)) {
|
||||
size_t count = src.GetRecordsetCount(rs);
|
||||
if (count < 0xffffffff) { // 4G check (-1 is reserved for error condition)
|
||||
ZRCola::DBSource::translation trans;
|
||||
// Parse translations and build temporary database.
|
||||
translation_db db_temp1;
|
||||
for (; !ZRCola::DBSource::IsEOF(rs); rs->MoveNext()) {
|
||||
// Read translation from the database.
|
||||
ZRCola::DBSource::translation trans;
|
||||
if (src.GetTranslation(rs, trans)) {
|
||||
// Add translation to temporary database.
|
||||
auto const t = db_temp1.find(trans.chr);
|
||||
if (t != db_temp1.end())
|
||||
t->second.insert(std::move(trans.decomp));
|
||||
else {
|
||||
translation_db::mapped_type d;
|
||||
d.insert(std::move(trans.decomp));
|
||||
db_temp1.insert(std::move(pair<translation_db::key_type, translation_db::mapped_type>(trans.chr, std::move(d))));
|
||||
}
|
||||
} else
|
||||
has_errors = true;
|
||||
}
|
||||
|
||||
// Decompose decompositions down to non-decomposable characters.
|
||||
translation_db db_temp2;
|
||||
for (auto t1 = db_temp1.cbegin(), t1_end = db_temp1.cend(); t1 != t1_end; ++t1) {
|
||||
for (auto d1 = t1->second.cbegin(), d1_end = t1->second.cend(); d1 != d1_end; ++d1) {
|
||||
set<wchar_t> path;
|
||||
path.insert(t1->first);
|
||||
auto str = decompose(db_temp1, d1->str.c_str(), path);
|
||||
assert(!str.empty());
|
||||
|
||||
// Add translation to temporary database.
|
||||
auto const t2 = db_temp2.find(t1->first);
|
||||
if (t2 != db_temp2.end()) {
|
||||
for (auto s = str.cbegin(), s_end = str.cend(); s != s_end; ++s)
|
||||
t2->second.insert(std::move(ZRCola::DBSource::charseq(d1->rank, s->c_str())));
|
||||
} else {
|
||||
translation_db::mapped_type d2;
|
||||
for (auto s = str.cbegin(), s_end = str.cend(); s != s_end; ++s)
|
||||
d2.insert(std::move(ZRCola::DBSource::charseq(d1->rank, s->c_str())));
|
||||
db_temp2.insert(std::move(pair<translation_db::key_type, translation_db::mapped_type>(t1->first, std::move(d2))));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
ZRCola::translation_db db;
|
||||
|
||||
// Preallocate memory.
|
||||
@@ -119,25 +207,21 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
db.data .reserve(count*4);
|
||||
|
||||
// Parse translations and build index and data.
|
||||
while (!ZRCola::DBSource::IsEOF(rs)) {
|
||||
// Read translation from the database.
|
||||
if (src.GetTranslation(rs, trans)) {
|
||||
// Add translation to index and data.
|
||||
for (auto t = db_temp2.cbegin(), t_end = db_temp2.cend(); t != t_end; ++t) {
|
||||
// Add translation to index and data.
|
||||
for (auto d = t->second.cbegin(), d_end = t->second.cend(); d != d_end; ++d) {
|
||||
unsigned __int32 idx = db.data.size();
|
||||
db.data.push_back(trans.chr);
|
||||
wxASSERT_MSG((int)0xffff8000 <= trans.rank && trans.rank <= (int)0x00007fff, wxT("transformation rank out of bounds"));
|
||||
db.data.push_back((unsigned __int16)trans.rank);
|
||||
wstring::size_type n = trans.str.length();
|
||||
db.data.push_back(t->first);
|
||||
wxASSERT_MSG((int)0xffff8000 <= d->rank && d->rank <= (int)0x00007fff, wxT("transformation rank out of bounds"));
|
||||
db.data.push_back((unsigned __int16)d->rank);
|
||||
wstring::size_type n = d->str.length();
|
||||
wxASSERT_MSG(n <= 0xffff, wxT("transformation string too long"));
|
||||
db.data.push_back((unsigned __int16)n);
|
||||
for (wstring::size_type i = 0; i < n; i++)
|
||||
db.data.push_back(trans.str[i]);
|
||||
db.data.push_back(d->str[i]);
|
||||
db.idxComp .push_back(idx);
|
||||
db.idxDecomp.push_back(idx);
|
||||
} else
|
||||
has_errors = true;
|
||||
|
||||
wxVERIFY(SUCCEEDED(rs->MoveNext()));
|
||||
}
|
||||
}
|
||||
|
||||
// Sort indices.
|
||||
@@ -158,7 +242,7 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
|
||||
{
|
||||
// Get key sequences.
|
||||
ATL::CComPtr<ADORecordset> rs;
|
||||
com_obj<ADORecordset> rs;
|
||||
if (src.SelectKeySequences(rs)) {
|
||||
size_t count = src.GetRecordsetCount(rs);
|
||||
if (count < 0xffffffff) { // 4G check (-1 is reserved for error condition)
|
||||
@@ -171,7 +255,7 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
db.data .reserve(count*4);
|
||||
|
||||
// Parse key sequences and build index and data.
|
||||
while (!ZRCola::DBSource::IsEOF(rs)) {
|
||||
for (; !ZRCola::DBSource::IsEOF(rs); rs->MoveNext()) {
|
||||
// Read key sequence from the database.
|
||||
if (src.GetKeySequence(rs, ks)) {
|
||||
// Add key sequence to index and data.
|
||||
@@ -192,8 +276,6 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
db.idxKey.push_back(idx);
|
||||
} else
|
||||
has_errors = true;
|
||||
|
||||
wxVERIFY(SUCCEEDED(rs->MoveNext()));
|
||||
}
|
||||
|
||||
// Sort indices.
|
||||
@@ -227,7 +309,7 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
|
||||
{
|
||||
// Get languages.
|
||||
ATL::CComPtr<ADORecordset> rs;
|
||||
com_obj<ADORecordset> rs;
|
||||
if (src.SelectLanguages(rs)) {
|
||||
size_t count = src.GetRecordsetCount(rs);
|
||||
if (count < 0xffffffff) { // 4G check (-1 is reserved for error condition)
|
||||
@@ -239,9 +321,12 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
db.data .reserve(count*4);
|
||||
|
||||
// Parse languages and build index and data.
|
||||
while (!ZRCola::DBSource::IsEOF(rs)) {
|
||||
for (; !ZRCola::DBSource::IsEOF(rs); rs->MoveNext()) {
|
||||
// Read language from the database.
|
||||
if (src.GetLanguage(rs, lang)) {
|
||||
if (build_pot)
|
||||
pot.insert(lang.name);
|
||||
|
||||
// Add language to index and data.
|
||||
unsigned __int32 idx = db.data.size();
|
||||
for (wstring::size_type i = 0; i < sizeof(ZRCola::langid_t)/sizeof(unsigned __int16); i++)
|
||||
@@ -252,12 +337,8 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
for (wstring::size_type i = 0; i < n; i++)
|
||||
db.data.push_back(lang.name[i]);
|
||||
db.idxLng.push_back(idx);
|
||||
if (build_pot)
|
||||
pot.insert(lang.name);
|
||||
} else
|
||||
has_errors = true;
|
||||
|
||||
wxVERIFY(SUCCEEDED(rs->MoveNext()));
|
||||
}
|
||||
|
||||
// Sort indices.
|
||||
@@ -277,7 +358,7 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
|
||||
{
|
||||
// Get language characters.
|
||||
ATL::CComPtr<ADORecordset> rs;
|
||||
com_obj<ADORecordset> rs;
|
||||
if (src.SelectLanguageCharacters(rs)) {
|
||||
size_t count = src.GetRecordsetCount(rs);
|
||||
if (count < 0xffffffff) { // 4G check (-1 is reserved for error condition)
|
||||
@@ -292,7 +373,7 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
db.data .reserve(count*4);
|
||||
|
||||
// Parse language characters and build index and data.
|
||||
while (!ZRCola::DBSource::IsEOF(rs)) {
|
||||
for (; !ZRCola::DBSource::IsEOF(rs); rs->MoveNext()) {
|
||||
// Read language characters from the database.
|
||||
if (src.GetLanguageCharacter(rs, lc)) {
|
||||
// Add language characters to index and data.
|
||||
@@ -306,8 +387,6 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
#endif
|
||||
} else
|
||||
has_errors = true;
|
||||
|
||||
wxVERIFY(SUCCEEDED(rs->MoveNext()));
|
||||
}
|
||||
|
||||
// Sort indices.
|
||||
@@ -330,7 +409,7 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
|
||||
{
|
||||
// Get character groups.
|
||||
ATL::CComPtr<ADORecordset> rs;
|
||||
com_obj<ADORecordset> rs;
|
||||
if (src.SelectCharacterGroups(rs)) {
|
||||
size_t count = src.GetRecordsetCount(rs);
|
||||
if (count < 0xffffffff) { // 4G check (-1 is reserved for error condition)
|
||||
@@ -342,9 +421,17 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
db.data .reserve(count*4);
|
||||
|
||||
// Parse character groups and build index and data.
|
||||
while (!ZRCola::DBSource::IsEOF(rs)) {
|
||||
for (; !ZRCola::DBSource::IsEOF(rs); rs->MoveNext()) {
|
||||
// Read character group from the database.
|
||||
if (src.GetCharacterGroup(rs, cg)) {
|
||||
if (build_pot)
|
||||
pot.insert(cg.name);
|
||||
|
||||
if (cg.chars.empty()) {
|
||||
// Skip empty character groups.
|
||||
continue;
|
||||
}
|
||||
|
||||
// Add character group to index and data.
|
||||
unsigned __int32 idx = db.data.size();
|
||||
wxASSERT_MSG((int)0xffff8000 <= cg.id && cg.id <= (int)0x00007fff, wxT("character group ID out of bounds"));
|
||||
@@ -361,13 +448,11 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
db.data.push_back(cg.name[i]);
|
||||
for (wstring::size_type i = 0; i < n_char; i++)
|
||||
db.data.push_back(cg.chars[i]);
|
||||
for (std::vector<unsigned __int16>::size_type i = 0, n = cg.show.size(); i < n; i++)
|
||||
db.data.push_back(cg.show[i]);
|
||||
db.idxRnk.push_back(idx);
|
||||
if (build_pot)
|
||||
pot.insert(cg.name);
|
||||
} else
|
||||
has_errors = true;
|
||||
|
||||
wxVERIFY(SUCCEEDED(rs->MoveNext()));
|
||||
}
|
||||
|
||||
// Sort indices.
|
||||
@@ -389,51 +474,62 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
|
||||
{
|
||||
// Get characters.
|
||||
ATL::CComPtr<ADORecordset> rs;
|
||||
com_obj<ADORecordset> rs;
|
||||
if (src.SelectCharacters(rs)) {
|
||||
size_t count = src.GetRecordsetCount(rs);
|
||||
if (count < 0xffffffff) { // 4G check (-1 is reserved for error condition)
|
||||
ZRCola::DBSource::character chr;
|
||||
ZRCola::character_db db;
|
||||
ZRCola::DBSource::character_desc_idx idxChrDsc, idxChrDscSub;
|
||||
|
||||
ZRCola::DBSource::character_bank chrs;
|
||||
|
||||
// Phase 1: Parse characters and build indexes.
|
||||
for (; !ZRCola::DBSource::IsEOF(rs); rs->MoveNext()) {
|
||||
// Read character from the database.
|
||||
unique_ptr<ZRCola::DBSource::character> c(new ZRCola::DBSource::character);
|
||||
if (src.GetCharacter(rs, *c)) {
|
||||
const auto &chr = *c.get();
|
||||
chrs[chr.chr].swap(c);
|
||||
} else
|
||||
has_errors = true;
|
||||
}
|
||||
|
||||
// Phase 2: Build related character lists.
|
||||
chrs.build_related();
|
||||
|
||||
ZRCola::character_db db;
|
||||
|
||||
// Preallocate memory.
|
||||
db.idxChr.reserve(count);
|
||||
db.data .reserve(count*4);
|
||||
|
||||
// Parse characters and build index and data.
|
||||
while (!ZRCola::DBSource::IsEOF(rs)) {
|
||||
// Read character from the database.
|
||||
if (src.GetCharacter(rs, chr)) {
|
||||
// Add character to index and data.
|
||||
unsigned __int32 idx = db.data.size();
|
||||
db.data.push_back((unsigned __int16)chr.chr);
|
||||
for (wstring::size_type i = 0; i < sizeof(ZRCola::chrcatid_t)/sizeof(unsigned __int16); i++)
|
||||
db.data.push_back(((const unsigned __int16*)chr.cat.data)[i]);
|
||||
wstring::size_type n_desc = chr.desc.length();
|
||||
wxASSERT_MSG(n_desc <= 0xffff, wxT("character description too long"));
|
||||
db.data.push_back((unsigned __int16)n_desc);
|
||||
wstring::size_type n_rel = chr.rel.length();
|
||||
wxASSERT_MSG(n_rel <= 0xffff, wxT("too many related characters"));
|
||||
db.data.push_back((unsigned __int16)n_rel);
|
||||
for (wstring::size_type i = 0; i < n_desc; i++)
|
||||
db.data.push_back(chr.desc[i]);
|
||||
for (wstring::size_type i = 0; i < n_rel; i++)
|
||||
db.data.push_back(chr.rel[i]);
|
||||
db.idxChr.push_back(idx);
|
||||
// Phase 3: Parse characters and build index and data.
|
||||
for (size_t i = 0, i_end = chrs.size(); i < i_end; i++) {
|
||||
const auto &chr = *(chrs[i].get());
|
||||
if (&chr == NULL) continue;
|
||||
|
||||
// Add description (and keywords) to index.
|
||||
idxChrDsc .add_keywords(chr.desc .c_str(), chr.chr, 0);
|
||||
idxChrDsc .add_keywords(chr.keywords.c_str(), chr.chr, 0);
|
||||
idxChrDscSub.add_keywords(chr.desc .c_str(), chr.chr, 3);
|
||||
idxChrDscSub.add_keywords(chr.keywords.c_str(), chr.chr, 3);
|
||||
// Add character to index and data.
|
||||
unsigned __int32 idx = db.data.size();
|
||||
db.data.push_back((unsigned __int16)chr.chr);
|
||||
for (wstring::size_type i = 0; i < sizeof(ZRCola::chrcatid_t)/sizeof(unsigned __int16); i++)
|
||||
db.data.push_back(((const unsigned __int16*)chr.cat.data)[i]);
|
||||
wstring::size_type n_desc = chr.desc.length();
|
||||
wxASSERT_MSG(n_desc <= 0xffff, wxT("character description too long"));
|
||||
db.data.push_back((unsigned __int16)n_desc);
|
||||
wstring::size_type n_rel = chr.rel.length();
|
||||
wxASSERT_MSG(n_rel <= 0xffff, wxT("too many related characters"));
|
||||
db.data.push_back((unsigned __int16)n_rel);
|
||||
for (wstring::size_type i = 0; i < n_desc; i++)
|
||||
db.data.push_back(chr.desc[i]);
|
||||
for (wstring::size_type i = 0; i < n_rel; i++)
|
||||
db.data.push_back(chr.rel[i]);
|
||||
db.idxChr.push_back(idx);
|
||||
|
||||
// Mark category used.
|
||||
categories_used.insert(chr.cat);
|
||||
} else
|
||||
has_errors = true;
|
||||
// Add description (and keywords) to index.
|
||||
idxChrDsc .add_keywords(chr.terms, chr.chr, 0);
|
||||
idxChrDscSub.add_keywords(chr.terms, chr.chr, 3);
|
||||
|
||||
wxVERIFY(SUCCEEDED(rs->MoveNext()));
|
||||
// Mark category used.
|
||||
categories_used.insert(chr.cat);
|
||||
}
|
||||
|
||||
// Sort indices.
|
||||
@@ -457,7 +553,7 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
|
||||
{
|
||||
// Get character categories.
|
||||
ATL::CComPtr<ADORecordset> rs;
|
||||
com_obj<ADORecordset> rs;
|
||||
if (src.SelectCharacterCategories(rs)) {
|
||||
size_t count = src.GetRecordsetCount(rs);
|
||||
if (count < 0xffffffff) { // 4G check (-1 is reserved for error condition)
|
||||
@@ -470,31 +566,32 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
db.data .reserve(count*4);
|
||||
|
||||
// Parse character categories and build index and data.
|
||||
while (!ZRCola::DBSource::IsEOF(rs)) {
|
||||
for (; !ZRCola::DBSource::IsEOF(rs); rs->MoveNext()) {
|
||||
// Read character category from the database.
|
||||
if (src.GetCharacterCategory(rs, cc)) {
|
||||
if (categories_used.find(cc.id) != categories_used.end()) {
|
||||
// Add character category to index and data.
|
||||
unsigned __int32 idx = db.data.size();
|
||||
for (wstring::size_type i = 0; i < sizeof(ZRCola::chrcatid_t)/sizeof(unsigned __int16); i++)
|
||||
db.data.push_back(((const unsigned __int16*)cc.id.data)[i]);
|
||||
wxASSERT_MSG((int)0xffff8000 <= cc.rank && cc.rank <= (int)0x00007fff, wxT("character category rank out of bounds"));
|
||||
db.data.push_back((unsigned __int16)cc.rank);
|
||||
wstring::size_type n_name = cc.name.length();
|
||||
wxASSERT_MSG(n_name <= 0xffff, wxT("character category name too long"));
|
||||
db.data.push_back((unsigned __int16)n_name);
|
||||
for (wstring::size_type i = 0; i < n_name; i++)
|
||||
db.data.push_back(cc.name[i]);
|
||||
db.idxChrCat.push_back(idx);
|
||||
db.idxRnk .push_back(idx);
|
||||
if (build_pot)
|
||||
pot.insert(cc.name);
|
||||
} else
|
||||
_ftprintf(stderr, wxT("%s: warning ZCC0019: Ommiting empty category %ls.\n"), (LPCTSTR)filenameIn.c_str(), (LPCWSTR)cc.name.c_str());
|
||||
if (build_pot)
|
||||
pot.insert(cc.name);
|
||||
|
||||
if (categories_used.find(cc.id) == categories_used.end()) {
|
||||
// Skip empty character categories.
|
||||
continue;
|
||||
}
|
||||
|
||||
// Add character category to index and data.
|
||||
unsigned __int32 idx = db.data.size();
|
||||
for (wstring::size_type i = 0; i < sizeof(ZRCola::chrcatid_t)/sizeof(unsigned __int16); i++)
|
||||
db.data.push_back(((const unsigned __int16*)cc.id.data)[i]);
|
||||
wxASSERT_MSG((int)0xffff8000 <= cc.rank && cc.rank <= (int)0x00007fff, wxT("character category rank out of bounds"));
|
||||
db.data.push_back((unsigned __int16)cc.rank);
|
||||
wstring::size_type n_name = cc.name.length();
|
||||
wxASSERT_MSG(n_name <= 0xffff, wxT("character category name too long"));
|
||||
db.data.push_back((unsigned __int16)n_name);
|
||||
for (wstring::size_type i = 0; i < n_name; i++)
|
||||
db.data.push_back(cc.name[i]);
|
||||
db.idxChrCat.push_back(idx);
|
||||
db.idxRnk .push_back(idx);
|
||||
} else
|
||||
has_errors = true;
|
||||
|
||||
wxVERIFY(SUCCEEDED(rs->MoveNext()));
|
||||
}
|
||||
|
||||
// Sort indices.
|
||||
@@ -513,7 +610,107 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
}
|
||||
}
|
||||
|
||||
stdex::idrec::close<ZRCola::recordid_t, ZRCola::recordsize_t, ZRCOLA_RECORD_ALIGN>(dst, dst_start);
|
||||
{
|
||||
// Get characters tags.
|
||||
com_obj<ADORecordset> rs;
|
||||
if (src.SelectCharacterTags(rs)) {
|
||||
size_t count = src.GetRecordsetCount(rs);
|
||||
if (count < 0xffffffff) { // 4G check (-1 is reserved for error condition)
|
||||
ZRCola::DBSource::chrtag ct;
|
||||
ZRCola::chrtag_db db;
|
||||
|
||||
// Preallocate memory.
|
||||
db.idxChr.reserve(count);
|
||||
db.idxTag.reserve(count);
|
||||
db.data .reserve(count*4);
|
||||
|
||||
// Parse characters tags and build index and data.
|
||||
for (; !ZRCola::DBSource::IsEOF(rs); rs->MoveNext()) {
|
||||
// Read characters tags from the database.
|
||||
if (src.GetCharacterTag(rs, ct)) {
|
||||
// Add characters tags to index and data.
|
||||
unsigned __int32 idx = db.data.size();
|
||||
db.data.push_back(ct.chr);
|
||||
wxASSERT_MSG((int)0xffff8000 <= ct.tag && ct.tag <= (int)0x00007fff, wxT("tag out of bounds"));
|
||||
db.data.push_back((unsigned __int16)ct.tag);
|
||||
db.idxChr.push_back(idx);
|
||||
db.idxTag.push_back(idx);
|
||||
} else
|
||||
has_errors = true;
|
||||
}
|
||||
|
||||
// Sort indices.
|
||||
db.idxChr .sort();
|
||||
db.idxTag.sort();
|
||||
|
||||
// Write characters tags to file.
|
||||
dst << ZRCola::chrtag_rec(db);
|
||||
} else {
|
||||
_ftprintf(stderr, wxT("%s: error ZCC0021: Error getting characters tags count from database or too many character tags.\n"), (LPCTSTR)filenameIn.c_str());
|
||||
has_errors = true;
|
||||
}
|
||||
} else {
|
||||
_ftprintf(stderr, wxT("%s: error ZCC0020: Error getting characters tags from database. Please make sure the file is ZRCola.zrc compatible.\n"), (LPCTSTR)filenameIn.c_str());
|
||||
has_errors = true;
|
||||
}
|
||||
}
|
||||
|
||||
{
|
||||
// Get tag names.
|
||||
com_obj<ADORecordset> rs;
|
||||
if (src.SelectTagNames(rs)) {
|
||||
size_t count = src.GetRecordsetCount(rs);
|
||||
if (count < 0xffffffff) { // 4G check (-1 is reserved for error condition)
|
||||
ZRCola::DBSource::tagname tn;
|
||||
ZRCola::tagname_db db;
|
||||
|
||||
// Preallocate memory.
|
||||
db.idxName.reserve(count*3);
|
||||
db.idxTag .reserve(count*3);
|
||||
db.data .reserve(count*3*4);
|
||||
|
||||
// Parse tags and build index and data.
|
||||
for (; !ZRCola::DBSource::IsEOF(rs); rs->MoveNext()) {
|
||||
// Read tag name from the database.
|
||||
if (src.GetTagName(rs, tn)) {
|
||||
// Add tag name to index and data.
|
||||
for (auto ln = tn.names.cbegin(), ln_end = tn.names.cend(); ln != ln_end; ++ln) {
|
||||
for (auto nm = ln->second.cbegin(), nm_end = ln->second.cend(); nm != nm_end; ++nm) {
|
||||
unsigned __int32 idx = db.data.size();
|
||||
wxASSERT_MSG((int)0xffff8000 <= tn.tag && tn.tag <= (int)0x00007fff, wxT("tag out of bounds"));
|
||||
db.data.push_back((unsigned __int16)tn.tag);
|
||||
db.data.push_back(LOWORD(ln->first));
|
||||
db.data.push_back(HIWORD(ln->first));
|
||||
wstring::size_type n = nm->length();
|
||||
wxASSERT_MSG(n <= 0xffff, wxT("tag name too long"));
|
||||
db.data.push_back((unsigned __int16)n);
|
||||
for (wstring::size_type i = 0; i < n; i++)
|
||||
db.data.push_back(nm->at(i));
|
||||
db.idxName.push_back(idx);
|
||||
db.idxTag .push_back(idx);
|
||||
}
|
||||
}
|
||||
} else
|
||||
has_errors = true;
|
||||
}
|
||||
|
||||
// Sort indices.
|
||||
db.idxName.sort();
|
||||
db.idxTag .sort();
|
||||
|
||||
// Write tags to file.
|
||||
dst << ZRCola::tagname_rec(db);
|
||||
} else {
|
||||
_ftprintf(stderr, wxT("%s: error ZCC0023: Error getting tag name count from database or too many tags.\n"), (LPCTSTR)filenameIn.c_str());
|
||||
has_errors = true;
|
||||
}
|
||||
} else {
|
||||
_ftprintf(stderr, wxT("%s: error ZCC0022: Error getting tags from database. Please make sure the file is ZRCola.zrc compatible.\n"), (LPCTSTR)filenameIn.c_str());
|
||||
has_errors = true;
|
||||
}
|
||||
}
|
||||
|
||||
idrec::close<ZRCola::recordid_t, ZRCola::recordsize_t, ZRCOLA_RECORD_ALIGN>(dst, dst_start);
|
||||
|
||||
if (dst.fail()) {
|
||||
_ftprintf(stderr, wxT("%s: error ZCC1000: Writing to output file failed.\n"), (LPCTSTR)filenameOut.c_str());
|
||||
@@ -531,10 +728,10 @@ int _tmain(int argc, _TCHAR *argv[])
|
||||
<< "\"MIME-Version: 1.0\\n\"" << endl
|
||||
<< "\"Content-Type: text/plain; charset=UTF-8\\n\"" << endl
|
||||
<< "\"Content-Transfer-Encoding: 8bit\\n\"" << endl
|
||||
<< "\"X-Generator: ZRColaCompile " << ZRCOLA_VERSION_STR << "\\n\"" << endl;
|
||||
<< "\"X-Generator: ZRColaCompile\\n\"" << endl;
|
||||
|
||||
wstring_convert<codecvt_utf8<wchar_t>> conv;
|
||||
for (set<wstring>::const_iterator i = pot.cbegin(); i != pot.cend(); ++i) {
|
||||
for (auto i = pot.cbegin(); i != pot.cend(); ++i) {
|
||||
// Convert UTF-16 to UTF-8 and escape.
|
||||
string t(conv.to_bytes(*i)), u;
|
||||
for (size_t i = 0, n = t.size(); i < n; i++) {
|
||||
|
||||
@@ -19,13 +19,12 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#define _ATL_NO_AUTOMATIC_NAMESPACE
|
||||
|
||||
#include "../include/zrcola.h"
|
||||
#include "../include/version.h"
|
||||
#include "dbsource.h"
|
||||
|
||||
#include <zrcola/language.h>
|
||||
#include <zrcola/translate.h>
|
||||
#include <zrcola/tag.h>
|
||||
#include <zrcolaui/chargroup.h>
|
||||
#include <zrcolaui/keyboard.h>
|
||||
|
||||
@@ -39,11 +38,13 @@
|
||||
|
||||
#include <stdex/idrec.h>
|
||||
|
||||
#include <WinStd/Common.h>
|
||||
|
||||
#include <initguid.h> // GUID helper to prevent LNK2001 errors (unresolved external symbol IID_IADO...)
|
||||
#include <adoint.h>
|
||||
#include <adoid.h>
|
||||
#include <atlcomcli.h>
|
||||
|
||||
#include <process.h>
|
||||
#include <tchar.h>
|
||||
|
||||
#include <stdlib.h>
|
||||
@@ -52,4 +53,6 @@
|
||||
#include <codecvt>
|
||||
#include <cwctype>
|
||||
#include <fstream>
|
||||
#include <memory>
|
||||
#include <set>
|
||||
#include <vector>
|
||||
|
||||
@@ -7,12 +7,12 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libZRCola", "lib\libZRCola\
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{ECE3F336-FFD2-41EE-AD8F-17BD7472BDCB}"
|
||||
ProjectSection(SolutionItems) = preProject
|
||||
include\zrcola.h = include\zrcola.h
|
||||
include\version.h = include\version.h
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ZRColaCompile", "ZRColaCompile\ZRColaCompile.vcxproj", "{87A3ADEC-1BE4-42E4-92B8-B742F3D21BC4}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "wxExtend", "lib\wxExtend\build\wxExtend.vcxproj", "{A3A36689-AC35-4026-93DA-A3BA0C0E767C}"
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "wxExtend", "lib\wxExtend\build\wxExtendDll.vcxproj", "{A3A36689-AC35-4026-93DA-A3BA0C0E767C}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "stdex", "lib\stdex\build\stdex.vcxproj", "{518777CC-0A59-4415-A12A-82751ED75343}"
|
||||
EndProject
|
||||
@@ -28,6 +28,8 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ZRColaInstallEn", "ZRColaIn
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ZRColaInstallRu", "ZRColaInstall\ZRColaInstallRu.vcxproj", "{2551B561-5E5B-497E-AE01-11519F91EF19}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "WinStd", "lib\WinStd\build\WinStd.vcxproj", "{47399D91-7EB9-41DE-B521-514BA5DB0C43}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Win32 = Debug|Win32
|
||||
@@ -98,6 +100,14 @@ Global
|
||||
{2551B561-5E5B-497E-AE01-11519F91EF19}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{2551B561-5E5B-497E-AE01-11519F91EF19}.Release|Win32.Build.0 = Release|Win32
|
||||
{2551B561-5E5B-497E-AE01-11519F91EF19}.Release|x64.ActiveCfg = Release|Win32
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Debug|x64.Build.0 = Debug|x64
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Release|Win32.Build.0 = Release|Win32
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Release|x64.ActiveCfg = Release|x64
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43}.Release|x64.Build.0 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
@@ -107,6 +117,7 @@ Global
|
||||
{A3A36689-AC35-4026-93DA-A3BA0C0E767C} = {A7D28E0C-BB96-444D-AAB0-F22A6483FE5F}
|
||||
{518777CC-0A59-4415-A12A-82751ED75343} = {A7D28E0C-BB96-444D-AAB0-F22A6483FE5F}
|
||||
{C0A84BD2-3870-4CD6-B281-0AB322E3C579} = {A7D28E0C-BB96-444D-AAB0-F22A6483FE5F}
|
||||
{47399D91-7EB9-41DE-B521-514BA5DB0C43} = {A7D28E0C-BB96-444D-AAB0-F22A6483FE5F}
|
||||
{0C2C89C2-C96B-41B6-AA99-7E7741E20F3A} = {7F5D45A3-B3D2-4B1D-B258-9B83395786E6}
|
||||
{620D6AC0-C8FF-4185-B820-DB1503ACB95C} = {7F5D45A3-B3D2-4B1D-B258-9B83395786E6}
|
||||
{5BD95B95-38B0-4C7D-9471-F99CA1203DF4} = {7F5D45A3-B3D2-4B1D-B258-9B83395786E6}
|
||||
|
||||
3541
bin/ZRCUpdate.wsf
@@ -1,4 +1,4 @@
|
||||
#include "zrcola.h"
|
||||
#include "version.h"
|
||||
|
||||
//
|
||||
// Update server(s)
|
||||
@@ -15,22 +15,3 @@
|
||||
// Update server catalog location
|
||||
//
|
||||
#define UPDATER_HTTP_PATH "/prenos/ZRCola/catalog-0000.xml"
|
||||
|
||||
|
||||
//
|
||||
// The product vendor and application name for configuration keeping.
|
||||
//
|
||||
#define UPDATER_CFG_VENDOR "Amebis"
|
||||
#define UPDATER_CFG_APPLICATION "ZRCola"
|
||||
|
||||
|
||||
//
|
||||
// Product version as a single DWORD
|
||||
// Note: Used for version comparison within C/C++ code.
|
||||
//
|
||||
#define UPDATER_PRODUCT_VERSION ZRCOLA_VERSION
|
||||
|
||||
//
|
||||
// Human readable product version and build year for UI
|
||||
//
|
||||
#define UPDATER_PRODUCT_VERSION_STR ZRCOLA_VERSION_STR
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup>
|
||||
<_PropertySheetDisplayName>ZRCola Win32</_PropertySheetDisplayName>
|
||||
<LibraryPath>$(WX_INSTALL_PATH)\lib\vc$(PlatformToolsetVersion)_dll;$(LibraryPath)</LibraryPath>
|
||||
<LibraryPath>$(WXWIN)\lib\vc$(PlatformToolsetVersion)_dll;$(LibraryPath)</LibraryPath>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup>
|
||||
<Lib>
|
||||
|
||||
@@ -21,13 +21,15 @@
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
<Import Project="xgettext.props" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Label="UserMacros">
|
||||
<UpdaterVersion>ZRCola</UpdaterVersion>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<IntDir>temp\$(ProjectName).$(Platform).$(Configuration).$(PlatformToolset)\</IntDir>
|
||||
<_PropertySheetDisplayName>ZRCola Common</_PropertySheetDisplayName>
|
||||
<OutDir>temp\$(ProjectName).$(Platform).$(Configuration).$(PlatformToolset)\</OutDir>
|
||||
<IncludePath>$(WX_INSTALL_PATH)\include\msvc;$(WX_INSTALL_PATH)\include;$(IncludePath)</IncludePath>
|
||||
<SourcePath>$(WX_INSTALL_PATH)\src\aui;$(WX_INSTALL_PATH)\src\cocoa;$(WX_INSTALL_PATH)\src\common;$(WX_INSTALL_PATH)\src\dfb;$(WX_INSTALL_PATH)\src\expat;$(WX_INSTALL_PATH)\src\generic;$(WX_INSTALL_PATH)\src\gtk;$(WX_INSTALL_PATH)\src\gtk1;$(WX_INSTALL_PATH)\src\html;$(WX_INSTALL_PATH)\src\jpeg;$(WX_INSTALL_PATH)\src\motif;$(WX_INSTALL_PATH)\src\msdos;$(WX_INSTALL_PATH)\src\msw;$(WX_INSTALL_PATH)\src\os2;$(WX_INSTALL_PATH)\src\osx;$(WX_INSTALL_PATH)\src\png;$(WX_INSTALL_PATH)\src\propgrid;$(WX_INSTALL_PATH)\src\regex;$(WX_INSTALL_PATH)\src\ribbon;$(WX_INSTALL_PATH)\src\richtext;$(WX_INSTALL_PATH)\src\stc;$(WX_INSTALL_PATH)\src\tiff;$(WX_INSTALL_PATH)\src\univ;$(WX_INSTALL_PATH)\src\unix;$(WX_INSTALL_PATH)\src\x11;$(WX_INSTALL_PATH)\src\xml;$(WX_INSTALL_PATH)\src\xrc;$(WX_INSTALL_PATH)\src\zlib;$(SourcePath)</SourcePath>
|
||||
<IntDir>temp\$(MSBuildProjectName).$(Platform).$(Configuration).$(PlatformToolset)\</IntDir>
|
||||
<OutDir>temp\$(MSBuildProjectName).$(Platform).$(Configuration).$(PlatformToolset)\</OutDir>
|
||||
<IncludePath>$(WXWIN)\include\msvc;$(WXWIN)\include;$(IncludePath)</IncludePath>
|
||||
<SourcePath>$(WXWIN)\src\aui;$(WXWIN)\src\cocoa;$(WXWIN)\src\common;$(WXWIN)\src\dfb;$(WXWIN)\src\expat;$(WXWIN)\src\generic;$(WXWIN)\src\gtk;$(WXWIN)\src\gtk1;$(WXWIN)\src\html;$(WXWIN)\src\jpeg;$(WXWIN)\src\motif;$(WXWIN)\src\msdos;$(WXWIN)\src\msw;$(WXWIN)\src\os2;$(WXWIN)\src\osx;$(WXWIN)\src\png;$(WXWIN)\src\propgrid;$(WXWIN)\src\regex;$(WXWIN)\src\ribbon;$(WXWIN)\src\richtext;$(WXWIN)\src\stc;$(WXWIN)\src\tiff;$(WXWIN)\src\univ;$(WXWIN)\src\unix;$(WXWIN)\src\x11;$(WXWIN)\src\xml;$(WXWIN)\src\xrc;$(WXWIN)\src\zlib;$(SourcePath)</SourcePath>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup>
|
||||
<ClCompile>
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
// Product version as a single DWORD
|
||||
// Note: Used for version comparison within C/C++ code.
|
||||
//
|
||||
#define ZRCOLA_VERSION 0x01ff0900
|
||||
#define PRODUCT_VERSION 0x02000000
|
||||
|
||||
//
|
||||
// Product version by components
|
||||
@@ -31,31 +31,31 @@
|
||||
// thus we need to specify major, minor and other version components
|
||||
// separately.
|
||||
//
|
||||
#define ZRCOLA_VERSION_MAJ 1
|
||||
#define ZRCOLA_VERSION_MIN 255
|
||||
#define ZRCOLA_VERSION_REV 9
|
||||
#define ZRCOLA_VERSION_BUILD 0
|
||||
#define PRODUCT_VERSION_MAJ 2
|
||||
#define PRODUCT_VERSION_MIN 0
|
||||
#define PRODUCT_VERSION_REV 0
|
||||
#define PRODUCT_VERSION_BUILD 0
|
||||
|
||||
//
|
||||
// Human readable product version and build year for UI
|
||||
//
|
||||
#define ZRCOLA_VERSION_STR "2.0-beta1"
|
||||
#define ZRCOLA_BUILD_YEAR_STR "2016"
|
||||
#define PRODUCT_VERSION_STR "2.0"
|
||||
#define PRODUCT_BUILD_YEAR_STR "2016"
|
||||
|
||||
//
|
||||
// Numerical version presentation for ProductVersion propery in
|
||||
// MSI packages (syntax: N.N[.N[.N]])
|
||||
//
|
||||
#define ZRCOLA_VERSION_INST "1.255.9"
|
||||
#define PRODUCT_VERSION_INST "2.0"
|
||||
|
||||
//
|
||||
// The product code for ProductCode property in MSI packages
|
||||
// Replace with new on every version change, regardless how minor it is.
|
||||
//
|
||||
#define ZRCOLA_VERSION_GUID "{F696F7A3-0639-467E-9A94-4B7E4CF28E44}"
|
||||
#define PRODUCT_VERSION_GUID "{59833018-A0F9-4C90-B4F3-8B88908BB89A}"
|
||||
|
||||
//
|
||||
// The product vendor and application name for configuration keeping.
|
||||
//
|
||||
#define ZRCOLA_CFG_VENDOR "Amebis"
|
||||
#define ZRCOLA_CFG_APPLICATION "ZRCola"
|
||||
#define PRODUCT_CFG_VENDOR "Amebis"
|
||||
#define PRODUCT_CFG_APPLICATION "ZRCola"
|
||||
@@ -24,7 +24,7 @@
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup>
|
||||
<_PropertySheetDisplayName>ZRCola x64</_PropertySheetDisplayName>
|
||||
<LibraryPath>$(WX_INSTALL_PATH)\lib\vc$(PlatformToolsetVersion)_x64_dll;$(LibraryPath)</LibraryPath>
|
||||
<LibraryPath>$(WXWIN)\lib\vc$(PlatformToolsetVersion)_x64_dll;$(LibraryPath)</LibraryPath>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup>
|
||||
<Lib>
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
<ItemGroup Condition="'@(SelectedFiles)' != ''">
|
||||
<POCompile Remove="@(POCompile)" Condition="'%(Identity)' != '@(SelectedFiles)'" />
|
||||
</ItemGroup>
|
||||
<Message Text="Compiling localization catalogues..." />
|
||||
<MakeDir Directories="$([System.IO.Path]::GetDirectoryName('%(POCompile.OutputFile)'))"/>
|
||||
<POCompile
|
||||
Condition="'@(POCompile)' != '' and '%(POCompile.ExcludedFromBuild)' != 'true'"
|
||||
Inputs="@(POCompile)"
|
||||
|
||||
1
lib/WinStd
Submodule
@@ -20,6 +20,7 @@
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="..\src\character.cpp" />
|
||||
<ClCompile Include="..\src\common.cpp" />
|
||||
<ClCompile Include="..\src\language.cpp" />
|
||||
<ClCompile Include="..\src\mapping.cpp" />
|
||||
<ClCompile Include="..\src\normalize.cpp" />
|
||||
@@ -29,6 +30,7 @@
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\src\tag.cpp" />
|
||||
<ClCompile Include="..\src\translate.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
@@ -36,6 +38,7 @@
|
||||
<ClInclude Include="..\include\zrcola\common.h" />
|
||||
<ClInclude Include="..\include\zrcola\language.h" />
|
||||
<ClInclude Include="..\include\zrcola\normalize.h" />
|
||||
<ClInclude Include="..\include\zrcola\tag.h" />
|
||||
<ClInclude Include="..\include\zrcola\translate.h" />
|
||||
<ClInclude Include="..\src\stdafx.h" />
|
||||
</ItemGroup>
|
||||
|
||||
@@ -33,6 +33,12 @@
|
||||
<ClCompile Include="..\src\character.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\src\common.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\src\tag.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\src\stdafx.h">
|
||||
@@ -53,6 +59,9 @@
|
||||
<ClInclude Include="..\include\zrcola\character.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\include\zrcola\tag.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="..\res\libZRCola.rc">
|
||||
|
||||
@@ -36,11 +36,16 @@
|
||||
|
||||
|
||||
namespace ZRCola {
|
||||
///
|
||||
/// Character rank type
|
||||
///
|
||||
typedef double charrank_t;
|
||||
|
||||
///
|
||||
/// Character category ID type
|
||||
/// Two letter abbreviation, non-terminated
|
||||
///
|
||||
struct chrcatid_t {
|
||||
struct ZRCOLA_API chrcatid_t {
|
||||
char data[2];
|
||||
|
||||
inline chrcatid_t& operator=(const chrcatid_t &src)
|
||||
@@ -55,15 +60,14 @@ namespace ZRCola {
|
||||
data[1] = (data[0] = src[0]) != 0 ? src[1] : 0;
|
||||
return *this;
|
||||
}
|
||||
|
||||
///
|
||||
/// Blank character category
|
||||
///
|
||||
static const chrcatid_t blank;
|
||||
};
|
||||
|
||||
|
||||
///
|
||||
/// Blank character category
|
||||
///
|
||||
const chrcatid_t chrcatid_t_blank = {};
|
||||
|
||||
|
||||
///
|
||||
/// Compares two character category IDs
|
||||
///
|
||||
@@ -227,6 +231,17 @@ namespace ZRCola {
|
||||
///
|
||||
inline character_db() : idxChr(data) {}
|
||||
|
||||
///
|
||||
/// Clears the database
|
||||
///
|
||||
inline void clear()
|
||||
{
|
||||
idxChr .clear();
|
||||
idxDsc .clear();
|
||||
idxDscSub.clear();
|
||||
data .clear();
|
||||
}
|
||||
|
||||
///
|
||||
/// Search for characters by description in given categories
|
||||
///
|
||||
@@ -234,10 +249,10 @@ namespace ZRCola {
|
||||
/// \param[in ] cats Set of categories, character must be a part of
|
||||
/// \param[inout] hits (character, count) map to append full-word hits to
|
||||
/// \param[inout] hits_sub (character, count) map to append partial-word hits to
|
||||
/// \param[in] fn_abort Pointer to function to periodically test for search cancellation
|
||||
/// \param[in] cookie Cookie for \p fn_abort call
|
||||
/// \param[in ] fn_abort Pointer to function to periodically test for search cancellation
|
||||
/// \param[in ] cookie Cookie for \p fn_abort call
|
||||
///
|
||||
bool Search(_In_z_ const wchar_t *str, _In_ const std::set<chrcatid_t> &cats, _Inout_ std::map<wchar_t, unsigned long> &hits, _Inout_ std::map<wchar_t, unsigned long> &hits_sub, _In_opt_ bool (__cdecl *fn_abort)(void *cookie) = NULL, _In_opt_ void *cookie = NULL) const;
|
||||
bool Search(_In_z_ const wchar_t *str, _In_ const std::set<chrcatid_t> &cats, _Inout_ std::map<wchar_t, charrank_t> &hits, _Inout_ std::map<wchar_t, charrank_t> &hits_sub, _In_opt_ bool (__cdecl *fn_abort)(void *cookie) = NULL, _In_opt_ void *cookie = NULL) const;
|
||||
|
||||
///
|
||||
/// Get character category
|
||||
@@ -246,14 +261,14 @@ namespace ZRCola {
|
||||
///
|
||||
/// \returns
|
||||
/// - Character category if character found
|
||||
/// - `ZRCola::chrcatid_t_blank` otherwise
|
||||
/// - `ZRCola::chrcatid_t::blank` otherwise
|
||||
///
|
||||
inline chrcatid_t GetCharCat(wchar_t c) const
|
||||
{
|
||||
char _chr[sizeof(character)];
|
||||
((character *)_chr)->chr = c;
|
||||
indexChar::size_type start;
|
||||
return idxChr.find(*((character *)_chr), start) ? idxChr[start].cat : chrcatid_t_blank;
|
||||
return idxChr.find(*((character *)_chr), start) ? idxChr[start].cat : chrcatid_t::blank;
|
||||
}
|
||||
};
|
||||
|
||||
@@ -375,6 +390,16 @@ namespace ZRCola {
|
||||
/// Constructs the database
|
||||
///
|
||||
inline chrcat_db() : idxChrCat(data), idxRnk(data) {}
|
||||
|
||||
///
|
||||
/// Clears the database
|
||||
///
|
||||
inline void clear()
|
||||
{
|
||||
idxChrCat.clear();
|
||||
idxRnk .clear();
|
||||
data .clear();
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -447,7 +472,7 @@ inline std::ostream& operator <<(_In_ std::ostream& stream, _In_ const ZRCola::c
|
||||
stream << db.idxDscSub;
|
||||
|
||||
// Write data count.
|
||||
std::vector<unsigned __int16>::size_type data_count = db.data.size();
|
||||
auto data_count = db.data.size();
|
||||
#if defined(_WIN64) || defined(__x86_64__) || defined(__ppc64__)
|
||||
// 4G check
|
||||
if (data_count > 0xffffffff) {
|
||||
@@ -486,7 +511,7 @@ inline std::ostream& operator <<(_In_ std::ostream& stream, _In_ const ZRCola::c
|
||||
stream << db.idxRnk;
|
||||
|
||||
// Write data count.
|
||||
std::vector<unsigned __int16>::size_type data_count = db.data.size();
|
||||
auto data_count = db.data.size();
|
||||
#if defined(_WIN64) || defined(__x86_64__) || defined(__ppc64__)
|
||||
// 4G check
|
||||
if (data_count > 0xffffffff) {
|
||||
|
||||
@@ -76,7 +76,7 @@ namespace ZRCola {
|
||||
/// Language ID type
|
||||
/// Three letter abbreviation, zero terminated
|
||||
///
|
||||
struct langid_t {
|
||||
struct ZRCOLA_API langid_t {
|
||||
char data[4];
|
||||
|
||||
inline langid_t& operator=(const langid_t &src)
|
||||
@@ -99,15 +99,14 @@ namespace ZRCola {
|
||||
src[3] : 0;
|
||||
return *this;
|
||||
}
|
||||
|
||||
///
|
||||
/// Blank language ID
|
||||
///
|
||||
static const langid_t blank;
|
||||
};
|
||||
|
||||
|
||||
///
|
||||
/// Blank language ID
|
||||
///
|
||||
const langid_t langid_t_blank = {};
|
||||
|
||||
|
||||
///
|
||||
/// Compares two language IDs
|
||||
///
|
||||
@@ -440,6 +439,17 @@ namespace ZRCola {
|
||||
textindex() {}
|
||||
|
||||
|
||||
///
|
||||
/// Clears the index
|
||||
///
|
||||
inline void clear()
|
||||
{
|
||||
std::vector< mappair_t<T_idx> >::clear();
|
||||
keys .clear();
|
||||
values.clear();
|
||||
}
|
||||
|
||||
|
||||
///
|
||||
/// Finds data for given key
|
||||
///
|
||||
@@ -557,7 +567,7 @@ template <class T, class T_idx, class T_data>
|
||||
inline std::ostream& operator <<(_In_ std::ostream& stream, _In_ const ZRCola::index<T, T_idx, T_data> &idx)
|
||||
{
|
||||
// Write index count.
|
||||
ZRCola::index<T, T_idx, T_data>::size_type idx_count = idx.size();
|
||||
auto idx_count = idx.size();
|
||||
#if defined(_WIN64) || defined(__x86_64__) || defined(__ppc64__)
|
||||
// 4G check
|
||||
if (idx_count > 0xffffffff) {
|
||||
@@ -619,7 +629,7 @@ inline std::ostream& operator <<(_In_ std::ostream& stream, _In_ const ZRCola::t
|
||||
unsigned __int32 count;
|
||||
|
||||
// Write index count.
|
||||
ZRCola::textindex<T_key, T_val, T_idx>::size_type idx_count = idx.size();
|
||||
auto idx_count = idx.size();
|
||||
#if defined(_WIN64) || defined(__x86_64__) || defined(__ppc64__)
|
||||
// 4G check
|
||||
if (idx_count > 0xffffffff) {
|
||||
@@ -636,7 +646,7 @@ inline std::ostream& operator <<(_In_ std::ostream& stream, _In_ const ZRCola::t
|
||||
stream.write((const char*)idx.data(), sizeof(ZRCola::textindex<T_key, T_val, T_idx>::value_type)*count);
|
||||
|
||||
// Write key count.
|
||||
std::vector<T_key>::size_type key_count = idx.keys.size();
|
||||
auto key_count = idx.keys.size();
|
||||
#if defined(_WIN64) || defined(__x86_64__) || defined(__ppc64__)
|
||||
// 4G check
|
||||
if (idx_count > 0xffffffff) {
|
||||
@@ -653,7 +663,7 @@ inline std::ostream& operator <<(_In_ std::ostream& stream, _In_ const ZRCola::t
|
||||
stream.write((const char*)idx.keys.data(), sizeof(std::vector<T_key>::value_type)*count);
|
||||
|
||||
// Write value count.
|
||||
std::vector<T_val>::size_type value_count = idx.values.size();
|
||||
auto value_count = idx.values.size();
|
||||
#if defined(_WIN64) || defined(__x86_64__) || defined(__ppc64__)
|
||||
// 4G check
|
||||
if (idx_count > 0xffffffff) {
|
||||
|
||||
@@ -175,6 +175,18 @@ namespace ZRCola {
|
||||
#endif
|
||||
{}
|
||||
|
||||
///
|
||||
/// Clears the database
|
||||
///
|
||||
inline void clear()
|
||||
{
|
||||
idxChr.clear();
|
||||
#ifdef ZRCOLA_LANGCHAR_LANG_IDX
|
||||
idxLng.clear();
|
||||
#endif
|
||||
data .clear();
|
||||
}
|
||||
|
||||
///
|
||||
/// Tests presence of character in the given language
|
||||
///
|
||||
@@ -248,6 +260,15 @@ namespace ZRCola {
|
||||
/// Constructs the database
|
||||
///
|
||||
inline language_db() : idxLng(data) {}
|
||||
|
||||
///
|
||||
/// Clears the database
|
||||
///
|
||||
inline void clear()
|
||||
{
|
||||
idxLng.clear();
|
||||
data .clear();
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -280,7 +301,7 @@ inline std::ostream& operator <<(_In_ std::ostream& stream, _In_ const ZRCola::l
|
||||
#endif
|
||||
|
||||
// Write data count.
|
||||
std::vector<unsigned __int16>::size_type data_count = db.data.size();
|
||||
auto data_count = db.data.size();
|
||||
#if defined(_WIN64) || defined(__x86_64__) || defined(__ppc64__)
|
||||
// 4G check
|
||||
if (data_count > 0xffffffff) {
|
||||
@@ -351,7 +372,7 @@ inline std::ostream& operator <<(_In_ std::ostream& stream, _In_ const ZRCola::l
|
||||
stream << db.idxLng;
|
||||
|
||||
// Write data count.
|
||||
std::vector<unsigned __int16>::size_type data_count = db.data.size();
|
||||
auto data_count = db.data.size();
|
||||
#if defined(_WIN64) || defined(__x86_64__) || defined(__ppc64__)
|
||||
// 4G check
|
||||
if (data_count > 0xffffffff) {
|
||||
|
||||
530
lib/libZRCola/include/zrcola/tag.h
Normal file
@@ -0,0 +1,530 @@
|
||||
/*
|
||||
Copyright 2015-2016 Amebis
|
||||
|
||||
This file is part of ZRCola.
|
||||
|
||||
ZRCola 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 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
ZRCola 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 ZRCola. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "common.h"
|
||||
|
||||
#include <stdex/idrec.h>
|
||||
#include <istream>
|
||||
#include <ostream>
|
||||
#include <vector>
|
||||
#include <string>
|
||||
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable: 4200)
|
||||
#pragma warning(disable: 4251)
|
||||
#pragma warning(disable: 4512)
|
||||
|
||||
|
||||
namespace ZRCola {
|
||||
typedef unsigned __int16 tagid_t;
|
||||
|
||||
///
|
||||
/// Character Tag Database
|
||||
///
|
||||
class ZRCOLA_API chrtag_db {
|
||||
public:
|
||||
#pragma pack(push)
|
||||
#pragma pack(2)
|
||||
///
|
||||
/// Character tag data
|
||||
///
|
||||
struct chrtag {
|
||||
wchar_t chr; ///> Character
|
||||
tagid_t tag; ///< Tag ID
|
||||
};
|
||||
#pragma pack(pop)
|
||||
|
||||
///
|
||||
/// Character Index
|
||||
///
|
||||
class indexChar : public index<unsigned __int16, unsigned __int32, chrtag>
|
||||
{
|
||||
public:
|
||||
///
|
||||
/// Constructs the index
|
||||
///
|
||||
/// \param[in] h Reference to vector holding the data
|
||||
///
|
||||
indexChar(_In_ std::vector<unsigned __int16> &h) : index<unsigned __int16, unsigned __int32, chrtag>(h) {}
|
||||
|
||||
///
|
||||
/// Compares two character tags by character (for searching)
|
||||
///
|
||||
/// \param[in] a Pointer to first element
|
||||
/// \param[in] b Pointer to second element
|
||||
///
|
||||
/// \returns
|
||||
/// - <0 when a < b
|
||||
/// - =0 when a == b
|
||||
/// - >0 when a > b
|
||||
///
|
||||
virtual int compare(_In_ const chrtag &a, _In_ const chrtag &b) const
|
||||
{
|
||||
if (a.chr < b.chr) return -1;
|
||||
else if (a.chr > b.chr) return 1;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
///
|
||||
/// Compares two character tags by character (for sorting)
|
||||
///
|
||||
/// \param[in] a Pointer to first element
|
||||
/// \param[in] b Pointer to second element
|
||||
///
|
||||
/// \returns
|
||||
/// - <0 when a < b
|
||||
/// - =0 when a == b
|
||||
/// - >0 when a > b
|
||||
///
|
||||
virtual int compare_sort(_In_ const chrtag &a, _In_ const chrtag &b) const
|
||||
{
|
||||
if (a.chr < b.chr) return -1;
|
||||
else if (a.chr > b.chr) return 1;
|
||||
|
||||
if (a.tag < b.tag) return -1;
|
||||
else if (a.tag > b.tag) return 1;
|
||||
|
||||
return 0;
|
||||
}
|
||||
} idxChr; ///< Character index
|
||||
|
||||
|
||||
///
|
||||
/// Tag Index
|
||||
///
|
||||
class indexTag : public index<unsigned __int16, unsigned __int32, chrtag>
|
||||
{
|
||||
public:
|
||||
///
|
||||
/// Constructs the index
|
||||
///
|
||||
/// \param[in] h Reference to vector holding the data
|
||||
///
|
||||
indexTag(_In_ std::vector<unsigned __int16> &h) : index<unsigned __int16, unsigned __int32, chrtag>(h) {}
|
||||
|
||||
///
|
||||
/// Compares two character tags by tag (for searching)
|
||||
///
|
||||
/// \param[in] a Pointer to first element
|
||||
/// \param[in] b Pointer to second element
|
||||
///
|
||||
/// \returns
|
||||
/// - <0 when a < b
|
||||
/// - =0 when a == b
|
||||
/// - >0 when a > b
|
||||
///
|
||||
virtual int compare(_In_ const chrtag &a, _In_ const chrtag &b) const
|
||||
{
|
||||
if (a.tag < b.tag) return -1;
|
||||
else if (a.tag > b.tag) return 1;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
///
|
||||
/// Compares two character tags by tag (for sorting)
|
||||
///
|
||||
/// \param[in] a Pointer to first element
|
||||
/// \param[in] b Pointer to second element
|
||||
///
|
||||
/// \returns
|
||||
/// - <0 when a < b
|
||||
/// - =0 when a == b
|
||||
/// - >0 when a > b
|
||||
///
|
||||
virtual int compare_sort(_In_ const chrtag &a, _In_ const chrtag &b) const
|
||||
{
|
||||
if (a.tag < b.tag) return -1;
|
||||
else if (a.tag > b.tag) return 1;
|
||||
|
||||
if (a.chr < b.chr) return -1;
|
||||
else if (a.chr > b.chr) return 1;
|
||||
|
||||
return 0;
|
||||
}
|
||||
} idxTag; ///< Tag index
|
||||
|
||||
std::vector<unsigned __int16> data; ///< Character tags data
|
||||
|
||||
public:
|
||||
///
|
||||
/// Constructs the database
|
||||
///
|
||||
inline chrtag_db() : idxChr(data), idxTag(data) {}
|
||||
|
||||
///
|
||||
/// Clears the database
|
||||
///
|
||||
inline void clear()
|
||||
{
|
||||
idxChr.clear();
|
||||
idxTag.clear();
|
||||
data .clear();
|
||||
}
|
||||
|
||||
///
|
||||
/// Search for characters by tags
|
||||
///
|
||||
/// \param[in ] tags Search tags
|
||||
/// \param[in ] ch_db Character database
|
||||
/// \param[in ] cats Set of categories from \p ch_db, character must be a part of
|
||||
/// \param[inout] hits (character, count) map to append hits to
|
||||
/// \param[in ] fn_abort Pointer to function to periodically test for search cancellation
|
||||
/// \param[in ] cookie Cookie for \p fn_abort call
|
||||
///
|
||||
bool Search(_In_ const std::map<tagid_t, unsigned __int16> &tags, _In_ const character_db &ch_db, _In_ const std::set<chrcatid_t> &cats, _Inout_ std::map<wchar_t, charrank_t> &hits, _In_opt_ bool (__cdecl *fn_abort)(void *cookie) = NULL, _In_opt_ void *cookie = NULL) const;
|
||||
};
|
||||
|
||||
|
||||
typedef ZRCOLA_API stdex::idrec::record<chrtag_db, recordid_t, recordsize_t, ZRCOLA_RECORD_ALIGN> chrtag_rec;
|
||||
|
||||
|
||||
///
|
||||
/// Tag name database
|
||||
///
|
||||
class ZRCOLA_API tagname_db {
|
||||
public:
|
||||
#pragma pack(push)
|
||||
#pragma pack(2)
|
||||
///
|
||||
/// Tag name data
|
||||
///
|
||||
struct tagname {
|
||||
tagid_t tag; ///< Tag ID
|
||||
LCID locale; ///< Locale ID
|
||||
unsigned __int16 name_len; ///< \c name length (in characters)
|
||||
wchar_t name[]; ///< Tag localized name
|
||||
|
||||
///
|
||||
/// Compares two names
|
||||
///
|
||||
/// \param[in] locale Locale ID to use for compare
|
||||
/// \param[in] str_a First name
|
||||
/// \param[in] count_a Number of characters in string \p str_a
|
||||
/// \param[in] str_b Second name
|
||||
/// \param[in] count_b Number of characters in string \p str_b
|
||||
///
|
||||
/// \returns
|
||||
/// - <0 when str_a < str_b
|
||||
/// - =0 when str_a == str_b
|
||||
/// - >0 when str_a > str_b
|
||||
///
|
||||
/// \note
|
||||
/// The function does not treat \\0 characters as terminators for performance reasons.
|
||||
/// Therefore \p count_a and \p count_b must represent exact string lengths.
|
||||
///
|
||||
static inline int CompareName(LCID locale, const wchar_t *str_a, unsigned __int16 count_a, const wchar_t *str_b, unsigned __int16 count_b)
|
||||
{
|
||||
switch (CompareString(locale, SORT_STRINGSORT | NORM_IGNORECASE, str_a, count_a, str_b, count_b)) {
|
||||
case CSTR_LESS_THAN : return -1;
|
||||
case CSTR_EQUAL : return 0;
|
||||
case CSTR_GREATER_THAN: return 1;
|
||||
default : assert(0); return -1;
|
||||
}
|
||||
}
|
||||
};
|
||||
#pragma pack(pop)
|
||||
|
||||
///
|
||||
/// Name index
|
||||
///
|
||||
class indexName : public index<unsigned __int16, unsigned __int32, tagname>
|
||||
{
|
||||
public:
|
||||
///
|
||||
/// Constructs the index
|
||||
///
|
||||
/// \param[in] h Reference to vector holding the data
|
||||
/// \param[in] locale Locale used to perform tag name comparison
|
||||
///
|
||||
indexName(_In_ std::vector<unsigned __int16> &h) : index<unsigned __int16, unsigned __int32, tagname>(h) {}
|
||||
|
||||
///
|
||||
/// Compares two tag names by name (for searching)
|
||||
///
|
||||
/// \param[in] a Pointer to first element
|
||||
/// \param[in] b Pointer to second element
|
||||
///
|
||||
/// \returns
|
||||
/// - <0 when a < b
|
||||
/// - =0 when a == b
|
||||
/// - >0 when a > b
|
||||
///
|
||||
virtual int compare(_In_ const tagname &a, _In_ const tagname &b) const
|
||||
{
|
||||
if (a.locale < b.locale) return -1;
|
||||
else if (a.locale > b.locale) return 1;
|
||||
|
||||
int r = tagname::CompareName(a.locale, a.name, a.name_len, b.name, b.name_len);
|
||||
if (r != 0) return r;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
///
|
||||
/// Compares two tag names by name (for sorting)
|
||||
///
|
||||
/// \param[in] a Pointer to first element
|
||||
/// \param[in] b Pointer to second element
|
||||
///
|
||||
/// \returns
|
||||
/// - <0 when a < b
|
||||
/// - =0 when a == b
|
||||
/// - >0 when a > b
|
||||
///
|
||||
virtual int compare_sort(_In_ const tagname &a, _In_ const tagname &b) const
|
||||
{
|
||||
if (a.locale < b.locale) return -1;
|
||||
else if (a.locale > b.locale) return 1;
|
||||
|
||||
int r = tagname::CompareName(a.locale, a.name, a.name_len, b.name, b.name_len);
|
||||
if (r != 0) return r;
|
||||
|
||||
if (a.tag < b.tag) return -1;
|
||||
else if (a.tag > b.tag) return 1;
|
||||
|
||||
return 0;
|
||||
}
|
||||
} idxName; ///< Name index
|
||||
|
||||
///
|
||||
/// Tag index
|
||||
///
|
||||
class indexTag : public index<unsigned __int16, unsigned __int32, tagname>
|
||||
{
|
||||
public:
|
||||
///
|
||||
/// Constructs the index
|
||||
///
|
||||
/// \param[in] h Reference to vector holding the data
|
||||
/// \param[in] locale Locale used to perform tag name comparison
|
||||
///
|
||||
indexTag(_In_ std::vector<unsigned __int16> &h) : index<unsigned __int16, unsigned __int32, tagname>(h) {}
|
||||
|
||||
///
|
||||
/// Compares two tag names by tag (for searching)
|
||||
///
|
||||
/// \param[in] a Pointer to first element
|
||||
/// \param[in] b Pointer to second element
|
||||
///
|
||||
/// \returns
|
||||
/// - <0 when a < b
|
||||
/// - =0 when a == b
|
||||
/// - >0 when a > b
|
||||
///
|
||||
virtual int compare(_In_ const tagname &a, _In_ const tagname &b) const
|
||||
{
|
||||
if (a.locale < b.locale) return -1;
|
||||
else if (a.locale > b.locale) return 1;
|
||||
|
||||
if (a.tag < b.tag) return -1;
|
||||
else if (a.tag > b.tag) return 1;
|
||||
|
||||
return 0;
|
||||
}
|
||||
} idxTag; ///< Tag index
|
||||
|
||||
std::vector<unsigned __int16> data; ///< Tag data
|
||||
|
||||
public:
|
||||
///
|
||||
/// Constructs the database
|
||||
///
|
||||
inline tagname_db() : idxName(data), idxTag(data) {}
|
||||
|
||||
///
|
||||
/// Clears the database
|
||||
///
|
||||
inline void clear()
|
||||
{
|
||||
idxName.clear();
|
||||
idxTag .clear();
|
||||
data .clear();
|
||||
}
|
||||
|
||||
///
|
||||
/// Search for tags by names
|
||||
///
|
||||
/// \param[in ] str Search string
|
||||
/// \param[in ] locale Locale to search tags in
|
||||
/// \param[inout] hits (tag, count) map to append hits to
|
||||
/// \param[in ] fn_abort Pointer to function to periodically test for search cancellation
|
||||
/// \param[in ] cookie Cookie for \p fn_abort call
|
||||
///
|
||||
bool Search(_In_z_ const wchar_t *str, _In_ LCID locale, _Inout_ std::map<tagid_t, unsigned __int16> &hits, _In_opt_ bool (__cdecl *fn_abort)(void *cookie) = NULL, _In_opt_ void *cookie = NULL) const;
|
||||
};
|
||||
|
||||
|
||||
typedef ZRCOLA_API stdex::idrec::record<tagname_db, recordid_t, recordsize_t, ZRCOLA_RECORD_ALIGN> tagname_rec;
|
||||
};
|
||||
|
||||
|
||||
const ZRCola::recordid_t stdex::idrec::record<ZRCola::chrtag_db, ZRCola::recordid_t, ZRCola::recordsize_t, ZRCOLA_RECORD_ALIGN>::id = *(ZRCola::recordid_t*)"C-T";
|
||||
const ZRCola::recordid_t stdex::idrec::record<ZRCola::tagname_db, ZRCola::recordid_t, ZRCola::recordsize_t, ZRCOLA_RECORD_ALIGN>::id = *(ZRCola::recordid_t*)"TGN";
|
||||
|
||||
|
||||
///
|
||||
/// Writes character tag database to a stream
|
||||
///
|
||||
/// \param[in] stream Output stream
|
||||
/// \param[in] db Character tag database
|
||||
///
|
||||
/// \returns The stream \p stream
|
||||
///
|
||||
inline std::ostream& operator <<(_In_ std::ostream& stream, _In_ const ZRCola::chrtag_db &db)
|
||||
{
|
||||
// Write character index.
|
||||
if (stream.fail()) return stream;
|
||||
stream << db.idxChr;
|
||||
|
||||
// Write tag index.
|
||||
if (stream.fail()) return stream;
|
||||
stream << db.idxTag;
|
||||
|
||||
// Write data count.
|
||||
auto data_count = db.data.size();
|
||||
#if defined(_WIN64) || defined(__x86_64__) || defined(__ppc64__)
|
||||
// 4G check
|
||||
if (data_count > 0xffffffff) {
|
||||
stream.setstate(std::ios_base::failbit);
|
||||
return stream;
|
||||
}
|
||||
#endif
|
||||
if (stream.fail()) return stream;
|
||||
unsigned __int32 count = (unsigned __int32)data_count;
|
||||
stream.write((const char*)&count, sizeof(count));
|
||||
|
||||
// Write data.
|
||||
if (stream.fail()) return stream;
|
||||
stream.write((const char*)db.data.data(), sizeof(unsigned __int16)*count);
|
||||
|
||||
return stream;
|
||||
}
|
||||
|
||||
|
||||
///
|
||||
/// Reads character tag database from a stream
|
||||
///
|
||||
/// \param[in ] stream Input stream
|
||||
/// \param[out] db Character tag database
|
||||
///
|
||||
/// \returns The stream \p stream
|
||||
///
|
||||
inline std::istream& operator >>(_In_ std::istream& stream, _Out_ ZRCola::chrtag_db &db)
|
||||
{
|
||||
// Read character index.
|
||||
stream >> db.idxChr;
|
||||
if (!stream.good()) return stream;
|
||||
|
||||
// Read tag index.
|
||||
stream >> db.idxTag;
|
||||
if (!stream.good()) return stream;
|
||||
|
||||
// Read data count.
|
||||
unsigned __int32 count;
|
||||
stream.read((char*)&count, sizeof(count));
|
||||
if (!stream.good()) return stream;
|
||||
|
||||
if (count) {
|
||||
// Read data.
|
||||
db.data.resize(count);
|
||||
stream.read((char*)db.data.data(), sizeof(unsigned __int16)*count);
|
||||
} else
|
||||
db.data.clear();
|
||||
|
||||
return stream;
|
||||
}
|
||||
|
||||
|
||||
///
|
||||
/// Writes tag database to a stream
|
||||
///
|
||||
/// \param[in] stream Output stream
|
||||
/// \param[in] db Tag database
|
||||
///
|
||||
/// \returns The stream \p stream
|
||||
///
|
||||
inline std::ostream& operator <<(_In_ std::ostream& stream, _In_ const ZRCola::tagname_db &db)
|
||||
{
|
||||
// Write name index.
|
||||
if (stream.fail()) return stream;
|
||||
stream << db.idxName;
|
||||
|
||||
// Write tag index.
|
||||
if (stream.fail()) return stream;
|
||||
stream << db.idxTag;
|
||||
|
||||
// Write data count.
|
||||
auto data_count = db.data.size();
|
||||
#if defined(_WIN64) || defined(__x86_64__) || defined(__ppc64__)
|
||||
// 4G check
|
||||
if (data_count > 0xffffffff) {
|
||||
stream.setstate(std::ios_base::failbit);
|
||||
return stream;
|
||||
}
|
||||
#endif
|
||||
if (stream.fail()) return stream;
|
||||
unsigned __int32 count = (unsigned __int32)data_count;
|
||||
stream.write((const char*)&count, sizeof(count));
|
||||
|
||||
// Write data.
|
||||
if (stream.fail()) return stream;
|
||||
stream.write((const char*)db.data.data(), sizeof(unsigned __int16)*count);
|
||||
|
||||
return stream;
|
||||
}
|
||||
|
||||
|
||||
///
|
||||
/// Reads tag database from a stream
|
||||
///
|
||||
/// \param[in ] stream Input stream
|
||||
/// \param[out] db Tag database
|
||||
///
|
||||
/// \returns The stream \p stream
|
||||
///
|
||||
inline std::istream& operator >>(_In_ std::istream& stream, _Out_ ZRCola::tagname_db &db)
|
||||
{
|
||||
// Read name index.
|
||||
stream >> db.idxName;
|
||||
if (!stream.good()) return stream;
|
||||
|
||||
// Read tag index.
|
||||
stream >> db.idxTag;
|
||||
if (!stream.good()) return stream;
|
||||
|
||||
// Read data count.
|
||||
unsigned __int32 count;
|
||||
stream.read((char*)&count, sizeof(count));
|
||||
if (!stream.good()) return stream;
|
||||
|
||||
if (count) {
|
||||
// Read data.
|
||||
db.data.resize(count);
|
||||
stream.read((char*)db.data.data(), sizeof(unsigned __int16)*count);
|
||||
} else
|
||||
db.data.clear();
|
||||
|
||||
return stream;
|
||||
}
|
||||
|
||||
#pragma warning(pop)
|
||||
@@ -204,6 +204,16 @@ namespace ZRCola {
|
||||
///
|
||||
inline translation_db() : idxComp(data), idxDecomp(data) {}
|
||||
|
||||
///
|
||||
/// Clears the database
|
||||
///
|
||||
inline void clear()
|
||||
{
|
||||
idxComp .clear();
|
||||
idxDecomp.clear();
|
||||
data .clear();
|
||||
}
|
||||
|
||||
///
|
||||
/// Composes string
|
||||
///
|
||||
@@ -224,7 +234,7 @@ namespace ZRCola {
|
||||
///
|
||||
inline void Decompose(_In_z_count_(inputMax) const wchar_t* input, _In_ size_t inputMax, _Out_ std::wstring &output, _Out_opt_ std::vector<mapping>* map = NULL) const
|
||||
{
|
||||
Decompose(input, inputMax, NULL, langid_t_blank, output, map);
|
||||
Decompose(input, inputMax, NULL, langid_t::blank, output, map);
|
||||
}
|
||||
|
||||
///
|
||||
@@ -267,7 +277,7 @@ inline std::ostream& operator <<(_In_ std::ostream& stream, _In_ const ZRCola::t
|
||||
stream << db.idxDecomp;
|
||||
|
||||
// Write data count.
|
||||
std::vector<unsigned __int16>::size_type data_count = db.data.size();
|
||||
auto data_count = db.data.size();
|
||||
#if defined(_WIN64) || defined(__x86_64__) || defined(__ppc64__)
|
||||
// 4G check
|
||||
if (data_count > 0xffffffff) {
|
||||
|
||||
@@ -20,7 +20,10 @@
|
||||
#include "stdafx.h"
|
||||
|
||||
|
||||
bool ZRCola::character_db::Search(_In_z_ const wchar_t *str, _In_ const std::set<chrcatid_t> &cats, _Inout_ std::map<wchar_t, unsigned long> &hits, _Inout_ std::map<wchar_t, unsigned long> &hits_sub, _In_opt_ bool (__cdecl *fn_abort)(void *cookie), _In_opt_ void *cookie) const
|
||||
const ZRCola::chrcatid_t ZRCola::chrcatid_t::blank = {};
|
||||
|
||||
|
||||
bool ZRCola::character_db::Search(_In_z_ const wchar_t *str, _In_ const std::set<chrcatid_t> &cats, _Inout_ std::map<wchar_t, charrank_t> &hits, _Inout_ std::map<wchar_t, charrank_t> &hits_sub, _In_opt_ bool (__cdecl *fn_abort)(void *cookie), _In_opt_ void *cookie) const
|
||||
{
|
||||
assert(str);
|
||||
|
||||
@@ -77,13 +80,13 @@ bool ZRCola::character_db::Search(_In_z_ const wchar_t *str, _In_ const std::set
|
||||
if (fn_abort && fn_abort(cookie)) return false;
|
||||
wchar_t c = data[i];
|
||||
if (cats.find(GetCharCat(c)) != cats.end()) {
|
||||
std::map<wchar_t, unsigned long>::iterator idx = hits.find(c);
|
||||
auto idx = hits.find(c);
|
||||
if (idx == hits.end()) {
|
||||
// New character.
|
||||
hits.insert(std::make_pair(data[i], 1));
|
||||
hits.insert(std::make_pair(data[i], 1.0/len));
|
||||
} else {
|
||||
// Increment existing character.
|
||||
idx->second++;
|
||||
// Increase rating of existing character.
|
||||
idx->second += 1.0/len;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -95,13 +98,13 @@ bool ZRCola::character_db::Search(_In_z_ const wchar_t *str, _In_ const std::set
|
||||
if (fn_abort && fn_abort(cookie)) return false;
|
||||
wchar_t c = data[i];
|
||||
if (cats.find(GetCharCat(c)) != cats.end()) {
|
||||
std::map<wchar_t, unsigned long>::iterator idx = hits_sub.find(c);
|
||||
auto idx = hits_sub.find(c);
|
||||
if (idx == hits_sub.end()) {
|
||||
// New character.
|
||||
hits_sub.insert(std::make_pair(data[i], 1));
|
||||
hits_sub.insert(std::make_pair(data[i], 1.0/len));
|
||||
} else {
|
||||
// Increment existing character.
|
||||
idx->second++;
|
||||
// Increase rating of existing character.
|
||||
idx->second += 1.0/len;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
23
lib/libZRCola/src/common.cpp
Normal file
@@ -0,0 +1,23 @@
|
||||
/*
|
||||
Copyright 2015-2016 Amebis
|
||||
|
||||
This file is part of ZRCola.
|
||||
|
||||
ZRCola 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 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
ZRCola 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 ZRCola. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include "stdafx.h"
|
||||
|
||||
|
||||
const ZRCola::langid_t ZRCola::langid_t::blank = {};
|
||||
@@ -19,12 +19,13 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "../../../include/zrcola.h"
|
||||
#include "../../../include/version.h"
|
||||
|
||||
#include "../include/zrcola/character.h"
|
||||
#include "../include/zrcola/language.h"
|
||||
#include "../include/zrcola/normalize.h"
|
||||
#include "../include/zrcola/translate.h"
|
||||
#include "../include/zrcola/tag.h"
|
||||
|
||||
#include <assert.h>
|
||||
|
||||
|
||||
120
lib/libZRCola/src/tag.cpp
Normal file
@@ -0,0 +1,120 @@
|
||||
/*
|
||||
Copyright 2015-2016 Amebis
|
||||
|
||||
This file is part of ZRCola.
|
||||
|
||||
ZRCola 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 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
ZRCola 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 ZRCola. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include "stdafx.h"
|
||||
|
||||
|
||||
bool ZRCola::chrtag_db::Search(_In_ const std::map<tagid_t, unsigned __int16> &tags, _In_ const character_db &ch_db, _In_ const std::set<chrcatid_t> &cats, _Inout_ std::map<wchar_t, charrank_t> &hits, _In_opt_ bool (__cdecl *fn_abort)(void *cookie), _In_opt_ void *cookie) const
|
||||
{
|
||||
for (auto tag = tags.cbegin(), tag_end = tags.cend(); tag != tag_end; ++tag) {
|
||||
if (fn_abort && fn_abort(cookie)) return false;
|
||||
|
||||
// Search for tagged characters.
|
||||
chrtag el = { 0, tag->first };
|
||||
size_t start, end;
|
||||
if (idxTag.find(el, start, end)) {
|
||||
for (size_t i = start; i < end; i++) {
|
||||
if (fn_abort && fn_abort(cookie)) return false;
|
||||
const chrtag &ct = idxTag[i];
|
||||
if (cats.find(ch_db.GetCharCat(ct.chr)) != cats.end()) {
|
||||
auto idx = hits.find(ct.chr);
|
||||
if (idx == hits.end()) {
|
||||
// New character.
|
||||
hits.insert(std::make_pair(ct.chr, tag->second));
|
||||
} else {
|
||||
// Increase count for existing character.
|
||||
idx->second += tag->second;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
bool ZRCola::tagname_db::Search(_In_z_ const wchar_t *str, _In_ LCID locale, _Inout_ std::map<tagid_t, unsigned __int16> &hits, _In_opt_ bool (__cdecl *fn_abort)(void *cookie), _In_opt_ void *cookie) const
|
||||
{
|
||||
assert(str);
|
||||
|
||||
while (*str) {
|
||||
if (fn_abort && fn_abort(cookie)) return false;
|
||||
|
||||
// Skip white space.
|
||||
for (;;) {
|
||||
if (*str == 0)
|
||||
return true;
|
||||
else if (!iswspace(*str))
|
||||
break;
|
||||
else
|
||||
str++;
|
||||
}
|
||||
|
||||
// Get name.
|
||||
std::wstring name;
|
||||
if (*str == L'"') {
|
||||
const wchar_t *str_end = ++str;
|
||||
for (;;) {
|
||||
if (*str_end == 0) {
|
||||
name.assign(str, str_end);
|
||||
break;
|
||||
} else if (*str_end == L'"') {
|
||||
name.assign(str, str_end);
|
||||
str_end++;
|
||||
break;
|
||||
} else
|
||||
str_end++;
|
||||
}
|
||||
str = str_end;
|
||||
} else {
|
||||
const wchar_t *str_end = str + 1;
|
||||
for (; *str_end && !iswspace(*str_end); str_end++);
|
||||
name.assign(str, str_end);
|
||||
str = str_end;
|
||||
}
|
||||
|
||||
if (!name.empty()) {
|
||||
if (fn_abort && fn_abort(cookie)) return false;
|
||||
|
||||
// Find the name.
|
||||
std::unique_ptr<tagname> tn(reinterpret_cast<tagname*>(new char[sizeof(tagname) + sizeof(wchar_t)*name.length()]));
|
||||
tn->locale = locale;
|
||||
memcpy(tn->name, name.data(), sizeof(wchar_t)*(tn->name_len = (unsigned __int16)name.length()));
|
||||
size_t start, end;
|
||||
if (idxName.find(*tn, start, end)) {
|
||||
// The name was found.
|
||||
for (size_t i = start; i < end; i++) {
|
||||
if (fn_abort && fn_abort(cookie)) return false;
|
||||
const tagname &name = idxName[i];
|
||||
auto idx = hits.find(name.tag);
|
||||
if (idx == hits.end()) {
|
||||
// New tag.
|
||||
hits.insert(std::make_pair(name.tag, 1));
|
||||
} else {
|
||||
// Increase count for existing tag.
|
||||
idx->second++;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
@@ -34,7 +34,7 @@ void ZRCola::translation_db::Compose(_In_z_count_(inputMax) const wchar_t* input
|
||||
if (map)
|
||||
map->clear();
|
||||
|
||||
indexComp::size_type compositionsCount = idxComp.size();
|
||||
auto compositionsCount = idxComp.size();
|
||||
|
||||
for (size_t i = 0; i < inputMax;) {
|
||||
// Find the longest matching composition at i-th character.
|
||||
@@ -116,7 +116,7 @@ void ZRCola::translation_db::Decompose(_In_z_count_(inputMax) const wchar_t* inp
|
||||
if (map)
|
||||
map->clear();
|
||||
|
||||
indexDecomp::size_type decompositionsCount = idxDecomp.size();
|
||||
auto decompositionsCount = idxDecomp.size();
|
||||
|
||||
for (size_t i = 0; i < inputMax;) {
|
||||
// Find whether the character can be decomposed.
|
||||
|
||||
@@ -19,6 +19,10 @@
|
||||
|
||||
!INCLUDE "..\..\..\include\MSIBuildCfg.mak"
|
||||
|
||||
!IFNDEF MSIBUILD_LANGID
|
||||
!ERROR Parameter MSIBUILD_LANGID is undefined.
|
||||
!ENDIF
|
||||
|
||||
|
||||
######################################################################
|
||||
# AppSearch
|
||||
@@ -72,7 +76,10 @@ complibZRColaUI.dll.Win32 {D9A5BF44-DDFE-4A22-89F4-14D291581829} ZRCOLABINDIR 0
|
||||
!IF "$(PLAT)" == "x64"
|
||||
complibZRColaUI.dll.x64 {360E78E5-9560-4C52-B806-45EDC682BB17} ZRCOLABINDIR 256 filelibZRColaUI.dll.x64
|
||||
!ENDIF
|
||||
!IF "$(LANG)" == "Sl"
|
||||
!IF "$(LANG)" == "ru_RU"
|
||||
complibZRColaUI.mo.ru_RU {2099A205-5D5E-4AD9-BD31-EECC87FEAB47} ZRCOLALOCRURUDIR $(MSIBUILD_COMPONENT_ATTRIB_FILE) filelibZRColaUI.mo.ru_RU
|
||||
!ENDIF
|
||||
!IF "$(LANG)" == "sl_SI"
|
||||
complibZRColaUI.mo.sl_SI {EAE1C699-8415-4FC6-9EC7-FE74AFC432A9} ZRCOLALOCSLSIDIR $(MSIBUILD_COMPONENT_ATTRIB_FILE) filelibZRColaUI.mo.sl_SI
|
||||
!ENDIF
|
||||
<<NOKEEP
|
||||
@@ -105,8 +112,8 @@ filelibZRColaUI.dll.x64 complibZRColaUI.dll.x64 LIBZRC~6.DLL|libZRColaUI10u_vc10
|
||||
filelibZRColaUI.dll.x64 complibZRColaUI.dll.x64 LIBZRC~8.DLL|libZRColaUI10ud_vc100_x64.dll 0 0 1536 1
|
||||
!ENDIF
|
||||
!ENDIF
|
||||
!IF "$(LANG)" == "Sl"
|
||||
filelibZRColaUI.mo.sl_SI complibZRColaUI.mo.sl_SI LIBZRC~1.MO|libZRColaUI.mo 0 1060 0 1
|
||||
!IF "$(LANG)" != "en_US"
|
||||
filelibZRColaUI.mo.$(LANG) complibZRColaUI.mo.$(LANG) LIBZRC~1.MO|libZRColaUI.mo 0 $(MSIBUILD_LANGID) 0 1
|
||||
!ENDIF
|
||||
<<NOKEEP
|
||||
|
||||
|
||||
@@ -23,6 +23,7 @@
|
||||
#include <zrcola/common.h>
|
||||
|
||||
#include <stdex/idrec.h>
|
||||
#include <assert.h>
|
||||
#include <istream>
|
||||
#include <ostream>
|
||||
#include <vector>
|
||||
@@ -50,6 +51,28 @@ namespace ZRCola {
|
||||
unsigned __int16 name_len; ///< Character group name length in \c data
|
||||
unsigned __int16 char_len; ///< Character list length in \c data
|
||||
wchar_t data[]; ///< Character group name and character list
|
||||
|
||||
inline const wchar_t* get_chars() const
|
||||
{
|
||||
return data + name_len;
|
||||
}
|
||||
|
||||
inline wchar_t get_char(size_t index) const
|
||||
{
|
||||
assert(index < char_len);
|
||||
return data[name_len + index];
|
||||
}
|
||||
|
||||
inline const unsigned __int16* get_char_shown() const
|
||||
{
|
||||
return (const unsigned __int16*)(data + name_len + char_len);
|
||||
}
|
||||
|
||||
inline bool is_char_shown(size_t index) const
|
||||
{
|
||||
assert(index < char_len);
|
||||
return (data[name_len + char_len + index / 16] & (1 << (index % 16))) ? true : false;
|
||||
}
|
||||
};
|
||||
#pragma pack(pop)
|
||||
|
||||
@@ -142,7 +165,7 @@ inline std::ostream& operator <<(_In_ std::ostream& stream, _In_ const ZRCola::c
|
||||
stream << db.idxRnk;
|
||||
|
||||
// Write data count.
|
||||
std::vector<unsigned __int16>::size_type data_count = db.data.size();
|
||||
auto data_count = db.data.size();
|
||||
#if defined(_WIN64) || defined(__x86_64__) || defined(__ppc64__)
|
||||
// 4G check
|
||||
if (data_count > 0xffffffff) {
|
||||
|
||||
@@ -209,6 +209,16 @@ namespace ZRCola {
|
||||
///
|
||||
inline keyseq_db() : idxChr(data), idxKey(data) {}
|
||||
|
||||
///
|
||||
/// Clears the database
|
||||
///
|
||||
inline void clear()
|
||||
{
|
||||
idxChr.clear();
|
||||
idxKey.clear();
|
||||
data .clear();
|
||||
}
|
||||
|
||||
///
|
||||
/// Get text representation of a given key sequence
|
||||
///
|
||||
@@ -264,7 +274,7 @@ inline std::ostream& operator <<(_In_ std::ostream& stream, _In_ const ZRCola::k
|
||||
stream << db.idxKey;
|
||||
|
||||
// Write data count.
|
||||
std::vector<unsigned __int16>::size_type data_count = db.data.size();
|
||||
auto data_count = db.data.size();
|
||||
#if defined(_WIN64) || defined(__x86_64__) || defined(__ppc64__)
|
||||
// 4G check
|
||||
if (data_count > 0xffffffff) {
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: libZRColaUI\n"
|
||||
"POT-Creation-Date: 2016-05-09 10:38+0200\n"
|
||||
"POT-Creation-Date: 2016-10-13 11:47+0200\n"
|
||||
"PO-Revision-Date: 2016-02-06 09:04+0100\n"
|
||||
"Last-Translator: Simon Rozman <simon.rozman@amebis.si>\n"
|
||||
"Language-Team: Amebis, d. o. o., Kamnik <info@amebis.si>\n"
|
||||
@@ -10,7 +10,7 @@ msgstr ""
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Generator: Poedit 1.8.7\n"
|
||||
"X-Generator: Poedit 1.8.9\n"
|
||||
"X-Poedit-Basepath: ..\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-Poedit-SourceCharset: UTF-8\n"
|
||||
|
||||
@@ -1,15 +1,15 @@
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: libZRColaUI\n"
|
||||
"POT-Creation-Date: 2016-05-13 19:20+0200\n"
|
||||
"PO-Revision-Date: 2016-05-13 19:20+0200\n"
|
||||
"POT-Creation-Date: 2016-10-05 08:33+0200\n"
|
||||
"PO-Revision-Date: 2016-10-05 08:33+0200\n"
|
||||
"Last-Translator: Simon Rozman <simon.rozman@amebis.si>\n"
|
||||
"Language-Team: Amebis, d. o. o., Kamnik <info@amebis.si>\n"
|
||||
"Language: ru_RU\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Generator: Poedit 1.8.7\n"
|
||||
"X-Generator: Poedit 1.8.9\n"
|
||||
"X-Poedit-Basepath: .\n"
|
||||
"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
|
||||
"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
|
||||
@@ -18,144 +18,144 @@ msgstr ""
|
||||
|
||||
#: src/keyboard.cpp:30 src/keyboard.cpp:72
|
||||
msgid "Ctrl"
|
||||
msgstr ""
|
||||
msgstr "Ctrl"
|
||||
|
||||
#: src/keyboard.cpp:31 src/keyboard.cpp:71
|
||||
msgid "Alt"
|
||||
msgstr ""
|
||||
msgstr "Alt"
|
||||
|
||||
#: src/keyboard.cpp:32 src/keyboard.cpp:70
|
||||
msgid "Shift"
|
||||
msgstr ""
|
||||
msgstr "Shift"
|
||||
|
||||
#: src/keyboard.cpp:45
|
||||
msgid "Esc"
|
||||
msgstr ""
|
||||
msgstr "Esc"
|
||||
|
||||
#: src/keyboard.cpp:47
|
||||
msgid "F1"
|
||||
msgstr ""
|
||||
msgstr "F1"
|
||||
|
||||
#: src/keyboard.cpp:48
|
||||
msgid "F2"
|
||||
msgstr ""
|
||||
msgstr "F2"
|
||||
|
||||
#: src/keyboard.cpp:49
|
||||
msgid "F3"
|
||||
msgstr ""
|
||||
msgstr "F3"
|
||||
|
||||
#: src/keyboard.cpp:50
|
||||
msgid "F4"
|
||||
msgstr ""
|
||||
msgstr "F4"
|
||||
|
||||
#: src/keyboard.cpp:51
|
||||
msgid "F5"
|
||||
msgstr ""
|
||||
msgstr "F5"
|
||||
|
||||
#: src/keyboard.cpp:52
|
||||
msgid "F6"
|
||||
msgstr ""
|
||||
msgstr "F6"
|
||||
|
||||
#: src/keyboard.cpp:53
|
||||
msgid "F7"
|
||||
msgstr ""
|
||||
msgstr "F7"
|
||||
|
||||
#: src/keyboard.cpp:54
|
||||
msgid "F8"
|
||||
msgstr ""
|
||||
msgstr "F8"
|
||||
|
||||
#: src/keyboard.cpp:55
|
||||
msgid "F9"
|
||||
msgstr ""
|
||||
msgstr "F9"
|
||||
|
||||
#: src/keyboard.cpp:56
|
||||
msgid "F10"
|
||||
msgstr ""
|
||||
msgstr "F10"
|
||||
|
||||
#: src/keyboard.cpp:57
|
||||
msgid "F11"
|
||||
msgstr ""
|
||||
msgstr "F11"
|
||||
|
||||
#: src/keyboard.cpp:58
|
||||
msgid "F12"
|
||||
msgstr ""
|
||||
msgstr "F12"
|
||||
|
||||
#: src/keyboard.cpp:60
|
||||
msgid "Print Screen"
|
||||
msgstr ""
|
||||
msgstr "Print Screen"
|
||||
|
||||
#: src/keyboard.cpp:61
|
||||
msgid "Scroll Lock"
|
||||
msgstr ""
|
||||
msgstr "Scroll Lock"
|
||||
|
||||
#: src/keyboard.cpp:62
|
||||
msgid "Pause"
|
||||
msgstr ""
|
||||
msgstr "Pause"
|
||||
|
||||
#: src/keyboard.cpp:64
|
||||
msgid "Backspace"
|
||||
msgstr ""
|
||||
msgstr "Backspace"
|
||||
|
||||
#: src/keyboard.cpp:65
|
||||
msgid "Tab"
|
||||
msgstr ""
|
||||
msgstr "Tab"
|
||||
|
||||
#: src/keyboard.cpp:66
|
||||
msgid "Caps Lock"
|
||||
msgstr ""
|
||||
msgstr "Caps Lock"
|
||||
|
||||
#: src/keyboard.cpp:67
|
||||
msgid "Return"
|
||||
msgstr ""
|
||||
msgstr "Return"
|
||||
|
||||
#: src/keyboard.cpp:68
|
||||
msgid "Space"
|
||||
msgstr ""
|
||||
msgstr "Space"
|
||||
|
||||
#: src/keyboard.cpp:73
|
||||
msgid "Menu"
|
||||
msgstr ""
|
||||
msgstr "Menu"
|
||||
|
||||
#: src/keyboard.cpp:75
|
||||
msgid "Insert"
|
||||
msgstr ""
|
||||
msgstr "Insert"
|
||||
|
||||
#: src/keyboard.cpp:76
|
||||
msgid "Delete"
|
||||
msgstr ""
|
||||
msgstr "Delete"
|
||||
|
||||
#: src/keyboard.cpp:77
|
||||
msgid "Page Up"
|
||||
msgstr ""
|
||||
msgstr "Page Up"
|
||||
|
||||
#: src/keyboard.cpp:78
|
||||
msgid "Page Down"
|
||||
msgstr ""
|
||||
msgstr "Page Down"
|
||||
|
||||
#: src/keyboard.cpp:79
|
||||
msgid "Home"
|
||||
msgstr ""
|
||||
msgstr "Home"
|
||||
|
||||
#: src/keyboard.cpp:80
|
||||
msgid "End"
|
||||
msgstr ""
|
||||
msgstr "End"
|
||||
|
||||
#: src/keyboard.cpp:82
|
||||
msgid "Left"
|
||||
msgstr ""
|
||||
msgstr "Left"
|
||||
|
||||
#: src/keyboard.cpp:83
|
||||
msgid "Up"
|
||||
msgstr ""
|
||||
msgstr "Up"
|
||||
|
||||
#: src/keyboard.cpp:84
|
||||
msgid "Right"
|
||||
msgstr ""
|
||||
msgstr "Right"
|
||||
|
||||
#: src/keyboard.cpp:85
|
||||
msgid "Down"
|
||||
msgstr ""
|
||||
msgstr "Down"
|
||||
|
||||
#: src/keyboard.cpp:87
|
||||
msgid "Num Lock"
|
||||
msgstr ""
|
||||
msgstr "Num Lock"
|
||||
|
||||