Index: /applications/viewer/jmapviewer/src/org/openstreetmap/gui/jmapviewer/JMapViewer.java
===================================================================
--- /applications/viewer/jmapviewer/src/org/openstreetmap/gui/jmapviewer/JMapViewer.java	(revision 31990)
+++ /applications/viewer/jmapviewer/src/org/openstreetmap/gui/jmapviewer/JMapViewer.java	(revision 31991)
@@ -44,4 +44,5 @@
 public class JMapViewer extends JPanel implements TileLoaderListener {
 
+    /** whether debug mode is enabled or not */
     public static boolean debug;
 
@@ -51,5 +52,7 @@
     private static final Point[] move = {new Point(1, 0), new Point(0, 1), new Point(-1, 0), new Point(0, -1)};
 
+    /** Maximum zoom level */
     public static final int MAX_ZOOM = 22;
+    /** Minimum zoom level */
     public static final int MIN_ZOOM = 0;
 
@@ -82,6 +85,11 @@
     protected JButton zoomOutButton;
 
+    /**
+     * Apparence of zoom controls.
+     */
     public enum ZOOM_BUTTON_STYLE {
+        /** Zoom buttons are displayed horizontally (default) */
         HORIZONTAL,
+        /** Zoom buttons are displayed vertically */
         VERTICAL
     }
@@ -229,8 +237,21 @@
     }
 
+    /**
+     * Sets the display position.
+     * @param x X coordinate
+     * @param y Y coordinate
+     * @param zoom zoom level, between {@link #MIN_ZOOM} and {@link #MAX_ZOOM}
+     */
     public void setDisplayPosition(int x, int y, int zoom) {
         setDisplayPosition(new Point(getWidth() / 2, getHeight() / 2), x, y, zoom);
     }
 
