Take the 2-minute tour ×
Graphic Design Stack Exchange is a question and answer site for Graphic Design professionals, students, and enthusiasts. It's 100% free, no registration required.

I have a tricky text to style and I am having some issues, and need your help.

Example text:

2012 Some product name name, State $50 This is a very impressive young pinot, with tremendous freshness and vitality. Red cherry and spice aromas, fragrant and lifted with hints of coconut and cherry-liqueur. Elegant, medium-weight, fruit-driven and bright, with pinpoint ripeness. Succulent and utterly delicious. It should be long-lived. >1-10 (rating)

96

The text above repeats 50 times with different text, so essentially it's a list of 50 wines.

The resultant text should look like this:

*96 # Some product name name, State $50 This is a very impressive young pinot, with >tremendous freshness and vitality. Red cherry and spice aromas, fragrant and lifted with hints >of coconut and cherry-liqueur.

*Elegant, medium-weight, fruit-driven and bright, with pinpoint ripeness. Succulent and >utterly delicious. It should be long-lived. >1-10

*2012

Explanation: 2012 needs to move from the start to the end and the number 96 should go to the start. I think this is possible with GREP search but not with GREP style. I can style the two paragraphs with NESTED styles based on the period. Using NEXT styles I can repeat it 50 times for each listing.

However, I am having trouble switching the year and the listing number. I want to make it easier for a designer, so that she can use it with minimal number of clicks.

Could you please suggest something easier than using (\d{4})(.*)(\r|\n)(\d\d\r\Z) and replacing with $3$2$1 etc

share|improve this question

migrated from stackoverflow.com Jun 20 at 14:35

This question came from our site for professional and enthusiast programmers.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.