Skip to content

Commit aca420e

Browse files
authored
Merge branch 'master' into voidptr
2 parents f253130 + 343aada commit aca420e

File tree

3 files changed

+17
-12
lines changed

3 files changed

+17
-12
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
1616

1717
### Changed
1818
* [#104](https://github.com/stlehmann/PyQt5-stubs/pull/104) `sip.voidptr` handles integer values and sequences and takes `self`
19+
* [#103](https://github.com/stlehmann/PyQt5-stubs/pull/103) `pyqtBoundSignal.disconnect()`'s `slot` parameter is optional
20+
* [#100](https://github.com/stlehmann/PyQt5-stubs/pull/100) fill generic parameter as `sip.array[int]` for QtDataVisualization textures
1921
* [#92](https://github.com/stlehmann/PyQt5-stubs/pull/92) remove self from `qDefaultSurfaceFormat()` and `qIdForNode()`
2022
* [#83](https://github.com/stlehmann/PyQt5-stubs/pull/83) fixes `sip.array` to be generic
2123
* [#79](https://github.com/stlehmann/PyQt5-stubs/pull/79) fixes extra class layer in several modules

PyQt5-stubs/QtCore.pyi

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,10 @@ class pyqtBoundSignal:
3535

3636
def emit(self, *args: typing.Any) -> None: ...
3737
def connect(self, slot: "PYQT_SLOT") -> "QMetaObject.Connection": ...
38-
def disconnect(self, slot: typing.Union["PYQT_SLOT", "QMetaObject.Connection"]=None) -> None: ...
38+
@typing.overload
39+
def disconnect(self) -> None: ...
40+
@typing.overload
41+
def disconnect(self, slot: typing.Union["PYQT_SLOT", "QMetaObject.Connection"]) -> None: ...
3942

4043

4144
class pyqtSignal:
@@ -2289,12 +2292,12 @@ class QIODevice(QObject):
22892292
def __invert__(self) -> 'QIODevice.OpenMode': ...
22902293
def __index__(self) -> int: ...
22912294
def __int__(self) -> int: ...
2292-
def __and__(self, other: typing.Union['QIODevice.OpenMode', 'QIODevice.OpenModeFlag']) -> 'QIODevice.OpenMode': ... #type: ignore[override]
2293-
def __iand__(self, other: typing.Union['QIODevice.OpenMode', 'QIODevice.OpenModeFlag']) -> 'QIODevice.OpenMode': ... #type: ignore[override]
2294-
def __or__(self, other: typing.Union['QIODevice.OpenMode', 'QIODevice.OpenModeFlag']) -> 'QIODevice.OpenMode': ... #type: ignore[override]
2295-
def __ior__(self, other: typing.Union['QIODevice.OpenMode', 'QIODevice.OpenModeFlag']) -> 'QIODevice.OpenMode': ... #type: ignore[override]
2296-
def __xor__(self, other: typing.Union['QIODevice.OpenMode', 'QIODevice.OpenModeFlag']) -> 'QIODevice.OpenMode': ... #type: ignore[override]
2297-
def __ixor__(self, other: typing.Union['QIODevice.OpenMode', 'QIODevice.OpenModeFlag']) -> 'QIODevice.OpenMode': ... #type: ignore[override]
2295+
def __and__(self, other: typing.Union['QIODevice.OpenMode', 'QIODevice.OpenModeFlag']) -> 'QIODevice.OpenMode': ...
2296+
def __iand__(self, other: typing.Union['QIODevice.OpenMode', 'QIODevice.OpenModeFlag']) -> 'QIODevice.OpenMode': ...
2297+
def __or__(self, other: typing.Union['QIODevice.OpenMode', 'QIODevice.OpenModeFlag']) -> 'QIODevice.OpenMode': ...
2298+
def __ior__(self, other: typing.Union['QIODevice.OpenMode', 'QIODevice.OpenModeFlag']) -> 'QIODevice.OpenMode': ...
2299+
def __xor__(self, other: typing.Union['QIODevice.OpenMode', 'QIODevice.OpenModeFlag']) -> 'QIODevice.OpenMode': ...
2300+
def __ixor__(self, other: typing.Union['QIODevice.OpenMode', 'QIODevice.OpenModeFlag']) -> 'QIODevice.OpenMode': ...
22982301

22992302
@typing.overload
23002303
def __init__(self) -> None: ...

PyQt5-stubs/QtDataVisualization.pyi

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -834,7 +834,7 @@ class QCustom3DVolume('QCustom3DItem'):
834834
@typing.overload
835835
def __init__(self, parent: typing.Optional[QtCore.QObject] = ...) -> None: ...
836836
@typing.overload
837-
def __init__(self, position: QtGui.QVector3D, scaling: QtGui.QVector3D, rotation: QtGui.QQuaternion, textureWidth: int, textureHeight: int, textureDepth: int, textureData: sip.array, textureFormat: QtGui.QImage.Format, colorTable: typing.Iterable[int], parent: typing.Optional[QtCore.QObject] = ...) -> None: ...
837+
def __init__(self, position: QtGui.QVector3D, scaling: QtGui.QVector3D, rotation: QtGui.QQuaternion, textureWidth: int, textureHeight: int, textureDepth: int, textureData: sip.array[int], textureFormat: QtGui.QImage.Format, colorTable: typing.Iterable[int], parent: typing.Optional[QtCore.QObject] = ...) -> None: ...
838838

839839
def sliceFrameThicknessesChanged(self, values: QtGui.QVector3D) -> None: ...
840840
def sliceFrameGapsChanged(self, values: QtGui.QVector3D) -> None: ...
@@ -846,7 +846,7 @@ class QCustom3DVolume('QCustom3DItem'):
846846
def preserveOpacityChanged(self, enabled: bool) -> None: ...
847847
def alphaMultiplierChanged(self, mult: float) -> None: ...
848848
def textureFormatChanged(self, format: QtGui.QImage.Format) -> None: ...
849-
def textureDataChanged(self, data: sip.array) -> None: ...
849+
def textureDataChanged(self, data: sip.array[int]) -> None: ...
850850
def colorTableChanged(self) -> None: ...
851851
def sliceIndexZChanged(self, value: int) -> None: ...
852852
def sliceIndexYChanged(self, value: int) -> None: ...
@@ -879,9 +879,9 @@ class QCustom3DVolume('QCustom3DItem'):
879879
def setSubTextureData(self, axis: QtCore.Qt.Axis, index: int, data: sip.voidptr) -> None: ...
880880
@typing.overload
881881
def setSubTextureData(self, axis: QtCore.Qt.Axis, index: int, image: QtGui.QImage) -> None: ...
882-
def textureData(self) -> sip.array: ...
883-
def createTextureData(self, images: typing.Iterable[QtGui.QImage]) -> sip.array: ...
884-
def setTextureData(self, data: sip.array) -> None: ...
882+
def textureData(self) -> sip.array[int]: ...
883+
def createTextureData(self, images: typing.Iterable[QtGui.QImage]) -> sip.array[int]: ...
884+
def setTextureData(self, data: sip.array[int]) -> None: ...
885885
def colorTable(self) -> typing.List[int]: ...
886886
def setColorTable(self, colors: typing.Iterable[int]) -> None: ...
887887
def setSliceIndices(self, x: int, y: int, z: int) -> None: ...

0 commit comments

Comments
 (0)