[Qgis-developer] Request for API change [will merge if ni claim before Aug. 26th]
Denis Rouzaud
denis.rouzaud at gmail.com
Tue Aug 19 06:19:36 PDT 2014
Hi all,
With Matthias' work on the new edit widgets, we have some wrappers that
allow using some Qt widgets as edit widgets but also some custom widgets
(relation reference, color button, etc.).
At first, the wrapper classes were named as widgets (e.g.
QgsColorWidget). But these are not really the widgets.
This brings some confusion and some naming conflicts:
1. QgsColorWidget inherits from QgsEditorWidgetWrapper. It should be
named according to its functionnality.
2. We have a naming conflict: if we create a class for the widget, we
can't name it properly as the name Widget is already taken.
Hence, I proposed [0] to rename the widgets to wrappers.
This breaks C++ API but not Python since widgets/wrappers are not
available yet.
This code was brought in 2.4.
I am quite sure nobody used this part of the API.
I know API should not be changed, and if we start making exception if
can be a mess. But considering that:
* it's a very narrow part of the code
* that it's not available in python
* it improves the readability
* it will avoid naming problems in the future
I am asking for this change.
If nobody claims something before August 26th, the pull request [0] will
be merged.
Greetings,
Denis
[0] https://github.com/qgis/QGIS/pull/1545
More information about the Qgis-developer
mailing list