Yes, boundingbox will reveal overwrites (not overrides), but as we have discussed before the boundingbox is just a rectangle, not all of which may be consumed by the mtext contents. Actually, you can use the intersectwith method with text objects as well, but it uses the same boundingbox approach to find the intersections.
Okay, so you can find all the intersections, but then what? It would be a lengthy trial and error process to programmatically (sp?) find a place to move them. That is where the human eye has an advantage. Ya just have to budget for clean-up time.
My most recent boss insisted on zero overwrites, and disdained the use of background masking. So I wrote this little diddy to at least save some time:
(defun C:R+M ( / *error* vars vals e obj objname ip rot)
;* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
;* *
;* R+M.LSP by John F. Uhden *
;* 2 Village Road *
;* Sea Girt, NJ 08750 *
;* *
;* * * * * * * * * * * * Do not delete this heading! * * * * * * * * * * * *
; Program combines rotating and moving text/mtext objects just to save time
; adjusting their position for neatness and legibility.
; v1.0 (01-17-2020) made for Challoner
(gc)
(prompt "\nR+M v1.0 (c)2020, John F. Uhden")
(defun *error* (error)
(sssetfirst)
(mapcar 'setvar vars vals)
(vla-endundomark *doc*)
(cond
(not error)
((wcmatch (strcase error) "*CANCEL*,*QUIT*")
(vl-exit-with-error "\r ")
)
(1 (vl-exit-with-error (strcat "\r*ERROR*: " error)))
)
(princ)
)
;;------------------------------------------
;; Intitialze drawing and program variables:
;;
(setq *acad* (vlax-get-acad-object))
(setq *doc* (vlax-get *acad* 'ActiveDocument))
(vla-endundomark *doc*)
(vla-startundomark *doc*)
(setq vars '("cmdecho" "highlight"))
(setq vals (mapcar 'getvar vars))
(mapcar 'setvar vars '(0 1))
(command "_.expert" (getvar "expert")) ;; dummy command
(while (setq e (car (entsel "\nSelect text object to rotate/move: ")))
(setq obj (vlax-ename->vla-object e)
objname (vlax-get obj 'ObjectName)
)
(and
(or
(wcmatch (strcase objname) "*TEXT")
(prompt "\nObject selected is not text.")
)
(setq ip (vlax-get obj 'InsertionPoint))
(setq rot (vlax-get obj 'Rotation))
(princ "\nNew rotation: ")
(vl-cmdf "_.rotate" e "" "_non" ip "_R" (angtos rot 0 4))
(while (> (getvar "cmdactive") 0)(vl-cmdf pause) 1)
(princ "\nNew position: ")
(vl-cmdf "_.move" e "" "_non" ip)
(while (> (getvar "cmdactive") 0)(vl-cmdf pause) 1)
)
)
(*error* nil)
)
(defun c:RM ()(c:R+M))