Opened 12 years ago

Closed 12 years ago

#8531 closed Task (wontfix)

No   hack needed on tables

Reported by: Frederico Caldeira Knabben Owned by:
Priority: Normal Milestone:
Component: General Version:
Keywords: Cc:

Description

The   trick we use on empty tables to show them is not needed. It can be solved by adding the following CSS to the editing area:

table { empty-cells: show; }

Not tested though.

Source: Show empty cells in data tables with empty-cells: show.

Attachments (1)

test3.html (657 bytes) - added by Jakub Ś 12 years ago.

Download all attachments as: .zip

Change History (3)

comment:1 Changed 12 years ago by Jakub Ś

Status: newconfirmed

As discussed earlier with @fredck - this feature was supposed to be used for the WYSIWYG area.

I have tried to test the issue a little bit. Here are my findings:

I’m not sure what @fredck meant by   trick as the only code for filling table I have found was the one from _source\plugins\table\dialogs\table.js:

if ( !CKEDITOR.env.ie )
	cell.append( makeElement( 'br' ) );

I haven't found any code that would fill the table with   (Well except when switching to source from wysiwyg - but it has nothing to do presentation of the table).


Style empty-cells: show;is used to render background and borders of empty table cells. According to the article it should work in older versions of IE but in my tests it didn’t work in IE6 and IE7 (empty table cells were not visible). Furthermore if you apply style provided by @fredck and remove the ‘if’ mentioned above, cells in non-IE browsers will be collapsed. The border and background will be visible but there will be no height. Cells will get line-height if you put cursor in them (Firefox) or type something inside them (Chrome).


As I was saying before I didn’t find the code for filling the table in IE so I have prepared a simple test-case file – empty table with only one   in first cell.

Results: Borders and background were shown but none of the browsers showed empty table cells with line heights. They were either collapsed (IE8, IE9) or invisible (IE6, IE7). Only the cells with &nbsp; had expected looks (the same result can be achieved with <br /> put inside table cell).


To summarize. This style does not work in IE6 and IE7. Furthermore empty cells are collapsed so it looks to me like the only way to handle this is to use &nbsp; or < br /> like we do.

NOTE: You can always add height to cell but still its border will not be visible in IE6-7.

Last edited 12 years ago by Jakub Ś (previous) (diff)

Changed 12 years ago by Jakub Ś

Attachment: test3.html added

comment:2 Changed 12 years ago by Jakub Ś

Resolution: wontfix
Status: confirmedclosed

I'm closing this as won't fix please reopen if I have missed something and there is a way to use it in all browsers.

Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy