Commit graph

754 commits

Author SHA1 Message Date
rc-swag
f7391e3a46 chore(windows): add debug log msgs for modifier key press
add debug log messages in the code that processes modifier
key presses. Will be usefull debuging issues with the
seralized event server and modifer keys.
2024-06-03 21:40:24 +10:00
Marc Durdin
c67369e143 fix(windows): correct filename and path for keymanengine.msm 2024-05-23 09:47:56 +07:00
Marc Durdin
c06dd480df chore(windows): add new build scripts for Windows builds 2024-05-20 08:27:31 +07:00
Marc Durdin
f9a321fa1a chore(windows): add compiled resources to .gitignore 2024-05-20 08:19:56 +07:00
Marc Durdin
d06f4b13d0 chore(windows): move insthelper up to engine folder 2024-05-20 08:19:27 +07:00
Marc Durdin
9f7eff122e chore(windows): remove legacy build Makefiles 2024-05-20 08:16:52 +07:00
Marc Durdin
fa57d5c674 chore(developer): final work on build.sh for developer
Now builds from a clean repo:

  developer/src/build.sh configure build test publish

* Splits kmbrowserhost into kmdbrowserhost for Developer; this means
  that Developer Browser Host now inherits the Developer settings rather
  than the Keyman for Windows settings, and simplifies distribution and
  management. The only difference between the two is in the startup code
  so this seems like a good split.

* Cleanup of various build scripts and dependencies.
2024-05-20 06:34:53 +07:00
Steven R. Loomis
6706ae0957 chore(core): km_core_cp -> km_core_cu
- km_core_cp represents a 16 bit code unit, not a code point.

Fixes: #11033
2024-05-02 17:39:15 -05:00
rc-swag
71377c3754 fix(windows): Still need to guard against out of bound index 2024-04-23 08:56:56 +10:00
rc-swag
94c8879961 fix(windows): check font count display none found
This change is to check number of fonts found for keyboard
to guard against trying to index it when there are no fonts.
  for i := 0 to grid.RowCount - 1 do
        m := System.Math.Max(m,
	Canvas.TextWidth(FSelectedKeyboard.Fonts[i].FontName) + 6)
It also notifies the user no suggested fonts where found.
2024-04-22 17:01:44 +10:00
rc-swag
043090f8a4
Merge pull request #10184 from keymanapp/feat/update-windows-engine-tests
feat(windows): update windows engine unit tests to match removal of engine cached context
2024-02-13 09:45:29 +10:00
rc-swag
477197ae23 chore(windows): missed registryw.cpp deffinition update
Checkin the kmtip registryw.cpp LPCWSTR argument update.
2024-02-12 15:19:43 +10:00
rc-swag
89f6770a78 chore(windows): add const to argument definition
Updated the call stack to keep a const string for the value parameter
being written to registry.

SaveKeyboardOptionCoretoRegistry calls
IntSaveKeyboardOptionCoretoRegistry which calls
RegistryFullAccess::WriteString which calls
RegSetValueExW, which takes a const data parameter.
2024-02-09 11:11:27 +10:00
rc-swag
a798303871 feat: remove uneeded tests after core refactor 2024-02-07 15:31:56 +10:00
Marc Durdin
4624247231
Merge pull request #10661 from keymanapp/chore/windows/rename-action-variable
chore(windows): rename actionItem to outputString for clarity
2024-02-07 16:02:17 +11:00
Marc Durdin
65125196e5
Merge pull request #10660 from keymanapp/fix/windows/wstrtostr-use-WideCharToMultiByte
fix(windows): `wstrtostr` should use `WideCharToMultiByte`
2024-02-07 16:02:11 +11:00
Marc Durdin
73b4ee5d21
Merge pull request #10650 from keymanapp/fix/windows/10604-unicode-logging
fix(windows): support unicode strings properly in logs
2024-02-07 16:01:45 +11:00
rc-swag
ec03e47b85 chore: Merge branch 'master' into feat/update-windows-engine-tests 2024-02-07 14:16:50 +10:00
rc-swag
c781808d8d chore(windows): rename actionOption to output string
renamed a variable for clarity added a description to make clear
that a null terminated string is the expected input.
2024-02-07 14:11:44 +10:00
Marc Durdin
f9bb4ba818 fix(windows): wstrtostr should use WideCharToMultiByte
Relates to #10604: "Note also wstrtostr crashes if you pass it surrogate
pairs because they won't convert ... ouch."
2024-02-07 10:39:07 +07:00
Marc Durdin
07c7a0659f
Merge branch 'master' into fix/core/10582-km_core_state_get_actions-idempotency 2024-02-07 12:32:41 +11:00
Marc Durdin
2c2602ba18
Merge pull request #10569 from keymanapp/chore/core/10520-hide-old-action-apis
chore(core): move action apis into keyman_core_api_actions.h
2024-02-07 12:30:22 +11:00
rc-swag
eed14b3c5b feat: keyman-engine-tests include icu and appcontext
The keyman-engine and keyman-engine-tests have the icu
dependncy added. Also the appcontext.h and appcontext.cpp
refactor has been update in the project.
2024-02-06 17:28:36 +10:00
Marc Durdin
810ed35a8a fix(windows): support unicode strings properly in logs
Fixes #10604.

