[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

draw text parallel to a sloping line



I want to draw some text parallel to a sloping line, e.g., 
the line through (X,Y) with a given Slope:

IDL> X = 24.5259  & Y = 16789.1 & Slope = -1763.03 ; data coordinates 
IDL> dX=2.2 & plot, [X-dX,X+dX], Y+[-dX,dX]*Slope

Then this doesn't give the desired result:

IDL> O_angle=atan(Slope)*!radeg 
IDL> xyouts,X,Y,'A_String_Parallel_To_A_Line',$
IDL>     alignment=0.5,orientation=O_angle

But then, how to do?
Any help appreciated!