I'm trying to create a UIButton where the facebook icon is a part of the centering, however i can't seem to figure out how to make it part of the centering process. So far i've just created a UIButton with the text. I could just create a image next to it, however then it will not be part of the centering.
You can easily set image and title both for your button for different control state like
normal,selected or highlighted etc.
So, set your image and title to your button from storyboard or programmatically there is no need to take separate
imageview for image.
You can set
edge insets for
image both from interface builder or programmatically. you can manage
top or bottom edge insets for title and image of button to manage it's vertical appearance!
check screen shot below,
Update : (as asked in comment)
this is the setup for my back button with image!