Question: As illustrated, what I need to achieve is when swiping left, a button with an image shows up, the blue one, and when swiping right the green button shows up, how to do this? i use swift and xcode 6.4

This is what i tried before asking, I was able to show two options with text in the right of a cell, but i don't want that, what is needed is in the illustration, and as said, the buttons need to be images not text.

[![enter image description here](https://i.stack.imgur.com/A1T7C.png)](https://i.stack.imgur.com/A1T7C.png)

Answer: 
If you want to use library for such function, i would suggest you to use 
<https://github.com/MortimerGoro/MGSwipeTableCell> ...

its easy to use and easy customise.
The overall idea is simple - your cell's content view is a `UIScrollView` with views on the sides.

However, the complete working solution is a bit complicated and probably too broad for an answer.

I would recommend you to start with an already implemented solution, e.g. [SWTableViewCell](https://github.com/CEWendel/SWTableViewCell) (but there are others) and look into the source code. Or just use it directly. Most of the solutions can be installed using `cocoapods` and they work both in Swift and Objective-C.