Hello,
I am using 2012.2.607.40 version of RadEditor. I have the editor inside a PageView. I have javascript that resizes my editor width (the resize code works perfectly except if I click on a ribbon bar tab). The problem I am having is when I navigate to the editor (ajax or direct page load) and then click on one of the ribbon bar tabs, the resize code does not resize the ribbon bar, which remains at it original 100% width. This also happen if I open the editor pageView on the initial page load so I don't think it has to do with Editor/PageView/Css issues? If I change to the Default editor toolbar, the editor and default toolbar resize correctly.
Here is my resize javascript code:
I do have the following code in my Master page to help with the well-known Css limitation:
Finally here is my editor markup:
Thank you!
I am using 2012.2.607.40 version of RadEditor. I have the editor inside a PageView. I have javascript that resizes my editor width (the resize code works perfectly except if I click on a ribbon bar tab). The problem I am having is when I navigate to the editor (ajax or direct page load) and then click on one of the ribbon bar tabs, the resize code does not resize the ribbon bar, which remains at it original 100% width. This also happen if I open the editor pageView on the initial page load so I don't think it has to do with Editor/PageView/Css issues? If I change to the Default editor toolbar, the editor and default toolbar resize correctly.
Here is my resize javascript code:
window.onresize = onPageResize;
function onPageResize() {
var editor = $find("<%=edEditor.ClientID %>");
if (editor != null) {
setTimeout(function () {
var wt = jQuery('.editorTop').width();
wt = (wt - 15);
editor.setSize(wt, 600);
editor.get_element().style.width = wt + "px";
}, 200);
}
}
I do have the following code in my Master page to help with the well-known Css limitation:
<
Telerik:RadStyleSheetManager
ID
=
"SSH1"
EnableStyleSheetCombine
=
"true"
runat
=
"server"
>
<
StyleSheets
>
<
Telerik:StyleSheetReference
Assembly
=
"Telerik.Web.UI"
Name
=
"Telerik.Web.UI.Skins.Editor.css"
/>
<
Telerik:StyleSheetReference
Assembly
=
"Telerik.Web.UI"
Name
=
"Telerik.Web.UI.Skins.Default.Editor.Default.css"
/>
<
Telerik:StyleSheetReference
Assembly
=
"Telerik.Web.UI"
Name
=
"Telerik.Web.UI.Skins.Window.css"
/>
<
Telerik:StyleSheetReference
Assembly
=
"Telerik.Web.UI"
Name
=
"Telerik.Web.UI.Skins.Default.Window.Default.css"
/>
</
StyleSheets
>
</
Telerik:RadStyleSheetManager
>
Finally here is my editor markup:
<
telerik:RadEditor
ID
=
"edEditor"
Height
=
"600px"
Skin
=
"Default"
ToolbarMode
=
"RibbonBar"
toolsfile
=
"~/Editor/Tools/ToolsFile.xml"
EnableResize
=
"false"
OnClientLoad
=
"edEditor_ClientLoad"
OnClientModeChange
=
"edEditor_ClientModeChange"
runat
=
"server"
>
<
CssFiles
>
<
telerik:EditorCssFile
Value
=
"~/Editor/Styles/EditorContentArea.css"
/>
</
CssFiles
>
</
telerik:RadEditor
>
Thank you!