/// <summary>
		/// Constructor.
		/// </summary>
		public RichTextReportEditorComponentControl(IReportEditorComponent component)
			: base(component)
		{
			_component = component;
			InitializeComponent();

			_richText.DataBindings.Add("Text", _component, "EditorText", true, DataSourceUpdateMode.OnPropertyChanged);
			_cannedTextSupport = new CannedTextSupport(_richText, _component.CannedTextLookupHandler);

			Control reportPreview = (Control)_component.ReportPreviewHost.ComponentView.GuiElement;
			reportPreview.Dock = DockStyle.Fill;
			_splitContainer.Panel1.Controls.Add(reportPreview);
			UpdatePreviewVisibility();

			((INotifyPropertyChanged)_component).PropertyChanged += _component_PropertyChanged;
		}
        /// <summary>
        /// Constructor.
        /// </summary>
        public RichTextReportEditorComponentControl(IReportEditorComponent component)
            : base(component)
        {
            _component = component;
            InitializeComponent();

            _richText.DataBindings.Add("Text", _component, "EditorText", true, DataSourceUpdateMode.OnPropertyChanged);
            _cannedTextSupport = new CannedTextSupport(_richText, _component.CannedTextLookupHandler);

            Control reportPreview = (Control)_component.ReportPreviewHost.ComponentView.GuiElement;

            reportPreview.Dock = DockStyle.Fill;
            _splitContainer.Panel1.Controls.Add(reportPreview);
            UpdatePreviewVisibility();

            ((INotifyPropertyChanged)_component).PropertyChanged += _component_PropertyChanged;
        }
Esempio n. 3
0
 /// <summary>
 /// Called by the host to assign this view to a component.
 /// </summary>
 public void SetComponent(IApplicationComponent component)
 {
     _component = (IReportEditorComponent)component;
 }
		/// <summary>
		/// Called by the host to assign this view to a component.
		/// </summary>
		public void SetComponent(IApplicationComponent component)
		{
			_component = (IReportEditorComponent)component;
		}