Пример #1
0
 protected void AddBrowser()
 {
     _browser      = new MshtmlEdit();
     _browser.Dock = DockStyle.Fill;
     _browser.add_KeyDown(OnKeyDown);
     _panelBrowser.Controls.Add(_browser);
 }
Пример #2
0
        /// <summary>
        /// Required method for Designer support - do not modify
        /// the contents of this method with the code editor.
        /// </summary>
        private void InitializeComponentSelf()
        {
            _txtTitle = new JetTextBox();
            _toolbar  = new RichEditToolbar();
            _htmled   = new MshtmlEdit();
            Closing  += new CancelEventHandler(OnBeforeCloseForm);
            SuspendLayout();
            //
            // _txtTitle
            //
            _txtTitle.Location     = new Point(36, 100);
            _txtTitle.Name         = "_txtTitle";
            _txtTitle.TabIndex     = 1;
            _txtTitle.Text         = "";
            _txtTitle.Dock         = DockStyle.Top;
            _txtTitle.TextChanged += new EventHandler(OnTitleChanged);
            _txtTitle.KeyDown     += new KeyEventHandler(OnEditorKeyDown);
            //
            // _htmled
            //
            _htmled.Name     = "_htmled";
            _htmled.TabIndex = 2;
            _htmled.Dock     = DockStyle.Fill;
            _htmled.add_KeyDown(new KeyEventHandler(OnEditorKeyDown));
            //
            // _toolbar
            //
//			_toolbar.DropDownArrows = true;
            _toolbar.Location = new Point(0, 0);
            _toolbar.Name     = "_toolbar";
            _toolbar.TabStop  = true;
            _toolbar.TabIndex = 3;
            //
            // _panelBody
            //
            _panelBody             = new Panel();
            _panelBody.BorderStyle = BorderStyle.Fixed3D;
            _panelBody.Controls.Add(_htmled);
            _panelBody.Dock     = DockStyle.Fill;
            _panelBody.Name     = "_panelBody";
            _panelBody.TabIndex = 2;
            //
            // BlogExtensionComposer
            //
            AutoScaleBaseSize = new Size(5, 13);
            ClientSize        = new Size(800, 600);
            Controls.Add(_panelBody);
            Controls.Add(_txtTitle);
            Controls.Add(_toolbar);
            Name = "BlogExtensionComposer";
            Text = "Compose a Blog Entry";
            ResumeLayout(false);
        }
Пример #3
0
        protected void SpawnControls()
        {
            // Combo
            IResourceList resIntersect = Core.ResourceStore.GetAllResources(JiraServer.Type);
            int           nServers     = resIntersect.Count;

            resIntersect = resIntersect.Union(Core.ResourceStore.GetAllResources(JiraProject.Type));
            resIntersect = resIntersect.Union(JiraServer.RootResource.ToResourceList());
            _comboProject.Items.Add(nServers != 0 ? Stringtable.DontSubmit : Stringtable.GotoTabAddServer);
            if (nServers != 0)
            {
                _comboProject.AddResourceHierarchy(JiraServer.RootResource, null, Core.Props.Parent, resIntersect);
            }

            // Browsers
            _browserTemplate      = new MshtmlEdit();
            _browserTemplate.Dock = DockStyle.Fill;
            _panelTemplate.Controls.Add(_browserTemplate);

            _browserDevelopers      = new MshtmlEdit();
            _browserDevelopers.Dock = DockStyle.Fill;
            _panelDevelopers.Controls.Add(_browserDevelopers);
        }
