Skip to content

Commit

Permalink
Add ḱ to PowerAccent for Proto-Indo-European
Browse files Browse the repository at this point in the history
  • Loading branch information
Hao Liu (from Dev Box) committed Dec 13, 2024
1 parent f19a34d commit 31ade5c
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 0 deletions.
13 changes: 13 additions & 0 deletions src/modules/poweraccent/PowerAccent.Core/Languages.cs
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ public enum Language
NL,
NO,
PI,
PIE,
PL,
PT,
RO,
Expand Down Expand Up @@ -100,6 +101,7 @@ public static string[] GetDefaultLetterKey(LetterKey letter, Language[] langs)
Language.NL => GetDefaultLetterKeyNL(letter), // Dutch
Language.NO => GetDefaultLetterKeyNO(letter), // Norwegian
Language.PI => GetDefaultLetterKeyPI(letter), // Pinyin
Language.PIE => GetDefaultLetterKeyPIE(letter), // Proto-Indo-European

Check failure

Code scanning / check-spelling

Unrecognized Spelling Error

Indo is not a recognized word. (unrecognized-spelling)
Language.PL => GetDefaultLetterKeyPL(letter), // Polish
Language.PT => GetDefaultLetterKeyPT(letter), // Portuguese
Language.RO => GetDefaultLetterKeyRO(letter), // Romanian
Expand Down Expand Up @@ -156,6 +158,7 @@ private static string[] GetDefaultLetterKeyALL(LetterKey letter)
.Union(GetDefaultLetterKeyNO(letter))
.Union(GetDefaultLetterKeyPI(letter))
.Union(GetDefaultLetterKeyPL(letter))
.Union(GetDefaultLetterKeyPIE(letter))
.Union(GetDefaultLetterKeyPT(letter))
.Union(GetDefaultLetterKeyRO(letter))
.Union(GetDefaultLetterKeySK(letter))
Expand Down Expand Up @@ -463,6 +466,16 @@ private static string[] GetDefaultLetterKeyPI(LetterKey letter)
};
}

// Proto-Indo-European

Check failure

Code scanning / check-spelling

Unrecognized Spelling Error

Indo is not a recognized word. (unrecognized-spelling)
private static string[] GetDefaultLetterKeyPIE(LetterKey letter)
{
return letter switch
{
LetterKey.VK_K => new[] { "ḱ" },
_ => Array.Empty<string>(),
};
}

// Turkish
private static string[] GetDefaultLetterKeyTK(LetterKey letter)
{
Expand Down
3 changes: 3 additions & 0 deletions src/settings-ui/Settings.UI/Strings/en-us/Resources.resw
Original file line number Diff line number Diff line change
Expand Up @@ -3672,6 +3672,9 @@ Activate by holding the key for the character you want to add an accent to, then
<data name="QuickAccent_SelectedLanguage_Pinyin" xml:space="preserve">
<value>Pinyin</value>
</data>
<data name="QuickAccent_SelectedLanguage_Proto_Indo_European" xml:space="preserve">

Check failure

Code scanning / check-spelling

Unrecognized Spelling Error

Indo is not a recognized word. (unrecognized-spelling)
<value>Proto Indo European</value>

Check failure

Code scanning / check-spelling

Unrecognized Spelling Error

Indo is not a recognized word. (unrecognized-spelling)
</data>
<data name="QuickAccent_SelectedLanguage_Polish" xml:space="preserve">
<value>Polish</value>
</data>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ public class PowerAccentViewModel : Observable
new PowerAccentLanguageModel("MI", "QuickAccent_SelectedLanguage_Maori", LanguageGroup),
new PowerAccentLanguageModel("NO", "QuickAccent_SelectedLanguage_Norwegian", LanguageGroup),
new PowerAccentLanguageModel("PI", "QuickAccent_SelectedLanguage_Pinyin", LanguageGroup),
new PowerAccentLanguageModel("PIE", "QuickAccent_SelectedLanguage_Proto_Indo_European", LanguageGroup),

Check failure

Code scanning / check-spelling

Unrecognized Spelling Error

Indo is not a recognized word. (unrecognized-spelling)
new PowerAccentLanguageModel("PL", "QuickAccent_SelectedLanguage_Polish", LanguageGroup),
new PowerAccentLanguageModel("PT", "QuickAccent_SelectedLanguage_Portuguese", LanguageGroup),
new PowerAccentLanguageModel("RO", "QuickAccent_SelectedLanguage_Romanian", LanguageGroup),
Expand Down

1 comment on commit 31ade5c

@github-actions
Copy link

Choose a reason for hiding this comment

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

@check-spelling-bot Report

🔴 Please review

See the 📜action log or 📝 job summary for details.

Unrecognized words (1)

Indo

These words are not needed and should be removed accctrl aclapi appdata Appium appmodel atlbase atlcom atlfile atlstr bootstrapper caniuse ceq cguid Cmds cne codicon comdef commandline commctrl commdlg comutil consts cppwinrt CRSEL crx dcommon dcomp DCs desktopwindowxamlsource devpkey dxgidebug dxgiformat emmintrin Emoji endpointvolume evntrace exdisp Functiondiscoverykeys guiddef hinstance hstring Intelli junja Knownfolders lmcons LONGLONG lpt LTRB mfapi mfidl mfobjects mftransform Minimatch mmdeviceapi mmsystem msedge msiquery newdev nodoc notlike Objbase objidl pathcch Pnp Preinstalled processthreadsapi propkey propvarutil redistributable Renamer reparse restrictederrorinfo roadmap ruleset runtimes shellapi shellscalingapi shldisp shlobj stl strsafe strutil subquery SWC tailwindcss tapp thumbcache tlhelp Toolset touchpad Tsd uninstantiated uniquifier Unknwn unregistering urlmon USERDATA Uxtheme verrsrc wcautil wincodec Wincodecsdk windef windowsapp windowsx winerror winevt winsdkver winternl wsl wtsapi

To accept these unrecognized words as correct and remove the previously acknowledged and now absent words, you could run the following commands

... in a clone of the [email protected]:microsoft/PowerToys.git repository
on the dev/haoliuu/updatePowerAccent branch (ℹ️ how do I use this?):

curl -s -S -L 'https://raw.githubusercontent.com/check-spelling/check-spelling/v0.0.24/apply.pl' |
perl - 'https://github.com/microsoft/PowerToys/actions/runs/12310099255/attempts/1'
If the flagged items are 🤯 false positives

If items relate to a ...

  • binary file (or some other file you wouldn't want to check at all).

    Please add a file path to the excludes.txt file matching the containing file.

    File paths are Perl 5 Regular Expressions - you can test yours before committing to verify it will match your files.

    ^ refers to the file's path from the root of the repository, so ^README\.md$ would exclude README.md (on whichever branch you're using).

  • well-formed pattern.

    If you can write a pattern that would match it,
    try adding it to the patterns.txt file.

    Patterns are Perl 5 Regular Expressions - you can test yours before committing to verify it will match your lines.

    Note that patterns can't match multiline strings.

Please sign in to comment.