Welcome, Guest
Username Password: Remember me

Regression between 1.5 and 1.6: sectionHeight much too large
(1 viewing) (1) Guest
  • Page:
  • 1

TOPIC: Regression between 1.5 and 1.6: sectionHeight much too large

Regression between 1.5 and 1.6: sectionHeight much too large 1 year, 6 months ago #1

I've an simple model with 3 SCTableViewCells. On touch, i dynamically add another section + a cell

The code is pretty straightforward:

 
- (void)showInfoText {
SCTableViewSection *infoSection = [SCTableViewSection sectionWithHeaderTitle:@""];
UIView *textLabel = [self prepareLabel:currentQuizElement.explanation font:[UIFont boldSystemFontOfSize:14]];
 
infoSection.headerView = textLabel;
infoSection.headerHeight = textLabel.height;
 
SCTableViewCell *infoCell = [SCTableViewCell cellWithText:currentQuizElement.urlText];
infoCell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;
[infoSection addCell:infoCell];
 
[tableModel addSection:infoSection];
[tableView insertSections:[NSIndexSet indexSetWithIndex:[tableModel indexForSection:infoSection]] withRowAnimation:UITableViewRowAnimationFade];
}
 


Now the funny thing, all worked with 1.5, but as i upgraded to the latest version the section are now huge, like 500 pixels. And this only happens in release mode. Totally curious why this happens. I didn't expected your framework and rewrote the prepareLabel function, to be really sure it returns the correct view. I can confirm now that this is the case. And after reverting to 1.5, everything works again (and the scrolling issue is also absent, see my other post).
  • steipete
  • OFFLINE
  • Junior Boarder
  • Posts: 21
  • Karma: 0

Re: Regression between 1.5 and 1.6: sectionHeight much too large 1 year, 6 months ago #2

Hi Peter,

We just recently discovered what seems to be a bug with Apple sizeWithFont method in release & ad-hoc modes only, and we modified our code to avoid it. The fix will be part of our next release, but I'll send you the latest update we now have and it should fix your problem.
  • tarekskr
  • OFFLINE
  • Administrator
  • Posts: 2404
  • Karma: 72

Re: Regression between 1.5 and 1.6: sectionHeight much too large 1 year, 6 months ago #3

Wow, I'm impressed. I will recommend your framework and your awesome instant service.
Thanks!
  • steipete
  • OFFLINE
  • Junior Boarder
  • Posts: 21
  • Karma: 0

Re: Regression between 1.5 and 1.6: sectionHeight much too large 1 year, 6 months ago #4

Thanks Peter
  • tarekskr
  • OFFLINE
  • Administrator
  • Posts: 2404
  • Karma: 72
  • Page:
  • 1
Time to create page: 1.46 seconds