Help talk:Extension:Kartographer

About this board

Welcome to the Maps discussion. This is a place to provide overall maps feedback.

Previous discussion was archived at Help talk:Extension:Kartographer/Archive 0 and Help talk:Extension:Kartographer/Archive 1.

Could Kartographer be used to show articles of Wikipedia Places/Nearby?

4
Prototyperspective (talkcontribs)

Could this extension be combined with the reintroduced Wikipedia Places feature (currently usable in the Wikipedia app)? In phab:T360197 I proposed filters for it and that one could create views using them that are then embedded in articles like e.g. one about greenspaces in a specific region.

TheDJ (talkcontribs)

This only draws a map. You seem to want additional 'filters'. In order to know how to filter, you first need to log somewhere what values go with each coordinate. The locations for each coordinate are tracked by Extension:GeoData. The search is done by Extension:CirrusSearch.

Prototyperspective (talkcontribs)

The filters would be implemented at the Wikipedia Places side. So instead of just a Show nearby places button there would be some other button and it would load the filtered list of geolocated articles (like 'all forests in region xy'). So it would not be filtered at Kartographer side. I was asking about whether it could show these filtered list of articles (e.g. embedded within AP articles) so it could be used for that part of my proposal (and I may add the info to the code issue). Do you think that is possible and/or are there some specific issues with that? Thanks for these infos – it seems like these two are or would be used by Wikipedia Places.

TheDJ (talkcontribs)

In the basis, it's just leaflet. So it can do anything leaflet can do, as long as you have code that connects your source with the map layer.

Reply to "Could Kartographer be used to show articles of Wikipedia Places/Nearby?"
Fgnievinski (talkcontribs)

Hi. I'm trying to use "mapbox|from=Muro_da_Mauá.map" (with the surrounding double curly braces) at en:Mauá_Wall#External_links, but nothing shows up. commons:Data:Muro_da_Mauá.map seems fine (except for the zoom view, which I plan to fix later, adding bboxes). Any ideas, please? (I've exported the JSON becase relation:site is not supported yet.) Thanks!

Fgnievinski (talkcontribs)
Reply to "JSON problem"

Shapes don't get filled

2
KajenCAT (talkcontribs)
This post was hidden by KajenCAT (history)
Reply to "Shapes don't get filled"

Thumbmail maps with geomasks

5
Summary by Thiemo Kreuz (WMDE)
Dipsacus fullonum (talkcontribs)

If coordinates and zoom are not specified for maps with geomasks, the static thumbmail map seems to be generated all zoomed out (zoom=0) which makes the thumbmail map pretty useless. It works fine for the same maps with geoshapes instead of geomasks. Please see examples in my Wikipedia sandbox at User:Dipsacus fullonum/sandbox/geoshape. Is this a known issue and is there a workaround?

Thiemo Kreuz (WMDE) (talkcontribs)

That's a really good example page, thanks for that! The reason for this behavior is how masks are implemented: as inverted shapes. A mask is just a shape that covers the entire world – with a hole. That's what the automatic zoom feature sees and why it shows the entire world. While it might be possible to improve the automatic zoom to understand this better I don't think anyone can assign resources to this at the moment.

TheDJ (talkcontribs)
Ponor (talkcontribs)

@Thiemo Kreuz (WMDE) @TheDJ Such a shame that this isn't working, there are multiple examples on enwiki (collapsed boxes here e.g.) that are showing this bug. But why Dipsacus' examples 1, 2 & 4 seem OK while I'm editing their sandbox (code) and previewing either in real time or by pressing the preview button? And why are they not working in a completely different way when editing in VisualEditor?

Thiemo Kreuz (WMDE) (talkcontribs)

The maps are generally rendered in two surprisingly different ways: Either as a dynamic map in your browser or as a static image. The wikitext preview works because it is done in your browser and doesn't involve the broken code mentioned in phab:T305121.

The issue we see in VisualEditor is very closely related, if not the same. VisualEditor generally has a very hard time doing anything with non-trivial maps.

Reply to "Thumbmail maps with geomasks"

Can the option to not have names on the maps be made available?

5
Summary by Thiemo Kreuz (WMDE)
RobinLeicester (talkcontribs)

