Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:122988 X-Original-To: internals@lists.php.net Delivered-To: internals@lists.php.net Received: from php-smtp4.php.net (php-smtp4.php.net [45.112.84.5]) by qa.php.net (Postfix) with ESMTPS id DB55A1A009C for ; Fri, 5 Apr 2024 21:32:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1712352776; bh=1PB0LTr3GRIgA/0iqrLU/ubxqlQ/Zsvq7Pnx/7Vc5ww=; h=Subject:To:References:From:Date:In-Reply-To:From; b=gwsmfK75Tkfx2s8VfVSSyAlWpKaquBD2IH3/D3BJUHmWZ2ZjX3HFO7uGIPuN7tsae ZhjABLjdcUm5R+Wf+kEp9KyUlW8v1UTssGK8QhHTtTDnSIh6EbJI7WY+LdqyrdlNRB 78WOIuhmpm6ndEWcz5DSyqrIwQaiH7D+X19J2xSPb4OwJZU3FJEiPwmQ1nqJof4Sy/ LK+EGFdKtO1Fs87adQNrKK6GMIqxJ9mrwiZF+asZ1Fsy6wHZFV/rm60EUXTz8GvftP Kt0LkafXZGZEs/Ksgwbypu84PNUX1aya1mfPE66fU++XAYWbOm3k3m9CVSHgrRUfie FgPGd9jQbxdYw== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 0AF07180069 for ; Fri, 5 Apr 2024 21:32:55 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.0 (2022-12-13) on php-smtp4.php.net X-Spam-Level: ** X-Spam-Status: No, score=2.3 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_20, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,DMARC_MISSING, HTML_MESSAGE,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2, SPF_HELO_NONE,SPF_SOFTFAIL,T_SCC_BODY_TEXT_LINE,URIBL_SBL_A,URI_DOTEDU autolearn=no autolearn_force=no version=4.0.0 X-Spam-Virus: No X-Envelope-From: Received: from weasel.tulip.relay.mailchannels.net (weasel.tulip.relay.mailchannels.net [23.83.218.247]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Fri, 5 Apr 2024 21:32:54 +0000 (UTC) X-Sender-Id: a2hosting|x-authuser|juliette@adviesenzo.nl Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id 4870EC321A for ; Fri, 5 Apr 2024 21:32:23 +0000 (UTC) Received: from nl1-ss105.a2hosting.com (unknown [127.0.0.6]) (Authenticated sender: a2hosting) by relay.mailchannels.net (Postfix) with ESMTPA id 7658FC30BE for ; Fri, 5 Apr 2024 21:32:22 +0000 (UTC) ARC-Seal: i=1; s=arc-2022; d=mailchannels.net; t=1712352742; a=rsa-sha256; cv=none; b=Iefg8CZM2ZhoeOiVSNYDCUVOU1D7ePRDbWnMo2sfVH30To1qPc/ojsIUnlC57I5hZZcgaA N3lqoSA0MSjfe+tkMsRJ98PLDE5kOO8qVWQHU4V8KlNRXTNr4sX4ZpwrhZVU0Cxw4G3RMB zrJPw3oUvz7bRH01y6MaxbA3TJoLzoxTOjodm2yZ7Obi0DqnE+f1TIVJih54i/W5M0Vyr/ pbmqA1hBVF0glvjV5juxT5e+EXkiIv6c/NcAyfrQxqmORVp/Wa20eNmk1yOEBRVHtnkett 8MQPj1sTZB1FwCBgAuQhILavO/nfQhtMLeAbW7v141TAHVoks80Ay5TG1ytoKw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=mailchannels.net; s=arc-2022; t=1712352742; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references:dkim-signature; bh=JIR7ynQqucLkHL4WBUaWAjfoIAwYFFbWA0cZoM71PHE=; b=PE6FoenL+/4lcS9/QiTNAnclRdo5ylTPS8vK51jnAweE2m6TQtvzu03iuP0rmupn4my+oU H9B8UCtndYx1ac01y0zbgiKib9atA83ifJJRDDYbqds73uY2zo+trbHgqaM5Jozl5eQ683 OrdURn31UKa0aTMni2Rt0nENZpY/jExIWvOaNGGEHQoGrEJMXtmpVvV+gbFgxwUFF+7+PM 3FaVUyYNZq6tjInz1ESfe9kaltnEQVReYNi2kP/FH9U5y9NdCqrl6iUeWAQrzjZInYrOru Mtv5oi9d8QW4YkqgjAx2RUeGYgjewb/e65Vn9bJnD5rJhHHRRzRTGyjdvpgl5g== ARC-Authentication-Results: i=1; rspamd-687b9dd446-9778w; auth=pass smtp.auth=a2hosting smtp.mailfrom=php-internals_nospam@adviesenzo.nl X-Sender-Id: a2hosting|x-authuser|juliette@adviesenzo.nl X-MC-Relay: Neutral X-MailChannels-SenderId: a2hosting|x-authuser|juliette@adviesenzo.nl X-MailChannels-Auth-Id: a2hosting X-Left-Fearful: 289a6c6b2b18ec37_1712352743192_409797382 X-MC-Loop-Signature: 1712352743192:1491484271 X-MC-Ingress-Time: 1712352743191 Received: from nl1-ss105.a2hosting.com (nl1-ss105.a2hosting.com [85.187.142.69]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384) by 100.126.216.122 (trex/6.9.2); Fri, 05 Apr 2024 21:32:23 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=adviesenzo.nl; s=default; h=Content-Type:In-Reply-To:MIME-Version:Date: Message-ID:From:References:To:Subject:Sender:Reply-To:Cc: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=JIR7ynQqucLkHL4WBUaWAjfoIAwYFFbWA0cZoM71PHE=; b=cVVsAeEVFIG7RBxIwFp9sQZEqi RoaUtAZGyUNOqhFHiM637RjqRwvq0k0uQZ+862qDD+8gGlZ1+opLRm24ix98wJqwkv3YDXdPAD8ZJ GbGKDQB7E5LA0dga2oqf+oqy2XC5LTERVtRNzbXf6QihMQXLV3xGmKSSdMHQTViYKd70=; Received: from mailnull by nl1-ss105.a2hosting.com with spam-scanner (Exim 4.96.2) (envelope-from ) id 1rsrAa-00CMC6-2F for internals@lists.php.net; Fri, 05 Apr 2024 23:32:20 +0200 X-ImunifyEmail-Filter-Info: X0RSVUdTX01NX1BST05PVU5DRSBSQ1ZEX1ZJQV9TTVRQX0FV VEggUkN WRF9UTFNfQUxMIFZFUklMT0NLX0NCIFJDVkRfQ09VTlRfT05FIEJBWU VTX0hBTSBNSU1FX1VOS05PV04gQVJDX05BIE1JRF9SSFNfTUFUQ0hfR lJPTSBJRV9WTF9QQkxfQUNDT1VOVF8wNSBNSU1FX1RSQUNFIEZST01f RVFfRU5WRlJPTSBGUk9NX0hBU19ETiBUT19ETl9OT05FIFJDUFRfQ09 VTlRfT05FIElFX1ZMX1BCTF9BQ0NPVU5UXzAxIFRPX01BVENIX0VOVl JDUFRfQUxMIF9EUlVHU19NTV9ESVNDT1VOVCBBU04= X-ImunifyEmail-Filter-Action: no action X-ImunifyEmail-Filter-Score: 0.97 X-ImunifyEmail-Filter-Version: 3.5.10/202404051703 Received: from [143.178.154.86] (port=64317 helo=[192.168.1.16]) by nl1-ss105.a2hosting.com with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96.2) (envelope-from ) id 1rsrAd-00CMBn-07 for internals@lists.php.net; Fri, 05 Apr 2024 23:32:20 +0200 Subject: Re: [PHP-DEV] [RFC] Casing of acronyms in class and method names To: internals@lists.php.net References: <792b2282-b7a3-40dd-899c-daab55353316@bastelstu.be> <69107662-eb03-4b75-8eed-59dd2eed6559@gmail.com> <66103C7A.3040906@adviesenzo.nl> <80ac7108-e016-4ae8-87ad-50afa0c2f257@bastelstu.be> <37f1b0c6-a7c8-41f3-bf2f-7dd466bb31c9@app.fastmail.com> Message-ID: <66106DDF.6050308@adviesenzo.nl> Date: Fri, 5 Apr 2024 23:32:15 +0200 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.7.0 Precedence: bulk list-help: list-post: List-Id: internals.lists.php.net MIME-Version: 1.0 In-Reply-To: <37f1b0c6-a7c8-41f3-bf2f-7dd466bb31c9@app.fastmail.com> Content-Type: multipart/alternative; boundary="------------090207070606070305020209" X-AuthUser: juliette@adviesenzo.nl From: php-internals_nospam@adviesenzo.nl (Juliette Reinders Folmer) This is a multi-part message in MIME format. --------------090207070606070305020209 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit On 5-4-2024 22:55, Larry Garfield wrote: > On Fri, Apr 5, 2024, at 7:15 PM, Tim Düsterhus wrote: >> Hi >> >> On 4/5/24 20:01, Juliette Reinders Folmer wrote: >>> In the "It decreases readability" section you make a sweeping statement >>> about accessibility, but don't back that up with research. Please back >>> your statement up as based on my understanding, the opposite is true. >> For context: This paragraph was added by Larry. It's my name on the RFC >> of course and I approved of the addition he made. Nevertheless Larry >> might've additional resources to add here. >> >>> Case in point: if written in all caps, screenreaders will spell the >>> characters out - think HTML -. If written in Mixed case, screenreaders >>> will try to pronounce the word, making acronyms and other abbreviations >>> very hard to understand for anyone using a screenreader. >>> >>> This is something which has repeatedly been pointed out, for instance at >>> conferences regarding conference acronym hashtags, like #DPC. >>> >>> So, I'd be very interested to see your statement backed up by actual >>> research and invite you to look into this a little deeper. >> Your remark looks at the accessibility from the PoV of a developer with >> impaired eyesight that is dependent on assistive technology. However >> accessibility also affects developers with regular vision. The concerns >> of these two groups might conflict. >> >> W3C's accessibility guidelines point out that: >> >> > Text in all capital letters is more difficult to read for most >> people, with and without disabilities. >> >> (https://w3c.github.io/low-vision-a11y-tf/requirements.html#capitalization) >> >> Harvards's Accessibility Guidelines agree: >> >> > Avoid using all caps. Readability is reduced with all caps because >> all words have a uniform rectangular shape, meaning readers can't >> identify words by their shape. >> >> (https://accessibility.huit.harvard.edu/design-readability) >> >> Of course program identifiers are not regular text and indeed more >> similar to hashtags, in that they do not permit the inclusion of >> whitespace to separate words. Underscores would work, but that would >> just add to the inconsistency. >> >> For Hashtags I found several resources pointing out to capitalize each >> word separately. For acronyms most resources pointed out that they >> should be avoided entirely (e.g. >> https://studentlife.mit.edu/das/accessibility/digital-accessibility/socialmedia, >> https://www.nyu.edu/life/information-technology/web-and-digital-publishing/digital-publishing/accessibility/how-to-guides/social-media.html#acronyms) >> and that recommendation is already part of the existing guidelines. >> >> I've tested with my Android phone with the 'performHttpRequest' example >> and both variants where read out equally terrible as 'per-form age tee >> tee pre-quest' (i.e. merging the p with the request). And your example >> of HTML was read out as 'age tee em el' (or rather the German >> pronounciation of the letters) for both HTML and Html. The lack of >> vowels might've helped with the result, though. >> >> The case of the boundary between two consecutive acronyms being unclear >> should affect developers with regular vision and impaired vision alike >> (i.e. PDOODBC and XSLRR). >> >> From my personal experience as a human with regular vision (not even >> glasses), the variant of treating acronyms as regular words is much >> easier to parse. >> >> Best regards >> Tim Düsterhus > Thanks Tim. Those are the same resources I was going to cite. :-) I'll also add > > >From the APA: https://apastyle.apa.org/style-grammar-guidelines/paper-format/accessibility/typography > > "It is true that presenting text in all caps will slow down all readers, especially those with certain types of visual and/or cognitive impairments." > > (They then go on to recommend using proper casing in the source and CSS styles to capitalize things, so that screen readers ignore it, which seems dumb to me given the other resources cited above.) > > And from the a11y Project: https://www.a11yproject.com/posts/how-to-accessible-heading-structure/#all-caps > > "Text in all capitals is harder to read. The shape of a word disappears, every word becomes a rectangle. Research shows that all caps text is especially difficult for readers with dyslexia. Make life easy for your readers, don't capitalize all the words." > > So the professional consensus among accessibility and publishing organizations is absolutely that ALLCAPS is bad for readability and accessibility. > > I've added some of the links above to the RFC for citation. > > --Larry Garfield > Larry, Tim, Thank you both for your responses. I think it would be a good idea to include these sources in the RFC. I also took the liberty to ask accessibility expert Nicolas Steenhout [1] for his opinion on this topic and he has given me permission to quote his reply: > From a human readability and an accessibility perspective, Camel Case are best when words are concatenated like that. > The rule I’d use here is uppercase the first letter of a word. Then lowercase the others. Unless you are writing an acronym. > So in your example, it should be `PerformHTTPRequest()` > The underscore becomes a problem because if for some reason we’re writing code as an example and it gets underline for any reason, the underline gets lost Hope this helps to inform the RFC further. Smile, Juliette 1: https://www.linkedin.com/in/nicolassteenhout/ --------------090207070606070305020209 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: 8bit
On 5-4-2024 22:55, Larry Garfield wrote:
On Fri, Apr 5, 2024, at 7:15 PM, Tim Düsterhus wrote:
Hi

