Author Topic: PLINE JOIN  (Read 6763 times)

0 Members and 1 Guest are viewing this topic.

TJAM51

  • Guest
PLINE JOIN
« on: December 03, 2004, 07:35:01 AM »
I am seeking a routine that will join a pline and offer a crossing or pick without having to go throuh all the PEDIT process....thanks

Keith™

  • Villiage Idiot
  • Seagull
  • Posts: 16899
  • Superior Stupidity at its best
PLINE JOIN
« Reply #1 on: December 03, 2004, 07:53:27 AM »
If you have express tools use pljoin
Proud provider of opinion and arrogance since November 22, 2003 at 09:35:31 am
CadJockey Militia Field Marshal

Find me on https://parler.com @kblackie

CAB

  • Global Moderator
  • Seagull
  • Posts: 10401
PLINE JOIN
« Reply #2 on: December 03, 2004, 08:05:51 AM »
I have this but never tried it.
Code: [Select]
;;  from Marc'Antonio Alessi (nospam_maalessi_at_tin_dot_it)
; #PlineJoinPrec = global
;
(defun C:ALE_PlJoin (/ SelSet FltLst OldLPr)
 ;(setvar "CMDECHO" 0) ; I have always = 0
  (princ "\nSelect lines, arcs or polylines to join:  ")
  (setq OldLPr (getvar "LUPREC"))  (setvar "LUPREC" 8)
  (setq
    FltLst
    '((0 . "LWPOLYLINE,POLYLINE,LINE,ARC"))
    #PlineJoinPrec
     (ureal 5 "" "Precision distance" (cond ( #PlineJoinPrec ) ( 0.00001 )))
  )
  (setvar "LUPREC" OldLPr)
  (cond
    ( (not (setq SelSet (cond ((ssget "_I" FltLst)) ((ssget FltLst)))))
      (prompt "\nNo arc or polyline selected.  ")
    )
    ( (ssget "_P" '((0 . "LINE,ARC")))
      (command "_.PEDIT" "_M" SelSet "" "_Y" "_J" "_J" "_E" #PlineJoinPrec"")
      (princ (strcat
        "\n" (itoa (sslength SelSet))
        " lines, arcs or polylines are joined.  "
      )       )
    )
    ( T
      (command "_.PEDIT" "_M" SelSet "" "_J" "_J" "_E" #PlineJoinPrec "")
      (princ "\n_ ")
      (princ (strcat "\n " (itoa (sslength SelSet)) " polylines are joined."))
    )
  )
  (princ)
)
;*
;* UREAL  Funzione di interfaccia utente per numeri reali.
;* BIT (0 per nessuno) e KWD key word ("" per nessuna) sono gli stessi di
;* INITGET.
;* MSG e' la stringa di prompt, alla quale e' aggiunto numero reale di default
;* come <DEF> (nil per nessuno), e un : sara' aggiunto.
;*
(defun ureal (bit kwd msg def / inp)
  (if def
    (setq
      msg (strcat "\n" msg " <" (ALE_RTOS_DZ8 def) ">: ")
      bit (* 2 (fix (/ bit 2)))
    )
    (setq msg (strcat "\n" msg ": "))
  )
  (initget bit kwd)
  (setq inp (getreal msg))
  (if inp inp def)
);defun UREAL
;
(defun ALE_RtoS_DZ8 (ReaVal / CurDZn OutVal)
  (if (= 8 (setq CurDZn (getvar "DIMZIN")))
    (setq CurDZn nil)
    (setvar "DIMZIN" 8)
  )
  (setq OutVal (rtos ReaVal 2))
  (and CurDZn (setvar "DIMZIN" CurDZn))
  OutVal
)
I've reached the age where the happy hour is a nap. (°¿°)
Windows 10 core i7 4790k 4Ghz 32GB GTX 970
Please support this web site.

SMOKIIBEAR

  • Guest
Re: PLINE JOIN
« Reply #3 on: November 15, 2005, 06:20:04 PM »
HOW CAN THIS ROUTINE BE REWRITTEN SO THAT IT IS NOT NECESSARY TO ENTER FUZZ DISTANCE AT THE COMMAND LINE EACH TIME, BUT THE OPTION COULD BE AVAILABLE?

Mark

  • Custom Title
  • Seagull
  • Posts: 28762
Re: PLINE JOIN
« Reply #4 on: November 15, 2005, 06:33:57 PM »
If you have a few dollars and don't want to write you own .... GBPoly [ http://www.geometricad.com/ ] You'll find it hard to beat. :-)
TheSwamp.org  (serving the CAD community since 2003)

DanB

  • Bull Frog
  • Posts: 367
Re: PLINE JOIN
« Reply #5 on: November 16, 2005, 12:22:57 PM »
Here's the one I use...

Code: [Select]
;;
;; 06/22/05
;; Polyline Joins Selected Objects
;;
  (defun c:j (/ ss)
   (prompt "\nSelect Objects to Join... ")
   (setq ss (ssget))
   (command "pedit" "m" ss "" "j" "" "")
   (princ)
  )


deegeecees

  • Guest
Re: PLINE JOIN
« Reply #6 on: November 16, 2005, 12:46:46 PM »
If you have a few dollars and don't want to write you own .... GBPoly [ http://www.geometricad.com/ ] You'll find it hard to beat. :-)


Very good app.

LE

  • Guest
Re: PLINE JOIN
« Reply #7 on: November 16, 2005, 12:54:13 PM »
Yes....

Here is a link to see GBPOLY in action:

http://www.geometricad.com/app.php?id=1&lang=en

There are a lot of open source, samples on how to join plines, lines and arcs, if you are looking for a smart and easy way to generate closed areas, then give GBPOLY a try.

SMOKIIBEAR

  • Guest
Re: PLINE JOIN
« Reply #8 on: November 16, 2005, 02:44:16 PM »
Ahhh...that makes me happy :lmao:

Thanks.  One of these days, I need to starting writing lisp.

whdjr

  • Guest
Re: PLINE JOIN
« Reply #9 on: November 16, 2005, 03:04:28 PM »
How about sooner that later.

Lisp Forum
Lisp Course Documents

Swift

  • Swamp Rat
  • Posts: 596
Re: PLINE JOIN
« Reply #10 on: November 16, 2005, 03:09:11 PM »
How about sooner that later.

Lisp Forum
Lisp Course Documents

Quote
An Error Has Occurred!
The topic or board you are looking for appears to be either missing or off limits to you

deegeecees

  • Guest
Re: PLINE JOIN
« Reply #11 on: November 16, 2005, 03:16:46 PM »
How about sooner that later.

Lisp Forum
Lisp Course Documents
Quote
An Error Has Occurred!
The topic or board you are looking for appears to be either missing or off limits to you

Ditto.

whdjr

  • Guest
Re: PLINE JOIN
« Reply #12 on: November 16, 2005, 03:19:13 PM »
I think that was invitation only forum.  You had to sign up for the class.

Maybe Mark can unlock that for everyone?

edit
Sorry 'bout that guys I forgot.

Keith™

  • Villiage Idiot
  • Seagull
  • Posts: 16899
  • Superior Stupidity at its best
Re: PLINE JOIN
« Reply #13 on: November 16, 2005, 03:19:24 PM »
I get the same thing .... perhaps when Mark was playing around with the board he got it mal-adjusted ...
Proud provider of opinion and arrogance since November 22, 2003 at 09:35:31 am
CadJockey Militia Field Marshal

Find me on https://parler.com @kblackie

jonesy

  • SuperMod
  • Seagull
  • Posts: 15568
Re: PLINE JOIN
« Reply #14 on: November 17, 2005, 02:47:22 AM »
That was a course that was run by Stig. We had to sign up for the course. I believe its only for the students on Stigs course.
T :-)
Thanks for explaining the word "many" to me, it means a lot.