Index: applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/DownloadWMSVectorImage.java
===================================================================
--- applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/DownloadWMSVectorImage.java	(revision 26822)
+++ applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/DownloadWMSVectorImage.java	(revision 26823)
@@ -36,5 +36,5 @@
                     if (CacheControl.cacheEnabled) {
                         if (wmsLayer.grabThread.getCacheControl().loadCacheIfExist()) {
-                            Main.map.mapView.zoomTo(wmsLayer.getCommuneBBox().toBounds());
+                            Main.map.mapView.zoomTo(wmsLayer.getFirstViewFromCacheBBox().toBounds());
                             //Main.map.mapView.repaint();
                             return;
Index: applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/GeorefImage.java
===================================================================
--- applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/GeorefImage.java	(revision 26822)
+++ applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/GeorefImage.java	(revision 26823)
@@ -29,4 +29,7 @@
     public EastNorth min;
     public EastNorth max;
+    // offset for vector images temporarily shifted (correcting Cadastre artifacts), in pixels
+    public double deltaEast=0;
+    public double deltaNorth=0;
     // bbox of the georeferenced original image (raster only) (inclined if rotated and before cropping)
     // P[0] is bottom,left then next are clockwise.
@@ -107,5 +110,7 @@
             return;
 
-        Point minPt = nc.getPoint(min), maxPt = nc.getPoint(max);
+        // apply offsets defined manually when vector images are translated manually (not saved in cache)
+        Point minPt = nc.getPoint(new EastNorth(min.east()+deltaEast, min.north()+deltaNorth));
+        Point maxPt = nc.getPoint(new EastNorth(max.east()+deltaEast, max.north()+deltaNorth));
 
         if (!g.hitClip(minPt.x, maxPt.y, maxPt.x - minPt.x, minPt.y - maxPt.y))
@@ -171,10 +176,10 @@
         double maxMaskNorth = (georefImage.max.north() < this.max.north()) ? georefImage.max.north() : this.max.north();
         if ((maxMaskNorth - minMaskNorth) > 0 && (maxMaskEast - minMaskEast) > 0) {
-            double pixelPerEast = (max.east() - min.east()) / image.getWidth();
-            double pixelPerNorth = (max.north() - min.north()) / image.getHeight();
-            int minXMaskPixel = (int) ((minMaskEast - min.east()) / pixelPerEast);
-            int minYMaskPixel = (int) ((max.north() - maxMaskNorth) / pixelPerNorth);
-            int widthXMaskPixel = Math.abs((int) ((maxMaskEast - minMaskEast) / pixelPerEast));
-            int heightYMaskPixel = Math.abs((int) ((maxMaskNorth - minMaskNorth) / pixelPerNorth));
+            double pxPerEast = (max.east() - min.east()) / image.getWidth();
+            double pxPerNorth = (max.north() - min.north()) / image.getHeight();
+            int minXMaskPixel = (int) ((minMaskEast - min.east()) / pxPerEast);
+            int minYMaskPixel = (int) ((max.north() - maxMaskNorth) / pxPerNorth);
+            int widthXMaskPixel = Math.abs((int) ((maxMaskEast - minMaskEast) / pxPerEast));
+            int heightYMaskPixel = Math.abs((int) ((maxMaskNorth - minMaskNorth) / pxPerNorth));
             Graphics g = image.getGraphics();
             for (int x = minXMaskPixel; x < minXMaskPixel + widthXMaskPixel; x++)
@@ -279,5 +284,5 @@
         }
     }
-
+    
     /**
      * Change this image scale by moving the min,max coordinates around an anchor
@@ -364,3 +369,12 @@
     }
 
+    /**
+     * Add a temporary translation (dx, dy) to this image (for vector images only)
+     * @param dx delta added to X image coordinate
+     * @param dy delta added to Y image coordinate
+     */
+    public void tempShear(double dx, double dy) {
+        this.deltaEast+=dx;
+        this.deltaNorth+=dy;
+    }
 }