Пример #4
0
 /// <summary>
 /// Required method for Designer support - do not modify
 /// the contents of this method with the code editor.
 /// </summary>
 private void InitializeComponent()
 {
     System.Resources.ResourceManager resources = new System.Resources.ResourceManager(typeof(HtmlEditor));
     this._toolbar       = new System.Windows.Forms.ToolBar();
     this._htmled        = new JetBrains.Omea.GUIControls.MshtmlBrowser.MshtmlEdit();
     this.toolBarButton1 = new System.Windows.Forms.ToolBarButton();
     this.toolBarButton2 = new System.Windows.Forms.ToolBarButton();
     this.toolBarButton3 = new System.Windows.Forms.ToolBarButton();
     this.toolBarButton4 = new System.Windows.Forms.ToolBarButton();
     this.toolBarButton5 = new System.Windows.Forms.ToolBarButton();
     this.toolBarButton6 = new System.Windows.Forms.ToolBarButton();
     this.toolBarButton7 = new System.Windows.Forms.ToolBarButton();
     this.toolBarButton8 = new System.Windows.Forms.ToolBarButton();
     ((System.ComponentModel.ISupportInitialize)(this._htmled)).BeginInit();
     this.SuspendLayout();
     //
     // _toolbar
     //
     this._toolbar.Appearance = System.Windows.Forms.ToolBarAppearance.Flat;
     this._toolbar.Buttons.AddRange(new System.Windows.Forms.ToolBarButton[] {
         this.toolBarButton1,
         this.toolBarButton2,
         this.toolBarButton3,
         this.toolBarButton4,
         this.toolBarButton5,
         this.toolBarButton6,
         this.toolBarButton7,
         this.toolBarButton8
     });
     this._toolbar.ButtonSize     = new System.Drawing.Size(60, 22);
     this._toolbar.Divider        = false;
     this._toolbar.DropDownArrows = true;
     this._toolbar.Location       = new System.Drawing.Point(0, 0);
     this._toolbar.Name           = "_toolbar";
     this._toolbar.ShowToolTips   = true;
     this._toolbar.Size           = new System.Drawing.Size(532, 26);
     this._toolbar.TabIndex       = 0;
     this._toolbar.TextAlign      = System.Windows.Forms.ToolBarTextAlign.Right;
     this._toolbar.ButtonClick   += new System.Windows.Forms.ToolBarButtonClickEventHandler(this.OnToolbarClick);
     //
     // _htmled
     //
     this._htmled.Dock    = System.Windows.Forms.DockStyle.Fill;
     this._htmled.Enabled = true;
     this._htmled.Html    = "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0 Transitional//EN\">\r\n<HTML><HEAD>\r\n<M" +
                            "ETA http-equiv=Content-Type content=\"text/html; charset=unicode\">\r\n<META content" +
                            "=\"MSHTML 6.00.2900.2604\" name=GENERATOR></HEAD>\r\n<BODY></BODY></HTML>\r\n";
     this._htmled.Location = new System.Drawing.Point(0, 26);
     this._htmled.Name     = "_htmled";
     this._htmled.OcxState = ((System.Windows.Forms.AxHost.State)(resources.GetObject("_htmled.OcxState")));
     this._htmled.Size     = new System.Drawing.Size(532, 272);
     this._htmled.TabIndex = 1;
     this._htmled.Text     = "undefined";
     //
     // toolBarButton1
     //
     this.toolBarButton1.Text = "Color";
     //
     // toolBarButton2
     //
     this.toolBarButton2.Tag  = "Bold";
     this.toolBarButton2.Text = "B";
     //
     // toolBarButton3
     //
     this.toolBarButton3.Tag  = "Italic";
     this.toolBarButton3.Text = "I";
     //
     // toolBarButton4
     //
     this.toolBarButton4.Tag  = "Underline";
     this.toolBarButton4.Text = "U";
     //
     // toolBarButton5
     //
     this.toolBarButton5.Tag  = "JustifyLeft";
     this.toolBarButton5.Text = "Left";
     //
     // toolBarButton6
     //
     this.toolBarButton6.Tag  = "JustifyRight";
     this.toolBarButton6.Text = "Right";
     //
     // toolBarButton7
     //
     this.toolBarButton7.Tag  = "JustifyCenter";
     this.toolBarButton7.Text = "Center";
     //
     // toolBarButton8
     //
     this.toolBarButton8.Tag  = "JustifyFull";
     this.toolBarButton8.Text = "Justify";
     //
     // HtmlEditor
     //
     this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
     this.ClientSize        = new System.Drawing.Size(532, 298);
     this.Controls.Add(this._htmled);
     this.Controls.Add(this._toolbar);
     this.Name = "HtmlEditor";
     this.Text = "HtmlEditor";
     ((System.ComponentModel.ISupportInitialize)(this._htmled)).EndInit();
     this.ResumeLayout(false);
 }
