TheSwamp

Code Red => AutoLISP (Vanilla / Visual) => Topic started by: Hangman on May 11, 2005, 03:43:15 PM

Title: pop0 to a key
Post by: Hangman on May 11, 2005, 03:43:15 PM
Afternoon all,
this is sort of a silly question, not sure if it would even go to this forum.
But, here it is:

Is it possible to set the pop0 from the acad.mns file to a key, like S for example.
Code: [Select]

***POP0
**SNAP
               [&Object Snap Cursor Menu]
ID_Tracking    [Temporary trac&k point]_tt
ID_From        [&From]_from
ID_MidTwoPts   [Mid Bet&ween 2 Points]_m2p
ID_MnPointFi   [->Poin&t Filters]
ID_PointFilx     [.X].X
ID_PointFily     [.Y].Y
ID_PointFilz     [.Z].Z
                 [--]
ID_PointFixy     [.XY].XY
ID_PointFixz     [.XZ].XZ
ID_PointFiyz     [<-.YZ].YZ
               [--]
ID_OsnapEndp   [&Endpoint]_endp
ID_OsnapMidp   [&Midpoint]_mid
ID_OsnapInte   [&Intersection]_int
ID_OsnapAppa   [&Apparent Intersect]_appint
ID_OsnapExte   [E&xtension]_ext
               [--]
ID_OsnapCent   [&Center]_cen
ID_OsnapQuad   [&Quadrant]_qua
ID_OsnapTang   [Tan&gent]_tan
               [--]
ID_OsnapPerp   [&Perpendicular]_per
ID_OsnapPara   [Para&llel]_par
ID_OsnapNode   [No&de]_nod
ID_OsnapInse   [In&sert]_ins
ID_OsnapNear   [Nea&rest]_nea
ID_OsnapNone   [&None]_non
               [--]
ID_Osnap       [&Osnap Settings...]'_+dsettings 2


I want to be able to hit the S key and the get menu rather than the shift+right click.

Any ideas on how this could be done ???
Title: pop0 to a key
Post by: Kerry on May 11, 2005, 04:17:44 PM
Something like :
Code: [Select]

(defun c:s ()
  (menucmd "P0=POP0")
  (menucmd "P0=*")
)
Title: pop0 to a key
Post by: Kerry on May 11, 2005, 04:18:46 PM
Though you will still have to hit enter or the space bar.
Title: pop0 to a key
Post by: Hangman on May 11, 2005, 05:38:44 PM
That's cool, I couldn't figure out the "P0=  you have in the line.  Thanks.

By the way, where are you getting the P0= from anyway ???
Title: pop0 to a key
Post by: rude dog on May 11, 2005, 07:36:16 PM
I also added this to minz after seeing my bud use it
Code: [Select]

ID_PointFil@     [@]@


and of course <mbuttonpan> is set to <0>