0

I created callouts with expression below, because I need to have anchor dropdown at the half of a line.

make_line ( make_point ( "auxiliary_storage_labeling_positionx",
"auxiliary_storage_labeling_positiony" ), line_interpolate_point(
$geometry, length ($geometry)/2 ) )

However, I sometimes need to move labels a bit without showing a callout. If I use callout option, it is possible to achieve it with a setting of an offset from feature and label area (picture). How can I achieve it if I created callouts with an expression? As is seen on pictures 2 (label not manually moved) and pictures 3 ((label manually moved) I only moved label along the line. enter image description here

enter image description here

enter image description here

7
  • Please define the cases in which you would need to callout line to not to be visible.
    – Erik
    Commented Jun 2, 2021 at 11:27
  • I need callout to be not visible when I move label along the line (with some small margin. because manually I am not able to move label "just" along the line, I always also move label "closer" or "away" line. . When I move label away from the line, I need callout to be visible. Therefore I originally used offset from feature (line), because then to some extent callout is not visible.
    – pazelvak
    Commented Jun 2, 2021 at 11:34
  • Then I suggest you compare the azimuth of your callout line to the azimuth of the line feature.
    – Erik
    Commented Jun 2, 2021 at 11:47
  • Can you advise how to compare azimuths? Also how to assign correct callouts to correct lines when comparing?
    – pazelvak
    Commented Jun 2, 2021 at 12:53
  • You should be able to get the azimuths using the corresponding expression, then substract them, then define a threshold below which you don't want labels to show.
    – Erik
    Commented Jun 2, 2021 at 12:55

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.