See the top rated post in this thread. Click here

Page 1 of 2 12 LastLast
Results 1 to 10 of 15

Thread: lisp routine for popout menu of sizes 3/4" to 36"

  1. #1
    Active Member
    Join Date
    2002-01
    Location
    Richmond, CA Lifer
    Posts
    72
    Login to Give a bone
    0

    Default lisp routine for popout menu of sizes 3/4" to 36"

    I know I've seen it before ... a list that would POPOUT from a menu that would offer standard pipe or conduit sizes to paste into a drawing. it would "op out" a list to choose the selectable size wanted and paste it into a drawing once or multiple times.

    Please let me know if you've seen this type of routine. Thanks.

    Al

  2. #2
    Certifiable AUGI Addict
    Join Date
    2001-03
    Location
    Tallahassee, FL USA
    Posts
    3,658
    Login to Give a bone
    0

    Default Re: lisp routine for popout menu of sizes 3/4" to 36"

    Moderator should move this to Programming → AutoLISP forum

    I like using initget & getkword to provide options to either select from command line or right-click popup menu.

  3. #3
    Active Member
    Join Date
    2002-01
    Location
    Richmond, CA Lifer
    Posts
    72
    Login to Give a bone
    0

    Default Re: lisp routine for popout menu of sizes 3/4" to 36"

    Good point ... could a Moderator move this to Programming → AutoLISP forum, please!

  4. #4
    Active Member
    Join Date
    2002-01
    Location
    Richmond, CA Lifer
    Posts
    72
    Login to Give a bone
    0

    Default Re: lisp routine for popout menu of sizes 3/4" to 36"

    lisp routine for popout menu of sizes 3/4" to 36"

    I know I've seen it before ... a list that would POPOUT from a menu that would offer standard pipe or conduit sizes to paste into a drawing. it would "pop out" a list to choose the selectable size wanted and paste it into a drawing once or multiple times.

    I want to create a FLYOUT that has the sizes to choose from 3'4" to 36" placing that size in the drawing.

    Please let me know if you've seen this type of routine. Thanks.

    Al

  5. #5
    I could stop if I wanted to
    Join Date
    2015-05
    Location
    West Des Moines
    Posts
    306
    Login to Give a bone
    0

    Default Re: lisp routine for popout menu of sizes 3/4" to 36"

    See attached. Is that what you mean by pop out menu?

    If so what are you trying to select in the menu? Blocks, line commands, images, etc. It sounds like blocks.

    The specific argument you want is

    (setq get1 (getkword "[size 1/size 2/etc] <default choice on return>")) if that's all you wanted.
    Attached Images Attached Images

  6. #6
    Active Member
    Join Date
    2002-01
    Location
    Richmond, CA Lifer
    Posts
    72
    Login to Give a bone
    0

    Default Re: lisp routine for popout menu of sizes 3/4" to 36"

    I think what I want is a flyout menu when picked a "FLYOUT" list of incremented pipe sizes or conduit sizes represented by text could be selected as text and placed multiple times in the drawing. It is a minor step saved but important in it's use. thanks.

  7. #7
    Certifiable AUGI Addict
    Join Date
    2001-03
    Location
    Tallahassee, FL USA
    Posts
    3,658
    Login to Give a bone
    0

    Default Re: lisp routine for popout menu of sizes 3/4" to 36"

    Quote Originally Posted by gugg View Post
    I think what I want is a flyout menu when picked a "FLYOUT" list of incremented pipe sizes or conduit sizes represented by text could be selected as text and placed multiple times in the drawing. It is a minor step saved but important in it's use. thanks.
    While this is slightly less confusing than your thread: http://forums.augi.com/showthread.ph...95#post1297595
    Varth's example uses initget & getkword to provide options to either select from command line or popup menu in a lisp routine. AutoCAD's drop-down Menus, Ribbon Panels, Toolbars, Tool Palettes, etc… all use flyouts. If you could explain how you expect to access this list and what you expect to happen when you select one of those sizes we should be able to figure out what you're looking for.

  8. #8
    All AUGI, all the time
    Join Date
    2003-07
    Posts
    555
    Login to Give a bone
    0

    Default Re: lisp routine for popout menu of sizes 3/4" to 36"

    Lots of ways to do this here is some examples,

    1 have a submenu from a main menu, simple to make
    2 we have old fashioned slide menu's so pick an image, supports automatically multiple pages.
    3 use a tool pallete
    4 old way again is to have a pop side menu, unfortunately this has lost support by Autodesk so a bit difficult to get to work but was super simple to make.
    5 use a library dcl and just populate a List dcl and pick.
    6 have a dcl with images about 4x4 is max

    Here is a library code for a LIST DCL returns ITEM as pick value

    Code:
        ;; LIST SELECT DIALOG (TEMP DCL LIST BOX SELECTION, BASED ON PROVIDED LIST)  ;; TITLE - LIST BOX TITLE
      ;; LABEL - LABEL FOR LIST BOX
      ;; HEIGHT - HEIGHT OF BOX
      ;; WIDTH - WIDTH OF BOX
      ;; MULTI - SELECTION METHOD ["TRUE": MULTIPLE, "FALSE": SINGLE]
      ;; LST - LIST OF STRINGS TO PLACE IN LIST BOX
      ;; ALAN J. THOMPSON, 09.23.08 / 05.17.10 (REWRITE)
    (DEFUN AT:LISTSELECT (TITLE LABEL HEIGHT WIDTH MULTI LST / FN FO D ITEM F)
      (SETQ FO (OPEN (SETQ FN (VL-FILENAME-MKTEMP "" "" ".DCL")) "W"))
      (FOREACH X (LIST (STRCAT "LIST_SELECT : DIALOG { LABEL = \"" TITLE "\"; SPACER;")
                       (STRCAT ": LIST_BOX { LABEL = \"" LABEL "\";" "KEY = \"LST\";")
                       (STRCAT "ALLOW_ACCEPT = TRUE; HEIGHT = " (VL-PRINC-TO-STRING HEIGHT) ";")
                       (STRCAT "WIDTH = " (VL-PRINC-TO-STRING WIDTH) ";")
                       (STRCAT "MULTIPLE_SELECT = " MULTI "; } SPACER; OK_CANCEL; }")
                 )
        (WRITE-LINE X FO)
      )
      (CLOSE FO)
      (NEW_DIALOG "LIST_SELECT" (SETQ D (LOAD_DIALOG FN)))
      (START_LIST "LST")
      (MAPCAR (FUNCTION ADD_LIST) LST)
      (END_LIST)
      (SETQ ITEM (SET_TILE "LST" "0"))
      (ACTION_TILE "LST" "(SETQ ITEM $VALUE)")
      (SETQ F (START_DIALOG))
      (UNLOAD_DIALOG D)
      (VL-FILE-DELETE FN)
      (IF (= F 1)
        ((LAMBDA (S / I S L)
           (WHILE (SETQ I (VL-STRING-SEARCH " " S))
             (SETQ L (CONS (NTH (ATOI (SUBSTR S 1 I)) LST) L))
             (SETQ S (SUBSTR S (+ 2 I)))
           )
           (REVERSE (CONS (NTH (ATOI S) LST) L))
         )
          ITEM
        )
      )
    )

  9. #9
    Mod / Salary / SM Wanderer's Avatar
    Join Date
    2001-12
    Location
    St. Louis
    Posts
    5,406
    Login to Give a bone
    0

    Default Re: lisp routine for popout menu of sizes 3/4" to 36"

    Quote Originally Posted by gugg View Post
    Good point ... could a Moderator move this to Programming → AutoLISP forum, please!
    Sure thing. You should get more help in this forum.

    Cheers!
    Melanie Stone
    @MistresDorkness

    Archibus, FMS/FMInteract and AutoCAD Expert (I use BricsCAD, Revit, Tandem, and Planon, too)
    Technical Editor
    not all those who wander are lost

  10. #10
    I could stop if I wanted to
    Join Date
    2015-05
    Location
    West Des Moines
    Posts
    306
    Login to Give a bone
    0

    Default Re: lisp routine for popout menu of sizes 3/4" to 36"

    Quote Originally Posted by Wanderer View Post
    Sure thing. You should get more help in this forum.

    Cheers!
    Too bad he already had the same thread here.

    I don't think we ever got clarification for what he was exactly wanting to do with this pop out list. It sounds like he wants to run a command to get a list, choose a size, and then bring in a block or a chunk of text or something which is why I offered what I offered in his other thread, but he seemed to turn it down. When Tom asked for further clarification on what he was exactly trying to use it for we never got a response.

Page 1 of 2 12 LastLast

Similar Threads

  1. Lisp routine request: "Draw By Example"
    By matt.bachardy903119 in forum AutoLISP
    Replies: 9
    Last Post: 2016-06-27, 07:02 PM
  2. Replies: 8
    Last Post: 2012-08-18, 01:31 AM
  3. Replies: 40
    Last Post: 2006-10-16, 05:02 PM
  4. Replies: 3
    Last Post: 2005-10-11, 06:59 PM
  5. Missing "inches" "mm" in Plot menu 2005
    By jfranco in forum AutoCAD Plotting
    Replies: 5
    Last Post: 2004-11-05, 10:10 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
  •