;; function to do a zoom > window.
(defun pjk
-zw
( / thisdwg
) );; End Function (pjk-zw)
;; Create a list for (pjk-AddMDICmd)
;; Zooming Commands...
(list "ZW" 'pjk
-zw
"ZW" 1) )
)
;|==============================================================================
Function Name: (pjk-AddMDICmd)
Arguments: <Command List> = List of lists in the format (list (list "<Global Command Name>" '<Function Name> "[Local Command Name]" [Cmd-Flags]))
Sub-list Arguments:
<Global Command Name> = String for the Name of the Command
<Function Name> = Quoted symbol for the autolisp function to run
[Local Command Name] = String (opt.) for the Name of the command - usually same as global name
[Cmd-Flags] = Integer Bit Flag for Command Behaivior - Bits are as follows:
0 = ACRX_CMD_MODAL; Command cannot be invoked while another command is active.
1 = ACRX_CMD_TRANSPARENT; Command can be invoked while another command is active.
2 = ACRX_CMD_USEPICKSET;When the pickfirst set is retrieved it is cleared within AutoCAD.
Command will be able to retrieve the pickfirst set. Command cannot retrieve or set grips.
4 = ACRX_CMD_REDRAW; When the pickfirst set or grip set is retrieved, neither will be cleared within AutoCAD.
Command can retrieve the pickfirst set and the grip set.
Returns: N/A
Description:
This command defines a list of functions as AutoCAD Commands
that are MDI aware. First the Commands are undefined if they
already exist in the ObjectARX environment. Then, a document
manager reactor is established to test if another document has
become active and redefines the commands in the active document.
This function can only be called once for Each drawing opened to
establish the Command list and functions. then the reactor does the
work.
*** Original Author: Stephan Koster - 1999 ***
================================================================================|;
(defun pjk
-AddMDICmd
(lst
/ old
) )
)
(pjk-CmdRedef nil nil)
) ;; End Function (pjk-AddMDICmd)
;|==============================================================================
Function Name: (pjk-CmdRedef)
Arguments:
Usage: (pjk-CmdRedef [Reactor Callback][Command Info])
Returns: A list of the results of the vlax-add-cmd call - length depends on the command list defined in PJK:Commandslist
Example: given 4 commands to be defined - '(T T T T) if all commands were defined correctly.
Description:
This Function is a reactor callback function for (pjk-addMDIcmd),
or can be called alone with both arguments set to NIL. If the
global variable PJK:COMMANDSLIST is defined, it will use it
to create AutoCAD Commands with (vlax-add-cmd).
*** Original Author: Stephan Koster - 1999 ***
================================================================================|;
(defun pjk
-CmdRedef
(calbck cmd
) )
ok
)
)
)
PJK:commandslist
)
) ;; End Function (pjk-CmdRedef)
;; define the zoom commands and reactor
(pjk-AddMDICmd cmdlst)