Release Notes for Trados Studio 2021 SR1
Integration API
Introduced enhancements to FilesController
The FilesController capabilities have been extended with support for the following:
- CurrentVisibleFiles - returns the list of project files that is currently displayed in the Files View
- CurrentSelectedLanguage - returns the currently selected language in the Files View
- SelectedFiles - marks as selected in the Files View the given list of Files
public bool SelectFileByName(string fileName)
{
var matchingFile = _filesController.CurrentVisibleFiles.FirstOrDefault(f => f.Name == fileName);
if (matchingFile != null)
{
_filesController.SelectFiles(new List<ProjectFile> { matchingFile });
return true;
}
return false;
}
Ability to delete all comments from the document
All active file comments can be deleted using IStudioDocument.DeleteAllCommentsWithoutNotification(). The user does not need to save the project explicitly as this method also saves the file.
Ability to retrieve the selected segment pairs from the editor
Exposed GetSelectedSegmentPairs method which returns a list of the selected segment pairs from the editor.
Ability to get the parent paragraph of a segment pair
Exposed GetParentParagraphUnit method which returns a clone of the ParentParagraphUnit of a SegmentPair.
Exposed the based url used for communicating with LC API
In order for a plugin to obtain the Language Cloud API URL used, it had to read the Trados Studio configuration file. We now expose the base URL for the Language Cloud API in the LanguageCloudIdentityApi class.
Ability to interact with track changes from the API
Via the IStudioDocument interface, third party developers can now use the following methods:
- AcceptAllTrackedChanges() - allows accepting all tracked changes and setting the confirmation level.
- SelectedSegmentsContainRevisions() - checks if the selected segments in target contains Revisions or TQA.
Ability to find and select a text from a given segment
Method FindTextInSegment returns true if a given text value is present in the specified segment number. It also has the ability to select the found text in the segment and bringing it into view. It can search in either the source or the target.
Ability to run a method on the UI thread through the Controllers
Developers can now marshal method execution on the UI thread if that is required using the BeginInvoke and Invoke method present on all the controllers, such as EditorController
Ability to control Concordance Search functionality.
Developers can now use the IConcordanceSearchController to obtain access to the Concordance Search functionality in the editor. They can now programatically perform searches in either source or target and read the results back. The controller can be obtained from the EditorController.ConcordanceSearchController property.
Ability to obtain the Translation Results
Developers can now use the ITranslationResultsController to obtain access to the translation results in the editor. They can now programatically select a result and apply it to the segment. The controller can be obtained from the EditorController.ConcordanceSearchController property.