Index: trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/BoxTextElement.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/BoxTextElement.java	(revision 12302)
+++ trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/BoxTextElement.java	(revision 12303)
@@ -25,10 +25,42 @@
      * MapCSS text-anchor-horizontal
      */
-    public enum HorizontalTextAlignment { LEFT, CENTER, RIGHT }
+    public enum HorizontalTextAlignment {
+        /**
+         * Align to the left
+         */
+        LEFT,
+        /**
+         * Align in the center
+         */
+        CENTER,
+        /**
+         * Align to the right
+         */
+        RIGHT }
 
     /**
      * MapCSS text-anchor-vertical
      */
-    public enum VerticalTextAlignment { ABOVE, TOP, CENTER, BOTTOM, BELOW }
+    public enum VerticalTextAlignment {
+        /**
+         * Render above the box
+         */
+        ABOVE,
+        /**
+         * Align to the top of the box
+         */
+        TOP,
+        /**
+         * Render at the center of the box
+         */
+        CENTER,
+        /**
+         * Align to the bottom of the box
+         */
+        BOTTOM,
+        /**
+         * Render below the box
+         */
+        BELOW }
 
     /**
@@ -52,4 +84,9 @@
         private final boolean temporary;
 
+        /**
+         * Create a new box provider result
+         * @param box The box
+         * @param temporary The temporary flag, will be returned by {@link #isTemporary()}
+         */
         public BoxProviderResult(Rectangle box, boolean temporary) {
             this.box = box;
Index: trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/LineElement.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/LineElement.java	(revision 12302)
+++ trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/LineElement.java	(revision 12303)
@@ -31,20 +31,62 @@
     public static final LineElement UNTAGGED_WAY = createSimpleLineStyle(null, false);
 
+    /**
+     * The stroke used to paint the line
+     */
     private final BasicStroke line;
+    /**
+     * The color of the line. Should not be accessed directly
+     */
     public Color color;
+
+    /**
+     * The stroke used to paint the gaps between the dashes
+     */
+    private final BasicStroke dashesLine;
+    /**
+     * The secondary color of the line that is used for the gaps in dashed lines. Should not be accessed directly
+     */
     public Color dashesBackground;
+    /**
+     * The dash offset. Should not be accessed directly
+     */
     public float offset;
-    public float realWidth; // the real width of this line in meter
+    /**
+     * the real width of this line in meter. Should not be accessed directly
+     */
+    public float realWidth;
+    /**
+     * A flag indicating if the direction arrwos should be painted. Should not be accessed directly
+     */
     public boolean wayDirectionArrows;
 
-    private final BasicStroke dashesLine;
-
+    /**
+     * The type of this line
+     */
     public enum LineType {
+        /**
+         * A normal line
+         */
         NORMAL("", 3f),
+        /**
+         * A casing (line behind normal line, extended to the right/left)
+         */
         CASING("casing-", 2f),
+        /**
+         * A casing, but only to the left
+         */
         LEFT_CASING("left-casing-", 2.1f),
+        /**
+         * A casing, but only to the right
+         */
         RIGHT_CASING("right-casing-", 2.1f);
 
+        /**
+         * The MapCSS line prefix used
+         */
         public final String prefix;
+        /**
+         * The major z index to use during painting
+         */
         public final float defaultMajorZIndex;
 
@@ -138,4 +180,10 @@
     }
 
+    /**
+     * Converts a linejoin of a {@link BasicStroke} to a MapCSS string
+     * @param linejoin The linejoin
+     * @return The MapCSS string or <code>null</code> on error.
+     * @see BasicStroke#getLineJoin()
+     */
     public String linejoinToString(int linejoin) {
         switch (linejoin) {
@@ -147,4 +195,10 @@
     }
 
+    /**
+     * Converts a linecap of a {@link BasicStroke} to a MapCSS string
+     * @param linecap The linecap
+     * @return The MapCSS string or <code>null</code> on error.
+     * @see BasicStroke#getEndCap()
+     */
     public String linecapToString(int linecap) {
         switch (linecap) {
@@ -209,8 +263,18 @@
     }
 
+    /**
+     * Create a line element from the given MapCSS environment
+     * @param env The environment
+     * @return The line element describing the line that should be painted, or <code>null</code> if none should be painted.
+     */
     public static LineElement createLine(Environment env) {
         return createImpl(env, LineType.NORMAL);
     }
 
+    /**
+     * Create a line element for the left casing from the given MapCSS environment
+     * @param env The environment
+     * @return The line element describing the line that should be painted, or <code>null</code> if none should be painted.
+     */
     public static LineElement createLeftCasing(Environment env) {
         LineElement leftCasing = createImpl(env, LineType.LEFT_CASING);
@@ -221,4 +285,9 @@
     }
 
+    /**
+     * Create a line element for the right casing from the given MapCSS environment
+     * @param env The environment
+     * @return The line element describing the line that should be painted, or <code>null</code> if none should be painted.
+     */
     public static LineElement createRightCasing(Environment env) {
         LineElement rightCasing = createImpl(env, LineType.RIGHT_CASING);
@@ -229,4 +298,9 @@
     }
 
+    /**
+     * Create a line element for the casing from the given MapCSS environment
+     * @param env The environment
+     * @return The line element describing the line that should be painted, or <code>null</code> if none should be painted.
+     */
     public static LineElement createCasing(Environment env) {
         LineElement casing = createImpl(env, LineType.CASING);
Index: trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/MapImage.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/MapImage.java	(revision 12302)
+++ trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/MapImage.java	(revision 12303)
@@ -33,20 +33,60 @@
     private BufferedImage img;
 
+    /**
+     * The alpha (opacity) value of the image. It is multiplied to the image alpha channel.
+     * Range: 0...255
+     */
     public int alpha = 255;
+    /**
+     * The name of the image that should be displayed. It is given to the {@link ImageProvider}
+     */
     public String name;
+    /**
+     * The StyleSource that registered the image
+     */
     public StyleSource source;
+    /**
+     * A flag indicating that the image should automatically be scaled to the right size.
+     */
     public boolean autoRescale;
+    /**
+     * The width of the image, as set by MapCSS
+     */
     public int width = -1;
+    /**
+     * The height of the image, as set by MapCSS
+     */
     public int height = -1;
+    /**
+     * The x offset of the anchor of this image
+     */
     public int offsetX;
+    /**
+     * The y offset of the anchor of this image
+     */
     public int offsetY;
 
     private boolean temporary;
+
+    /**
+     * A cache that holds a disabled (gray) version of this image
+     */
     private BufferedImage disabledImgCache;
 
+    /**
+     * Creates a new {@link MapImage}
+     * @param name The image name
+     * @param source The style source that requests this image
+     */
     public MapImage(String name, StyleSource source) {
         this(name, source, true);
     }
 
+    /**
+     * Creates a new {@link MapImage}
+     * @param name The image name
+     * @param source The style source that requests this image
+     * @param autoRescale A flag indicating to automatically adjust the width/height of the image
+     */
     public MapImage(String name, StyleSource source, boolean autoRescale) {
         this.name = name;
@@ -125,12 +165,24 @@
     }
 
+    /**
+     * Gets the image width
+     * @return The real image width
+     */
     public int getWidth() {
         return getImage().getWidth(null);
     }
 
+    /**
+     * Gets the image height
+     * @return The real image height
+     */
     public int getHeight() {
         return getImage().getHeight(null);
     }
 
+    /**
+     * Gets the alpha value the image should be multiplied with
+     * @return The value in range 0..1
+     */
     public float getAlphaFloat() {
         return Utils.colorInt2float(alpha);
@@ -187,4 +239,8 @@
     }
 
+    /**
+     * Gets a box provider that provides a box that covers the size of this image
+     * @return The box provider
+     */
     public BoxProvider getBoxProvider() {
         return new MapImageBoxProvider();
Index: trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/NodeElement.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/NodeElement.java	(revision 12302)
+++ trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/NodeElement.java	(revision 12303)
@@ -48,5 +48,11 @@
     private static final String[] ICON_KEYS = {ICON_IMAGE, ICON_WIDTH, ICON_HEIGHT, ICON_OPACITY, ICON_OFFSET_X, ICON_OFFSET_Y};
 
+    /**
+     * The style used for simple nodes
+     */
     public static final NodeElement SIMPLE_NODE_ELEMSTYLE;
+    /**
+     * A box provider that provides the size of a simple node
+     */
     public static final BoxProvider SIMPLE_NODE_ELEMSTYLE_BOXPROVIDER;
     static {
@@ -58,5 +64,12 @@
     }
 
+    /**
+     * The default styles that are used for nodes.
+     * @see #SIMPLE_NODE_ELEMSTYLE
+     */
     public static final StyleElementList DEFAULT_NODE_STYLELIST = new StyleElementList(NodeElement.SIMPLE_NODE_ELEMSTYLE);
+    /**
+     * The default styles that are used for nodes with text.
+     */
     public static final StyleElementList DEFAULT_NODE_STYLELIST_TEXT = new StyleElementList(NodeElement.SIMPLE_NODE_ELEMSTYLE,
             BoxTextElement.SIMPLE_NODE_TEXT_ELEMSTYLE);
Index: trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/RepeatImageElement.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/RepeatImageElement.java	(revision 12302)
+++ trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/RepeatImageElement.java	(revision 12303)
@@ -22,6 +22,15 @@
      */
     public enum LineImageAlignment {
+        /**
+         * Align it to the top side of the line
+         */
         TOP(.5),
+        /**
+         * Align it to the center of the line
+         */
         CENTER(0),
+        /**
+         * Align it to the bottom of the line
+         */
         BOTTOM(-.5);
 
@@ -41,8 +50,23 @@
     }
 
+    /**
+     * The image to draw on the line repeatedly
+     */
     public MapImage pattern;
+    /**
+     * The offset to the side of the way
+     */
     public float offset;
+    /**
+     * The space between the images
+     */
     public float spacing;
+    /**
+     * The offset of the first image along the way
+     */
     public float phase;
+    /**
+     * The alignment of the image
+     */
     public LineImageAlignment align;
 
@@ -50,4 +74,13 @@
             null, null};
 
+    /**
+     * Create a new image element
+     * @param c The cascade
+     * @param pattern The image to draw on the line repeatedly
+     * @param offset The offset to the side of the way
+     * @param spacing The space between the images
+     * @param phase The offset of the first image along the way
+     * @param align The alignment of the image
+     */
     public RepeatImageElement(Cascade c, MapImage pattern, float offset, float spacing, float phase, LineImageAlignment align) {
         super(c, 2.9f);
@@ -61,4 +94,9 @@
     }
 
+    /**
+     * Create a RepeatImageElement from the given environment
+     * @param env The environment
+     * @return The image style element or <code>null</code> if none should be painted
+     */
     public static RepeatImageElement create(Environment env) {
         MapImage pattern = NodeElement.createIcon(env, REPEAT_IMAGE_KEYS);
Index: trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/StyleElement.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/StyleElement.java	(revision 12302)
+++ trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/StyleElement.java	(revision 12303)
@@ -18,5 +18,5 @@
 /**
  * Class that defines how objects ({@link OsmPrimitive}) should be drawn on the map.
- * 
+ *
  * Several subclasses of this abstract class implement different drawing features,
  * like icons for a node or area fill. This class and all its subclasses are immutable
@@ -33,9 +33,24 @@
     protected static final int ICON_OFFSET_Y_IDX = 5;
 
+    /**
+     * The major z index of this style element
+     */
     public float majorZIndex;
+    /**
+     * The z index as set by the user
+     */
     public float zIndex;
+    /**
+     * The object z index
+     */
     public float objectZIndex;
-    public boolean isModifier;  // false, if style can serve as main style for the
-    // primitive; true, if it is a highlight or modifier
+    /**
+     * false, if style can serve as main style for the primitive;
+     * true, if it is a highlight or modifier
+     */
+    public boolean isModifier;
+    /**
+     * A flag indicating that the selection color handling should be done automatically
+     */
     public boolean defaultSelectedHandling;
 
@@ -77,4 +92,8 @@
             boolean selected, boolean outermember, boolean member);
 
+    /**
+     * Check if this is a style that makes the line visible to the user
+     * @return <code>true</code> for line styles
+     */
     public boolean isProperLineStyle() {
         return false;
Index: trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/TextLabel.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/TextLabel.java	(revision 12302)
+++ trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/TextLabel.java	(revision 12303)
@@ -24,4 +24,7 @@
  */
 public class TextLabel implements StyleKeys {
+    /**
+     * The default strategy to use when determining the label of a element.
+     */
     public static final LabelCompositionStrategy AUTO_LABEL_COMPOSITION_STRATEGY = new DeriveLabelFromNameTagsCompositionStrategy();
 
