Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:75991 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 42879 invoked from network); 24 Jul 2014 04:56:26 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 24 Jul 2014 04:56:26 -0000 Authentication-Results: pb1.pair.com header.from=tjerk.meesters@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=tjerk.meesters@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.220.173 as permitted sender) X-PHP-List-Original-Sender: tjerk.meesters@gmail.com X-Host-Fingerprint: 209.85.220.173 mail-vc0-f173.google.com Received: from [209.85.220.173] ([209.85.220.173:49506] helo=mail-vc0-f173.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id B0/10-41057-8F190D35 for ; Thu, 24 Jul 2014 00:56:25 -0400 Received: by mail-vc0-f173.google.com with SMTP id hy10so3960965vcb.4 for ; Wed, 23 Jul 2014 21:56:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=v8dYJOcTWIYLWSSEm1sno4Oql8RLzGNYVTmP5T70C10=; b=wN48zFaS0rdMrYb5bchpLbiRUmZEprbZCGfmUDLDJoeiO8CX8jPMn757PPSGVBQTU8 dRo0oSr1mRSAEg8OpZyOfjYevOYXgzEW3KzuKV1ipyFER1DsSl4tD/spmjlE+2HTqCii X4EAYKMaD6Cr8b8DbzD4qEitW76Uh7dk78+m1745p55inI3DnMjxQjQFKrCpzM78dSxG eXyNdPW+T7oc+79UG+T/qmlksTOMC0XL+QgJit2K12vy3B+xqjd4Kr3AsBrD5jVgQP/L jOtqxxj0jlZM/GEYSbC7v9b2gJTi+8Sy6oyml7o4xenIEXjJEiyxFxzK7YtybFUqPRvR DSgg== MIME-Version: 1.0 X-Received: by 10.52.252.226 with SMTP id zv2mr6840253vdc.19.1406177785048; Wed, 23 Jul 2014 21:56:25 -0700 (PDT) Received: by 10.58.89.170 with HTTP; Wed, 23 Jul 2014 21:56:25 -0700 (PDT) In-Reply-To: References: Date: Thu, 24 Jul 2014 12:56:25 +0800 Message-ID: To: Lonny Kapelushnik Cc: PHP Internals , Pierre Joye Content-Type: multipart/alternative; boundary=001a1135ed225e764304fee94715 Subject: Re: [PHP-DEV] Deprecating GD functions imagettftext/bbox From: tjerk.meesters@gmail.com (Tjerk Meesters) --001a1135ed225e764304fee94715 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Hi Lonny, On Wed, Jul 23, 2014 at 3:01 AM, Lonny Kapelushnik wrote: > Morning, > > I propose deprecating two GD functions: imagettftext and imagettfbbox. > > The reasons I would like to deprecate them are: > 1. Their functionality is a subset of imagefttext and imageftbbox > 2. The imagettf* functions have the same requirements as the imageft* > functions > 3. The imagettf* functions parameters are compatible with the imageft* > functions parameters > > As far as I can tell the original reason for having both functions was > because PHP LIBGD is a custom implementation of LIBGD that had additional > functionality from the actual LIBGD. While this is still the case it seem= s > that now the required functions (gdImageStringFT and gdImageStringFTEx) > exist in both libraries. > > The only difference between imagettf* and imageft* functions is the > imagettf* functions do not provide the optional =E2=80=98extrainfo=E2=80= =99 parameter > > The only step to migrate from the imagettf* functions to imageft* > functions is to change the function names from =E2=80=98imagettf*=E2=80= =99 to =E2=80=98imageft*' > I'm glad to see you've taken the time to write this down after our small discussion on chat the other day :) According to the release process, an x+1.0.0 release may break API, so that would technically mean they can be removed for php.next granted an RFC is submitted and accepted before then. That said, I didn't see any clear guidelines as to how deprecation periods should be outlined, so I would expect some discussions to arise from that .. > I would like to create a timeline to deprecate and remove the imagettf* > functions. Providing a timeline will allow for: > 1. Clarity for which PHP functions to use going forward > 2. Ability to plan a migration to the new PHP functions > 3. Clarity for which PHP functions to improve in php-src > 4. Ability to clean up some of the GD code in php-src > From what I could tell, the clean up will be relatively small because both functions already call the same underlying php_image*_common() function. > I will hold off on proposing an actual timeline for now. > I can implement any coding changes needed. > > Please let me know the general thoughts to deprecating these functions. I= f > the reception is positive I would like to create an RFC to discuss this = in > full and come up with a timeline. > Personally I think, although the current functions are used a lot more often (~ 3x based on Google results), the simple fix makes it relatively easy to port existing code. From what I could tell you don't have a Wiki account yet, so that would be the first step :) > > =E2=80=93=E2=80=93=E2=80=93 > Hakuna Matata! > Lonny Kapelushnik > https://www.lonnylot.com > 732.685.9175 > > --=20 -- Tjerk --001a1135ed225e764304fee94715--