All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.qt.widgets.QStyleOptionTab Maven / Gradle / Ivy

There is a newer version: 6.8.0
Show newest version
package io.qt.widgets;

import io.qt.*;


/**
 * 

Used to describe the parameters for drawing a tab bar

*

Java wrapper for Qt class QStyleOptionTab

*/ public class QStyleOptionTab extends io.qt.widgets.QStyleOption implements java.lang.Cloneable { /** *

Java wrapper for Qt enum QStyleOptionTab::CornerWidget

* * @see CornerWidgets */ public enum CornerWidget implements QtFlagEnumerator { /** *

Representing QStyleOptionTab::NoCornerWidgets

*/ NoCornerWidgets(0), /** *

Representing QStyleOptionTab::LeftCornerWidget

*/ LeftCornerWidget(1), /** *

Representing QStyleOptionTab::RightCornerWidget

*/ RightCornerWidget(2); static { QtJambi_LibraryUtilities.initialize(); } private CornerWidget(int value) { this.value = value; } /** * {@inheritDoc} */ @Override public int value() { return value; } /** * Create a QFlags of the enum entry. * @return QFlags */ @Override public @NonNull CornerWidgets asFlags() { return new CornerWidgets(value); } /** * Combines this entry with other enum entry. * @param e enum entry * @return new flag */ public @NonNull CornerWidgets combined(@NonNull CornerWidget e) { return asFlags().setFlag(e, true); } /** * Excludes other enum entry from a flag of this entry. * @param e enum entry * @return new flag */ public @NonNull CornerWidgets cleared(@NonNull CornerWidget e) { return asFlags().setFlag(e, false); } /** * Creates a new {@link CornerWidgets} from the entries. * @param values entries * @return new flag */ public static @NonNull CornerWidgets flags(@Nullable CornerWidget @NonNull... values) { return new CornerWidgets(values); } /** * Returns the corresponding enum entry for the given value. * @param value * @return enum entry */ public static @NonNull CornerWidget resolve(int value) { switch (value) { case 0: return NoCornerWidgets; case 1: return LeftCornerWidget; case 2: return RightCornerWidget; default: throw new QNoSuchEnumValueException(value); } } private final int value; } /** * {@link QFlags} type for enum {@link CornerWidget} */ public static final class CornerWidgets extends QFlags implements Comparable { private static final long serialVersionUID = 0x4af7f516cae3bc48L; static { QtJambi_LibraryUtilities.initialize(); } /** * Creates a new CornerWidgets where the flags in args are set. * @param args enum entries */ public CornerWidgets(@Nullable CornerWidget @NonNull... args){ super(args); } /** * Creates a new CornerWidgets with given value. * @param value */ public CornerWidgets(int value) { super(value); } /** * Combines this flags with enum entry. * @param e enum entry * @return new CornerWidgets */ @Override public final @NonNull CornerWidgets combined(@StrictNonNull CornerWidget e){ return new CornerWidgets(value() | e.value()); } /** * Sets the flag e * @param e enum entry * @return this */ @Override public final @NonNull CornerWidgets setFlag(@Nullable CornerWidget e){ return setFlag(e, true); } /** * Sets or clears the flag flag * @param e enum entry * @param on set (true) or clear (false) * @return this */ @Override public final @NonNull CornerWidgets setFlag(@Nullable CornerWidget e, boolean on){ if (on) { setValue(value() | e.value()); }else { setValue(value() & ~e.value()); } return this; } /** * Returns an array of flag objects represented by this CornerWidgets. * @return array of enum entries */ @Override public final @NonNull CornerWidget @NonNull[] flags(){ return super.flags(CornerWidget.values()); } /** * {@inheritDoc} */ @Override public final @NonNull CornerWidgets clone(){ return new CornerWidgets(value()); } /** * {@inheritDoc} */ @Override public final int compareTo(@StrictNonNull CornerWidgets other){ return Integer.compare(value(), other.value()); } } /** *

Java wrapper for Qt enum QStyleOptionTab::SelectedPosition

*/ public enum SelectedPosition implements QtEnumerator { /** *

Representing QStyleOptionTab::NotAdjacent

*/ NotAdjacent(0), /** *

Representing QStyleOptionTab::NextIsSelected

*/ NextIsSelected(1), /** *

Representing QStyleOptionTab::PreviousIsSelected

*/ PreviousIsSelected(2); static { QtJambi_LibraryUtilities.initialize(); } private SelectedPosition(int value) { this.value = value; } /** * {@inheritDoc} */ @Override public int value() { return value; } /** * Returns the corresponding enum entry for the given value. * @param value * @return enum entry */ public static @NonNull SelectedPosition resolve(int value) { switch (value) { case 0: return NotAdjacent; case 1: return NextIsSelected; case 2: return PreviousIsSelected; default: throw new QNoSuchEnumValueException(value); } } private final int value; } /** *

Java wrapper for Qt enum QStyleOptionTab::TabFeature

* * @see TabFeatures */ public enum TabFeature implements QtFlagEnumerator { /** *

Representing QStyleOptionTab::None

*/ None(0), /** *

Representing QStyleOptionTab::HasFrame

*/ HasFrame(1); static { QtJambi_LibraryUtilities.initialize(); } private TabFeature(int value) { this.value = value; } /** * {@inheritDoc} */ @Override public int value() { return value; } /** * Create a QFlags of the enum entry. * @return QFlags */ @Override public @NonNull TabFeatures asFlags() { return new TabFeatures(value); } /** * Combines this entry with other enum entry. * @param e enum entry * @return new flag */ public @NonNull TabFeatures combined(@NonNull TabFeature e) { return asFlags().setFlag(e, true); } /** * Excludes other enum entry from a flag of this entry. * @param e enum entry * @return new flag */ public @NonNull TabFeatures cleared(@NonNull TabFeature e) { return asFlags().setFlag(e, false); } /** * Creates a new {@link TabFeatures} from the entries. * @param values entries * @return new flag */ public static @NonNull TabFeatures flags(@Nullable TabFeature @NonNull... values) { return new TabFeatures(values); } /** * Returns the corresponding enum entry for the given value. * @param value * @return enum entry */ public static @NonNull TabFeature resolve(int value) { switch (value) { case 0: return None; case 1: return HasFrame; default: throw new QNoSuchEnumValueException(value); } } private final int value; } /** * {@link QFlags} type for enum {@link TabFeature} */ public static final class TabFeatures extends QFlags implements Comparable { private static final long serialVersionUID = 0x83a8b592e1d9c4dfL; static { QtJambi_LibraryUtilities.initialize(); } /** * Creates a new TabFeatures where the flags in args are set. * @param args enum entries */ public TabFeatures(@Nullable TabFeature @NonNull... args){ super(args); } /** * Creates a new TabFeatures with given value. * @param value */ public TabFeatures(int value) { super(value); } /** * Combines this flags with enum entry. * @param e enum entry * @return new TabFeatures */ @Override public final @NonNull TabFeatures combined(@StrictNonNull TabFeature e){ return new TabFeatures(value() | e.value()); } /** * Sets the flag e * @param e enum entry * @return this */ @Override public final @NonNull TabFeatures setFlag(@Nullable TabFeature e){ return setFlag(e, true); } /** * Sets or clears the flag flag * @param e enum entry * @param on set (true) or clear (false) * @return this */ @Override public final @NonNull TabFeatures setFlag(@Nullable TabFeature e, boolean on){ if (on) { setValue(value() | e.value()); }else { setValue(value() & ~e.value()); } return this; } /** * Returns an array of flag objects represented by this TabFeatures. * @return array of enum entries */ @Override public final @NonNull TabFeature @NonNull[] flags(){ return super.flags(TabFeature.values()); } /** * {@inheritDoc} */ @Override public final @NonNull TabFeatures clone(){ return new TabFeatures(value()); } /** * {@inheritDoc} */ @Override public final int compareTo(@StrictNonNull TabFeatures other){ return Integer.compare(value(), other.value()); } } /** *

Java wrapper for Qt enum QStyleOptionTab::TabPosition

*/ public enum TabPosition implements QtEnumerator { /** *

Representing QStyleOptionTab::Beginning

*/ Beginning(0), /** *

Representing QStyleOptionTab::Middle

*/ Middle(1), /** *

Representing QStyleOptionTab::End

*/ End(2), /** *

Representing QStyleOptionTab::OnlyOneTab

*/ OnlyOneTab(3), /** *

Representing QStyleOptionTab::Moving

*/ Moving(4); static { QtJambi_LibraryUtilities.initialize(); } private TabPosition(int value) { this.value = value; } /** * {@inheritDoc} */ @Override public int value() { return value; } /** * Returns the corresponding enum entry for the given value. * @param value * @return enum entry */ public static @NonNull TabPosition resolve(int value) { switch (value) { case 0: return Beginning; case 1: return Middle; case 2: return End; case 3: return OnlyOneTab; case 4: return Moving; default: throw new QNoSuchEnumValueException(value); } } private final int value; } /** *

See QStyleOptionTab::QStyleOptionTab()

*/ public QStyleOptionTab(){ super((QPrivateConstructor)null); initialize_native(this); } private native static void initialize_native(QStyleOptionTab instance); /** *

See QStyleOptionTab::QStyleOptionTab(QStyleOptionTab)

*/ public QStyleOptionTab(io.qt.widgets.@NonNull QStyleOptionTab other){ super((QPrivateConstructor)null); initialize_native(this, other); } private native static void initialize_native(QStyleOptionTab instance, io.qt.widgets.QStyleOptionTab other); /** *

See QStyleOptionTab::operator=(QStyleOptionTab)

*/ @QtUninvokable public final void assign(io.qt.widgets.@NonNull QStyleOptionTab arg__1){ assign_native_cref_QStyleOptionTab(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(arg__1)); } @QtUninvokable private native void assign_native_cref_QStyleOptionTab(long __this__nativeId, long arg__1); /** *

OR combination of CornerWidget values indicating the corner widgets of the tab bar

*

See QStyleOptionTab::cornerWidgets

*/ @QtUninvokable public final void setCornerWidgets(io.qt.widgets.QStyleOptionTab.@NonNull CornerWidgets cornerWidgets){ setCornerWidgets_native_cref_QStyleOptionTab_CornerWidgets(QtJambi_LibraryUtilities.internal.nativeId(this), cornerWidgets.value()); } @QtUninvokable private native void setCornerWidgets_native_cref_QStyleOptionTab_CornerWidgets(long __this__nativeId, int cornerWidgets); /** *

OR combination of CornerWidget values indicating the corner widgets of the tab bar

*

See QStyleOptionTab::cornerWidgets

*/ @QtUninvokable public final io.qt.widgets.QStyleOptionTab.@NonNull CornerWidgets cornerWidgets(){ return new io.qt.widgets.QStyleOptionTab.CornerWidgets(cornerWidgets_native(QtJambi_LibraryUtilities.internal.nativeId(this))); } @QtUninvokable private native int cornerWidgets_native(long __this__nativeId); /** *

Whether the tabbar is in document mode

*

See QStyleOptionTab::documentMode

*/ @QtUninvokable public final void setDocumentMode(boolean documentMode){ setDocumentMode_native_bool(QtJambi_LibraryUtilities.internal.nativeId(this), documentMode); } @QtUninvokable private native void setDocumentMode_native_bool(long __this__nativeId, boolean documentMode); /** *

Whether the tabbar is in document mode

*

See QStyleOptionTab::documentMode

*/ @QtUninvokable public final boolean documentMode(){ return documentMode_native(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native boolean documentMode_native(long __this__nativeId); /** *

See QStyleOptionTab::features

*/ @QtUninvokable public final void setFeatures(io.qt.widgets.QStyleOptionTab.@NonNull TabFeatures features){ setFeatures_native_cref_QStyleOptionTab_TabFeatures(QtJambi_LibraryUtilities.internal.nativeId(this), features.value()); } @QtUninvokable private native void setFeatures_native_cref_QStyleOptionTab_TabFeatures(long __this__nativeId, int features); /** *

See QStyleOptionTab::features

*/ @QtUninvokable public final io.qt.widgets.QStyleOptionTab.@NonNull TabFeatures features(){ return new io.qt.widgets.QStyleOptionTab.TabFeatures(features_native(QtJambi_LibraryUtilities.internal.nativeId(this))); } @QtUninvokable private native int features_native(long __this__nativeId); /** *

The icon for the tab

*

See QStyleOptionTab::icon

*/ @QtUninvokable public final void setIcon(io.qt.gui.@NonNull QIcon icon){ setIcon_native_cref_QIcon(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(icon)); } @QtUninvokable private native void setIcon_native_cref_QIcon(long __this__nativeId, long icon); /** *

The icon for the tab

*

See QStyleOptionTab::icon

*/ @QtUninvokable public final io.qt.gui.@NonNull QIcon icon(){ return icon_native(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native io.qt.gui.QIcon icon_native(long __this__nativeId); /** *

The size for the icons

*

See QStyleOptionTab::iconSize

*/ @QtUninvokable public final void setIconSize(io.qt.core.@NonNull QSize iconSize){ setIconSize_native_cref_QSize(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(iconSize)); } @QtUninvokable private native void setIconSize_native_cref_QSize(long __this__nativeId, long iconSize); /** *

The size for the icons

*

See QStyleOptionTab::iconSize

*/ @QtUninvokable public final io.qt.core.@NonNull QSize iconSize(){ return iconSize_native(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native io.qt.core.QSize iconSize_native(long __this__nativeId); /** *

The size for the left widget on the tab

*

See QStyleOptionTab::leftButtonSize

*/ @QtUninvokable public final void setLeftButtonSize(io.qt.core.@NonNull QSize leftButtonSize){ setLeftButtonSize_native_cref_QSize(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(leftButtonSize)); } @QtUninvokable private native void setLeftButtonSize_native_cref_QSize(long __this__nativeId, long leftButtonSize); /** *

The size for the left widget on the tab

*

See QStyleOptionTab::leftButtonSize

*/ @QtUninvokable public final io.qt.core.@NonNull QSize leftButtonSize(){ return leftButtonSize_native(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native io.qt.core.QSize leftButtonSize_native(long __this__nativeId); /** *

The position of the tab in the tab bar

*

See QStyleOptionTab::position

*/ @QtUninvokable public final void setPosition(io.qt.widgets.QStyleOptionTab.@NonNull TabPosition position){ setPosition_native_cref_QStyleOptionTab_TabPosition(QtJambi_LibraryUtilities.internal.nativeId(this), position.value()); } @QtUninvokable private native void setPosition_native_cref_QStyleOptionTab_TabPosition(long __this__nativeId, int position); /** *

The position of the tab in the tab bar

*

See QStyleOptionTab::position

*/ @QtUninvokable public final io.qt.widgets.QStyleOptionTab.@NonNull TabPosition position(){ return io.qt.widgets.QStyleOptionTab.TabPosition.resolve(position_native(QtJambi_LibraryUtilities.internal.nativeId(this))); } @QtUninvokable private native int position_native(long __this__nativeId); /** *

The size for the right widget on the tab

*

See QStyleOptionTab::rightButtonSize

*/ @QtUninvokable public final void setRightButtonSize(io.qt.core.@NonNull QSize rightButtonSize){ setRightButtonSize_native_cref_QSize(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(rightButtonSize)); } @QtUninvokable private native void setRightButtonSize_native_cref_QSize(long __this__nativeId, long rightButtonSize); /** *

The size for the right widget on the tab

*

See QStyleOptionTab::rightButtonSize

*/ @QtUninvokable public final io.qt.core.@NonNull QSize rightButtonSize(){ return rightButtonSize_native(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native io.qt.core.QSize rightButtonSize_native(long __this__nativeId); /** *

Which row the tab is currently in

*

See QStyleOptionTab::row

*/ @QtUninvokable public final void setRow(int row){ setRow_native_int(QtJambi_LibraryUtilities.internal.nativeId(this), row); } @QtUninvokable private native void setRow_native_int(long __this__nativeId, int row); /** *

Which row the tab is currently in

*

See QStyleOptionTab::row

*/ @QtUninvokable public final int row(){ return row_native(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native int row_native(long __this__nativeId); /** *

The position of the selected tab in relation to this tab

*

See QStyleOptionTab::selectedPosition

*/ @QtUninvokable public final void setSelectedPosition(io.qt.widgets.QStyleOptionTab.@NonNull SelectedPosition selectedPosition){ setSelectedPosition_native_cref_QStyleOptionTab_SelectedPosition(QtJambi_LibraryUtilities.internal.nativeId(this), selectedPosition.value()); } @QtUninvokable private native void setSelectedPosition_native_cref_QStyleOptionTab_SelectedPosition(long __this__nativeId, int selectedPosition); /** *

The position of the selected tab in relation to this tab

*

See QStyleOptionTab::selectedPosition

*/ @QtUninvokable public final io.qt.widgets.QStyleOptionTab.@NonNull SelectedPosition selectedPosition(){ return io.qt.widgets.QStyleOptionTab.SelectedPosition.resolve(selectedPosition_native(QtJambi_LibraryUtilities.internal.nativeId(this))); } @QtUninvokable private native int selectedPosition_native(long __this__nativeId); /** *

The tab shape used to draw the tab; by default QTabBar::RoundedNorth

*

See QStyleOptionTab::shape

*/ @QtUninvokable public final void setShape(io.qt.widgets.QTabBar.@NonNull Shape shape){ setShape_native_cref_QTabBar_Shape(QtJambi_LibraryUtilities.internal.nativeId(this), shape.value()); } @QtUninvokable private native void setShape_native_cref_QTabBar_Shape(long __this__nativeId, int shape); /** *

The tab shape used to draw the tab; by default QTabBar::RoundedNorth

*

See QStyleOptionTab::shape

*/ @QtUninvokable public final io.qt.widgets.QTabBar.@NonNull Shape shape(){ return io.qt.widgets.QTabBar.Shape.resolve(shape_native(QtJambi_LibraryUtilities.internal.nativeId(this))); } @QtUninvokable private native int shape_native(long __this__nativeId); /** *

The index for the tab being represented

*

See QStyleOptionTab::tabIndex

*/ @QtUninvokable public final void setTabIndex(int tabIndex){ setTabIndex_native_int(QtJambi_LibraryUtilities.internal.nativeId(this), tabIndex); } @QtUninvokable private native void setTabIndex_native_int(long __this__nativeId, int tabIndex); /** *

The index for the tab being represented

*

See QStyleOptionTab::tabIndex

*/ @QtUninvokable public final int tabIndex(){ return tabIndex_native(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native int tabIndex_native(long __this__nativeId); /** *

The text of the tab

*

See QStyleOptionTab::text

*/ @QtUninvokable public final void setText(java.lang.@NonNull String text){ setText_native_cref_QString(QtJambi_LibraryUtilities.internal.nativeId(this), text); } @QtUninvokable private native void setText_native_cref_QString(long __this__nativeId, java.lang.String text); /** *

The text of the tab

*

See QStyleOptionTab::text

*/ @QtUninvokable public final java.lang.@NonNull String text(){ return text_native(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native java.lang.String text_native(long __this__nativeId); /** * Constructor for internal use only. * @param p expected to be null. * @hidden */ @NativeAccess protected QStyleOptionTab(QPrivateConstructor p) { super(p); } /** *

Creates and returns a copy of this object.

See QStyleOptionTab::QStyleOptionTab(QStyleOptionTab)

*/ @QtUninvokable @Override public QStyleOptionTab clone() { return clone_native(QtJambi_LibraryUtilities.internal.nativeId(this)); } private static native QStyleOptionTab clone_native(long __this_nativeId); /** * @deprecated Use {@link #assign(io.qt.widgets.QStyleOptionTab)} instead. */ @Deprecated @QtUninvokable public final void set(io.qt.widgets.@NonNull QStyleOptionTab arg__1) { assign(arg__1); } /** *

Overloaded function for {@link #setCornerWidgets(io.qt.widgets.QStyleOptionTab.CornerWidgets)}.

*/ @QtUninvokable public final void setCornerWidgets(io.qt.widgets.QStyleOptionTab.@NonNull CornerWidget @NonNull... cornerWidgets) { setCornerWidgets(new io.qt.widgets.QStyleOptionTab.CornerWidgets(cornerWidgets)); } /** * @hidden *

Kotlin property getter. In Java use {@link #cornerWidgets()} instead.

*/ @QtUninvokable public final io.qt.widgets.QStyleOptionTab.@NonNull CornerWidgets getCornerWidgets() { return cornerWidgets(); } /** * @hidden *

Kotlin property getter. In Java use {@link #documentMode()} instead.

*/ @QtUninvokable public final boolean getDocumentMode() { return documentMode(); } /** *

Overloaded function for {@link #setFeatures(io.qt.widgets.QStyleOptionTab.TabFeatures)}.

*/ @QtUninvokable public final void setFeatures(io.qt.widgets.QStyleOptionTab.@NonNull TabFeature @NonNull... features) { setFeatures(new io.qt.widgets.QStyleOptionTab.TabFeatures(features)); } /** * @hidden *

Kotlin property getter. In Java use {@link #features()} instead.

*/ @QtUninvokable public final io.qt.widgets.QStyleOptionTab.@NonNull TabFeatures getFeatures() { return features(); } /** *

Overloaded function for {@link #setIcon(io.qt.gui.QIcon)}.

*/ @QtUninvokable public final void setIcon(io.qt.gui.@NonNull QPixmap icon) { setIcon(new io.qt.gui.QIcon(icon)); } /** * @hidden *

Kotlin property getter. In Java use {@link #icon()} instead.

*/ @QtUninvokable public final io.qt.gui.@NonNull QIcon getIcon() { return icon(); } /** * @hidden *

Kotlin property getter. In Java use {@link #iconSize()} instead.

*/ @QtUninvokable public final io.qt.core.@NonNull QSize getIconSize() { return iconSize(); } /** * @hidden *

Kotlin property getter. In Java use {@link #leftButtonSize()} instead.

*/ @QtUninvokable public final io.qt.core.@NonNull QSize getLeftButtonSize() { return leftButtonSize(); } /** * @hidden *

Kotlin property getter. In Java use {@link #position()} instead.

*/ @QtUninvokable public final io.qt.widgets.QStyleOptionTab.@NonNull TabPosition getPosition() { return position(); } /** * @hidden *

Kotlin property getter. In Java use {@link #rightButtonSize()} instead.

*/ @QtUninvokable public final io.qt.core.@NonNull QSize getRightButtonSize() { return rightButtonSize(); } /** * @hidden *

Kotlin property getter. In Java use {@link #row()} instead.

*/ @QtUninvokable public final int getRow() { return row(); } /** * @hidden *

Kotlin property getter. In Java use {@link #selectedPosition()} instead.

*/ @QtUninvokable public final io.qt.widgets.QStyleOptionTab.@NonNull SelectedPosition getSelectedPosition() { return selectedPosition(); } /** * @hidden *

Kotlin property getter. In Java use {@link #shape()} instead.

*/ @QtUninvokable public final io.qt.widgets.QTabBar.@NonNull Shape getShape() { return shape(); } /** * @hidden *

Kotlin property getter. In Java use {@link #tabIndex()} instead.

*/ @QtUninvokable public final int getTabIndex() { return tabIndex(); } /** * @hidden *

Kotlin property getter. In Java use {@link #text()} instead.

*/ @QtUninvokable public final java.lang.@NonNull String getText() { return text(); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy