Pick foreground color, choose the line or the brush tool, pick the size/shape of brush.
- Place the cursor where you want to start the line
- click the left mouse button
- press and hold down the Shift key
- Drag the cursor to where you want the line to end
- Let go of the mouse