On 4/5/24 20:01, Juliette Reinders Folmer wrote:
In the "It decreases readability" section you make a sweeping statement
about accessibility, but don't back that up with research. Please back
your statement up as based on my understanding, the opposite is true.
For context: This paragraph was added by Larry. It's my name on the RFC 
of course and I approved of the addition he made. Nevertheless Larry 
might've additional resources to add here.

Case in point: if written in all caps, screenreaders will spell the
characters out - think HTML -. If written in Mixed case, screenreaders
will try to pronounce the word, making acronyms and other abbreviations
very hard to understand for anyone using a screenreader.

This is something which has repeatedly been pointed out, for instance at
conferences regarding conference acronym hashtags, like #DPC.

So, I'd be very interested to see your statement backed up by actual
research and invite you to look into this a little deeper.
Your remark looks at the accessibility from the PoV of a developer with 
impaired eyesight that is dependent on assistive technology. However 
accessibility also affects developers with regular vision. The concerns 
of these two groups might conflict.

W3C's accessibility guidelines point out that:

 > Text in all capital letters is more difficult to read for most 
people, with and without disabilities.

(https://w3c.github.io/low-vision-a11y-tf/requirements.html#capitalization)

Harvards's Accessibility Guidelines agree:

 > Avoid using all caps. Readability is reduced with all caps because 
all words have a uniform rectangular shape, meaning readers can't 
identify words by their shape.

(https://accessibility.huit.harvard.edu/design-readability)

Of course program identifiers are not regular text and indeed more 
similar to hashtags, in that they do not permit the inclusion of 
whitespace to separate words. Underscores would work, but that would 
just add to the inconsistency.

For Hashtags I found several resources pointing out to capitalize each 
word separately. For acronyms most resources pointed out that they 
should be avoided entirely (e.g. 
https://studentlife.mit.edu/das/accessibility/digital-accessibility/socialmedia, 
https://www.nyu.edu/life/information-technology/web-and-digital-publishing/digital-publishing/accessibility/how-to-guides/social-media.html#acronyms) 
and that recommendation is already part of the existing guidelines.

I've tested with my Android phone with the 'performHttpRequest' example 
and both variants where read out equally terrible as 'per-form age tee 
tee pre-quest' (i.e. merging the p with the request). And your example 
of HTML was read out as 'age tee em el' (or rather the German 
pronounciation of the letters) for both HTML and Html. The lack of 
vowels might've helped with the result, though.

The case of the boundary between two consecutive acronyms being unclear 
should affect developers with regular vision and impaired vision alike 
(i.e. PDOODBC and XSLRR).

 From my personal experience as a human with regular vision (not even 
glasses), the variant of treating acronyms as regular words is much 
easier to parse.

Best regards
Tim Düsterhus
Thanks Tim.  Those are the same resources I was going to cite. :-)  I'll also add

>From the APA: https://apastyle.apa.org/style-grammar-guidelines/paper-format/accessibility/typography

"It is true that presenting text in all caps will slow down all readers, especially those with certain types of visual and/or cognitive impairments."

(They then go on to recommend using proper casing in the source and CSS styles to capitalize things, so that screen readers ignore it, which seems dumb to me given the other resources cited above.)

And from the a11y Project: https://www.a11yproject.com/posts/how-to-accessible-heading-structure/#all-caps

"Text in all capitals is harder to read. The shape of a word disappears, every word becomes a rectangle. Research shows that all caps text is especially difficult for readers with dyslexia. Make life easy for your readers, don't capitalize all the words."

So the professional consensus among accessibility and publishing organizations is absolutely that ALLCAPS is bad for readability and accessibility.

I've added some of the links above to the RFC for citation.

--Larry Garfield


Larry, Tim,

Thank you both for your responses. I think it would be a good idea to include these sources in the RFC.

I also took the liberty to ask accessibility expert Nicolas Steenhout [1] for his opinion on this topic and he has given me permission to quote his reply:

> From a human readability and an accessibility perspective, Camel Case are best when words are concatenated like that.
> The rule I’d use here is uppercase the first letter of a word. Then lowercase the others. Unless you are writing an acronym.
> So in your example, it should be `PerformHTTPRequest()`
> The underscore becomes a problem because if for some reason we’re writing code as an example and it gets underline for any reason, the underline gets lost

Hope this helps to inform the RFC further.

Smile,
Juliette


1: https://www.linkedin.com/in/nicolassteenhout/


--------------090207070606070305020209--