Open Bug 145419 Opened 23 years ago Updated 2 years ago

dynamically added ::first-letter and ::first-line rules not applied

Categories

(Core :: CSS Parsing and Computation, defect, P3)

defect

Tracking

()

Future

People

(Reporter: danielcdawson, Unassigned)

References

(Blocks 1 open bug)

Details

(Keywords: css1, testcase)

Attachments

(5 files)

From Bugzilla Helper: User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0rc1) Gecko/20020417 BuildID: 2002041711 If an alternate stylesheet specifies a rule using the :first-letter or :first-line pseudo-element, but no rule in the default stylesheet matches the same pseudo, the former rule is ignored for that element. For instance, if the default stylesheet says the first letter of a given paragraph should be green, and the alternate stylesheet says red, both are honored, but if the "green" rule is missing, both are rendered using the inherited value. Reproducible: Always Steps to Reproduce: 1. View any page that does not specify a style rule for a given :first-letter or :first-line pseudo-element in its default stylesheet but does specify such a rule in an alternate stylesheet 2. Use the View > Use Style menu to switch to the alternate stylesheet Actual Results: The rule in the alternate stylesheet is ignored. Expected Results: The rule in the alternate stylesheet should be applied; the default stylesheet should not affect alternate stylesheets.
(Re)name to default.css to test.
(Re)name to default.css to test.
Name it alternate.css to test.
Summary: :first-letter and :first-line pseudos ignored in alternate stylesheet if not used in default stylesheet → [RR/RCF]:first-letter and :first-line pseudos ignored in alternate stylesheet if not used in default stylesheet
This looks remarkably like bug 126072 although that is about :before and :after pseudo classes
Hmm. Not only are they remarkably alike, it looks like they're one and the same. (Both caused by a general problem with pseudo-elements.) Would it be appropriate to call this a dup?
this testcase uses - attachment 84146 [details] for default-1 stylesheet - attachment 84147 [details] for default-2 stylesheet - attachment 84148 [details] for Alternate stylesheet
I see the bug on linux, win2000 and macOS 9.1. Confirming the bug. Repeating reporter's comment : "If an alternate stylesheet specifies a rule using the :first-letter or :first-line pseudo-element, but no rule in the default stylesheet matches the same pseudo, the former rule is ignored for that element."
Severity: normal → major
Status: UNCONFIRMED → NEW
Ever confirmed: true
Keywords: testcase
OS: Linux → All
Priority: -- → P3
Hardware: PC → All
Severity: major → normal
Status: NEW → ASSIGNED
Priority: P3 → P2
Target Milestone: --- → mozilla1.2alpha
This may be the same problem as bug 23604.
Depends on: 23604
Priority: P2 → P3
Summary: [RR/RCF]:first-letter and :first-line pseudos ignored in alternate stylesheet if not used in default stylesheet → [RR/RCF]dynamically added :first-letter and :first-line rules not applied
Target Milestone: mozilla1.2alpha → Future
Depends on: 8253
Keywords: css1
Summary: [RR/RCF]dynamically added :first-letter and :first-line rules not applied → dynamically added ::first-letter and ::first-line rules not applied
Assignee: dbaron → nobody
Status: ASSIGNED → NEW
QA Contact: ian → style-system
Blocks: 1106759
When inverting Default-1 and Default-2 it works fine. Maybe It’s because it wasn’t defined before…
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: