2009-12-08 04:07 UTC
With Build 6.0.0.15
with Ac2010
The Palette is described as
How do I get the palette to collapse and 'expand automatically in response to cursor movement.'
ie how do I hide the Palette when the mouse is not on it?
With the Palette NOT docked :
Then when I select the Auto-Hide icon on the vertical bar, the palette will close and show manually.
The Auti-Hide toggle accessed from right click on the Vertical bar seems to have no affect
With the Palette docked :
Then when I select the Auto-Hide icon on the vertical bar, the palette become Un-docked.
(vl-load-com)
(command "OPENDCL")
;;(if (not (vl-symbol-value 'kglobal:librarybuild))
;; (load "KDUB_LIBRARY.VLX")
;;)
;;;---------------------------------------------------------------------------
;;;
;; (findfile "Pal.ODCL")
;|<>|;
(defun c:pal (/ dialogreturn)
;; (dcl_project_load "Pal.ODCL" t)
(dcl_project_load "Pal.ODCL")
;; Show the main form
(setq dialogreturn (dcl_form_show Pal_main))
;;------
(princ)
)
;;;---------------------------------------------------------------------------
;;;
;|<>|;
;;;---------------------------------------------------------------------------
;;;
;|<>|;
;;;-------------------------------------------
;|
This event is triggered immediately before the dialog is closed.
UpperLeftX, UpperLeftY is the coordinate of the upper left corner of the dialog.
|;
(defun c:Pal_Main_OnClose (UpperLeftX UpperLeftY /)
(dcl_MessageBox "To Do: code must be added to event handler\r\nc:Pal_Main_OnClose" "To do")
)
;;;-------------------------------------------
;|
The OnInitialize event is called immediately before a form is shown on the screen.
This event handler can initialize the form and its controls before they are displayed.
|;
(defun c:Pal_Main_OnInitialize (/)
;; (dcl_MessageBox "To Do: code must be added to event handler\r\nc:Pal_Main_OnInitialize" "To do")
(dcl_Control_SetCaption Pal_Main_Label1 (getvar "DWGNAME"))
(princ)
)
;;;-------------------------------------------
;|
This event is triggered when the user closes the last open AutoCAD drawing.
If any of the modeless dialog's controls are dependent on the state or contents of the current drawing file,
they should be cleared at this time. Once the drawing is closed, no AutoLISP code can execute since there
is no document context for it to execute in.
This event handler will be the last opportunity to execute code until a new document is opened.
|;
(defun c:Pal_Main_OnEnteringNoDocState (/)
(if (dcl_Form_IsActive Pap)
(dcl_form_close Pal)
)
)
;;;-------------------------------------------
;|
This event is triggered when the user switches to a different open AutoCAD drawing.
Note that opening a new drawing will not trigger any event. An application that uses modeless dialogs
must be installed so that its code is loaded into each newly created drawing document,
and the application's initialization code must check for already active dialogs that it must manage.
|;
(defun c:Pal_Main_OnDocActivated (/)
(dcl_MessageBox "To Do: code must be added to event handler\r\nc:Pal_Main_OnDocActivated" "To do")
)
;;;---------------------------------------------------------------------------
;;;Attached is the ODCL I'm using:
with Ac2010
The Palette is described as
The palette form displays a modeless dialog that can either remain floating or be docked to the AutoCAD window. Palettes have a vertical title bar, and feature the ability to collapse and expand automatically in response to cursor movement.
How do I get the palette to collapse and 'expand automatically in response to cursor movement.'
ie how do I hide the Palette when the mouse is not on it?
With the Palette NOT docked :
Then when I select the Auto-Hide icon on the vertical bar, the palette will close and show manually.
The Auti-Hide toggle accessed from right click on the Vertical bar seems to have no affect
With the Palette docked :
Then when I select the Auto-Hide icon on the vertical bar, the palette become Un-docked.
(vl-load-com)
(command "OPENDCL")
;;(if (not (vl-symbol-value 'kglobal:librarybuild))
;; (load "KDUB_LIBRARY.VLX")
;;)
;;;---------------------------------------------------------------------------
;;;
;; (findfile "Pal.ODCL")
;|<>|;
(defun c:pal (/ dialogreturn)
;; (dcl_project_load "Pal.ODCL" t)
(dcl_project_load "Pal.ODCL")
;; Show the main form
(setq dialogreturn (dcl_form_show Pal_main))
;;------
(princ)
)
;;;---------------------------------------------------------------------------
;;;
;|<>|;
;;;---------------------------------------------------------------------------
;;;
;|<>|;
;;;-------------------------------------------
;|
This event is triggered immediately before the dialog is closed.
UpperLeftX, UpperLeftY is the coordinate of the upper left corner of the dialog.
|;
(defun c:Pal_Main_OnClose (UpperLeftX UpperLeftY /)
(dcl_MessageBox "To Do: code must be added to event handler\r\nc:Pal_Main_OnClose" "To do")
)
;;;-------------------------------------------
;|
The OnInitialize event is called immediately before a form is shown on the screen.
This event handler can initialize the form and its controls before they are displayed.
|;
(defun c:Pal_Main_OnInitialize (/)
;; (dcl_MessageBox "To Do: code must be added to event handler\r\nc:Pal_Main_OnInitialize" "To do")
(dcl_Control_SetCaption Pal_Main_Label1 (getvar "DWGNAME"))
(princ)
)
;;;-------------------------------------------
;|
This event is triggered when the user closes the last open AutoCAD drawing.
If any of the modeless dialog's controls are dependent on the state or contents of the current drawing file,
they should be cleared at this time. Once the drawing is closed, no AutoLISP code can execute since there
is no document context for it to execute in.
This event handler will be the last opportunity to execute code until a new document is opened.
|;
(defun c:Pal_Main_OnEnteringNoDocState (/)
(if (dcl_Form_IsActive Pap)
(dcl_form_close Pal)
)
)
;;;-------------------------------------------
;|
This event is triggered when the user switches to a different open AutoCAD drawing.
Note that opening a new drawing will not trigger any event. An application that uses modeless dialogs
must be installed so that its code is loaded into each newly created drawing document,
and the application's initialization code must check for already active dialogs that it must manage.
|;
(defun c:Pal_Main_OnDocActivated (/)
(dcl_MessageBox "To Do: code must be added to event handler\r\nc:Pal_Main_OnDocActivated" "To do")
)
;;;---------------------------------------------------------------------------
;;;Attached is the ODCL I'm using: