freetype-commit
[Top][All Lists]
Advanced

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

[freetype2-demos] master 0e60650: [ftlint] Improve output.


From: Werner Lemberg
Subject: [freetype2-demos] master 0e60650: [ftlint] Improve output.
Date: Wed, 30 Jun 2021 04:23:26 -0400 (EDT)

branch: master
commit 0e6065003129dfb518b538fc4707004679d9d691
Author: Werner Lemberg <wl@gnu.org>
Commit: Werner Lemberg <wl@gnu.org>

    [ftlint] Improve output.
    
    * src/ftlint.c (main): Add header to output and remove repetitive
    strings.
    (Analyze): Updated.
---
 ChangeLog     |  8 ++++++++
 src/ftlint.c  | 15 +++++++++++----
 src/ftmulti.c |  6 +++---
 3 files changed, 22 insertions(+), 7 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 534f7a0..0566b0d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2021-06-30  Werner Lemberg  <wl@gnu.org>
+
+       [ftlint] Improve output.
+
+       * src/ftlint.c (main): Add header to output and remove repetitive
+       strings.
+       (Analyze): Updated.
+
 2021-06-22  Alexei Podtelezhnikov  <apodtele@gmail.com>
 
        [ftlint] Improve error reporting.
diff --git a/src/ftlint.c b/src/ftlint.c
index fd75568..3996661 100644
--- a/src/ftlint.c
+++ b/src/ftlint.c
@@ -107,7 +107,7 @@
       s1 += d1;
     }
 
-    printf( "X=%.4lf  ", s1 ? (double)s2 / s1 : 2.0 );
+    printf( "%.4lf ", s1 ? (double)s2 / s1 : 2.0 );
 
     /* Y-acutance */
     for ( s1 = s2 = 0, j = 0; j < bitmap->width; j++ )
@@ -126,7 +126,7 @@
       s1 += d1;
     }
 
-    printf( "Y=%.4lf  ", s1 ? (double)s2 / s1 : 2.0 );
+    printf( "%.4lf ", s1 ? (double)s2 / s1 : 2.0 );
   }
 
 
@@ -248,7 +248,7 @@
         continue;
       }
 
-      printf( quiet ? "  %s %s:" : "  %s %s:\n",
+      printf( quiet ? "  %s %s:" : "  %s %s\n\n",
               face->family_name, face->style_name );
 
       error = FT_Set_Char_Size( face, ptsize << 6, ptsize << 6, 72, 72 );
@@ -262,6 +262,13 @@
       li = last_index < (unsigned int)face->num_glyphs ?
                         last_index : (unsigned int)face->num_glyphs - 1;
 
+      if ( !quiet )
+      {
+        /*      "NNNNN AAAxBBBB X.XXXX Y.YYYY 
MMDD55MMDD55MMDD55MMDD55MMDD55MM" */
+        printf( " GID  imgsize  Xacut  Yacut  MD5 hashsum\n" );
+        printf( 
"-------------------------------------------------------------\n" );
+      }
+
       Fail = 0;
       for ( id = fi; id <= li; id++ )
       {
@@ -283,7 +290,7 @@
         if ( quiet )
           continue;
 
-        printf( "%5u: ", id );
+        printf( "%5u ", id );
 
         error = FT_Render_Glyph( face->glyph, render_mode );
         if ( error && error != FT_Err_Cannot_Render_Glyph )
diff --git a/src/ftmulti.c b/src/ftmulti.c
index 761da20..c68f8e5 100644
--- a/src/ftmulti.c
+++ b/src/ftmulti.c
@@ -109,9 +109,9 @@
   static FT_MM_Var    *multimaster   = NULL;
   static FT_Fixed      design_pos   [MAX_MM_AXES];
   static FT_Fixed      requested_pos[MAX_MM_AXES];
-  static unsigned int  requested_cnt = 0;
-  static unsigned int  used_num_axis = 0;
-  static int           increment = 20;  /* for axes */
+  static unsigned int  requested_cnt =  0;
+  static unsigned int  used_num_axis =  0;
+  static int           increment     = 20;  /* for axes */
 
   /*
    * We use the following arrays to support both the display of all axes and



reply via email to

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