Whitespace Correct tool
The Whitespace Correct tool cleans up whitespace in target translations. It can collapse repeated spaces, trim leading and trailing whitespace, match the source's leading/trailing whitespace onto the target, remove zero-width characters, and remove whitespace after specific punctuation marks. The last is particularly useful when translating from a space-delimited language into a non-space-delimited one such as Chinese or Japanese.
The tool operates only on the target text, so a target locale is required, and only blocks that already have a target for that locale are processed.
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
correctComma | boolean | true | Korriger mellomrom etter kommaer |
correctExclamation | boolean | true | Korriger mellomrom etter utropstegn |
correctFullStop | boolean | true | Korriger mellomrom etter punktum |
correctQuestion | boolean | true | Korriger mellomrom etter spørsmålstegn |
includeHorizontalWS | boolean | true | Inkluder horisontale tabulatortegn i rettelser |
includeVerticalWS | boolean | true | Inkluder vertikale mellomrom (linjeskift og vognretur) i rettelsene |
matchSourceWhitespace | boolean | true | Kopier innledende/avsluttende mellomrom fra kilde til mål |
normalizeSpaces | boolean | true | Slå sammen flere mellomrom til ett enkelt mellomrom |
removeZeroWidthChars | boolean | true | Fjern mellomrom med nullbredde og sammenbindere |
targetLocale | string | Mållokal for behandling | |
trimLeading | boolean | false | Fjern innledende mellomrom fra måltekst |
trimTrailing | boolean | false | Fjern etterfølgende mellomrom fra målteksten |
Configure it live
Examples
Normalize spacing for a locale
Apply the default whitespace cleanup to a target.
targetLocale: fr
Tidy CJK punctuation spacing
Remove spaces after punctuation for a non-space-delimited target.
targetLocale: zh-Hans
correctFullStop: true
correctComma: true
Processing notes
Operates on the target text only; a target locale is required and only existing targets are processed.
Punctuation correction removes the whitespace that immediately follows each enabled punctuation mark, limited to the included whitespace types.
← Back to the Tool Reference