protected override void SetStyleToForm(object style)
        {
            CRotateStyleItem item = (CRotateStyleItem)style;

            this.InitializeComponent();
            this.Text = item.GetDisplayName();
            switch (item.Rotate)
            {
            case 90:
                this.rdoRight90.Checked = true;
                break;

            case 180:
                this.rdo180.Checked = true;
                break;

            case 270:
                this.rdoLeft90.Checked = true;
                break;

            default:
                this.rdoNone.Checked = true;
                break;
            }
            this.chkVertical.Checked = item.VerticalReflection;
            this.chkHorizon.Checked  = item.HorizonReflection;
            this.imgBackground       = new Bitmap(this.picPreview.Width, this.picPreview.Height, PixelFormat.Format24bppRgb);
            using (Graphics graphics = Graphics.FromImage(this.imgBackground))
            {
                graphics.CopyFromScreen(new Point(0, 0), new Point(0, 0), this.imgBackground.Size);
            }
            this.imgScrap = (System.Drawing.Image)SETUNA.Resources.Image.SampleImage.Clone();
            this.RotateSample();
        }
Beispiel #2
0
        protected override void SetTunedStyleItem(CStyleItem newOwn)
        {
            CRotateStyleItem item = (CRotateStyleItem)newOwn;

            this.Rotate             = item.Rotate;
            this.VerticalReflection = item.VerticalReflection;
            this.HorizonReflection  = item.HorizonReflection;
        }
        protected override object GetStyleFromForm()
        {
            CRotateStyleItem item = new CRotateStyleItem();

            if (this.rdoRight90.Checked)
            {
                item.Rotate = 90;
            }
            else if (this.rdo180.Checked)
            {
                item.Rotate = 180;
            }
            else if (this.rdoLeft90.Checked)
            {
                item.Rotate = 270;
            }
            else
            {
                item.Rotate = 0;
            }
            item.VerticalReflection = this.chkVertical.Checked;
            item.HorizonReflection  = this.chkHorizon.Checked;
            return(item);
        }
        // Token: 0x060004C1 RID: 1217 RVA: 0x00020D98 File Offset: 0x0001EF98
        protected override object GetStyleFromForm()
        {
            var crotateStyleItem = new CRotateStyleItem();

            if (rdoRight90.Checked)
            {
                crotateStyleItem.Rotate = 90;
            }
            else if (rdo180.Checked)
            {
                crotateStyleItem.Rotate = 180;
            }
            else if (rdoLeft90.Checked)
            {
                crotateStyleItem.Rotate = 270;
            }
            else
            {
                crotateStyleItem.Rotate = 0;
            }
            crotateStyleItem.VerticalReflection = chkVertical.Checked;
            crotateStyleItem.HorizonReflection  = chkHorizon.Checked;
            return(crotateStyleItem);
        }
 public RotateStyleItemPanel(CRotateStyleItem item) : base(item)
 {
 }