Beispiel #1
0
        public void TestLoad()
        {
            DefaultTextRecord record = new DefaultTextRecord(TestcaseRecordInputStream.Create((short)0x1024, data));

            Assert.AreEqual(2, (int)record.FormatType);
            Assert.AreEqual(6, record.RecordSize);
        }
Beispiel #2
0
        private static DefaultTextRecord CreateDefaultTextRecord()
        {
            DefaultTextRecord r = new DefaultTextRecord();

            r.FormatType = TextFormatInfo.FontScaleNotSet;
            return(r);
        }
Beispiel #3
0
        public void TestStore()
        {
            DefaultTextRecord record = new DefaultTextRecord();
            record.FormatType = (TextFormatInfo)2;


            byte[] recordBytes = record.Serialize();
            Assert.AreEqual(recordBytes.Length - 4, data.Length);
            for (int i = 0; i < data.Length; i++)
                Assert.AreEqual(data[i], recordBytes[i + 4], "At offset " + i);
        }
Beispiel #4
0
        public DFTTextAggregate(RecordStream rs, ChartRecordAggregate container)
            : base(RuleName_DFTTEXT, container)
        {
            if (rs.PeekNextChartSid() == DataLabExtRecord.sid)
            {
                dataLabExt  = (DataLabExtRecord)rs.GetNext();
                startObject = (ChartStartObjectRecord)rs.GetNext();
            }
            defaultText   = (DefaultTextRecord)rs.GetNext();
            attachedLabel = new AttachedLabelAggregate(rs, this);

            if (startObject != null)
            {
                endObject = (ChartEndObjectRecord)rs.GetNext();
            }
        }