Skip to content
Permalink
Browse files

Add relations capabilites and widgets

  • Loading branch information
m-kuhn committed Oct 4, 2013
1 parent fb32966 commit dc3b56a13cd50ecd5337724bebb9036a96e8c51d
Showing with 4,135 additions and 164 deletions.
  1. +4 −0 images/images.qrc
  2. +4 −4 images/themes/default/mActionAdd.svg
  3. +74 −0 images/themes/default/mActionLink.svg
  4. +193 −0 images/themes/default/mActionRemove.svg
  5. +122 −0 images/themes/default/mActionUnlink.svg
  6. +605 −0 images/themes/default/relation.svg
  7. +2 −1 python/core/core.sip
  8. +171 −0 python/core/qgsrelation.sip
  9. +3 −2 python/gui/qgsattributedialog.sip
  10. +11 −0 src/app/qgisapp.cpp
  11. +7 −2 src/app/qgisappinterface.cpp
  12. +30 −9 src/app/qgisappinterface.h
  13. +60 −0 src/app/qgsfieldsproperties.cpp
  14. +13 −0 src/app/qgsfieldsproperties.h
  15. +19 −0 src/app/qgsprojectproperties.cpp
  16. +2 −0 src/app/qgsprojectproperties.h
  17. +5 −0 src/core/CMakeLists.txt
  18. +3 −3 src/core/qgsfeaturerequest.cpp
  19. +0 −1 src/core/qgsfeaturerequest.h
  20. +19 −10 src/core/qgsproject.cpp
  21. +11 −6 src/core/qgsproject.h
  22. +258 −0 src/core/qgsrelation.cpp
  23. +227 −0 src/core/qgsrelation.h
  24. +172 −0 src/core/qgsrelationmanager.cpp
  25. +66 −0 src/core/qgsrelationmanager.h
  26. +18 −11 src/core/qgsvectordataprovider.h
  27. +47 −0 src/core/qgsvectorlayer.cpp
  28. +56 −0 src/core/qgsvectorlayer.h
  29. +3 −2 src/core/qgsvectorlayercache.cpp
  30. +10 −1 src/core/qgsvectorlayercache.h
  31. +71 −50 src/gui/CMakeLists.txt
  32. +2 −4 src/gui/editorwidgets/core/qgseditorwidgetregistry.cpp
  33. +1 −1 src/gui/editorwidgets/core/qgseditorwidgetregistry.h
  34. +59 −0 src/gui/editorwidgets/qgsrelationreferencefactory.cpp
  35. +79 −0 src/gui/editorwidgets/qgsrelationreferencefactory.h
  36. +202 −0 src/gui/editorwidgets/qgsrelationreferencewidget.cpp
  37. +63 −0 src/gui/editorwidgets/qgsrelationreferencewidget.h
  38. +78 −0 src/gui/editorwidgets/qgsrelreferenceconfigdlg.cpp
  39. +35 −0 src/gui/editorwidgets/qgsrelreferenceconfigdlg.h
  40. +19 −11 src/gui/qgisinterface.h
  41. +19 −2 src/gui/qgsattributedialog.cpp
  42. +21 −8 src/gui/qgsattributedialog.h
  43. +13 −1 src/gui/qgsattributeeditor.cpp
  44. +2 −1 src/gui/qgsattributeeditor.h
  45. +40 −0 src/gui/qgsfeatureselectiondlg.cpp
  46. +37 −0 src/gui/qgsfeatureselectiondlg.h
  47. +79 −0 src/gui/qgsrelationadddlg.cpp
  48. +36 −0 src/gui/qgsrelationadddlg.h
  49. +183 −0 src/gui/qgsrelationeditor.cpp
  50. +60 −0 src/gui/qgsrelationeditor.h
  51. +154 −0 src/gui/qgsrelationmanagerdialog.cpp
  52. +50 −0 src/gui/qgsrelationmanagerdialog.h
  53. +2 −1 src/ui/CMakeLists.txt
  54. +55 −0 src/ui/editorwidgets/qgsrelreferenceconfigdlgbase.ui
  55. +12 −14 src/ui/qgsattributetabledialog.ui
  56. +78 −0 src/ui/qgsfeatureselectiondlg.ui
  57. +22 −6 src/ui/qgsfieldspropertiesbase.ui
  58. +29 −13 src/ui/qgsprojectpropertiesbase.ui
  59. +128 −0 src/ui/qgsrelationadddlgbase.ui
  60. +182 −0 src/ui/qgsrelationeditorwidgetbase.ui
  61. +109 −0 src/ui/qgsrelationmanagerdialogbase.ui
