Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
5c06d59
fix(developer): compiler emitting garbage for readonly groups
mcdurdin Jul 29, 2022
f9240d7
fix(developer): stack overflow when compiling non-web keyboard
mcdurdin Aug 3, 2022
e5bd4e0
fix(developer): prevent crash attempting to compile ansi keyboard
mcdurdin Aug 3, 2022
e8caeda
fix(web): button, float init timer cleanup
jahorton Aug 4, 2022
fd713e0
fix(web): late toolbar init
jahorton Aug 5, 2022
3657219
chore(linux): Update debian changelog
ermshiperete Aug 5, 2022
b1d201a
feat(linux): Replace deprecated distutils
ermshiperete Aug 8, 2022
c01431a
Merge pull request #7041 from keymanapp/chore/linux/cherry-pick/chang…
ermshiperete Aug 8, 2022
a2cf939
auto: increment master version to 16.0.45
keyman-server Aug 8, 2022
4ed6c02
Merge pull request #7053 from keymanapp/auto/version-master-16.0.45
keyman-server Aug 8, 2022
dbca571
chore(linux): Adjust Linux source package to restructured code
ermshiperete Aug 9, 2022
e6b4648
Merge pull request #7051 from keymanapp/feat/linux/6955_Replace-depre…
ermshiperete Aug 9, 2022
7cf2b0c
Merge pull request #7056 from keymanapp/chore/linux/packaging
ermshiperete Aug 9, 2022
03397be
auto: increment master version to 16.0.46
keyman-server Aug 9, 2022
563c891
Merge pull request #7057 from keymanapp/auto/version-master-16.0.46
keyman-server Aug 9, 2022
422e722
chore(core): move kmx_file.h to common
mcdurdin Aug 11, 2022
bb24d59
chore(core): remove duplicate types
mcdurdin Aug 11, 2022
dedb06e
chore(common): refactor shared types into km_types.h
mcdurdin Aug 11, 2022
16082ff
chore(linux): Refactor `jenkins.sh`
ermshiperete Aug 11, 2022
600f6bf
chore(linux): update include paths
mcdurdin Aug 11, 2022
b1b097b
chore(windows): update include paths
mcdurdin Aug 11, 2022
e30871f
chore(linux): add common/include to further paths
mcdurdin Aug 11, 2022
515bda7
chore(linux): ensure char16_t and namespace
mcdurdin Aug 11, 2022
8e36b33
chore(common): check for redefinition of defines
mcdurdin Aug 11, 2022
10d9ed4
chore(core): use c-compatible type for KMX_UCHAR
mcdurdin Aug 11, 2022
f9dc68b
docs(core): cleanup in keyboardprocessor.h
srl295 Aug 11, 2022
a7fe8be
chore(web): cleans up UI init timer handling
jahorton Aug 12, 2022
139b26e
chore(linux): update tar ignore for common folder
mcdurdin Aug 12, 2022
431d3b0
Merge pull request #7065 from keymanapp/fix/core/kbptypo
srl295 Aug 12, 2022
131525b
auto: increment master version to 16.0.47
keyman-server Aug 12, 2022
5ff13ce
Merge pull request #7070 from keymanapp/auto/version-master-16.0.47
keyman-server Aug 12, 2022
5635372
Merge pull request #7062 from keymanapp/refactor/core/move-kmx_file.h…
mcdurdin Aug 15, 2022
c20e92f
Merge pull request #7031 from keymanapp/fix/developer/7030-stack-over…
mcdurdin Aug 15, 2022
1a001d6
Merge pull request #7033 from keymanapp/fix/developer/7032-crash-comp…
mcdurdin Aug 15, 2022
7d449a5
Merge pull request #7060 from keymanapp/chore/linux/improve_include
ermshiperete Aug 15, 2022
f718938
Merge pull request #7013 from keymanapp/fix/developer/keymanweb-reado…
mcdurdin Aug 15, 2022
5084f6f
auto: increment master version to 16.0.48
keyman-server Aug 15, 2022
b6def5f
Merge pull request #7073 from keymanapp/auto/version-master-16.0.48
keyman-server Aug 15, 2022
760a20e
chore(web): Apply suggestions from code review
jahorton Aug 16, 2022
be77d55
Merge pull request #7036 from keymanapp/fix/web/ui-module-test-stability
jahorton Aug 16, 2022
3fe2499
auto: increment master version to 16.0.49
keyman-server Aug 16, 2022
bc0b716
Merge pull request #7076 from keymanapp/auto/version-master-16.0.49
keyman-server Aug 16, 2022
f2fe3b1
fix: remove saving and restoring context kbd options
rc-swag Aug 17, 2022
ea50559
chore(deps): bump @actions/core from 1.8.2 to 1.9.1
dependabot[bot] Aug 18, 2022
73da0d8
Merge pull request #7077 from keymanapp/fix/7074/keyboard-options-not…
rc-swag Aug 22, 2022
8e160e2
Merge pull request #7087 from keymanapp/dependabot/npm_and_yarn/actio…
mcdurdin Aug 22, 2022
b03e7ca
chore(core): Remove obsolete python keyboardprocessor
ermshiperete Aug 22, 2022
d92ac6e
auto: increment master version to 16.0.50
keyman-server Aug 22, 2022
57b9c6b
Merge pull request #7095 from keymanapp/auto/version-master-16.0.50
keyman-server Aug 22, 2022
096e5da
Merge pull request #7094 from keymanapp/chore/core/python
ermshiperete Aug 23, 2022
e6ff47f
chore: Merge branch 'master' into feature-ldml
mcdurdin Aug 23, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions HISTORY.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,35 @@
# Keyman Version History

