I would measure how much straight area I need for the grips, brake levers, and shifter(s), and cut the bar so there's room for all that but not much more. If you're comfortable steering a road bike with 40 cm of leverage, you don't need more than that.
That is exactly what I did on my hybrid and it worked out perfectly.