예제 #1
0
        public static double CreateAndShowDialog(Form parent, GrblCore Core, double oldval)
        {
            double rv = oldval;

            using (ResolutionHelperForm f = new ResolutionHelperForm())
            {
                f.UDDesired.Value  = (decimal)oldval;
                f.UDHardware.Value = Core.Configuration.ResolutionX;
                f.Compute(null, null);

                if (f.ShowDialog(parent) == DialogResult.OK)
                {
                    rv = f.mRetVal;
                }
            }

            return(rv);
        }
예제 #2
0
        public static double CreateAndShowDialog(double oldval)
        {
            double rv = oldval;

            using (ResolutionHelperForm f = new ResolutionHelperForm())
            {
                f.UDDesired.Value  = (decimal)oldval;
                f.UDHardware.Value = (decimal)Settings.GetObject("Hardware Resolution", 100.0m);
                f.Compute(null, null);

                if (f.ShowDialog() == DialogResult.OK)
                {
                    rv = f.mRetVal;
                }
            }

            return(rv);
        }
예제 #3
0
 private void BtnFillingQualityInfo_Click(object sender, EventArgs e)
 {
     UDFillingQuality.Value = Math.Min(UDFillingQuality.Maximum, (decimal)ResolutionHelperForm.CreateAndShowDialog(this, mCore, (double)UDFillingQuality.Value));
     //Tools.Utils.OpenLink(@"https://lasergrbl.com/usage/raster-image-import/setting-reliable-resolution/");
 }
예제 #4
0
 private void BtnFillingQualityInfo_Click(object sender, EventArgs e)
 {
     UDFillingQuality.Value = (decimal)ResolutionHelperForm.CreateAndShowDialog(mCore, (double)UDFillingQuality.Value);
     //System.Diagnostics.Process.Start(@"http://lasergrbl.com/usage/raster-image-import/setting-reliable-resolution/");
 }