Opened 18 years ago
Closed 17 years ago
#861 closed New Feature (duplicate)
Background color for tables
Reported by: | anonymous | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | General | Version: | |
Keywords: | SF | Cc: | simpleupdates@… |
Description
I would like to have the background color option for whole tables, not only cells. The editor will really suck if that option is not supported because most browsers support colors in tables.
If the style of the tables should be set with CSS classes then the whole thing will be a mess! I don't know why you should make things difficult to use if there is an easy way to do it.
Moved from SF:
http://sourceforge.net/tracker/index.php?func=detail&aid=1414896&group_id=75348&atid=543656
Change History (3)
comment:1 Changed 18 years ago by
Cc: | simpleupdates@… added |
---|---|
Reporter: | changed from Martin Kou to anonymous |
comment:2 Changed 18 years ago by
I copied the code from the table cell dialog, and it appears to work. Any reason why this can't be put in the next release?
Yes, I accept it should use separate fcklang codes from the cell dialog, although the words are the same.
Patched fck_table.html (2.4.3, build 15657) as below: (the indenting gets lost in transit)
83a84,85
document.getElementById('txtBackColor').value = GetAttribute( table, 'bgColor' ) ; document.getElementById('txtBorderColor').value = GetAttribute( table, 'borderColor' ) ;
118a121,122
SetAttribute( table, 'bgColor' , GetE('txtBackColor').value ) ; SetAttribute( table, 'borderColor' , GetE('txtBorderColor').value ) ;
163a168,183
function SelectBackColor( color ) {
if ( color && color.length > 0 )
GetE('txtBackColor').value = color ;
}
function SelectBorderColor( color ) {
if ( color && color.length > 0 )
GetE('txtBorderColor').value = color ;
}
function SelectColor( wich ) {
oEditor.FCKDialog.OpenDialog( 'FCKDialog_Color', oEditor.FCKLang.DlgColorTitle, 'dialog/fck_colorselector.html', 400, 330, wich == 'Back' ? SelectBackColor : SelectBorderColor, window ) ;
}
212a233,238
<tr>
<td>
</td>
<td>
</td>
</tr>
266a293,318
</tr>
</table> <table cellspacing="0" cellpadding="0" border="0">
<tr>
<td nowrap="nowrap">
<span fcklang="DlgCellBackColor">Background Color</span>:</td>
<td>
<input id="txtBackColor" type="text" size="8" name="txtCellSpacing"></td>
<td>
<input type="button" fcklang="DlgCellBtnSelect" value="Select..." onclick="SelectColor( 'Back' )"></td>
</tr> <tr>
<td nowrap="nowrap">
<span fcklang="DlgCellBorderColor">Border Color</span>:</td>
<td>
<input id="txtBorderColor" type="text" size="8" name="txtCellPadding" /></td>
<td>
<input type="button" fcklang="DlgCellBtnSelect" value="Select..." onclick="SelectColor( 'Border' )" /></td>
</tr> <tr>
<td>
</td>
<td>
</td>
I would also like this capability!
Moved from SF. Original poster: simpleupdate