[Qgis-developer] Labeling gui redesign branch ready

Larry Shaffer larrys at dakotacarto.com
Sat May 18 13:10:03 PDT 2013


Hi,

I think the branch I have been working on for the labeling gui redesign and
expression-based data definitions is ready to merge [0]. Here is the commit
message:

Update labeling gui and add expression support as data defined value
- Add QgsDataDefined class
- Add QgsDataDefinedButton class
- Add data defined Python support
- Add standalone SVG selector dialog to QgsSvgSelectorWidget class
- Fix for #4607, show only pertinent fields when setting a data defined
value
- Fix for #5048 and #5049, data defined settings are literally used
- Fix for #5726, number formatting does not work for expressions
- Fix for #7755, using bufferSize to enable/disable label buffer is
confusing
- Fix for #7779, labels do not register in label collision engine; and for
#4719, inactive options in labeling dialog
- Prepare label text's expression upfront when preparing layer; makes
rendering much faster
- Change name of 'feature obstacles' to appropriate terminology

(Due to my workflow between 3 computers and constant rebasing, my branch
was squashed down to one commit; sorry about that).

I would like to merge this branch sometime this weekend, but will hold off
if someone objects. I can create a pull request if needed.

The goal of this redesign was to add expression-based data definitions,
make a small data defined tool button with visual feedback that can be used
in-line in any form layouts [1, 2], and bring all the new labeling features
to a finished looking state for 2.0. Also, the redesign was done with the
intent that it integrates well with an eventual move to rule-based labels
and styles (2.0 >).

The work was mostly financed through a generous donation by a community
member (thank you for the support).

Notes:

There were 83 labeling data defined options added or updated, with well
over 100 basic label configuration combinations that need unit tests. Full
data defined labeling Python support was just completed in this branch, so
now a complete test suite for can finally be built for labeling. Currently
there are no tests, so anyone who can help manually test this update would
be greatly appreciated.

Enabling a label buffer is no longer triggered by it size. I have added
code to compensate where it was used by older projects. Please let me know
ASAP if there is an issue with any layer-level or data defined buffers in
any new or converted projects.

The implementation of quadrant offset for 'Over point' has be changed to an
enum setup. This feature was not in 1.8, but may have been set by users
working with 1.9 projects. I can add code to update projects from 1.9 to
2.0, but it seemed extraneous given it was a change between releases. Users
with 1.9 projects will have to manually reset quadrant choices.

The code for migrating index-based data defined project settings to
name-based ones was updated. My tests show it is OK, but please contact me
ASAP if you find opening any 1.8 project seems to have issues.

[0] https://github.com/dakcarto/Quantum-GIS/tree/labeling-gui_redesign
[1] http://drive.dakotacarto.com/qgis/labeling-redesign_btn-tool-tip.png
[2] http://drive.dakotacarto.com/qgis/labeling-redesign_btn-menu.png

Regards,

Larry Shaffer
Dakota Cartography
Black Hills, South Dakota
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20130518/2b2c68ad/attachment.html>


More information about the Qgis-developer mailing list