splitting text ranges based on their parent method/class