Closed Bug 110034 Opened 24 years ago Closed 22 years ago

by CSS defined borders for <INPUT type="radio">

Categories

(Core :: Layout: Form Controls, defect)

x86
Other
defect
Not set
normal

Tracking

()

RESOLVED WONTFIX
Future

People

(Reporter: tapio.markula, Assigned: kinmoz)

References

()

Details

The aim of CSS is to replace presentational features of HTML as far as possible. Concerning <INPUT type="radio"> Netscape 6.x/ corresponding Mozilla go too far, because official CSS-specification don't handle at this moment rounded borders. According to CSS2 the radio button should have additional rectangular borders. Rounded corners belong to CSS2 and in order to define them it is necessary to use such CSS-properties, which don't belong to CSS2
Tapio's comment (making it not all be one line): The aim of CSS is to replace presentational features of HTML as far as possible. Concerning <INPUT type="radio"> Netscape 6.x/ corresponding Mozilla go too far, because official CSS-specification don't handle at this moment rounded borders. According to CSS2 the radio button should have additional rectangular borders. Rounded corners belong to CSS2 and in order to define them it is necessary to use such CSS-properties, which don't belong to CSS2 ---------------------- ==> form controls. note that the CSS spec is completely undefined as to whether form controls are styleable at all and if so in what ways, so nothing we do here is actually wrong or right, merely reasonable or unreasonable.
Assignee: attinasi → rods
Status: UNCONFIRMED → NEW
Component: Layout → HTML Form Controls
Ever confirmed: true
QA Contact: petersen → madhur
Status: NEW → ASSIGNED
Target Milestone: --- → Future
Boris, it is truly unfortunate that the CSS specifications do not address form elements, even in a provisionary way. I am curious as to whom among the Mozilla team has made some of the decisions about which features of form elements are "stylable" in author stylesheets and which are not. I would like to try to convince this person to grant more freedom to authors. As a specific example, I have noted that it is possible to remove the outset/inset borders on text inputs and textareas, but it not possible to do so on checkboxes, radio buttons, or select lists. The border-style and border-width of these latter form elements are flagged as !important in forms.css. Hence, it is possible for me to develop a stylesheet that sets the border of text inputs and textareas to a two-pixel wide solid color, but I cannot do the same for the remaining form elements. What is the underlying rationale for this inconsistency? I am merely curious (mostly because I would really like to be able to build a totally customized stylesheet for form elements). Thanks.
The basic reason is that it's imposible to make <input type="text"> invisible by disabling its border. It's possible to do it for <input type="radio/checkbox"> and a number of sites unfortunately do just that.
I think GetFrameForPoint does this (not sure), nsGFXTextControlFrame orrides this and returns the "Stack" frame. Kin?
Assignee: rods → kin
Status: ASSIGNED → NEW
er? What does GetFrameForPoint() have to do with this? The issue here is the !important rules in forms.css... Also note that we _do_ support the CSS3 border-radius stuff, which is what we use for these elements... Also, note that checkboxes are not at all relevant to the original bug report, since checkbox borders _are_ perfectly well describable by CSS2.
The last I heard there is no CSS specification for describing how style applies to form controls. It does not matter that checkboxes etc. CAN be described by CSS2 and CSS3 is still off in commitee as far as I know. One of the single biggest misteps we EVER took in Gecko was leading people to think they could style form controls via their own style sheets. ALL the rules should have had !important on them from the beginning.
Whilst CSS1/2 migth be a bit vague on form control styling, CSS3 selectors (candidate recommendation) clearly has pseudo-classes aimed at things like radio buttons (:checked, :unchecked, :indeterminate), so in the long term it looks like form controls will need the ability to be fully CSS-stylable. It certainly doesn't help web developers that the styling of <input>s is so horribly inconsistent at the minute.
This bug is requesting an extra square border around the round button, and that's not going to happen. The rest of the argument is not really about this bug.
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.