4

I am working in a map with mixed names (Arabic and English). Data comes from OSM, a PBF export from BBBIKE, imported to Spatialite using OGR2OGR. I am adding the spatialite database using UTF-8 encoding.

Using the same display technique for both points and lines, for the POINTS layer I am getting the names displayed in Arabic as expected, without issues. However for the LINES layer, the names get displayed with the correct Arabic character but reversed (instead of being displayed for reading from right to left, are displayed in inverted order, as if they were meant to be read from left to right).

Here an example. Screen capture from the original OSM site of a section with a point feature (the mosque) and a line feature (the Brega Road, in red, at the lower right side of the image) OSM original map

Then here is the result I get in GQIS: enter image description here

Note that the mosque name gets displayed correctly in QGIS (font is slightly different, but the order is the correct one). On the other hand, the Brega Road below gets displayed inverted. That's it, should say "AQIRBLA QIRT" (for "TRIQ ALBRIQA", the name of the road in Arabic characters) but it says instead "TRIQ ALBRIQA" displaying the letters in the correct ORDER but in the wrong direction (as if it was meant to read like in English, from left to right).

Here below the capture of the content of the cells with the names. In both cases the content is the correct one, displayed correctly both in order and direction. The mosque name cell:

enter image description here

The road name cell:

enter image description here

Any idea on what could be wrong?

  • Have you considered changing encoding as below post : gis.stackexchange.com/questions/87367/… – Shiko Jan 24 '17 at 13:56
  • Yes, and it doesn't work. In fact when I use Windows-1256 the text comes out garbled, as it is not the coding used by OSM (OSM uses UTF-8). Same thing for Arabic encoding. Thanks – Juan Batman Jan 24 '17 at 14:20
  • 2
    i think this may be a known issue. Does it work if you try an option other than 'curved'? – Steven Kay Jan 24 '17 at 19:20
  • Thanks! That was it! I changed to horizontal, and now the labels are just fine. Thanks for the help, I will mark it as solved, even if it is still an open issue in QGIS! – Juan Batman Jan 25 '17 at 6:44
2

Thanks to Steven Kay. It is a known issue. The workaround is to put in Label, Placement, an option other than "Curved" (either Parallel or Horizontal). The labels will be displayed correctly after.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.