Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

Commit

Permalink
[Qt] Added line-dasharray to the example app
Browse files Browse the repository at this point in the history
Showing how to add numbers in an array.
  • Loading branch information
tmpsantos committed Jan 9, 2017
1 parent 0caa496 commit eaf03f4
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions platform/qt/app/mapwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,12 @@ void MapWindow::keyPressEvent(QKeyEvent *ev)
m_map->setLayoutProperty("route", "line-join", "round");
m_map->setLayoutProperty("route", "line-cap", "round");

QVariantList lineDashArray;
lineDashArray.append(1);
lineDashArray.append(2);

m_map->setPaintProperty("route", "line-dasharray", lineDashArray);

// Markers at the beginning and end of the route
m_map->addImage("label-arrow", QImage(":label-arrow.svg"));
m_map->addImage("label-background", QImage(":label-background.svg"));
Expand Down

0 comments on commit eaf03f4

Please sign in to comment.