Predelnik / DSpellCheck

Notepad++ Spell-checking Plug-in
GNU General Public License v2.0
198 stars 33 forks source link

Option to Capitalize Word (Perhaps in Additonal Actions) #279

Closed MadokaAyukawa closed 8 months ago

MadokaAyukawa commented 2 years ago

I work on a lot of English subtitles for foreign films/dramas. As such I have a lot of foreign names of people and places that DSC does not recognize. Often times, these proper names are not capitalized for some reason. DSC will recognize them as a misspelled word, but will suggest a wrong word as the names aren't misspelled.

It would be nice to have an option in the additional actions to Capitalize Word at Cursor, which would also capitalize all instances in the document (just the first letter, not all caps). Or it can be Change Case, going from upper to lower and vice versa, again all instances. It would also be useful in the drop down suggestion box, but that may be harder to implement; additional actions would be good enough as I could bind a hotkey to it. I don't know how hard this would be either way, but hopefully you will consider it. Thank you.

Predelnik commented 2 years ago

Maybe I misunderstand the problem but Replace all with in context menu should just do it if correct capitalization is in suggestion, for example: image Maybe I don't understand why correct capitalization is not in suggestions in your case, if so could you provide more concrete example.

MadokaAyukawa commented 2 years ago

In your example, Dave is a known correct capitalized word. I work with a lot of foreign scripts with foreign names that are recognized as a misspelling in English, but there's no correct capitalized suggestion. In the example below, Madoka is a Japanese name that should be capitalized and Gwangju is a Korean city. They are recognized as misspelled, but no correct spelling is suggested. They are spelled correctly except for the capitalization. This could be an option in the settings to "always suggest a capitalized version of the misspelled word" so people who don't need this don't have extra suggestions.

image

image

Predelnik commented 2 years ago

Always suggest capitalized spelling is possible I guess but I'm curious why are you not adding capitalized versions of them in user dictionary though? (in that case they should appear in suggestions)

MadokaAyukawa commented 2 years ago

I use an English dictionary so these foreign names are unknown. I don't know if I can get a dictionary of foreign names in English. I could add them I guess, but there are just hundreds of names/words I run across. I actually made a custom dictionary of common Japanese names, and I still run into lots of unknown names.

MadokaAyukawa commented 2 years ago

I made a custom dictionary for Korean cities. And maybe it's supposed to work this way. So DSC now sees the capitalized Gwangju as spelled correctly and the lowercase gwangju as misspelled, but it doesn't suggest the capitalized Gwangju in the drop down menu.

image

Predelnik commented 2 years ago

Well that should work for Hunspell but might not work with Native spell-checker unfortunately.

MadokaAyukawa commented 2 years ago

I see; thank you. I can't seem to get the custom dictionaries to work with Hunspell. I'll stick with Native for now then.