io.qt.gui.QRegion Maven / Gradle / Ivy
Show all versions of qtjambi Show documentation
package io.qt.gui;
import io.qt.*;
/**
* Specifies a clip region for a painter
* Java wrapper for Qt class QRegion
*/
public class QRegion extends QtObject
implements java.lang.Iterable,
java.lang.Cloneable
{
static {
QtJambi_LibraryUtilities.initialize();
}
/**
* Java wrapper for Qt enum QRegion::RegionType
*/
public enum RegionType implements QtEnumerator {
/**
* Representing QRegion:: Rectangle
*/
Rectangle(0),
/**
* Representing QRegion:: Ellipse
*/
Ellipse(1);
static {
QtJambi_LibraryUtilities.initialize();
}
private RegionType(int value) {
this.value = value;
}
/**
* {@inheritDoc}
*/
public int value() {
return value;
}
/**
* Returns the corresponding enum entry for the given value.
* @param value
* @return enum entry
*/
public static @NonNull RegionType resolve(int value) {
switch (value) {
case 0: return Rectangle;
case 1: return Ellipse;
default: throw new QNoSuchEnumValueException(value);
}
}
private final int value;
}
/**
*
*/
public QRegion(){
super((QPrivateConstructor)null);
initialize_native(this);
}
private native static void initialize_native(QRegion instance);
/**
*
*/
public QRegion(io.qt.gui.@NonNull QBitmap bitmap){
super((QPrivateConstructor)null);
initialize_native(this, bitmap);
}
private native static void initialize_native(QRegion instance, io.qt.gui.QBitmap bitmap);
/**
* See QRegion:: QRegion(QPolygon, Qt::FillRule)
*/
public QRegion(io.qt.gui.@NonNull QPolygon pa, io.qt.core.Qt.@NonNull FillRule fillRule){
super((QPrivateConstructor)null);
initialize_native(this, pa, fillRule);
}
private native static void initialize_native(QRegion instance, io.qt.gui.QPolygon pa, io.qt.core.Qt.FillRule fillRule);
/**
* See QRegion:: QRegion(QRect, QRegion::RegionType)
*/
public QRegion(io.qt.core.@NonNull QRect r, io.qt.gui.QRegion.@NonNull RegionType t){
super((QPrivateConstructor)null);
initialize_native(this, r, t);
}
private native static void initialize_native(QRegion instance, io.qt.core.QRect r, io.qt.gui.QRegion.RegionType t);
/**
*
*/
public QRegion(io.qt.gui.@NonNull QRegion region){
super((QPrivateConstructor)null);
initialize_native(this, region);
}
private native static void initialize_native(QRegion instance, io.qt.gui.QRegion region);
/**
* See QRegion:: QRegion(int, int, int, int, QRegion::RegionType)
*/
public QRegion(int x, int y, int w, int h, io.qt.gui.QRegion.@NonNull RegionType t){
super((QPrivateConstructor)null);
initialize_native(this, x, y, w, h, t);
}
private native static void initialize_native(QRegion instance, int x, int y, int w, int h, io.qt.gui.QRegion.RegionType t);
/**
*
*/
@QtUninvokable
protected final io.qt.core.@NonNull QSequentialConstIterator begin(){
return begin_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private native io.qt.core.QSequentialConstIterator begin_native_constfct(long __this__nativeId);
/**
* See QRegion:: 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 QRegion:: contains(QPoint)const
*/
@QtUninvokable
public final boolean contains(io.qt.core.@NonNull QPoint p){
return contains_native_cref_QPoint_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(p));
}
@QtUninvokable
private native boolean contains_native_cref_QPoint_constfct(long __this__nativeId, long p);
/**
* See QRegion:: contains(QRect)const
*/
@QtUninvokable
public final boolean contains(io.qt.core.@NonNull QRect r){
return contains_native_cref_QRect_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native boolean contains_native_cref_QRect_constfct(long __this__nativeId, long r);
/**
*
*/
@QtUninvokable
protected final io.qt.core.@NonNull QSequentialConstIterator end(){
return end_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private native io.qt.core.QSequentialConstIterator end_native_constfct(long __this__nativeId);
/**
* See QRegion:: intersected(QRect)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion intersected(io.qt.core.@NonNull QRect r){
return intersected_native_cref_QRect_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native io.qt.gui.QRegion intersected_native_cref_QRect_constfct(long __this__nativeId, long r);
/**
* See QRegion:: intersected(QRegion)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion intersected(io.qt.gui.@NonNull QRegion r){
return intersected_native_cref_QRegion_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native io.qt.gui.QRegion intersected_native_cref_QRegion_constfct(long __this__nativeId, long r);
/**
* See QRegion:: intersects(QRect)const
*/
@QtUninvokable
public final boolean intersects(io.qt.core.@NonNull QRect r){
return intersects_native_cref_QRect_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native boolean intersects_native_cref_QRect_constfct(long __this__nativeId, long r);
/**
* See QRegion:: intersects(QRegion)const
*/
@QtUninvokable
public final boolean intersects(io.qt.gui.@NonNull QRegion r){
return intersects_native_cref_QRegion_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native boolean intersects_native_cref_QRegion_constfct(long __this__nativeId, long r);
/**
*
*/
@QtUninvokable
public final boolean isEmpty(){
return isEmpty_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private native boolean isEmpty_native_constfct(long __this__nativeId);
/**
*
*/
@QtUninvokable
public final boolean isNull(){
return isNull_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private native boolean isNull_native_constfct(long __this__nativeId);
/**
* See operator*(QRegion, QTransform)
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion 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.QRegion times_native_cref_QTransform(long __this__nativeId, long m);
/**
* See QRegion:: operator+(QRect)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion plus(io.qt.core.@NonNull QRect r){
return plus_native_cref_QRect_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native io.qt.gui.QRegion plus_native_cref_QRect_constfct(long __this__nativeId, long r);
/**
* See QRegion:: operator+(QRegion)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion plus(io.qt.gui.@NonNull QRegion r){
return plus_native_cref_QRegion_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native io.qt.gui.QRegion plus_native_cref_QRegion_constfct(long __this__nativeId, long r);
/**
* See QRegion:: operator-(QRegion)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion minus(io.qt.gui.@NonNull QRegion r){
return minus_native_cref_QRegion_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native io.qt.gui.QRegion minus_native_cref_QRegion_constfct(long __this__nativeId, long r);
/**
* See operator<<(QDataStream&, QRegion)
*/
@QtUninvokable
public void writeTo(io.qt.core.@StrictNonNull QDataStream arg__1){
java.util.Objects.requireNonNull(arg__1, "Argument 'arg__1': null not expected.");
writeTo_native_ref_QDataStream(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(arg__1));
}
@QtUninvokable
private native void writeTo_native_ref_QDataStream(long __this__nativeId, long arg__1);
/**
* See QRegion:: operator=(QRegion)
*/
@QtUninvokable
public final void assign(io.qt.gui.@NonNull QRegion arg__1){
assign_native_cref_QRegion(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(arg__1));
}
@QtUninvokable
private native void assign_native_cref_QRegion(long __this__nativeId, long arg__1);
/**
* See QRegion:: operator==(QRegion)const
*/
@QtUninvokable
public final boolean equals(io.qt.gui.@NonNull QRegion r){
return equals_native_cref_QRegion_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native boolean equals_native_cref_QRegion_constfct(long __this__nativeId, long r);
/**
* See operator>>(QDataStream&, QRegion&)
*/
@QtUninvokable
public void readFrom(io.qt.core.@StrictNonNull QDataStream arg__1){
java.util.Objects.requireNonNull(arg__1, "Argument 'arg__1': null not expected.");
readFrom_native_ref_QDataStream(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(arg__1));
}
@QtUninvokable
private native void readFrom_native_ref_QDataStream(long __this__nativeId, long arg__1);
/**
*
*/
@QtUninvokable
public final int rectCount(){
return rectCount_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private native int rectCount_native_constfct(long __this__nativeId);
/**
* See QRegion:: setRects(const QRect*, int)
*/
@QtUninvokable
public final void setRects(io.qt.core.@NonNull QRect... rect){
setRects_native_const_QRect_ptr_int(QtJambi_LibraryUtilities.internal.nativeId(this), rect);
}
@QtUninvokable
private native void setRects_native_const_QRect_ptr_int(long __this__nativeId, io.qt.core.QRect[] rect);
/**
* See QRegion:: subtracted(QRegion)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion subtracted(io.qt.gui.@NonNull QRegion r){
return subtracted_native_cref_QRegion_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native io.qt.gui.QRegion subtracted_native_cref_QRegion_constfct(long __this__nativeId, long r);
/**
*
*/
@QtUninvokable
public final void swap(io.qt.gui.@StrictNonNull QRegion other){
java.util.Objects.requireNonNull(other, "Argument 'other': null not expected.");
swap_native_ref_QRegion(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(other));
}
@QtUninvokable
private native void swap_native_ref_QRegion(long __this__nativeId, long other);
/**
* See QRegion:: translate(QPoint)
*/
@QtUninvokable
public final void translate(io.qt.core.@NonNull QPoint p){
translate_native_cref_QPoint(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(p));
}
@QtUninvokable
private native void translate_native_cref_QPoint(long __this__nativeId, long p);
/**
* See QRegion:: 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 QRegion:: translated(QPoint)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion translated(io.qt.core.@NonNull QPoint p){
return translated_native_cref_QPoint_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(p));
}
@QtUninvokable
private native io.qt.gui.QRegion translated_native_cref_QPoint_constfct(long __this__nativeId, long p);
/**
* See QRegion:: translated(int, int)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion translated(int dx, int dy){
return translated_native_int_int_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), dx, dy);
}
@QtUninvokable
private native io.qt.gui.QRegion translated_native_int_int_constfct(long __this__nativeId, int dx, int dy);
/**
* See QRegion:: united(QRect)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion united(io.qt.core.@NonNull QRect r){
return united_native_cref_QRect_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native io.qt.gui.QRegion united_native_cref_QRect_constfct(long __this__nativeId, long r);
/**
* See QRegion:: united(QRegion)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion united(io.qt.gui.@NonNull QRegion r){
return united_native_cref_QRegion_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native io.qt.gui.QRegion united_native_cref_QRegion_constfct(long __this__nativeId, long r);
/**
* See QRegion:: xored(QRegion)const
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion xored(io.qt.gui.@NonNull QRegion r){
return xored_native_cref_QRegion_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(r));
}
@QtUninvokable
private native io.qt.gui.QRegion xored_native_cref_QRegion_constfct(long __this__nativeId, long r);
/**
* Returns an iterator for this iterable object.
* @see #begin()
* @see #end()
*/
@Override
public java.util.@NonNull Iterator iterator() {
return begin().iterator();
}
/**
* Constructor for internal use only.
* @param p expected to be null
.
* @hidden
*/
@NativeAccess
protected QRegion(QPrivateConstructor p) { super(p); }
/**
* See QRegion:: operator==(QRegion)const
*/
@Override
@QtUninvokable
public boolean equals(Object other) {
if (other instanceof io.qt.gui.QRegion) {
return equals((io.qt.gui.QRegion) other);
}
return false;
}
/**
* Returns the objects's hash code computed by qHash(QRegion)
.
*/
@QtUninvokable
@Override
public int hashCode() {
return hashCode_native(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private native static int hashCode_native(long __this_nativeId);
/**
* See operator<<(QDebug, QRegion)
*/
@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.
*/
@QtUninvokable
@Override
public QRegion clone() {
return clone_native(QtJambi_LibraryUtilities.internal.nativeId(this));
}
private static native QRegion clone_native(long __this_nativeId);
/**
* Overloaded constructor for {@link #QRegion(io.qt.gui.QPolygon, io.qt.core.Qt.FillRule)}
* with fillRule = io.qt.core.Qt.FillRule.OddEvenFill
.
*/
public QRegion(io.qt.gui.@NonNull QPolygon pa) {
this(pa, io.qt.core.Qt.FillRule.OddEvenFill);
}
/**
* Overloaded constructor for {@link #QRegion(io.qt.core.QRect, io.qt.gui.QRegion.RegionType)}
* with t = io.qt.gui.QRegion.RegionType.Rectangle
.
*/
public QRegion(io.qt.core.@NonNull QRect r) {
this(r, io.qt.gui.QRegion.RegionType.Rectangle);
}
/**
* Overloaded constructor for {@link #QRegion(int, int, int, int, io.qt.gui.QRegion.RegionType)}
* with t = io.qt.gui.QRegion.RegionType.Rectangle
.
*/
public QRegion(int x, int y, int w, int h) {
this(x, y, w, h, io.qt.gui.QRegion.RegionType.Rectangle);
}
/**
* Overloaded function for {@link #intersected(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion intersected(io.qt.gui.@NonNull QPolygon r) {
return intersected(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #intersected(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion intersected(io.qt.gui.@NonNull QBitmap r) {
return intersected(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #intersects(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final boolean intersects(io.qt.gui.@NonNull QPolygon r) {
return intersects(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #intersects(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final boolean intersects(io.qt.gui.@NonNull QBitmap r) {
return intersects(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #plus(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion plus(io.qt.gui.@NonNull QPolygon r) {
return plus(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #plus(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion plus(io.qt.gui.@NonNull QBitmap r) {
return plus(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #minus(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion minus(io.qt.core.@NonNull QRect r) {
return minus(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #minus(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion minus(io.qt.gui.@NonNull QPolygon r) {
return minus(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #minus(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion minus(io.qt.gui.@NonNull QBitmap r) {
return minus(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #assign(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final void assign(io.qt.core.@NonNull QRect arg__1) {
assign(new io.qt.gui.QRegion(arg__1));
}
/**
* Overloaded function for {@link #assign(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final void assign(io.qt.gui.@NonNull QPolygon arg__1) {
assign(new io.qt.gui.QRegion(arg__1));
}
/**
* Overloaded function for {@link #assign(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final void assign(io.qt.gui.@NonNull QBitmap arg__1) {
assign(new io.qt.gui.QRegion(arg__1));
}
/**
* Overloaded function for {@link #equals(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final boolean equals(io.qt.core.@NonNull QRect r) {
return equals(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #equals(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final boolean equals(io.qt.gui.@NonNull QPolygon r) {
return equals(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #equals(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final boolean equals(io.qt.gui.@NonNull QBitmap r) {
return equals(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #subtracted(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion subtracted(io.qt.core.@NonNull QRect r) {
return subtracted(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #subtracted(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion subtracted(io.qt.gui.@NonNull QPolygon r) {
return subtracted(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #subtracted(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion subtracted(io.qt.gui.@NonNull QBitmap r) {
return subtracted(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #united(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion united(io.qt.gui.@NonNull QPolygon r) {
return united(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #united(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion united(io.qt.gui.@NonNull QBitmap r) {
return united(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #xored(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion xored(io.qt.core.@NonNull QRect r) {
return xored(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #xored(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion xored(io.qt.gui.@NonNull QPolygon r) {
return xored(new io.qt.gui.QRegion(r));
}
/**
* Overloaded function for {@link #xored(io.qt.gui.QRegion)}.
*/
@QtUninvokable
public final io.qt.gui.@NonNull QRegion xored(io.qt.gui.@NonNull QBitmap r) {
return xored(new io.qt.gui.QRegion(r));
}
}