### Godot version

v4.0.beta10.official [d0398f62f]

### System information

linux mint Vulkan API 1.3.194 - Using Vulkan Device #0: NVIDIA - NVIDIA GeForce GTX 1660 Ti, Vulkan API 1.3.194 - Using Vulkan Device #0: NVIDIA - NVIDIA GeForce GTX 1660 Ti

### Issue description

draw_dashed line fills the ending up instead leaving unpainted, maybe intended to draw more closed dashed rectangles, but i would call this a bug. If its intended the docs should mention this and i would like to see an option to turn this behavior off.
For example to use this for drawing multicolored dashed lines it would be a unwanted.

big dashed line length 119
![grafik](https://user-images.githubusercontent.com/8441455/211654997-0bd59f52-1429-431d-aa44-a3067e87124f.png)

big dashed line length 120
![grafik](https://user-images.githubusercontent.com/8441455/211655381-a279d25e-40eb-4f31-b613-fe141f72416f.png)

Below is shown lengths from 1 to 200

### Steps to reproduce

Run this lines to draw dashed lines:

```
	for i in range(0,200,2):
		self.draw_dashed_line(topleft + Vector2(0, i),
		topleft + Vector2(i, i),
		Color(1,1,1,1), 1, 10)
```

### Minimal reproduction project

-
if (!is_inside_tree()) {
			return;
		}
		_notify_transform(this);
		if (!block_transform_notify && notify_local_transform) {
			notification(NOTIFICATION_LOCAL_TRANSFORM_CHANGED);
		}
	}
	void item_rect_changed(bool p_size_changed = true);
	void _notification(int p_what);
	static void _bind_methods();
	GDVIRTUAL0(_draw)
public:
	enum {
		NOTIFICATION_TRANSFORM_CHANGED = SceneTree::NOTIFICATION_TRANSFORM_CHANGED, 
		NOTIFICATION_DRAW = 30,
		NOTIFICATION_VISIBILITY_CHANGED = 31,
		NOTIFICATION_ENTER_CANVAS = 32,
		NOTIFICATION_EXIT_CANVAS = 33,
		NOTIFICATION_LOCAL_TRANSFORM_CHANGED = 35,
		NOTIFICATION_WORLD_2D_CHANGED = 36,
	};
	
#ifdef TOOLS_ENABLED
	
	virtual bool _edit_is_selected_on_click(const Point2 &p_point, double p_tolerance) const;
	
	virtual void _edit_set_state(const Dictionary &p_state) {}