### Godot version

3.5.1 custom build

### System information

N/A

### Issue description

When using Line2D, I noticed a discrepancy with UVs depending on the end cap mode.

Here are some examples using a tiled repeating texture:

### No capping ✔️ 
![image](https://user-images.githubusercontent.com/95356449/218230984-e5d507d4-7af7-4967-aee7-79c8daa206ff.png)

### Begin cap: Box ✔️ 
![image](https://user-images.githubusercontent.com/95356449/218231092-311370cc-7ff8-4699-976b-c4581eaada0a.png)

### End cap: Box ❌ 
![image](https://user-images.githubusercontent.com/95356449/218231131-00ddf4f7-2a9a-4740-a445-a8601ab026e1.png)


### Steps to reproduce

Create a Line2D
Add a texture with repeating enabled
Set end cap mode to Box

### Minimal reproduction project

not needed, bugfix pr incoming
if (intersection_result != SEGMENT_INTERSECT) {
				
				
				strip_begin(pos_up0, pos_down0, color1, uvx1);
			}
		}
	}
	
	pos1 = points[points.size() - 1];
	if (distance_required) {
		current_distance1 += pos0.distance_to(pos1);
	}
	if (_interpolate_color) {
		color1 = gradient->get_color(gradient->get_point_count() - 1);
	}
	if (retrieve_curve) {
		width_factor = curve->sample_baked(1.f);
	}
	Vector2 pos_up1 = pos1 + u0 * hw * width_factor;
	Vector2 pos_down1 = pos1 - u0 * hw * width_factor;
	
	if (end_cap_mode == Line2D::LINE_CAP_BOX) {
		pos_up1 += f0 * hw * width_factor;
		pos_down1 += f0 * hw * width_factor;
	}
	if (texture_mode == Line2D::LINE_TEXTURE_TILE) {
		uvx1 = current_distance1 / (width * tile_aspect);
	} else if (texture_mode == Line2D::LINE_TEXTURE_STRETCH) {
		uvx1 = current_distance1 / total_distance;
	}