コード例 #1
0
        public void TestNeutralLossTextSequences()
        {
            var document =
                (SrmDocument) new XmlSerializer(typeof(SrmDocument)).Deserialize(
                    new StringReader(NEUTRAL_LOSS_DOCUMENT));
            var peptideDocNode = document.Molecules.First();
            var modFontHolder  = new ModFontHolder(new Control());
            var textSequences  = PeptideTreeNode.CreateTextSequences(peptideDocNode, document.Settings, "MGFGGTLEIK", null, modFontHolder);

            VerifyTextSequences(textSequences,
                                Tuple.Create("M", FontStyle.Bold | FontStyle.Underline, Color.Black),
                                Tuple.Create("GFGGTLEIK", FontStyle.Regular, Color.Black)
                                );
        }
コード例 #2
0
        public void TestStaticAndHeavyTextSequences()
        {
            var document =
                (SrmDocument) new XmlSerializer(typeof(SrmDocument)).Deserialize(
                    new StringReader(STATIC_AND_HEAVY_MODIFICATIONS_DOCUMENT));
            var modFontHolder   = new ModFontHolder(new Control());
            var oxidizedPeptide = document.Molecules.First();

            VerifyTextSequences(PeptideTreeNode.CreateTextSequences(oxidizedPeptide, document.Settings, "MPEPTIDE", null, modFontHolder),
                                Tuple.Create("M", FontStyle.Bold | FontStyle.Underline, Color.Blue),
                                Tuple.Create("PEPTIDE", FontStyle.Bold, Color.Blue)
                                );

            var peptide = document.Molecules.Skip(1).First();

            VerifyTextSequences(PeptideTreeNode.CreateTextSequences(peptide, document.Settings, "MPEPTIDE", null, modFontHolder),
                                Tuple.Create("MPEPTIDE", FontStyle.Bold, Color.Blue));
        }