* UITextBox: 修复了无水印文字时,光标有时不显示的问题
This commit is contained in:
parent
7bf2f55173
commit
e351e113ee
@ -77,6 +77,7 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private void waterMarkContainer_Paint(object sender, PaintEventArgs e)
|
private void waterMarkContainer_Paint(object sender, PaintEventArgs e)
|
||||||
{
|
{
|
||||||
|
waterMarkContainer.Visible = Watermark.IsValid();
|
||||||
waterMarkContainer.Location = new Point(2, 0);
|
waterMarkContainer.Location = new Point(2, 0);
|
||||||
waterMarkContainer.Height = this.Height;
|
waterMarkContainer.Height = this.Height;
|
||||||
waterMarkContainer.Width = this.Width;
|
waterMarkContainer.Width = this.Width;
|
||||||
@ -158,9 +159,13 @@ namespace Sunny.UI
|
|||||||
protected override void OnInvalidated(InvalidateEventArgs e)
|
protected override void OnInvalidated(InvalidateEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnInvalidated(e);
|
base.OnInvalidated(e);
|
||||||
|
|
||||||
if (waterMarkContainer != null)
|
if (waterMarkContainer != null)
|
||||||
|
{
|
||||||
|
waterMarkContainer.Visible = Watermark.IsValid();
|
||||||
waterMarkContainer.Invalidate();
|
waterMarkContainer.Invalidate();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
[Browsable(false), DefaultValue(false)]
|
[Browsable(false), DefaultValue(false)]
|
||||||
public bool IsScaled { get; set; }
|
public bool IsScaled { get; set; }
|
||||||
|
@ -37,6 +37,7 @@
|
|||||||
* 2022-06-23: V3.2.0 重写水印文字,解决不同背景色下泛白的问题
|
* 2022-06-23: V3.2.0 重写水印文字,解决不同背景色下泛白的问题
|
||||||
* 2022-07-17: V3.2.1 增加SelectionChanged事件
|
* 2022-07-17: V3.2.1 增加SelectionChanged事件
|
||||||
* 2022-07-28: V3.2.2 修复了有水印文字时,不响应Click和DoubleClick事件的问题
|
* 2022-07-28: V3.2.2 修复了有水印文字时,不响应Click和DoubleClick事件的问题
|
||||||
|
* 2022-09-05: V3.2.3 修复了无水印文字时,光标有时不显示的问题
|
||||||
******************************************************************************/
|
******************************************************************************/
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user