Beispiel #1
0
        public static string ToStringMorphForm(MorphForm form)
        {
            StringBuilder res = new StringBuilder();

            if (((form & MorphForm.Short)) != MorphForm.Undefined)
            {
                res.Append("кратк.|");
            }
            if (((form & MorphForm.Synonym)) != MorphForm.Undefined)
            {
                res.Append("синонимич.|");
            }
            if (res.Length > 0)
            {
                res.Length--;
            }
            return(res.ToString());
        }
        // Morph an image
        public void morphTwosrcFiltersItem_Click(object sender, System.EventArgs e)
        {
            // get overlay image
            Bitmap overlayImage = host.GetImage(this, "Select an image to which the curren image will be morphed", new Size(width, height), image.PixelFormat);

            if (overlayImage != null)
            {
                // show filter setting dialog
                MorphForm form = new MorphForm(overlayImage);

                form.Image = image;

                // get filter settings
                if (form.ShowDialog() == DialogResult.OK)
                {
                    ApplyFilter(form.Filter);
                }
            }
        }