我正在尝试为TextBox添加水印。TextBox.Background是System.Windows.Media.Brush。我需要Graphics.FillRectangle(System.Drawing.Brush ....)
有什么方法可以将mediea画笔转换为绘图画笔吗?
试试这个
System.Drawing.Brush b = new System.Drawing.SolidBrush((System.Drawing.Color)new System.Drawing.ColorConverter().ConvertFromString(new System.Windows.Media.BrushConverter().ConvertToString(mediabrush)));
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句