io.qt.gui.QPolygon Maven / Gradle / Ivy
Show all versions of qtjambi Show documentation
package io.qt.gui;
import io.qt.*;
import io.qt.core.QPoint;
/**
* List of points using integer precision
* Java wrapper for Qt class QPolygon
*/
public class QPolygon extends io.qt.core.QList
implements java.lang.Cloneable
{
static {
QtJambi_LibraryUtilities.initialize();
}
/**
*
*/
public QPolygon(){
super((QPrivateConstructor)null);
initialize_native(this);
}
private native static void initialize_native(QPolygon instance);
/**
* See QPolygon:: QPolygon(QList<QPoint>)
*/
public QPolygon(java.util.@NonNull Collection extends io.qt.core.@NonNull QPoint> v){
super((QPrivateConstructor)null);
initialize_native(this, v);
}
private native static void initialize_native(QPolygon instance, java.util.Collection extends io.qt.core.QPoint> v);
/**
* See QPolygon:: QPolygon(QPolygon)
*/
public QPolygon(io.qt.gui.@NonNull QPolygon other){
super((QPrivateConstructor)null);
initialize_native(this, other);
}
private native static void initialize_native(QPolygon instance, io.qt.gui.QPolygon other);
/**
* See QPolygon:: QPolygon(QRect, bool)
*/
public QPolygon(io.qt.core.@NonNull QRect r, boolean closed){
super((QPrivateConstructor)null);
initialize_native(this, r, closed);
}
private native static void initialize_native(QPolygon instance, io.qt.core.QRect r, boolean closed);
/**
* See QPolygon:: QPolygon(int, const int*)
*/
public QPolygon(java.nio.@StrictNonNull IntBuffer points){
super((QPrivateConstructor)null);
java.util.Objects.requireNonNull(points, "Argument 'points': null not expected.");
initialize_native(this, points);
}
private native static void initialize_native(QPolygon instance, java.nio.IntBuffer points);
/**
* See QPolygon:: boundingRect()const
*/
@QtUninvokable
public final io.qt.core.@NonNull QRect boundingRect(){
return boundingRect_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private native io.qt.core.QRect boundingRect_native_constfct(long __this__nativeId);
/**
* See QPolygon:: containsPoint(QPoint, Qt::FillRule)const
*/
@QtUninvokable
public final boolean containsPoint(io.qt.core.@NonNull QPoint pt, io.qt.core.Qt.@NonNull FillRule fillRule){
return containsPoint_native_cref_QPoint_Qt_FillRule_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(pt), fillRule.value());
}
@QtUninvokable
private native boolean containsPoint_native_cref_QPoint_Qt_FillRule_constfct(long __this__nativeId, long pt, int fillRule);
/**
* See QPolygon:: intersected(QPolygon)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QPolygon intersected(io.qt.gui.@NonNull QPolygon r){
return intersected_native_cref_QPolygon_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native io.qt.gui.QPolygon intersected_native_cref_QPolygon_constfct(long __this__nativeId, long r);
/**
* See QPolygon:: intersects(QPolygon)const
*/
@QtUninvokable
public final boolean intersects(io.qt.gui.@NonNull QPolygon r){
return intersects_native_cref_QPolygon_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native boolean intersects_native_cref_QPolygon_constfct(long __this__nativeId, long r);
/**
* See operator*(QPolygon, QTransform)
*/
@QtUninvokable
public final io.qt.gui.@NonNull QPolygon times(io.qt.gui.@NonNull QTransform m){
return times_native_cref_QTransform(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(m));
}
@QtUninvokable
private native io.qt.gui.QPolygon times_native_cref_QTransform(long __this__nativeId, long m);
/**
* See operator<<(QDataStream&, QPolygon)
*/
@QtUninvokable
public void writeTo(io.qt.core.@StrictNonNull QDataStream stream){
java.util.Objects.requireNonNull(stream, "Argument 'stream': null not expected.");
writeTo_native_ref_QDataStream(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(stream));
}
@QtUninvokable
private native void writeTo_native_ref_QDataStream(long __this__nativeId, long stream);
/**
* See operator>>(QDataStream&, QPolygon&)
*/
@QtUninvokable
public void readFrom(io.qt.core.@StrictNonNull QDataStream stream){
java.util.Objects.requireNonNull(stream, "Argument 'stream': null not expected.");
readFrom_native_ref_QDataStream(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(stream));
}
@QtUninvokable
private native void readFrom_native_ref_QDataStream(long __this__nativeId, long stream);
/**
*
*/
@QtUninvokable
public final io.qt.core.@NonNull QPoint point(int i){
return point_native_int_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), i);
}
@QtUninvokable
private native io.qt.core.QPoint point_native_int_constfct(long __this__nativeId, int i);
/**
* See QPolygon:: putPoints(int, int, QPolygon, int)
*/
@QtUninvokable
public final void putPoints(int index, int nPoints, io.qt.gui.@NonNull QPolygon from, int fromIndex){
putPoints_native_int_int_cref_QPolygon_int(QtJambi_LibraryUtilities.internal.nativeId(this), index, nPoints, QtJambi_LibraryUtilities.internal.checkedNativeId(from), fromIndex);
}
@QtUninvokable
private native void putPoints_native_int_int_cref_QPolygon_int(long __this__nativeId, int index, int nPoints, long from, int fromIndex);
/**
* See QPolygon:: putPoints(int, int, const int*)
*/
@QtUninvokable
public final void putPoints(int index, java.nio.@StrictNonNull IntBuffer points){
java.util.Objects.requireNonNull(points, "Argument 'points': null not expected.");
putPoints_native_int_int_const_int_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), index, points);
}
@QtUninvokable
private native void putPoints_native_int_int_const_int_ptr(long __this__nativeId, int index, java.nio.IntBuffer points);
/**
* See QPolygon:: setPoint(int, QPoint)
*/
@QtUninvokable
public final void setPoint(int index, io.qt.core.@NonNull QPoint p){
setPoint_native_int_cref_QPoint(QtJambi_LibraryUtilities.internal.nativeId(this), index, QtJambi_LibraryUtilities.internal.checkedNativeId(p));
}
@QtUninvokable
private native void setPoint_native_int_cref_QPoint(long __this__nativeId, int index, long p);
/**
* See QPolygon:: setPoint(int, int, int)
*/
@QtUninvokable
public final void setPoint(int index, int x, int y){
setPoint_native_int_int_int(QtJambi_LibraryUtilities.internal.nativeId(this), index, x, y);
}
@QtUninvokable
private native void setPoint_native_int_int_int(long __this__nativeId, int index, int x, int y);
/**
* See QPolygon:: setPoints(int, const int*)
*/
@QtUninvokable
public final void setPoints(java.nio.@StrictNonNull IntBuffer points){
java.util.Objects.requireNonNull(points, "Argument 'points': null not expected.");
setPoints_native_int_const_int_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), points);
}
@QtUninvokable
private native void setPoints_native_int_const_int_ptr(long __this__nativeId, java.nio.IntBuffer points);
/**
* See QPolygon:: subtracted(QPolygon)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QPolygon subtracted(io.qt.gui.@NonNull QPolygon r){
return subtracted_native_cref_QPolygon_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native io.qt.gui.QPolygon subtracted_native_cref_QPolygon_constfct(long __this__nativeId, long r);
/**
*
*/
@QtUninvokable
public final void swap(io.qt.gui.@StrictNonNull QPolygon other){
java.util.Objects.requireNonNull(other, "Argument 'other': null not expected.");
swap_native_ref_QPolygon(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(other));
}
@QtUninvokable
private native void swap_native_ref_QPolygon(long __this__nativeId, long other);
/**
* See QPolygon:: toPolygonF()const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QPolygonF toPolygonF(){
return toPolygonF_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private native io.qt.gui.QPolygonF toPolygonF_native_constfct(long __this__nativeId);
/**
* See QPolygon:: translate(QPoint)
*/
@QtUninvokable
public final void translate(io.qt.core.@NonNull QPoint offset){
translate_native_cref_QPoint(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(offset));
}
@QtUninvokable
private native void translate_native_cref_QPoint(long __this__nativeId, long offset);
/**
* See QPolygon:: translate(int, int)
*/
@QtUninvokable
public final void translate(int dx, int dy){
translate_native_int_int(QtJambi_LibraryUtilities.internal.nativeId(this), dx, dy);
}
@QtUninvokable
private native void translate_native_int_int(long __this__nativeId, int dx, int dy);
/**
* See QPolygon:: translated(QPoint)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QPolygon translated(io.qt.core.@NonNull QPoint offset){
return translated_native_cref_QPoint_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(offset));
}
@QtUninvokable
private native io.qt.gui.QPolygon translated_native_cref_QPoint_constfct(long __this__nativeId, long offset);
/**
* See QPolygon:: translated(int, int)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QPolygon translated(int dx, int dy){
return translated_native_int_int_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), dx, dy);
}
@QtUninvokable
private native io.qt.gui.QPolygon translated_native_int_int_constfct(long __this__nativeId, int dx, int dy);
/**
* See QPolygon:: united(QPolygon)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QPolygon united(io.qt.gui.@NonNull QPolygon r){
return united_native_cref_QPolygon_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native io.qt.gui.QPolygon united_native_cref_QPolygon_constfct(long __this__nativeId, long r);
/**
* Constructor for internal use only.
* @param p expected to be null
.
* @hidden
*/
@NativeAccess
protected QPolygon(QPrivateConstructor p) { super(p); }
/**
* Returns the objects's hash code computed by qHash(QPolygon)
.
*/
@QtUninvokable
@Override
public int hashCode() {
return hashCode_native(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private native static int hashCode_native(long __this_nativeId);
@QtUninvokable
public final void append(int x, int y) {
append(new QPoint(x, y));
}
/**
* See operator<<(QDebug, QPolygon)
*/
@QtUninvokable
@Override
public @NonNull String toString() {
return toString_native(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private static native String toString_native(long __this_nativeId);
/**
* Creates and returns a copy of this object.
See QPolygon:: QPolygon(QPolygon)
*/
@QtUninvokable
@Override
public QPolygon clone() {
return clone_native(QtJambi_LibraryUtilities.internal.nativeId(this));
}
private static native QPolygon clone_native(long __this_nativeId);
/**
* Overloaded constructor for {@link #QPolygon(io.qt.core.QRect, boolean)}
* with closed = false
.
*/
public QPolygon(io.qt.core.@NonNull QRect r) {
this(r, (boolean)false);
}
/**
* Overloaded constructor for {@link #QPolygon(java.nio.IntBuffer)}.
*/
public QPolygon(int @StrictNonNull... points) {
this(points==null ? null : java.nio.IntBuffer.wrap(points));
}
/**
* Overloaded function for {@link #putPoints(int, int, io.qt.gui.QPolygon, int)}
* with fromIndex = 0
.
*/
@QtUninvokable
public final void putPoints(int index, int nPoints, io.qt.gui.@NonNull QPolygon from) {
putPoints(index, nPoints, from, (int)0);
}
/**
* Overloaded function for {@link #putPoints(int, java.nio.IntBuffer)}.
*/
@QtUninvokable
public final void putPoints(int index, int @StrictNonNull... points) {
putPoints(index, points==null ? null : java.nio.IntBuffer.wrap(points));
}
/**
* Overloaded function for {@link #setPoints(java.nio.IntBuffer)}.
*/
@QtUninvokable
public final void setPoints(int @StrictNonNull... points) {
setPoints(points==null ? null : java.nio.IntBuffer.wrap(points));
}
}