如何删除IE中dijit.form.Button中的多余填充? [英] How to remove extra padding in dijit.form.Button in IE?

查看:81
本文介绍了如何删除IE中dijit.form.Button中的多余填充?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我们的应用程序中,有许多dijit.form.Button类型的dojo按钮。它在Firefox中工作正常。但是,在IE中,按钮中文本的左侧和右侧有多余的填充。填充的长度与按钮中文本的长度成比例。

In our application there are many dojo buttons of type dijit.form.Button. It works fine in Firefox. However, in IE, there are extra padding to the left and right of the texts in the button. The length of the padding is proportional to the length of the text in the button.

有什么方法可以删除这些填充?

Is there any way to remove those paddings?

我在网上搜索并找到了Button的方法,例如: http://www.viget.com/inspire/styling-the-button-element-in-internet-explorer/

I searched the web and found ways for Buttons, for example: http://www.viget.com/inspire/styling-the-button-element-in-internet-explorer/

但是,它不适用于dijit.form.Button。

However, it does not work for dijit.form.Button.

请注意,dijit.form.Button位于表单元格内。如果按钮不在表单元格中,似乎没问题(无填充)。

Note that the dijit.form.Button is inside table cells. It seems ok (no padding) if the button is not in table cells.

预先感谢。

推荐答案

DO:

.dijitButtonText
{
    padding:0pt;
}  

.dijitButtonText  
{       
    padding:0pt;
} 

.dijitButtonText
{      
    padding:0pt;
}

在CSS上....如果已将按钮分配给不同的baseClass ... do:

on your css....if you have assigned your buttons into different baseClass...do:

.myBaseClass .dijitButtonText
{
    padding:0pt;
}  

.myBaseClass .dijitButtonText  
{       
    padding:0pt;
} 

.myBaseClass .dijitButtonText
{      
    padding:0pt;
}

避免对每个dojo按钮进行全局更改。 ..

to avoid global change to every dojo button...

这篇关于如何删除IE中dijit.form.Button中的多余填充?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