In firefox 3.6 you could use ::-moz-focus-inner {border:0;padding:0;margin:0;}
to remove those default margins and paddings forms.css
added.
How can I reset this in Firefox 4? I've been searching for any .css files inside the install directory that could add styles to my button but can't find any for ff4 - the button still gets that annoying 1px top padding that won't allow the text to align to vertical middle.
http://easwee.net/other/FF_problem.gif
EDIT: I use a reset stylesheet so no need to reset styles. It's a browser stylesheet that's messing here.
Click "View" on the toolbar, select "Page Style" and click "No Style" in the resulting sub-menu to disable the stylesheets. The stylesheets are disabled immediately.
#*If you're unable to access the Help menu, type '''about:support''' in your address bar to bring up the Troubleshooting Information page. #At the top right corner of the page, you should see a button that says "Refresh Firefox" ("Reset Firefox" in older Firefox versions). Click on it. #Firefox will close.
Fira Sans is the typeface used in Firefox web products. Despite Open Sans being used on some Mozilla web properties, it is currently not recommended for Firefox products. Roboto is the standard typeface on Android.
I actually found the solution myself.
In your url field type: resource://gre-resources/forms.css
- this will open forms.css for FF4 - and search for the following selector
button::-moz-focus-inner, input[type="reset"]::-moz-focus-inner, input[type="button"]::-moz-focus-inner, input[type="submit"]::-moz-focus-inner, input[type="file"] > input[type="button"]::-moz-focus-inner
Now just put that in your main stylesheet like:
button::-moz-focus-inner, input[type="reset"]::-moz-focus-inner, input[type="button"]::-moz-focus-inner, input[type="submit"]::-moz-focus-inner, input[type="file"] > input[type="button"]::-moz-focus-inner {border:0;padding:0;margin:0;}
It shouldn't be overriding your css anymore. Also note that if you haven't defined any font style for your inputs FF won't inherit body font styling.
try setting it's values to undefined (border:undefined
etc). not sure here, but it worked for me when I had a similiar problem.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With