Hi Ted,

This continues a discussion we were having last year about refining  
the PHP clippings set (which alas my own work, wife and child — and my  
need to decode your excellent XSLT — inhibited progress on...)

I use the PHP clippings all the time (they're a god send when it comes  
to remembering function signatures: "Which one is it this time:   
needle-haystack or haystack-needle? Who knows? God bless PHP!" ;-) My  
thoughts on them, inter-spaced with yours from today, are these:

1) There's the outstanding issue about the spacing. I (still) haven't  
had the chance to work through your existing XSLT but allowing a more  
compact template should be possible (yes?)

On 19 Jun 2009, at 13:46, G. T. Stresen-Reuter wrote:

> For example, the PHP clipping set includes a fairly complete class
> definition clipping but honestly, even though I created it, I've only
> used it once or twice (in the 4 or 5 years it's been in there).

> Why is that? Is it possible that although it includes the kitchen sink
> that it's simply too much for most of my needs?


I found this too big. Rather I've created an empty class outline and  
then clippings for functions (allowing for PPP status) -- these allow  
me to build up a class as I go.

I also have doc-block clippings.

> I tend to agree (although I'm not sure I understand exactly what he's
> saying). In PHP there is a fairly robust way to set up the Singleton
> pattern (that keeps people from circumventing the limitation on
> running a single instance) but I've only had to write a singleton
> function 3 or 4 times in the past coulpe of years.

> I think the goal of clippings (and I may be wrong about this), is to
> minimize frequently REPEATED typing tasks.
>
> A new version of the PHP clipping set will include sq and dq (single
> quote and double quote): insert a pair of quotes and drop the
> insertion point in between them. This is something I do ALL THE TIME.

I have a singleton clipping but I tend to agree with you that they're  
best for REPEATED typing tasks. (The Singleton pattern is perhaps an  
exception in that there is, until PHP 5.3 at least, one stereotyped  
way of doing it; I'm not sure this holds true for other patterns...)

> Note that the existing PHP clipping set includes clippings for all the
> control structures (that I'm aware of). Yes, the clippings could be
> more refined, but I really need to know what people need in order to
> be able to refine them so please don't be shy...

I've used these as a basis for refinement. The trouble is I don't  
think they can really be automatically generated to be perfect — a  
#SELECTION#, and an #INSERTION# there can make all the difference –   
and what perfect is is probably open to debate...

I am happy to contribute what I've got as examples... one thing I did  
was to break the if-elseif-else group up so you can build the  
branching structure as you go. (I don't think I've got any of them  
perfect yet -- mainly because it's only in the heat of battle that you  
think "it would be good if it did this" but they might help...)

> I recently posted a jquery clipping set to this list for someone who
> requested it. As usual, I never heard back from that person, not even
> a "hey thanks! That was nice of you to invest the time in creating it
> and not even charging me for it even though you have a job, a wife, a
> house and two kids to pay for..."

I'm grateful. Thank you.

Regards,
Carlton
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "BBEdit Talk" group.
To post to this group, send email to bbedit@googlegroups.com
To unsubscribe from this group, send email to
bbedit+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/bbedit?hl=en
If you have a specific feature request or would like to report a suspected (or 
confirmed) problem with the software, please email to "supp...@barebones.com" 
rather than posting to the group.
-~----------~----~----~----~------~----~------~--~---

Reply via email to