Exemplo n.º 1
0
 public static void Add(VisualCue config)
 {
     lock (AllConfigs)
     {
         AllConfigs.Add(config);
     }
 }
Exemplo n.º 2
0
 private void MnuPFont_Click(object sender, EventArgs e)
 {
     if (DlgFontForLSV.ShowDialog() == DialogResult.OK)
     {
         var selFont = DlgFontForLSV.Font;
         if (selFont != fontForListView)
         {
             foreach (var openFile in mapOpenFiles.Values)
             {
                 openFile.SetLSVFont(selFont);
             }
             VisualCue.UpdateDecorationForUnMatchedLogEntries(null, null, selFont);
         }
         fontForListView = selFont;
     }
 }
Exemplo n.º 3
0
        private void lsvTailViewer_RetrieveVirtualItem(object sender, RetrieveVirtualItemEventArgs e)
        {
            var lineToDisplay = tailedFile[e.ItemIndex];

            e.Item = new ListViewItem((e.ItemIndex + 1).ToString())
            {
                UseItemStyleForSubItems = false,
                ToolTipText             = lineToDisplay
            };
            VisualCue cfg = null;// HighlightsHandler.TryGetConfigFor(lineToDisplay);

            if (cfg != null)
            {
                e.Item.SubItems.Add(lineToDisplay, cfg.ForeGround, cfg.BackGround, cfg.DisplayFont);
            }
            else
            {
                e.Item.SubItems.Add(lineToDisplay, Color.Black, Color.White, lsvTailViewer.Font);
            }
        }