Example #1
0
 /// <summary>
 /// Show the properties of an image layer in the legend.
 /// </summary>
 /// <param name="e"></param>
 public void ShowProperties(IImageLayer e)
 {
     using (var dlg = new LayerDialog(e, new ImageCategoryControl()))
     {
         ShowDialog(dlg);
     }
 }
Example #2
0
 /// <summary>
 /// Show the properties of an image layer in the legend. 
 /// </summary>
 /// <param name="e"></param>
 public void ShowProperties(IImageLayer e)
 {
     using (var dlg = new LayerDialog(e,new ImageCategoryControl()))
     {
         ShowDialog(dlg);
     }
 }
Example #3
0
        public void updateImageList()
        {
            if (m_imageList?.Count > 0)
            {
                Image img = m_imageList[0].createImage();
                m_image = new Bitmap(img.Width, img.Height);
                using (Graphics g = Graphics.FromImage(m_image))
                {
                    for (int i = 0; i < m_imageList.Count; i++)
                    {
                        IImageLayer il = m_imageList[i];

                        ColorMatrix CMFade = new ColorMatrix();
                        CMFade.Matrix33 = (float)il.Alpha;
                        ImageAttributes AFade = new ImageAttributes();
                        AFade.SetColorMatrix(CMFade, ColorMatrixFlag.Default, ColorAdjustType.Bitmap);

                        img = il.createImage();
                        g.DrawImage(img,
                                    new Rectangle(il.Position, img.Size),
                                    0, 0, img.Width, img.Height,
                                    GraphicsUnit.Pixel, AFade);
                    }
                }
            }
            else
            {
                m_image = new Bitmap(100, 100);
            }
            updateImageParameters();
        }
 /// <summary>
 /// Show the properties of an image layer in the legend. 
 /// </summary>
 /// <param name="e"></param>
 public void ShowProperties(IImageLayer e)
 {
     using (var dlg = new PropertyDialog())
     {
         dlg.PropertyGrid.SelectedObject = e.Copy();
         dlg.OriginalObject = e;
         ShowDialog(dlg);
     }
 }
Example #5
0
 /// <summary>
 /// Show the properties of an image layer in the legend.
 /// </summary>
 /// <param name="e"></param>
 public void ShowProperties(IImageLayer e)
 {
     using (var dlg = new PropertyDialog())
     {
         dlg.PropertyGrid.SelectedObject = e.Copy();
         dlg.OriginalObject = e;
         ShowDialog(dlg);
     }
 }
        /// <summary>
        /// Sets up the Table to work with the specified layer
        /// </summary>
        /// <param name="layer"></param>
        public void Initialize(IImageLayer layer)
        {
            if (layer.Symbolizer == null) layer.Symbolizer = new ImageSymbolizer();
            _originalLayer = layer;
            _symbolizer = layer.Symbolizer;
            _newLayer = layer.Copy();

            _ignoreRefresh = true;
            rsOpacity.Value = _symbolizer.Opacity;
            _ignoreRefresh = false;
        }
Example #7
0
        /// <summary>
        /// Sets up the Table to work with the specified layer
        /// </summary>
        /// <param name="layer"></param>
        public void Initialize(IImageLayer layer)
        {
            if (layer.Symbolizer == null)
            {
                layer.Symbolizer = new ImageSymbolizer();
            }
            _originalLayer = layer;
            _symbolizer    = layer.Symbolizer;
            _newLayer      = layer.Copy();

            _ignoreRefresh  = true;
            rsOpacity.Value = _symbolizer.Opacity;
            _ignoreRefresh  = false;
        }
Example #8
0
 /// <summary>
 /// Show the properties of an image layer in the legend.
 /// </summary>
 /// <param name="layer">The image layer.</param>
 public void ShowProperties(IImageLayer layer)
 {
     using var dlg = new LayerDialog(layer, new ImageCategoryControl());
     ShowDialog(dlg);
 }
Example #9
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ImageLayerEventArgs"/> class.
 /// </summary>
 /// <param name="imageLayer">The IImageLayer that is involved in this event.</param>
 public ImageLayerEventArgs(IImageLayer imageLayer)
 {
     ImageLayer = imageLayer;
 }
Example #10
0
 public ImageCategoryControl(IImageLayer layer)
 {
     InitializeComponent();
     Initialize(layer);
 }
 public ImageCategoryControl(IImageLayer layer)
 {
     InitializeComponent();
     Initialize(layer);
 }
 /// <summary>
 /// Initializes a new instance of the ImageLayerEventArgs class.
 /// </summary>
 /// <param name="imageLayer">The IImageLayer that is involved in this event.</param>
 public ImageLayerEventArgs(IImageLayer imageLayer)
 {
     _imageLayer = imageLayer;
 }