Note: does not address limitations in etl2log yet, but allows us to emit
unicode strings to the logs.
2024-02-06 14:12:41 +07:00
rc-swag
6d4b287d7d feat(windows): variable name change 2024-02-06 08:47:22 +10:00
rc-swag
eecc6cd7bd
fix(windows): address review comments
Co-authored-by: Marc Durdin <marc@durdin.net>
2024-02-06 08:25:08 +10:00
rc-swag
dbc3338d41 chore: Merge branch 'master' into feat/update-windows-engine-tests 2024-02-05 15:19:03 +10:00
Marc Durdin
e69bfe7e71 chore(windows): remove old code relating to actions lifecycle
After the changes to core in previous commit, Windows no longer needs to
dispose the actions struct. Also refactored the lifecycle of
core_actions to make ownership clearer.
2024-02-05 09:59:47 +07:00
Marc Durdin
aa80992fb8
Merge branch 'feat/windows/use-km-core-actions-struct' into chore/core/10520-hide-old-action-apis 2024-02-05 13:44:36 +11:00
rc-swag
50b5d197b3 feat(windows): remove extra debug messages 2024-02-05 11:00:27 +10:00
Marc Durdin
f34976e8c0
Merge branch 'feat/windows/use-km-core-actions-struct' into chore/core/10520-hide-old-action-apis 2024-02-03 09:40:53 +11:00
rc-swag
8f2e0a76eb feat(windows): code comment 2024-02-02 16:55:28 +10:00
rc-swag
d34ba7e527 feat(windows): remove extra debugging 2024-02-02 16:48:09 +10:00
rc-swag
2b0950617d feat(windows): add cached actions 2024-02-01 15:11:23 +10:00
Marc Durdin
9ee5777e48 chore(core): move action apis into keyman_core_api_actions.h
Fixes #10520.

The definitions for `struct km_core_action_item`, `struct
km_core_backspace_item`, `enum km_core_backspace_type`, `enum
km_core_action_type`, `km_core_state_action_items()`,
`km_core_state_queue_action_items()`, `km_core_process_queued_actions()`
are now in keyman_core_api_actions.h rather than in the primary
keyman_core_api.h, as they should not be used by engines in general.

The current users of those APIs are the interactive kmx debugger, and
the IMX integration in Keyman Engine for Windows. Both of these depend
on the old action queue model rather than the actions struct.

