Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(developer): use richedit in debug memo to support Egyptian cartouches #12464

Merged
merged 2 commits into from
Oct 9, 2024

Conversation

mcdurdin
Copy link
Member

@mcdurdin mcdurdin commented Sep 24, 2024

RichEdit allows text selection one character past end-of-string, so we need to cater for that as well in passing text ranges to the character grid.

Note: in draft as this uses RichEdit 2.0 which has other spacing issues for complex scripts (e.g. Khmer), need to be basing on RichEdit 4.1 preferably.

Fixes: #12454

User Testing

  • TEST_KMN_DEBUGGER: In Keyman Developer, open a Keyman .kmn keyboard, and press F5 to start the debugger. Run through a number of normal operations in the debugger, selecting text, typing, etc, and look for any unexpected display issues or anomalies. Pass this test if no issues are encountered.

  • TEST_LDML_DEBUGGER: In Keyman Developer, open or create a Keyman LDML keyboard, and press F5 to start the debugger. Run through a number of normal operations in the debugger, selecting text, typing, etc, and look for any unexpected display issues or anomalies. Pass this test if no issues are encountered.

…ches

RichEdit allows text selection one character past end-of-string, so we
need to cater for that as well in passing text ranges to the character
grid.

Fixes: #12454
@keymanapp-test-bot keymanapp-test-bot bot added the user-test-missing User tests have not yet been defined for the PR label Sep 24, 2024
@keymanapp-test-bot
Copy link

keymanapp-test-bot bot commented Sep 24, 2024

User Test Results

Test specification and instructions

Test Artifacts

@keymanapp-test-bot keymanapp-test-bot bot added this to the A18S11 milestone Sep 24, 2024
@darcywong00 darcywong00 modified the milestones: A18S11, A18S12 Sep 28, 2024
Adds support for using RichEdit 4.1, and sets the richedit control into
the correct mode for rendering arbitrary Unicode correctly. Removes
some unnecessary per-character refresh for improved performance.

Fixes: #12454
@mcdurdin mcdurdin marked this pull request as ready for review October 8, 2024 07:23
@keymanapp-test-bot keymanapp-test-bot bot added has-user-test user-test-required User tests have not been completed and removed user-test-missing User tests have not yet been defined for the PR labels Oct 8, 2024
@dinakaranr
Copy link

dinakaranr commented Oct 8, 2024

Test Results

I tested this issue with the attached "18.0.117-alpha-test-12464" build on the Windows 10 and 11 OS. I'm sharing my observation here.

  • TEST_KMN_DEBUGGER (failed): 
  1. I installed the Keyman developer 18.0.117-alpha-test-12464 version and then started the configuration.
  2. On Keyman Developer, navigate to the "Keyboard" tab and then click the *.kmn link button to navigate to the build tab.
  3. Click the "Complie Keyboard" button.
  4. Click the "Start Debugging" button.
  5. Debugger mode was opened.
  6. Press the a, b, c, and e keys in an empty box.
  7. I tested the above steps for the "gff_amharic" keyboard and then observed the square box appeared.
    Please take a look at the screenshot below.
  • TEST_LDML_DEBUGGER (failed): 
    I installed the Keyman developer 18.0.117-alpha-test-12464 version and then started the configuration.
    On Keyman developer: 
  1. Create a new LDML project. 
  2. Navigate to the "Keyboards" tab.
  3. Click the *.xml link button to open the "View Source" *.xml file content.
  4. Navigation moved to the *.xml tab.
  5. Copy and paste any standard LDML keyboard content. (e.g. imperial_aramaic) 
  6. Save the changes.
  7. Press the F5 key to start the debugging mode.
  8. The debugger box appeared below the "view source" code.
  9. Press the a, b, c, and e keys in an empty box.
  10. I tested the above steps for the "imperial_aramaic" keyboard and then observed the square box appeared.
    Please refer to the screenshot below.
Note: This same project works well using the Keyman 18.0.122 alpha build. there is no square box appearing when typing a text.

@keymanapp-test-bot keymanapp-test-bot bot added user-test-failed and removed user-test-required User tests have not been completed labels Oct 8, 2024
@mcdurdin
Copy link
Member Author

mcdurdin commented Oct 9, 2024

@dinakaranr I think this is happening because you haven't selected a font for the test or 'characters' in the keyboard. If you choose an appropriate font (right-click on the test window to change font), you should find the characters displaying correctly. If you don't have an appropriate font available, you could install the font that is referenced in the corresponding .kps file, and use that.

@keymanapp-test-bot retest

@keymanapp-test-bot keymanapp-test-bot bot added user-test-required User tests have not been completed and removed user-test-failed labels Oct 9, 2024
Copy link
Contributor

@rc-swag rc-swag left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@dinakaranr
Copy link

Test Results

Okay. Thank you for the clarification. I retested this issue with the attached "18.0.117-alpha-test-12464" build on the Windows 10 and 11 OS. 

  • TEST_KMN_DEBUGGER (Passed):
  1. I installed the Keyman developer 18.0.117-alpha-test-12464 version and then started the configuration.
  2. On Keyman Developer, navigate to the "Keyboard" tab and then click the *.kmn link button to navigate to the build tab.
  3. Click the "Complie Keyboard" button.
  4. Click the "Start Debugging" button.
  5. Debugger mode was opened.
  6. Press the a, b, c, and e keys in an empty box.
  7. Select an appropriate font for the keyboard. (Noto serif Ethiopic - gff_amharic)
  8. I tested the above steps for the "gff_amharic" keyboard and then observed the text appeared
  • TEST_LDML_DEBUGGER (Passed):
    I installed the Keyman developer 18.0.117-alpha-test-12464 version and then started the configuration.
    On Keyman developer: 
  1. Create a new LDML project. 
  2. Navigate to the "Keyboards" tab.
  3. Click the *.xml link button to open the "View Source" *.xml file content.
  4. Navigation moved to the *.xml tab.
  5. Copy and paste any standard LDML keyboard content. (e.g. imperial_aramaic) 
  6. Save the changes.
  7. Press the F5 key to start the debugging mode.
  8. The debugger box appeared below the "view source" code.
  9. Select an appropriate font for the keyboard.(Noto Sans Imperial - imperial_aramaic)
  10. Press the a, b, c, and e keys in an empty box.
  11. I tested the above steps for the "imperial_aramaic" keyboard and observed text appeared.
    Please take a look at the screenshot below.

@keymanapp-test-bot keymanapp-test-bot bot removed the user-test-required User tests have not been completed label Oct 9, 2024
@mcdurdin mcdurdin merged commit 473fea9 into master Oct 9, 2024
6 checks passed
@mcdurdin mcdurdin deleted the fix/developer/12454-use-richedit-for-debugger-memo branch October 9, 2024 07:49
@keyman-server
Copy link
Collaborator

Changes in this pull request will be available for download in Keyman version 18.0.124-alpha

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

bug(developer): debug edit control should be a plain text richedit to support some render strings
5 participants