@@ -438,6 +438,10 @@
<file>flags/nb_NO.png</file>
<file>flags/gl.png</file>
<file>flags/hi.png</file>
<file>themes/default/relation.svg</file>
<file>themes/default/mActionLink.svg</file>
<file>themes/default/mActionUnlink.svg</file>
<file>themes/default/mActionRemove.svg</file>
</qresource>
<qresource prefix="/images/tips">
<file alias="symbol_levels.png">qgis_tips/symbol_levels.png</file>
@@ -14,7 +14,7 @@
id="svg5692"
version="1.1"
inkscape:version="0.48.4 r9939"
sodipodi:docname="mActionAddDelimitedTextLayer.svg"
sodipodi:docname="mActionAdd.svg"
inkscape:export-filename="/media/home1/robert/svn/graphics/trunk/toolbar-icons/32x32/layer-vector.png"
inkscape:export-xdpi="90"
inkscape:export-ydpi="90">
@@ -80,7 +80,7 @@
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="15.937501"
inkscape:cx="-5.5360852"
inkscape:cx="-5.410595"
inkscape:cy="11.532645"
inkscape:current-layer="layer2"
showgrid="true"
@@ -90,7 +90,7 @@
inkscape:window-width="1231"
inkscape:window-height="858"
inkscape:window-x="683"
inkscape:window-y="115"
inkscape:window-y="867"
inkscape:window-maximized="0"
inkscape:snap-global="true"
showguides="true"
@@ -162,7 +162,7 @@
transform="translate(0,-8)">
<g
id="g3772"
transform="matrix(1.8506786,0,0,1.8506786,-35.158971,-27.158972)">
transform="matrix(1.6141779,0,0,1.6141779,-29.159575,-21.159576)">
<rect
ry="2.6149368"
inkscape:export-ydpi="120"
@@ -0,0 +1,74 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->

<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="24"
height="24"
id="svg3072"
version="1.1"
inkscape:version="0.48.4 r9939"
sodipodi:docname="New document 1">
<defs
id="defs3074" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="22.4"
inkscape:cx="8.6107244"
inkscape:cy="15.703898"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1920"
inkscape:window-height="1021"
inkscape:window-x="0"
inkscape:window-y="867"
inkscape:window-maximized="1" />
<metadata
id="metadata3077">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1028.3622)">
<rect
style="color:#000000;fill:none;stroke:#c4a000;stroke-width:1;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
id="rect2902"
width="10.839286"
height="4.098249"
x="2.4375007"
y="1038.1122"
rx="2.6428566"
ry="2.0491245" />
<rect
style="color:#000000;fill:none;stroke:#c4a000;stroke-width:1;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
id="rect2902-3"
width="10.839286"
height="4.098249"
x="10.964286"
y="1038.1345"
rx="2.6428566"
ry="2.0491245" />
</g>
</svg>
@@ -0,0 +1,193 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->

