<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto">Some interesting solution found in pgadmin <div><br></div><div><a href="https://gis.stackexchange.com/questions/261654/automatic-bus-route-map-without-overlaps">https://gis.stackexchange.com/questions/261654/automatic-bus-route-map-without-overlaps</a><br><br><div dir="ltr">Nicolas Cadieux<div><a href="https://gitlab.com/njacadieux">https://gitlab.com/njacadieux</a></div></div><div dir="ltr"><br><blockquote type="cite">Le 11 nov. 2022 à 09:13, Nicolas Cadieux <njacadieux.gitlab@gmail.com> a écrit :<br><br></blockquote></div><blockquote type="cite"><div dir="ltr"><meta http-equiv="content-type" content="text/html; charset=utf-8">Hi,<div><br><div>I am not aware of a function or of a plugin that does that. I would start by googling.  A quick Google search has shown me this python solution. <a href="https://gis.stackexchange.com/questions/239129/shifting-display-of-overlapping-lines-in-qgis">https://gis.stackexchange.com/questions/239129/shifting-display-of-overlapping-lines-in-qgis</a></div><div><br>It was created for an earlier version of QGIS with another version of Python. If would need to be adapted.  If this is for a small project (but to big to do by hand) you could always just install a QGIS 2.XX version of QGIS in a virtual machine to see if it works.</div><div><br></div><div>Then, you could ask help to adapt if to QGIS 3x.  Maybe there is a plugin that already does this.</div><div><br></div><div><div dir="ltr">Nicolas Cadieux<div><a href="https://gitlab.com/njacadieux">https://gitlab.com/njacadieux</a></div></div><div dir="ltr"><br><blockquote type="cite">Le 11 nov. 2022 à 06:45, Bombonato Antonio Maria <antoniomaria.bombonato@italtel.com> a écrit :<br><br></blockquote></div><blockquote type="cite"><div dir="ltr">

<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style>@font-face { font-family: Helvetica; }
@font-face { font-family: "Cambria Math"; }
@font-face { font-family: Calibri; }
@font-face { font-family: Consolas; }
@font-face { font-family: "Minion Pro"; }
p.MsoNormal, li.MsoNormal, div.MsoNormal { margin: 0cm; font-size: 11pt; font-family: Calibri, sans-serif; }
a:link, span.MsoHyperlink { color: rgb(5, 99, 193); text-decoration: underline; }
pre { margin: 0cm; font-size: 10pt; font-family: "Courier New"; }
span.PreformattatoHTMLCarattere { font-family: Consolas; }
span.StileMessaggioDiPostaElettronica24 { font-family: Calibri, sans-serif; color: windowtext; }
.MsoChpDefault { font-size: 10pt; }
@page WordSection1 { size: 612pt 792pt; margin: 70.85pt 2cm 2cm; }
div.WordSection1 { page: WordSection1; }</style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->


