rute 0.0.6

UI library implemented on top of Qt
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787

// This file is auto-generated by rute_gen. DO NOT EDIT.
use std::cell::Cell;
use std::rc::Rc;

#[allow(unused_imports)]
use std::marker::PhantomData;

#[allow(unused_imports)]
use std::os::raw::c_void;

#[allow(unused_imports)]
use std::mem::transmute;

#[allow(unused_imports)]
use std::ffi::{CString, CStr};

use rute_ffi_base::*;

#[allow(unused_imports)]
use auto::*;


/// 
/// A painter path is an object composed of a number of graphical
/// building blocks, such as rectangles, ellipses, lines, and curves.
/// Building blocks can be joined in closed subpaths, for example as a
/// rectangle or an ellipse. A closed path has coinciding start and
/// end points. Or they can exist independently as unclosed subpaths,
/// such as lines and curves.
/// 
/// A QPainterPath object can be used for filling, outlining, and
/// clipping. To generate fillable outlines for a given painter path,
/// use the QPainterPathStroker class. The main advantage of painter
/// paths over normal drawing operations is that complex shapes only
/// need to be created once; then they can be drawn many times using
/// only calls to the QPainter::drawPath() function.
/// 
/// QPainterPath provides a collection of functions that can be used
/// to obtain information about the path and its elements. In addition
/// it is possible to reverse the order of the elements using the
/// toReversed() function. There are also several functions to convert
/// this painter path object into a polygon representation.
/// 
/// # Composing a QPainterPath
/// 
/// A QPainterPath object can be constructed as an empty path, with a
/// given start point, or as a copy of another QPainterPath object.
/// Once created, lines and curves can be added to the path using the
/// lineTo(), arcTo(), cubicTo() and quadTo() functions. The lines and
/// curves stretch from the currentPosition() to the position passed
/// as argument.
/// 
/// The currentPosition() of the QPainterPath object is always the end
/// position of the last subpath that was added (or the initial start
/// point). Use the moveTo() function to move the currentPosition()
/// without adding a component. The moveTo() function implicitly
/// starts a new subpath, and closes the previous one. Another way of
/// starting a new subpath is to call the closeSubpath() function
/// which closes the current path by adding a line from the
/// currentPosition() back to the path's start position. Note that the
/// new path will have (0, 0) as its initial currentPosition().
/// 
/// QPainterPath class also provides several convenience functions to
/// add closed subpaths to a painter path: addEllipse(), addPath(),
/// addRect(), addRegion() and addText(). The addPolygon() function
/// adds an *unclosed* subpath. In fact, these functions are all
/// collections of moveTo(), lineTo() and cubicTo() operations.
/// 
/// In addition, a path can be added to the current path using the
/// connectPath() function. But note that this function will connect
/// the last element of the current path to the first element of given
/// one by adding a line.
/// 
/// Below is a code snippet that shows how a QPainterPath object can
/// be used:
/// 
/// * ![qpainterpath-construction.png](qpainterpath-construction.png)
/// 
/// 
/// 
/// The painter path is initially empty when constructed. We first add
/// a rectangle, which is a closed subpath. Then we add two bezier
/// curves which together form a closed subpath even though they are
/// not closed individually. Finally we draw the entire path. The path
/// is filled using the default fill rule, Qt::OddEvenFill. Qt
/// provides two methods for filling paths:
/// 
/// * Qt::OddEvenFill
/// * Qt::WindingFill
/// 
/// * ![qt-fillrule-oddeven.png](qt-fillrule-oddeven.png)
/// 
/// * ![qt-fillrule-winding.png](qt-fillrule-winding.png)
/// 
/// See the Qt::FillRule documentation for the definition of the
/// rules. A painter path's currently set fill rule can be retrieved
/// using the fillRule() function, and altered using the setFillRule()
/// function.
/// 
/// # QPainterPath Information
/// 
/// The QPainterPath class provides a collection of functions that
/// returns information about the path and its elements.
/// 
/// The currentPosition() function returns the end point of the last
/// subpath that was added (or the initial start point). The
/// elementAt() function can be used to retrieve the various subpath
/// elements, the *number* of elements can be retrieved using the
/// elementCount() function, and the isEmpty() function tells whether
/// this QPainterPath object contains any elements at all.
/// 
/// The controlPointRect() function returns the rectangle containing
/// all the points and control points in this path. This function is
/// significantly faster to compute than the exact boundingRect()
/// which returns the bounding rectangle of this painter path with
/// floating point precision.
/// 
/// Finally, QPainterPath provides the contains() function which can
/// be used to determine whether a given point or rectangle is inside
/// the path, and the intersects() function which determines if any of
/// the points inside a given rectangle also are inside this path.
/// 
/// # QPainterPath Conversion
/// 
/// For compatibility reasons, it might be required to simplify the
/// representation of a painter path: QPainterPath provides the
/// toFillPolygon(), toFillPolygons() and toSubpathPolygons()
/// functions which convert the painter path into a polygon. The
/// toFillPolygon() returns the painter path as one single polygon,
/// while the two latter functions return a list of polygons.
/// 
/// The toFillPolygons() and toSubpathPolygons() functions are
/// provided because it is usually faster to draw several small
/// polygons than to draw one large polygon, even though the total
/// number of points drawn is the same. The difference between the two
/// is the *number* of polygons they return: The toSubpathPolygons()
/// creates one polygon for each subpath regardless of intersecting
/// subpaths (i.e. overlapping bounding rectangles), while the
/// toFillPolygons() functions creates only one polygon for
/// overlapping subpaths.
/// 
/// The toFillPolygon() and toFillPolygons() functions first convert
/// all the subpaths to polygons, then uses a rewinding technique to
/// make sure that overlapping subpaths can be filled using the
/// correct fill rule. Note that rewinding inserts additional lines in
/// the polygon so the outline of the fill polygon does not match the
/// outline of the path.
/// 
/// # Examples
/// 
/// Qt provides the [Painter Paths Example](painting/painterpaths)
/// 
/// and the [Vector Deformation example](painting/deform)
/// which are
/// located in Qt's example directory.
/// 
/// The [Painter Paths Example](painting/painterpaths)
/// shows how
/// painter paths can be used to build complex shapes for rendering
/// and lets the user experiment with the filling and stroking. The
/// [Vector Deformation Example](painting/deform)
/// shows how to use
/// QPainterPath to draw text.
/// 
/// * [Painter Paths Example](painting/painterpaths)
/// 
/// * [Vector Deformation Example](painting/deform)
/// 
/// * ![qpainterpath-example.png](qpainterpath-example.png)
/// 
/// * ![qpainterpath-demo.png](qpainterpath-demo.png)
/// 
/// **See also:** QPainterPathStroker
/// QPainter
/// QRegion
/// {Painter Paths Example}
/// # Licence
///
/// The documentation is an adoption of the original [Qt Documentation](http://doc.qt.io/) and provided herein is licensed under the terms of the [GNU Free Documentation License version 1.3](http://www.gnu.org/licenses/fdl.html) as published by the Free Software Foundation.
#[derive(Clone)]
pub struct PainterPath<'a> {
    pub data: Rc<Cell<Option<*const RUBase>>>,
    pub all_funcs: *const RUPainterPathAllFuncs,
    pub owned: bool,
    pub _marker: PhantomData<::std::cell::Cell<&'a ()>>,
}

impl <'a>PainterPath<'a> {
    pub fn new() -> PainterPath<'a> {
        let data = Rc::new(Cell::new(None));

        let ffi_data = unsafe {
            ((*rute_ffi_get()).create_painter_path)(
                ::std::ptr::null(),
                transmute(rute_object_delete_callback as usize),
                Rc::into_raw(data.clone()) as *const c_void)
        };

        data.set(Some(ffi_data.qt_data));

