freetype-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Git][freetype/freetype][master] [base] Complete `ft_glyphslot_clear`.


From: Werner Lemberg
Subject: [Git][freetype/freetype][master] [base] Complete `ft_glyphslot_clear`.
Date: Fri, 02 Apr 2021 09:10:28 +0000

Werner Lemberg pushed to branch master at FreeType / FreeType

Commits:

2 changed files:

Changes:

  • ChangeLog
    1
    +2021-04-02  Ben Wagner  <bungeman@chromium.org>
    
    2
    +
    
    3
    +	[base] Complete `ft_glyphslot_clear`.
    
    4
    +
    
    5
    +	* src/base/ftobjs.c (ft_glyphslot_clear): This function is intended
    
    6
    +	to reset all the values of a glyph slot.  However, it was not
    
    7
    +	resetting the values of the advances and `glyph_index`.  Reset the
    
    8
    +	advances and `glyph_index` to zero.
    
    9
    +
    
    1 10
     2021-04-02  Ben Wagner  <bungeman@chromium.org>
    
    2 11
     
    
    3 12
     	[truetype] Prevent glyph program state from persisting.
    

  • src/base/ftobjs.c
    ... ... @@ -539,6 +539,8 @@
    539 539
         ft_glyphslot_free_bitmap( slot );
    
    540 540
     
    
    541 541
         /* clear all public fields in the glyph slot */
    
    542
    +    slot->glyph_index = 0;
    
    543
    +
    
    542 544
         FT_ZERO( &slot->metrics );
    
    543 545
         FT_ZERO( &slot->outline );
    
    544 546
     
    
    ... ... @@ -559,6 +561,8 @@
    559 561
     
    
    560 562
         slot->linearHoriAdvance = 0;
    
    561 563
         slot->linearVertAdvance = 0;
    
    564
    +    slot->advance.x         = 0;
    
    565
    +    slot->advance.y         = 0;
    
    562 566
         slot->lsb_delta         = 0;
    
    563 567
         slot->rsb_delta         = 0;
    
    564 568
       }
    


  • reply via email to

    [Prev in Thread] Current Thread [Next in Thread]