Index: applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/WMSAdjustAction.java
===================================================================
--- applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/WMSAdjustAction.java	(revision 26822)
+++ applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/WMSAdjustAction.java	(revision 26823)
@@ -12,5 +12,4 @@
 import java.awt.event.MouseListener;
 import java.awt.event.MouseMotionListener;
-import java.util.ArrayList;
 
 import javax.swing.JOptionPane;
@@ -22,5 +21,4 @@
 import org.openstreetmap.josm.data.coor.EastNorth;
 import org.openstreetmap.josm.tools.ImageProvider;
-import org.openstreetmap.josm.gui.layer.Layer;
 
 public class WMSAdjustAction extends MapMode implements
@@ -28,6 +26,5 @@
 
     private static final long serialVersionUID = 1L;
-    private ArrayList<WMSLayer> modifiedLayers = new ArrayList<WMSLayer>();
-    WMSLayer selectedLayer;
+    private WMSLayer modifiedLayer = null;
     private boolean rasterMoved;
     private EastNorth prevEastNorth;
@@ -38,5 +35,5 @@
     public WMSAdjustAction(MapFrame mapFrame) {
         super(tr("Adjust WMS"), "adjustxywms",
-                        tr("Adjust the position of the WMS layer (raster images only)"), mapFrame,
+                        tr("Adjust the position of the WMS layer (saved for raster images only)"), mapFrame,
                         ImageProvider.getCursor("normal", "move"));
     }
