public void AddButton(int x, int y, int width, int height, SkinForm form,EventHandler ClickHandler) { ImageButton img = new ImageButton(new Rectangle(x, y, width, height), form); img.Click += ClickHandler; this.Buttons.Add(img); }
public SkinFormCaptionRenderEventArgs( SkinForm skinForm, Graphics g, Rectangle clipRect, bool active) : base(g, clipRect) { _skinForm = skinForm; _active = active; }
public override Region CreateRegion(SkinForm form) { Rectangle rect = new Rectangle(Point.Empty, form.Size); using (GraphicsPath path = GraphicsPathHelper.CreatePath( rect, form.Radius, form.RoundStyle, false)) { return new Region(path); } }
public SkinFormControlBoxRenderEventArgs( SkinForm form, Graphics graphics, Rectangle clipRect, bool active, ControlBoxStyle controlBoxStyle, ControlBoxState controlBoxState) : base(graphics, clipRect) { _form = form; _active = active; _controlBoxState = controlBoxState; _controlBoxStyle = controlBoxStyle; }
public ImageButton(Rectangle size, SkinForm Parent) { this._Size = size; _ParentControl = Parent; if (_ParentControl.Renderer is IPSSkinRender) { TitleImage = ((IPSSkinRender)_ParentControl.Renderer).TitleImage; } if (TitleImage != null) { _Image = TitleImage.Clone(size, TitleImage.PixelFormat); _OverImage = Brightness(_Image,25); } }
protected override void OnRenderSkinFormControlBox( SkinFormControlBoxRenderEventArgs e) { SkinForm form = e.Form; Graphics g = e.Graphics; Rectangle rect = e.ClipRectangle; ControlBoxState state = e.ControlBoxtate; bool active = e.Active; bool minimizeBox = form.ControlBox && form.MinimizeBox; bool maximizeBox = form.ControlBox && form.MaximizeBox; switch (e.ControlBoxStyle) { case ControlBoxStyle.Close: RenderSkinFormCloseBoxInternal( g, rect, state, active, minimizeBox, maximizeBox); break; case ControlBoxStyle.Maximize: RenderSkinFormMaximizeBoxInternal( g, rect, state, active, minimizeBox, form.WindowState == FormWindowState.Maximized); break; case ControlBoxStyle.Minimize: RenderSkinFormMinimizeBoxInternal( g, rect, state, active); break; } }
protected override void OnRenderSkinFormBackground( SkinFormBackgroundRenderEventArgs e) { Graphics g = e.Graphics; Rectangle rect = e.ClipRectangle; SkinForm form = e.SkinForm; using (AntiAliasGraphics antiGraphics = new AntiAliasGraphics(g)) { using (Brush brush = new SolidBrush(ColorTable.Back)) { using (GraphicsPath path = GraphicsPathHelper.CreatePath( rect, form.Radius, form.RoundStyle, false)) { g.FillPath(brush, path); } } } }
public abstract Region CreateRegion(SkinForm form);
public void Dispose() { _owner = null; }
public ControlBoxManager(SkinForm owner) { _owner = owner; }
public override void InitSkinForm(SkinForm form) { form.BackColor = ColorTable.Back; }
public abstract void InitSkinForm(SkinForm form);