Beispiel #1
0
        private void InitializeComponent()
        {
            SuspendLayout();

            acbLine = new Label();
            //acbLine.BorderStyle = BorderStyle.Fixed3D;
            acbLine.Cursor     = Cursors.Pointer;
            acbLine.TextColor  = Colors.White;
            acbLine.Size       = new Size(100, 20);
            acbLine.Text       = "Line color";
            acbLine.MouseDown += lblColorClick;

            acbBack = new Label();
            //acbBack.BorderStyle = BorderStyle.Fixed3D;
            acbBack.Cursor     = Cursors.Pointer;
            acbBack.Size       = new Size(100, 20);
            acbBack.Text       = "Background color";
            acbBack.MouseDown += lblColorClick;

            acbText = new Label();
            //acbText.BorderStyle = BorderStyle.Fixed3D;
            acbText.Cursor     = Cursors.Pointer;
            acbText.TextColor  = Colors.White;
            acbText.Size       = new Size(100, 20);
            acbText.Text       = "Text color";
            acbText.MouseDown += lblColorClick;

            acb7 = new Label();
            //acb7.BorderStyle = BorderStyle.Fixed3D;
            acb7.Cursor     = Cursors.Pointer;
            acb7.Size       = new Size(100, 20);
            acb7.Text       = "Circle 7";
            acb7.MouseDown += lblColorClick;

            acb6 = new Label();
            //acb6.BorderStyle = BorderStyle.Fixed3D;
            acb6.Cursor     = Cursors.Pointer;
            acb6.Size       = new Size(100, 20);
            acb6.Text       = "Circle 6";
            acb6.MouseDown += lblColorClick;

            acb5 = new Label();
            //acb5.BorderStyle = BorderStyle.Fixed3D;
            acb5.Cursor     = Cursors.Pointer;
            acb5.Size       = new Size(100, 20);
            acb5.Text       = "Circle 5";
            acb5.MouseDown += lblColorClick;

            acb4 = new Label();
            //acb4.BorderStyle = BorderStyle.Fixed3D;
            acb4.Cursor     = Cursors.Pointer;
            acb4.Size       = new Size(100, 20);
            acb4.Text       = "Circle 4";
            acb4.MouseDown += lblColorClick;

            acb3 = new Label();
            //acb3.BorderStyle = BorderStyle.Fixed3D;
            acb3.Cursor     = Cursors.Pointer;
            acb3.Size       = new Size(100, 20);
            acb3.Text       = "Circle 3";
            acb3.MouseDown += lblColorClick;

            acb2 = new Label();
            //acb2.BorderStyle = BorderStyle.Fixed3D;
            acb2.Cursor     = Cursors.Pointer;
            acb2.Size       = new Size(100, 20);
            acb2.Text       = "Circle 2";
            acb2.MouseDown += lblColorClick;

            acb1 = new Label();
            //acb1.BorderStyle = BorderStyle.Fixed3D;
            acb1.Cursor     = Cursors.Pointer;
            acb1.Size       = new Size(100, 20);
            acb1.Text       = "Circle 1";
            acb1.MouseDown += lblColorClick;

            acb0 = new Label();
            //acb0.BorderStyle = BorderStyle.Fixed3D;
            acb0.Cursor     = Cursors.Pointer;
            acb0.Size       = new Size(100, 20);
            acb0.Text       = "Circle 0";
            acb0.MouseDown += lblColorClick;

            chkHideEmptySegments = new CheckBox();
            //chkHideEmptySegments.Size = new Size(328, 24);
            chkHideEmptySegments.Text = "chkHideEmptySegments";

            Content = new DefTableLayout()
            {
                Rows =
                {
                    new TableRow {
                        Cells =  { acb0,    acb1,    acb2, acb3 }
                    },
                    new TableRow {
                        Cells =  { acb4,    acb5,    acb6, acb7 }
                    },
                    new TableRow {
                        Cells =  { acbText, acbBack, acbLine }
                    },
                    new TableRow {
                        Cells =  { chkHideEmptySegments }
                    }
                }
            };

            UIHelper.SetControlFont(this, UIHelper.GetDefaultFont());
            ResumeLayout();
        }
Beispiel #2
0
        private void InitializeComponent()
        {
            SuspendLayout();

            Lab1      = new Label();
            Lab1.Text = "XXX1";

            Lab2      = new Label();
            Lab2.Text = "XXX2";

            Edit1          = new TextBox();
            Edit1.ReadOnly = true;
            Edit1.Width    = 350;

            Edit2          = new TextBox();
            Edit2.ReadOnly = true;
            Edit2.Width    = 350;

            btnRec1Select        = new Button();
            btnRec1Select.Size   = new Size(80, 26);
            btnRec1Select.Text   = "btnRec1Select";
            btnRec1Select.Click += btnRec1Select_Click;

            btnRec2Select        = new Button();
            btnRec2Select.Size   = new Size(80, 26);
            btnRec2Select.Text   = "btnRec2Select";
            btnRec2Select.Click += btnRec2Select_Click;

            btnMergeToLeft         = new Button();
            btnMergeToLeft.Enabled = false;
            btnMergeToLeft.Size    = new Size(80, 26);
            btnMergeToLeft.Text    = "<<<";
            btnMergeToLeft.Click  += btnMergeToLeft_Click;

            btnMergeToRight         = new Button();
            btnMergeToRight.Enabled = false;
            btnMergeToRight.Size    = new Size(80, 26);
            btnMergeToRight.Text    = ">>>";
            btnMergeToRight.Click  += btnMergeToRight_Click;

            fView1 = new HyperView();
            fView2 = new HyperView();

            var contPan = new DefTableLayout(2, 4);

            contPan.SetRowScale(0, false);
            contPan.SetRowScale(1, false);
            contPan.SetRowScale(2, true);
            contPan.SetRowScale(3, false);
            contPan.SetColumnScale(0, true);
            contPan.SetColumnScale(1, true);

            contPan.Add(Lab1, 0, 0);
            contPan.Add(Lab2, 1, 0);
            contPan.Add(TableLayout.Horizontal(Edit1, null, btnRec1Select), 0, 1);
            contPan.Add(TableLayout.Horizontal(Edit2, null, btnRec2Select), 1, 1);
            contPan.Add(fView1, 0, 2);
            contPan.Add(fView2, 1, 2);
            contPan.Add(TableLayout.Horizontal(null, btnMergeToLeft), 0, 3);
            contPan.Add(TableLayout.Horizontal(btnMergeToRight, null), 1, 3);

            Content = contPan;

            UIHelper.SetControlFont(this, UIHelper.GetDefaultFont());
            ResumeLayout();
        }