Index: plugins/buildings_tools/src/org/openstreetmap/josm/plugins/buildings_tools/ConfigKey.java
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
diff --git a/plugins/buildings_tools/src/org/openstreetmap/josm/plugins/buildings_tools/ConfigKey.java b/plugins/buildings_tools/src/org/openstreetmap/josm/plugins/buildings_tools/ConfigKey.java
new file mode 100644
--- /dev/null	(date 1615494172861)
+++ b/plugins/buildings_tools/src/org/openstreetmap/josm/plugins/buildings_tools/ConfigKey.java	(date 1615494172861)
@@ -0,0 +1,20 @@
+package org.openstreetmap.josm.plugins.buildings_tools;
+
+enum ConfigKey {
+    TAGS("buildings_tools.tags"),
+    SHAPE("buildings_tools.shape"),
+    BBMODE("buildings_tools.bbmode"),
+    SOFTCURSOR("buildings_tools.softcursor"),
+    NOCLICKDRAG("buildings_tools.noclickdrag"),
+    ADDRNODE("buildings_tools.addrNode");
+
+    private final String key;
+
+    ConfigKey(String key) {
+        this.key = key;
+    }
+
+    public String getKey() {
+        return key;
+    }
+}
\ No newline at end of file
Index: plugins/buildings_tools/src/org/openstreetmap/josm/plugins/buildings_tools/DrawBuildingAction.java
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
diff --git a/plugins/buildings_tools/src/org/openstreetmap/josm/plugins/buildings_tools/DrawBuildingAction.java b/plugins/buildings_tools/src/org/openstreetmap/josm/plugins/buildings_tools/DrawBuildingAction.java
--- a/plugins/buildings_tools/src/org/openstreetmap/josm/plugins/buildings_tools/DrawBuildingAction.java	(revision 35719)
+++ b/plugins/buildings_tools/src/org/openstreetmap/josm/plugins/buildings_tools/DrawBuildingAction.java	(date 1615493296089)
@@ -39,6 +39,8 @@
 import org.openstreetmap.josm.gui.layer.OsmDataLayer;
 import org.openstreetmap.josm.gui.util.KeyPressReleaseListener;
 import org.openstreetmap.josm.gui.util.ModifierExListener;
+import org.openstreetmap.josm.spi.preferences.Config;
+import org.openstreetmap.josm.spi.preferences.PreferenceChangedListener;
 import org.openstreetmap.josm.tools.Geometry;
 import org.openstreetmap.josm.tools.ImageProvider;
 import org.openstreetmap.josm.tools.Logging;
@@ -50,7 +52,6 @@
         None, Drawing, DrawingWidth, DrawingAngFix
     }
 
-    private final Cursor cursorCrosshair;
     private final Cursor cursorJoinNode;
     private final Cursor cursorJoinWay;
     private Cursor currCursor;
@@ -65,17 +66,21 @@
 
     final transient Building building = new Building();
 
+    private final PreferenceChangedListener shapeChangeListener = event -> updCursor();
+
     public DrawBuildingAction() {
         super(tr("Draw buildings"), "building", tr("Draw buildings"),
                 Shortcut.registerShortcut("mapmode:buildings",
                         tr("Mode: {0}", tr("Draw buildings")),
                         KeyEvent.VK_B, Shortcut.DIRECT),
-                getCursor());
+                // Set super.cursor to crosshair without overlay because super.cursor is final,
+                // but we use two different cursors with overlays for rectangular and circular buildings
+                // the actual cursor is drawn in enterMode()
+                ImageProvider.getCursor("crosshair", null));
 
-        cursorCrosshair = getCursor();
+        currCursor = getCursor();
         cursorJoinNode = ImageProvider.getCursor("crosshair", "joinnode");
         cursorJoinWay = ImageProvider.getCursor("crosshair", "joinway");
