Discussion Forums  >  Status Bar, Navigation Bar

Replies: 4    Views: 320

Djdios
Lost but trying
Profile
Posts: 175
Reg: Mar 20, 2013
Valby, Denmark
3,550
09/19/13 12:06 PM (7 years ago)

Tab bar icons

Hi
2 questions.
How do you out there change an icon for your tab bar? So far I tried to change the icon at BT website and within Xcode by adding it to the BT_art (I have checked the pdf how to transfer files). Now it won't recognize the changed file. Is the only way to re-download the project?

I've also found a new icon set but the files are 25x25 and the previous was 16x16. The 25x25 looks great on the iPad simulator but looks pixelated on every other simulator. Is there a way to add different sizes of the icon, or is it a preferred size?
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
09/19/13 02:46 PM (7 years ago)
You place the Tab Bar icons in the BT_images directory.

http://www.idev101.com/code/User_Interface/sizes.html

Cheers!

-- Smug
 
Djdios
Lost but trying
Profile
Posts: 175
Reg: Mar 20, 2013
Valby, Denmark
3,550
like
09/23/13 01:49 AM (7 years ago)
So sorry to reply so late. I previosly added the icons in the Art folder and worked out finde, but you suggest to put them in the image folder? From the link you sent it says up to 30x30. I've used an icon which was 25x25 but it was still pixelated. What size do you prefer?
Thank you so much for your replies in several of my posts Smug.
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
09/23/13 02:25 AM (7 years ago)
When images are pixelated, that usually means you have a 30 x 30 icon on a retina display; it really should be 60 x 60 (or double the original icon file size), and named 'tabIcon@2x.png', where 'tabIcon.png' is the original 30 x 30 icon image file.

It's a little misleading. All of the image 'sizes' that it speaks of is correct for a non-retina display, but the images are showing iPhone 4/5, which are retina displays.

Make a new icon. Size it at 50 x 50. name it the same as your 25 x 25 and append it with '@2x' (so that 'tabIcon.png' becomes 'tabIcon@2x.png') and it should appear ok.

What happens internally (without anyone having to do anything) is xcode reads your code and comes across a requirement for 'tabIcon.png'. It looks at the device resolution, and determines whether it is a retina display or not. If it is a regular display, it uses 'tabIcon.png'. If it is a retina display (iPhone 4+), it looks for a file called 'tabIcon@2x.png' and if it finds it, it will use it, and things look great. If it does not find it, it will use 'tabIcon.png' - and will appear a little pixelated, because the image is being shown at twice it's original size.

With respect to location, as long as you correctly 'add' a file into your xcode bundle, it doesn't matter 'where' it actually resides. But images are 'typically' held in BT_images, for consistency sake. BT_art is for Application resources (icons and screens) and BT_images are for internal resources.

As long as 'you' know where they are, it really doesn't matter. But sometimes it's easier if you give fewer choices to newer users and have them commit to a certain workflow. In Buzztouch, that's our workflow. Until people realize it 'can' be different, BT gives them a strategy that ensures correct operation. Usually. :)

Cheers!

-- Smug

Edit: and you 'could' just use 'tabIcon@2x.png' in your BT Control panel, and it would turn out fine... for an iPhone 4+, but on the iPhone 3, and some iPads, the icons will be HUGE, so it's best to just keep it 'normal' if you plan to make your app available 'across the board'.
 
Djdios
Lost but trying
Profile
Posts: 175
Reg: Mar 20, 2013
Valby, Denmark
3,550
like
09/23/13 02:42 AM (7 years ago)
Thank you so much Smug, I will try it out and see how it goes.
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.