ControlBar Size

Started by velasquez, October 08, 2010, 02:39:43 PM

Previous topic - Next topic

velasquez

 I am working with a ControlBar form with DockableSides = 4. 
What do I need to do to update the window of AutoCAD when the width of ControlBar is modified?

owenwengerd

The layout should be recalculated automatically. How are you changing the width?

velasquez

Quote from: owenwengerd on October 08, 2010, 02:41:26 PM
The layout should be recalculated automatically. How are you changing the width?

I am changing the width with dcl_Control_SetWidth.

(defun c:Project-2-Dockable_Form2_Label1_OnClicked (/)
      (dcl_Control_SetWidth Project-2-Dockable_Form2 20)
      (setq JoyLargura (dcl_Control_GetWidth Project-2-Dockable_Form2))
) ;_ fim de defun

velasquez

I posted the files to show the problem with Control Bar Form. 
If this is not a bug anybody does it can me to help to adjust the width of the layout of AutoCAD?
Thanks

owenwengerd

The control bar is not designed to be resizable by code unless it is floating. The fact that OpenDCL is actually resizing the hosted form is a bug; it should not attempt to resize when the control bar is docked.

I investigated again to see if there is any way to add the ability to resize a docked control bar, but unfortunately I could not find any way to do it. Depending on your needs, a palette might work better as it can snap to an edge while remaining floating (and thus resizable).

velasquez

Ok Owen,
Thank you for the help.