This is a migrated thread and some comments may be shown as answers.

Can editor have different stylesheets, accoarding to the list/Page?

2 Answers 57 Views
WebParts for SharePoint
This is a migrated thread and some comments may be shown as answers.
Christos
Top achievements
Rank 1
Christos asked on 25 Nov 2008, 02:51 PM
Hello,
I use Radeditor in Page content, where I have my own stylesheets.
I also have a rich text field in a document library, where I want a subset of the above stylesheets.
Is this possible?

Thanks

2 Answers, 1 is accepted

Sort by
0
Accepted
Stanimir
Telerik team
answered on 25 Nov 2008, 04:28 PM
Hi Christos,

The CSS class dropdown of RadEditor is populated from the CssClasses Collection. You can predefine the styles to be shown in the CSS Class dropdown using the respective ToolsFile.xml.
For example:
<root> 
 <tools name="MainToolbar" enabled="true"
   <tool name="ApplyClass" /> 
 </tools> 
 <classes> 
   <class name="Clear Class" value="" /> 
   <class name="Links Class" value="a.link" /> 
   <class name="Images Class" value=".img" /> 
   <class name="My Red Text" value=".redText" /> 
 </classes> 
</root>  

In order to configure the CssClass collection for document library you need to modify the respective ListToolsFile.xml.

You can find these files in the following location: /Program Files/Common Files/Microsoft Shared/web server extensions/wpresources/RadEditorSharePoint/5.2.3.0__1f131a624888eeed/Resources/

Note that the folder name depends on the editor version (in this case it is 5.2.3.0).

You can find additional information on defining custom CSS styles in our online help:
http://www.telerik.com/help/aspnet-ajax/defining-custom-css-styles.html

I hope this helps.



Greetings,
Stanimir
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Christos
Top achievements
Rank 1
answered on 26 Nov 2008, 08:56 AM
Hello and thanks
I now understand the difference between ToolsFle and ListToolsFile


Tags
WebParts for SharePoint
Asked by
Christos
Top achievements
Rank 1
Answers by
Stanimir
Telerik team
Christos
Top achievements
Rank 1
Share this question
or