### Godot version

4.0.beta15

### System information

windows 10, nvidia graphics, opengl backend

### Issue description

When using a TileSetAtlasSource on a TileSet with dimensions greater than 799x799 and selecting the Tiles tab in the TileSet editor, all tabs in the right editor panel disappear.

This is likely a regression of https://github.com/godotengine/godot/issues/67942

### Steps to reproduce

see attached video:

https://user-images.githubusercontent.com/5783414/215139823-f78e94c5-5199-452e-b601-76ec0f680748.mp4


### Minimal reproduction project

[LikelyRegressionOf67942.zip](https://github.com/godotengine/godot/files/10520933/LikelyRegressionOf67942.zip)

state.instance_data_array[r_index].color_texture_pixel_size[0] = 0.0;
		state.instance_data_array[r_index].color_texture_pixel_size[1] = 0.0;
		state.instance_data_array[r_index].pad[0] = 0.0;
		state.instance_data_array[r_index].pad[1] = 0.0;
		state.instance_data_array[r_index].lights[0] = lights[0];
		state.instance_data_array[r_index].lights[1] = lights[1];
		state.instance_data_array[r_index].lights[2] = lights[2];
		state.instance_data_array[r_index].lights[3] = lights[3];
		state.instance_data_array[r_index].flags = base_flags | (state.instance_data_array[r_index == 0 ? 0 : r_index - 1].flags & (FLAGS_DEFAULT_NORMAL_MAP_USED | FLAGS_DEFAULT_SPECULAR_MAP_USED)); 
		Color blend_color = base_color;
		GLES3::CanvasShaderData::BlendMode blend_mode = p_blend_mode;
		if (c->type == Item::Command::TYPE_RECT) {
			const Item::CommandRect *rect = static_cast<const Item::CommandRect *>(c);
			if (rect->flags & CANVAS_RECT_LCD) {
				blend_mode = GLES3::CanvasShaderData::BLEND_MODE_LCD;
				blend_color = rect->modulate * base_color;
			}
		}
		if (blend_mode != state.canvas_instance_batches[state.current_batch_index].blend_mode || blend_color != state.canvas_instance_batches[state.current_batch_index].blend_color) {
			_new_batch(r_batch_broken, r_index);
			state.canvas_instance_batches[state.current_batch_index].blend_mode = blend_mode;
			state.canvas_instance_batches[state.current_batch_index].blend_color = blend_color;
		}
		switch (c->type) {
			case Item::Command::TYPE_RECT: {
				const Item::CommandRect *rect = static_cast<const Item::CommandRect *>(c);
				if (rect->flags & CANVAS_RECT_TILE && state.canvas_instance_batches[state.current_batch_index].repeat != RenderingServer::CanvasItemTextureRepeat::CANVAS_ITEM_TEXTURE_REPEAT_ENABLED) {
					_new_batch(r_batch_broken, r_index);
					state.canvas_instance_batches[state.current_batch_index].repeat = RenderingServer::CanvasItemTextureRepeat::CANVAS_ITEM_TEXTURE_REPEAT_ENABLED;
				}