Exemplo n.º 1
0
 public MyQueries()
 {
     this.Font = FontManager.GetDefaultFont();
     this.InitializeComponent();
     this.InitWatcher();
     base.ImageList = TreeViewHelper.UpscaleImages(this.Font, this.imageList);
 }
Exemplo n.º 2
0
 public BaseForm()
 {
     try
     {
         this.Font = FontManager.GetDefaultFont();
     }
     catch
     {
     }
 }
Exemplo n.º 3
0
        public ReadLinePanel()
        {
            Label label = new Label {
                Dock     = DockStyle.Top,
                AutoSize = true,
                Padding  = new Padding(0, 2, 0, 3)
            };

            this.lblPrompt = label;
            TextBox box = new TextBox {
                BackColor        = Color.Black,
                ForeColor        = Color.White,
                BorderStyle      = BorderStyle.None,
                Dock             = DockStyle.Fill,
                AutoCompleteMode = AutoCompleteMode.SuggestAppend
            };

            this.txtInput = box;
            Panel panel = new Panel {
                BackColor   = Color.Black,
                BorderStyle = BorderStyle.None,
                Dock        = DockStyle.Top
            };

            this.panTextBorder = panel;
            this._history      = new List <string>();
            this._historyIndex = 0;
            try
            {
                this.txtInput.Font = new Font("Consolas", 10f);
            }
            catch
            {
                try
                {
                    this.txtInput.Font = new Font("Courier New", 10f);
                }
                catch
                {
                }
            }
            try
            {
                this.lblPrompt.Font = new Font(FontManager.GetDefaultFont(), FontStyle.Bold);
            }
            catch
            {
            }
            this.panTextBorder.Controls.Add(this.txtInput);
            base.Controls.Add(this.panTextBorder);
            base.Controls.Add(this.lblPrompt);
        }
Exemplo n.º 4
0
 public QueryProps(QueryCore q)
 {
     this._query = q;
     this.InitializeComponent();
     foreach (string str in q.AdditionalReferences)
     {
         this.AddListViewAssembly(str);
     }
     foreach (string str in q.AdditionalGACReferences)
     {
         this.AddListViewAssembly(new AssemblyName(str));
     }
     if (q.IsMyExtensions)
     {
         Label label = new Label {
             Dock     = DockStyle.Top,
             AutoSize = true,
             Text     = "My Extensions: References that you add here will apply to all queries",
             Padding  = new Padding(0, 0, 0, 3),
             Font     = new Font(FontManager.GetDefaultFont(), FontStyle.Bold)
         };
         this.tabPage1.Controls.Add(label);
         this.btnSetAsDefault.Enabled = false;
     }
     else
     {
         QueryCore query = MyExtensions.Query;
         if (query != null)
         {
             foreach (string str in query.AdditionalReferences)
             {
                 this.FlagAsInherited(this.AddListViewAssembly(str));
             }
             foreach (string str in query.AdditionalGACReferences)
             {
                 this.FlagAsInherited(this.AddListViewAssembly(new AssemblyName(str)));
             }
         }
     }
     this.txtNS.Lines = q.AdditionalNamespaces.ToArray <string>();
     this.chkIncludePredicateBuilder.Checked = q.IncludePredicateBuilder;
     this._origNS = this.txtNS.Text.Trim();
     this.EnableControls();
     this.lvRefs.Sorting    = SortOrder.Ascending;
     this.lvRefs.MouseMove += new MouseEventHandler(this.lvRefs_MouseMove);
     this.lvRefs.MouseDown += new MouseEventHandler(this.lvRefs_MouseDown);
     this.tc.TabPages[2].Dispose();
 }
Exemplo n.º 5
0
 public FixedLinkLabel()
 {
     this.Cursor       = Cursors.Hand;
     this.ForeColor    = (SystemColors.Window.GetBrightness() < 0.5f) ? SystemColors.HotTrack : Color.Blue;
     this._defaultFont = new Font(FontManager.GetDefaultFont(), FontStyle.Underline);
 }