Closed Bug 482692 Opened 14 years ago Closed 13 years ago
Should be able to override -moz-border-colors with border-color
Take http://mxr.mozilla.org/mozilla-central/source/toolkit/themes/pinstripe/global/textbox.css for example. It uses -moz-border-*-colors, and whenever you use -moz-appearance:none to manually style a particular textbox, you have to use -moz-border-*-colors even if you only want a single color on each side. That's annoying.
Making border-left-color, etc., into shorthands would be a good bit of a pain. I'm not sure if it's worth it. I'd note that you can use -moz-border-*-colors: none to turn off that behavior and use border-*-color again.
(In reply to comment #1) > I'd note that you can use -moz-border-*-colors: none to turn off that behavior > and use border-*-color again. But I can't do: -moz-border-colors: none; border: 1px solid red; since there's no -moz-border-colors shorthand, right? So this is hardly better: -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border: 1px solid red; than: border: 1px solid; -moz-border-top-colors: red; -moz-border-right-colors: red; -moz-border-bottom-colors: red; -moz-border-left-colors: red; Even if there was a -moz-border-colors shorthand, I'm not sure that "none" is helpful, because this: -moz-border-colors: none; border: 1px solid red; doesn't seem like a great improvement over this: border: 1px solid; -moz-border-colors: red; when I really want this to just work: border: 1px solid red;
So one thing that would be quite easy is to make the 'border' shorthand imply -moz-border-*-colors: none, and likewise make border-X imply -moz-border-X-colors: none. It seems like that would help your problem a good bit; not sure how much it would break.
Yeah, that would help, but... > make border-X imply -moz-border-X-colors: none what about -moz-border-start/end?
To do that I'd have to implement -moz-border-start-colors and -moz-border-end-colors, I think.
(In reply to comment #3) > and likewise make border-X imply -moz-border-X-colors: none Actually, this part is harder than I thought, thanks to the fun of the parser and the differences between left/right and top/bottom (thanks to start/end).
Here's a patch for making just the 'border' shorthand reset -moz-border-*-colors and (per last week's CSS WG decision) 'border-image'.
(In reply to comment #7) > Created an attachment (id=366883) [details] > patch > > Here's a patch for making just the 'border' shorthand reset > -moz-border-*-colors and (per last week's CSS WG decision) 'border-image'. Can we get this reviewed and landed?
I'd sort of like to know whether dbaron thinks the patch is ready to go before reviewing.
Yeah, the patch is fine, but it could use a test.
Comment on attachment 427596 [details] [diff] [review] patch r=bzbarsky
Attachment #427596 - Flags: review?(bzbarsky) → review+
I had to make a few additional test changes: http://hg.mozilla.org/users/dbaron_mozilla.com/patches/rev/2b70680896ee
Status: ASSIGNED → RESOLVED
Closed: 13 years ago
Priority: -- → P4
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.9.3a2
Does or should this affect serialization at all?
(In reply to comment #7) > and (per last week's CSS WG decision) 'border-image'. Is there a link to that particular CSS WG discussion/decision available, for reference?
You need to log in before you can comment on or make changes to this bug.