Exactly. Take a measurement when the implement is level with the PTO shaft from your tractor (with the shaft removed from the tractor and implement). That is the closest the two points will be, the shaft from the gear box and the PTO on the tractor.
An easy way to do this is to remove the plastic housing from the PTO shaft and measure it completely closed, telescoped all the way in. If that length is too long from your previous measurement, then you will need to trim, from both parts of the shaft, equal amounts. Measure again. (always measure again! Measure, go have a cup of coffee, come back and measure again.)
Now measure the shaft with about 3 inches of overlap. Extend the shaft. I wouldn't go less than that. Some manuals say 2in, whatever, but I prefer 3".
Measure the distance between the gear box shaft on the implement to the PTO on the tractor when the implement is at its highest, and lowest points. Remember that the implement will likely go further down than on level ground, find a hill or jack the rear of the tractor to get the 3pt all the way down. Those two distances should not exceed the length of your trimmed PTO shaft. If it does, then you either took too much off or your PTO shaft, or is completely wrong. Ether way, you will need a new one.
It also should be noted that most new shafts go together one way. The metal is extruded like a key. However, if your shaft is older and can go back together differently (like an old square shaft) then make sure you mark the yokes so they go back together the same way. They should be offset if memory serves.
Remember to reinstall the plastic on the shaft and your done, simple.