After much weeping and nashing of teeth I have set up an environment, thanks to following Jeff Potts' excellent tutorial and those in the Alfresco Docs, specifically this:
Using the all-in-one archetype (with everything changed to 4.1.7.3 Enterprise) I'm able to "sort of" debug a java-backed web script by placing a break point in the java code and stepping through it. I say "sort of" because although I have the code for the new java class, I don't have it for everything else, and so I can't see the code for the extended class. Is there a way to get the source code into my development environment too?
Yes you can associate source code to each of the jars which holds that extended class. You will be able to see source in alfresco SDK itself you just need to map it with your original jar through eclipse's "attache source" tool.
We might be talking about different things. Just to be clear, I'm talking about the tutorial I linked in the first post, not the older Alfresco SDK. I puttered around with that for a little while until I found the newer Maven Alfresco SDK, which I'm trying to set up now. In the latter, I can find .jar files in locations like (using the linked tutorial as an example) locations like \javadir\alfresco\target\war\work\org.alfresco.enterprise\alfresco\WEB-INF\lib, but when I right-click on these and select properties the option to add code/javadocs is not there.
I can also find the big list of Maven dependencies, but I'm not sure that adding the code to these is advised. Specifically, the instructions here:
which I had used to try out the Alfresco SDK warned against adding the source code for dependencies. I don't know enough about Eclipse and its inner workings to say that this advice applies to the Maven Alfresco SDK as well, so I'm still asking here. I can say, though, that code and javadocs can be added to these Maven Dependencies using the method described in the above link, although I am wary of doing so.