Sar*_*arz 3 java primefaces jsf-2
我的工作环境是:使用JSF 2.0的Primefaces 4.0我的目的是在窗体中设置命令按钮的宽度相同.我发现style="font-size:10px"设置按钮的字体大小正在改变按钮的标签大小.我想改变按钮的大小
您可以在commandButton中使用style属性以及css属性width和height.
<p:commandButton id="button" value="Click"
actionListener="#{myBean.doAction}"
style="width:100px;height:100px"/>
Run Code Online (Sandbox Code Playgroud)
要为页面上的所有commandButtons设置相同的值,请将以下css添加到jsf页面.
.ui-button{
width:100px;
height:100px;
}
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
30805 次 |
| 最近记录: |