Hi,
first I need to say: Great Toolkit, looks awesome and has nice features !
I'm just evaluating/trying to use it for a project in which I need some (5-10) RichTextEditor parts inside one VLayout.
Best would be to use the built-in RichTextEditor() class but unfortunately it's very limited at the moment. I need at least additional UL/LI and a indent (UL in UL) functionality.
While I searched the forum for a kickoff how to implement them, I read some posts which advised better to use the external FCKEditor instead.
Because I already used the FCKEditor in other projects, I thought: "that could be done easily".
But also for this, my experience/knowledge seems to be to limited, at least for now.
Here's what I did now.
The problem with this is that it doesn't get initialized some times.
Mostly the browser window needs to be resized to get the FCK rendered.
Also FCK-Popups like the one for "Format" is render at wrong positions.
I also tried to implement the FCK as "textarea" but that approach had problems with multiple FCKs as well as resizing problems in the way that the html "textarea" got rendered back.
Every tip is welcome.
first I need to say: Great Toolkit, looks awesome and has nice features !
I'm just evaluating/trying to use it for a project in which I need some (5-10) RichTextEditor parts inside one VLayout.
Best would be to use the built-in RichTextEditor() class but unfortunately it's very limited at the moment. I need at least additional UL/LI and a indent (UL in UL) functionality.
While I searched the forum for a kickoff how to implement them, I read some posts which advised better to use the external FCKEditor instead.
Because I already used the FCKEditor in other projects, I thought: "that could be done easily".
But also for this, my experience/knowledge seems to be to limited, at least for now.
Here's what I did now.
Code:
public class FCKEditor extends Canvas { private Object fckO = null; public FCKEditor() { setOverflow(Overflow.VISIBLE); setCanDragResize(false); setRedrawOnResize(false); initEditor(this.getID()); } public String getInnerHTML() { return jsniGetInnerHTML(fckO); } private native String jsniGetInnerHTML(Object fckO) /*-{ return fckO.CreateHtml(); }-*/; public native void setValue(String text) /*-{ this.@com.emcc.extranet.client.widgets.FCKEditor::fckO.Value = text; }-*/; private native void initEditor(String id) /*-{ this.@com.emcc.extranet.client.widgets.FCKEditor::fckO = new $wnd.FCKeditor("fckEd_"+id); this.@com.emcc.extranet.client.widgets.FCKEditor::fckO.BasePath = "fckeditor/"; this.@com.emcc.extranet.client.widgets.FCKEditor::fckO.Width = "100%"; this.@com.emcc.extranet.client.widgets.FCKEditor::fckO.Height = 200; this.@com.emcc.extranet.client.widgets.FCKEditor::fckO.Config["FloatingPanelsZIndex"] = 900000 ; // modal popup fix this.@com.emcc.extranet.client.widgets.FCKEditor::fckO.Config["CustomConfigurationsPath"] = "../../inc/fckEditorPrisma.js"; this.@com.emcc.extranet.client.widgets.FCKEditor::fckO.ToolbarSet = "Prisma"; }-*/; }
Mostly the browser window needs to be resized to get the FCK rendered.
Also FCK-Popups like the one for "Format" is render at wrong positions.
I also tried to implement the FCK as "textarea" but that approach had problems with multiple FCKs as well as resizing problems in the way that the html "textarea" got rendered back.
Every tip is welcome.
Comment