0 votes

Dear Paratext users,

We are working on a project and need to change the beginning of the verse from a lowercase letter to an uppercase letter through regex. If anyone is able to assist in this matter, I would appreciate it.

For example:

\v 15 and let them be for lights in the firmament of the heaven to give light upon the earth: and it was so.
\p
\v 16 And God made two great lights; the greater light to rule the day, and the lesser light to rule the night: \add he made\add* the stars also.
\p
\v 17 And God set them in the firmament of the heaven to give light upon the earth,
\p
\v 18 and to rule over the day and over the night, and to divide the light from the darkness: and God saw that \add it was\add* good.

Thanks with regards,

Thiyagarajan

Paratext by (110 points)

1 Answer

0 votes
This can be done by using the list feature of RegEx Pal. There is a discussion of this at:

https://support.bible/9271/using-a-list-for-replacing-in-regex-pal?show=9271#q9271

or you can search for "Using a list for replacing in RegEx Pal"

Your list of expressions might be something like:

(?<=(\\v \d+ ))a-->A

(?<=(\\v \d+ ))b-->B

(?<=(\\v \d+ ))e-->E

(?<=(\\v \d+ ))i-->I

(?<=(\\v \d+ ))p-->P

This says look for a lowercase letter preceded by \v digits space and change it to uppercase.
by (8.5k points)

It is greatly appreciated that you responded to me so promptly. Having checked these regex rules, I am pleased to report that they appear to work as expected.

Welcome to Support Bible, where you can ask questions and receive answers from other members of the community.
For just as each of us has one body with many members, and these members do not all have the same function, so in Christ we, though many, form one body, and each member belongs to all the others.
Romans 12:4-5
2,688 questions
5,457 answers
5,118 comments
1,523 users