Skip to main content
Home Forums Silverlight Programming Report a Silverlight Bug Bug: ScrollBar HorizontalRootElement shows as artifact behind VerticalRootElement
3 replies. Latest Post by KeithRome on June 22, 2008.
(1)
jseaver
Member
14 points
14 Posts
03-28-2008 2:11 PM |
Steps to reproduce the problem:
1) Populate a ListBox control with enough content so that both vertical and horizontal scroll bars appear.
2) Copy the default ListBox, ScrollBar, and related templates to App.xaml and wire them up as appropriate
3) Comment out the Track Layer in the VerticalRootElement so that you can see behind the scroll bar
4) An artifact of the HorizontalRootElement (from the HorizontalThumbTemplate) is clearly visible (narrow the vertical bar if you have trouble seeing it)
A very annoying bug, it took many hours to track it down.
Yi-Lun L...
All-Star
25052 points
2,747 Posts
03-31-2008 6:53 AM |
Hello, this is a known issue. The ScollBar's code missed this line:
ElementVerticalTemplate = GetTemplateChild(ElementVerticalTemplateName)
It'll probably be fixed soon. For now, you can download the source code of the Controls from http://www.microsoft.com/downloads/details.aspx?familyid=EA93DD89-3AF2-4ACB-9CF4-BFE01B3F02D4&displaylang=en and do the modification yourself.
markheath
117 points
63 Posts
06-21-2008 3:04 PM |
this bug is still present in beta 2. (see my blog entry here for more details)
KeithRome
112 points
47 Posts
06-22-2008 7:20 PM |
I can confirm this bug is still present in beta2 as well. But since the ScrollBar control was relocated to the core Silverlight assembly (as opposed to the external controls assembly), we can't "hand patch" it ourselves.
So I guess it's back to my old work-around of having seperate Horizontal and Vertical versions of the ScrollBar templates in my custom styles... oh well, at least I get some help from Blend now when editing the templates...