How to draw a horizontal line in a slice view?

I want that the line to occupy the entire width of the view, and still occupy the entire width when zooming and panning.
At the same time, the line should move as the image moves.

Did you try the line tool?

Do you mean the line markup?
I know the tool. But it can only be drawn with two endpoints.
I want the line to be of infinite length. (like the crosschair)
Thanks!