Mike Arasteh
Top achievements
Rank 1
Mike Arasteh
asked on 01 Apr 2010, 10:15 AM
Hello,
On the tree view, when I hover or click on an item, it gets highlighted with some color.
The color covers only the length of the text, so they become inconsistent as one text is longer than the other.
How can I make the color fixed and not changed based on the length of the text.
Thank You..!
On the tree view, when I hover or click on an item, it gets highlighted with some color.
The color covers only the length of the text, so they become inconsistent as one text is longer than the other.
How can I make the color fixed and not changed based on the length of the text.
Thank You..!
4 Answers, 1 is accepted
0
Accepted
Hello Mike Arasteh,
You can achieve this using the following CSS:
If you want to preserve to have border around the selected node, please remove the borde:none declaration.
Greetings,
Genady Sergeev
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.
You can achieve this using the following CSS:
.rtSelected .rtIn, .rtHover .rtIn
{
background
:
none
!important
;
color
:
#000000
!important
;
border
:
none
!important
;
}
If you want to preserve to have border around the selected node, please remove the borde:none declaration.
Greetings,
Genady Sergeev
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.
0
Mike Arasteh
Top achievements
Rank 1
answered on 04 Apr 2010, 07:46 AM
Thanks alot
0
Ben
Top achievements
Rank 1
answered on 13 Dec 2012, 08:24 PM
Hi Genady,
Is there a way to do this for the top node only? I want subnodes to behave the default way but only the root nodes to not show the highlight around the text.
-Ben
Is there a way to do this for the top node only? I want subnodes to behave the default way but only the root nodes to not show the highlight around the text.
-Ben
0
Princy
Top achievements
Rank 2
answered on 14 Dec 2012, 07:34 AM
Hi Ben,
Try the following code snippet to remove the hover effect of RadTreeNode.
ASPX:
JS:
Hope this helps.
Regards,
Princy.
Try the following code snippet to remove the hover effect of RadTreeNode.
ASPX:
<
telerik:RadTreeView
ID
=
"RadTreeView1"
runat
=
"server"
OnClientMouseOver
=
"unhighlight"
......>
</
telerik:RadTreeView
>
JS:
<script type=
"text/javascript"
>
function
unhighlight(sender, args) {
if
(args.get_node().get_level() == 0) {
args.get_node().unhighlight();
}
}
</script>
Hope this helps.
Regards,
Princy.