Index: /applications/editors/josm/plugins/mappaint/src/mappaint/MapPaintVisitor.java
===================================================================
--- /applications/editors/josm/plugins/mappaint/src/mappaint/MapPaintVisitor.java	(revision 2595)
+++ /applications/editors/josm/plugins/mappaint/src/mappaint/MapPaintVisitor.java	(revision 2596)
@@ -32,15 +32,17 @@
 	// Altered from SimplePaintVisitor
 	@Override public void visit(Node n) {
-		ElemStyle nodeStyle = MapPaintPlugin.elemStyles.getStyle(n);
-		if(nodeStyle!=null && Main.map.mapView.zoom()>=nodeStyle.getMinZoom()){
-			if(nodeStyle instanceof IconElemStyle) {
-				drawNode(n, ((IconElemStyle)nodeStyle).getIcon());
+		if (isNodeVisible(n)) {
+			ElemStyle nodeStyle = MapPaintPlugin.elemStyles.getStyle(n);
+			if(nodeStyle!=null && Main.map.mapView.zoom()>=nodeStyle.getMinZoom()){
+				if(nodeStyle instanceof IconElemStyle) {
+					drawNode(n, ((IconElemStyle)nodeStyle).getIcon());
+				} else {
+					// throw some sort of exception
+				}
 			} else {
-				// throw some sort of exception
-			}
-		} else {
-			drawNode(n, n.selected ? getPreferencesColor("selected",
-									Color.YELLOW)
-				: getPreferencesColor("node", Color.RED));
+				drawNode(n, n.selected ? getPreferencesColor("selected",
+										Color.YELLOW)
+					: getPreferencesColor("node", Color.RED));
+			}
 		}
 	}
@@ -52,5 +54,6 @@
 	 */
 	@Override public void visit(Segment ls) {
-		drawSegment(ls, getPreferencesColor("untagged",Color.GRAY));
+		if (isSegmentVisible(ls))
+			drawSegment(ls, getPreferencesColor("untagged",Color.GRAY));
 	}
 
@@ -87,5 +90,5 @@
 			for (Segment ls : w.segments)
 			{
-				if (!ls.selected) // selected already in good color
+				if ((!ls.selected) && (isSegmentVisible(ls))) // selected already in good color
 					drawSegment(ls, w.selected ?
 						getPreferencesColor("selected", Color.YELLOW) : colour,
@@ -126,4 +129,28 @@
 			g2d.setStroke(new BasicStroke(1));
 		}
+	}
+
+	/**
+	 * Checks if the given node is in the visible area.
+	 */
+	protected boolean isNodeVisible(Node n) {
+		Point p = nc.getPoint(n.eastNorth);
+		return !((p.x < 0) || (p.y < 0) || (p.x > nc.getWidth()) || (p.y > nc.getHeight()));
+	}
+
+	/**
+	 * Checks is the given segment is int the visible area.
+	 * NOTE: This will return true for a small number of non-visible
+	 *       segments.
+	 */
+	protected boolean isSegmentVisible(Segment ls) {
+		if (ls.incomplete) return false;
+		Point p1 = nc.getPoint(ls.from.eastNorth);
+		Point p2 = nc.getPoint(ls.to.eastNorth);
+		if ((p1.x < 0) && (p2.x < 0)) return false;
+		if ((p1.y < 0) && (p2.y < 0)) return false;
+		if ((p1.x > nc.getWidth()) && (p2.x > nc.getWidth())) return false;
+		if ((p1.y > nc.getHeight()) && (p2.y > nc.getHeight())) return false;
+		return true;
 	}
 