@@ -44,28 +41,14 @@
     @Override public void enterMode() {
         if (Main.map != null) {
-            selectedLayer = null;
-            WMSLayer possibleLayer = null;
-            int cRasterLayers = 0;
-            for (Layer l : Main.map.mapView.getAllLayers()) {
-                if (l instanceof WMSLayer && ((WMSLayer)l).isRaster()) {
-                    possibleLayer = (WMSLayer)l;
-                    cRasterLayers++;
-                }
-            }
-            Layer activeLayer = Main.map.mapView.getActiveLayer();
-            if (activeLayer instanceof WMSLayer && ((WMSLayer)activeLayer).isRaster()) {
-                selectedLayer = (WMSLayer)activeLayer;
-            } else if (cRasterLayers == 1) {
-                selectedLayer = possibleLayer;
-            }
-            if (selectedLayer != null) {
+            if (Main.map.mapView.getActiveLayer() instanceof WMSLayer) {
+                modifiedLayer = (WMSLayer)Main.map.mapView.getActiveLayer();
                 super.enterMode();
                 Main.map.mapView.addMouseListener(this);
                 Main.map.mapView.addMouseMotionListener(this);
                 rasterMoved = false;
-                selectedLayer.adjustModeEnabled = true;
+                modifiedLayer.adjustModeEnabled = true;
             } else {
-                JOptionPane.showMessageDialog(Main.parent,tr("This mode works only if active layer is\n"
-                        +"a cadastre \"plan image\" (raster image)"));
+//                JOptionPane.showMessageDialog(Main.parent,tr("This mode works only if active layer is\n"
+//                        +"a cadastre layer"));
                 exitMode();
                 Main.map.selectMapMode((MapMode)Main.map.getDefaultButtonAction());
@@ -78,5 +61,5 @@
         Main.map.mapView.removeMouseListener(this);
         Main.map.mapView.removeMouseMotionListener(this);
-        if (rasterMoved && CacheControl.cacheEnabled) {
+        if (rasterMoved && CacheControl.cacheEnabled && modifiedLayer.isRaster()) {
             int reply = JOptionPane.showConfirmDialog(null,
                     "Save the changes in cache ?",
@@ -87,8 +70,8 @@
             }
         }
-        modifiedLayers.clear();
-        if (selectedLayer != null) {
-            selectedLayer.adjustModeEnabled = false;
-            selectedLayer = null;
+        rasterMoved = false;
+        if (modifiedLayer != null) {
+            modifiedLayer.adjustModeEnabled = false;
+            modifiedLayer = null;
         }
     }
@@ -101,7 +84,7 @@
         // boolean alt = (e.getModifiers() & ActionEvent.ALT_MASK) != 0;
         boolean shift = (e.getModifiers() & ActionEvent.SHIFT_MASK) != 0;
-        if (shift && !ctrl)
+        if (shift && !ctrl && modifiedLayer.isRaster())
             mode = Mode.moveZ;
-        else if (shift && ctrl)
+        else if (shift && ctrl && modifiedLayer.isRaster())
             mode = Mode.rotate;
         else
@@ -124,6 +107,4 @@
             prevEastNorth = newEastNorth;
         }
-        if (!modifiedLayers.contains(selectedLayer))
-            modifiedLayers.add(selectedLayer);
         Main.map.mapView.repaint();
     }
@@ -141,31 +122,31 @@
 
     private void displace(EastNorth start, EastNorth end) {
-        selectedLayer.displace(end.east()-start.east(), end.north()-start.north());
+        modifiedLayer.displace(end.east()-start.east(), end.north()-start.north());
     }
 
     private void resize(EastNorth newEastNorth) {
-        EastNorth center = selectedLayer.getRasterCenter();
+        EastNorth center = modifiedLayer.getRasterCenter();
         double dPrev = prevEastNorth.distance(center.east(), center.north());
         double dNew = newEastNorth.distance(center.east(), center.north());
-        selectedLayer.resize(center, dNew/dPrev);
+        modifiedLayer.resize(center, dNew/dPrev);
     }
 
     private void rotate(EastNorth start, EastNorth end) {
-        EastNorth pivot = selectedLayer.getRasterCenter();
+        EastNorth pivot = modifiedLayer.getRasterCenter();
         double startAngle = Math.atan2(start.east()-pivot.east(), start.north()-pivot.north());
         double endAngle = Math.atan2(end.east()-pivot.east(), end.north()-pivot.north());
         double rotationAngle = endAngle - startAngle;
-        selectedLayer.rotate(pivot, rotationAngle);
+        modifiedLayer.rotate(pivot, rotationAngle);
     }
 
     private void rotateFrameOnly(EastNorth start, EastNorth end) {
         if (start != null && end != null) {
-            EastNorth pivot = selectedLayer.getRasterCenter();
+            EastNorth pivot = modifiedLayer.getRasterCenter();
             double startAngle = Math.atan2(start.east()-pivot.east(), start.north()-pivot.north());
             double endAngle = Math.atan2(end.east()-pivot.east(), end.north()-pivot.north());
             double rotationAngle = endAngle - startAngle;
-            if (selectedLayer.getImage(0).orgCroppedRaster != null) {
+            if (modifiedLayer.getImage(0).orgCroppedRaster != null) {
                 for (int i=0; i<4; i++) {
-                    croppedRaster[i] = selectedLayer.getImage(0).orgCroppedRaster[i].rotate(pivot, rotationAngle);
+                    croppedRaster[i] = modifiedLayer.getImage(0).orgCroppedRaster[i].rotate(pivot, rotationAngle);
                 }
                 croppedRaster[4] = croppedRaster[0];
@@ -197,7 +178,5 @@
 
     private void saveModifiedLayers() {
-        for (WMSLayer wmsLayer : modifiedLayers) {
-            wmsLayer.grabThread.saveNewCache();
-        }
+            modifiedLayer.grabThread.saveNewCache();
     }
 }
Index: applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/WMSLayer.java
===================================================================
--- applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/WMSLayer.java	(revision 26822)
+++ applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/WMSLayer.java	(revision 26823)
@@ -11,4 +11,5 @@
 import java.awt.RenderingHints;
 import java.awt.Toolkit;
+import java.awt.event.ActionEvent;
 import java.awt.image.BufferedImage;
 import java.awt.image.ImageObserver;
@@ -29,4 +30,5 @@
 
 import org.openstreetmap.josm.Main;
+import org.openstreetmap.josm.actions.JosmAction;
 import org.openstreetmap.josm.data.Bounds;
 import org.openstreetmap.josm.data.coor.EastNorth;
@@ -87,4 +89,22 @@
     private Action cancelGrab;
 
+    @SuppressWarnings("serial")
+    class ResetOffsetActionMenu extends JosmAction {
+        private WMSLayer wmsLayer;
+        public ResetOffsetActionMenu(WMSLayer wmsLayer) {
+            super(tr("Reset offset"), null, tr("Reset offset (only vector images)"), null, false);
+            this.wmsLayer = wmsLayer;
+        }
+        @Override
+        public void actionPerformed(ActionEvent arg0) {
+            for (GeorefImage img:wmsLayer.images) {
+                img.deltaEast = 0;
+                img.deltaNorth = 0;
+            }
+            Main.map.mapView.repaint();
+        }
+        
+    }
+    
     public boolean adjustModeEnabled;
 
@@ -213,12 +233,4 @@
                 dividedBbox.add(new EastNorthBound(mid, new EastNorth(mid.east()+c, mid.north()+c)));
             }
-//            // simple algorithm to grab all squares
-//            minEast = minEast - minEast % cSquare;
-//            minNorth = minNorth - minNorth % cSquare;
-//            for (int xEast = (int)minEast; xEast < lambertMax.east(); xEast+=cSquare)
-//                for (int xNorth = (int)minNorth; xNorth < lambertMax.north(); xNorth+=cSquare) {
-//                    dividedBbox.add(new EastNorthBound(new EastNorth(xEast, xNorth),
-//                                new EastNorth(xEast + cSquare, xNorth + cSquare)));
-//            }
         }
     }
@@ -297,4 +309,6 @@
         cancelGrab = new MenuActionCancelGrab(this);
         cancelGrab.setEnabled(!isRaster && grabThread.getImagesToGrabSize() > 0);
+        Action resetOffset = new ResetOffsetActionMenu(this);
+        resetOffset.setEnabled(!isRaster && images.size() > 0 && (images.get(0).deltaEast!=0.0 || images.get(0).deltaNorth!=0.0));
         return new Action[] {
                 LayerListDialog.getInstance().createShowHideLayerAction(),
@@ -303,4 +317,5 @@
                 saveAsPng,
                 cancelGrab,
+                resetOffset, 
                 new LayerListPopup.InfoAction(this),
 
@@ -566,4 +581,22 @@
         return communeBBox;
     }
+    
+    public EastNorthBound getFirstViewFromCacheBBox() {
+        if (isRaster) {
+            return communeBBox;
+        }
+        double min_x = Double.MAX_VALUE;
+        double max_x = Double.MIN_VALUE;
+        double min_y = Double.MAX_VALUE;
+        double max_y = Double.MIN_VALUE;
+        for (GeorefImage image:images){
+            min_x = image.min.east() < min_x ? image.min.east() : min_x;
+            max_x = image.max.east() > max_x ? image.max.east() : max_x; 
+            min_y = image.min.north() < min_y ? image.min.north() : min_y;
+            max_y = image.max.north() > max_y ? image.max.north() : max_y; 
+        }
+        EastNorthBound maxGrabbedBBox = new EastNorthBound(new EastNorth(min_x, min_y), new EastNorth(max_x, max_y));
+        return maxGrabbedBBox;
+    }
 
     public void setCommuneBBox(EastNorthBound entireCommune) {
@@ -588,7 +621,12 @@
 
     public void displace(double dx, double dy) {
-        this.rasterMin = new EastNorth(rasterMin.east() + dx, rasterMin.north() + dy);
-        this.rasterMax = new EastNorth(rasterMax.east() + dx, rasterMax.north() + dy);
-        images.get(0).shear(dx, dy);
+        if (isRaster) {
+            this.rasterMin = new EastNorth(rasterMin.east() + dx, rasterMin.north() + dy);
+            this.rasterMax = new EastNorth(rasterMax.east() + dx, rasterMax.north() + dy);
+            images.get(0).shear(dx, dy);
+        } else {
+            for (GeorefImage image:images)
+                image.tempShear(dx, dy);
+        }
     }
 