-        currCursor = cursorCrosshair;
     }
 
     private static Cursor getCursor() {
@@ -133,20 +138,24 @@
     @Override
     public void enterMode() {
         super.enterMode();
+
         MapFrame map = MainApplication.getMap();
         if (getLayerManager().getEditDataSet() == null) {
             map.selectSelectTool(false);
             return;
         }
         selectedColor = new NamedColorProperty(marktr("selected"), selectedColor).get();
-        currCursor = cursorCrosshair;
         map.mapView.addMouseListener(this);
         map.mapView.addMouseMotionListener(this);
         map.mapView.addTemporaryLayer(this);
         map.keyDetector.addKeyListener(this);
         map.keyDetector.addModifierExListener(this);
         SelectionEventManager.getInstance().addSelectionListener(this);
+        Config.getPref().addKeyPreferenceChangeListener(ConfigKey.SHAPE.getKey(), shapeChangeListener);
+
         updateSnap(getLayerManager().getEditDataSet().getSelected());
+        // super.enterMode() draws the basic cursor. Overwrite it with the cursor for the current building mode. 
+        updCursor();
     }
 
     @Override
@@ -159,6 +168,8 @@
         map.keyDetector.removeKeyListener(this);
         map.keyDetector.removeModifierExListener(this);
         SelectionEventManager.getInstance().removeSelectionListener(this);
+        Config.getPref().removeKeyPreferenceChangeListener(ConfigKey.SHAPE.getKey(), shapeChangeListener);
+
         if (mode != Mode.None)
             map.mapView.repaint();
         mode = Mode.None;
@@ -385,13 +396,11 @@
     }
 
     private void updCursor() {
-        if (mousePos == null)
-            return;
         if (!MainApplication.isDisplayingMapView())
             return;
-        Node n = null;
-        if (!ctrl) {
-            n = MainApplication.getMap().mapView.getNearestNode(mousePos, OsmPrimitive::isSelectable);
+
+        if (!ctrl && (mousePos != null)) {
+            Node n = MainApplication.getMap().mapView.getNearestNode(mousePos, OsmPrimitive::isSelectable);
             if (n != null) {
                 setCursor(cursorJoinNode);
                 return;
Index: plugins/buildings_tools/src/org/openstreetmap/josm/plugins/buildings_tools/ToolSettings.java
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
diff --git a/plugins/buildings_tools/src/org/openstreetmap/josm/plugins/buildings_tools/ToolSettings.java b/plugins/buildings_tools/src/org/openstreetmap/josm/plugins/buildings_tools/ToolSettings.java
--- a/plugins/buildings_tools/src/org/openstreetmap/josm/plugins/buildings_tools/ToolSettings.java	(revision 35719)
+++ b/plugins/buildings_tools/src/org/openstreetmap/josm/plugins/buildings_tools/ToolSettings.java	(date 1615494172946)
@@ -19,7 +19,7 @@
         // Hide default constructor for utils classes
     }
 
-    public static final BooleanProperty PROP_USE_ADDR_NODE = new BooleanProperty("buildings_tools.addrNode", false);
+    static final BooleanProperty PROP_USE_ADDR_NODE = new BooleanProperty(ConfigKey.ADDRNODE.getKey(), false);
 
     public enum Shape {
             CIRCLE, RECTANGLE
@@ -71,12 +71,12 @@
             values.add(entry.getKey());
             values.add(entry.getValue());
         }
-        Config.getPref().putList("buildings_tools.tags", values);
+        Config.getPref().putList(ConfigKey.TAGS.getKey(), values);
     }
 
     private static void loadTags() {
         TAGS.clear();
-        Collection<String> values = Config.getPref().getList("buildings_tools.tags",
+        Collection<String> values = Config.getPref().getList(ConfigKey.TAGS.getKey(),
                 Arrays.asList("building", "yes"));
         try {
             for (Iterator<String> iterator = values.iterator(); iterator.hasNext();) {
@@ -88,11 +88,11 @@
     }
 
     public static void saveShape(Shape shape) {
-        Config.getPref().put("buildings_tool.shape", shape.name());
+        Config.getPref().put(ConfigKey.SHAPE.getKey(), shape.name());
     }
 
     private static Shape loadShape() {
-        String shape = Config.getPref().get("buildings_tool.shape");
+        String shape = Config.getPref().get(ConfigKey.SHAPE.getKey());
         if (ToolSettings.Shape.CIRCLE.name().equals(shape)) {
             ToolSettings.shape = Shape.CIRCLE;
             return Shape.CIRCLE;
@@ -103,19 +103,19 @@
     }
 
     public static void setBBMode(boolean bbmode) {
-        Config.getPref().putBoolean("buildings_tools.bbmode", bbmode);
+        Config.getPref().putBoolean(ConfigKey.BBMODE.getKey(), bbmode);
     }
 
     public static boolean isBBMode() {
-        return Config.getPref().getBoolean("buildings_tools.bbmode", false);
+        return Config.getPref().getBoolean(ConfigKey.BBMODE.getKey(), false);
     }
 
     public static void setSoftCursor(boolean softCursor) {
-        Config.getPref().putBoolean("buildings_tools.softcursor", softCursor);
+        Config.getPref().putBoolean(ConfigKey.SOFTCURSOR.getKey(), softCursor);
     }
 
     public static boolean isSoftCursor() {
-        return Config.getPref().getBoolean("buildings_tools.softcursor", false);
+        return Config.getPref().getBoolean(ConfigKey.SOFTCURSOR.getKey(), false);
     }
 
     public static boolean isAutoSelect() {
@@ -127,10 +127,10 @@
     }
 
     public static boolean isNoClickAndDrag() {
-        return Config.getPref().getBoolean("buildings_tools.noclickdrag", false);
+        return Config.getPref().getBoolean(ConfigKey.NOCLICKDRAG.getKey(), false);
     }
 
     public static void setNoClickAndDrag(boolean noClickDrag) {
-        Config.getPref().putBoolean("buildings_tools.noclickdrag", noClickDrag);
+        Config.getPref().putBoolean(ConfigKey.NOCLICKDRAG.getKey(), noClickDrag);
     }
 }
