View Full Version : getvar "textsize"
jayhay35365091
2013-11-18, 03:30 PM
I currently have a lisp that draws a line down the center of text i.e "strikthrough". I'm needing to move this line under the text by a value that is equal to the text size.
Tom Beauford
2013-11-18, 03:52 PM
"strikthrough" was added in 2014, "underscore" & "overscore" have been around as long as I remember. The lisp should be easy enough to modify, but I doubt if it would work with multiline-text. It would probably create a separate object making modifying the text a pain. Do you have issues with "underscore" from the editor?
jayhay35365091
2013-11-18, 05:23 PM
I've attched the lsp file. The code is a tweak on Lee Mac's strikethrough routine. After the strikethrough command is run the routine moves the line down .1875 to put it under the text. The clients I work with do not like the underline function of either the text or mtext commands. They say the line is too close and I havn't found a way to change the underline distance, so I usually just manually draw a line under the text. I'm needing the routine to get the text size and move the line down the same distance as the text height.
Tom Beauford
2013-11-18, 07:19 PM
Add
y (- y (* (dx 40 e) .6)) to lower the text 60% of the text height after line 44
y (/ (+ (cadar tb) (cadadr tb)) 2.) Untested, but should work.
jayhay35365091
2013-11-18, 09:06 PM
I got it to work but in a little different way. I just changed the "+" sign of line 44 to a "-" and it worked perfectly. Probably wouldn't have found it if you hadn't pointed out that line of code.
Powered by vBulletin® Version 4.2.5 Copyright © 2025 vBulletin Solutions Inc. All rights reserved.