Segmentation by underscore
Thread poster: Norma Fernández Suárez
Norma Fernández Suárez
Norma Fernández Suárez  Identity Verified
Local time: 06:15
English to Spanish
+ ...
Oct 4, 2017

Hello!!

I am currently translating a document that contains a lot of programming commands. I know you're not supposed to translate them, but my client is insisting on it. Therefore, I was wondering if anybody knows if it is possible to create a rule so that Trados segments these commands by underscores. E.g. I would like "DQ_EXCP_REASON" to be segmented into "DQ_", "EXCP_" and "REASON".
Is this something that can be done???

Please help me!
Thanks in advance!


 
Nora Diaz
Nora Diaz  Identity Verified
Mexico
Local time: 05:15
Member (2002)
English to Spanish
+ ...
Custom segmentation Oct 4, 2017

Hi Norma,

Yes, this is possible. In your TM settings, go to Language Resources - Segmentation Rules - Add. Enter a description for the new rule, then click Advanced View. In the Before break box, enter a dot followed by an underscore. In the After break box enter a dot. Close the segmentation rules dialog box and make sure that the TM that contains your new rule is at the top of the list in your Project Settings. Add your file to the project and prepare it, and that's it!

... See more
Hi Norma,

Yes, this is possible. In your TM settings, go to Language Resources - Segmentation Rules - Add. Enter a description for the new rule, then click Advanced View. In the Before break box, enter a dot followed by an underscore. In the After break box enter a dot. Close the segmentation rules dialog box and make sure that the TM that contains your new rule is at the top of the list in your Project Settings. Add your file to the project and prepare it, and that's it!

Here's what the rule should look like:
2017-10-04_075918

And here's what your file will look like:
2017-10-04_080215
Collapse


 
Norma Fernández Suárez
Norma Fernández Suárez  Identity Verified
Local time: 06:15
English to Spanish
+ ...
TOPIC STARTER
Worked like a charm! Oct 5, 2017

Thank you so very much for your prompt response and your invaluable assistance!!
You just saved me hours of work. You're a complete lifesaver!


 
CafeTran Training (X)
CafeTran Training (X)
Netherlands
Local time: 14:15
Isolating the underscores Oct 5, 2017

Very interesting! What would be the regex to isolate the underscores in separate segments?

 
Nora Diaz
Nora Diaz  Identity Verified
Mexico
Local time: 05:15
Member (2002)
English to Spanish
+ ...
Isolating the underscores: 2 rules Oct 5, 2017

To isolate the underscores, you would need two separate rules.

Rule 1:
Before the break, an underscore: _
After the break, a dot: .

Rule 2:
Before the break, a dot: .
After the break, an underscore: _

This would give the following result:

2017-10-05_070150


 
CafeTran Training (X)
CafeTran Training (X)
Netherlands
Local time: 14:15
Great! Oct 5, 2017

Nora Diaz wrote:

To isolate the underscores, you would need two separate rules.



Thank you, Nora!


 
Nora Diaz
Nora Diaz  Identity Verified
Mexico
Local time: 05:15
Member (2002)
English to Spanish
+ ...
: ) Oct 5, 2017

Happy to help!

 


To report site rules violations or get help, contact a site moderator:


You can also contact site staff by submitting a support request »

Segmentation by underscore







CafeTran Espresso
You've never met a CAT tool this clever!

Translate faster & easier, using a sophisticated CAT tool built by a translator / developer. Accept jobs from clients who use Trados, MemoQ, Wordfast & major CAT tools. Download and start using CafeTran Espresso -- for free

Buy now! »
Protemos translation business management system
Create your account in minutes, and start working! 3-month trial for agencies, and free for freelancers!

The system lets you keep client/vendor database, with contacts and rates, manage projects and assign jobs to vendors, issue invoices, track payments, store and manage project files, generate business reports on turnover profit per client/manager etc.

More info »