Closed Bug 176709 Opened 22 years ago Closed 21 years ago

can't apply font styles to pasted HTML which includes user defined tags

Categories

(Core :: DOM: Editor, defect)

x86
Windows XP
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: barrowma, Assigned: harishd)

References

()

Details

(Whiteboard: EDITORBASE+)

Attachments

(1 file)

When I cut & paste a paragraph from the story at
http://www.washingtonpost.com/wp-dyn/articles/A13845-2002Oct24.html, into the
composer or mail editor, the source HTML includes user defined tags
(<nitf>...</nitf>).  

When I try to apply Bold, Italics, etc., to the section, nothing happens.  

If I remove the <nitf>...</nitf> tags, I can successfully apply Bold, etc.
I'm not seeing this result. 
Status: NEW → ASSIGNED
reassign to new placeholder
Assignee: syd → composer
Status: ASSIGNED → NEW
I still see this using trunk build on WinXP from 02/06/2003.

To reproduce: 
1. go to http://www.washingtonpost.com/wp-dyn/articles/A13845-2002Oct24.html
2. select and copy a paragraph from the story
3. pasted into a new editor window
4. select a word in the paragraph you just pasted, and apply the Bold style to it

Expected: word becomes bold
Actual: nothing happens

5. view the HTML Source: you will see <nitf>...</nitf> tags.  If you manually
remove these, step 4 will behave as expected.
Whiteboard: EDITORBASE
EDITORBASE+ ->jfrancis
Assignee: composer → jfrancis
Component: Editor: Composer → Editor: Core
QA Contact: sujay → beppe
Whiteboard: EDITORBASE → EDITORBASE+
taking for initial investigation...
Assignee: jfrancis → nisheeth
Harish, is there any reason why <nitf> should end up as eHTMLTag_unknown instead
of eHTMLTag_userdefined?  eHTMLTag_unknown is a non-container while
eHTMLTag_userdefined can contain inlines.  If <nitf> would get parsed into
eHTMLTag_userdefined, the DTD rules would allow a <b> to get inserted into
markup within <nitf> and this bug would go away.
Status: NEW → ASSIGNED
<nitf> should be considered as an userdefined tag ( Note: CNavDTD does treat
<nitf> as userdefined tag ). The bug seems to be in COtherElements.h where
userdefined element is probably not initialized correctly. I'll take a look into
it today.
Attached patch Patch v1.0Splinter Review
Intialize userdefined element.
I've verified that this patch fixes this bug.  Re-assigning to Harish so that he
can checkin this fix...

Thanks, Harish!
Assignee: nisheeth → harishd
Status: ASSIGNED → NEW
Attachment #126305 - Flags: superreview?(jst)
Attachment #126305 - Flags: review?(nisheeth)
Comment on attachment 126305 [details] [diff] [review]
Patch v1.0

sr=jst
Attachment #126305 - Flags: superreview?(jst) → superreview+
Comment on attachment 126305 [details] [diff] [review]
Patch v1.0

Looks good to me. r=nisheeth.
Attachment #126305 - Flags: review?(nisheeth) → review+
Fix landed.
Status: NEW → RESOLVED
Closed: 21 years ago
Resolution: --- → FIXED
This fix may have caused the regression in bug 228688
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: