### 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

-
return canvas_texture;
}
void CanvasTexture::_bind_methods() {
	ClassDB::bind_method(D_METHOD("set_diffuse_texture", "texture"), &CanvasTexture::set_diffuse_texture);
	ClassDB::bind_method(D_METHOD("get_diffuse_texture"), &CanvasTexture::get_diffuse_texture);
	ClassDB::bind_method(D_METHOD("set_normal_texture", "texture"), &CanvasTexture::set_normal_texture);
	ClassDB::bind_method(D_METHOD("get_normal_texture"), &CanvasTexture::get_normal_texture);
	ClassDB::bind_method(D_METHOD("set_specular_texture", "texture"), &CanvasTexture::set_specular_texture);
	ClassDB::bind_method(D_METHOD("get_specular_texture"), &CanvasTexture::get_specular_texture);
	ClassDB::bind_method(D_METHOD("set_specular_color", "color"), &CanvasTexture::set_specular_color);
	ClassDB::bind_method(D_METHOD("get_specular_color"), &CanvasTexture::get_specular_color);
	ClassDB::bind_method(D_METHOD("set_specular_shininess", "shininess"), &CanvasTexture::set_specular_shininess);
	ClassDB::bind_method(D_METHOD("get_specular_shininess"), &CanvasTexture::get_specular_shininess);
	ClassDB::bind_method(D_METHOD("set_texture_filter", "filter"), &CanvasTexture::set_texture_filter);
	ClassDB::bind_method(D_METHOD("get_texture_filter"), &CanvasTexture::get_texture_filter);
	ClassDB::bind_method(D_METHOD("set_texture_repeat", "repeat"), &CanvasTexture::set_texture_repeat);
	ClassDB::bind_method(D_METHOD("get_texture_repeat"), &CanvasTexture::get_texture_repeat);
	ADD_GROUP("Diffuse", "diffuse_");
	ADD_PROPERTY(PropertyInfo(Variant::OBJECT, "diffuse_texture", PROPERTY_HINT_RESOURCE_TYPE, "Texture2D"), "set_diffuse_texture", "get_diffuse_texture");
	ADD_GROUP("NormalMap", "normal_");
	ADD_PROPERTY(PropertyInfo(Variant::OBJECT, "normal_texture", PROPERTY_HINT_RESOURCE_TYPE, "Texture2D"), "set_normal_texture", "get_normal_texture");
	ADD_GROUP("Specular", "specular_");
	ADD_PROPERTY(PropertyInfo(Variant::OBJECT, "specular_texture", PROPERTY_HINT_RESOURCE_TYPE, "Texture2D"), "set_specular_texture", "get_specular_texture");
	ADD_PROPERTY(PropertyInfo(Variant::COLOR, "specular_color", PROPERTY_HINT_COLOR_NO_ALPHA), "set_specular_color", "get_specular_color");
	ADD_PROPERTY(PropertyInfo(Variant::FLOAT, "specular_shininess", PROPERTY_HINT_RANGE, "0,1,0.01"), "set_specular_shininess", "get_specular_shininess");
	ADD_GROUP("Texture", "texture_");
	ADD_PROPERTY(PropertyInfo(Variant::INT, "texture_filter", PROPERTY_HINT_ENUM, "Inherit,Nearest,Linear,Nearest Mipmap,Linear Mipmap,Nearest Mipmap Anisotropic,Linear Mipmap Anisotropic"), "set_texture_filter", "get_texture_filter");
	ADD_PROPERTY(PropertyInfo(Variant::INT, "texture_repeat", PROPERTY_HINT_ENUM, "Inherit,Disabled,Enabled,Mirror"), "set_texture_repeat", "get_texture_repeat");
}
CanvasTexture::CanvasTexture() {