Source/Design/ExpandablePanelDesigner.cs
(开头部分) 3KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System.Collections;
using System.ComponentModel;
using System.ComponentModel.Design;
using System;
using System.Drawing;
namespace DevComponents.DotNetBar.Design
{
public class ExpandablePanelDesigner : PanelExDesigner
{
#region Internal Implementation
#if FRAMEWORK20
public override void InitializeNewComponent(IDictionary defaultValues)
{
base.InitializeNewComponent(defaultValues);
SetDesignTimeDefaults();
}
#else
public override void OnSetComponentDefaults()
{
base.OnSetComponentDefaults();
SetDesignTimeDefaults();
}
#endif
private void SetDesignTimeDefaults()
{
ExpandablePanel p = this.Control as ExpandablePanel;
if (p == null)
return;
p.ApplyLabelStyle();
p.Style.BorderColor.ColorSchemePart = eColorSchemePart.BarDockedBorder;
p.Style.Border = eBorderType.SingleLine;
p.Style.BackColor1.ColorSchemePart = eColorSchemePart.PanelBackground;
p.Style.BackColor2.ColorSchemePart = eColorSchemePart.PanelBackground2;
p.Text = "";
p.TitlePanel.ApplyPanelStyle();
this.ColorSchemeStyle = eDotNetBarStyle.Office2007;
}
protected override void PreFilterProperties(IDictionary properties)
{
base.PreFilterProperties(properties);
properties["ColorSchemeStyle"] = TypeDescriptor.CreateProperty(typeof(ExpandablePanelDesigner), (PropertyDescriptor)properties["ColorSchemeStyle"], new Attribute[]
{
new DefaultValueAttribute(eDotNetBarStyle.Office2003),
new BrowsableAttribute(true),
new CategoryAttribute("Style"),
new DescriptionAttribute("Gets or sets color scheme style.")});
}
/// <summary>
/// Gets or sets color scheme style.
/// </summary>
[Browsable(true), DevCoBrowsable(true), Category("Style"), Description("Gets or sets color scheme style."), DefaultValue(eDotNetBarStyle.Office2003)]
public eDotNetBarStyle ColorSchemeStyle
{
get
{
后面还有 36 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。