In a future version, we may refactor these further to make them apply
directly to the KMX processor, and provide access via an interface to
the KMX processor rather than as a general Core API. Once this change is
made, then Core itself will no longer support action queues at all, and
will expect keyboard processors to fill in an action struct (this is
already done for LDML).
2024-01-31 11:32:09 +07:00
rc-swag
118466f6b2 feat(windows): use delete-context for backspace
Use the delete_context memember of the action struct to
check for surrogates and determine the code units to delete.
2024-01-31 10:31:59 +10:00
rc-swag
5ff8092bde chore(windows): Merge branch 'master' into feat/windows/use-km-core-actions-struct 2024-01-31 09:59:12 +10:00
rc-swag
1e554c8804 feat(windows): don't write persisted option back to core
When the action from the core is to persist an option there
is no need to write that value back to the core as it has already
been updated, by the core.
2024-01-30 15:42:17 +10:00
rc-swag
d8c232dc7c feat(windows): refactor to use km_core_actions struct 2024-01-30 14:07:55 +10:00
Marc Durdin
671973baab refactor(core): split context API from Core primary API
Relates to #9999.
Fixes #10384.

The context API endpoints should no longer be considered as part of the
standard Core API. The only consumers that have a need to access these
APIs are the IMX integration in Engine for Windows, and the Keyman
Developer Debugger.

These symbols are currently used by Developer:
* `km_core_context` struct
* `km_core_context_type` enum
* `km_core_context_item` struct
* `KM_CORE_CONTEXT_ITEM_END` macro
* `km_core_state_context()`
* `km_core_context_set()`
* `km_core_context_clear()`

These symbols are currently used by Windows IMX:
* `km_core_context` struct
* `km_core_context_type` enum
* `km_core_context_item` struct
* `KM_CORE_CONTEXT_ITEM_END` macro
* `km_core_context_items_dispose()`
* `km_core_context_item_list_size()`
* `km_core_state_get_intermediate_context()`

The following functions and symbols are moving to
keyman_core_api_context.h:
* `km_core_context` struct
* `km_core_context_type` enum
* `km_core_context_item` struct
* `KM_CORE_CONTEXT_ITEM_END` macro
* `km_core_state_context()` function
* `km_core_state_get_intermediate_context()` function
* `km_core_context_set()` function
* `km_core_context_clear()` function
* `km_core_context_get()` function
* `km_core_context_items_from_utf16()` function
* `km_core_context_items_from_utf8()` function
* `km_core_context_items_to_utf8()` function
* `km_core_context_items_to_utf16()` function
* `km_core_context_items_to_utf32()` function
* `km_core_context_items_dispose()` function
* `km_core_context_length()` function
* `km_core_context_append()` function
* `km_core_context_shrink()` function
* `km_core_context_item_list_size()` function
2024-01-17 14:44:25 +11:00
Marc Durdin
7cd7ab3346 refactor(windows): use km_core_state_context_debug
Relates to #10365.
2024-01-15 08:29:27 +07:00
Marc Durdin
3d5506ef3e chore(windows): move reportExceptions check in exception handler to caller 2023-12-11 20:44:53 +07:00
Marc Durdin
3a91c7d197 chore(developer): move IDEOptions key responsibility into KeymanDeveloperOptions
First part of addressing #10161 is to refactor the existing usage of the
registry values into the common KeymanDeveloperOptions unit. This was
mostly straightforward except for the changes to KeymanSentryClient,
which happens to be the most important part of this particular fix.
2023-12-11 13:48:43 +07:00
rc-swag
d11ee1a1e3 feat: remove tests cases - build not working 2023-12-08 09:55:37 +10:00
rc-swag
21c012208b
Merge pull request #10176 from keymanapp/fix/windows/keyman64-dll-debug-build
fix(windows): debug includes libcmtd vs libcmt.dll
2023-12-08 09:40:48 +10:00
rc-swag
42a089a84d fix(windows): debug includes libcmtd vs libcmt.dll 2023-12-07 15:20:05 +10:00
rc-swag
63e4371513 chore(windows): fix argument passed into to km_core_state_context_set_if_needed 2023-11-30 12:51:52 +10:00
rc-swag
23da871f18 chore(windows): remove res from PR change resetcontext 2023-11-24 07:52:16 +10:00
rc-swag
08b3764496
chore(windows): review comments
Co-authored-by: Marc Durdin <marc@durdin.net>
2023-11-24 07:48:23 +10:00
rc-swag
2dbad870ca chore(windows): add comments ReadContext 2023-11-23 22:01:26 +10:00