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

RadEditor Custom Tool in SplitButton not showing image

2 Answers 66 Views
Editor
This is a migrated thread and some comments may be shown as answers.
Erick Burgess
Top achievements
Rank 1
Erick Burgess asked on 12 May 2014, 09:37 PM
I have this in my tools xml file:
<tools name="Tools">
    <tool name="Custom_StripWidth" text="Strip All Widths/Heights" />
    <tool name="Custom_ClearAll" text="Clear" />
    <tool name="Custom_Format" type="SplitButton">
        <tool name="Custom_StripWidth" text="Strip Widths/Heights" />
        <tool name="StripCss"/>
        <tool name="StripFont"/>
        <tool name="StripSpan"/>
        <tool name="StripWord"/>
        <tool name="StripAll"/>
    </tool>
</tools>

And this in my css:
.reTool .Custom_Format {
    background-image: url('../images/icons/format.png');
} 
.reTool .Custom_StripWidth {
    background-image: url('../images/icons/strip_width.png');
}

As you can see from the attached picture, the Custom_StripWidth tool on the main bar looks correct, but the one nested in the SplitButton is missing the image.

Any ideas?

2 Answers, 1 is accepted

Sort by
0
Accepted
Ianko
Telerik team
answered on 13 May 2014, 10:50 AM
Hello Erick,

Note that the tools in Split Buttons are differently rendered than the ordinary buttons. INvwestigating the rendered tools with the dev toolbar you should see that the parent of the tool has class name reTool_text and this is why the set rule does not work for the slit button.

I suggest using the following example in the built project:
.reTool .Custom_StripWidth,
.reToolbar .reTool_text span.Custom_StripWidth {
    background-image: url('../images/icons/strip_width.png');
}


Regards,
Ianko
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Erick Burgess
Top achievements
Rank 1
answered on 13 May 2014, 03:57 PM
That did it, thanks!
Tags
Editor
Asked by
Erick Burgess
Top achievements
Rank 1
Answers by
Ianko
Telerik team
Erick Burgess
Top achievements
Rank 1
Share this question
or