Ejemplo n.º 1
0
        private void btFindAll_Click(object sender, EventArgs e)
        {
            FCTB.FindAll(FindText);

            Range range;
            //range.
        }
Ejemplo n.º 2
0
 private void SearchForm_FormClosing(object sender, FormClosingEventArgs e)
 {
     if (e.CloseReason == CloseReason.UserClosing)
     {
         e.Cancel = true;
         Hide();
     }
     FCTB?.Focus();
 }
Ejemplo n.º 3
0
 private void Find()
 {
     if (cbNext.Checked)
     {
         FCTB.FindNext(FindText);
     }
     else
     {
         FCTB.FindPrevious(FindText);
     }
 }
Ejemplo n.º 4
0
 public void ClearBookmarks()
 {
     //int line = 0;
     //while (line < fctbOutput.LinesCount)
     //{
     //    fctbOutput.Bookmarks.Remove(line);
     //    fctbOutput.Lines.
     //    line++;
     //}
     FCTB.Bookmarks.Clear();
     FCTB.Refresh();
 }
Ejemplo n.º 5
0
        public void SaveToFile()
        {
            SaveFileDialog sfd = new SaveFileDialog();

            sfd.Filter     = "(*.txt)|*.txt";
            sfd.DefaultExt = "txt";

            if (sfd.ShowDialog() == DialogResult.OK)
            {
                FCTB.SaveToFile(sfd.FileName, Encoding.ASCII);
            }
        }
Ejemplo n.º 6
0
 private void fctbRcv_MouseDoubleClick(object sender, MouseEventArgs e)
 {
     if (e.X < FCTB.LeftIndent)
     {
         var place = FCTB.PointToPlace(e.Location);
         if (FCTB.Bookmarks.Contains(place.iLine))
         {
             FCTB.Bookmarks.Remove(place.iLine);
         }
         else
         {
             FCTB.Bookmarks.Add(place.iLine);
         }
     }
 }
Ejemplo n.º 7
0
        private void AppendRcvText(string msg)
        {
            LogToFile(msg);

            BeginInvoke(new Action(() =>
            {
                FCTB.BeginUpdate();
                FCTB.AppendText(msg);
                if (fctbRcvAutoScroll)
                {
                    //fctbRcv.GoEnd();
                    FCTB.GoEndHead();
                }
                FCTB.EndUpdate();
            }));
        }
Ejemplo n.º 8
0
        public DummyDoc(SerialPort p, CustomStyle style)
        {
            InitializeComponent();
            AutoScaleMode = AutoScaleMode.Dpi;

            rcvSetting = new ReceiveSetting(this);

            if (null != p)
            {
                Text = p.PortName;

                serialPort.PortName = p.PortName;
                serialPort.BaudRate = p.BaudRate;
                serialPort.DataBits = p.DataBits;
                serialPort.StopBits = p.StopBits;
                serialPort.Parity   = p.Parity;
            }
            else
            {
                FCTB.AppendText("create fail");
            }

            UpdateStyle(style);
        }
Ejemplo n.º 9
0
 private void copyToolStripMenuItem_Click(object sender, EventArgs e)
 {
     FCTB.Copy();
 }
Ejemplo n.º 10
0
 private void ClearReceive()
 {
     FCTB.Clear();
     rcvCharNum = 0;
 }
Ejemplo n.º 11
0
 public void Clear()
 {
     FCTB.Clear();
 }