i;m trying to open a control that it will fill the dockinmanager in the center
i have the following code:
RadSplitContainer container = new RadSplitContainer();
container.InitialPosition = DockState.DockedRight;
RadDocking.SetDockState(container, DockState.DockedRight);
m_dockingManager.Items.Add(container);
RadPaneGroup group = new RadPaneGroup();
container.Items.Add(group);
RadPane newPane = new RadPane();
group.AddItem(newPane, global::Telerik.Windows.Controls.Docking.DockPosition.Center);
RadDocking.SetSerializationTag(newPane, control.Name);
newPane.Title = ps.Caption;
newPane.Content = control;
newPane.Measure(new Size(double.PositiveInfinity, double.PositiveInfinity));
newPane.Arrange(new Rect(control.DesiredSize));
newPane.ClipToBounds = true;
newPane.CanUserClose = ps.CloseButtonVisability;
newPane.CanUserPin = ps.AutoHideVisability;
newPane.CanDockInDocumentHost = (ps.FloatOnly == false);
if (ps.FloatOnly == true)
newPane.MakeFloatingOnly();
else
{
if (ps.Floating == true)
newPane.MakeFloatingDockable();
else
newPane.MakeDockable();
}
ResourceDictionary dic = GetTelerikResourceStyle();
newPane.Style =(Style)dic[DEFAULTRADPANESTYLE];
but this doesnt work- it always open the control in 24 width and heigth in the top left corner of the screen.
why?????
i have the following code:
RadSplitContainer container = new RadSplitContainer();
container.InitialPosition = DockState.DockedRight;
RadDocking.SetDockState(container, DockState.DockedRight);
m_dockingManager.Items.Add(container);
RadPaneGroup group = new RadPaneGroup();
container.Items.Add(group);
RadPane newPane = new RadPane();
group.AddItem(newPane, global::Telerik.Windows.Controls.Docking.DockPosition.Center);
RadDocking.SetSerializationTag(newPane, control.Name);
newPane.Title = ps.Caption;
newPane.Content = control;
newPane.Measure(new Size(double.PositiveInfinity, double.PositiveInfinity));
newPane.Arrange(new Rect(control.DesiredSize));
newPane.ClipToBounds = true;
newPane.CanUserClose = ps.CloseButtonVisability;
newPane.CanUserPin = ps.AutoHideVisability;
newPane.CanDockInDocumentHost = (ps.FloatOnly == false);
if (ps.FloatOnly == true)
newPane.MakeFloatingOnly();
else
{
if (ps.Floating == true)
newPane.MakeFloatingDockable();
else
newPane.MakeDockable();
}
ResourceDictionary dic = GetTelerikResourceStyle();
newPane.Style =(Style)dic[DEFAULTRADPANESTYLE];
but this doesnt work- it always open the control in 24 width and heigth in the top left corner of the screen.
why?????