Skip to content

Instantly share code, notes, and snippets.

@Kalgar
Kalgar / View Hierarchy - iOS
Created March 24, 2011 04:37
iOS function for dumping view hierarchy
***************************************************************************************************
DISCLAIMER:
I did not write this, I found it on Stack Overflow attributed to user Sophtware. Finding it useful, I decided to save this here, in case SO deleted the page (since the question was closed as a non-question)
***************************************************************************************************
void dumpViews(UIView* view, NSString *text, NSString *indent)
{
Class cl = [view class];
NSString *classDescription = [cl description];