نمایش نتایج 1 تا 40 از 534

نام تاپیک: 1001 نکته در سی شارپ

Hybrid View

پست قبلی پست قبلی   پست بعدی پست بعدی
  1. #1

    ترسیم انواع چک باکس ها به کمک +GDI

    private void DrawCheckBox(Graphics g, ref Rectangle rc, ButtonState state)
    {
    ControlPaint.DrawCheckBox(g, rc, state);
    g.DrawString(state.ToString() , Font, Brushes.Black,
    rc.Width + 5, rc.Y + (rc.Height - Font.Height) / 2);
    rc.Offset(0, rc.Height + 5);
    }
    private void Form1_Paint(object sender, PaintEventArgs e)
    {
    Rectangle rc = new Rectangle(0, 0, 25, 25);
    DrawCheckBox(e.Graphics, ref rc, ButtonState.All);
    DrawCheckBox(e.Graphics, ref rc, ButtonState.Checked);
    DrawCheckBox(e.Graphics, ref rc, ButtonState.Flat);
    DrawCheckBox(e.Graphics, ref rc, ButtonState.Inactive);
    DrawCheckBox(e.Graphics, ref rc, ButtonState.Normal);
    DrawCheckBox(e.Graphics, ref rc, ButtonState.Pushed);
    }

    منبع : http://www.amazon.com/GDI-Custom-Con.../dp/1904811604
    عکس های ضمیمه عکس های ضمیمه

برچسب های این تاپیک

قوانین ایجاد تاپیک در تالار

  • شما نمی توانید تاپیک جدید ایجاد کنید
  • شما نمی توانید به تاپیک ها پاسخ دهید
  • شما نمی توانید ضمیمه ارسال کنید
  • شما نمی توانید پاسخ هایتان را ویرایش کنید
  •