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

ContextMenu With No Image Alignment Issue

1 Answer 44 Views
Editor
This is a migrated thread and some comments may be shown as answers.
robertw102
Top achievements
Rank 1
robertw102 asked on 05 Mar 2010, 05:41 PM
I've noticed that when you create your own custom ContextMenu commands for the Editor and set ShowIcon="false" that the text is not aligned correctly. The text is shown over the "dark-gray" section reserved for images.

I've attached an image that shows what I'm talking about.

1 Answer, 1 is accepted

Sort by
0
Dobromir
Telerik team
answered on 10 Mar 2010, 03:17 PM
Hi Robert,

By design, when EditorTool has its property ShowIcon set to false, the icon container is not rendered on the page - that is the reason for the text shifting to the left. As a workaround for this problem I would suggest to have the custom tool defined for the context menu with its icon displayed (ShowIcon="true") and just to remove the background-image of the container, e.g:
<head runat="server">
    <title></title>
    <style type="text/css">
        .Custom1{background-image:none !important;}
    </style>
</head>
<body>
    .......
        <telerik:RadEditor ID="RadEditor1" runat="server">
            <ContextMenus>
                <telerik:EditorContextMenu TagName="IMG" Enabled="true">
                    <telerik:EditorTool Name="Custom1" />
                    <telerik:EditorTool Name="SetImageProperties" />
                    <telerik:EditorTool Name="ImageMapDialog" />
                </telerik:EditorContextMenu>
            </ContextMenus>
             
            <Content>
                <img src="#" width="100" height="100" />
            </Content>
        </telerik:RadEditor>
    .......
 
</body>


Best wishes,
Dobromir
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Tags
Editor
Asked by
robertw102
Top achievements
Rank 1
Answers by
Dobromir
Telerik team
Share this question
or