The 'OSM Location map' template, previously using the Graph: extension, has now been converted to get the maps from <mapframe>. One loss from this is the option for a basemap with no names. In Graph this was possible (and quite widely used) by setting 'style=osm' rather than 'style=osm-intl'.

The relevant phrase from the Kartographer installation page says:

$wgKartographerStyles
["osm-intl", "osm"]
Available map styles users can request from your $wgKartographerMapServer via mapstyle="…".

But as I understand it, this has not been made available to <mapframe>. If there is any way this could be given as an option, it would help the various editors who are asking for this at en:template:OSM Location map. Thanks.

Thiemo Kreuz (WMDE) (talkcontribs)

Technically, mapstyle="osm" is available. However, I think I discovered a bug that might explain the confusion, see phab:T362531. Can you tell on which wiki you are experiencing issues with this?

RobinLeicester (talkcontribs)

It is on En:wikipedia. Having just tried it, I find it does indeed work, but not in preview. When trying different combinations, it had not occurred to me to submit any of the edits, when it didn't preview as working. That is a really useful step forward. If the bug can also be resolved, that would be even better. Thanks

Thiemo Kreuz (WMDE) (talkcontribs)

Great, that confirms the issue I have seen. Thanks! The fix should be deployed the next days.

RobinLeicester (talkcontribs)

Great news. At risk of pushing our luck ... an editor also mentioned how street names continue to be shown at zooms 14 and upwards, even with the labels supressed. Just in case there was a simple way to remove them as well, I said I would mention it here. Thanks

Reply to "Can the option to not have names on the maps be made available?"
Guillaume Taillefer (talkcontribs)

Whenever I am in VisualEditor and try to click on the map button to add one, it pops up with the window but constantly is loading and doesn't try to show a map. I can't click neither the exit nor save button, but if I press esc then it will let me exit out with nothing. I am on MediaWiki 1.40

TheDJ (talkcontribs)

> I am on MediaWiki 1.40

So not a wikimedia wiki ?

Guillaume Taillefer (talkcontribs)

Yes sorry I tried using it on MediaWiki thinking I could use it like any other extension. But I guess I will have to try to use Maps

Reply to "The map will not load"
Inehmo (talkcontribs)

How could I draw a circle using Kartographer? This would be useful in describing a radius of action or an operating range.

Thiemo Kreuz (WMDE) (talkcontribs)

Kartographer is based on GeoJSON and can only offer what GeoJSON supports. What you can do is to draw a polygon that looks like a circle.

Reply to "Circles"
The Patriot Woodworker (talkcontribs)

Good day, am I able to use Kartographer on my own personal Mediawiki installation? Thank you.

TheDJ (talkcontribs)

If you also bring your own map tile renderer. in theory. yes. But that's a pretty theoretical answer. In general for 3rd parties Extension:Maps is a better option.

The Patriot Woodworker (talkcontribs)

Thanks TheDJ, experimenting with Maps now, appreciate your feedback.

This post was hidden by The Patriot Woodworker (history)
Fl.schmitt (talkcontribs)

Could you please provide an example to draw a geoline based on a OSM way? All of your examples seem to refer to relation objects in OSM, not to ways. I wasn't able to modify the geoline example "Interstate Highway I-696" to work with an OSM way. If this is a technical restriction, it should be mentioned in the docs. Thanks a lot!

Andree.sk (talkcontribs)

Probably a too late answer, but OSM cannot identify entities other than relations, in a stable way. Anyone is free to move/replace/split/combine ways "as they like". OTOH, editors usually keep relations in place...

Reply to "geoline from OSM way?"
Sdkb (talkcontribs)

At w:Claremont Colleges#Colleges, it used to render properly, but checking recently, the southernmost college (Pomona) has only an outline, whereas the others have the fill. Any idea why that's happening?

Pomona is (I think) the only one to have a proper relation on OSM, so that might be part of it, but it shouldn't be an issue as it's still linked from OSM to Wikidata.

TheDJ (talkcontribs)

Generally, that means the relation on OSM has a hole in the outline and thus fill is not possible

Sdkb (talkcontribs)
Reply to "Help/possible bug"
Return to "Extension:Kartographer" page.