Qleader MText Movement

Discussion in 'AutoCAD' started by jayhawk261, Feb 12, 2004.

  1. jayhawk261

    jayhawk261 Guest

    I need a little help with a QLeader issue. We use the Qleader with attached Mtext. The issue we have is that when the text needs to be moved, the leader streches at what we consider the wrong vertex. I would like to write a lisp that moves specific vertexes of the leader the same X & Y dimensions as the Mtext is moved. That way, the leader still looks proper, not like it is "bent out of shape" If anyone can help me out with this or make another suggestion, that would be great.

    Thanks,

    Randy Nicholson
     
    jayhawk261, Feb 12, 2004
    #1
  2. jayhawk261

    Charliep Guest

    When you start the QLeader command (LE?), how many times do you select before you start right clicking to get the mtext dialog box?
    I my self, select the start point of my leader (arrow placement) select a second location and right click until I get the mtext dialog box. When I move the finished leader, I have never found it to deform.
    Hope that this helps.
     
    Charliep, Feb 12, 2004
    #2
  3. jayhawk261

    Steve Doman Guest

    Randy,

    Where I work we use Qleader with left justified mtext, having zero width,
    with the leader attached to the middle of the topline on either the left or
    right side. This leader style looks to us to be more like hand written text
    then AutoCAD's default look. However when these leaders are mirrored, they
    tend to revert back to the leader's primordial default - center justified
    with leader attached to the center of the mtext object.

    I just so happen to be working on a lisp routine that "reformats" leaders
    when they get messed up from mirroring. This routine formats the mtext to
    left justified, forces a horizontal dogleg, and extends the leader last
    vertex to the end of the text in the top line. Works great but still needs
    more testing and polishing.

    Can you elaborate a bit more on exactly what you are trying to do and also
    post any code you have so far. Or perhaps post a small dwg file on CF
    showing one of your leaders before and after "moving".

    If you want to get the vertices of the leader, look at dxf 10 from the
    leaders entget list.

    ;; Get leader dxf codes
    (if (setq leaderent (car (entsel "\nPick a leader: ")))
    (setq elist (entget leaderent))
    )

    ;; Get leader coordinates
    ;; Returns list in first to last order
    (setq coords
    (vl-remove-if
    (function (lambda (x) (/= (car x) 10)))
    elist
    )
    )

    Modfiy the "coords" list from above to your satisfaction, and entmod it.

    (entmod elist)
    (entupd leadent)

    I had a little trouble with the leader updating but found a work around
    (which I can explain later). I'll post more code this weekend if your
    interested. I need some time to test and polish the routine up a bit.

    Regards,
    Steve Doman



    attached Mtext. The issue we have is that when the text needs to be moved,
    the leader streches at what we consider the wrong vertex. I would like to
    write a lisp that moves specific vertexes of the leader the same X & Y
    dimensions as the Mtext is moved. That way, the leader still looks proper,
    not like it is "bent out of shape" If anyone can help me out with this or
    make another suggestion, that would be great.
     
    Steve Doman, Feb 13, 2004
    #3
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.