Пример #5
0
        /// <summary>
        /// Required method for Designer support - do not modify
        /// the contents of this method with the code editor.
        /// </summary>
        private void InitializeComponentSelf()
        {
            _subject  = new Label();
            _txtTitle = new JetTextBox();
//            _toolbar = new RichEditToolbarFull();
            _toolbar         = new RichEditToolbar();
            _htmled          = new MshtmlEdit();
            _panelSubject    = new Panel();
            _panelBody       = new Panel();
            _panelCategories = new Panel();
            _selector        = new CategoriesSelector();
            SuspendLayout();

            //
            // _panelSubject
            //
            _panelSubject.Location = new Point(0, 0);
            _panelSubject.Size     = new Size(800, 30);
            _panelSubject.Controls.Add(_subject);
            _panelSubject.Controls.Add(_txtTitle);
            _panelSubject.Dock = DockStyle.Top;
            //
            // _subject
            //
            _subject.Location = new Point(4, 7);
            _subject.Name     = "_subject";
            _subject.TabStop  = false;
            _subject.Text     = "&Subject:";
            _subject.Size     = new Size(65, 25);
            //
            // _txtTitle
            //
            _txtTitle.Location     = new Point(80, 4);
            _txtTitle.Size         = new Size(700, 25);
            _txtTitle.Name         = "_txtTitle";
            _txtTitle.TabStop      = false;
            _txtTitle.Text         = "";
            _txtTitle.TextChanged += OnTitleChanged;
            _txtTitle.KeyDown     += OnEditorKeyDown;
            //
            // _htmled
            //
            _htmled.Name     = "_htmled";
            _htmled.TabIndex = 1;
            _htmled.Dock     = DockStyle.Fill;
            _htmled.add_KeyDown(new KeyEventHandler(OnEditorKeyDown));
            _htmled.add_PropertyChanged(new EventHandler(OnPropChanged));
            _htmled.add_PasteHandler(new EventHandler(OnPropChanged));
            //
            // _toolbar
            //
//			_toolbar.DropDownArrows = true;
            _toolbar.Location = new Point(36, 0);
            _toolbar.Name     = "_toolbar";
            _toolbar.TabStop  = false;
            _toolbar.Dock     = DockStyle.Top;
            //
            // _panelBody
            //
            _panelBody.BorderStyle = BorderStyle.Fixed3D;
            _panelBody.Controls.Add(_htmled);
            _panelBody.Controls.Add(_toolbar);
            _panelBody.Dock     = DockStyle.Fill;
            _panelBody.Name     = "_panelBody";
            _panelBody.TabIndex = 1;
            //
            // _panelCategories
            //
            _panelCategories.Controls.Add(_selector);
            _panelCategories.BorderStyle = BorderStyle.Fixed3D;
            _panelCategories.Size        = new Size(800, 40);
            _panelCategories.Dock        = DockStyle.Bottom;
            _panelCategories.Name        = "_panelCategories";
            _panelCategories.TabIndex    = 2;
            //
            // _selector
            //
            _selector.Dock     = DockStyle.Fill;
            _selector.Location = new Point(0, 0);
            _selector.Name     = "_selector";
            _selector.Size     = new Size(320, 40);
            _selector.TabIndex = 3;
            //
            // NoteComposer
            //
            ClientSize = new Size(800, 600);
            Controls.Add(_panelBody);
            Controls.Add(_panelCategories);
            Controls.Add(_panelSubject);
            ParentChanged += NoteEditor_ParentChanged;
            Name           = "NoteComposer";
            Text           = "Edit a Note";
            ResumeLayout(false);
        }