<div class="WordSection1">
<p class="MsoNormal">Thanks Nicolas.<o:p></o:p></p>
<p class="MsoNormal">Unfortunately, the problem is not to identify the overlapping lines.
<o:p></o:p></p>
<p class="MsoNormal">I already have a shapefile that identifies the sections with multiple overlapping lines. In this shapefile, for each segment with overlaps, I have the indication of how many overlapping lines there are (at most 3).<o:p></o:p></p>
<p class="MsoNormal">The real problem is to draw the lines without overlappings.<o:p></o:p></p>
<p class="MsoNormal">Any suggestion will be appreciated.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:12.0pt;margin-right:0cm;margin-bottom:2.0pt;margin-left:0cm;line-height:120%;text-autospace:none">
<b><span style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT"></span></b></p><div><b><image001.png></b></div><b><span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT"><o:p></o:p></span></b><p></p>
<p class="MsoNormal" style="mso-margin-top-alt:6.0pt;margin-right:0cm;margin-bottom:2.0pt;margin-left:0cm;line-height:120%;text-autospace:none">
<b><span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:#404040;mso-fareast-language:IT">Antonio Maria Bombonato<o:p></o:p></span></b></p>
<p class="MsoNormal" style="mso-margin-top-alt:6.0pt;margin-right:0cm;margin-bottom:2.0pt;margin-left:0cm;line-height:120%;text-autospace:none">
<span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT">Software Developer<br>
Business Unit Ultra Broadband</span><span lang="EN-US" style="font-size:9.0pt;line-height:120%;mso-fareast-language:IT"><br>
</span><span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT"><br>
</span><b><span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:#404040;mso-fareast-language:IT">Italtel S.p.A.</span></b><span lang="EN-US" style="font-size:12.0pt;line-height:120%;font-family:"Minion Pro";color:black;mso-fareast-language:IT"><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-bottom:2.0pt;line-height:120%;text-autospace:none">
<span style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;letter-spacing:.2pt;mso-fareast-language:IT">Via Caldera, 21
<br>
20153 Milano </span><span style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT">MI – Italy<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-bottom:2.0pt;line-height:120%;text-autospace:none">
<span style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT">email:
</span><a href="mailto:antoniomaria.bombonato@italtel.com"><span style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:blue;mso-fareast-language:IT">antoniomaria.bombonato@italtel.com</span></a><span style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT"><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-bottom:2.0pt;line-height:120%;text-autospace:none">
<span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT">P: +39 024388388<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-bottom:2.0pt;line-height:120%;text-autospace:none">
<a href="http://www.italtel.com/"><span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:blue;mso-fareast-language:IT">www.italtel.com</span></a><span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT"><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-bottom:2.0pt;line-height:120%;text-autospace:none">
<span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:IT"><o:p> </o:p></span></p>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span style="mso-fareast-language:IT">Da:</span></b><span style="mso-fareast-language:IT"> Nicolas Cadieux <njacadieux.gitlab@gmail.com>
<br>
<b>Inviato:</b> martedì 8 novembre 2022 18:40<br>
<b>A:</b> Bombonato Antonio Maria <antoniomaria.bombonato@italtel.com>; qgis-user@lists.osgeo.org<br>
<b>Oggetto:</b> Re: [Qgis-user] Problem display overlapping lines<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p>Hi,<o:p></o:p></p>
<p>It would be nice to have this QGIS.  My first reaction is to use line offset but the end result is not predictable. You may need to work with Python to do this.  You could also probably create a model. 
<o:p></o:p></p>
<p>If you need to identify the overlapping segments, you can use my Fix Directional Network model 1 to 3.  You can download this on the plugin page.
<a href="https://plugins.qgis.org/models/?order_by=-upload_date&&is_gallery=true">
https://plugins.qgis.org/models/?order_by=-upload_date&&is_gallery=true</a><o:p></o:p></p>
<p>The first model will check the Geometries.  Test with all default values.  After running this model, run the second model.  It should identify all partially overlapping lines.  This layer will be called "Potential Problem || Overlapping lines." You can open
 the second model and look at the "Find overlapping lines" algorithm to see how it's done.   It should find any overlapping or partially overlapping lines.<o:p></o:p></p>
