コード例 #1
0
ファイル: LabelSetup2.cs プロジェクト: CGX-GROUP/DotSpatial
        /// <summary>
        /// Fires the ChangesApplied event.
        /// </summary>
        protected virtual void OnChangesApplied()
        {
            //_activeCategory.Expression = sqlExpression.ExpressionText;
            _activeCategory.Expression = expressionDialog1.Expression;
            //CGX save masks
            _activeCategory.UseMask           = maskControl1.UseMask;
            _activeCategory.MaskedLayers      = maskControl1.MaskedLayers;
            _activeCategory.MaskMargin_Top    = maskControl1.MaskMargin_Top;
            _activeCategory.MaskMargin_Bottom = maskControl1.MaskMargin_Bottom;
            _activeCategory.MaskMargin_Left   = maskControl1.MaskMargin_Left;
            _activeCategory.MaskMargin_Right  = maskControl1.MaskMargin_Right;
            if (ChangesApplied != null)
            {
                ChangesApplied(this, EventArgs.Empty);
            }

            if (_original != null)
            {
                _original.CopyProperties(_layer);
                _original.CreateLabels();

                // We have no guarantee that the MapFrame property is set, but redrawing the map is important.
                if (_original.FeatureLayer.MapFrame != null)
                {
                    _original.FeatureLayer.MapFrame.Invalidate();
                }
            }
        }
コード例 #2
0
ファイル: LabelSetup.cs プロジェクト: CGX-GROUP/DotSpatial
        /// <summary>
        /// Fires the ChangesApplied event.
        /// </summary>
        protected virtual void OnChangesApplied()
        {
            _activeCategory.Expression = sqlExpression.ExpressionText;

            ChangesApplied?.Invoke(this, EventArgs.Empty);

            if (_original != null)
            {
                _original.CopyProperties(_layer);
                _original.CreateLabels();

                // We have no guarantee that the MapFrame property is set, but redrawing the map is important.
                _original.FeatureLayer.MapFrame?.Invalidate();
            }
        }
コード例 #3
0
        /// <summary>
        /// Fires the ChangesApplied event.
        /// </summary>
        protected virtual void OnChangesApplied()
        {
            if (ChangesApplied != null)
            {
                ChangesApplied(this, EventArgs.Empty);
            }

            if (_original != null)
            {
                _original.CopyProperties(_layer);
                _original.CreateLabels();

                // We have no guarantee that the MapFrame property is set, but redrawing the map is important.
                if (_original.FeatureLayer.MapFrame != null)
                {
                    _original.FeatureLayer.MapFrame.Invalidate();
                }
            }
        }