Esempio n. 1
0
        private void CreateTextB_Click(object sender, EventArgs e)
        {
            Button b = sender as Button;

            AddPanel.Location = b.Parent.Parent.Location;
            AddPanel.Show();
            RuleOrTextPanel.Hide();

            clauseFlag = false;
        }
Esempio n. 2
0
        private void control_button_Click(object sender, EventArgs e)
        {
            if (alreadyClicked == false)
            {
                Button b = sender as Button;
                clicked   = b.Name;
                b.Visible = false;

                RuleOrTextPanel.Visible  = true;
                RuleOrTextPanel.Location = b.Location;
                CreateTextB.Enabled      = true;

                Tree t = mainTree.FindName(mainTree, b.Name);
                if (!t.Prev.IsClause)
                {
                    CreateTextB.Enabled = false;
                }
            }

            if (alreadyClicked == true)
            {
                foreach (Button b2 in positionsList)
                {
                    if (b2.Location == RuleOrTextPanel.Location)
                    {
                        b2.Show();
                        b2.BackColor = SystemColors.Control;
                        AddPanel.Hide();
                        RuleOrTextPanel.Hide();
                    }
                }

                Button b = sender as Button;
                clicked   = b.Name;
                b.Visible = false;

                RuleOrTextPanel.Visible  = true;
                RuleOrTextPanel.Location = b.Location;
                CreateTextB.Enabled      = true;

                Tree t = mainTree.FindName(mainTree, b.Name);
                if (!t.Prev.IsClause)
                {
                    CreateTextB.Enabled = false;
                }
            }

            alreadyClicked = true;
        }
Esempio n. 3
0
        private void CreateRuleB_Click(object sender, EventArgs e)
        {
            if (newTreeFlag == true)
            {
                DeleteNewRuleB.Enabled = false;
            }

            Button b = sender as Button;

            AddPanel.Location = b.Parent.Parent.Location;
            AddPanel.Show();
            RuleOrTextPanel.Hide();

            clauseFlag = true;
        }
Esempio n. 4
0
        private void CreateTreeB_Click(object sender, EventArgs e)
        {
            CreateTreeB.Hide();
            paintFlag = true;
            Refresh();
            foreach (Button b in positionsList)
            {
                b.Visible = true;
            }
            RuleOrTextPanel.Location = new Point(870, 100);
            positionsList[0].Hide();

            CreateTextB.Enabled = false;
            RuleOrTextPanel.Show();
            doneB.Location = new Point(100, 100);
            doneB.Show();
            legendPanel.Visible = true;
            minusLabel.Visible  = true;
            plusLabel.Visible   = true;
        }