The locator overlay has always been a bit blurry on retina screens. Now that this layer has been updated (#7025), it'd be especially nice to load the high-resolution tiles, but only for high-DPI devices.
Mapbox specifies the {@2x} parameter for toggling retina tiles. Leaflet uses {r}. The editor-layer-index doesn't support either yet, but we can tack one onto the locator overlay endpoint in update_imagery.js and then determine what resolution to fetch in code based on window.devicePixelRatio. The great part is that this will also work for custom backgrounds and if ELI decides to support one of these parameters in the future.

iD now loads retina tiles for the locator overlay on retina screens. iD will switch between retina and non-retina requests if the pixel density changes, such as when dragging a browser window between displays. Custom background layers can also take advantage of this behavior by specifying {r} or {@2x} if the endpoint supports retina tiles.

While I was at it, I improved the formatting of the custom background instructions. We have a lot of parameters now following #7510.

Is there a way or plan to support @3x scaling? It would be nice to have universal scaling parameter and specify supported scalings. For example: {@2x,@3x} or {r,2,3}.
@quincylvania sorry to hijack this issue. To support retina for wms sources, wouldn't it just be necessary to increase the width and height parameter of the getmap queries if isRetina is true? https://github.com/openstreetmap/iD/blob/3ef36a8badc50d56b15dd4749df8e36be5f50a1b/modules/renderer/background_source.js#L159
But it probably needs to be investigated if this would have a negative impact on the performance of wms layers.
Is there a way or plan to support @3x scaling?
@zdila No ongoing plans… we could theoretically support it but I'm not sure how useful it'd be. 2x is suitable for most screens. Doesn't look like Leaflet supports this yet either. Do you know of any actual 3x endpoints that people might need in iD?
To support retina for wms sources, wouldn't it just be necessary to increase the width and height parameter of the getmap queries if isRetina is true?
I'm not a WMS expert but if the endpoints is imagery-only, something like this might work. #8163 might be related.
we could theoretically support it but I'm not sure how useful it'd be
useful for 8k 32" and smaller displays ... maybe more a future ;-)
Do you know of any actual 3x endpoints that people might need in iD?
"Ortofotomozaika SR" background supports it. But not sure if anybody needs it.
"Ortofotomozaika SR" background supports it. But not sure if anybody needs it.
Okay, well I'd say we can wait for 3x to catch on more before worrying about it.
Most helpful comment
iD now loads retina tiles for the locator overlay on retina screens. iD will switch between retina and non-retina requests if the pixel density changes, such as when dragging a browser window between displays. Custom background layers can also take advantage of this behavior by specifying
{r}or{@2x}if the endpoint supports retina tiles.While I was at it, I improved the formatting of the custom background instructions. We have a lot of parameters now following #7510.