I checked out how we internally handle ReplaceAll in Misc/SearchOperations.cpp and for each file we handle the replacements in reverse order so that all match objects are calculated just once. That means using python replacement functions would need changes if we wanted to use them for renumbering things as that would require a new routine that works in spine order from top to bottom in each file, unlike our current C++ approach which is done for better efficiency and speed.
I still think renumbering is better done by Doitsu's excellent plugin anyway.
Last edited by KevinH; 03-24-2022 at 05:11 PM.
Reason: specify a good renumbering plugin!
|