式守同学不只可爱而已

最后更新于 2023年09月11日

分类: 动漫 地区: 日本 年份:2022 

状态: 全剧完结 | 共12集

类型:爱情 动画 

导演:伊藤良太 山中祥平 

主演:大西沙织/梅田修一朗/松冈美里/日高里菜/冈本信彦/福原绫香//

又名:我家女友可不止可爱呢/ShikimorisNotJustaCutie

全剧完结 | 共12集

2022/日本/爱情,动画

豆瓣评分:6.9分

式守同学不只可爱而已剧情简介

" ]; UIColor *color = [UIColor colorWithRed:0.902f green:0.886f blue:0.863f alpha:1.0f]; self.tableView.backgroundColor = color; self.tableView.separatorColor = [UIColor clearColor]; self.tableView.separatorStyle = UITableViewCellSeparatorStyleNone;}- (void)viewDidLoad { [super viewDidLoad]; [self.tableView registerClass:[NewsTitleCell class] forCellReuseIdentifier:@"cell"]; [self.tableView registerClass:[UITableViewCell class] forCellReuseIdentifier:@"cellOther"];}#pragma mark - Table view data source- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { return _titleArr.count * 2;}- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { if (indexPath.row % 2 == 0) { NewsTitleCell *cell = [tableView dequeueReusableCellWithIdentifier:@"cell" forIndexPath:indexPath]; cell.selectionStyle = UITableViewCellSelectionStyleNone; cell.titleLabel.text = _titleArr[indexPath.row/2]; cell.summaryLabel.text = _summaryArr[indexPath.row/2]; return cell; } else { UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"cellOther" forIndexPath:indexPath]; cell.selectionStyle = UITableViewCellSelectionStyleNone; cell.textLabel.numberOfLines = 0; cell.textLabel.lineBreakMode = NSLineBreakByCharWrapping; cell.textLabel.text = _summaryArr[indexPath.row/2]; return cell; }}- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath { if (indexPath.row % 2 != 0) { return 40 [self calculateSizeWithString:_summaryArr[indexPath.row/2] font:[UIFont systemFontOfSize:14] maxW:kWindowW - 30].height; } else { return 80.0f; }}- (CGSize)calculateSizeWithString:(NSString *)string font:(UIFont *)font maxW:(CGFloat)maxW{ CGSize maxSize = CGSizeMake(maxW, MAXFLOAT); // 计算文字 CGRect rect = [string boundingRectWithSize:maxSize options:nil attributes:nil context:nil]; NSDictionary *dict = @{NSFontAttributeName : font}; CGRect rect = [string boundingRectWithSize:maxSize options:NSStringDrawingUsesLineFragmentOrigin attributes:dict context:nil]; CGSize size = rect.size; return size; }@end

猜你喜欢

空之音

2.0 2010/日本/剧情,动画

星猫历险记之名胜篇

6.0 2008/大陆/科幻,动画,儿童,冒险

妖怪手表

2.0 2014/日本/剧情,喜剧,动画