Git Product home page Git Product logo

labelconnector's Introduction

Label connector plugin is the successor of EasyCustomLabeling.

The purpose of this plugin is to simplify the drawing of label connectors, also known as callouts.

EasyCustom labeling did a copy of the dataset to be labeled into a line memory layer. LabelConnector will only take profit of the symbology power of geometry generators and auxiliary data to avoid the data duplication.

It is a temporary solution for QGIS 3.4 / 3.6 / 3.8. QGIS 3.10 now has the native feature of drawing callouts.

Connectors in action

labelconnector's People

Contributors

lbartoletti avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

labelconnector's Issues

break styles improvement discussion

Break style currently leads to sometimes weird lines going backwards compared to old easycustomlabeling style:

image

That should probably be improved still I'd like to hear about user's preferences

Easy custom labeling always forced a '45°' heading for the line start, so that all connectors end to be aligned, making a more tidy view. Label connector computes a break at half length of the connector thus leading to different angles between connectors

image

Point de départ (centroid) incorrect pour des lignes.

Si on utilise labelconnector sur des lignes, le point de départ qui est fixé sur le centroid n'est pas correct.
2019-07-03_09h15_54

Il faut utiliser une expression : line_interpolate_point($geometry, line_locate_point($geometry,centroid($geometry)))
comme point de départ.
2019-07-03_09h19_31

version FR vs version US

Les textes des boites de dialogue sont en anglais même si l'interface de QGIS est paramétré en français.
La traduction Anglais/français (fichier metadata.txt) de la phrase de présentation du plugin n'est pas tout à fait équivalente.
La version anglaise
'This plugin creates label connector (line from centroid to the label)'
n'indique pas clairement que les connecteur ne sont créés que pour les étiquettes déplacés manuellement.

Changer le style de connecteur plus simplement

Actuellement si on souhaite changer le style de connecteur il faut d'abord supprimer manuellement le générateur de géométrie de l'ancien connecteur dans le style. Ne serait-il pas possible de poser la question à l'utilisateur en cas de lancement une 2ème fois de labelconnector, puis le cas échéant de supprimer par programme l'ancien générateur, plutôt que d'afficher un message lui demandant de le faire manuellement ?

pb avec ajout a posteriori d'une règle n'affichant pas des étiquettes déplacées

si on ajoute, après avoir déplacé des étiquettes, une règle qui n'affiche plus certaines étiquettes déplacées, le connecteur reste visible. Je pense que ce pb ne doit pas être facile à résoudre.
Au minimum avertir les utilisateurs dans la documentation de déplacer les étiquettes avant ajout de toute règles n'affichant pas toutes les étiquettes.
2019-07-18_16h03_09

Plugin overrides ruled based labeling

Si des étiquettes ont été définies par des règles puis que l'on utilise LabelConnector, les étiquettes reviennent à étiquettes simples et la définition des étiquettes est perdue.

Calling twice LabeConnector shoudn't end in two overlaid connectors

Current logic applies a new geometry generator each time.
We could set tags into the geometry expression so that if a geometry generator is already there, with the tags, the plugin would only replace the expression

It is also a possibility to explain user where the expression comes from :

image

Label styles should have aliases

Currently names are populated from filenames.
We need translatable aliases in full encoded string.

For instance straight should be Straight lines in english and Lignes simples in translation french

Unclear (to me) on how to make this work

Having a simple lin (highway) shape, I thought to test the plugin.

So opened the shape (without saving it to a project...) and added normal labels.
Then tried to change them to 'connected labels' but did not see something happen.
Then removed labels and tried again to use the 'connected labels', but only see this now:

2019-06-21T08:56:57 CRITICAL LabelConnector already exists : If you want to add a new LabelConnector on the style, please remove the comment in the expression first.

BUT: I cannot find "the comment in the expression".
It could also have something to do with not having saved the project first?
Happy to sent you the (demo) shape.

Label settings not applied correctly when source layer is not labeled

When applying label connector to a a layer with no label, the labeling toolbar does not activate itself. I have to play with the settings and then this triggers the activation of the labeling toolbar.
I suspect we need to emit some signal in that case to activate the toolbar.

Labels for overlapping points not displayed correctly.

I'm not certain if this is necessary an issue or a matter of adjusting the label settings, but the labels generated where there are overlapping points are not displayed correctly.
In the example below, I have 2 points at the same location, but I cannot seem to find a way to move the individual labels independently. When I move the label, all overlapping labels are moved at the same time.
image

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.