< prev index next >

src/java.desktop/share/native/libfreetype/src/base/ftpsprop.c

Print this page


   1 /***************************************************************************/
   2 /*                                                                         */
   3 /*  ftpsprop.c                                                             */
   4 /*                                                                         */
   5 /*    Get and set properties of PostScript drivers (body).                 */
   6 /*    See `ftdriver.h' for available properties.                           */
   7 /*                                                                         */
   8 /*  Copyright 2017-2018 by                                                 */
   9 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
  10 /*                                                                         */
  11 /*  This file is part of the FreeType project, and may only be used,       */
  12 /*  modified, and distributed under the terms of the FreeType project      */
  13 /*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
  14 /*  this file you indicate that you have read the license and              */
  15 /*  understand and accept it fully.                                        */
  16 /*                                                                         */
  17 /***************************************************************************/
  18 
  19 
  20 #include <ft2build.h>
  21 #include FT_DRIVER_H
  22 #include FT_INTERNAL_DEBUG_H
  23 #include FT_INTERNAL_POSTSCRIPT_AUX_H
  24 #include FT_INTERNAL_OBJECTS_H
  25 #include FT_INTERNAL_POSTSCRIPT_PROPS_H
  26 
  27 
  28   /*************************************************************************/
  29   /*                                                                       */
  30   /* The macro FT_COMPONENT is used in trace mode.  It is an implicit      */
  31   /* parameter of the FT_TRACE() and FT_ERROR() macros, used to print/log  */
  32   /* messages during execution.                                            */
  33   /*                                                                       */
  34 #undef  FT_COMPONENT
  35 #define FT_COMPONENT  trace_psprops
  36 
  37 
  38   FT_BASE_CALLBACK_DEF( FT_Error )
  39   ps_property_set( FT_Module    module,         /* PS_Driver */
  40                    const char*  property_name,
  41                    const void*  value,
  42                    FT_Bool      value_is_string )
  43   {
  44     FT_Error   error  = FT_Err_Ok;
  45     PS_Driver  driver = (PS_Driver)module;
  46 
  47 #ifndef FT_CONFIG_OPTION_ENVIRONMENT_PROPERTIES
  48     FT_UNUSED( value_is_string );
  49 #endif
  50 
  51 
  52     if ( !ft_strcmp( property_name, "darkening-parameters" ) )
  53     {
  54       FT_Int*  darken_params;
  55       FT_Int   x1, y1, x2, y2, x3, y3, x4, y4;


   1 /****************************************************************************
   2  *
   3  * ftpsprop.c
   4  *
   5  *   Get and set properties of PostScript drivers (body).
   6  *   See `ftdriver.h' for available properties.
   7  *
   8  * Copyright (C) 2017-2019 by
   9  * David Turner, Robert Wilhelm, and Werner Lemberg.
  10  *
  11  * This file is part of the FreeType project, and may only be used,
  12  * modified, and distributed under the terms of the FreeType project
  13  * license, LICENSE.TXT.  By continuing to use, modify, or distribute
  14  * this file you indicate that you have read the license and
  15  * understand and accept it fully.
  16  *
  17  */
  18 
  19 
  20 #include <ft2build.h>
  21 #include FT_DRIVER_H
  22 #include FT_INTERNAL_DEBUG_H
  23 #include FT_INTERNAL_POSTSCRIPT_AUX_H
  24 #include FT_INTERNAL_OBJECTS_H
  25 #include FT_INTERNAL_POSTSCRIPT_PROPS_H
  26 
  27 
  28   /**************************************************************************
  29    *
  30    * The macro FT_COMPONENT is used in trace mode.  It is an implicit
  31    * parameter of the FT_TRACE() and FT_ERROR() macros, used to print/log
  32    * messages during execution.
  33    */
  34 #undef  FT_COMPONENT
  35 #define FT_COMPONENT  psprops
  36 
  37 
  38   FT_BASE_CALLBACK_DEF( FT_Error )
  39   ps_property_set( FT_Module    module,         /* PS_Driver */
  40                    const char*  property_name,
  41                    const void*  value,
  42                    FT_Bool      value_is_string )
  43   {
  44     FT_Error   error  = FT_Err_Ok;
  45     PS_Driver  driver = (PS_Driver)module;
  46 
  47 #ifndef FT_CONFIG_OPTION_ENVIRONMENT_PROPERTIES
  48     FT_UNUSED( value_is_string );
  49 #endif
  50 
  51 
  52     if ( !ft_strcmp( property_name, "darkening-parameters" ) )
  53     {
  54       FT_Int*  darken_params;
  55       FT_Int   x1, y1, x2, y2, x3, y3, x4, y4;


< prev index next >