WPF之Label

Label在wpf中表示控件的文本标签,并提供访问密钥支持。

常用属性:

|----------------------------|----------|
| HorizontalContentAlignment | 文本水平内容排列 |
| VerticalContentAlignment | 垂直内容排列 |
| width | 宽 |
| height | 高 |
| fontsize | 字体大小 |
| fontfamily | 字体样式 |
| fontwidth | 字体粗细 |
[属性]

具体写法

cs 复制代码
<Label Width="200" Height="40" 
       Background="Red" 
       Content="我是Label" 
       HorizontalContentAlignment="Center"
       VerticalContentAlignment="Center"
       FontSize="17" Margin="0,0,350,250"
       Name="l1">
</Label>
相关推荐
氵文大师15 小时前
A机通过 python -m http.server 下载B机的文件
linux·开发语言·python·http
封奚泽优16 小时前
下降算法(Python实现)
开发语言·python·算法
笃行客从不躺平16 小时前
遇到大SQL怎么处理
java·开发语言·数据库·sql
郝学胜-神的一滴16 小时前
Python中常见的内置类型
开发语言·python·程序人生·个人开发
g***B73816 小时前
Kotlin协程在Android中的使用
android·开发语言·kotlin
火白学安全16 小时前
《Python红队攻防零基础脚本编写:进阶篇(一)》
开发语言·python·安全·web安全·网络安全·系统安全
爱码小白16 小时前
PyQt5 QTimer总结
开发语言·qt
A***279517 小时前
Kotlin反射机制
android·开发语言·kotlin
E***q53917 小时前
C++内存对齐优化
开发语言·c++
q***d17317 小时前
Kotlin在后台服务中的框架
android·开发语言·kotlin