        PainterPath {
            data,
            all_funcs: ffi_data.all_funcs,
            owned: true,
            _marker: PhantomData,
        }
    }
    pub fn new_from_rc(ffi_data: RUPainterPath) -> PainterPath<'a> {
        PainterPath {
            data: unsafe { Rc::from_raw(ffi_data.host_data as *const Cell<Option<*const RUBase>>) },
            all_funcs: ffi_data.all_funcs,
            owned: false,
            _marker: PhantomData,
        }
    }

    pub fn new_from_owned(ffi_data: RUPainterPath) -> PainterPath<'a> {
        PainterPath {
            data: Rc::new(Cell::new(Some(ffi_data.qt_data as *const RUBase))),
            all_funcs: ffi_data.all_funcs,
            owned: true,
            _marker: PhantomData,
        }
    }

    pub fn new_from_temporary(ffi_data: RUPainterPath) -> PainterPath<'a> {
        PainterPath {
            data: Rc::new(Cell::new(Some(ffi_data.qt_data as *const RUBase))),
            all_funcs: ffi_data.all_funcs,
            owned: false,
            _marker: PhantomData,
        }
    }
}
pub trait PainterPathType<'a> {
    /// 
    /// Swaps painter path *other* with this painter path. This operation is very
    /// fast and never fails.
    fn swap<P: PainterPathType<'a>>(&self, other: &P) -> &Self {
        let (obj_other_1, _funcs) = other.get_painter_path_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).swap)(obj_data, obj_other_1);
        }
        self
    }
    /// 
    /// Closes the current subpath by drawing a line to the beginning of
    /// the subpath, automatically starting a new path. The current point
    /// of the new path is (0, 0).
    /// 
    /// If the subpath does not contain any elements, this function does
    /// nothing.
    /// 
    /// **See also:** moveTo()
    /// {QPainterPath#Composing a QPainterPath}{Composing
    /// a QPainterPath}
    fn close_subpath(&self) -> &Self {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).close_subpath)(obj_data);
        }
        self
    }
    /// 
    /// **Overloads**
    /// Moves the current position to ( *x* , *y* ) and starts a new
    /// subpath, implicitly closing the previous path.
    /// 
    /// Moves the current point to the given *point,* implicitly starting
    /// a new subpath and closing the previous one.
    /// 
    /// **See also:** closeSubpath()
    /// {QPainterPath#Composing a
    /// QPainterPath}{Composing a QPainterPath}
    fn move_to<P: PointFType<'a>>(&self, p: &P) -> &Self {
        let (obj_p_1, _funcs) = p.get_point_f_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).move_to)(obj_data, obj_p_1);
        }
        self
    }
    /// 
    /// **Overloads**
    /// Moves the current position to ( *x* , *y* ) and starts a new
    /// subpath, implicitly closing the previous path.
    /// 
    /// Moves the current point to the given *point,* implicitly starting
    /// a new subpath and closing the previous one.
    /// 
    /// **See also:** closeSubpath()
    /// {QPainterPath#Composing a
    /// QPainterPath}{Composing a QPainterPath}
    fn move_to(&self, x: f32, y: f32) -> &Self {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).move_to)(obj_data, x, y);
        }
        self
    }
    /// 
    /// **Overloads**
    /// Draws a line from the current position to the point ( *x* ,
    /// *y* ).
    /// 
    /// Adds a straight line from the current position to the given *endPoint.* After the line is drawn, the current position is updated
    /// to be at the end point of the line.
    /// 
    /// **See also:** addPolygon()
    /// addRect()
    /// {QPainterPath#Composing a
    /// QPainterPath}{Composing a QPainterPath}
    fn line_to<P: PointFType<'a>>(&self, p: &P) -> &Self {
        let (obj_p_1, _funcs) = p.get_point_f_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).line_to)(obj_data, obj_p_1);
        }
        self
    }
    /// 
    /// **Overloads**
    /// Draws a line from the current position to the point ( *x* ,
    /// *y* ).
    /// 
    /// Adds a straight line from the current position to the given *endPoint.* After the line is drawn, the current position is updated
    /// to be at the end point of the line.
    /// 
    /// **See also:** addPolygon()
    /// addRect()
    /// {QPainterPath#Composing a
    /// QPainterPath}{Composing a QPainterPath}
    fn line_to(&self, x: f32, y: f32) -> &Self {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).line_to)(obj_data, x, y);
        }
        self
    }
    /// 
    /// **Overloads**
    /// Creates a move to that lies on the arc that occupies the
    /// QRectF( *x,* *y,* *width,* *height)* at *angle.*
    /// 
    /// Creates a move to that lies on the arc that occupies the given *rectangle* at *angle.*
    /// 
    /// Angles are specified in degrees. Clockwise arcs can be specified
    /// using negative angles.
    /// 
    /// **See also:** moveTo()
    /// arcTo()
    fn arc_move_to<R: RectFType<'a>>(&self, rect: &R, angle: f32) -> &Self {
        let (obj_rect_1, _funcs) = rect.get_rect_f_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).arc_move_to)(obj_data, obj_rect_1, angle);
        }
        self
    }
    /// 
    /// **Overloads**
    /// Creates a move to that lies on the arc that occupies the
    /// QRectF( *x,* *y,* *width,* *height)* at *angle.*
    /// 
    /// Creates a move to that lies on the arc that occupies the given *rectangle* at *angle.*
    /// 
    /// Angles are specified in degrees. Clockwise arcs can be specified
    /// using negative angles.
    /// 
    /// **See also:** moveTo()
    /// arcTo()
    fn arc_move_to(&self, x: f32, y: f32, w: f32, h: f32, angle: f32) -> &Self {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).arc_move_to)(obj_data, x, y, w, h, angle);
        }
        self
    }
    /// 
    /// height, qreal startAngle, qreal sweepLength)
    /// 
    /// **Overloads**
    /// Creates an arc that occupies the rectangle QRectF( *x,* *y,* *width,* *height),* beginning at the specified *startAngle* and
    /// extending *sweepLength* degrees counter-clockwise.
    /// 
    /// 
    /// Creates an arc that occupies the given *rectangle,* beginning at
    /// the specified *startAngle* and extending *sweepLength* degrees
    /// counter-clockwise.
    /// 
    /// Angles are specified in degrees. Clockwise arcs can be specified
    /// using negative angles.
    /// 
    /// Note that this function connects the starting point of the arc to
    /// the current position if they are not already connected. After the
    /// arc has been added, the current position is the last point in
    /// arc. To draw a line back to the first point, use the
    /// closeSubpath() function.
    /// 
    /// * ![qpainterpath-arcto.png](qpainterpath-arcto.png)
    /// 
    /// 
    /// 
    /// **See also:** arcMoveTo()
    /// addEllipse()
    /// QPainter::drawArc()
    /// QPainter::drawPie()
    /// {QPainterPath#Composing a QPainterPath}{Composing a
    /// QPainterPath}
    fn arc_to<R: RectFType<'a>>(&self, rect: &R, start_angle: f32, arc_length: f32) -> &Self {
        let (obj_rect_1, _funcs) = rect.get_rect_f_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).arc_to)(obj_data, obj_rect_1, start_angle, arc_length);
        }
        self
    }
    /// 
    /// height, qreal startAngle, qreal sweepLength)
    /// 
    /// **Overloads**
    /// Creates an arc that occupies the rectangle QRectF( *x,* *y,* *width,* *height),* beginning at the specified *startAngle* and
    /// extending *sweepLength* degrees counter-clockwise.
    /// 
    /// 
    /// Creates an arc that occupies the given *rectangle,* beginning at
    /// the specified *startAngle* and extending *sweepLength* degrees
    /// counter-clockwise.
    /// 
    /// Angles are specified in degrees. Clockwise arcs can be specified
    /// using negative angles.
    /// 
    /// Note that this function connects the starting point of the arc to
    /// the current position if they are not already connected. After the
    /// arc has been added, the current position is the last point in
    /// arc. To draw a line back to the first point, use the
    /// closeSubpath() function.
    /// 
    /// * ![qpainterpath-arcto.png](qpainterpath-arcto.png)
    /// 
    /// 
    /// 
    /// **See also:** arcMoveTo()
    /// addEllipse()
    /// QPainter::drawArc()
    /// QPainter::drawPie()
    /// {QPainterPath#Composing a QPainterPath}{Composing a
    /// QPainterPath}
    fn arc_to(&self, x: f32, y: f32, w: f32, h: f32, start_angle: f32, arc_length: f32) -> &Self {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).arc_to)(obj_data, x, y, w, h, start_angle, arc_length);
        }
        self
    }
    /// 
    /// qreal c2Y, qreal endPointX, qreal endPointY);
    /// 
    /// **Overloads**
    /// Adds a cubic Bezier curve between the current position and the end
    /// point ( *endPointX* , *endPointY* ) with control points specified
    /// by ( *c1X* , *c1Y* ) and ( *c2X* , *c2Y* ).
    /// 
    /// Adds a cubic Bezier curve between the current position and the
    /// given *endPoint* using the control points specified by *c1,* and
    /// *c2.*
    /// 
    /// After the curve is added, the current position is updated to be at
    /// the end point of the curve.
    /// 
    /// * ![qpainterpath-cubicto.png](qpainterpath-cubicto.png)
    /// 
    /// 
    /// 
    /// **See also:** quadTo()
    /// {QPainterPath#Composing a QPainterPath}{Composing
    /// a QPainterPath}
    fn cubic_to<P: PointFType<'a>>(&self, ctrl_pt1: &P, ctrl_pt2: &P, end_pt: &P) -> &Self {
        let (obj_ctrl_pt1_1, _funcs) = ctrl_pt1.get_point_f_obj_funcs();
        let (obj_ctrl_pt2_2, _funcs) = ctrl_pt2.get_point_f_obj_funcs();
        let (obj_end_pt_3, _funcs) = end_pt.get_point_f_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).cubic_to)(obj_data, obj_ctrl_pt1_1, obj_ctrl_pt2_2, obj_end_pt_3);
        }
        self
    }
    /// 
    /// qreal c2Y, qreal endPointX, qreal endPointY);
    /// 
    /// **Overloads**
    /// Adds a cubic Bezier curve between the current position and the end
    /// point ( *endPointX* , *endPointY* ) with control points specified
    /// by ( *c1X* , *c1Y* ) and ( *c2X* , *c2Y* ).
    /// 
    /// Adds a cubic Bezier curve between the current position and the
    /// given *endPoint* using the control points specified by *c1,* and
    /// *c2.*
    /// 
    /// After the curve is added, the current position is updated to be at
    /// the end point of the curve.
    /// 
    /// * ![qpainterpath-cubicto.png](qpainterpath-cubicto.png)
    /// 
    /// 
    /// 
    /// **See also:** quadTo()
    /// {QPainterPath#Composing a QPainterPath}{Composing
    /// a QPainterPath}
    fn cubic_to(&self, ctrl_pt1x: f32, ctrl_pt1y: f32, ctrl_pt2x: f32, ctrl_pt2y: f32, end_ptx: f32, end_pty: f32) -> &Self {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).cubic_to)(obj_data, ctrl_pt1x, ctrl_pt1y, ctrl_pt2x, ctrl_pt2y, end_ptx, end_pty);
        }
        self
    }
    /// 
    /// **Overloads**
    /// Adds a quadratic Bezier curve between the current point and the endpoint
    /// ( *endPointX* , *endPointY* ) with the control point specified by
    /// ( *cx* , *cy* ).
    /// 
    /// Adds a quadratic Bezier curve between the current position and the
    /// given *endPoint* with the control point specified by *c.*
    /// 
    /// After the curve is added, the current point is updated to be at
    /// the end point of the curve.
    /// 
    /// **See also:** cubicTo()
    /// {QPainterPath#Composing a QPainterPath}{Composing a
    /// QPainterPath}
    fn quad_to<P: PointFType<'a>>(&self, ctrl_pt: &P, end_pt: &P) -> &Self {
        let (obj_ctrl_pt_1, _funcs) = ctrl_pt.get_point_f_obj_funcs();
        let (obj_end_pt_2, _funcs) = end_pt.get_point_f_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).quad_to)(obj_data, obj_ctrl_pt_1, obj_end_pt_2);
        }
        self
    }
    /// 
    /// **Overloads**
    /// Adds a quadratic Bezier curve between the current point and the endpoint
    /// ( *endPointX* , *endPointY* ) with the control point specified by
    /// ( *cx* , *cy* ).
    /// 
    /// Adds a quadratic Bezier curve between the current position and the
    /// given *endPoint* with the control point specified by *c.*
    /// 
    /// After the curve is added, the current point is updated to be at
    /// the end point of the curve.
    /// 
    /// **See also:** cubicTo()
    /// {QPainterPath#Composing a QPainterPath}{Composing a
    /// QPainterPath}
    fn quad_to(&self, ctrl_ptx: f32, ctrl_pty: f32, end_ptx: f32, end_pty: f32) -> &Self {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).quad_to)(obj_data, ctrl_ptx, ctrl_pty, end_ptx, end_pty);
        }
        self
    }
    /// 
    /// Returns the current position of the path.
    fn current_position(&self) -> PointF {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).current_position)(obj_data);
            let t = ret_val;
            let ret_val;
            if t.host_data != ::std::ptr::null() {
                ret_val = PointF::new_from_rc(t);
            } else {
                ret_val = PointF::new_from_owned(t);
            }
            ret_val
        }
    }
    /// 
    /// **Overloads**
    /// Adds a rectangle at position ( *x* , *y* ), with the given *width* and *height,* as a closed subpath.
    /// 
    /// Adds the given *rectangle* to this path as a closed subpath.
    /// 
    /// The *rectangle* is added as a clockwise set of lines. The painter
    /// path's current position after the *rectangle* has been added is
    /// at the top-left corner of the rectangle.
    /// 
    /// * ![qpainterpath-addrectangle.png](qpainterpath-addrectangle.png)
    /// 
    /// 
    /// 
    /// **See also:** addRegion()
    /// lineTo()
    /// {QPainterPath#Composing a
    /// QPainterPath}{Composing a QPainterPath}
    fn add_rect<R: RectFType<'a>>(&self, rect: &R) -> &Self {
        let (obj_rect_1, _funcs) = rect.get_rect_f_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_rect)(obj_data, obj_rect_1);
        }
        self
    }
    /// 
    /// **Overloads**
    /// Adds a rectangle at position ( *x* , *y* ), with the given *width* and *height,* as a closed subpath.
    /// 
    /// Adds the given *rectangle* to this path as a closed subpath.
    /// 
    /// The *rectangle* is added as a clockwise set of lines. The painter
    /// path's current position after the *rectangle* has been added is
    /// at the top-left corner of the rectangle.
    /// 
    /// * ![qpainterpath-addrectangle.png](qpainterpath-addrectangle.png)
    /// 
    /// 
    /// 
    /// **See also:** addRegion()
    /// lineTo()
    /// {QPainterPath#Composing a
    /// QPainterPath}{Composing a QPainterPath}
    fn add_rect(&self, x: f32, y: f32, w: f32, h: f32) -> &Self {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_rect)(obj_data, x, y, w, h);
        }
        self
    }
    /// 
    /// **Overloads**
    /// Creates an ellipse within the bounding rectangle defined by its top-left
    /// corner at ( *x,* *y),* *width* and *height,* and adds it to the
    /// painter path as a closed subpath.
    /// 
    /// **Overloads**
    /// Creates an ellipse positioned at *center* with radii *rx* and *ry* ,
    /// and adds it to the painter path as a closed subpath.
    /// 
    /// Creates an ellipse within the specified *boundingRectangle*
    /// and adds it to the painter path as a closed subpath.
    /// 
    /// The ellipse is composed of a clockwise curve, starting and
    /// finishing at zero degrees (the 3 o'clock position).
    /// 
    /// * ![qpainterpath-addellipse.png](qpainterpath-addellipse.png)
    /// 
    /// 
    /// 
    /// **See also:** arcTo()
    /// QPainter::drawEllipse()
    /// {QPainterPath#Composing a
    /// QPainterPath}{Composing a QPainterPath}
    fn add_ellipse<R: RectFType<'a>>(&self, rect: &R) -> &Self {
        let (obj_rect_1, _funcs) = rect.get_rect_f_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_ellipse)(obj_data, obj_rect_1);
        }
        self
    }
    /// 
    /// **Overloads**
    /// Creates an ellipse within the bounding rectangle defined by its top-left
    /// corner at ( *x,* *y),* *width* and *height,* and adds it to the
    /// painter path as a closed subpath.
    /// 
    /// **Overloads**
    /// Creates an ellipse positioned at *center* with radii *rx* and *ry* ,
    /// and adds it to the painter path as a closed subpath.
    /// 
    /// Creates an ellipse within the specified *boundingRectangle*
    /// and adds it to the painter path as a closed subpath.
    /// 
    /// The ellipse is composed of a clockwise curve, starting and
    /// finishing at zero degrees (the 3 o'clock position).
    /// 
    /// * ![qpainterpath-addellipse.png](qpainterpath-addellipse.png)
    /// 
    /// 
    /// 
    /// **See also:** arcTo()
    /// QPainter::drawEllipse()
    /// {QPainterPath#Composing a
    /// QPainterPath}{Composing a QPainterPath}
    fn add_ellipse(&self, x: f32, y: f32, w: f32, h: f32) -> &Self {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_ellipse)(obj_data, x, y, w, h);
        }
        self
    }
    /// 
    /// **Overloads**
    /// Creates an ellipse within the bounding rectangle defined by its top-left
    /// corner at ( *x,* *y),* *width* and *height,* and adds it to the
    /// painter path as a closed subpath.
    /// 
    /// **Overloads**
    /// Creates an ellipse positioned at *center* with radii *rx* and *ry* ,
    /// and adds it to the painter path as a closed subpath.
    /// 
    /// Creates an ellipse within the specified *boundingRectangle*
    /// and adds it to the painter path as a closed subpath.
    /// 
    /// The ellipse is composed of a clockwise curve, starting and
    /// finishing at zero degrees (the 3 o'clock position).
    /// 
    /// * ![qpainterpath-addellipse.png](qpainterpath-addellipse.png)
    /// 
    /// 
    /// 
    /// **See also:** arcTo()
    /// QPainter::drawEllipse()
    /// {QPainterPath#Composing a
    /// QPainterPath}{Composing a QPainterPath}
    fn add_ellipse<P: PointFType<'a>>(&self, center: &P, rx: f32, ry: f32) -> &Self {
        let (obj_center_1, _funcs) = center.get_point_f_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_ellipse)(obj_data, obj_center_1, rx, ry);
        }
        self
    }
    /// 
    /// Adds the given *polygon* to the path as an (unclosed) subpath.
    /// 
    /// Note that the current position after the polygon has been added,
    /// is the last point in *polygon.* To draw a line back to the first
    /// point, use the closeSubpath() function.
    /// 
    /// * ![qpainterpath-addpolygon.png](qpainterpath-addpolygon.png)
    /// 
    /// 
    /// 
    /// **See also:** lineTo()
    /// {QPainterPath#Composing a QPainterPath}{Composing
    /// a QPainterPath}
    fn add_polygon<P: PolygonFType<'a>>(&self, polygon: &P) -> &Self {
        let (obj_polygon_1, _funcs) = polygon.get_polygon_f_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_polygon)(obj_data, obj_polygon_1);
        }
        self
    }
    /// 
    /// **Overloads**
    /// Adds the given *text* to this path as a set of closed subpaths created
    /// from the *font* supplied. The subpaths are positioned so that the left
    /// end of the text's baseline lies at the point specified by ( *x,* *y).*
    /// 
    /// Adds the given *text* to this path as a set of closed subpaths
    /// created from the *font* supplied. The subpaths are positioned so
    /// that the left end of the text's baseline lies at the specified *point.*
    /// 
    /// * ![qpainterpath-addtext.png](qpainterpath-addtext.png)
    /// 
    /// 
    /// 
    /// **See also:** QPainter::drawText()
    /// {QPainterPath#Composing a
    /// QPainterPath}{Composing a QPainterPath}
    fn add_text<F: FontType<'a>, P: PointFType<'a>>(&self, point: &P, f: &F, text: &str) -> &Self {
        let (obj_point_1, _funcs) = point.get_point_f_obj_funcs();
        let (obj_f_2, _funcs) = f.get_font_obj_funcs();
        let str_in_text_3 = CString::new(text).unwrap();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_text)(obj_data, obj_point_1, obj_f_2, str_in_text_3.as_ptr());
        }
        self
    }
    /// 
    /// **Overloads**
    /// Adds the given *text* to this path as a set of closed subpaths created
    /// from the *font* supplied. The subpaths are positioned so that the left
    /// end of the text's baseline lies at the point specified by ( *x,* *y).*
    /// 
    /// Adds the given *text* to this path as a set of closed subpaths
    /// created from the *font* supplied. The subpaths are positioned so
    /// that the left end of the text's baseline lies at the specified *point.*
    /// 
    /// * ![qpainterpath-addtext.png](qpainterpath-addtext.png)
    /// 
    /// 
    /// 
    /// **See also:** QPainter::drawText()
    /// {QPainterPath#Composing a
    /// QPainterPath}{Composing a QPainterPath}
    fn add_text<F: FontType<'a>>(&self, x: f32, y: f32, f: &F, text: &str) -> &Self {
        let (obj_f_3, _funcs) = f.get_font_obj_funcs();
        let str_in_text_4 = CString::new(text).unwrap();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_text)(obj_data, x, y, obj_f_3, str_in_text_4.as_ptr());
        }
        self
    }
    /// 
    /// Adds the given *path* to *this* path as a closed subpath.
    /// 
    /// **See also:** connectPath()
    /// {QPainterPath#Composing a
    /// QPainterPath}{Composing a QPainterPath}
    fn add_path<P: PainterPathType<'a>>(&self, path: &P) -> &Self {
        let (obj_path_1, _funcs) = path.get_painter_path_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_path)(obj_data, obj_path_1);
        }
        self
    }
    /// 
    /// Adds the given *region* to the path by adding each rectangle in
    /// the region as a separate closed subpath.
    /// 
    /// **See also:** addRect()
    /// {QPainterPath#Composing a QPainterPath}{Composing
    /// a QPainterPath}
    fn add_region<R: RegionType<'a>>(&self, region: &R) -> &Self {
        let (obj_region_1, _funcs) = region.get_region_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_region)(obj_data, obj_region_1);
        }
        self
    }
    /// 
    /// Adds the given rectangle *rect* with rounded corners to the path.
    /// 
    /// The *xRadius* and *yRadius* arguments specify the radii of
    /// the ellipses defining the corners of the rounded rectangle.
    /// When *mode* is Qt::RelativeSize, *xRadius* and
    /// *yRadius* are specified in percentage of half the rectangle's
    /// width and height respectively, and should be in the range 0.0 to 100.0.
    /// 
    /// **See also:** addRect()
    /// 
    /// **Overloads**
    /// Adds the given rectangle *x,* *y,* *w,* *h* with rounded corners to the path.
    fn add_rounded_rect<R: RectFType<'a>>(&self, rect: &R, x_radius: f32, y_radius: f32, mode: SizeMode) -> &Self {
        let (obj_rect_1, _funcs) = rect.get_rect_f_obj_funcs();
        let enum_mode_4 = mode as i32;

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_rounded_rect)(obj_data, obj_rect_1, x_radius, y_radius, enum_mode_4);
        }
        self
    }
    /// 
    /// Adds the given rectangle *rect* with rounded corners to the path.
    /// 
    /// The *xRadius* and *yRadius* arguments specify the radii of
    /// the ellipses defining the corners of the rounded rectangle.
    /// When *mode* is Qt::RelativeSize, *xRadius* and
    /// *yRadius* are specified in percentage of half the rectangle's
    /// width and height respectively, and should be in the range 0.0 to 100.0.
    /// 
    /// **See also:** addRect()
    /// 
    /// **Overloads**
    /// Adds the given rectangle *x,* *y,* *w,* *h* with rounded corners to the path.
    fn add_rounded_rect(&self, x: f32, y: f32, w: f32, h: f32, x_radius: f32, y_radius: f32, mode: SizeMode) -> &Self {
        let enum_mode_7 = mode as i32;

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_rounded_rect)(obj_data, x, y, w, h, x_radius, y_radius, enum_mode_7);
        }
        self
    }
    /// 
    /// Adds a rectangle *r* with rounded corners to the path.
    /// 
    /// The *xRnd* and *yRnd* arguments specify how rounded the corners
    /// should be. 0 is angled corners, 99 is maximum roundedness.
    /// 
    /// **See also:** addRoundedRect()
    /// 
    /// **Overloads**
    /// Adds a rounded rectangle, *rect,* to the path.
    /// 
    /// The *roundness* argument specifies uniform roundness for the
    /// rectangle. Vertical and horizontal roundness factors will be
    /// adjusted accordingly to act uniformly around both axes. Use this
    /// method if you want a rectangle equally rounded across both the X and
    /// Y axis.
    /// 
    /// **See also:** addRoundedRect()
    /// 
    /// **Overloads**
    /// Adds a rectangle with rounded corners to the path. The rectangle
    /// is constructed from *x,* *y,* and the width and height *w*
    /// and *h.*
    /// 
    /// The *xRnd* and *yRnd* arguments specify how rounded the corners
    /// should be. 0 is angled corners, 99 is maximum roundedness.
    /// 
    /// **See also:** addRoundedRect()
    /// 
    /// **Overloads**
    /// Adds a rounded rectangle to the path, defined by the coordinates *x* and *y* with the specified *width* and *height.*
    /// 
    /// The *roundness* argument specifies uniform roundness for the
    /// rectangle. Vertical and horizontal roundness factors will be
    /// adjusted accordingly to act uniformly around both axes. Use this
    /// method if you want a rectangle equally rounded across both the X and
    /// Y axis.
    /// 
    /// **See also:** addRoundedRect()
    fn add_round_rect<R: RectFType<'a>>(&self, rect: &R, x_rnd: i32, y_rnd: i32) -> &Self {
        let (obj_rect_1, _funcs) = rect.get_rect_f_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_round_rect)(obj_data, obj_rect_1, x_rnd, y_rnd);
        }
        self
    }
    /// 
    /// Adds a rectangle *r* with rounded corners to the path.
    /// 
    /// The *xRnd* and *yRnd* arguments specify how rounded the corners
    /// should be. 0 is angled corners, 99 is maximum roundedness.
    /// 
    /// **See also:** addRoundedRect()
    /// 
    /// **Overloads**
    /// Adds a rounded rectangle, *rect,* to the path.
    /// 
    /// The *roundness* argument specifies uniform roundness for the
    /// rectangle. Vertical and horizontal roundness factors will be
    /// adjusted accordingly to act uniformly around both axes. Use this
    /// method if you want a rectangle equally rounded across both the X and
    /// Y axis.
    /// 
    /// **See also:** addRoundedRect()
    /// 
    /// **Overloads**
    /// Adds a rectangle with rounded corners to the path. The rectangle
    /// is constructed from *x,* *y,* and the width and height *w*
    /// and *h.*
    /// 
    /// The *xRnd* and *yRnd* arguments specify how rounded the corners
    /// should be. 0 is angled corners, 99 is maximum roundedness.
    /// 
    /// **See also:** addRoundedRect()
    /// 
    /// **Overloads**
    /// Adds a rounded rectangle to the path, defined by the coordinates *x* and *y* with the specified *width* and *height.*
    /// 
    /// The *roundness* argument specifies uniform roundness for the
    /// rectangle. Vertical and horizontal roundness factors will be
    /// adjusted accordingly to act uniformly around both axes. Use this
    /// method if you want a rectangle equally rounded across both the X and
    /// Y axis.
    /// 
    /// **See also:** addRoundedRect()
    fn add_round_rect(&self, x: f32, y: f32, w: f32, h: f32, x_rnd: i32, y_rnd: i32) -> &Self {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_round_rect)(obj_data, x, y, w, h, x_rnd, y_rnd);
        }
        self
    }
    /// 
    /// Adds a rectangle *r* with rounded corners to the path.
    /// 
    /// The *xRnd* and *yRnd* arguments specify how rounded the corners
    /// should be. 0 is angled corners, 99 is maximum roundedness.
    /// 
    /// **See also:** addRoundedRect()
    /// 
    /// **Overloads**
    /// Adds a rounded rectangle, *rect,* to the path.
    /// 
    /// The *roundness* argument specifies uniform roundness for the
    /// rectangle. Vertical and horizontal roundness factors will be
    /// adjusted accordingly to act uniformly around both axes. Use this
    /// method if you want a rectangle equally rounded across both the X and
    /// Y axis.
    /// 
    /// **See also:** addRoundedRect()
    /// 
    /// **Overloads**
    /// Adds a rectangle with rounded corners to the path. The rectangle
    /// is constructed from *x,* *y,* and the width and height *w*
    /// and *h.*
    /// 
    /// The *xRnd* and *yRnd* arguments specify how rounded the corners
    /// should be. 0 is angled corners, 99 is maximum roundedness.
    /// 
    /// **See also:** addRoundedRect()
    /// 
    /// **Overloads**
    /// Adds a rounded rectangle to the path, defined by the coordinates *x* and *y* with the specified *width* and *height.*
    /// 
    /// The *roundness* argument specifies uniform roundness for the
    /// rectangle. Vertical and horizontal roundness factors will be
    /// adjusted accordingly to act uniformly around both axes. Use this
    /// method if you want a rectangle equally rounded across both the X and
    /// Y axis.
    /// 
    /// **See also:** addRoundedRect()
    fn add_round_rect<R: RectFType<'a>>(&self, rect: &R, roundness: i32) -> &Self {
        let (obj_rect_1, _funcs) = rect.get_rect_f_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_round_rect)(obj_data, obj_rect_1, roundness);
        }
        self
    }
    /// 
    /// Adds a rectangle *r* with rounded corners to the path.
    /// 
    /// The *xRnd* and *yRnd* arguments specify how rounded the corners
    /// should be. 0 is angled corners, 99 is maximum roundedness.
    /// 
    /// **See also:** addRoundedRect()
    /// 
    /// **Overloads**
    /// Adds a rounded rectangle, *rect,* to the path.
    /// 
    /// The *roundness* argument specifies uniform roundness for the
    /// rectangle. Vertical and horizontal roundness factors will be
    /// adjusted accordingly to act uniformly around both axes. Use this
    /// method if you want a rectangle equally rounded across both the X and
    /// Y axis.
    /// 
    /// **See also:** addRoundedRect()
    /// 
    /// **Overloads**
    /// Adds a rectangle with rounded corners to the path. The rectangle
    /// is constructed from *x,* *y,* and the width and height *w*
    /// and *h.*
    /// 
    /// The *xRnd* and *yRnd* arguments specify how rounded the corners
    /// should be. 0 is angled corners, 99 is maximum roundedness.
    /// 
    /// **See also:** addRoundedRect()
    /// 
    /// **Overloads**
    /// Adds a rounded rectangle to the path, defined by the coordinates *x* and *y* with the specified *width* and *height.*
    /// 
    /// The *roundness* argument specifies uniform roundness for the
    /// rectangle. Vertical and horizontal roundness factors will be
    /// adjusted accordingly to act uniformly around both axes. Use this
    /// method if you want a rectangle equally rounded across both the X and
    /// Y axis.
    /// 
    /// **See also:** addRoundedRect()
    fn add_round_rect(&self, x: f32, y: f32, w: f32, h: f32, roundness: i32) -> &Self {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).add_round_rect)(obj_data, x, y, w, h, roundness);
        }
        self
    }
    /// 
    /// Connects the given *path* to *this* path by adding a line from the
    /// last element of this path to the first element of the given path.
    /// 
    /// **See also:** addPath()
    /// {QPainterPath#Composing a QPainterPath}{Composing
    /// a QPainterPath}
    fn connect_path<P: PainterPathType<'a>>(&self, path: &P) -> &Self {
        let (obj_path_1, _funcs) = path.get_painter_path_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).connect_path)(obj_data, obj_path_1);
        }
        self
    }
    /// 
    /// Returns `true` if the given *point* is inside the path, otherwise
    /// returns `false.`
    /// 
    /// **See also:** intersects()
    /// 
    /// Returns `true` if the given *rectangle* is inside the path,
    /// otherwise returns `false.`
    /// 
    /// Returns `true` if the given path *p* is contained within
    /// the current path. Returns `false` if any edges of the current path and
    /// *p* intersect.
    /// 
    /// Set operations on paths will treat the paths as areas. Non-closed
    /// paths will be treated as implicitly closed.
    /// 
    /// **See also:** intersects()
    fn contains<P: PointFType<'a>>(&self, pt: &P) -> bool {
        let (obj_pt_1, _funcs) = pt.get_point_f_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).contains)(obj_data, obj_pt_1);
            ret_val
        }
    }
    /// 
    /// Returns `true` if the given *point* is inside the path, otherwise
    /// returns `false.`
    /// 
    /// **See also:** intersects()
    /// 
    /// Returns `true` if the given *rectangle* is inside the path,
    /// otherwise returns `false.`
    /// 
    /// Returns `true` if the given path *p* is contained within
    /// the current path. Returns `false` if any edges of the current path and
    /// *p* intersect.
    /// 
    /// Set operations on paths will treat the paths as areas. Non-closed
    /// paths will be treated as implicitly closed.
    /// 
    /// **See also:** intersects()
    fn contains<R: RectFType<'a>>(&self, rect: &R) -> bool {
        let (obj_rect_1, _funcs) = rect.get_rect_f_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).contains)(obj_data, obj_rect_1);
            ret_val
        }
    }
    /// 
    /// Returns `true` if any point in the given *rectangle* intersects the
    /// path; otherwise returns `false.`
    /// 
    /// There is an intersection if any of the lines making up the
    /// rectangle crosses a part of the path or if any part of the
    /// rectangle overlaps with any area enclosed by the path. This
    /// function respects the current fillRule to determine what is
    /// considered inside the path.
    /// 
    /// **See also:** contains()
    /// 
    /// Returns `true` if the current path intersects at any point the given path *p.*
    /// Also returns `true` if the current path contains or is contained by any part of *p.*
    /// 
    /// Set operations on paths will treat the paths as areas. Non-closed
    /// paths will be treated as implicitly closed.
    /// 
    /// **See also:** contains()
    fn intersects<R: RectFType<'a>>(&self, rect: &R) -> bool {
        let (obj_rect_1, _funcs) = rect.get_rect_f_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).intersects)(obj_data, obj_rect_1);
            ret_val
        }
    }
    /// 
    /// Returns the bounding rectangle of this painter path as a rectangle with
    /// floating point precision.
    /// 
    /// **See also:** controlPointRect()
    fn bounding_rect(&self) -> RectF {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).bounding_rect)(obj_data);
            let t = ret_val;
            let ret_val;
            if t.host_data != ::std::ptr::null() {
                ret_val = RectF::new_from_rc(t);
            } else {
                ret_val = RectF::new_from_owned(t);
            }
            ret_val
        }
    }
    /// 
    /// Returns the painter path's currently set fill rule.
    /// 
    /// **See also:** setFillRule()
    fn fill_rule(&self) -> FillRule {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).fill_rule)(obj_data);
           let ret_val = { transmute::<i32, FillRule>(ret_val) };
            ret_val
        }
    }
    /// 
    /// Sets the fill rule of the painter path to the given *fillRule.* Qt provides two methods for filling paths:
    /// 
    /// * Qt::OddEvenFill (default)
    /// * Qt::WindingFill
    /// 
    /// * ![qt-fillrule-oddeven.png](qt-fillrule-oddeven.png)
    /// 
    /// * ![qt-fillrule-winding.png](qt-fillrule-winding.png)
    /// 
    /// **See also:** fillRule()
    fn set_fill_rule(&self, fill_rule: FillRule) -> &Self {
        let enum_fill_rule_1 = fill_rule as i32;

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).set_fill_rule)(obj_data, enum_fill_rule_1);
        }
        self
    }
    /// 
    /// Returns `true` if either there are no elements in this path, or if the only
    /// element is a MoveToElement; otherwise returns `false.`
    /// 
    /// **See also:** elementCount()
    fn is_empty(&self) -> bool {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).is_empty)(obj_data);
            ret_val
        }
    }
    /// 
    /// Creates and returns a reversed copy of the path.
    /// 
    /// It is the order of the elements that is reversed: If a
    /// QPainterPath is composed by calling the moveTo(), lineTo() and
    /// cubicTo() functions in the specified order, the reversed copy is
    /// composed by calling cubicTo(), lineTo() and moveTo().
    fn to_reversed(&self) -> PainterPath {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).to_reversed)(obj_data);
            let t = ret_val;
            let ret_val;
            if t.host_data != ::std::ptr::null() {
                ret_val = PainterPath::new_from_rc(t);
            } else {
                ret_val = PainterPath::new_from_owned(t);
            }
            ret_val
        }
    }
    /// 
    /// Converts the path into a list of polygons using the QTransform
    /// *matrix,* and returns the list.
    /// 
    /// This function creates one polygon for each subpath regardless of
    /// intersecting subpaths (i.e. overlapping bounding rectangles). To
    /// make sure that such overlapping subpaths are filled correctly, use
    /// the toFillPolygons() function instead.
    /// 
    /// **See also:** toFillPolygons()
    /// toFillPolygon()
    /// {QPainterPath#QPainterPath
    /// Conversion}{QPainterPath Conversion}
    /// 
    /// **Overloads**
    fn to_subpath_polygons<M: MatrixType<'a>>(&self, matrix: &M) -> RefArray<PolygonF, WrapperRcOwn> {
        let (obj_matrix_1, _funcs) = matrix.get_matrix_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).to_subpath_polygons)(obj_data, obj_matrix_1);
            let t = ret_val;
            let ret_val;
            if t.host_data != ::std::ptr::null() {
                ret_val = PolygonF::new_from_rc(t);
            } else {
                ret_val = PolygonF::new_from_owned(t);
            }
            ret_val
        }
    }
    /// 
    /// Converts the path into a list of polygons using the
    /// QTransform *matrix,* and returns the list.
    /// 
    /// The function differs from the toFillPolygon() function in that it
    /// creates several polygons. It is provided because it is usually
    /// faster to draw several small polygons than to draw one large
    /// polygon, even though the total number of points drawn is the same.
    /// 
    /// The toFillPolygons() function differs from the toSubpathPolygons()
    /// function in that it create only polygon for subpaths that have
    /// overlapping bounding rectangles.
    /// 
    /// Like the toFillPolygon() function, this function uses a rewinding
    /// technique to make sure that overlapping subpaths can be filled
    /// using the correct fill rule. Note that rewinding inserts addition
    /// lines in the polygons so the outline of the fill polygon does not
    /// match the outline of the path.
    /// 
    /// **See also:** toSubpathPolygons()
    /// toFillPolygon()
    /// {QPainterPath#QPainterPath Conversion}{QPainterPath Conversion}
    /// 
    /// **Overloads**
    fn to_fill_polygons<M: MatrixType<'a>>(&self, matrix: &M) -> RefArray<PolygonF, WrapperRcOwn> {
        let (obj_matrix_1, _funcs) = matrix.get_matrix_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).to_fill_polygons)(obj_data, obj_matrix_1);
            let t = ret_val;
            let ret_val;
            if t.host_data != ::std::ptr::null() {
                ret_val = PolygonF::new_from_rc(t);
            } else {
                ret_val = PolygonF::new_from_owned(t);
            }
            ret_val
        }
    }
    /// 
    /// Converts the path into a list of polygons using the
    /// QTransform *matrix,* and returns the list.
    /// 
    /// The function differs from the toFillPolygon() function in that it
    /// creates several polygons. It is provided because it is usually
    /// faster to draw several small polygons than to draw one large
    /// polygon, even though the total number of points drawn is the same.
    /// 
    /// The toFillPolygons() function differs from the toSubpathPolygons()
    /// function in that it create only polygon for subpaths that have
    /// overlapping bounding rectangles.
    /// 
    /// Like the toFillPolygon() function, this function uses a rewinding
    /// technique to make sure that overlapping subpaths can be filled
    /// using the correct fill rule. Note that rewinding inserts addition
    /// lines in the polygons so the outline of the fill polygon does not
    /// match the outline of the path.
    /// 
    /// **See also:** toSubpathPolygons()
    /// toFillPolygon()
    /// {QPainterPath#QPainterPath Conversion}{QPainterPath Conversion}
    /// 
    /// **Overloads**
    /// 
    /// Converts the path into a polygon using the QTransform
    /// *matrix,* and returns the polygon.
    /// 
    /// The polygon is created by first converting all subpaths to
    /// polygons, then using a rewinding technique to make sure that
    /// overlapping subpaths can be filled using the correct fill rule.
    /// 
    /// Note that rewinding inserts addition lines in the polygon so
    /// the outline of the fill polygon does not match the outline of
    /// the path.
    /// 
    /// **See also:** toSubpathPolygons()
    /// toFillPolygons()
    /// {QPainterPath#QPainterPath Conversion}{QPainterPath Conversion}
    /// 
    /// **Overloads**
    fn to_fill_polygon<M: MatrixType<'a>>(&self, matrix: &M) -> PolygonF {
        let (obj_matrix_1, _funcs) = matrix.get_matrix_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).to_fill_polygon)(obj_data, obj_matrix_1);
            let t = ret_val;
            let ret_val;
            if t.host_data != ::std::ptr::null() {
                ret_val = PolygonF::new_from_rc(t);
            } else {
                ret_val = PolygonF::new_from_owned(t);
            }
            ret_val
        }
    }
    /// 
    /// Converts the path into a list of polygons using the QTransform
    /// *matrix,* and returns the list.
    /// 
    /// This function creates one polygon for each subpath regardless of
    /// intersecting subpaths (i.e. overlapping bounding rectangles). To
    /// make sure that such overlapping subpaths are filled correctly, use
    /// the toFillPolygons() function instead.
    /// 
    /// **See also:** toFillPolygons()
    /// toFillPolygon()
    /// {QPainterPath#QPainterPath
    /// Conversion}{QPainterPath Conversion}
    /// 
    /// **Overloads**
    fn to_subpath_polygons<T: TransformType<'a>>(&self, matrix: &T) -> RefArray<PolygonF, WrapperRcOwn> {
        let (obj_matrix_1, _funcs) = matrix.get_transform_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).to_subpath_polygons)(obj_data, obj_matrix_1);
            let t = ret_val;
            let ret_val;
            if t.host_data != ::std::ptr::null() {
                ret_val = PolygonF::new_from_rc(t);
            } else {
                ret_val = PolygonF::new_from_owned(t);
            }
            ret_val
        }
    }
    /// 
    /// Converts the path into a list of polygons using the
    /// QTransform *matrix,* and returns the list.
    /// 
    /// The function differs from the toFillPolygon() function in that it
    /// creates several polygons. It is provided because it is usually
    /// faster to draw several small polygons than to draw one large
    /// polygon, even though the total number of points drawn is the same.
    /// 
    /// The toFillPolygons() function differs from the toSubpathPolygons()
    /// function in that it create only polygon for subpaths that have
    /// overlapping bounding rectangles.
    /// 
    /// Like the toFillPolygon() function, this function uses a rewinding
    /// technique to make sure that overlapping subpaths can be filled
    /// using the correct fill rule. Note that rewinding inserts addition
    /// lines in the polygons so the outline of the fill polygon does not
    /// match the outline of the path.
    /// 
    /// **See also:** toSubpathPolygons()
    /// toFillPolygon()
    /// {QPainterPath#QPainterPath Conversion}{QPainterPath Conversion}
    /// 
    /// **Overloads**
    fn to_fill_polygons<T: TransformType<'a>>(&self, matrix: &T) -> RefArray<PolygonF, WrapperRcOwn> {
        let (obj_matrix_1, _funcs) = matrix.get_transform_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).to_fill_polygons)(obj_data, obj_matrix_1);
            let t = ret_val;
            let ret_val;
            if t.host_data != ::std::ptr::null() {
                ret_val = PolygonF::new_from_rc(t);
            } else {
                ret_val = PolygonF::new_from_owned(t);
            }
            ret_val
        }
    }
    /// 
    /// Converts the path into a list of polygons using the
    /// QTransform *matrix,* and returns the list.
    /// 
    /// The function differs from the toFillPolygon() function in that it
    /// creates several polygons. It is provided because it is usually
    /// faster to draw several small polygons than to draw one large
    /// polygon, even though the total number of points drawn is the same.
    /// 
    /// The toFillPolygons() function differs from the toSubpathPolygons()
    /// function in that it create only polygon for subpaths that have
    /// overlapping bounding rectangles.
    /// 
    /// Like the toFillPolygon() function, this function uses a rewinding
    /// technique to make sure that overlapping subpaths can be filled
    /// using the correct fill rule. Note that rewinding inserts addition
    /// lines in the polygons so the outline of the fill polygon does not
    /// match the outline of the path.
    /// 
    /// **See also:** toSubpathPolygons()
    /// toFillPolygon()
    /// {QPainterPath#QPainterPath Conversion}{QPainterPath Conversion}
    /// 
    /// **Overloads**
    /// 
    /// Converts the path into a polygon using the QTransform
    /// *matrix,* and returns the polygon.
    /// 
    /// The polygon is created by first converting all subpaths to
    /// polygons, then using a rewinding technique to make sure that
    /// overlapping subpaths can be filled using the correct fill rule.
    /// 
    /// Note that rewinding inserts addition lines in the polygon so
    /// the outline of the fill polygon does not match the outline of
    /// the path.
    /// 
    /// **See also:** toSubpathPolygons()
    /// toFillPolygons()
    /// {QPainterPath#QPainterPath Conversion}{QPainterPath Conversion}
    /// 
    /// **Overloads**
    fn to_fill_polygon<T: TransformType<'a>>(&self, matrix: &T) -> PolygonF {
        let (obj_matrix_1, _funcs) = matrix.get_transform_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).to_fill_polygon)(obj_data, obj_matrix_1);
            let t = ret_val;
            let ret_val;
            if t.host_data != ::std::ptr::null() {
                ret_val = PolygonF::new_from_rc(t);
            } else {
                ret_val = PolygonF::new_from_owned(t);
            }
            ret_val
        }
    }
    /// 
    /// Returns the number of path elements in the painter path.
    /// 
    /// **See also:** ElementType
    /// elementAt()
    /// isEmpty()
    fn element_count(&self) -> i32 {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).element_count)(obj_data);
            ret_val
        }
    }
    /// 
    /// Returns the element at the given *index* in the painter path.
    /// 
    /// **See also:** ElementType
    /// elementCount()
    /// isEmpty()
    fn element_at(&self, i: i32) -> Element {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).element_at)(obj_data, i);
           let ret_val = { transmute::<i32, Element>(ret_val) };
            ret_val
        }
    }
    /// 
    /// Sets the x and y coordinate of the element at index *index* to *x* and *y.*
    fn set_element_position_at(&self, i: i32, x: f32, y: f32) -> &Self {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            ((*funcs).set_element_position_at)(obj_data, i, x, y);
        }
        self
    }
    /// 
    /// Returns the length of the current path.
    fn length(&self) -> f32 {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).length)(obj_data);
            ret_val
        }
    }
    /// 
    /// Returns percentage of the whole path at the specified length *len.*
    /// 
    /// Note that similarly to other percent methods, the percentage measurement
    /// is not linear with regards to the length, if curves are present
    /// in the path. When curves are present the percentage argument is mapped
    /// to the t parameter of the Bezier equations.
    fn percent_at_length(&self, t: f32) -> f32 {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).percent_at_length)(obj_data, t);
            ret_val
        }
    }
    /// 
    /// Returns the point at at the percentage *t* of the current path.
    /// The argument *t* has to be between 0 and 1.
    /// 
    /// Note that similarly to other percent methods, the percentage measurement
    /// is not linear with regards to the length, if curves are present
    /// in the path. When curves are present the percentage argument is mapped
    /// to the t parameter of the Bezier equations.
    fn point_at_percent(&self, t: f32) -> PointF {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).point_at_percent)(obj_data, t);
            let t = ret_val;
            let ret_val;
            if t.host_data != ::std::ptr::null() {
                ret_val = PointF::new_from_rc(t);
            } else {
                ret_val = PointF::new_from_owned(t);
            }
            ret_val
        }
    }
    /// 
    /// Returns the angle of the path tangent at the percentage *t.*
    /// The argument *t* has to be between 0 and 1.
    /// 
    /// Positive values for the angles mean counter-clockwise while negative values
    /// mean the clockwise direction. Zero degrees is at the 3 o'clock position.
    /// 
    /// Note that similarly to the other percent methods, the percentage measurement
    /// is not linear with regards to the length if curves are present
    /// in the path. When curves are present the percentage argument is mapped
    /// to the t parameter of the Bezier equations.
    fn angle_at_percent(&self, t: f32) -> f32 {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).angle_at_percent)(obj_data, t);
            ret_val
        }
    }
    /// 
    /// Returns the slope of the path at the percentage *t.* The
    /// argument *t* has to be between 0 and 1.
    /// 
    /// Note that similarly to other percent methods, the percentage measurement
    /// is not linear with regards to the length, if curves are present
    /// in the path. When curves are present the percentage argument is mapped
    /// to the t parameter of the Bezier equations.
    fn slope_at_percent(&self, t: f32) -> f32 {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).slope_at_percent)(obj_data, t);
            ret_val
        }
    }
    /// 
    /// Returns `true` if any point in the given *rectangle* intersects the
    /// path; otherwise returns `false.`
    /// 
    /// There is an intersection if any of the lines making up the
    /// rectangle crosses a part of the path or if any part of the
    /// rectangle overlaps with any area enclosed by the path. This
    /// function respects the current fillRule to determine what is
    /// considered inside the path.
    /// 
    /// **See also:** contains()
    /// 
    /// Returns `true` if the current path intersects at any point the given path *p.*
    /// Also returns `true` if the current path contains or is contained by any part of *p.*
    /// 
    /// Set operations on paths will treat the paths as areas. Non-closed
    /// paths will be treated as implicitly closed.
    /// 
    /// **See also:** contains()
    fn intersects<P: PainterPathType<'a>>(&self, p: &P) -> bool {
        let (obj_p_1, _funcs) = p.get_painter_path_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).intersects)(obj_data, obj_p_1);
            ret_val
        }
    }
    /// 
    /// Returns `true` if the given *point* is inside the path, otherwise
    /// returns `false.`
    /// 
    /// **See also:** intersects()
    /// 
    /// Returns `true` if the given *rectangle* is inside the path,
    /// otherwise returns `false.`
    /// 
    /// Returns `true` if the given path *p* is contained within
    /// the current path. Returns `false` if any edges of the current path and
    /// *p* intersect.
    /// 
    /// Set operations on paths will treat the paths as areas. Non-closed
    /// paths will be treated as implicitly closed.
    /// 
    /// **See also:** intersects()
    fn contains<P: PainterPathType<'a>>(&self, p: &P) -> bool {
        let (obj_p_1, _funcs) = p.get_painter_path_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).contains)(obj_data, obj_p_1);
            ret_val
        }
    }
    /// 
    /// Returns a path which is the union of this path's fill area and *p's* fill area.
    /// 
    /// Set operations on paths will treat the paths as areas. Non-closed
    /// paths will be treated as implicitly closed.
    /// Bezier curves may be flattened to line segments due to numerical instability of
    /// doing bezier curve intersections.
    /// 
    /// **See also:** intersected()
    /// subtracted()
    fn united<P: PainterPathType<'a>>(&self, r: &P) -> PainterPath {
        let (obj_r_1, _funcs) = r.get_painter_path_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).united)(obj_data, obj_r_1);
            let t = ret_val;
            let ret_val;
            if t.host_data != ::std::ptr::null() {
                ret_val = PainterPath::new_from_rc(t);
            } else {
                ret_val = PainterPath::new_from_owned(t);
            }
            ret_val
        }
    }
    /// 
    /// Returns a path which is the intersection of this path's fill area and *p's* fill area.
    /// Bezier curves may be flattened to line segments due to numerical instability of
    /// doing bezier curve intersections.
    fn intersected<P: PainterPathType<'a>>(&self, r: &P) -> PainterPath {
        let (obj_r_1, _funcs) = r.get_painter_path_obj_funcs();

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).intersected)(obj_data, obj_r_1);
            let t = ret_val;
            let ret_val;
            if t.host_data != ::std::ptr::null() {
                ret_val = PainterPath::new_from_rc(t);
            } else {
                ret_val = PainterPath::new_from_owned(t);
            }
            ret_val
        }
    }
    /// 
    /// Returns a simplified version of this path. This implies merging all subpaths that intersect,
    /// and returning a path containing no intersecting edges. Consecutive parallel lines will also
    /// be merged. The simplified path will always use the default fill rule, Qt::OddEvenFill.
    /// Bezier curves may be flattened to line segments due to numerical instability of
    /// doing bezier curve intersections.
    fn simplified(&self) -> PainterPath {

        let (obj_data, funcs) = self.get_painter_path_obj_funcs();
        unsafe {
            let ret_val = ((*funcs).simplified)(obj_data);
            let t = ret_val;
            let ret_val;
            if t.host_data != ::std::ptr::null() {
                ret_val = PainterPath::new_from_rc(t);
            } else {
                ret_val = PainterPath::new_from_owned(t);
            }
            ret_val
        }
    }

    #[inline]
    fn get_painter_path_obj_funcs(&self) -> (*const RUBase, *const RUPainterPathFuncs);
}

impl<'a> PainterPathType<'a> for PainterPath<'a> {
    #[inline]
    fn get_painter_path_obj_funcs(&self) -> (*const RUBase, *const RUPainterPathFuncs) {
        let obj = self.data.get().unwrap();
        unsafe {
            (obj, (*self.all_funcs).painter_path_funcs)
        }
    }
}