Hide / Unhide Text tool makes it easy to hide text from your CAT tool when only parts of your document need to be translated or to convert non-translatable text into tags.
- How Hide / Unhide Text tool can help you in your work
- Where to find the tool
- Using Hide / Unhide Text tool
- Related tools
How Hide / Unhide Text tool can help you in your work
- Translate text added in a previously translated document: sometimes the customer provides a document where the text to be translated is inserted among existing text and marked with a specific color. Such text is often scattered around the document and it is difficult to extract it into a new document for translation. In order to translate this text and ignore all the other text, choose Hide everything except specific text, select Highlight Color or Font Color depending on the type of color used to mark translatable text, and choose the specific color from the dropdown list.
- Create a dual-language document: if you need to deliver a dual-language document where the original text is next to its translation, the easiest method is to place a copy of the original text next to the original (by using a two-column table or a special delimiter like “/”), mark the copy with a specific color, and then hide the original using Hide everything except specific text option of Hide / Unhide Text tool. To prepare documents for dual-language translation quickly, you can use Dual-Language Document Assistant tool.
- Ignore specific parts of the document: sometimes you don't need to translate the entire document. For example, you may need to translate only specific sections while the remaining sections are still being revised. It is also common to skip standard sections which are identical in all customer documents. In this case mark all non-translatable parts with a certain highlight color or font color, choose Hide specific text only option, select the right color, and click Hide Text button.
- Hide sensitive parts of the document: you can hide specific names and numbers and then import the document into your CAT tool. The hidden text will be converted into tags. Some CAT tools do not display the content of these tags to the translator, and it is also possible to export the file to XLIFF format and import it into another CAT tool which will hide the content of these tags. You can use this workflow with some CAT tools only, so you should test it beforehand.
- Skip specific parts of a document – sometimes the customer does not want to translate textboxes, comments, headers/footers, etc. In this case you can select Hide specific text only option and choose these content types in order to hide them from the CAT tool.
- New in version 1.2: you can process multiple Word documents with Hide / Unhide Text tool by using Document Processing Tool. Click here for more information about this tool.
Download TransTools+ brochure to see real-life examples of how Hide / Unhide Text tool and other TransTools+ features can help you increase quality and productivity.
Where to find the tool
To run Hide / Unhide Text tool, click Hide / Unhide Text button on TransTools+ ribbon:
This will open Hide / Unhide Text tool pane to the right of the current document.
Using Hide / Unhide Text tool
How the tool “hides” text from your CAT tool
Most CAT tools provide a way to skip non-translatable text in Word documents or display it as tags if this text is marked with special formatting. For most CAT tools, this is “Hidden Text” font attribute. By using this feature, you can skip original text in dual-language documents where two languages should appear side by side, translate new text added in a previously translated document, skip non-translatable text in various text-based documents such as subtitles or scripts, or convert various placeholders into tags in localization documents.
How hidden text is displayed inside Microsoft Word
Scope: Select Entire Document to process the entire document, including headers / footers, comments, footnotes, etc. Select Selection to process selected text only.
What do you want to do? – the tool provides 3 ways to process a document:
Hide everything except specific text – when this option is selected, the tool leaves the found text visible, but hides everything else. This option is commonly used to translate text formatted with a certain color.
Hide specific text only – when this option is selected, the tool hides all found text and leaves everything else visible. Use this option if the customer marked non-translatable text with a specific color, or if you want to skip specific parts of the document or convert them into tags in your CAT tool.
This option has additional options:
When you click the (options) link, you will see the following dialogue:
By default, if the document already contains hidden text, Hide / Unhide Text tool remembers where this text is located and clears its hidden formatting before hiding text according to your options (the hidden formatting is restored when you run the tool with Unhide everything option activated). This way you can translate this text in your CAT tool if necessary. However, in some cases you will need to run Hide / Unhide Text tool several times, and in such cases you will want to preserve hidden formatting which was applied during previous hiding operations. In such cases, use the second option called Do not clear existing hidden formatting....
Unhide everything – use this option after the translated document is generated to unhide all the text in the document.
Hide text using... / Text was hidden using...: While most CAT tools consider hidden text as non-translatable, some CAT tools do not. In addition to hidden text attribute, you can choose “Marching Red Ants” and “Double Strikethrough” formatting, which are supported by Wordfast Classic as non-translatable text attribute.
Hide Text / Unhide Text – this button hides the text in the document based on the options, or unhides all text in the current scope, depending on the selected action.
Hiding options – By text color
To hide text based on its color, select Hide By Color from the Hiding Options dropdown list:
If the text to be hidden / translated has color highlighting, select Highlight Color and then choose Any Color for any highlight color or pick a specific color from the dropdown list.
If the text to be hidden / translated has a specific font color, select Font Color and then choose the specific font color from the list.
If the color is not in the list or it is difficult to find the right color inside the list, you can select the text that has the right color inside the document and then choose Selection Color from the dropdown list. This will copy the color from the document.
If the text that needs to be hidden or translated is marked in several different colors, you can select multiple colors. To do this, first select a specific color in the dropdown list and then check Use Multiple Colors checkbox. When you do this, you will be able to add colors to the list using Add button, or remove individual colors using Remove button. Uncheck this checkbox if you want to use a single color or leave a single color in the list.
Hiding options – By text or regular expressions
To hide text based on specific text matches found inside the document, select By text or regular expressions from the Hiding Options dropdown list:
In this mode, the tool finds the text that matches the search items in the list. There are two types of search items: standard text items () and regular expression items ():
Standard text items describe the parameters for finding text using Microsoft Word’s text search options.
To use standard text search, select Text option button in the Item Editor.
In the Find What field, enter the text search string. You can insert special symbols such as ^l for manual line break by clicking Insert... button or typing the appropriate code. To make the expression easier to read, you can change the font size by clicking the buttons to the right of the Find What field.
Check Match Case checkbox to perform case-sensitive text search.
Check Find Whole Words Only checkbox if the text must match full words, i.e. without spanning only part of a word. For example, this is useful for finding the singular form of a noun: if you enter “spider” and check Find Whole Words Only checkbox, the tool will find “spider”, but not “spiders”.
Check Use Wildcards checkbox if you want to use Word’s special wildcard symbols. When this checkbox is checked, Insert... button allows you to insert special wildcard codes.
In the Description field, you can add a short note to make it easier to understand what kind of text will be found by the expression.
Regular expression items describe the parameters for finding text using Microsoft .NET regular expression mechanism. NOTE: The search is conducted in each individual paragraph, so this type of search can only be used when the match (i.e. text described by the regular expression) does not span several paragraphs, i.e. it is located inside a single paragraph.
To use regular expression search, select Regular Expression option button in the Item Editor.
In the Find What field, enter the search string. You can insert regular expression operators and constructs by clicking Insert... button. To make the expression easier to read, you can change the font size by clicking the buttons to the right of the Find What field.
Uncheck Match Case checkbox if the regular expression must be case-insensitive (regular expressions are case-sensitive by default).
If your regular expression contains a capturing group, you can match the text found by this capturing group instead of the text found by the entire regular expression. To do this, check “Find capturing group...” checkbox and then select the sequential number of the group from the dropdown list.
In the Description field, you can add a short note to make it easier to understand what kind of text will be found by the expression.
Editing the search entries: Click Add button to add a new entry to the current list. Edit button allows you to edit the selected entry. Remove button removes entries which were selected in the list. Clear button removes all entries currently displayed in the list. You need to click Save button in order to record these changes in the file where the appropriate list is stored.
To create a new list, make sure that [New List] is selected in the dropdown list, then add entries using Add button or import entries from another list, external file or clipboard by using Import button. Then save the changes using Save button or export the search entries by clicking Export button. An alternative method is to click Create New List button located to the right of the dropdown list, assign a name to the new list, and then add entries to it.
To use search entries from an existing list, select the list from the dropdown list, or click the right-most button (Open) to open a list stored in an external file. If you need to use several search entries only, simply remove the unneeded entries using Remove button. The changes will not be recorded in the appropriate list file unless you click Save button.
To make changes to an existing list, simply select the list from the dropdown list or click Open File button on the right-hand side to load an external file. Make the appropriate changes and then click Save button to update the corresponding file on disk.
In order to copy search entries from one list to another or from / to external applications like Microsoft Excel, you can use Import and Export buttons:
- Import button loads search entries from a named list file, external file or clipboard and places them at the end of the list:
If you choose Import from clipboard option, you need to make sure that the text located on the clipboard is in the correct format (you can save an existing list to clipboard to see the expected format).
- Export button copies the current search entries to a named list file, external file or clipboard:
If you export to an existing list in the tool's internal configuration file, the contents of the file will be overwritten with current search entries.
You can test whether the tool can find correct text by clicking Find Next Match button. The tool will find the first match after the current selection point, wrapping to the beginning of the document if it reaches the end of the document.
You can also highlight found text in order to see which text was found during the hiding operation or to manipulate this text later. To do this, check Also Highlight Found Text checkbox and then select the highlight color from the dropdown list:
If there is an overlap between two matches for different search items, the earlier match is kept and the later match is discarded.
Hide / Unhide Text tool is provided with several pre-defined lists of search expressions which you can use to prepare documents for translation. The following lists are provided:
- SRT (SubRip Text) files – this list uses a number of regular expressions to hide non-translatable text (time codes and formatting codes) in SRT subtitles. To translate such subtitles, copy the text from an SRT file or open it inside Microsoft Word, load this list, then select Hide specific text only option and click Hide text button.
- HTML and HTML - Translatable attributes – these lists use several regular expressions to hide non-translatable text in HTML files. If you want to translate HTML files, you will need to follow these steps to make sure that all non-translatable text is hidden correctly:
- Select Hide specific text only option. Clear the item list, load pre-defined HTML list by clicking Load... button, check Also Highlight Found Text checkbox and select Red highlight color. Click Hide Text button to highlight and hide the found text. This action will highlight HTML tags and entities using Red color.
- Select Hide specific text only option. Clear the item list, load pre-defined HTML - Translatable attributes list by clicking Load... button, check Also Highlight Found Text checkbox and select Bright green highlight color. Click Hide Text button to highlight and hide the found text. When you see Hidden Formatting Warning dialogue, leave the first option selected and click Continue. This action will highlight translatable text inside HTML tags using Bright Green color.
- Go through the document and mark additional non-translatable text using Red highlight color. For example, you will need to mark all text from <head> up to </head> at the top of the document, leaving existing Bright Green text untouched.
- At this point, all non-translatable text will be hightlighted in red. Select Hide specific text only option and select Hide by color from Hiding Options dropdown list. Choose Highlight Color option and select Red from the dropdown list. Click Hide Text button. When you see Hidden Formatting Warning dialogue, leave the first option selected and click Continue.
- Now all non-translatable text will be hidden and the document will be ready for CAT tool import. NOTE: This procedure hides HTML entities such as (non-breaking space), ” (”), etc., turning these sequences into tags in your CAT tool. It is better to replace these characters with the actual symbols as the very first step, and convert them back to HTML entities when the translation is finished.
- XML – this list uses a number of regular expressions to hide non-translatable text in XML files. To translate such files, copy the text from an XML file or open it inside Microsoft Word, load this list, then select Hide specific text only option and click Hide text button. NOTE: Translatable attributes inside XML tags will be hidden, so if you want to translate them, you can use a multi-step procedure similar to the above procedure for HTML files.
- Non-translatable paragraphs – this simple list allows you hide paragraphs that consist entirely of non-translatable text such as numbers without decimal point or thousand separators. Naturally, such paragraphs will hinder translation, especially if there are a lot of them, so it is a good idea to hide them. You can extend this list with your own custom expressions. To hide non-translatable paragraphs, load this list, then select Hide specific text only option and click Hide text button.
Hiding options – By type of content
To hide text based on type of content, select Hide by type of content from the Hiding Options dropdown list:
The tool supports 6 types of content in Microsoft Word documents: document body (where almost all text is normally placed), comments (comment balloons next to commented text), footnotes, headers and footers, textboxes, and endnotes.
Tools for partial (selective) translation
- Dual-Language Document Assistant – prepare documents for translation into dual-language format
- Hide / Unhide Text – mark text as non-translatable in order to hide it from your CAT tool
- Highlighting Tool – simplify editing work: apply color highlighting, clear color highlighting, or find color highlighting
- Document Processing Tool – perform various actions on multiple Word documents (DOCX, DOC, RTF format), using one or several different TransTools+ commands one after the other.