From 6499439cc5c1d0fbc67e96e7126c529a3f10472a Mon Sep 17 00:00:00 2001 From: Nyall Dawson Date: Mon, 11 Jan 2016 11:54:55 +1100 Subject: [PATCH] Fix failing tests, add tests for ordered placement Sponsored by Andreas Neumann --- python/core/qgspallabeling.sip | 27 +- src/core/pal/feature.h | 1 - .../python/test_qgspallabeling_placement.py | 72 +++++ .../sp_point_dd_ordered_placement.png | Bin 0 -> 1200 bytes .../sp_point_dd_ordered_placement_mask.png | Bin 0 -> 1005 bytes .../sp_point_dd_ordered_placement1.png | Bin 0 -> 1368 bytes .../sp_point_dd_ordered_placement1_mask.png | Bin 0 -> 1000 bytes .../sp_point_ordered_placement1.png | Bin 0 -> 1219 bytes .../sp_point_ordered_placement1_mask.png | Bin 0 -> 992 bytes .../sp_point_ordered_placement2.png | Bin 0 -> 1582 bytes .../sp_point_ordered_placement2_mask.png | Bin 0 -> 1007 bytes .../sp_point_ordered_placement3.png | Bin 0 -> 1625 bytes .../sp_point_ordered_placement3_mask.png | Bin 0 -> 1009 bytes .../sp_point_ordered_placement4.png | Bin 0 -> 1661 bytes .../sp_point_ordered_placement4_mask.png | Bin 0 -> 1034 bytes .../testdata/labeling/pal_features_v3.sqlite | Bin 117760 -> 144384 bytes .../labeling/point_ordered_obstacle1.qml | 252 +++++++++++++++++ .../labeling/point_ordered_obstacle2.qml | 252 +++++++++++++++++ .../labeling/point_ordered_obstacle3.qml | 252 +++++++++++++++++ .../labeling/point_ordered_obstacle_top.qml | 252 +++++++++++++++++ .../labeling/point_ordered_placement.qml | 254 ++++++++++++++++++ 21 files changed, 1360 insertions(+), 2 deletions(-) create mode 100644 tests/testdata/control_images/expected_pal_placement/sp_point_dd_ordered_placement/sp_point_dd_ordered_placement.png create mode 100644 tests/testdata/control_images/expected_pal_placement/sp_point_dd_ordered_placement/sp_point_dd_ordered_placement_mask.png create mode 100644 tests/testdata/control_images/expected_pal_placement/sp_point_dd_ordered_placement1/sp_point_dd_ordered_placement1.png create mode 100644 tests/testdata/control_images/expected_pal_placement/sp_point_dd_ordered_placement1/sp_point_dd_ordered_placement1_mask.png create mode 100644 tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement1/sp_point_ordered_placement1.png create mode 100644 tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement1/sp_point_ordered_placement1_mask.png create mode 100644 tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement2/sp_point_ordered_placement2.png create mode 100644 tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement2/sp_point_ordered_placement2_mask.png create mode 100644 tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement3/sp_point_ordered_placement3.png create mode 100644 tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement3/sp_point_ordered_placement3_mask.png create mode 100644 tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement4/sp_point_ordered_placement4.png create mode 100644 tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement4/sp_point_ordered_placement4_mask.png create mode 100644 tests/testdata/labeling/point_ordered_obstacle1.qml create mode 100644 tests/testdata/labeling/point_ordered_obstacle2.qml create mode 100644 tests/testdata/labeling/point_ordered_obstacle3.qml create mode 100644 tests/testdata/labeling/point_ordered_obstacle_top.qml create mode 100644 tests/testdata/labeling/point_ordered_placement.qml diff --git a/python/core/qgspallabeling.sip b/python/core/qgspallabeling.sip index 1c7b6a093e1f..b230361d8e3d 100644 --- a/python/core/qgspallabeling.sip +++ b/python/core/qgspallabeling.sip @@ -100,7 +100,25 @@ class QgsPalLayerSettings Line, /**< Arranges candidates parallel to a generalised line representing the feature or parallel to a polygon's perimeter. Applies to line or polygon layers only. */ Curved, /** Arranges candidates following the curvature of a line feature. Applies to line layers only.*/ Horizontal, /**< Arranges horizontal candidates scattered throughout a polygon feature. Applies to polygon layers only.*/ - Free /**< Arranges candidates scattered throughout a polygon feature. Candidates are rotated to respect the polygon's orientation. Applies to polygon layers only.*/ + Free, /**< Arranges candidates scattered throughout a polygon feature. Candidates are rotated to respect the polygon's orientation. Applies to polygon layers only.*/ + OrderedPositionsAroundPoint, /**< Candidates are placed in predefined positions around a point. Peference is given to positions with greatest cartographic appeal, eg top right, bottom right, etc. Applies to point layers only.*/ + }; + + //! Positions for labels when using the QgsPalLabeling::OrderedPositionsAroundPoint placement mode + enum PredefinedPointPosition + { + TopLeft, //!< Label on top-left of point + TopSlightlyLeft, //! Label on top of point, slightly left of center + TopMiddle, //!< Label directly above point + TopSlightlyRight, //! Label on top of point, slightly right of center + TopRight, //!< Label on top-right of point + MiddleLeft, //!< Label on left of point + MiddleRight, //!< Label on right of point + BottomLeft, //!< Label on bottom-left of point + BottomSlightlyLeft, //! Label below point, slightly left of center + BottomMiddle, //!< Label directly below point + BottomSlightlyRight, //! Label below point, slightly right of center + BottomRight, //!< Label on bottom right of point }; /** Line placement flags, which control how candidates are generated for a linear feature. @@ -304,6 +322,7 @@ class QgsPalLayerSettings RepeatDistance, RepeatDistanceUnit, Priority, + PredefinedPositionOrder, // rendering ScaleVisibility, @@ -437,6 +456,12 @@ class QgsPalLayerSettings bool centroidWhole; // whether centroid calculated from whole or visible polygon bool centroidInside; // whether centroid-point calculated must be inside polygon + /** Ordered list of predefined label positions for points. Positions earlier + * in the list will be prioritised over later positions. Only used when the placement + * is set to QgsPalLayerSettings::OrderedPositionsAroundPoint. + */ + QVector< QgsPalLayerSettings::PredefinedPointPosition > predefinedPositionOrder; + /** True if only labels which completely fit within a polygon are allowed. */ bool fitInPolygonOnly; diff --git a/src/core/pal/feature.h b/src/core/pal/feature.h index e84147fc6916..b7db33afe376 100644 --- a/src/core/pal/feature.h +++ b/src/core/pal/feature.h @@ -147,7 +147,6 @@ namespace pal * @param y y coordinate of the point * @param lPos pointer to an array of candidates, will be filled by generated candidate * @param angle orientation of the label - * @param mapShape optional geometry of source polygon * @returns the number of generated candidates */ int createCandidatesAtOrderedPositionsOverPoint( double x, double y, QList &lPos, double angle ); diff --git a/tests/src/python/test_qgspallabeling_placement.py b/tests/src/python/test_qgspallabeling_placement.py index a114abfe8eab..82005c61483b 100644 --- a/tests/src/python/test_qgspallabeling_placement.py +++ b/tests/src/python/test_qgspallabeling_placement.py @@ -185,6 +185,78 @@ def test_multipolygon_obstacle(self): self.removeMapLayer(polyLayer) self.layer = None + def test_point_ordered_placement1(self): + # Test ordered placements for point + self.layer = TestQgsPalLabeling.loadFeatureLayer('point_ordered_placement') + self._TestMapSettings = self.cloneMapSettings(self._MapSettings) + self.lyr.placement = QgsPalLayerSettings.OrderedPositionsAroundPoint + self.lyr.dist = 2 + self.checkTest() + self.removeMapLayer(self.layer) + self.layer = None + + def test_point_ordered_placement2(self): + # Test ordered placements for point (1 obstacle) + self.layer = TestQgsPalLabeling.loadFeatureLayer('point_ordered_placement') + obstacleLayer = TestQgsPalLabeling.loadFeatureLayer('point_ordered_obstacle1') + self._TestMapSettings = self.cloneMapSettings(self._MapSettings) + self.lyr.placement = QgsPalLayerSettings.OrderedPositionsAroundPoint + self.lyr.dist = 2 + self.checkTest() + self.removeMapLayer(obstacleLayer) + self.removeMapLayer(self.layer) + self.layer = None + + def test_point_ordered_placement3(self): + # Test ordered placements for point (2 obstacle) + self.layer = TestQgsPalLabeling.loadFeatureLayer('point_ordered_placement') + obstacleLayer = TestQgsPalLabeling.loadFeatureLayer('point_ordered_obstacle2') + self._TestMapSettings = self.cloneMapSettings(self._MapSettings) + self.lyr.placement = QgsPalLayerSettings.OrderedPositionsAroundPoint + self.lyr.dist = 2 + self.checkTest() + self.removeMapLayer(obstacleLayer) + self.removeMapLayer(self.layer) + self.layer = None + + def test_point_ordered_placement4(self): + # Test ordered placements for point (3 obstacle) + self.layer = TestQgsPalLabeling.loadFeatureLayer('point_ordered_placement') + obstacleLayer = TestQgsPalLabeling.loadFeatureLayer('point_ordered_obstacle3') + self._TestMapSettings = self.cloneMapSettings(self._MapSettings) + self.lyr.placement = QgsPalLayerSettings.OrderedPositionsAroundPoint + self.lyr.dist = 2 + self.checkTest() + self.removeMapLayer(obstacleLayer) + self.removeMapLayer(self.layer) + self.layer = None + + def test_point_dd_ordered_placement(self): + # Test ordered placements for point with data defined order + self.layer = TestQgsPalLabeling.loadFeatureLayer('point_ordered_placement') + self._TestMapSettings = self.cloneMapSettings(self._MapSettings) + self.lyr.placement = QgsPalLayerSettings.OrderedPositionsAroundPoint + self.lyr.dist = 2 + self.lyr.setDataDefinedProperty(QgsPalLayerSettings.PredefinedPositionOrder, True, True, "'T,B'", None) + self.checkTest() + self.removeMapLayer(self.layer) + self.lyr.removeDataDefinedProperty(QgsPalLayerSettings.PredefinedPositionOrder) + self.layer = None + + def test_point_dd_ordered_placement1(self): + # Test ordered placements for point with data defined order and obstacle + self.layer = TestQgsPalLabeling.loadFeatureLayer('point_ordered_placement') + obstacleLayer = TestQgsPalLabeling.loadFeatureLayer('point_ordered_obstacle_top') + self._TestMapSettings = self.cloneMapSettings(self._MapSettings) + self.lyr.placement = QgsPalLayerSettings.OrderedPositionsAroundPoint + self.lyr.dist = 2 + self.lyr.setDataDefinedProperty(QgsPalLayerSettings.PredefinedPositionOrder, True, True, "'T,B'", None) + self.checkTest() + self.removeMapLayer(obstacleLayer) + self.removeMapLayer(self.layer) + self.lyr.removeDataDefinedProperty(QgsPalLayerSettings.PredefinedPositionOrder) + self.layer = None + if __name__ == '__main__': # NOTE: unless PAL_SUITE env var is set all test class methods will be run # SEE: test_qgspallabeling_tests.suiteTests() to define suite diff --git a/tests/testdata/control_images/expected_pal_placement/sp_point_dd_ordered_placement/sp_point_dd_ordered_placement.png b/tests/testdata/control_images/expected_pal_placement/sp_point_dd_ordered_placement/sp_point_dd_ordered_placement.png new file mode 100644 index 0000000000000000000000000000000000000000..f2b0f3fb855dc3c7dcb514a487407b4b38ee0a43 GIT binary patch literal 1200 zcmeAS@N?(olHy`uVBq!ia0y~yU|a&k5*%zm5n-1mYaqpz|H(?D8gCb z5n0T@z%2yAjF;}#{Q(NHmw5WRvOi$tW|kC+;;Wp+z`$bb>EaktaqI0Zdq0sxhGP%Q zc@*6wlGDVKl3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mZOIenmc$-+V*OVt{ zY(4n!%$~e;G1+^v(!TE#WS3rWm)-XNgax*tS5NI-ef(4Dqhc@3n|t$Bw!eDM!wl4v z{B!<9bLAI3$@ecPDl$1flK=kOU%Juv<+JJ2-2_yw%|2|uPNLEG>ES+iw;Kv`HZfB% zVWUPVa=wYk-!?Ph@r&QJ2FADTrJ8)p?{7Aovhm~6Q#=f7Oy|F$PQJph9^y5c d-{AX3pDlA%l!l1*Y+xD4;OXk;vd$@?2>{IBb#VXy literal 0 HcmV?d00001 diff --git a/tests/testdata/control_images/expected_pal_placement/sp_point_dd_ordered_placement1/sp_point_dd_ordered_placement1_mask.png b/tests/testdata/control_images/expected_pal_placement/sp_point_dd_ordered_placement1/sp_point_dd_ordered_placement1_mask.png new file mode 100644 index 0000000000000000000000000000000000000000..1839d8962e06ab772aef3a881fef4a510201ea8c GIT binary patch literal 1000 zcmeAS@N?(olHy`uVBq!ia0y~yU|a&k5*%zm5n-1mYaqpz|H(?D8gCb z5n0T@z%2yAjF;}#{Q(NHmw5WRvOi$tW|kJq553RGz`$JU>EaktaqI2fjl2gGcw8N= zlm1Vg%ll{vhev_=q5OF<3Pws=3<(=gvoLT7flw0*5H%<;0+E6T0}xR~m|EuGa170i zr#uu6Tx;XJw^B=)VSdUo!5A`vQ|AG9an$nq!#0n9|B^MIw^3S8g+V}tfrS%<9GQT~ zVFCjXS#-B=ykPM+(O|~}kUXjqxGD@8h-MtZH_jR`&Ru21^uP&f35GgMgXg8V{CLC0 zAWp;7#4(8z(~EdLg5hqws)3TEX+Txo@c+&SDFIW1482dlJjvkc>gTe~DWM4fef6=t literal 0 HcmV?d00001 diff --git a/tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement1/sp_point_ordered_placement1.png b/tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement1/sp_point_ordered_placement1.png new file mode 100644 index 0000000000000000000000000000000000000000..1ae9e0f15f04546982d6b861f17d366fdcaab9a2 GIT binary patch literal 1219 zcmeAS@N?(olHy`uVBq!ia0y~yU|a&k5*%zm5n-1mYaqpz|H(?D8gCb z5n0T@z%2yAjF;}#{Q(NHmw5WRvOi$tW-{lzweE5*0|QHdr;B4q#jUru_IpJa${c(6 z-jj8?)fO|QK*K13<4QN2yv^Sqba=m@FKp7V$!vx zdR(^0b%PhEP83!=Z~X6p&ihZ6|0lhDRVv0{kiaU;px^;Q96}(}!~#SO3XDKR6=7Cc+?vaSzTiNtTuD*Uukj(^>< zq}=ZZ3@#|w-*oJsv_v4=x_xfG+q@o!2?+~!wPt)uGn}<}`LVa_bYYxMA>g^>bP0l+XkK D!8|H(?D8gCb z5n0T@z%2yAjF;}#{Q(NHmw5WRvOi$tX0ldwIsBoCfq^;K)5S5Q;?~={hFlE>0xlP0 zPyStRGtYrXLiEdCtE*=7S6&L8%G5AD*N>q=ff0xlJQ#q8LkNVLSb&Hs!qhSchhu1A z{GaOuOcv9Q2p(`^a+tsXL;@-x#KH+hj!X=WSY#ZT8Y=60T3dJB7Tj_6dcDCmRE;=w zp&4eEYQeZ>@{=#V<<=q*9t;s42flPMaf9s!8-b=A;wqemH@x1p>Jbmn6k5bBa-7g0 m=|GGJlC(*gR5bp8aG9aKfPVVbxR1cR$l&Sf=d#Wzp$Pz{^R;>a literal 0 HcmV?d00001 diff --git a/tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement2/sp_point_ordered_placement2.png b/tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement2/sp_point_ordered_placement2.png new file mode 100644 index 0000000000000000000000000000000000000000..662fc2fb5ddc07c0dc17839ebe6bd35589fe6d6f GIT binary patch literal 1582 zcmeAS@N?(olHy`uVBq!ia0y~yU|a&k5*%zm5n-1mYaqpz|H(?D8gCb z5n0T@z%2yAjF;}#{Q(NHmw5WRvOi$tX0ouXe*d43fq`|mr;B4q#jUru&SzgQWjOxv zdODYoOZ(Q^EAB`#ZkRXi`7BL6`--TUObuVJ zB{DIvaDtE{6A(E}U;rWk6%e9|FtyCV;TW13j~ojB@_v7=JJ9-zQG3(VFE+2we>k*4 zF+rJC)01r;PxK_+rCT4*6MVq>`2-*3VR$1(Y}Vz-oU;;5zNx!8AN*gebvj1MZpzY~ z?JG|iZQW;UX;x>e$@TaFA7{q=i^}brx9`)RKX2dc&FN~FU&x)fabiNEfXaeekQp^5 zvk(3~9=={y#%AL2;P0DluA2xnv21Y<6j^!dQ~dg7g@a)`jc+orbL=X6=a(C_dh4C7WofCB>&CkOpZj9> zPTV+gVa=bL(VAUKw!Qyk_7HU8mWPY`gFIZTo!0g|qdve;PTZQ_Y-}^6l zG3Wfb^4*hF&RT!Ixh?4Y$&a0-|Lf}a8W*J>NqaO=cFnvp zx_bib9Kh6{)B<#F;I#iWJ037FatLj?>aD+jQdGS1TI#3_!#o1VT+LK-8eX2t-s7rj|K4978kXsT&Fyu4nMP zwDHEQjZ6%$vld#;U9@`l`c+@wp4|BHwP#=iYr{5R+MnLWpPKnD(dyj1nLdlF6@X>h zG{yyM-TGzD-TSq#rs~(b`R^z2@y$E&c;)ZNdD&6y4cj6z{L(*O%whX3??34eBTLSe VbH_!*T7V@xgQu&X%Q~loCIDoC0e%1g literal 0 HcmV?d00001 diff --git a/tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement2/sp_point_ordered_placement2_mask.png b/tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement2/sp_point_ordered_placement2_mask.png new file mode 100644 index 0000000000000000000000000000000000000000..2049ffffe00b0c420972302d1a79277c714a7fd4 GIT binary patch literal 1007 zcmeAS@N?(olHy`uVBq!ia0y~yU|a&k5*%zm5n-1mYaqpz|H(?D8gCb z5n0T@z%2yAjF;}#{Q(NHmw5WRvOi$tX0kGM$iKLpfq}Wk)5S5Q;?~9!L-&Ij5+ zb|2{5&mj1)k)Hu*3CuUtiBpugPzEI%TBIDXEwoFRv^0KQ6(f&@uvv+dL?tk5GI+ZB KxvX|H(?D8gCb z5n0T@z%2yAjF;}#{Q(NHmw5WRvOi$tX0kTXE51;`z`**<)5S5Q;?~>S_p`5-${hcA z{d&u~U6Hp_WX#O_7wq2L{btb{H>s5yqJwYMKj6BFY;2 zLP867D@xCvXQ}qPG}xT2c7LqP;sbhfD$hN!k((}WVQ}xwoadGG`|k(WRF!gny?i6<@%>oUy8AYh zRW#$?zFA%Ms@byOW7kWD3o)TnH%@$b#>JvSi9{U z2ZMkL2(fU2kRuZiIZR*xBB}^e%N!hzp_%d24Fv&}jIFK5Ld4RS@iN^yQKg)qyYiIL z^KWm@U3$|Tk~;I*V<}2Pb*r<5$bGV4>s!cVIEX{maIA<-} zT&{3e`t{Db&u32E+$z2Na*zOFz6!*GxF# zt+?&?2??dER-JkNe*aAO$=`!ST+MQBO;Vm-ZzKVXjb3$IhYzlAWt$i3)*Af2yDI*5 zxyOf|f3Jn^evAJu$(Q@|dHBAnW!HDNvmBVE;K9Hl1VT+LK-8eX2t+_JY6(Nk`E$5R zx#55O`S;B;D}RbNFL?X!{e0KL#7BjxJq%lBd6&__2{iU0wTyo&vE=B?%wUEEOU0yu zHLZ64S`E)W%a|N41G7`{@3QpFZ;sdI+LW1pUH4W}TGC9CVb-fZ|7>qY-JU4y{{BxX zf9CZI8PC*?Z??H@Aj>c-X`$iNqwU{~w|p*`^u&M3O}^^|dJba1N`S%B)z4*}Q$iB} Dq*xZ5 literal 0 HcmV?d00001 diff --git a/tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement3/sp_point_ordered_placement3_mask.png b/tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement3/sp_point_ordered_placement3_mask.png new file mode 100644 index 0000000000000000000000000000000000000000..bce256d4facfee239d635e63d47f2e4e8d077710 GIT binary patch literal 1009 zcmeAS@N?(olHy`uVBq!ia0y~yU|a&k5*%zm5n-1mYaqpz|H(?D8gCb z5n0T@z%2yAjF;}#{Q(NHmw5WRvOi$tW@a!D$(xwQz`$JR>EaktaqI0}L#_h~JPsF^ zRQ%UoUfr&gA^N78{l$c*!h*8}0~r}+$GR~zC@=z%f(HW-aR`A>6AKVgMVMOV;BXA> zjHhZS09}6|>nz8OrK{TZPn^ldX{N#;pu)iS_yk|v8H+HM9DLz^=IKj?Z6AZo6P%eG zCNKaIP$v+va57Zw_{Ph<+zgq1;7BHK!tacEA( g8ww=Y`anI8=cRz9M~=mMVCH1-boFyt=akR{00j87HUIzs literal 0 HcmV?d00001 diff --git a/tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement4/sp_point_ordered_placement4.png b/tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement4/sp_point_ordered_placement4.png new file mode 100644 index 0000000000000000000000000000000000000000..515128e18a470d85e1ab7195756ae3cdf0d2f85d GIT binary patch literal 1661 zcmeAS@N?(olHy`uVBq!ia0y~yU|a&k5*%zm5n-1mYaqpz|H(?D8gCb z5n0T@z%2yAjF;}#{Q(NHmw5WRvOi$tW@coKK9<4))X3%O;uunK>+Ri*{-Na(#~;4m zdGy5%AuU0st{DMlotd*EOcP%`c(TAj^{$EUEI+m*+D)$cd`e%)+gEGv8kqU4{nV2m1=GZz1&O%s`o(^P!?9`ZyH_{b zHE)GqDt`1=#q;YuuX{fiTZh-}$Uoeo`+vA(?h&fj-p?DGSw56+4ItJf*c@xZrI`TyJBi|?PGt+LxI z_x<9t>svYQ@tmK)AfWQ#ZNVRw+Y_08C9oGBP&89nplVUatNj{29CgeN{9Zpx{6U^B%*KSMU zVlcUyRch#ZzWQzI^M%SgEleke==d<0`0d;{F?zB3=SMd$hs^8gd0G-}WNDXU#9(se z$c>eAZf;laKi~WBE6>YM7dGnXpGmFVnPtUbas+5n_SU5_R#sC~ehQzh_q2^kUK$Im PC>T6l{an^LB{Ts5gf%0* literal 0 HcmV?d00001 diff --git a/tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement4/sp_point_ordered_placement4_mask.png b/tests/testdata/control_images/expected_pal_placement/sp_point_ordered_placement4/sp_point_ordered_placement4_mask.png new file mode 100644 index 0000000000000000000000000000000000000000..fce37f2a3c4dbba1476b9b3a8fd456e653f432ac GIT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Xj;o`+ZO{WucS)*C?mSYKDVa!<~t0SR{i_bAx!_SqZ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0 + 0 + 0 + pkuid + + + + + + + + + + + + + + + + 0 + + + 0 + generatedlayout + + + + + + diff --git a/tests/testdata/labeling/point_ordered_obstacle2.qml b/tests/testdata/labeling/point_ordered_obstacle2.qml new file mode 100644 index 000000000000..7310a3b7cb52 --- /dev/null +++ b/tests/testdata/labeling/point_ordered_obstacle2.qml @@ -0,0 +1,252 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0 + 0 + 0 + pkuid + + + + + + + + + + + + + + + + 0 + + + 0 + generatedlayout + + + + + + diff --git a/tests/testdata/labeling/point_ordered_obstacle3.qml b/tests/testdata/labeling/point_ordered_obstacle3.qml new file mode 100644 index 000000000000..b673be303c72 --- /dev/null +++ b/tests/testdata/labeling/point_ordered_obstacle3.qml @@ -0,0 +1,252 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0 + 0 + 0 + pkuid + + + + + + + + + + + + + + + + 0 + + + 0 + generatedlayout + + + + + + diff --git a/tests/testdata/labeling/point_ordered_obstacle_top.qml b/tests/testdata/labeling/point_ordered_obstacle_top.qml new file mode 100644 index 000000000000..59248aea60ab --- /dev/null +++ b/tests/testdata/labeling/point_ordered_obstacle_top.qml @@ -0,0 +1,252 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0 + 0 + 0 + pkuid + + + + + + + + + + + + + + + + 0 + + + 0 + generatedlayout + + + + + + diff --git a/tests/testdata/labeling/point_ordered_placement.qml b/tests/testdata/labeling/point_ordered_placement.qml new file mode 100644 index 000000000000..a8095ebc94bc --- /dev/null +++ b/tests/testdata/labeling/point_ordered_placement.qml @@ -0,0 +1,254 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0 + 0 + 0 + pkuid + + + + + + + + + + + + + + + + 0 + + + 0 + generatedlayout + + + + + +