Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

moonman239

Cancelled
Original poster
Mar 27, 2009
1,541
32
I just put in an image for a new button. This image is for both when the button is not selected and when it is. However, when I go to run my app on a device, I see a blue ellipse in the image's place. To make matters worse, I can't find any reference to an ellipse anywhere within my project.

The image is a PNG file, and it renders correctly on my computer.

Will someone please tell me how to fix this? Thanks.
 
Last edited:
It's difficult to say. Do you have a screenshot of what you're seeing?

Also, how are you setting the image, programmatically or via storyboard?
 
That blue outline is the default appearance of a button of type Custom that has a title but no image. How are you configuring the button? (code or IB?)
 
OK, that's not the default outline I was thinking of. So are there two buttons in the screenshots? The blue ellipse and the back button to its right? If so what's the difference between the two? If the button is completely configured in IB then show us a screenshot of the configuration screen for the button.
 
OK, that's not the default outline I was thinking of. So are there two buttons in the screenshots? The blue ellipse and the back button to its right? If so what's the difference between the two? If the button is completely configured in IB then show us a screenshot of the configuration screen for the button.

Yes, there are two buttons. The "back" button takes the user back to the previous screen, while the button in question tells an AVPlayer to repeat the last file it played.
Edit: Here is a screenshot: https://drive.google.com/open?id=0BxWy5I3ibO--Yi1Nc2JYdVVfWFE

Edit #2: I found a potential solution on Stack Overflow (link to question) One of the answers suggest checking the RGB profile - could this be the solution?

Edit #3: Didn't work.
 
Last edited:
So what are those slashes in the button image name? UIButton loads its images with image(named: ) Is the button image in your xcassets? Also, I would not have spaces in the image file name.
 
UPDATE: Solved!! The solution was for me to go into Preview and set the color space of the image to sRGB.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.