CGPath with outline
问题 I am trying to draw a CGPath that has a stroke for it's stroke. Basically I want a draw a line using CGPath. I then want to go back and draw lines on both sides of the last CGPath giving it the effect that it is outlines. This line can bend and turn in any way but I always need the two lines on the outside to follow. EDIT: I need to be able to make the middle of the line transparent but the outlines solid black. 回答1: Use CGPathCreateCopyByStrokingPath to create a new path by stroking your old