Autocapitalize first letter of segment Thread poster: Spiros Doikas
| Spiros Doikas Local time: 17:16 Member (2002) English to Greek + ...
This is standard feature in most CAT tools I know, in Phrase, still sadly lacking. Does one know of any autohotkey script or any other way that would accomplish that? | | |
^+c:: Send, ^a Send, ^c ClipWait StringUpper, firstLetter, clipboard, T StringMid, restOfString, clipboard, 2 clipboard := firstLetter . restOfString Send, ^v return ``` This script still triggers with Ctrl+Shift+C. It selects all text, copies it to the clipboard, changes the first letter of the first word to uppercase, and then pastes the modified text. Not tested!
[Edited at 2024-03-13 15:23 GMT] | | | Spiros Doikas Local time: 17:16 Member (2002) English to Greek + ... TOPIC STARTER |
Sure. But you can also link the suggested macro—if it works at all—to the command to navigate to the next segment. | |
|
|
Stepan Konev Russian Federation Local time: 17:16 English to Russian AHK script to batch replace the first lowercase letter with uppercase one | Mar 13 |
I would do it in two steps. First, use a regex to filter segments starting with a lowercase only. I use this one: ^[а-я] but it is for the Cyrillic alphabet. You can use ^[a-z] or ^[a-ž] depending on your language. Second step is to run the following script (provided that you replace all Cyrillic pairs of letters with your language letters) with Win+R: #r:: InputBox,Var,Batch Replace List, How many times do you want to run the sequence? ... See more I would do it in two steps. First, use a regex to filter segments starting with a lowercase only. I use this one: ^[а-я] but it is for the Cyrillic alphabet. You can use ^[a-z] or ^[a-ž] depending on your language. Second step is to run the following script (provided that you replace all Cyrillic pairs of letters with your language letters) with Win+R: #r:: InputBox,Var,Batch Replace List, How many times do you want to run the sequence? loop, % Var {ClipSaved := ClipboardAll Clipboard = SendInput, ^a^c ClipWait, 30 FixString := Clipboard vList := " ;continuation section ( а А б Б в В г Г д Д е Е ё Ё ж Ж з З и И й Й к К л Л м М н Н о О п П р Р с С т Т у У ф Ф х Х ц Ц ч Ч ш Ш щ Щ ъ Ъ ы Ы ь Ь э Э ю Ю я Я )" Loop, Parse, vList, `n { oTemp := StrSplit(A_LoopField, "`t") FindWhat := "^\Q" . oTemp.1 . "\E" ; Match the lowercase letter only at the start of a line FixString := RegExReplace(FixString, FindWhat, oTemp.2) } oTemp := "" Clipboard := FixString ; load the new string to clipboard Sleep 200 Send ^v Sleep 200 SendInput, {Down} Sleep 200 } Return The downside of this method is that you need to know how many segments you have filtered out in step 1, which you can't know for sure with Phrase. Neither it shows the number of filtered segments, nor it has an option to move to the next segment with one keystroke. ▲ Collapse | | | Stepan Konev Russian Federation Local time: 17:16 English to Russian There must be tabs in between each pair of letters | Mar 13 |
*There must be tabs in between each pair of letters. Proz has changed tabs to spaces. | | | Spiros Doikas Local time: 17:16 Member (2002) English to Greek + ... TOPIC STARTER | There is no moderator assigned specifically to this forum. To report site rules violations or get help, please contact site staff » Autocapitalize first letter of segment Trados Business Manager Lite | Create customer quotes and invoices from within Trados Studio
Trados Business Manager Lite helps to simplify and speed up some of the daily tasks, such as invoicing and reporting, associated with running your freelance translation business.
More info » |
| Trados Studio 2022 Freelance | The leading translation software used by over 270,000 translators.
Designed with your feedback in mind, Trados Studio 2022 delivers an unrivalled, powerful desktop
and cloud solution, empowering you to work in the most efficient and cost-effective way.
More info » |
|
| | | | X Sign in to your ProZ.com account... | | | | | |