Esempio n. 1
0
        /// <summary>
        /// Add a set of QSOs - all for the same callsign - to the list to be printed
        /// </summary>
        public int AddQSOs(LabelEntry label, List<Contact> entries)
        {
            // For each group of up to n QSOs, print on to one label
            int startIndex = 0;
            int labelsUsedHere = 0;
            while (startIndex < entries.Count)
            {
                List<Contact> labelContacts = entries.GetRange(startIndex, Math.Min(QsoPerLabel, entries.Count - startIndex));
                List<TableEntry> labelEntries = labelContacts.ConvertAll<TableEntry>(c => new TableEntry(c));

                label.QSOs = labelEntries.ToArray();
                m_MainTable.AddCell(PopulateCell(label));
                startIndex += QsoPerLabel;
                m_LabelsUsed++;
                labelsUsedHere++;
            }
            return labelsUsedHere;
        }