Beispiel #1
0
        /// <summary>
        /// Notifies all child controls that the properties of the text edtiors have changed.
        /// </summary>
        public void OptionsChanged()
        {
            _textArea.OptionsChanged();

            if (_textArea.TextEditorProperties.ShowHorizontalRuler)
            {
                if (_hRuler == null)
                {
                    _hRuler = new HRuler(_textArea);
                    Controls.Add(_hRuler);
                    ResizeTextArea();
                }
                else
                {
                    _hRuler.Invalidate();
                }
            }
            else
            {
                if (_hRuler != null)
                {
                    Controls.Remove(_hRuler);
                    _hRuler.Dispose();
                    _hRuler = null;
                    ResizeTextArea();
                }
            }

            SetScrollBars();
            AdjustScrollBars();
        }