效果图: 笔记分享: https://www.yuque.com/docs/share/4aac743b-1ff0-42d2-9ec3-c605c145a58e?# 《WPF 自定义简单的TextBox控件》