The Java Tutorials' Weblog

pageicon Tuesday Jun 05, 2007

Knowing the Audience

So my latest assignment is to update the custom painting section of the Swing tutorial. The version that's currently online is really a combination of two separate topics: custom painting, and guidelines for creating custom components. A while back I had posted a proposed outline to this blog about how to update that lesson. It sparked some discussion between myself and the Swing engineering team, resulting in a decision to break the material up even more into two separate lessons.

Now, covering a topic like custom painting involves first describing painting in AWT, and then talking about what's changed in Swing. And as you might imagine, there are many excellent articles out there that already do this. The most relevant is Amy Fowler's discussion of painting in AWT and Swing, available at http://java.sun.com/products/jfc/tsc/articles/painting/

As a technical writer, a large part of my job here at Sun is knowing the audience and adjusting my writing style to suit. We've found that the tutorial audience responds very well to complete examples... code that you can see in its entirety, with narrative that gives the reader a specific, guided walk-through of the concepts. This approach is very different from say, writing a whitepaper for JavaOne, or making a clarification to the platform API spec. So how do I go about documenting a subject that has already been covered elsewhere? For me there are two basic steps: 1) learn the facts (AWT and Swing painting subsystems in this case) and 2) create a new presentation from scratch... one that is fresh and not just a copy of something else already out there.

In this case I thought that since custom painting is a "visual" activity, it would make sense to start with something basic (like a Frame or JFrame), then add a drawing surface (Canvas or JPanel etc.), then add some new piece of functionality in each subsequent section. This allows the reader to learn in stages as the application evolves. By the time you finish the lesson, you'll have walked through the concepts that we consider important (by "we" I mean myself AND the Swing engineering team), and hopefully when you're done, you'll think "Wow, that was easy!"

The lesson is currently up for engineering review, but will be posted to the tutorial in early July. Make sure to come back then and check it out!

-- Scott Hommel

Comments:

  1. please note java 6,7 specifics
  2. please show good technique by seperating problem domain from presentaion.

Posted by Paul Campbell on June 06, 2007 at 10:22 AM PDT #

Thanks for the work you are doing on the Java tutorials. I have very often found them useful. The process you have for teaching: create something simple and then go ahead one step at a time introducing new concepts is a very effective process. Sometimes, good (and engaging) screencasts can augment the material very well. But they are extremely time consuming to produce. I think the biggest problem that people who are new to Java have is the vast sea of information and how to make sense of it. Everything seems very overwhleming. Add to it, the fact that there are usually multiple ways of doing the same thing adds a bit to that feeling. A tutorial that can serve as a roadmap to this vast sea of information will be very very useful. Starting by explaining the fundamental concepts and helping people get their hands dirty. Giving them some practice, and then offering signs and directions to all the other possibilities. This is a bit at a tangent, but being able to discuss the concepts that people are learning with other learners and well as more experienced folks is also very useful in the learning process. Offcourse I am not sure how a tutorial can handle this, and we already have message boards and IRC channels. But here's just a thought. If tutorial pages had embedded chat applets where the learner can immediately discuss concepts with other people who are also veiwing that page, might improve the whole learning experience and result in better learning. Just a thought... Thanks again for the excellent work you guys are doing with the Java tutorial. -- Regards Parag

Posted by Parag Shah on June 06, 2007 at 10:22 PM PDT #

Oops sorry, my entire post appeared as one paragraph. I guess I should have used html line breaks instead of hitting the enter key for a newline.

--
Regards
Parag

Posted by Parag Shah on June 06, 2007 at 10:24 PM PDT #

Parag, your chat suggestion has become the topic of the next blog entry :)

Posted by Scott Hommel on June 08, 2007 at 11:28 AM PDT #

Post a Comment:
  • HTML Syntax: NOT allowed

« December 2009
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
  
       
Today

Feeds

Search this blog

Links

Weblog menu

Today's referrers

Today's Page Hits: 620