Opened 16 years ago
Closed 16 years ago
#3728 closed Bug (fixed)
Automatic color options don't seem to do anything
Reported by: | Damian | Owned by: | Frederico Caldeira Knabben |
---|---|---|---|
Priority: | Normal | Milestone: | CKEditor 3.0 |
Component: | General | Version: | |
Keywords: | IBM Confirmed Review+ | Cc: |
Description
The Font color and Background color toolbar options provide an "Automatic" selection. Based on the way that FCKEditor 2.6 has implemented this option, it should reset the background/font color. This doesn't appear to work in the nightly CKEditor builds.
Attachments (2)
Change History (13)
comment:1 Changed 16 years ago by
Keywords: | Confirmed added |
---|
comment:2 Changed 16 years ago by
Owner: | set to Martin Kou |
---|---|
Status: | new → assigned |
Changed 16 years ago by
Attachment: | 3728.patch added |
---|
comment:3 Changed 16 years ago by
Keywords: | Review? added |
---|
comment:4 Changed 16 years ago by
Keywords: | Review- added; Review? removed |
---|
I think you fixing is somehow conflicting with the existing logic there:
if ( color ) style.apply( editor.document ); else style.remove( editor.document );
So the correct fix would either remove the current colored style OR apply the inherited style.
comment:5 Changed 16 years ago by
Keywords: | Review? added; Review- removed |
---|
There's no conflict there. If the color is to be removed, then color would be null and thus style.remove() is executed. What's missing is that we need to detect the color to be removed before running style.remove(), and that's what my patch does.
comment:6 Changed 16 years ago by
Keywords: | Review+ added; Review? removed |
---|
Sorry, my fault, doesn't get the idea of your patch.
comment:7 Changed 16 years ago by
Keywords: | Review- added; Review+ removed |
---|
The proposed patch doesn't work on mixed colors selection.
comment:8 Changed 16 years ago by
Owner: | changed from Martin Kou to Frederico Caldeira Knabben |
---|---|
Status: | assigned → new |
It looks like it was just a small misunderstanding in the original implementation. I've a new patch for it.
Changed 16 years ago by
Attachment: | 3728_2.patch added |
---|
comment:9 Changed 16 years ago by
Keywords: | Review? added; Review- removed |
---|---|
Status: | new → assigned |
comment:10 Changed 16 years ago by
Keywords: | Review+ added; Review? removed |
---|
This is due to some missing logic in colorbutton plugin.