## 16.0.49 alpha 2022-08-22

* fix: remove saving and restoring context kbd options (#7077)
* chore(deps): bump @actions/core from 1.8.2 to 1.9.1 (#7087)

## 16.0.48 alpha 2022-08-16

* fix(web): button, float init timer cleanup (#7036)

## 16.0.47 alpha 2022-08-15

* chore(core): refactor kmx_file.h to common (#7062)
* fix(developer): stack overflow when compiling non-web keyboard (#7031)
* fix(developer): prevent crash attempting to compile ansi keyboard (#7033)
* chore(linux): Refactor `jenkins.sh` (#7060)
* fix(developer): compiler emitting garbage for readonly groups (#7013)

## 16.0.46 alpha 2022-08-12

* docs(core): cleanup in keyboardprocessor.h (#7065)

## 16.0.45 alpha 2022-08-09

* feat(linux): Replace deprecated distutils (#7051)
* chore(linux): Adjust Linux source package to restructured code (#7056)

## 16.0.44 alpha 2022-08-08

* chore(linux): Update debian changelog (#7041)

## 16.0.43 alpha 2022-08-05

* chore(web): centralizes web-based modules' CI unit test configurations (#7024)
Expand Down
2 changes: 1 addition & 1 deletion VERSION.md
Original file line number Diff line number Diff line change
@@ -1 +1 @@
16.0.44
16.0.50
65 changes: 65 additions & 0 deletions common/include/km_types.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
#pragma once

/*
#if defined(_WIN32) || defined(_WIN64)
#define snprintf _snprintf
#define vsnprintf _vsnprintf
#define strcasecmp _stricmp
#define strncasecmp _strnicmp
#endif
*/

#if defined(__LP64__) || defined(_LP64)
/* 64-bit, g++ */
#define KMX_64BIT
#endif

#if defined(_WIN64) && !defined(USE_64)
/* 64-bit, Windows */
#define KMX_64BIT
#endif

typedef uint32_t KMX_DWORD;
typedef int32_t KMX_BOOL;
typedef uint8_t KMX_BYTE;
typedef uint16_t KMX_WORD;

#if defined(__cplusplus)
typedef char16_t km_kbp_cp;
typedef char32_t km_kbp_usv;
#else
typedef uint16_t km_kbp_cp; // code point
typedef uint32_t km_kbp_usv; // Unicode Scalar Value
#endif

typedef km_kbp_cp KMX_WCHAR; // wc, 16-bit UNICODE character
typedef KMX_WCHAR *PKMX_WCHAR;

typedef char KMX_CHAR;
typedef KMX_CHAR *PKMX_CHAR;

typedef uint32_t KMX_UINT;

typedef KMX_BYTE *PKMX_BYTE;
typedef KMX_WORD *PKMX_WORD;
typedef KMX_DWORD *PKMX_DWORD;

#ifndef FALSE
#define FALSE 0
#endif

#ifndef TRUE
#define TRUE 1
#endif

// Macros and types to support char16_t vs wchar_t depending on project

#ifdef USE_CHAR16_T
#define lpuch(x) u ## x
typedef km_kbp_cp KMX_UCHAR;
#else
#define lpuch(x) L ## x
typedef wchar_t KMX_UCHAR;
#endif

typedef KMX_UCHAR* KMX_PUCHAR;
7 changes: 6 additions & 1 deletion core/src/kmx/kmx_file.h → common/include/kmx_file.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,14 @@

#pragma once

#include "kmx_base.h"
#include <km_types.h>

#ifdef KMN_KBP
// TODO: move this to a common namespace keyman::common::kmx_file or similar in the future
namespace km {
namespace kbp {
namespace kmx {
#endif

#define KMX_MAX_ALLOWED_FILE_SIZE (128 * 1024 * 1024) /* 128MB */
/* */
Expand Down Expand Up @@ -371,6 +374,8 @@ static_assert(sizeof(COMP_KEY) == KEYBOARDFILEKEY_SIZE, "COMP_KEY must be KEYBOA
static_assert(sizeof(COMP_GROUP) == KEYBOARDFILEGROUP_SIZE, "COMP_GROUP must be KEYBOARDFILEGROUP_SIZE bytes");
static_assert(sizeof(COMP_KEYBOARD) == KEYBOARDFILEHEADER_SIZE, "COMP_KEYBOARD must be KEYBOARDFILEHEADER_SIZE bytes");

#ifdef KMN_KBP
} // namespace kmx
} // namespace kbp
} // namespace km
#endif
2 changes: 1 addition & 1 deletion common/web/keyboard-processor/src/text/codes.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
namespace com.keyman.text {
export var Codes = {
// Define Keyman Developer modifier bit-flags (exposed for use by other modules)
// Compare against /core/src/kmx/kmx_file.h. CTRL+F "#define LCTRLFLAG" to find the secton.
// Compare against /common/include/kmx_file.h. CTRL+F "#define LCTRLFLAG" to find the secton.
modifierCodes: {
"LCTRL":0x0001, // LCTRLFLAG
"RCTRL":0x0002, // RCTRLFLAG
Expand Down
2 changes: 1 addition & 1 deletion common/windows/cpp/include/legacy_kmx_file.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
Name: legacy_kmx_file
Copyright: Copyright (C) SIL International.
Documentation:
Description: Describes .kmx binary format. To be replaced with Core's kmx_file.h
Description: Describes .kmx binary format. To be replaced with common/include/kmx_file.h
Create Date: 4 Jan 2007

Modified Date: 24 Aug 2015
Expand Down
15 changes: 2 additions & 13 deletions core/include/keyman/keyboardprocessor.h
Original file line number Diff line number Diff line change
Expand Up @@ -110,13 +110,6 @@ extern "C"
#endif
// Basic types
//
#if defined(__cplusplus)
typedef char16_t km_kbp_cp;
typedef char32_t km_kbp_usv;
#else
typedef uint16_t km_kbp_cp; // code point
typedef uint32_t km_kbp_usv; // Unicode Scalar Value
#endif
typedef uint16_t km_kbp_virtual_key; // A virtual key code.
typedef uint32_t km_kbp_status; // Status return code.

Expand Down Expand Up @@ -650,7 +643,7 @@ undefined. The returned buffer uses UTF-8 encoding.
- `KM_KBP_STATUS_INVALID_ARGUMENT`: If non-optional parameters are null.
- `KM_KBP_STATUS_NO_MEM`: In the event an internal memory allocation fails.
##### Parameters:
- __opts__: An opaque pointer to a state object.
- __state__: An opaque pointer to a state object.
- __buf__: A pointer to the buffer to place the C string containing the JSON
document into, can be null.
- __space__: A pointer to a size_t variable. This variable must contain the
Expand Down Expand Up @@ -793,7 +786,7 @@ km_kbp_keyboard_get_key_list(km_kbp_keyboard const *keyboard,
Free the allocated memory belonging to a keyboard key list previously
returned by `km_kbp_keyboard_get_key_list`.
##### Parameters:
- __keyboard__: A pointer to the keyboard key list to be
- __key_list__: A pointer to the keyboard key list to be
disposed of.

```c
Expand Down Expand Up @@ -1127,10 +1120,6 @@ In the event the `state` pointer is null

##### Parameters:
- __state__: A pointer to the opaque state object.
- __vk__: A virtual key to be processed.
- __modifier_state__:
The combinations of modifier keys set at the time key `vk` was pressed, bitmask
from the `km_kbp_modifier_state` enum.

```c
*/
Expand Down
9 changes: 9 additions & 0 deletions core/include/keyman/keyboardprocessor_bits.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,12 @@
#define KMN_API _kmn_tag_fn(_kmn_import_flag)
#define KMN_DEPRECATED_API _kmn_tag_fn(_kmn_deprecated_flag _kmn_and _kmn_import_flag)
#endif

#ifndef KMN_KBP
#define KMN_KBP
#endif
#ifndef USE_CHAR16_T
#define USE_CHAR16_T
#endif

#include <km_types.h>
2 changes: 1 addition & 1 deletion core/include/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@
# History: 6 Oct 2018 - TSE - Move into keyman folder.
#

inc = include_directories('.', is_system: true)
inc = include_directories('.', '../../common/include', is_system: true)
subdir('keyman')
4 changes: 4 additions & 0 deletions core/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,10 @@ message('compiler.get_id(): ' + compiler.get_id())

cc = meson.get_compiler('c')

# TODO: Shared includes may use namespaces, etc which need future tidyup.
# For now, we use KMN_KBP to inject the km::kbp::kmx namespace
defns = ['-DKMN_KBP']

subdir('doc')
subdir('include')
subdir('src')
Expand Down
Loading