(五十六)c#Winform自定义控件-瓶子(工业)-HZHControls
官网
前提
入行已经7,8年了,一直想做一套漂亮点的自定义控件,于是就有了本系列文章。
GitHub:https://github.com/kwwwvagaa/NetWinformControl
码云:https://gitee.com/kwwwvagaa/net_winform_custom_control.git
如果觉得写的还行,请点个 star 支持一下吧
欢迎前来交流探讨: 企鹅群568015492
麻烦博客下方点个【推荐】,谢谢
NuGet
Install-Package HZH_Controls
目录
https://www.cnblogs.com/bfyx/p/11364884.html
用处及效果
准备工作
依然是GDI+ 不了解请先百度一下
开始
添加一个类UCBottle,继承UserControl
添加几个控制属性
//瓶身区域
/// <summary>
/// The m working rect
/// </summary>
Rectangle m_workingRect; /// <summary>
/// The title
/// </summary>
string title = "瓶子1"; /// <summary>
/// Gets or sets the title.
/// </summary>
/// <value>The title.</value>
[Description("标题"), Category("自定义")]
public string Title
{
get { return title; }
set
{
title = value;
ResetWorkingRect();
Refresh();
}
} /// <summary>
/// The bottle color
/// </summary>
private Color bottleColor = Color.FromArgb(, , ); /// <summary>
/// Gets or sets the color of the bottle.
/// </summary>
/// <value>The color of the bottle.</value>
[Description("瓶子颜色"), Category("自定义")]
public Color BottleColor
{
get { return bottleColor; }
set
{
bottleColor = value;
Refresh();
}
} /// <summary>
/// The bottle mouth color
/// </summary>
private Color bottleMouthColor = Color.FromArgb(, , ); /// <summary>
/// Gets or sets the color of the bottle mouth.
/// </summary>
/// <value>The color of the bottle mouth.</value>
[Description("瓶口颜色"), Category("自定义")]
public Color BottleMouthColor
{
get { return bottleMouthColor; }
set { bottleMouthColor = value; }
} /// <summary>
/// The liquid color
/// </summary>
private Color liquidColor = Color.FromArgb(, , ); /// <summary>
/// Gets or sets the color of the liquid.
/// </summary>
/// <value>The color of the liquid.</value>
[Description("液体颜色"), Category("自定义")]
public Color LiquidColor
{
get { return liquidColor; }
set
{
liquidColor = value;
Refresh();
}
} /// <summary>
/// 获取或设置控件显示的文字的字体。
/// </summary>
/// <value>The font.</value>
/// <PermissionSet>
/// <IPermission class="System.Security.Permissions.EnvironmentPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true" />
/// <IPermission class="System.Security.Permissions.FileIOPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true" />
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="UnmanagedCode, ControlEvidence" />
/// <IPermission class="System.Diagnostics.PerformanceCounterPermission, System, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true" />
/// </PermissionSet>
[Description("文字字体"), Category("自定义")]
public override Font Font
{
get
{
return base.Font;
}
set
{
base.Font = value;
ResetWorkingRect();
Refresh();
}
} /// <summary>
/// 获取或设置控件的前景色。
/// </summary>
/// <value>The color of the fore.</value>
/// <PermissionSet>
/// <IPermission class="System.Security.Permissions.FileIOPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true" />
/// </PermissionSet>
[Description("文字颜色"), Category("自定义")]
public override System.Drawing.Color ForeColor
{
get
{
return base.ForeColor;
}
set
{
base.ForeColor = value;
Refresh();
}
} /// <summary>
/// The maximum value
/// </summary>
private decimal maxValue = ; /// <summary>
/// Gets or sets the maximum value.
/// </summary>
/// <value>The maximum value.</value>
[Description("最大值"), Category("自定义")]
public decimal MaxValue
{
get { return maxValue; }
set
{
if (value < m_value)
return;
maxValue = value;
Refresh();
}
} /// <summary>
/// The m value
/// </summary>
private decimal m_value = ; /// <summary>
/// Gets or sets the value.
/// </summary>
/// <value>The value.</value>
[Description("值"), Category("自定义")]
public decimal Value
{
get { return m_value; }
set
{
if (value <= || value > maxValue)
return;
m_value = value;
Refresh();
}
} /// <summary>
/// The m no
/// </summary>
private string m_NO;
/// <summary>
/// Gets or sets the NO.
/// </summary>
/// <value>The no.</value>
[Description("编号"), Category("自定义")]
public string NO
{
get { return m_NO; }
set
{
m_NO = value;
Refresh();
}
}
重绘
protected override void OnPaint(PaintEventArgs e)
{
base.OnPaint(e);
var g = e.Graphics;
g.SetGDIHigh();
//写文字
var size = g.MeasureString(title, Font);
g.DrawString(title, Font, new SolidBrush(ForeColor), new PointF((this.Width - size.Width) / , )); //画空瓶子
GraphicsPath pathPS = new GraphicsPath();
Point[] psPS = new Point[]
{
new Point(m_workingRect.Left, m_workingRect.Top),
new Point(m_workingRect.Right - , m_workingRect.Top),
new Point(m_workingRect.Right - , m_workingRect.Bottom - ),
new Point(m_workingRect.Right - - m_workingRect.Width / , m_workingRect.Bottom),
new Point(m_workingRect.Left + m_workingRect.Width / , m_workingRect.Bottom),
new Point(m_workingRect.Left, m_workingRect.Bottom - ),
};
pathPS.AddLines(psPS);
pathPS.CloseAllFigures();
g.FillPath(new SolidBrush(bottleColor), pathPS);
//画液体
decimal decYTHeight = (m_value / maxValue) * m_workingRect.Height;
GraphicsPath pathYT = new GraphicsPath();
Rectangle rectYT = Rectangle.Empty;
if (decYTHeight < )
{
PointF[] psYT = new PointF[]
{
new PointF((float)(m_workingRect.Left+(-decYTHeight))+,(float)(m_workingRect.Bottom-decYTHeight)),
new PointF((float)(m_workingRect.Right-(-decYTHeight))-,(float)(m_workingRect.Bottom-decYTHeight)),
new PointF(m_workingRect.Right--m_workingRect.Width/, m_workingRect.Bottom),
new PointF(m_workingRect.Left+m_workingRect.Width/, m_workingRect.Bottom),
};
pathYT.AddLines(psYT);
pathYT.CloseAllFigures();
rectYT = new Rectangle((m_workingRect.Left + ( - (int)decYTHeight)) + , m_workingRect.Bottom - (int)decYTHeight - , m_workingRect.Width - (int)( - decYTHeight) * - , );
}
else
{
PointF[] psYT = new PointF[]
{
new PointF(m_workingRect.Left,(float)(m_workingRect.Bottom-decYTHeight)),
new PointF(m_workingRect.Right-,(float)(m_workingRect.Bottom-decYTHeight)),
new PointF(m_workingRect.Right-,m_workingRect.Bottom-),
new PointF(m_workingRect.Right--m_workingRect.Width/, m_workingRect.Bottom),
new PointF(m_workingRect.Left+m_workingRect.Width/, m_workingRect.Bottom),
new PointF(m_workingRect.Left,m_workingRect.Bottom-),
};
pathYT.AddLines(psYT);
pathYT.CloseAllFigures();
rectYT = new Rectangle(m_workingRect.Left, m_workingRect.Bottom - (int)decYTHeight - , m_workingRect.Width, );
} g.FillPath(new SolidBrush(liquidColor), pathYT);
g.FillPath(new SolidBrush(Color.FromArgb(, bottleMouthColor)), pathYT);
//画液体面
g.FillEllipse(new SolidBrush(liquidColor), rectYT);
g.FillEllipse(new SolidBrush(Color.FromArgb(, Color.White)), rectYT); //画高亮
int intCount = m_workingRect.Width / / ;
int intSplit = ( - ) / intCount;
for (int i = ; i < intCount; i++)
{
int _penWidth = m_workingRect.Width / - * i;
if (_penWidth <= )
_penWidth = ;
g.DrawLine(new Pen(new SolidBrush(Color.FromArgb(, Color.White)), _penWidth), new Point(m_workingRect.Width / , m_workingRect.Top), new Point(m_workingRect.Width / , m_workingRect.Bottom - ));
if (_penWidth == )
break;
} //画瓶底
g.FillEllipse(new SolidBrush(bottleColor), new RectangleF(m_workingRect.Left, m_workingRect.Top - , m_workingRect.Width - , ));
g.FillEllipse(new SolidBrush(Color.FromArgb(, Color.White)), new RectangleF(m_workingRect.Left, m_workingRect.Top - , m_workingRect.Width - , ));
//画瓶口
g.FillRectangle(new SolidBrush(bottleMouthColor), new Rectangle(m_workingRect.Left + m_workingRect.Width / , m_workingRect.Bottom, m_workingRect.Width / , ));
//画瓶颈阴影
GraphicsPath pathPJ = new GraphicsPath();
Point[] psPJ = new Point[]
{
new Point(m_workingRect.Left, m_workingRect.Bottom-),
new Point(m_workingRect.Right-, m_workingRect.Bottom-),
new Point(m_workingRect.Right--m_workingRect.Width/, m_workingRect.Bottom),
new Point(m_workingRect.Left+m_workingRect.Width/, m_workingRect.Bottom)
};
pathPJ.AddLines(psPJ);
pathPJ.CloseAllFigures();
g.FillPath(new SolidBrush(Color.FromArgb(, bottleMouthColor)), pathPJ); //写编号
if (!string.IsNullOrEmpty(m_NO))
{
var nosize = g.MeasureString(m_NO, Font);
g.DrawString(m_NO, Font, new SolidBrush(ForeColor), new PointF((this.Width - nosize.Width) / , m_workingRect.Top + ));
}
}
代码就这么多
完整代码
// ***********************************************************************
// Assembly : HZH_Controls
// Created : 2019-09-05
//
// ***********************************************************************
// <copyright file="UCBottle.cs">
// Copyright by Huang Zhenghui(黄正辉) All, QQ group:568015492 QQ:623128629 Email:623128629@qq.com
// </copyright>
//
// Blog: https://www.cnblogs.com/bfyx
// GitHub:https://github.com/kwwwvagaa/NetWinformControl
// gitee:https://gitee.com/kwwwvagaa/net_winform_custom_control.git
//
// If you use this code, please keep this note.
// ***********************************************************************
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Drawing;
using System.Drawing.Drawing2D;
using System.ComponentModel; namespace HZH_Controls.Controls
{
/// <summary>
/// Class UCBottle.
/// Implements the <see cref="System.Windows.Forms.UserControl" />
/// </summary>
/// <seealso cref="System.Windows.Forms.UserControl" />
public class UCBottle : UserControl
{
//瓶身区域
/// <summary>
/// The m working rect
/// </summary>
Rectangle m_workingRect; /// <summary>
/// The title
/// </summary>
string title = "瓶子1"; /// <summary>
/// Gets or sets the title.
/// </summary>
/// <value>The title.</value>
[Description("标题"), Category("自定义")]
public string Title
{
get { return title; }
set
{
title = value;
ResetWorkingRect();
Refresh();
}
} /// <summary>
/// The bottle color
/// </summary>
private Color bottleColor = Color.FromArgb(, , ); /// <summary>
/// Gets or sets the color of the bottle.
/// </summary>
/// <value>The color of the bottle.</value>
[Description("瓶子颜色"), Category("自定义")]
public Color BottleColor
{
get { return bottleColor; }
set
{
bottleColor = value;
Refresh();
}
} /// <summary>
/// The bottle mouth color
/// </summary>
private Color bottleMouthColor = Color.FromArgb(, , ); /// <summary>
/// Gets or sets the color of the bottle mouth.
/// </summary>
/// <value>The color of the bottle mouth.</value>
[Description("瓶口颜色"), Category("自定义")]
public Color BottleMouthColor
{
get { return bottleMouthColor; }
set { bottleMouthColor = value; }
} /// <summary>
/// The liquid color
/// </summary>
private Color liquidColor = Color.FromArgb(, , ); /// <summary>
/// Gets or sets the color of the liquid.
/// </summary>
/// <value>The color of the liquid.</value>
[Description("液体颜色"), Category("自定义")]
public Color LiquidColor
{
get { return liquidColor; }
set
{
liquidColor = value;
Refresh();
}
} /// <summary>
/// 获取或设置控件显示的文字的字体。
/// </summary>
/// <value>The font.</value>
/// <PermissionSet>
/// <IPermission class="System.Security.Permissions.EnvironmentPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true" />
/// <IPermission class="System.Security.Permissions.FileIOPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true" />
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="UnmanagedCode, ControlEvidence" />
/// <IPermission class="System.Diagnostics.PerformanceCounterPermission, System, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true" />
/// </PermissionSet>
[Description("文字字体"), Category("自定义")]
public override Font Font
{
get
{
return base.Font;
}
set
{
base.Font = value;
ResetWorkingRect();
Refresh();
}
} /// <summary>
/// 获取或设置控件的前景色。
/// </summary>
/// <value>The color of the fore.</value>
/// <PermissionSet>
/// <IPermission class="System.Security.Permissions.FileIOPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true" />
/// </PermissionSet>
[Description("文字颜色"), Category("自定义")]
public override System.Drawing.Color ForeColor
{
get
{
return base.ForeColor;
}
set
{
base.ForeColor = value;
Refresh();
}
} /// <summary>
/// The maximum value
/// </summary>
private decimal maxValue = ; /// <summary>
/// Gets or sets the maximum value.
/// </summary>
/// <value>The maximum value.</value>
[Description("最大值"), Category("自定义")]
public decimal MaxValue
{
get { return maxValue; }
set
{
if (value < m_value)
return;
maxValue = value;
Refresh();
}
} /// <summary>
/// The m value
/// </summary>
private decimal m_value = ; /// <summary>
/// Gets or sets the value.
/// </summary>
/// <value>The value.</value>
[Description("值"), Category("自定义")]
public decimal Value
{
get { return m_value; }
set
{
if (value <= || value > maxValue)
return;
m_value = value;
Refresh();
}
} /// <summary>
/// The m no
/// </summary>
private string m_NO;
/// <summary>
/// Gets or sets the NO.
/// </summary>
/// <value>The no.</value>
[Description("编号"), Category("自定义")]
public string NO
{
get { return m_NO; }
set
{
m_NO = value;
Refresh();
}
} /// <summary>
/// Initializes a new instance of the <see cref="UCBottle" /> class.
/// </summary>
public UCBottle()
{
this.SetStyle(ControlStyles.AllPaintingInWmPaint, true);
this.SetStyle(ControlStyles.DoubleBuffer, true);
this.SetStyle(ControlStyles.ResizeRedraw, true);
this.SetStyle(ControlStyles.Selectable, true);
this.SetStyle(ControlStyles.SupportsTransparentBackColor, true);
this.SetStyle(ControlStyles.UserPaint, true);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.SizeChanged += UCBottle_SizeChanged;
this.Size = new Size(, );
} /// <summary>
/// Handles the SizeChanged event of the UCBottle control.
/// </summary>
/// <param name="sender">The source of the event.</param>
/// <param name="e">The <see cref="EventArgs"/> instance containing the event data.</param>
void UCBottle_SizeChanged(object sender, EventArgs e)
{
ResetWorkingRect();
} /// <summary>
/// Resets the working rect.
/// </summary>
private void ResetWorkingRect()
{
var g = this.CreateGraphics();
var size = g.MeasureString(title, Font);
m_workingRect = new Rectangle(, (int)size.Height + , this.Width, this.Height - ((int)size.Height + ) - );
} /// <summary>
/// 引发 <see cref="E:System.Windows.Forms.Control.Paint" /> 事件。
/// </summary>
/// <param name="e">包含事件数据的 <see cref="T:System.Windows.Forms.PaintEventArgs" />。</param>
protected override void OnPaint(PaintEventArgs e)
{
base.OnPaint(e);
var g = e.Graphics;
g.SetGDIHigh();
//写文字
var size = g.MeasureString(title, Font);
g.DrawString(title, Font, new SolidBrush(ForeColor), new PointF((this.Width - size.Width) / , )); //画空瓶子
GraphicsPath pathPS = new GraphicsPath();
Point[] psPS = new Point[]
{
new Point(m_workingRect.Left, m_workingRect.Top),
new Point(m_workingRect.Right - , m_workingRect.Top),
new Point(m_workingRect.Right - , m_workingRect.Bottom - ),
new Point(m_workingRect.Right - - m_workingRect.Width / , m_workingRect.Bottom),
new Point(m_workingRect.Left + m_workingRect.Width / , m_workingRect.Bottom),
new Point(m_workingRect.Left, m_workingRect.Bottom - ),
};
pathPS.AddLines(psPS);
pathPS.CloseAllFigures();
g.FillPath(new SolidBrush(bottleColor), pathPS);
//画液体
decimal decYTHeight = (m_value / maxValue) * m_workingRect.Height;
GraphicsPath pathYT = new GraphicsPath();
Rectangle rectYT = Rectangle.Empty;
if (decYTHeight < )
{
PointF[] psYT = new PointF[]
{
new PointF((float)(m_workingRect.Left+(-decYTHeight))+,(float)(m_workingRect.Bottom-decYTHeight)),
new PointF((float)(m_workingRect.Right-(-decYTHeight))-,(float)(m_workingRect.Bottom-decYTHeight)),
new PointF(m_workingRect.Right--m_workingRect.Width/, m_workingRect.Bottom),
new PointF(m_workingRect.Left+m_workingRect.Width/, m_workingRect.Bottom),
};
pathYT.AddLines(psYT);
pathYT.CloseAllFigures();
rectYT = new Rectangle((m_workingRect.Left + ( - (int)decYTHeight)) + , m_workingRect.Bottom - (int)decYTHeight - , m_workingRect.Width - (int)( - decYTHeight) * - , );
}
else
{
PointF[] psYT = new PointF[]
{
new PointF(m_workingRect.Left,(float)(m_workingRect.Bottom-decYTHeight)),
new PointF(m_workingRect.Right-,(float)(m_workingRect.Bottom-decYTHeight)),
new PointF(m_workingRect.Right-,m_workingRect.Bottom-),
new PointF(m_workingRect.Right--m_workingRect.Width/, m_workingRect.Bottom),
new PointF(m_workingRect.Left+m_workingRect.Width/, m_workingRect.Bottom),
new PointF(m_workingRect.Left,m_workingRect.Bottom-),
};
pathYT.AddLines(psYT);
pathYT.CloseAllFigures();
rectYT = new Rectangle(m_workingRect.Left, m_workingRect.Bottom - (int)decYTHeight - , m_workingRect.Width, );
} g.FillPath(new SolidBrush(liquidColor), pathYT);
g.FillPath(new SolidBrush(Color.FromArgb(, bottleMouthColor)), pathYT);
//画液体面
g.FillEllipse(new SolidBrush(liquidColor), rectYT);
g.FillEllipse(new SolidBrush(Color.FromArgb(, Color.White)), rectYT); //画高亮
int intCount = m_workingRect.Width / / ;
int intSplit = ( - ) / intCount;
for (int i = ; i < intCount; i++)
{
int _penWidth = m_workingRect.Width / - * i;
if (_penWidth <= )
_penWidth = ;
g.DrawLine(new Pen(new SolidBrush(Color.FromArgb(, Color.White)), _penWidth), new Point(m_workingRect.Width / , m_workingRect.Top), new Point(m_workingRect.Width / , m_workingRect.Bottom - ));
if (_penWidth == )
break;
} //画瓶底
g.FillEllipse(new SolidBrush(bottleColor), new RectangleF(m_workingRect.Left, m_workingRect.Top - , m_workingRect.Width - , ));
g.FillEllipse(new SolidBrush(Color.FromArgb(, Color.White)), new RectangleF(m_workingRect.Left, m_workingRect.Top - , m_workingRect.Width - , ));
//画瓶口
g.FillRectangle(new SolidBrush(bottleMouthColor), new Rectangle(m_workingRect.Left + m_workingRect.Width / , m_workingRect.Bottom, m_workingRect.Width / , ));
//画瓶颈阴影
GraphicsPath pathPJ = new GraphicsPath();
Point[] psPJ = new Point[]
{
new Point(m_workingRect.Left, m_workingRect.Bottom-),
new Point(m_workingRect.Right-, m_workingRect.Bottom-),
new Point(m_workingRect.Right--m_workingRect.Width/, m_workingRect.Bottom),
new Point(m_workingRect.Left+m_workingRect.Width/, m_workingRect.Bottom)
};
pathPJ.AddLines(psPJ);
pathPJ.CloseAllFigures();
g.FillPath(new SolidBrush(Color.FromArgb(, bottleMouthColor)), pathPJ); //写编号
if (!string.IsNullOrEmpty(m_NO))
{
var nosize = g.MeasureString(m_NO, Font);
g.DrawString(m_NO, Font, new SolidBrush(ForeColor), new PointF((this.Width - nosize.Width) / , m_workingRect.Top + ));
}
}
}
}
最后的话
如果你喜欢的话,请到 https://gitee.com/kwwwvagaa/net_winform_custom_control 点个星星吧
(五十六)c#Winform自定义控件-瓶子(工业)-HZHControls的更多相关文章
- (五十)c#Winform自定义控件-滑块
前提 入行已经7,8年了,一直想做一套漂亮点的自定义控件,于是就有了本系列文章. GitHub:https://github.com/kwwwvagaa/NetWinformControl 码云:ht ...
- (八十)c#Winform自定义控件-分割线标签-HZHControls
官网 http://www.hzhcontrols.com 前提 入行已经7,8年了,一直想做一套漂亮点的自定义控件,于是就有了本系列文章. GitHub:https://github.com/kww ...
- (五十一)c#Winform自定义控件-文字提示-HZHControls
官网 http://www.hzhcontrols.com 前提 入行已经7,8年了,一直想做一套漂亮点的自定义控件,于是就有了本系列文章. GitHub:https://github.com/kww ...
- 【Visual C++】游戏开发五十六 浅墨DirectX教程二十三 打造游戏GUI界面(一)
本系列文章由zhmxy555(毛星云)编写,转载请注明出处. 文章链接:http://blog.csdn.net/poem_qianmo/article/details/16384009 作者:毛星云 ...
- 第三百五十六节,Python分布式爬虫打造搜索引擎Scrapy精讲—scrapy分布式爬虫要点
第三百五十六节,Python分布式爬虫打造搜索引擎Scrapy精讲—scrapy分布式爬虫要点 1.分布式爬虫原理 2.分布式爬虫优点 3.分布式爬虫需要解决的问题
- “全栈2019”Java第五十六章:多态与字段详解
难度 初级 学习时间 10分钟 适合人群 零基础 开发语言 Java 开发环境 JDK v11 IntelliJ IDEA v2018.3 文章原文链接 "全栈2019"Java第 ...
- 《手把手教你》系列技巧篇(五十六)-java+ selenium自动化测试-下载文件-上篇(详细教程)
1.简介 前边几篇文章讲解完如何上传文件,既然有上传,那么就可能会有下载文件.因此宏哥就接着讲解和分享一下:自动化测试下载文件.可能有的小伙伴或者童鞋们会觉得这不是很简单吗,还用你介绍和讲解啊,不说就 ...
- (三十)c#Winform自定义控件-文本框(三)
前提 入行已经7,8年了,一直想做一套漂亮点的自定义控件,于是就有了本系列文章. 开源地址:https://gitee.com/kwwwvagaa/net_winform_custom_control ...
- Abp(net core)+easyui+efcore实现仓储管理系统——出库管理之七(五十六)
abp(net core)+easyui+efcore实现仓储管理系统目录 abp(net core)+easyui+efcore实现仓储管理系统--ABP总体介绍(一) abp(net core)+ ...
- (二十)c#Winform自定义控件-有后退的窗体
前提 入行已经7,8年了,一直想做一套漂亮点的自定义控件,于是就有了本系列文章. 开源地址:https://gitee.com/kwwwvagaa/net_winform_custom_control ...
随机推荐
- CSRF与auth模块
目录 一.模拟实现中间件的编程思想 (一)impotlib模块 (二)实现功能的配置使用 二.跨站请求伪造CSRF (一)由来 (二)form表单的CSRF (三)ajax中的CSRF (1)通过da ...
- 在Docker中跑Hadoop与镜像制作
重复造轮子,这里使用重新打包生成一个基于Docker的Hadoop镜像: Hadoop集群依赖的软件分别为:jdk.ssh等,所以只要这两项还有Hadoop相关打包进镜像中去即可: 配置文件准 ...
- SuperMap iDesktop .NET 10i制图技巧-----如何贴图
当我们在没有模型数据的情况下,我们只能通过造白膜来模拟三维建筑了,但是光秃秃的建筑物显然缺乏代入感,因此需要贴图来给场景润色,本文介绍如何给道路贴图和如何给白膜贴图 道路贴图: 1.打开二维道路数据 ...
- Android 菜单 使用XML
@Override public boolean onCreateOptionsMenu(Menu menu) { // Inflate the menu; this adds items to th ...
- STM32的Keil找不到想要flash的解决方法
STM32的Keil找不到想要flash的解决方法:https://blog.csdn.net/qq_38376586/article/details/79582020
- <离散数学>代数系统——群,半群
------运算的定义及性质 设S是一个非空集合,映射f:Sn->S称为S上的一个n元运算.假设“•”是定义在集合S上的一个二元运算.若: ∀x,y∈S,x•y∈S,则称“•”在S上是封闭的. ...
- mysql的锁机制详解
这段时间一直在学习mysql数据库.项目组一直用的是oracle,所以对mysql的了解也不深.本文主要是对mysql锁的总结. Mysql的锁主要分为3大类: 表级锁:存储引擎为Myisam.锁住整 ...
- Python 3.7的安装过程
百度云Pyhton3.7-32位安装包: 链接:https://pan.baidu.com/s/1P5Egkl2KNt_DjhiFaDzqsg提取码:5171 百度云Pyhton3.7-64位安装包: ...
- uml统一建模语言学习笔记(一)
UML是一种统一建模语言,他是以面向对象的方式来实现对任何的系统进行描述的一种语言, 它包括9种图形+包图,分为静态和动态两种,也就是结构图和行为图 “静态”图有:用例图.类图.对象图.部署图.构件图 ...
- JS PopupAlert
JS PopupAlert 可以在 JavaScript 中创建三种消息框:警告框.确认框.提示框. 警告框 警告框经常用于确保用户可以得到某些信息. 当警告框出现后,用户需要点击确定按钮才能继续进行 ...