DotNet 4.8.1 build of DotNetBar

This commit is contained in:
2025-02-07 10:35:23 -05:00
parent 33439b63a0
commit 6b0a5d60f4
2609 changed files with 989814 additions and 7 deletions

View File

@@ -0,0 +1,47 @@
using System.Drawing;
using System.Drawing.Drawing2D;
namespace DevComponents.Tree
{
namespace Display
{
/// <summary>
/// Base class for node expand button display.
/// </summary>
public abstract class NodeExpandDisplay
{
/// <summary>Creates new instance of the class</summary>
public NodeExpandDisplay()
{
}
/// <summary>Draws expand button.</summary>
/// <param name="e">Context parameters for drawing expand button.</param>
public abstract void DrawExpandButton(NodeExpandPartRendererEventArgs e);
protected Pen GetBorderPen(NodeExpandPartRendererEventArgs e)
{
return new Pen(e.BorderColor, Dpi.Width1);
}
protected Pen GetExpandPen(NodeExpandPartRendererEventArgs e)
{
return new Pen(e.ExpandLineColor,Dpi.Width1);
}
protected Brush GetBackgroundBrush(NodeExpandPartRendererEventArgs e)
{
if(e.BackColor.IsEmpty && e.BackColor2.IsEmpty)
return null;
if(e.BackColor2.IsEmpty)
return new SolidBrush(e.BackColor);
System.Drawing.Drawing2D.LinearGradientBrush brush=DisplayHelp.CreateLinearGradientBrush(e.ExpandPartBounds,e.BackColor,e.BackColor2,e.BackColorGradientAngle);
//brush.SetSigmaBellShape(0.8f);
return brush;
}
}
}
}