A few different ways CHX CHY comes to mind, a command U0.15 L0.15 using a reactor where 0.15 can be any value, or simpler a lisp and just type U0.15 D0.15 R0.15 L0.15 and so on.
Smarter people than me will use GRREAD to detect direction.
Another can detect which arrow you press.
So for me a simple answer a smart answer hopefully some one else.
Pleas feel free to play with this
; Enter the filet radius as part of a command line entry f100 offset O234 circle c123-45
; changed to x move y & z to be added
; note - is used for decimal point
; original code and methology by Alan H
; assistance and code that worked by Lee-Mac
; OCT 2015
( (lambda nil
(vl-load-com)
(foreach obj (cdar (vlr-reactors :vlr-command-reactor))
(if (= "ahmove-reactor" (vlr-data obj))
(vlr-remove obj)
)
)
(vlr-command-reactor "ahmove-reactor" '((:vlr-unknowncommand . ahmove-reactor-callback)))
)
)
(defun movex ( )
(setq xval (distof (substr com 2) 2))
(if (< 0.0 xval)
(progn
(setq pt1 (list 0.0 0.0 0.0))
(setq pt2 (list xval 0.0 0.0))
(setq ent (entsel "select object"))
(vla-sendcommand ahmove-reactor-acdoc "_.Move !ent !pt1 !pt2 ")
;(command "move" ent "" pt1 pt2) for Briscad
(setq pt1 nil pt2 nil ent nil)
)
)
)
(defun movey ( )
(setq yval (distof (substr com 2) 2))
(if (< 0.0 yval)
(progn
(setq pt1 (list 0.0 0.0 0.0))
(setq pt2 (list 0.0 yval 0.0))
(setq ent (entsel "select object"))
(vla-sendcommand ahmove-reactor-acdoc "_.Move !ent !pt1 !pt2 ")
;(command "move" ent "" pt1 pt2) for Briscad
(setq pt1 nil pt2 nil ent nil)
)
)
)
(defun ahmove-reactor-callback ( obj com )
(setq com (vl-string-translate "-" "." (strcase (car com))))
(cond
( (and
(wcmatch com "~*[~X.0-9]*")
(wcmatch com "X*")
(wcmatch com "~X*X*")
(wcmatch com "~*.*.*")
) ; and
(movex)
)
( (and
(wcmatch com "~*[~Y.0-9]*")
(wcmatch com "Y*")
(wcmatch com "~Y*Y*")
(wcmatch com "~*.*.*")
) ; and
(movey)
)
) ; master cond
) ; defun
(if (not ahmove-reactor-acdoc)
(setq ahmove-reactor-acdoc (vla-get-activedocument (vlax-get-acad-object)))
)