コード例 #1
0
        private void FreeGlyphBuffers()
        {
            GlyphCapacity = 0;

            if (Glyphs != null)
            {
                Memory.Free(Glyphs);
                Glyphs = null;
            }

            if (GlyphVisualAttributes != null)
            {
                Memory.Free(GlyphVisualAttributes);
                GlyphVisualAttributes = null;
            }

            if (GlyphAdvanceWidths != null)
            {
                Memory.Free(GlyphAdvanceWidths);
                GlyphAdvanceWidths = null;
            }

            if (GlyphOffsets != null)
            {
                Memory.Free(GlyphOffsets);
                GlyphOffsets = null;
            }
        }
コード例 #2
0
 private void ReAllocGlyphBuffers(int newGlyphCapacity)
 {
     Glyphs = (ushort *)Memory.ReAlloc(Glyphs, newGlyphCapacity * sizeof(ushort));
     GlyphVisualAttributes = (SCRIPT_VISATTR *)Memory.ReAlloc(GlyphVisualAttributes, newGlyphCapacity * sizeof(SCRIPT_VISATTR));
     GlyphAdvanceWidths    = (int *)Memory.ReAlloc(GlyphAdvanceWidths, newGlyphCapacity * sizeof(int));
     GlyphOffsets          = (GOFFSET *)Memory.ReAlloc(GlyphOffsets, newGlyphCapacity * sizeof(GOFFSET));
 }
コード例 #3
0
 private void InitializeGlyphBuffers()
 {
     GlyphCapacity         = 0;
     Glyphs                = null;
     GlyphVisualAttributes = null;
     GlyphAdvanceWidths    = null;
     GlyphOffsets          = null;
 }
コード例 #4
0
 public static extern int ScriptCPtoX(
     [In] int iCP,
     [In] bool fTrailing,
     [In] int cChars,
     [In] int cGlyphs,
     [In] ushort *pwLogClust,
     [In] SCRIPT_VISATTR *psva,
     [In] int *piAdvance,
     [In] SCRIPT_ANALYSIS *psa,
     [Out] out int piX);
コード例 #5
0
 public static extern int ScriptXtoCP(
     [In] int iX,
     [In] int cChars,
     [In] int cGlyphs,
     [In] ushort *pwLogClust,
     [In] SCRIPT_VISATTR *psva,
     [In] int *piAdvance,
     [In] SCRIPT_ANALYSIS *psa,
     [Out] out int piCP,
     [Out] out int piTrailing);
コード例 #6
0
 public static extern int ScriptPlace(
     [In] IntPtr hdc,
     [In, Out] ref IntPtr psc,
     [In] ushort *pwGlyphs,
     [In] int cGlyphs,
     [In] SCRIPT_VISATTR *psva,
     [In, Out] SCRIPT_ANALYSIS *psa,
     [Out] int *piAdvance,
     [Out] GOFFSET *pGoffset,
     [Out] out ABC pABC);
コード例 #7
0
 public static extern int ScriptShape(
     [In] IntPtr hdc,
     [In, Out] ref IntPtr psc,
     [In] char *pwcChars,
     [In] int cChars,
     [In] int cMaxGlyphs,
     [Out] SCRIPT_ANALYSIS *psa,
     [Out] ushort *pwOutGlyphs,
     [Out] ushort *pwLogClust,
     [Out] SCRIPT_VISATTR *psva,
     [Out] out int pcGlyphs);
コード例 #8
0
        private void FreeGlyphBuffers()
        {
            GlyphCapacity = 0;

            if (Glyphs != null)
            {
                Memory.Free(Glyphs);
                Glyphs = null;
            }

            if (GlyphVisualAttributes != null)
            {
                Memory.Free(GlyphVisualAttributes);
                GlyphVisualAttributes = null;
            }

            if (GlyphAdvanceWidths != null)
            {
                Memory.Free(GlyphAdvanceWidths);
                GlyphAdvanceWidths = null;
            }

            if (GlyphOffsets != null)
            {
                Memory.Free(GlyphOffsets);
                GlyphOffsets = null;
            }
        }
コード例 #9
0
 private void ReAllocGlyphBuffers(int newGlyphCapacity)
 {
     Glyphs = (ushort*)Memory.ReAlloc(Glyphs, newGlyphCapacity * sizeof(ushort));
     GlyphVisualAttributes = (SCRIPT_VISATTR*)Memory.ReAlloc(GlyphVisualAttributes, newGlyphCapacity * sizeof(SCRIPT_VISATTR));
     GlyphAdvanceWidths = (int*)Memory.ReAlloc(GlyphAdvanceWidths, newGlyphCapacity * sizeof(int));
     GlyphOffsets = (GOFFSET*)Memory.ReAlloc(GlyphOffsets, newGlyphCapacity * sizeof(GOFFSET));
 }
コード例 #10
0
 private void InitializeGlyphBuffers()
 {
     GlyphCapacity = 0;
     Glyphs = null;
     GlyphVisualAttributes = null;
     GlyphAdvanceWidths = null;
     GlyphOffsets = null;
 }