<p>This video should help you figure things out. <a href="https://youtu.be/v61PafSByvM">
https://youtu.be/v61PafSByvM</a><o:p></o:p></p>
<p>It's not a total solution but it's at least a start!<o:p></o:p></p>
<p>Nicolas Cadieux<o:p></o:p></p>
<p><o:p> </o:p></p>
<div>
<p class="MsoNormal">Le 2022-11-03 à 3:12 p.m., Bombonato Antonio Maria via Qgis-user a écrit :<o:p></o:p></p>
</div>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<p class="MsoNormal">Hello,<o:p></o:p></p>
<p class="MsoNormal">First of all, sorry for my english.<o:p></o:p></p>
<p class="MsoNormal">My name is Antonio Bombonato and it is the first time I ask a question to this mailing list.<o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal">I have a shapefile with multiple routes (each one is identified by an univoque OBJECT_ID) and some are partially overlapped (i.e they share the same segment). I need to display these routes so they are all visible and without overlapping.<o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal">i tryed using line offset but some line still remains overlapped.<o:p></o:p></p>
<p class="MsoNormal">Any idea to solve the problem, possibly using a python script, will be appreciated.<o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal">Attached the starting shapefile (cables) and the desired result I want to obtain (target).<o:p></o:p></p>
<p class="MsoNormal">In this case the shapefile target was created manually moving the vertices of each line.<o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal">P.S. I use 3.16.7-Hannover QGIS version<o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal">Best regards,<o:p></o:p></p>
<p class="MsoNormal">Antonio<o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:12.0pt;margin-right:0cm;margin-bottom:2.0pt;margin-left:0cm;line-height:120%;text-autospace:none">
<b><span style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT"></span></b></p><div><b><image001.png></b></div><o:p></o:p><p></p>
<p class="MsoNormal" style="mso-margin-top-alt:6.0pt;margin-right:0cm;margin-bottom:2.0pt;margin-left:0cm;line-height:120%;text-autospace:none">
<b><span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:#404040;mso-fareast-language:IT">Antonio Maria Bombonato</span></b><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:6.0pt;margin-right:0cm;margin-bottom:2.0pt;margin-left:0cm;line-height:120%;text-autospace:none">
<span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT">Software Developer<br>
Business Unit Ultra Broadband</span><span lang="EN-US" style="font-size:9.0pt;line-height:120%;mso-fareast-language:IT"><br>
</span><span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT"><br>
</span><b><span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:#404040;mso-fareast-language:IT">Italtel S.p.A.</span></b><o:p></o:p></p>
<p class="MsoNormal" style="margin-bottom:2.0pt;line-height:120%;text-autospace:none">
<span style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;letter-spacing:.2pt;mso-fareast-language:IT">Via Caldera, 21
<br>
20153 Milano </span><span style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT">MI – Italy</span><o:p></o:p></p>
<p class="MsoNormal" style="margin-bottom:2.0pt;line-height:120%;text-autospace:none">
<span style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT">email:
</span><a href="mailto:antoniomaria.bombonato@italtel.com"><span style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:blue;mso-fareast-language:IT">antoniomaria.bombonato@italtel.com</span></a><o:p></o:p></p>
<p class="MsoNormal" style="margin-bottom:2.0pt;line-height:120%;text-autospace:none">
<span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT">P: +39 024388388</span><o:p></o:p></p>
<p class="MsoNormal" style="margin-bottom:2.0pt;line-height:120%;text-autospace:none">
<a href="http://www.italtel.com/"><span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:blue;mso-fareast-language:IT">www.italtel.com</span></a><o:p></o:p></p>
<p class="MsoNormal" style="margin-bottom:2.0pt;line-height:120%;text-autospace:none">
<span lang="EN-US" style="font-size:9.0pt;line-height:120%;font-family:"Helvetica",sans-serif;color:black;mso-fareast-language:IT"> </span><o:p></o:p></p>
<p class="MsoNormal"><span style="mso-fareast-language:IT"> </span><o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal"><span style="mso-fareast-language:IT"><br>
<br>
<o:p></o:p></span></p>
<pre>_______________________________________________<o:p></o:p></pre>
<pre>Qgis-user mailing list<o:p></o:p></pre>
<pre><a href="mailto:Qgis-user@lists.osgeo.org">Qgis-user@lists.osgeo.org</a><o:p></o:p></pre>
<pre>List info: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-user">https://lists.osgeo.org/mailman/listinfo/qgis-user</a><o:p></o:p></pre>
<pre>Unsubscribe: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-user">https://lists.osgeo.org/mailman/listinfo/qgis-user</a><o:p></o:p></pre>
</blockquote>
</div>


</div></blockquote></div></div></div></blockquote></div></body></html>