Exemplo n.º 1
0
        internal static GlyphPairAdjustmentRecord[] GetGlyphPairAdjustmentRecords(List <uint> glyphIndexes, out int recordCount)
        {
            FontEngine.GenericListToMarshallingArray <uint>(ref glyphIndexes, ref FontEngine.s_GlyphIndexes_MarshallingArray_A);
            FontEngine.PopulatePairAdjustmentRecordMarshallingArray_from_GlyphIndexes(FontEngine.s_GlyphIndexes_MarshallingArray_A, out recordCount);
            bool flag = recordCount == 0;

            GlyphPairAdjustmentRecord[] result;
            if (flag)
            {
                result = null;
            }
            else
            {
                FontEngine.SetMarshallingArraySize <GlyphPairAdjustmentRecord>(ref FontEngine.s_PairAdjustmentRecords_MarshallingArray, recordCount);
                FontEngine.GetGlyphPairAdjustmentRecordsFromMarshallingArray(FontEngine.s_PairAdjustmentRecords_MarshallingArray);
                FontEngine.s_PairAdjustmentRecords_MarshallingArray[recordCount] = default(GlyphPairAdjustmentRecord);
                result = FontEngine.s_PairAdjustmentRecords_MarshallingArray;
            }
            return(result);
        }
Exemplo n.º 2
0
        internal static GlyphPairAdjustmentRecord[] GetGlyphPairAdjustmentRecords(List <uint> newGlyphIndexes, List <uint> allGlyphIndexes)
        {
            FontEngine.GenericListToMarshallingArray <uint>(ref newGlyphIndexes, ref FontEngine.s_GlyphIndexes_MarshallingArray_A);
            FontEngine.GenericListToMarshallingArray <uint>(ref allGlyphIndexes, ref FontEngine.s_GlyphIndexes_MarshallingArray_B);
            int num;

            FontEngine.PopulatePairAdjustmentRecordMarshallingArray_for_NewlyAddedGlyphIndexes(FontEngine.s_GlyphIndexes_MarshallingArray_A, FontEngine.s_GlyphIndexes_MarshallingArray_B, out num);
            bool flag = num == 0;

            GlyphPairAdjustmentRecord[] result;
            if (flag)
            {
                result = null;
            }
            else
            {
                FontEngine.SetMarshallingArraySize <GlyphPairAdjustmentRecord>(ref FontEngine.s_PairAdjustmentRecords_MarshallingArray, num);
                FontEngine.GetGlyphPairAdjustmentRecordsFromMarshallingArray(FontEngine.s_PairAdjustmentRecords_MarshallingArray);
                FontEngine.s_PairAdjustmentRecords_MarshallingArray[num] = default(GlyphPairAdjustmentRecord);
                result = FontEngine.s_PairAdjustmentRecords_MarshallingArray;
            }
            return(result);
        }