12207480 / TYPagerController

page scroll view and controller,simple,high custom,and have many tabBar styles,,support Objective-C and swift
MIT License
1.37k stars 232 forks source link

tabBar 选中字体 未按照配置的渲染 #117

Closed bluesky0109 closed 6 years ago

bluesky0109 commented 6 years ago
            fromCell.titleLabel.font = _normalTextFont;
            fromCell.titleLabel.textColor = _normalTextColor;
            fromCell.transform = CGAffineTransformMakeScale(_selectFontScale, _selectFontScale);
        }
        if (toCell) {
            toCell.titleLabel.font = **_selectedTextFont**;
            toCell.titleLabel.textColor = _selectedTextColor ? _selectedTextColor : _normalTextColor;
            toCell.transform = CGAffineTransformIdentity;
        }

toCell.titleLabel.font = _normalTextFont >>> toCell.titleLabel.font = _selectedTextFont ; 如上修正代码

12207480 commented 6 years ago

没有问题

bluesky0109 commented 6 years ago
 self.tabBar.layout.normalTextFont = [UIFont systemFontOfSize:17];
 self.tabBar.layout.selectedTextFont = [UIFont boldSystemFontOfSize:19];

如上 需要自定义 选中字体时,源码 在选中时 设置的还是 normalTextFont,外面自定义设置的并未生效。

12207480 commented 6 years ago

恩 因为字体是缩放selectedTextFont大小,所以这样设置不行