Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
180
WPF XamDataChart DragZoom outer area color/opacity
posted

Hi,

how can I change the color/opacity of the outer part of the dragzoom area?

The contrast between dragzoom area und outer part will be way to weak e.g. if I have a red plot area background

BR,

Hendrik

Parents
No Data
Reply
  • 34810
    Verified Answer
    Offline posted

    Hello Hendrik,

    In order to change the color and opacity of the outer part of the drag-zoom area, I would recommend utilizing the PreviewPathStyle property of the XamDataChart. This property accepts a Style targeting a Path element, and setting the Fill and Opacity properties will allow you to change the color and opacity of the area outside of the preview zoom rectangle.

    Some sample code to do this could look like the following:

    <ig:XamDataChart.PreviewPathStyle>
       <Style TargetType="{x:Type Path}">
         <Setter Property="Fill" Value="Red"/>
         <Setter Property="Opacity" Value=".5"/>
       </Style>
    </ig:XamDataChart.PreviewPathStyle>

    Please let me know if you have any other questions or concerns on this matter.

    Sincerely,
    Andrew
    Associate Developer

Children