See the top rated post in this thread. Click here

Page 2 of 2 FirstFirst 12
Results 11 to 15 of 15

Thread: Remove Text Mask On Select Dimension Objetcs

  1. #11
    I could stop if I wanted to
    Join Date
    2011-09
    Posts
    308
    Login to Give a bone
    0

    Default Re: Remove Text Mask On Select Dimension Objetcs

    OK I got it!!! I'm sure it could be simplified as I don't think it really needs the IF/ELSE bit for DIMENSIONS anymore.

    But it's now globally disabling background fill for DIMS, MTEXT and MLEADERS!!!



    Code:
    (vl-load-com)
    (defun c:unmask (/ ent entdata hnd i newentdata ob1 ss xdata)
      (if (setq ss (ssget "X" (list(cons 0 "DIMENSION,MTEXT,MULTILEADER"))))
        (repeat (setq i (sslength ss))
          (setq hnd (ssname ss (setq i (1- i)))
                ent (entget hnd)
          )
          (cond ((wcmatch (cdr (assoc 0 ent)) "*TEXT")
                 (setq ob1 (vlax-ename->vla-object hnd))
                 (vlax-put ob1 'backgroundfill 0)
                )
                ((= (cdr (assoc 0 ent)) "MULTILEADER")
                 (setq ob1 (vlax-ename->vla-object hnd))
                 (vlax-put ob1 'textbackgroundfill 0)
                )
                (T
                 (setq ent (entget hnd '("ACAD")))
                 (if (or (not (setq xdata (assoc -3 ent)))
                         (and (setq xdata (assoc -3 ent))
                              (member '(1000 . "DSTYLE") (last xdata))
                              (/= (cdr (assoc 1070 (reverse (last xdata)))) 1)
                              (setq ent (vl-remove-if '(lambda (x) (= -3 (car x))) ent))
                         )
                     )
                   (setq entdata    '((-3 ("ACAD" (1000 . "DSTYLE") (1002 . "{") (1070 . 69) (1070 . 0) (1002 . "}"))))
                         newentdata (append ent entdata)
                   )
                   (setq ent        (vl-remove-if '(lambda (x) (= -3 (car x))) ent)
                         entdata    '((-3 ("ACAD" (1000 . "DSTYLE") (1002 . "{") (1070 . 69) (1070 . 0) (1002 . "}"))))
                         newentdata (append ent entdata)
                   )
                 )
                 (entmod newentdata)
                )
          )
        )
      )
      (princ)
    )
    Last edited by jpcadconsulting347236; 2015-05-12 at 04:17 PM.

  2. #12
    I could stop if I wanted to
    Join Date
    2011-09
    Posts
    308
    Login to Give a bone
    0

    Default Re: Remove Text Mask On Select Dimension Objetcs

    I found another way as well.

    Using Lee Mac's StripMtext routine, you can issue the following code (assuming StrimMtext.lsp is loaded)

    Code:
    ^C^C(if (setq ss (ssget "X" (list(cons 0 "DIMENSION,MTEXT,MULTILEADER"))))(StripMtext ss "M"))
    Oddly enough, I can't seem to find StripMtext on his site anymore... not sure what's up with that. But it's available all over if you search for it.

  3. #13
    Member
    Join Date
    2006-12
    Location
    Cascais, Portugal
    Posts
    25
    Login to Give a bone
    0

    Default Re: Remove Text Mask On Select Dimension Objetcs

    Hi James,

    with the 'unmask' function, you are trying to unmask, DIMENSION,MTEXT and MULTILEADER objects?
    Or just MTEXT and MULTILEADER objects?

    StripMtext, by Steve Doman and Joe Burke


    Henrique
    Last edited by hmsilva; 2015-05-12 at 06:37 PM.

  4. #14
    I could stop if I wanted to
    Join Date
    2011-09
    Posts
    308
    Login to Give a bone
    0

    Default Re: Remove Text Mask On Select Dimension Objetcs

    Everything.

    DIMENSION,MTEXT and MULTILEADER.

  5. #15
    Member
    Join Date
    2006-12
    Location
    Cascais, Portugal
    Posts
    25
    Login to Give a bone
    1

    Default Re: Remove Text Mask On Select Dimension Objetcs

    James,

    as far as I can remembre, StripMtex, is not from Lee Mac, is from Steve Doman and Joe Burke...(Link in my previous post)

    Henrique

Page 2 of 2 FirstFirst 12

Similar Threads

  1. Dimension Text Background Mask
    By Wish List System in forum AutoCAD Wish List
    Replies: 0
    Last Post: 2014-03-05, 01:24 AM
  2. Dimension text mask model - not paper???
    By CADMama in forum AutoCAD General
    Replies: 1
    Last Post: 2010-10-20, 03:13 PM
  3. Text/Dimension Mask in Drawings
    By inventor.wishlist1738 in forum Inventor Wish List
    Replies: 0
    Last Post: 2010-09-16, 03:25 PM
  4. Dimension Text background mask
    By Grumpy in forum AutoCAD General
    Replies: 3
    Last Post: 2005-08-24, 12:21 PM
  5. Dimension Text Mask?
    By timothy.chapman in forum AutoCAD General
    Replies: 4
    Last Post: 2004-07-21, 02:29 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •