I am using UIRefreshControl to implement pull down to refresh in my IOS app. It works fine. But after a few refreshes say for exactly third or fourth one it crops the title a bit and immediately it gets misaligned. Please check the attached images for screen shots
I am using the UIrefresh Control in different screens. Every screen is showing the same behaviour. Some of them are UITableViewControllers and some others are having UITableView inside a UIViewController.
Here is the code how I create the title for UIRefreshControl
NSString *titleStr = [NSString stringWithFormat:@"Last updated at %@",[appDelegate getLastUpdatedDate]];
NSMutableAttributedString *title = [[NSMutableAttributedString alloc] initWithString:titleStr];
[title addAttribute:NSForegroundColorAttributeName value:[UIColor redColor] range:NSMakeRange(0, titleStr.length)];
self.refreshControl.attributedTitle = title;
The misalignment and cropping happens while its refreshing. It becomes normal once the refresh is finished.
How to make this work properly?
Thanks