mirror of
https://github.com/NickeManarin/ScreenToGif.git
synced 2026-04-25 23:25:52 +03:00
[PR #1125] [MERGED] Removes 'key translation' when getting key text #1315
Labels
No labels
copy cats
duplicated
future feature
pull-request
⬜ Accepted
⬜ Completed
⬜ Help Wanted 💪
⬜ In Progress
⬜ Missing Details
⬜ Pending
⬜ Waiting For Answer ⏳
🆕 feature preview
🔷 Bug 🐛
🔷 Out Of Scope
🔷 Out Of Scope
🔷 Question
🔷Enhancement
🔷Enhancement
🔷Invalid / External
🔷Knowledge Base
🔷Won't Fix
🕑 High
🕑 High
🕑 High
🕕 Medium
🕙 Low
🕛 Critical
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/ScreenToGif#1315
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/NickeManarin/ScreenToGif/pull/1125
Author: @jfbueno
Created: 6/22/2022
Status: ✅ Merged
Merged: 7/10/2022
Merged by: @NickeManarin
Base:
dev← Head:bugfix/1122📝 Commits (1)
a48e29cRemoving 'key translation' when getting key text📊 Changes
1 file changed (+3 additions, -30 deletions)
View changed files
📝
ScreenToGif.Native/Helpers/Other.cs(+3 -30)📄 Description
This PR removes the "key translation" that is done when obtaining the key text.
I guess this translation was needed because
-1was considered an invalid result from theToUnicodeAPI (in theGetCharFromKeymethod). However, this result represents dead keys - which looks like the root of the problem here - and should be considered valid. It says that a dead key was pressed and the spacing version of that dead key was written to the output buffer, ie it'll write~even with just one click (in an ABNT2 Portuguese keyboard).Here's the section of the documentation that explains the possible results.
This fixes #1122
The problem in this issue is specific to one specific case in this translation tho. The OEM 7 key is a quote in the US standard keyboard layout, but it's translated to a comma.
File: Other.cs
I thought it would be better to fix it to make it work in all keyboard layouts.
I didn't write any unit tests because I couldn't think of any way of doing that without changing the OS keyboard layout.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.