+    /**
+     * Sets the display position.
+     * @param mapPoint map point
+     * @param x X coordinate
+     * @param y Y coordinate
+     * @param zoom zoom level, between {@link #MIN_ZOOM} and {@link #MAX_ZOOM}
+     */
     public void setDisplayPosition(Point mapPoint, int x, int y, int zoom) {
         if (zoom > tileController.getTileSource().getMaxZoom() || zoom < MIN_ZOOM)
@@ -865,6 +886,5 @@
      * level can be obtained via {@link #getZoom()}.
      *
-     * @param oldZoom
-     *            the previous zoom level
+     * @param oldZoom the previous zoom level
      */
     protected void zoomChanged(int oldZoom) {
@@ -876,8 +896,16 @@
     }
 
+    /**
+     * Determines whether the tile grid is visible or not.
+     * @return {@code true} if the tile grid is visible, {@code false} otherwise
+     */
     public boolean isTileGridVisible() {
         return tileGridVisible;
     }
 
+    /**
+     * Sets whether the tile grid is visible or not.
+     * @param tileGridVisible {@code true} if the tile grid is visible, {@code false} otherwise
+     */
     public void setTileGridVisible(boolean tileGridVisible) {
         this.tileGridVisible = tileGridVisible;
@@ -885,4 +913,8 @@
     }
 
+    /**
+     * Determines whether {@link MapMarker}s are painted or not.
+     * @return {@code true} if {@link MapMarker}s are painted, {@code false} otherwise
+     */
     public boolean getMapMarkersVisible() {
         return mapMarkersVisible;
@@ -901,4 +933,8 @@
     }
 
+    /**
+     * Sets the list of {@link MapMarker}s.
+     * @param mapMarkerList list of {@link MapMarker}s
+     */
     public void setMapMarkerList(List<MapMarker> mapMarkerList) {
         this.mapMarkerList = mapMarkerList;
@@ -906,8 +942,16 @@
     }
 
+    /**
+     * Returns the list of {@link MapMarker}s.
+     * @return list of {@link MapMarker}s
+     */
     public List<MapMarker> getMapMarkerList() {
         return mapMarkerList;
     }
 
+    /**
+     * Sets the list of {@link MapRectangle}s.
+     * @param mapRectangleList list of {@link MapRectangle}s
+     */
     public void setMapRectangleList(List<MapRectangle> mapRectangleList) {
         this.mapRectangleList = mapRectangleList;
@@ -915,8 +959,16 @@
     }
 
+    /**
+     * Returns the list of {@link MapRectangle}s.
+     * @return list of {@link MapRectangle}s
+     */
     public List<MapRectangle> getMapRectangleList() {
         return mapRectangleList;
     }
 
+    /**
+     * Sets the list of {@link MapPolygon}s.
+     * @param mapPolygonList list of {@link MapPolygon}s
+     */
     public void setMapPolygonList(List<MapPolygon> mapPolygonList) {
         this.mapPolygonList = mapPolygonList;
@@ -924,8 +976,16 @@
     }
 
+    /**
+     * Returns the list of {@link MapPolygon}s.
+     * @return list of {@link MapPolygon}s
+     */
     public List<MapPolygon> getMapPolygonList() {
         return mapPolygonList;
     }
 
+    /**
+     * Add a {@link MapMarker}.
+     * @param marker map marker to add
+     */
     public void addMapMarker(MapMarker marker) {
         mapMarkerList.add(marker);
@@ -933,4 +993,8 @@
     }
 
+    /**
+     * Remove a {@link MapMarker}.
+     * @param marker map marker to remove
+     */
     public void removeMapMarker(MapMarker marker) {
         mapMarkerList.remove(marker);
@@ -938,4 +1002,7 @@
     }
 
+    /**
+     * Remove all {@link MapMarker}s.
+     */
     public void removeAllMapMarkers() {
         mapMarkerList.clear();
@@ -943,4 +1010,8 @@
     }
 
+    /**
+     * Add a {@link MapRectangle}.
+     * @param rectangle map rectangle to add
+     */
     public void addMapRectangle(MapRectangle rectangle) {
         mapRectangleList.add(rectangle);
@@ -948,4 +1019,8 @@
     }
 
+    /**
+     * Remove a {@link MapRectangle}.
+     * @param rectangle map rectangle to remove
+     */
     public void removeMapRectangle(MapRectangle rectangle) {
         mapRectangleList.remove(rectangle);
@@ -953,4 +1028,7 @@
     }
 
+    /**
+     * Remove all {@link MapRectangle}s.
+     */
     public void removeAllMapRectangles() {
         mapRectangleList.clear();
@@ -958,4 +1036,8 @@
     }
 
+    /**
+     * Add a {@link MapPolygon}.
+     * @param polygon map polygon to add
+     */
     public void addMapPolygon(MapPolygon polygon) {
         mapPolygonList.add(polygon);
@@ -963,4 +1045,8 @@
     }
 
+    /**
+     * Remove a {@link MapPolygon}.
+     * @param polygon map polygon to remove
+     */
     public void removeMapPolygon(MapPolygon polygon) {
         mapPolygonList.remove(polygon);
@@ -968,4 +1054,7 @@
     }
 
+    /**
+     * Remove all {@link MapPolygon}s.
+     */
     public void removeAllMapPolygons() {
         mapPolygonList.clear();
@@ -973,4 +1062,8 @@
     }
 
+    /**
+     * Sets whether zoom controls are displayed or not. 
+     * @param visible {@code true} if zoom controls are displayed, {@code false} otherwise
+     */
     public void setZoomContolsVisible(boolean visible) {
         zoomSlider.setVisible(visible);
@@ -979,8 +1072,16 @@
     }
 
+    /**
+     * Determines whether zoom controls are displayed or not. 
+     * @return {@code true} if zoom controls are displayed, {@code false} otherwise
+     */
     public boolean getZoomControlsVisible() {
         return zoomSlider.isVisible();
     }
 
+    /**
+     * Sets the tile source.
+     * @param tileSource tile source
+     */
     public void setTileSource(TileSource tileSource) {
         if (tileSource.getMaxZoom() > MAX_ZOOM)
@@ -1008,4 +1109,8 @@
     }
 
+    /**
+     * Determines whether the {@link MapRectangle}s are painted or not.
+     * @return {@code true} if the {@link MapRectangle}s are painted, {@code false} otherwise
+     */
     public boolean isMapRectanglesVisible() {
         return mapRectanglesVisible;
@@ -1013,5 +1118,5 @@
 
     /**
-     * Enables or disables painting of the {@link MapRectangle}
+     * Enables or disables painting of the {@link MapRectangle}s.
      *
      * @param mapRectanglesVisible {@code true} to enable painting of rectangles
@@ -1024,4 +1129,8 @@
     }
 
+    /**
+     * Determines whether the {@link MapPolygon}s are painted or not.
+     * @return {@code true} if the {@link MapPolygon}s are painted, {@code false} otherwise
+     */
     public boolean isMapPolygonsVisible() {
         return mapPolygonsVisible;
@@ -1029,5 +1138,5 @@
 
     /**
-     * Enables or disables painting of the {@link MapPolygon}
+     * Enables or disables painting of the {@link MapPolygon}s.
      *
      * @param mapPolygonsVisible {@code true} to enable painting of polygons
@@ -1040,8 +1149,16 @@
     }
 
+    /**
+     * Determines whether scroll wrap is enabled or not. 
+     * @return {@code true} if scroll wrap is enabled, {@code false} otherwise
+     */
     public boolean isScrollWrapEnabled() {
         return scrollWrapEnabled;
     }
 
+    /**
+     * Sets whether scroll wrap is enabled or not. 
+     * @param scrollWrapEnabled {@code true} if scroll wrap is enabled, {@code false} otherwise
+     */
     public void setScrollWrapEnabled(boolean scrollWrapEnabled) {
         this.scrollWrapEnabled = scrollWrapEnabled;
@@ -1049,8 +1166,16 @@
     }
 
+    /**
+     * Returns the zoom controls apparence style (horizontal/vertical).
+     * @return {@link ZOOM_BUTTON_STYLE#VERTICAL} or {@link ZOOM_BUTTON_STYLE#HORIZONTAL}
+     */
     public ZOOM_BUTTON_STYLE getZoomButtonStyle() {
         return zoomButtonStyle;
     }
 
+    /**
+     * Sets the zoom controls apparence style (horizontal/vertical).
+     * @param style {@link ZOOM_BUTTON_STYLE#VERTICAL} or {@link ZOOM_BUTTON_STYLE#HORIZONTAL}
+     */
     public void setZoomButtonStyle(ZOOM_BUTTON_STYLE style) {
         zoomButtonStyle = style;
@@ -1059,9 +1184,4 @@
         }
         switch (style) {
-        case HORIZONTAL:
-            zoomSlider.setBounds(10, 10, 30, 150);
-            zoomInButton.setBounds(4, 155, 18, 18);
-            zoomOutButton.setBounds(26, 155, 18, 18);
-            break;
         case VERTICAL:
             zoomSlider.setBounds(10, 27, 30, 150);
@@ -1069,4 +1189,5 @@
             zoomOutButton.setBounds(14, 176, 20, 20);
             break;
+        case HORIZONTAL:
         default:
             zoomSlider.setBounds(10, 10, 30, 150);
@@ -1078,4 +1199,8 @@
     }
 
+    /**
+     * Returns the tile controller.
+     * @return the tile controller
+     */
     public TileController getTileController() {
         return tileController;
@@ -1091,8 +1216,16 @@
     }
 
+    /**
+     * Sets the tile loader.
+     * @param loader tile loader
+     */
     public void setTileLoader(TileLoader loader) {
         tileController.setTileLoader(loader);
     }
 
+    /**
+     * Returns attribution.
+     * @return attribution
+     */
     public AttributionSupport getAttribution() {
         return attribution;
