private void MainForm_Paint(object sender, PaintEventArgs e) { if (effect == null) { effect = new GDIPlusCommonGraphics(gEffectGDI, Color.Gray, Color.Gray, true, 255, 1); } if (gr == null) { gr = new GDIPlusCommonGraphics(gGDI, Color.Black, Color.White, true, 255, 2); } Shape sh1 = new shape.Ellipse(10, 10, 100, 60); Shape sh2 = new shape.Ellipse(10, 100, 100, 60); Shape sh1WithShadow = new ShadowEffect(sh1, effect); Shape sh2WithShadow = new ShadowEffect(sh2, effect); Shape sh2WithShadowAndBorder = new BorderEffect(sh2WithShadow, effect); Shape DFstartBlock = new DFStartBlock(150, 5, 100); Shape DFforward1 = new DFForwardBlock(200, 76, 200, 100); Shape DFinput = new DFInputBlock(150, 100, 100); Shape DFforward2 = new DFForwardBlock(200, 146, 200, 170); Shape DFprocess = new DFProcessBlock(150, 170, 100); Shape DFforward3 = new DFForwardBlock(200, 236, 200, 260); Shape DFoutput = new DFOutputBlock(150, 260, 100); Shape DFforward4 = new DFForwardBlock(200, 306, 200, 330); Shape DFendBlock = new DFEndBlock(150, 330, 100); sh1WithShadow.draw(gr); sh2WithShadowAndBorder.draw(gr); Shape FCstart = new FCStartBlock(280, 20, 100); Shape FCforward1 = new FCForwardBlock(330, 68, 330, 100); Shape FCinput = new FCInputBlock(280, 100, 100); Shape FCforward2 = new FCForwardBlock(330, 146, 330, 170); Shape FCprocess = new FCProcessBlock(280, 170, 100); Shape FCforward3 = new FCForwardBlock(330, 215, 330, 260); Shape FCoutput = new FCOutputBlock(280, 260, 100); Shape FCforward4 = new FCForwardBlock(330, 306, 330, 330); Shape FCcondition = new FCConditionBlock(280, 330, 100); Shape FCforward5 = new FCForwardBlock(330, 376, 330, 400); Shape FCend = new FCEndBlock(280, 400, 100); DFstartBlock.draw(gr); DFforward1.draw(gr); DFinput.draw(gr); DFforward2.draw(gr); DFprocess.draw(gr); DFforward3.draw(gr); DFoutput.draw(gr); DFforward4.draw(gr); DFendBlock.draw(gr); FCstart.draw(gr); FCforward1.draw(gr); FCinput.draw(gr); FCforward2.draw(gr); FCprocess.draw(gr); FCforward3.draw(gr); FCoutput.draw(gr); FCforward4.draw(gr); FCcondition.draw(gr); FCforward5.draw(gr); FCend.draw(gr); shapes.Add(sh1WithShadow); shapes.Add(sh2WithShadowAndBorder); shapes.Add(DFstartBlock); shapes.Add(DFinput); shapes.Add(DFprocess); shapes.Add(DFoutput); shapes.Add(DFendBlock); shapes.Add(DFforward1); shapes.Add(DFforward2); shapes.Add(DFforward3); shapes.Add(DFforward4); shapes.Add(FCstart); shapes.Add(FCinput); shapes.Add(FCoutput); shapes.Add(FCprocess); shapes.Add(FCcondition); shapes.Add(FCend); shapes.Add(FCforward1); shapes.Add(FCforward2); shapes.Add(FCforward3); shapes.Add(FCforward4); shapes.Add(FCforward5); }