WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED CONFIGURATION CHANGED
40481
Consider adding support for :first-letter and :first-line in SVG
https://bugs.webkit.org/show_bug.cgi?id=40481
Summary
Consider adding support for :first-letter and :first-line in SVG
Abhishek Arya
Reported
2010-06-11 10:42:37 PDT
There was no seperate implementation of :first-letter and :first-line for SVG, which is why we had crashes and incorrect layouts when those pseudo classes were used for text elements in SVG. As a result, we disabled them in security bug -
https://bugs.webkit.org/show_bug.cgi?id=40031
. Other browsers such as firefox, opera, (svg implementation batik) don't support it. However, after chatting with Dave, Maciej, we should consider writing these features.
Attachments
Add attachment
proposed patch, testcase, etc.
Dirk Schulze
Comment 1
2010-06-11 22:57:39 PDT
:first-line doesn't make sense for texts in SVG. We don't have block level elements like paragraph in SVG. So :first-line would always be true on texts. Are there other application areas for this pseudo element?
Abhishek Arya
Comment 2
2010-06-23 10:21:24 PDT
How about :first-letter, does that apply to SVG ?
Dirk Schulze
Comment 3
2010-06-23 10:37:03 PDT
(In reply to
comment #2
)
> How about :first-letter, does that apply to SVG ?
Yea, I think so.
Abhishek Arya
Comment 4
2010-06-23 11:25:33 PDT
cut-copy-paste from 40031 In an SVG user agent that supports CSS style sheets, the following facilities from [CSS2] must be supported: --------- * CSS2's dynamic pseudo-classes :hover, :active and :focus and pseudo-classes :first-child, :visited, :link and :lang. The remaining CSS2 pseudo-classes, including those having to do with generated content, are not part of the SVG language definition. (Note: an SVG element gains focus when it is selected. See Text selection.) --------- Is it part of SVG specification or a requirement ?
Stephen Chenney
Comment 5
2012-01-18 12:51:13 PST
Adding myself to CC list.
Dirk Schulze
Comment 6
2014-05-12 05:49:21 PDT
I attached a test case. It does not seem to run in any browser.
Brent Fulgham
Comment 7
2022-07-15 14:51:56 PDT
Safari, Chrome, and Firefox all agree on rendering for this test case. I don't believe there is any remaining compatibility issue.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug