Before you start fixing anything, you really need to know if it is the chair or the floor that wobbles. If the chair only wobbles in one or two spots in the room, it is probably the floor that is out of line.
CHECKING THE FLOOR
To check the floor, either use a laser beam or a string line that gives you the same height off the floor on each end of the room. Run your tape measurer across the room and see if the distance from the floor changes, meaning that the floor is either rising up or dropping down. Floors are not always easy to straighten out although if the ceiling below is open you can shim up a low spot by driving a cedar shingle between the joist and the sub-floor.
CHECKING THE CHAIR
To get all four legs of a chair to sit flat, start by running strings across the diagonals like in the second photo. Do it twice, once with one string on top, again with the other on top. In one of those two arrangements, the strings could interfere with each other and give you a false sense of it being flat. If the two strings don't touch in the same way both times, you need to either lengthen a short leg, or shorten a long one.
You could put pins into the bottom of the legs, using little paper shims to make one longer than the other.
If you want to cut a bit off of a leg, clamp boards on the leg to be cut, that run over to the other legs. This gives you a guide for your saw that will be parallel to the floor. As an option, put the chair on a flat surface that you can scratch, like a large piece of plywood, or 4 plywood squares. Then run a thin saw (like a hacksaw without a frame) under the leg that is too long.
PROTECTING THE FLOOR FROM THE CHAIR
If your chair legs tend to dig into the floor, which usually happens when people lean back in a chair, make sure that the outer edge of the part touching the floor has been rounded off with a file or sandpaper. Removing that sharp edge can be all that is needed.
Don't use nails on underpads because when they wear, the nail will scratch the floor. Use either glue on pads, or socket pads. One trick for the glue on pads: on a fresh saw cut, or a sanded clean end of the leg, apply a good coat of contact cement and let it dry. This will now be an excellent primed surface for the self sticking felt pads to adhere to.