Bring Image or View to the Front

iPhone SDK Tips & Tricks

[self.view bringSubviewToFront:myImageView];

Other relevant function:

– bringSubviewToFront:
– sendSubviewToBack:
– insertSubview:atIndex:
– insertSubview:aboveSubview:
– insertSubview:belowSubview:
– exchangeSubviewAtIndex:withSubviewAtIndex:

add Image Border

iPhone SDK Tips & Tricks

#import <QuartzCore/QuartzCore.h>

[imageView.layer setBorderColor: [[UIColor blackColor] CGColor]];
[imageView.layer setBorderWidth: 2.0];