title: How to draw a line connecting a label to its position on OpenLayers3
body: <p>I need to draw a line connecting a point to its label. Like this:</p>
  
  <p><a href="https://i.stack.imgur.com/SJre8.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/SJre8.png" alt="enter image description here"></a></p>
  
  <p>The 'Y' has coordinates, the label is in a different position on the screen by using offSet. I also can drag the label around by changing its offset, and I need the line to adapt when I do that so they remain connected.</p>
  
  <p>Is there any way to draw a line on the map without providing coordinates to it? Because I only have one set of coordinates and an offset.</p>
  
  <p>This is how I created the point:</p>
  
  <pre><code>    configLabel(offsetx,offsety,label){
      labelStyle = new ol.style.Style({
          text: new ol.style.Text({
              font: '12px Calibri,sans-serif',
              fill: new ol.style.Fill({ color: color }),
              stroke: new ol.style.Stroke({
              color: '#fff', width: 2
              }),
              text: label,
              offsetY: offsety,
              offsetX: offsetx
          })
      });
  }
  
  pointStyle = new ol.style.Style({
      image: new ol.style.Icon({
          anchor: [0.5, 25],
          anchorXUnits: 'fraction',
          anchorYUnits: 'pixels',
          src: 'img/point.ico'
      })
  });
  
  var point = new ol.Feature(new ol.geom.Point(coord));
  point.setStyle(pointStyle);
  layerSource.addFeature(point);
  
  var label1 = new ol.Feature(new ol.geom.Point(coord));
  var style = configLabel(0,15, 'line1');
  label1.setStyle(style);
  layerSource.addFeature(label1);
  
  var label2 = new ol.Feature(new ol.geom.Point(coord));
  var style = configLabel(0,30, 'line2');
  label2.setStyle(style);
  layerSource.addFeature(label2);
  
  var label3 = new ol.Feature(new ol.geom.Point(coord));
  var style = configLabel(0,45, 'line3');
  label3.setStyle(style);
  layerSource.addFeature(label3);
  
  var label4 = new ol.Feature(new ol.geom.Point(coord));
  var style = configLabel(0,60, 'line4');
  label4.setStyle(style);
  layerSource.addFeature(label4);
  </code></pre>
  
  <p>Thanks a lot!</p>