<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="24"
height="24"
id="svg5692"
version="1.1"
inkscape:version="0.48.4 r9939"
sodipodi:docname="mActionRemove.svg"
inkscape:export-filename="/media/home1/robert/svn/graphics/trunk/toolbar-icons/32x32/layer-vector.png"
inkscape:export-xdpi="90"
inkscape:export-ydpi="90">
<title
id="title2829">GIS icon theme 0.2</title>
<defs
id="defs5694">
<inkscape:perspective
sodipodi:type="inkscape:persp3d"
inkscape:vp_x="0 : 16 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_z="32 : 16 : 1"
inkscape:persp3d-origin="16 : 10.666667 : 1"
id="perspective3486" />
<inkscape:perspective
id="perspective3496"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective3600"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective7871"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective8710"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective9811"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective4762"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
</defs>
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="15.937501"
inkscape:cx="-5.410595"
inkscape:cy="11.532645"
inkscape:current-layer="layer2"
showgrid="true"
inkscape:grid-bbox="true"
inkscape:document-units="px"
borderlayer="false"
inkscape:window-width="1231"
inkscape:window-height="858"
inkscape:window-x="687"
inkscape:window-y="867"
inkscape:window-maximized="0"
inkscape:snap-global="true"
showguides="true"
inkscape:guide-bbox="true"
inkscape:snap-object-midpoints="true"
inkscape:snap-grids="false">
<inkscape:grid
type="xygrid"
id="grid5700"
empspacing="5"
visible="true"
enabled="true"
snapvisiblegridlinesonly="true"
dotted="true"
originx="2.5px"
originy="2.5px" />
</sodipodi:namedview>
<metadata
id="metadata5697">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title>GIS icon theme 0.2</dc:title>
<dc:creator>
<cc:Agent>
<dc:title>Robert Szczepanek</dc:title>
</cc:Agent>
</dc:creator>
<dc:rights>
<cc:Agent>
<dc:title>Robert Szczepanek</dc:title>
</cc:Agent>
</dc:rights>
<dc:subject>
<rdf:Bag>
<rdf:li>GIS icons</rdf:li>
</rdf:Bag>
</dc:subject>
<dc:coverage>GIS icons</dc:coverage>
<dc:description>http://robert.szczepanek.pl/</dc:description>
<cc:license
rdf:resource="http://creativecommons.org/licenses/by-sa/3.0/" />
</cc:Work>
<cc:License
rdf:about="http://creativecommons.org/licenses/by-sa/3.0/">
<cc:permits
rdf:resource="http://creativecommons.org/ns#Reproduction" />
<cc:permits
rdf:resource="http://creativecommons.org/ns#Distribution" />
<cc:requires
rdf:resource="http://creativecommons.org/ns#Notice" />
<cc:requires
rdf:resource="http://creativecommons.org/ns#Attribution" />
<cc:permits
rdf:resource="http://creativecommons.org/ns#DerivativeWorks" />
<cc:requires
rdf:resource="http://creativecommons.org/ns#ShareAlike" />
</cc:License>
</rdf:RDF>
</metadata>
<g
inkscape:groupmode="layer"
id="layer2"
inkscape:label="Layer"
style="display:inline"
transform="translate(0,-8)">
<g
id="layer1"
transform="matrix(2.0979294,0,0,2.0979294,-27.846021,-36.723572)">
<g
id="g8247">
<path
style="opacity:0.9;fill:#cc0000;stroke:#cc0000;stroke-linecap:square;stroke-linejoin:round"
inkscape:connector-curvature="0"
d="m 15.143,22.5 h 7.715 c 0.354,0 0.643,0.288 0.643,0.643 v 7.715 c 0,0.354 -0.288,0.643 -0.643,0.643 h -7.715 c -0.354,0 -0.643,-0.288 -0.643,-0.643 v -7.715 c 0,-0.355 0.288,-0.643 0.643,-0.643 z"
enable-background="new "
id="rect10143-0-5" />
<path
style="opacity:0.3;fill:#fcffff"
inkscape:connector-curvature="0"
d="m 14.5,27 h 9 v -3 c 0,-1.5 0,-1.5 -2.25,-1.5 -0.523,0 -4.555,0 -5.25,0 -1.5,0 -1.5,0 -1.5,1.5 0,0.75 0,1.5 0,3 z"
enable-background="new "
id="path10149-9-8" />
<path
style="fill:#5c3566;stroke:#eeeeec;stroke-width:1.70560002;stroke-linecap:round"
inkscape:connector-curvature="0"
d="m 16,24 6.001,6"
id="path13835-7" />
<path
style="fill:#5c3566;stroke:#eeeeec;stroke-width:1.70560002;stroke-linecap:round"
inkscape:connector-curvature="0"
d="m 16,30 6.001,-6"
id="path8245" />
</g>
</g>
</g>
</svg>

0 comments on commit dc3b56a

Please sign in to comment.
You can’t perform that action at this time.