I don’t know how it helps but here’s some names in Irish that would be problematic
Parthalán Ó heachthairn
Tomás Ághas
Éinrí Eoin Ó beólláin
Máire Ní bhraonáin
Dainéil Ó buachalla
Should be
Parthalán Ó hEachthairn
Tomás Ághas
Éinrí Eoin Ó Beólláin
Máire Ní Bhraonáin
Dainéil Ó Buachalla
As you can see the Ó heac.. should be Ó hEac… etc.
Although there is a way to add an All Cap to a GREP style for characters after certain letters and conditions.. there is no way of predicting the pattern as it could be
MacTyson
McTyson
(or in Irish) Mac an Tí (son of Tighe)
Equally, for your example, it could be
O’conner/Mcmurphy should be O’Conner/McMurphy
It could be
O’Conner or O’ Conner – or it could be McMurphy or MacMurphy
Each having different spaces/letters between each.
You would need to build a “Smart Title Case” list with all the different variations – and you may come up against my own name in Irish which would be Eoin Mac an Tí
Which is a whole different set of problems.
I don’t see an easy way of doing it.