コード例 #1
0
ファイル: ListMessage.cs プロジェクト: sillsdev/chorus
        public ListViewItem GetListViewItem(ChorusNotesDisplaySettings displaySettings)
        {
            var i = new ListViewItem(ParentAnnotation.GetLabelFromRef(""));

            i.Tag = this;
            if (_sLabelFont == null)
            {
                //we cache this to save memory
                _sLabelFont = new Font(displaySettings.WritingSystemForNoteLabel.FontName, 10);
            }
            //note: while we would like to just use this font for the label column, this winform ui component
            //doesn't support different fonts.
            i.Font = _sLabelFont;
            i.SubItems.Add(Message.GetAuthor("?"));
            i.SubItems.Add(Message.Date.ToShortDateString());
            SetListViewImage(i);
            return(i);
        }