Exemplo n.º 1
0
        /// <summary>
        /// Создание нового сигнала используя ToolBox
        /// </summary>
        /// <param name="pt"></param>
        public void CreateNewSignal_Dragged(Point pt)
        {
            pt = form.PointToClient(pt);
            if (Lock == true)
            {
                MessageBox.Show("You must create figure " + SelectedFigure.name + " before.", "Fatal Error :)", MessageBoxButtons.OK, MessageBoxIcon.Error);
                return;
            }
            graph.UnselectAllFigures();

            Schematix.FSM.My_Signal signal = null;
            if (Graph.Language == FSM_Language.VHDL)
            {
                signal = new Schematix.FSM.My_Signal("Variable" + graph.Signals.Count.ToString(), "STD_LOGIC", "'0'", pt, this);
            }
            if (Graph.Language == FSM_Language.Verilog)
            {
                signal = new Schematix.FSM.My_Signal("Variable" + graph.Signals.Count.ToString(), "reg", "'0'", pt, this);
            }
            SelectedFigure = signal;
            graph.AddFigure(signal);
            Lock = false;
            //AddToHistory("New signal Draged");
            bitmap.UpdateBitmap();
        }
Exemplo n.º 2
0
 public SignalPropertiesVerilog(Schematix.FSM.My_Signal signal, Schematix.FSM.Constructor_Core core)
 {
     InitializeComponent();
     this.signal = signal;
     this.core   = core;
     LoadData();
 }
Exemplo n.º 3
0
 public SignalPropertiesVHDL(Schematix.FSM.My_Signal signal, Schematix.FSM.Constructor_Core core)
 {
     InitializeComponent();
     this.signal              = signal;
     this.core                = core;
     comboBoxGenType.Parent   = this;
     comboBoxGenType.Location = new Point(12, 95);
     LoadData();
 }
Exemplo n.º 4
0
        public void Delete_Signal(Schematix.FSM.My_Signal s)
        {
            DialogResult res = MessageBox.Show("Are you sure want to delete signal " + s.name + " ?", "Delete Signal?", MessageBoxButtons.YesNo, MessageBoxIcon.Question);

            if (res == DialogResult.Yes)
            {
                RemoveFigure(s);
            }
        }
Exemplo n.º 5
0
        /// <summary>
        /// Создание нового сигнала
        /// </summary>
        public void CreateNewSignal()
        {
            if (Lock == true)
            {
                MessageBox.Show("You must create figure " + SelectedFigure.name + " before.", "Fatal Error :)", MessageBoxButtons.OK, MessageBoxIcon.Error);
                return;
            }
            graph.UnselectAllFigures();

            Schematix.FSM.My_Signal signal = new Schematix.FSM.My_Signal(this);
            SelectedFigureList.Add(signal);
            SelectedFigure = signal;
            signal.Core    = this;
            graph.AddFigure(signal);
        }