Author Topic: Help troubleshooting a script  (Read 1147 times)

0 Members and 1 Guest are viewing this topic.

kasaron

  • Guest
Help troubleshooting a script
« on: November 23, 2016, 02:57:04 PM »
I'm trying to debug a script.

The gist of the script is to automate/simplify creation of text items, and to automatically offset them a set distance from a point based on justification.

User punches in the command, and then selects a point, then selects an angle; this determines the justification of the text. then they specify the type of text, and the program is supposed to place the text entity, offsetting it's location based on the size of the text (predefined) and the justification of the text.

Issue is, the offest is very, very unreliable and doesn't seem to work.

If anyone can figure out why the offset is not being applied, I'd really appreciate it. I know it's probably a total mess; I'm a neophyte at coding/lisp and I'm running off of just basic knowledge.

roy_043

  • Water Moccasin
  • Posts: 1895
  • BricsCAD 18
Re: Help troubleshooting a script
« Reply #1 on: November 24, 2016, 04:19:17 AM »
See: https://www.theswamp.org/index.php?topic=51955.msg569852#msg569852
Change:
Code: [Select]
(command "mtext" pnt_fix "j" inp_jtx "s" txt_stl "l" "e" "1x" pnt_fix)To:
Code: [Select]
(command "mtext" "_non" pnt_fix "j" inp_jtx "s" txt_stl "l" "e" "1x" pnt_fix)