(defun C:ANG1 ()
(SETVAR "ORTHOMODE" 0)
;(IF (= (TYPE F1) 'FILE ) "YES"  (STOP))
;(IF (= (TYPE F2) 'FILE ) "YES" (STOP))
(SETQ LP (GETVAR "LUPREC"))
(SETQ W1 (ENTSEL "\nSelect line:"))
(SETQ W2 (ENTGET (CAR W1 )))
(SETQ WW (CADR W1))
(SETQ P1 (ASSOC 10 W2 ))
(SETQ P2 (ASSOC 11 W2 ))
(SETQ ANGL (ANGLE (CDR P1) (CDR P2)))
(SETQ ANG1 (RTD ANGL))
(SETQ ANG2 ANG1)
(IF (AND (> ANG1 90) (<= ANG1 180)) (SETQ ANG1 (- ANG1 90)))
(IF (AND (> ANG1 180) (<= ANG1 270)) (SETQ ANG1 (- ANG1 180)))
(IF (AND (> ANG1 270) (<= ANG1 360)) (SETQ ANG1 (- ANG1 270)))
(IF (> ANG1 45) (SETQ ANG1 (- 90 ANG1)))
(IF (= (- (FIX ANG1) ANG1) 0.0)
     (PROGN
       (SETQ ANG1 (FIX ANG1))
       (SETQ LP 0)
     )
)
(SETQ ANGLT (RTOS ANG1 2 LP))
(SETQ I 1)
(MENUCMD "S=NUMBER")
(SETQ W4 (GETSTRING "\nSelect number or RETURN for none:"))
(IF (= W4 "")
     (COMMAND "DIM" "LEADER" "NEAR" ww pause "" (STRCAT anglt "%%D") EXIT)
     (COMMAND "DIM" "LEADER" "NEAR" ww pause "" (STRCAT W4 "-" anglt "%%D") EXIT))
(COMMAND "SETVAR" "HIGHLIGHT" "1")
)
