コード例 #1
0
        // ------------------------------------------------------------------
        /// <summary>
        /// Creates a Bitmap from the selected entities.  If no entities are
        /// selected, then 'null' is returned.
        /// </summary>
        /// <returns>Bitmap</returns>
        // ------------------------------------------------------------------
        public Bitmap ToBitmap()
        {
            if (SelectedItems.Count <= 0)
            {
                return(null);
            }

            Graphics g = mController.View.Graphics;

            g.Transform     = mController.View.ViewMatrix;
            g.SmoothingMode = SmoothingMode.HighQuality;
            Bundle bundle = new Bundle(SelectedItems.Copy());

            return(ImageExporter.FromBundle(bundle, g));
        }