diff --git a/common/windows/cpp/include/legacy_kmx_memory.h b/common/windows/cpp/include/legacy_kmx_memory.h index 771a4d57ca..b0c03f271e 100644 --- a/common/windows/cpp/include/legacy_kmx_memory.h +++ b/common/windows/cpp/include/legacy_kmx_memory.h @@ -21,41 +21,37 @@ typedef struct tagKEY typedef struct tagGROUP { PWSTR dpName; - LPKEY dpKeyArray; // [LPKEY] address of first item in key array + LPKEY dpKeyArray; // [LPKEY] address of first item in key array PWSTR dpMatch; PWSTR dpNoMatch; - DWORD cxKeyArray; // in array entries - BOOL fUsingKeys; // group(xx) [using keys] <-- specified or not + DWORD cxKeyArray; // in array entries + BOOL fUsingKeys; // group(xx) [using keys] <-- specified or not } GROUP, * LPGROUP; typedef struct tagKEYBOARD { - DWORD dwIdentifier; // Keyman compiled keyboard id + DWORD dwIdentifier; // Keyman compiled keyboard id - DWORD dwFileVersion; // Version of the file - Keyman 4.0 is 0x0400 + DWORD dwFileVersion; // Version of the file - Keyman 4.0 is 0x0400 - DWORD dwCheckSum; // As stored in keyboard. DEPRECATED as of 16.0 - DWORD xxkbdlayout; // as stored in HKEY_LOCAL_MACHINE//system//currentcontrolset//control//keyboard layouts - DWORD IsRegistered; // layout id, from same registry key - DWORD version; // keyboard version + DWORD dwCheckSum; // As stored in keyboard. DEPRECATED as of 16.0 + DWORD xxkbdlayout; // as stored in HKEY_LOCAL_MACHINE//system//currentcontrolset//control//keyboard layouts + DWORD IsRegistered; // layout id, from same registry key + DWORD version; // keyboard version - DWORD cxStoreArray; // in array entries - DWORD cxGroupArray; // in array entries + DWORD cxStoreArray; // in array entries + DWORD cxGroupArray; // in array entries - LPSTORE dpStoreArray; // [LPSTORE] address of first item in store array, from start of file - LPGROUP dpGroupArray; // [LPGROUP] address of first item in group array, from start of file + LPSTORE dpStoreArray; // [LPSTORE] address of first item in store array, from start of file + LPGROUP dpGroupArray; // [LPGROUP] address of first item in group array, from start of file - DWORD StartGroup[2]; // index of starting groups [2 of them] + DWORD StartGroup[2]; // index of starting groups [2 of them] // Ansi=0, Unicode=1 - DWORD dwFlags; // Flags for the keyboard file + DWORD dwFlags; // Flags for the keyboard file - DWORD dwHotKey; // standard windows hotkey (hiword=shift/ctrl/alt stuff, loword=vkey) + DWORD dwHotKey; // standard windows hotkey (hiword=shift/ctrl/alt stuff, loword=vkey) - //PWSTR dpName; // offset of name - //PWSTR dpLanguageName; // offset of language name; - //PWSTR dpCopyright; // offset of copyright - //PWSTR dpMessage; // offset of message in Keyboard About box - - HBITMAP hBitmap; // handle to the bitmap in the file; + DWORD dpBitmapOffset; // 0038 offset of the bitmaps in the file + DWORD dwBitmapSize; // 003C size in bytes of the bitmaps } KEYBOARD, * LPKEYBOARD; diff --git a/windows/src/engine/mcompile/mc_kmxfile.h b/windows/src/engine/mcompile/mc_kmxfile.h deleted file mode 100644 index 557ba968c7..0000000000 --- a/windows/src/engine/mcompile/mc_kmxfile.h +++ /dev/null @@ -1,66 +0,0 @@ -#include - -#ifndef _KMXFILE_H -#define _KMXFILE_H - -typedef struct tagSTORE { - DWORD dwSystemID; - PWSTR dpName; - PWSTR dpString; -} STORE, *LPSTORE; - -typedef struct tagKEY { - WCHAR Key; - DWORD Line; - DWORD ShiftFlags; - PWSTR dpOutput; - PWSTR dpContext; -} KEY, *LPKEY; - - -typedef struct tagGROUP { - PWSTR dpName; - LPKEY dpKeyArray; // [LPKEY] address of first item in key array - PWSTR dpMatch; - PWSTR dpNoMatch; - DWORD cxKeyArray; // in array entries - BOOL fUsingKeys; // group(xx) [using keys] <-- specified or not -} GROUP, *LPGROUP; - - -typedef struct tagKEYBOARD { - DWORD dwIdentifier; // Keyman compiled keyboard id - - DWORD dwFileVersion; // Version of the file - Keyman 4.0 is 0x0400 - - DWORD dwCheckSum; // As stored in keyboard. DEPRECATED as of 16.0 - DWORD xxkbdlayout; // as stored in HKEY_LOCAL_MACHINE//system//currentcontrolset//control//keyboard layouts - DWORD IsRegistered; // layout id, from same registry key - DWORD version; // keyboard version - - DWORD cxStoreArray; // in array entries - DWORD cxGroupArray; // in array entries - - LPSTORE dpStoreArray; // [LPSTORE] address of first item in store array, from start of file - LPGROUP dpGroupArray; // [LPGROUP] address of first item in group array, from start of file - - DWORD StartGroup[2]; // index of starting groups [2 of them] - // Ansi=0, Unicode=1 - - DWORD dwFlags; // Flags for the keyboard file - - DWORD dwHotKey; // standard windows hotkey (hiword=shift/ctrl/alt stuff, loword=vkey) - - //PWSTR dpName; // offset of name - //PWSTR dpLanguageName; // offset of language name; - //PWSTR dpCopyright; // offset of copyright - //PWSTR dpMessage; // offset of message in Keyboard About box - - DWORD dpBitmapOffset; // 0038 offset of the bitmaps in the file - DWORD dwBitmapSize; // 003C size in bytes of the bitmaps - //HBITMAP hBitmap; // handle to the bitmap in the file; -} KEYBOARD, *LPKEYBOARD; - -BOOL LoadKeyboard(LPWSTR fileName, LPKEYBOARD *lpKeyboard); - -#endif diff --git a/windows/src/engine/mcompile/mcompile.h b/windows/src/engine/mcompile/mcompile.h index 68f1da807c..46b2dce6bb 100644 --- a/windows/src/engine/mcompile/mcompile.h +++ b/windows/src/engine/mcompile/mcompile.h @@ -1,20 +1,20 @@ /* Name: mcompile Copyright: Copyright (C) 2003-2017 SIL International. - Documentation: - Description: + Documentation: + Description: Create Date: 3 Aug 2014 Modified Date: 3 Aug 2014 Authors: mcdurdin - Related Files: - Dependencies: + Related Files: + Dependencies: - Bugs: - Todo: - Notes: + Bugs: + Todo: + Notes: History: 03 Aug 2014 - mcdurdin - I4353 - V9.0 - mnemonic layout recompiler mixes up deadkey rules - + */ #include @@ -28,3 +28,5 @@ struct DeadkeyMapping { // I4353 }; extern std::vector FDeadkeys; // I4353 + +BOOL LoadKeyboard(LPWSTR fileName, LPKEYBOARD *lpKeyboard); diff --git a/windows/src/engine/mcompile/pch.h b/windows/src/engine/mcompile/pch.h index acbd5b6400..eb7a71f729 100644 --- a/windows/src/engine/mcompile/pch.h +++ b/windows/src/engine/mcompile/pch.h @@ -8,8 +8,8 @@ #include "targetver.h" #include +#include "../../../../common/windows/cpp/include/legacy_kmx_memory.h" #include "mcompile.h" -#include "mc_kmxfile.h" #include "mc_syskbd.h" #include "../../../../common/windows/cpp/include/crc32.h" #include "../../../../common/include/kmx_file.h"