Suggestion: Component::begin() ::end()


Component::begin() end() for standard C++ iteration through child-components


It’s tempting, but I’ve resisted it because it seems like that are only a small number of contexts where this’d be useful, and it may lure people into doing silly things, e.g. if you delete, remove or change the z-order of any child components in the middle of the loop, bad things will happen…


…just a note on this: I searched the entire juce codebase with a regex to look for any for loops that iterate a component’s children in the natural oder, and only found about 10 places where this happens.