private void DrawCustomButtons(GraphicsCache cache)
 {
     foreach (EditorButton button in View.ButtonsStrore.Keys)
     {
         customButtonPainter.DrawObject(GetButtonInfoArgs(cache, View.ButtonsStrore[button], button));
     }
 }
Beispiel #2
0
 void DrawBackground(TreeListNode node, CustomDrawEventArgs e)
 {
     if (hotNode != node && !node.Focused)
     {
         return;
     }
     SetUpButtonInfoArgs(e);
     customButtonPainter.DrawObject(args);
 }
Beispiel #3
0
        void DrawButton(EditorButton button, RowObjectCustomDrawEventArgs e)
        {
            Rectangle buttonRect = GetButtonRect(e.Bounds, button.Index);
            SkinEditorButtonPainter    painter = new SkinEditorButtonPainter(linkedView.GridControl.LookAndFeel.ActiveLookAndFeel);
            EditorButtonObjectInfoArgs args    = new EditorButtonObjectInfoArgs(e.Cache, button, e.Appearance);

            args.Bounds = buttonRect;
            if (button.Index == hotTrackedIndex)
            {
                args.State = ObjectState.Hot;
            }
            painter.DrawObject(args);
        }
 protected override void DrawButton(ButtonEditViewInfo viewInfo, EditorButtonObjectInfoArgs info)
 {
     if (info.Button.Tag != null && info.Button.Tag.ToString() == "Custom")
     {
         var look = new UserLookAndFeel(viewInfo.OwnerEdit);
         look.SkinName = look.ActiveSkinName;
         look.UseDefaultLookAndFeel = false;
         look.SkinMaskColor         = info.Button.Appearance.BackColor;
         SkinEditorButtonPainter painter = new SkinEditorButtonPainter(look);
         painter.DrawObject(info);
     }
     else
     {
         base.DrawButton(viewInfo, info);
     }
 }
Beispiel #5
0
 protected override void OnPaint(PaintEventArgs pevent)
 {
     if (UseSkins)
     {
         EditorButtonObjectInfoArgs args = new EditorButtonObjectInfoArgs(new GraphicsCache(pevent.Graphics), _Button, AppearanceObject.EmptyAppearance);
         args.Bounds         = new Rectangle(0, 0, Width, Height);
         args.BuiltIn        = false;
         args.FillBackground = false;
         args.State          = GetObjectState();
         args.Button.Caption = Text;
         _Painter.DrawObject(args);
     }
     else
     {
         base.OnPaint(pevent);
     }
 }
Beispiel #6
0
 private void DrawCustomButton(ColumnHeaderCustomDrawEventArgs e)
 {
     SetUpButtonInfoArgs(e);
     customButtonPainter.DrawObject(args);
 }