Feature request #3226
Patch to show number of features per class in legend
|Pull Request or Patch supplied:||Yes||Resolution:||fixed|
|Easy fix?:||No||Copied to github as #:||13286|
The following patch adds the capability of showing the number of features per class in the legend (updated after symbology change or attribute edit). To enable this feature, select the check box in the options dialog (general->show number of features in legend).
But I'm not sure if it is good to set that in the option or if it would be better to store it in the vectorlayer and expose through the vector property dialog. Because for large layers, it might take some time to update the feature count.
What do you think about it?
#1 Updated by Tim Sutton almost 11 years ago
I tested out your patch - cool addition! Yes I agree it is probably better to add as a general property of the layer - I tested with a large dataset and it seemed to spend a significant amount of time updating feature counts.
On a purely cosmetic level it might be nicer to put the counts in square brackets after the class name e.g.
#6 Updated by Mayeul Kauffmann over 10 years ago
Replying to [comment:5 pcav]:
I just saw your question after opening bug #3737.
Yes, there is still this bug for rule-based rendering.
(I'm not sure whether it's best to convert the patch into a bug or to open a new bug, please close one of the two if you wish).