本文整理汇总了C#中WeifenLuo.WinFormsUI.Docking.DockPane类的典型用法代码示例。如果您正苦于以下问题:C# DockPane类的具体用法?C# DockPane怎么用?C# DockPane使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
DockPane类属于WeifenLuo.WinFormsUI.Docking命名空间,在下文中一共展示了DockPane类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: InternalConstruct
private void InternalConstruct(DockPanel dockPanel, DockPane pane, bool boundsSpecified, Rectangle bounds)
{
if (dockPanel == null)
throw(new ArgumentNullException(Strings.FloatWindow_Constructor_NullDockPanel));
m_nestedPanes = new NestedPaneCollection(this);
FormBorderStyle = FormBorderStyle.SizableToolWindow;
ShowInTaskbar = false;
if (dockPanel.RightToLeft != RightToLeft)
RightToLeft = dockPanel.RightToLeft;
if (RightToLeftLayout != dockPanel.RightToLeftLayout)
RightToLeftLayout = dockPanel.RightToLeftLayout;
SuspendLayout();
if (boundsSpecified)
{
Bounds = bounds;
StartPosition = FormStartPosition.Manual;
}
else
{
StartPosition = FormStartPosition.WindowsDefaultLocation;
Size = dockPanel.DefaultFloatWindowSize;
}
m_dockPanel = dockPanel;
Owner = DockPanel.FindForm();
DockPanel.AddFloatWindow(this);
if (pane != null)
pane.FloatWindow = this;
ResumeLayout();
}
示例2: VS2005DockPaneCaption
public VS2005DockPaneCaption(DockPane pane) : base(pane)
{
SuspendLayout();
Font = PluginCore.PluginBase.Settings.DefaultFont;
m_components = new Container();
m_toolTip = new ToolTip(Components);
// Adjust size based on scale
double scale = ScaleHelper.GetScale();
if (scale >= 2) // 200%
{
_TextGapTop = 3;
_TextGapBottom = 6;
_ButtonGapBottom = 4;
}
else if (scale >= 1.5) // 150%
{
_TextGapTop = 2;
_TextGapBottom = 4;
_ButtonGapBottom = 4;
}
else if (scale >= 1.2) // 120%
{
_TextGapTop = 2;
_TextGapBottom = 2;
}
// Else 100%
ResumeLayout();
}
示例3: VS2005MultithreadingDockPaneCaption
public VS2005MultithreadingDockPaneCaption(DockPane pane)
: base(pane)
{
SuspendLayout();
m_components = new Container();
m_toolTip = new ToolTip(Components);
// clone shared resources
lock (typeof(Resources))
{
_imageButtonAutoHide = (Bitmap)Resources.DockPane_AutoHide.Clone();
_imageButtonClose = (Bitmap)Resources.DockPane_Close.Clone();
_imageButtonDock = (Bitmap)Resources.DockPane_Dock.Clone();
_imageButtonOptions = (Bitmap)Resources.DockPane_Option.Clone();
}
// create background blend
_activeBackColorGradientBlend = new Blend(2)
{
Factors = new float[] { 0.5F, 1.0F },
Positions = new float[] { 0.0F, 1.0F },
};
ResumeLayout();
}
示例4: VS2005MultithreadingDockPaneStrip
public VS2005MultithreadingDockPaneStrip(DockPane pane)
: base(pane)
{
SetStyle(ControlStyles.ResizeRedraw |
ControlStyles.UserPaint |
ControlStyles.AllPaintingInWmPaint |
ControlStyles.OptimizedDoubleBuffer, true);
SuspendLayout();
m_components = new Container();
m_toolTip = new ToolTip(Components);
m_selectMenu = new ContextMenuStrip(Components);
m_graphicsPath = new GraphicsPath();
// clone shared resources
lock (typeof(Resources))
{
m_imageButtonClose = (Bitmap)Resources.DockPane_Close.Clone();
m_imageButtonWindowList = (Bitmap)Resources.DockPane_Option.Clone();
m_imageButtonWindowListOverflow = (Bitmap)Resources.DockPane_OptionOverflow.Clone();
}
ResumeLayout();
}
示例5: InitWindows
public void InitWindows( DockPane navigatorPane, DockPane outputPane )
{
availableTestStations = new AvailableTestStationsWindow();
availableTestStations.Show(DockPanel, DockState.DockRight);
availableTestStations.Hide();
//availableTestAdapters = new AvailableTestAdaptersWindow();
//availableTestAdapters.Show(navigatorPane, DockAlignment.Bottom, .60);
//availableTestAdapters.Hide();
availableInstruments = new AvailableInstrumentsWindow();
availableInstruments.Show(navigatorPane, DockAlignment.Bottom, .50);
availableInstruments.Hide();
requiredSignals = new RequiredSignalsWindow();
requiredSignals.Show(outputPane, DockAlignment.Right, .50 );
requiredSignals.Hide();
requiredSignals.SignalRequirementSelected += new ATMLManagerLibrary.delegates.ItemSelectionDeligate<ATMLModelLibrary.model.SignalRequirementsSignalRequirement>(requiredSignals_SignalRequirementSelected);
requiredInstruments = new RequiredInstrumentsWindow();
requiredInstruments.Show( requiredSignals.Pane, DockAlignment.Bottom, 0 );
requiredInstruments.DockTo(requiredSignals.Pane, DockStyle.Fill, 0 );
requiredInstruments.Hide();
requiredAdapters = new RequiredAdaptersWindow();
requiredAdapters.Show(requiredSignals.Pane, DockAlignment.Bottom, 0);
requiredAdapters.DockTo(requiredSignals.Pane, DockStyle.Fill, 0);
requiredAdapters.Hide();
}
示例6: DockTo
public void DockTo(DockPane pane, DockStyle dockStyle, int contentIndex)
{
if (dockStyle == DockStyle.Fill)
{
for (int i = NestedPanes.Count - 1; i >= 0; i--)
{
DockPane paneFrom = NestedPanes[i];
for (int j = paneFrom.Contents.Count - 1; j >= 0; j--)
{
IDockContent c = paneFrom.Contents[j];
c.DockHandler.Pane = pane;
if (contentIndex != -1)
pane.SetContentIndex(c, contentIndex);
c.DockHandler.Activate();
}
}
}
else
{
DockAlignment alignment = DockAlignment.Left;
if (dockStyle == DockStyle.Left)
alignment = DockAlignment.Left;
else if (dockStyle == DockStyle.Right)
alignment = DockAlignment.Right;
else if (dockStyle == DockStyle.Top)
alignment = DockAlignment.Top;
else if (dockStyle == DockStyle.Bottom)
alignment = DockAlignment.Bottom;
MergeNestedPanes(VisibleNestedPanes, pane.NestedPanesContainer.NestedPanes, pane, alignment, 0.5);
}
}
示例7: CustomFloatWindow
public CustomFloatWindow(DockPanel dockPanel, DockPane pane, Rectangle bounds)
: base(dockPanel, pane, bounds)
{
FormBorderStyle = FormBorderStyle.Sizable;
ShowInTaskbar = true;
Owner = null;
}
示例8: SetStatus
internal void SetStatus(NestedPaneCollection nestedPanes, DockPane previousPane, DockAlignment alignment, double proportion)
{
m_nestedPanes = nestedPanes;
m_previousPane = previousPane;
m_alignment = alignment;
m_proportion = proportion;
}
示例9: DockPane
protected internal DockPane(IDockContent content, DockPane previousPane, DockAlignment alignment,
double proportion, bool show)
{
if (previousPane == null)
throw (new ArgumentNullException("previousPane"));
InternalConstruct(content, previousPane.DockState, false, Rectangle.Empty, previousPane, alignment,
proportion, show);
}
示例10: VS2005DockPaneCaption
public VS2005DockPaneCaption(DockPane pane)
: base(pane)
{
this.SuspendLayout();
this.m_components = new Container();
this.m_toolTip = new ToolTip(this.Components);
this.ResumeLayout();
}
示例11: DockPaneCaptionBase
protected internal DockPaneCaptionBase(DockPane pane)
{
this.m_dockPane = pane;
this.SetStyle(
ControlStyles.OptimizedDoubleBuffer | ControlStyles.ResizeRedraw | ControlStyles.UserPaint
| ControlStyles.AllPaintingInWmPaint, true);
this.SetStyle(ControlStyles.Selectable, false);
}
示例12: SetActivePane
private void SetActivePane()
{
DockPane value = (ActiveContent == null ? null : ActiveContent.DockHandler.Pane);
if (value == m_activePane)
return;
m_activePane = value;
}
示例13: VS2012LightSplitterControl
public VS2012LightSplitterControl(DockPane pane)
: base(pane)
{
_horizontalBrush = new SolidBrush(pane.DockPanel.Skin.DockPaneStripSkin.DocumentGradient.ActiveTabGradient.EndColor);
this._verticalSurroundColors = new[]
{
pane.DockPanel.Skin.DockPaneStripSkin.DocumentGradient
.InactiveTabGradient.StartColor
};
}
示例14: VS2012DockPaneCaption
public VS2012DockPaneCaption(DockPane pane)
: base(pane)
{
SuspendLayout();
m_components = new Container();
m_toolTip = new ToolTip(Components);
ResumeLayout();
}
示例15: VS2012SplitterControl
public VS2012SplitterControl(DockPane pane)
: base(pane)
{
_horizontalBrush = pane.DockPanel.Theme.PaintingService.GetBrush(pane.DockPanel.Skin.ColorPalette.TabSelectedInactive.Background);
_backgroundBrush = pane.DockPanel.Theme.PaintingService.GetBrush(pane.DockPanel.Skin.ColorPalette.MainWindowActive.Background);
this._verticalSurroundColors = new[]
{
pane.DockPanel.Skin.ColorPalette.TabSelectedInactive.Background
};
}