HI,
here's a script that extract the info about encoding inside the dictionary.
just type the name of the script and the path to the dictionary and it will tell you the encoding, on what row it was found inside and name of the package. Ensure you don't place .zip-files in the same directory, unless they're spelling dictionaries from OOorg you want to check. See below.
if you download all packages (yes there's an option for that as well) it'll scan them all as the're named e.g. af_Za.zip to zu_ZA.zip
//Jan-Erik
Sample output:
Encoding:UTF-8 Name:cop_EG Row:19
Encoding:UTF-8 Name:csb_CSB Row:1
Encoding:ISO8859-2 Name:cs_CZ Row:1
Encoding:ISO8859-14 Name:cy_GB Row:79
Encoding:ISO8859-1 Name:da_DK Row:1
Encoding:ISO8859-1 Name:de_AT Row:1
Encoding:ISO8859-1 Name:de_CH Row:1
Encoding:ISO8859-1 Name:de_DE_comb Row:1
Encoding:ISO8859-1 Name:de_DE_neu Row:1
Encoding:ISO8859-1 Name:de_DE Row:1
Encoding:ISO8859-1 Name:de_frami_neu Row:1
Encoding:ISO8859-7 Name:el_GR Row:31
Encoding:ISO8859-1 Name:en_AU Row:7
Encoding:ISO8859-1 Name:en_CA Row:1
Encoding:ISO8859-1 Name:en_GB-oed Row:7
Encoding:ISO8859-1 Name:en_GB Row:7
Encoding:ISO8859-1 Name:en_NZ Row:7
Encoding:ISO8859-1 Name:en_US Row:1
Encoding:ISO8859-1 Name:en_ZA Row:7
Encoding:ISO8859-3 Name:eo_l3 Row:1
Encoding:ISO8859-1 Name:es_ES Row:1
Encoding:ISO8859-1 Name:es_MX Row:1
Encoding:ISO8859-1 Name:et_EE Row:1
Encoding:ISO8859-1 Name:eu-ES Row:9
Note! You need unzip32.dll from Info-Zip to use it, but it should be included in your system...
/* OpenOffice.org v3 Dictionaries -> Dictionary Encoding */
call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs'
call SysLoadFuncs
call RxFuncAdd 'UZLoadFuncs', 'UNZIP32', 'UZLoadFuncs'
call UZLoadFuncs
parse arg retval
fname = 'D:\OOorg_Spelling_pack\'
if retval = '' then retval = fname
cfg.file = retval
call RxFuncAdd 'ULSLoadFuncs', 'rxuls', 'ULSLoadFuncs'
call ULSLoadFuncs
curr_time = TIME( 'R' )
CALL SysFileTree retval||'*.oxt', 'fnames', 'FO'
IF fnames.0 = 0 THEN
CALL SysFileTree retval||'*.zip', 'fnames', 'FO'
DO a = 1 to fnames.0
CALL UZFileTree fnames.a, 'file','*.aff'
DO i = 1 to file.0
PARSE VALUE FILESPEC( 'N', file.i ) WITH file.i.name'.'.
lng. = 0
retval = UZUnZipToVar( fnames.a, file.i, 'lng' )
DO j = 1 TO lng.0
PARSE VALUE lng.j WITH 'SET' rest
rest = STRIP( rest )
IF LENGTH( rest ) > 0 THEN DO
say 'Encoding:'||rest||' Name:'||file.i.name||' Row:'||j
LEAVE j
END
END
DROP lng.
END
DROP file.
END
CALL ULSDropFuncs
call UZDropFuncs
exit