I have a multi-line UILabel that I want to enable zooming on.
I embedded it with a UIScrollView and set min zoom to .25 and max zoom to 4.
iOS 4+
- (void)scrollViewDidEndZooming:(UIScrollView *)scrollView withView:(UIView *)view atScale:(float)scale {
scrollView.contentScaleFactor = scale;
for (UIView *subview in scrollView.subviews) {
subview.contentScaleFactor = scale;
}
}
If this gets too intensive and performance is slow, just try setting the contentScaleFactor for only your labels.