Ajmal Posted January 11, 2021 Share Posted January 11, 2021 this one I can use only index colour how can I change to true colour and colour book (defun c:test(/ ccol) (setq ClayP(entget(tblobjname "layer"(setq clay(getvar 'clayer))))) (if (= (getvar 'CECOLOR)"BYLAYER") (setq ccol(cdr(assoc 62 ClayP))) (setq ccol(atoi(getvar 'CECOLOR))) ) (if (setq pt1 (getpoint "\nSpecify Base Point: ")) (progn (setq pt1(trans pt1 1 2)) (while (= 5 (car (setq pt3 (grread nil 13 0)))) (redraw) (setq pt4 (cadr pt3) pt4 (trans pt4 1 2)) (grdraw pt1 pt4 ccol)))) (redraw) (entmake (list(cons 0 "line")(cons 8 (getvar 'Clayer))(cons 10 pt1)(cons 11 pt4))) ) Quote Link to comment Share on other sites More sharing options...
ronjonp Posted January 11, 2021 Share Posted January 11, 2021 As far as I know GRDRAW only accepts and integer for color. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.