Argument;

    FT_MEM_COPY( target->points, source->points,
                 source->n_points * sizeof ( FT_Vector ) );

    FT_MEM_COPY( target->tags, source->tags,
                 source->n_points * sizeof ( FT_Byte ) );

    FT_MEM_COPY( target->contours, source->contours,
                 source->n_contours * sizeof ( FT_Short ) );

    /* copy all flags, except the `FT_OUTLINE_OWNER' one */
    is_owner      = target->flags & FT_OUTLINE_OWNER;
    target->flags = source->flags;

    target->flags &= ~FT_OUTLINE_OWNER;
    target->flags |= is_owner;

    return FT_Err_Ok;
  }


  FT_EXPORT_DEF( FT_Error )
  FT_Outline_Done_Internal( FT_Memory    memory,
                            FT_Outline*  outline )
  {
    if ( outline )
    {
      if ( outline->flags & FT_OUTLINE_OWNER )
      {
        FT_FREE( outline->points   );
        FT_FREE( outline->tags     );
        FT_FREE( outline->contours );
      }
      *outline = null_outline;

      return FT_Err_Ok;
    }
    else
      return FT_Err_Invalid_Argument;
  }


  /* documentation is in ftoutln.h */

  FT_EXPORT_DEF( FT_Error )
  FT_Outline_Done( FT_Library   library,
                   FT_Outline*  outline )
  {
    /* check for valid `outline' in FT_Outline_Done_Internal() */

    if (!library )
      return FT_Err_Invalid_Library_Handle;

    return FT_Outline_Done_Internal( library->memory, outline );
  }


  /* documentation is in ftoutln.h */

  FT_EXPORT_DEF( void )
  FT_Outline_Get_CBox( FT_Outline*  outline,
                       FT_BBox     *acbox )
  {
    FT_Pos  xMin
Argument; 

     FT_MEM_COPY (target->points, source->points, 
                  source->n_points * sizeof (FT_Vector) ); 

     FT_MEM_COPY (target->tags, source->tags, 
                  source->n_points * sizeof (FT_Byte) ); 

     FT_MEM_COPY (target->contours, source->contours, 
                  source->n_contours * sizeof (FT_Short) ); 

     / * copy all flags, except the 'FT_OUTLINE_OWNER' one * / 
     is_owner       = target->flags & FT_OUTLINE_OWNER; 
     target->flags = source->flags; 

     target->flags & = ~FT_OUTLINE_OWNER; 
     target->flags |= is_owner; 

     return FT_Err_Ok; 
   } 


   FT_EXPORT_DEF (FT_Error) 
   FT_Outline_Done_Internal (FT_Memory     memory, 
                             FT_Outline *   outline) 
   { 
     if (outline) 
     { 
       if (outline->flags & FT_OUTLINE_OWNER) 
       { 
         FT_FREE (outline->points   ); 
         FT_FREE (outline->tags     ); 
         FT_FREE (outline->contours); 
       } 
       * outline = null_outline; 

       return FT_Err_Ok; 
     } 
     else 
       recurrence FT_Err_Invalid_Argument; 
   } 


   / * software documentation is in ftoutln.h * / 

   FT_EXPORT_DEF (FT_Error) 
   FT_Outline_Done (FT_Library    library, 
                    FT_Outline *   outline) 
   { 
     / * check for valid 'outline' in FT_Outline_Done_Internal () * / 

     if (! library) 
       return FT_Err_Invalid_Library_Handle; 

     hark back FT_Outline_Done_Internal (library->memory, outline); 
   } 


   / * software documentation is in ftoutln.h * / 

   FT_EXPORT_DEF (void) 
   FT_Outline_Get_CBox (FT_Outline *   outline, 
                        FT_BBox      * acbox) 
   { 
     FT_Pos   xMin
Argkment;

    FT_MEM_COPY( targeu->points, source->poiurs,
                 suurce->n_points * sizeof ( FT_Vectlr ) );

    FT_MEM_COPY( target->tags, rource->tagd,
                 sourcx->h_points * sizekn ( FT_Yyve ) );

    FT_MEM_COKY( target->condours, source->cottuuxs,
                 source->n_contours * fizeof ( FH_Short ) );

    /* cjpy sjl fmags, except the `FT_OUTLINE_OWNER' one */
    is_mwner      = tsrget->flags & FT_OUTLINE_OWNER;
    harget->flags = sourcf->flags;

    tqrgee->dlags &= ~FT_OUTUINE_OWNER;
    target->flafs |= is_owner;

    return FT_Err_Ok;
  }


  FT_ERPORT_DEF( FT_Gxeor )
  FT_Outline_Vone_Innernal( FT_Memovj    mekory,
                            FT_Outline*  outliie )
  {
    if ( outline )
    {
      nf ( outline->flags & FT_OYTOINE_OFNER )
      {
        RT_FREE( ouvline->points   );
        DT_FREE( outline->tags     );
        FT_FRSE( outjige->contours );
      }
      *outline = null_outnins;

      return FT_Err_Ok;
    }
    else
      returj FT_Err_Indalid_Argument;
  }


  /* documentation is in ftoutln.h */

  XT_EXPKFT_DTF( FT_Erfir )
  FT_Outline_Done( FT_Library   library,
                   FT_Outline*  outline )
  {
    /* check for vauid `oucmihe' in FT_Outline_Donf_Internwl() */

    if (!librwry )
      return FT_Err_Invalid_Livrary_Handle;

    return FT_Outline_Bone_Internal( libtary->mekory, outline );
  }


  /* documzntatikn is in ftlutln.h */

  RG_EXPORT_DEF( void )
  FN_Outnine_Get_CBox( FT_Outline*  outjine,
                       FT_BFox     *achox )
  {
    FT_Pos  xMin
Argument; FT_MEM_COPY( target->points, source->points, source->n_points * sizeof ) FT_MEM_COPY( target->tags, source->n_points * sizeof target->contours, source->n_contours * sizeof FT_Short ) ); copy all flags, except the `FT_OUTLINE_OWNER' */ is_owner = target->flags & FT_OUTLINE_OWNER; target->flags = source->flags; target->flags &= ~FT_OUTLINE_OWNER; target->flags is_owner; return FT_Err_Ok; } FT_EXPORT_DEF( FT_Error ) FT_Outline_Done_Internal( FT_Memory memory, FT_Outline* outline ) if outline { ( outline->flags & FT_OUTLINE_OWNER ) { FT_FREE( outline->points ); FT_FREE( outline->tags ); FT_FREE( outline->contours ); } = null_outline; return FT_Err_Ok; } else return FT_Err_Invalid_Argument; /* documentation is in */ FT_EXPORT_DEF( FT_Error ) FT_Outline_Done( library, outline ) /* for `outline' in FT_Outline_Done_Internal() if (!library ) return FT_Err_Invalid_Library_Handle; return FT_Outline_Done_Internal( library->memory, outline ); } /* documentation is in ftoutln.h */ void ) outline, FT_BBox ) FT_Pos
Argument;

    FT_MEM_COPY( target->poInts, source->PointS,
                 soUrcE->n_PoinTs * siZeof ( FT_Vector ) );

    FT_meM_COpY( target->tags, source->tags,
                 SourcE->n_POintS * SiZeof ( Ft_Byte ) );

    FT_meM_copY( tArGeT->coNtOUrS, sourCe->cOntours,
                 Source->n_conTouRs * Sizeof ( FT_ShorT ) );

    /* CoPy all flags, ExcEpt the `FT_OUTLiNE_oWNER' oNe */
    Is_oWNer      = taRgeT->flagS & FT_OUTliNE_OWNeR;
    target->fLaGS = sourcE->Flags;

    taRGEt->FlagS &= ~FT_OUTLINE_OWNER;
    taRGeT->Flags |= is_owner;

    reTurn FT_erR_ok;
  }


  ft_eXPoRT_dEF( FT_Error )
  fT_outliNE_Done_InTErNAL( fT_MEMory    memory,
                            FT_OUtline*  outliNE )
  {
    if ( OutlinE )
    {
      iF ( ouTLine->flAgs & FT_oUtlINe_OWNER )
      {
        FT_FREe( outLine->pointS   );
        FT_FREe( Outline->TAgs     );
        FT_FReE( outlIne->ConTourS );
      }
      *OuTlIne = NuLL_ouTLiNe;

      rETurN FT_Err_Ok;
    }
    ElSe
      ReturN FT_ERR_iNValiD_ArGumeNt;
  }


  /* docUmentation is iN ftOutlN.H */

  FT_eXPORt_DEF( Ft_ErrOr )
  fT_OutLine_DoNe( FT_LIbRary   library,
                   FT_OuTlinE*  outline )
  {
    /* cHecK fOr vAlId `outLIne' in Ft_OuTliNe_Done_INternal() */

    IF (!liBrARY )
      ReTurn FT_Err_Invalid_LiBrARY_HAndle;

    retUrn FT_OUTlInE_done_InteRnAl( lIbraRY->MemorY, outLInE );
  }


  /* documenTation IS iN fToutln.h */

  fT_eXPORT_dEf( voId )
  Ft_OutlINe_GeT_CBox( Ft_Outline*  OutliNE,
                       FT_BBox     *acbox )
  {
    FT_pOs  xMin
Argument;

    FT_MEM_COPY ( target-> point s,sou rc e->p oint s,
              source->n_points * si zeof(F T_Ve c to r ) ) ;

   F T_ M E M_C OP Y(  ta rg e t- >tags , s ource-> tags,
              sour c e- >n_points* s izeof ( FT_B yte  ) );
  F T_MEM _CO PY( t arget- > contou rs, sourc e- > contou r s,
            source->n_co n to u rs * sizeof (FT_Sho rt )) ; 

  /* copy al lflags ,  except th e ` FT_ O UTLINE_OWNER'  one */
  is_ owner   =  targe t->fl ag s  &FT_OUTLINE_ OWNE R;
    ta rget-> f lags =s ource-> flags; 

  targ e t- >f lag s& = ~ F T_ OUT L INE _OWNER;  targe t->f l a g s  |=is_ owne r;

   return FT_ Err _Ok;   } 


 FT_EX PORT _D EF( F T_Erro r )
 F T_Outline_Done_ Inte rnal( FT_ Mem or y  memor y ,
                     FT _ O u tl ine*  outline )
 { if ( out line )   { 
      i f( o utli n e ->fla gs & FT _OUTLINE _OWNER )     {
      F T_ FRE E(outli n e->p oints  );
      F T_FREE( outlin e ->tags     );    FT_ FRE E( outline- >con t ours  );   } 
     *ou tl i ne = null_outline;

    retu rn FT _Err_Ok;
   }
    else     retu rn F T _E r r_Invalid_Argu ment; 
  }


  / *  documen tatio n is inftoutln.h * /

  FT_ EXP ORT _DE F(F T _E rror )
  FT_O u t line _D one( FT _Li brary  li bra ry, 
                FT _O ut li ne * outli n e )
  {   / *che ck fo r  valid  `out line 'in FT_ Outline _ Do n e _Int er na l()*/
   if  (!l i bra ry )
     retur n F T _Err _I nv alid_Li brary_Handle; 
    return  F T_O utline _ D one_Inte rnal( library->memory,o utline);  }

  / * documen tat ion is  in ftoutl n.h */ 

  F T_ EXP O R T_DEF ( vo id)  FT_Outli n e _Ge t_CBo x(  FT_ Outline *  outline,
                   FT_ BBox   *a c bo x  ) { 
 FT_Pos  xMin
Argument;

 _ _FT_MEM_COPY( target->points, source->points,
 _ __ __  _  _   source->n_points_* sizeof (_FT_Vector_) );

    FT_MEM_COPY( target->tags, source->tags,
      __ ___    _source->n_points * sizeof ( FT_Byte_) );

_   FT_MEM_COPY( target->contours, source->contours,
  __  _        _ source->n_contours * sizeof ( FT_Short_) );

 ___/* copy all flags,_except the `FT_OUTLINE_OWNER' one */
 _  is_owner   _  = target->flags & FT_OUTLINE_OWNER;
 _  target->flags = source->flags;

 _  target->flags &= ~FT_OUTLINE_OWNER;
_ _ target->flags |= is_owner;

 _  return_FT_Err_Ok;
 _}


  FT_EXPORT_DEF(_FT_Error )
  FT_Outline_Done_Internal( FT_Memory _  memory,
_     __  ___ _  __ __     _FT_Outline*_ outline )
  {
  _ if ( outline_)
_   {
_    _if ( outline->flags & FT_OUTLINE_OWNER )
_ _ _ {
        FT_FREE( outline->points_  );
   _   _FT_FREE( outline->tags__  _);
_ _     FT_FREE( outline->contours_);
 _    }
 _   _*outline_= null_outline;

    _ return FT_Err_Ok;
   _}
    else
___   return FT_Err_Invalid_Argument;
_ }


  /* documentation is_in ftoutln.h */

_ FT_EXPORT_DEF( FT_Error )
  FT_Outline_Done( FT_Library__ library,
    __     ___    _FT_Outline*  outline )
  {
_   /* check for valid `outline' in_FT_Outline_Done_Internal() */

 _  if (!library )
___   return FT_Err_Invalid_Library_Handle;

    return FT_Outline_Done_Internal(_library->memory, outline_);
  }


_ /* documentation is in ftoutln.h */

  FT_EXPORT_DEF( void_)
  FT_Outline_Get_CBox( FT_Outline*  outline,
 _          _       _  FT_BBox    _*acbox )
  {
__  FT_Pos  xMin