Modify

Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#2141 closed defect (fixed)

Pasting of tables from Word is broken

Reported by: JasonWinnebeck Owned by: jun66j5
Priority: normal Component: TracWysiwygPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.10

Description

Pasting tables from MS Word 2003 to Firefox 2 is broken. It is attempted but generates wiki that is very far off. Other environments not tested.

Attachments (0)

Change History (4)

comment:1 Changed 7 years ago by JasonWinnebeck

The problem appears only to be that a lot of extra newlines are generated in the source, which generates invalid wiki, so after editing is complete it doesn't "round trip" back to the editor. What's worse is that it looks correct on the screen until you save/preview/or select textarea.

comment:2 Changed 7 years ago by JasonWinnebeck

r2777 seems to change this slightly, now the table generated with new lines when round tripped are terminated, but the generated wikitext is horribly corrupted. Newlines in tables should be converted to BR's, but more newlines are generated than there should be.

I create a 2x2 table in Word with cells a,b,c,d. The expected result is:

ab
cd

When I paste I see the appropriate view in the wysiwyg editor, but when I click textarea I see:

= heading =
 
  || a

  || b

  ||
  || c

  || d

  ||
 
 text

Then I click wysiwyg, and see the table broken out vertically. Click textarea again, and now I see:

= heading =
 

  || a||

  || b||

  ||
  || c||

  || d||

  ||

 

  text}}}

The roundtrip is stable at this point.

I also tested table paste from Excel. That works, except that it indents the table for some reason.

comment:3 Changed 7 years ago by jun66j5

  • Resolution set to fixed
  • Status changed from new to closed

(In [2794]) fixed #2141 - a problem with pasting of tables from word.

comment:4 Changed 7 years ago by JasonWinnebeck

Good, this works well now. There is still one problem remaining and that is when you use the "abcd" example from above, but when you put a new line in one of the tables, two BRs come out instead of the expected one.

Add Comment

Modify Ticket

Action
as closed .
as The resolution will be set. Next status will be 'closed'.
to The owner will be changed from jun66j5. Next status will be 'closed'.
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.