0
강조 표시 될 때 UITabBarItem의 이미지와 텍스트 위치를 변경해야합니다. 가능한가?UITabBarItem 위치를 변경하는 방법은 무엇입니까?
강조 표시 될 때 UITabBarItem의 이미지와 텍스트 위치를 변경해야합니다. 가능한가?UITabBarItem 위치를 변경하는 방법은 무엇입니까?
UITabBarItem의 이미지 위치를 바꿀 방법이없는 것처럼 보입니다. 난 그냥 버튼을 약 15 픽셀이 내 선택한 이미지를 수정하고 한 tabBar 15에 UITabBarItem 제목의 위치를 수정 : didSelectItem : 내 사용자 지정의 방법 UITabBarController가 :
- (void)tabBar:(UITabBar *)tabBar didSelectItem:(UITabBarItem *)item
{
// If there is another selected item set default properties to it.
for (int counter = 0; counter < [self.tabBar.items count]; counter++) {
UITabBarItem *currentSelectedItem = [self.tabBar.items objectAtIndex:counter];
[currentSelectedItem setTitlePositionAdjustment:UIOffsetMake(0, 0)];
}
// Set selected item.
UITabBarItem *selectedItem = item;
[selectedItem setTitlePositionAdjustment:UIOffsetMake(0, -15)];
}