I am working at National library in Slovenia on the IMPACT project of digitazing and OCR books from 19th century. It aims to significantly improve access to historical text and to take away the barriers that stand in the way of the mass digitisation of the European cultural heritage.

We are working also with xml files - there are about 5.000 files.

We are changing (find-replace) some mistakes in them with Text crawler.

We have already correct some mistakes - background color, color of fonts, etc., but we can't find a simple Regular expression for finding and replacing these example:

find: <GraphicRegion id="r[0-9]*">
replace: <GraphicRegion id="r[0-9]* type="other">

The field [0-9]* shouldn't be changed
and the > should be chaged with type="other">

We have examples like this:
Find: <GraphicRegion id="r12">
Replace: <GraphicRegion id="r12" type="other">

Find: <GraphicRegion id="r42">
Replace: <GraphicRegion id="r42" type="other">

Find: <GraphicRegion id="r8">
Replace: <GraphicRegion id="r8" type="other">

Thank you for your help.