Example #1
0
 public void ReplaceVScrollBar(VScrollbar widget)
 {
     if (vScrollBar != null)
     {
         RemoveChild(vScrollBar);
         vScrollBar.Dispose();
     }
     vScrollBar         = widget;
     vScrollBar.Visible = true;
     AddChild(vScrollBar);
 }
 protected override void OnStyleSet(Style previous_style)
 {
     base.OnStyleSet(previous_style);
     if (Core.Platform.IsWindows)
     {
         using (var scrollstyle = Rc.GetStyleByPaths(Settings, null, null, VScrollbar.GType)) {
             var scrl = new VScrollbar(null);
             scrl.Style          = scrollstyle;
             win81Slider         = scrollstyle.Background(StateType.Normal).ToCairoColor();
             win81SliderPrelight = scrollstyle.Background(StateType.Prelight).ToCairoColor();
             win81ScrollbarWidth = (int)scrl.StyleGetProperty("slider-width");
             scrl.Dispose();
         }
     }
 }