qt: rebuild (add UnsafePointer/UnsafeNew, moved binding helpers)

This commit is contained in:
mappu 2024-10-16 18:07:56 +13:00
parent 88ef4e922c
commit 050a578057
1061 changed files with 9429 additions and 4794 deletions

View File

@ -6,7 +6,7 @@
#include <QString>
#include <QByteArray>
#include <cstring>
#include "qabstractanimation.h"
#include <qabstractanimation.h>
#include "gen_qabstractanimation.h"
#include "_cgo_export.h"

View File

@ -48,19 +48,26 @@ func (this *QAbstractAnimation) cPointer() *C.QAbstractAnimation {
return this.h
}
func (this *QAbstractAnimation) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractAnimation(h *C.QAbstractAnimation) *QAbstractAnimation {
if h == nil {
return nil
}
return &QAbstractAnimation{h: h, QObject: newQObject_U(unsafe.Pointer(h))}
return &QAbstractAnimation{h: h, QObject: UnsafeNewQObject(unsafe.Pointer(h))}
}
func newQAbstractAnimation_U(h unsafe.Pointer) *QAbstractAnimation {
func UnsafeNewQAbstractAnimation(h unsafe.Pointer) *QAbstractAnimation {
return newQAbstractAnimation((*C.QAbstractAnimation)(h))
}
func (this *QAbstractAnimation) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAbstractAnimation_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAbstractAnimation_MetaObject(this.h)))
}
func (this *QAbstractAnimation) Metacast(param1 string) unsafe.Pointer {
@ -92,7 +99,7 @@ func (this *QAbstractAnimation) State() QAbstractAnimation__State {
}
func (this *QAbstractAnimation) Group() *QAnimationGroup {
return newQAnimationGroup_U(unsafe.Pointer(C.QAbstractAnimation_Group(this.h)))
return UnsafeNewQAnimationGroup(unsafe.Pointer(C.QAbstractAnimation_Group(this.h)))
}
func (this *QAbstractAnimation) Direction() QAbstractAnimation__Direction {
@ -308,14 +315,21 @@ func (this *QAnimationDriver) cPointer() *C.QAnimationDriver {
return this.h
}
func (this *QAnimationDriver) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAnimationDriver(h *C.QAnimationDriver) *QAnimationDriver {
if h == nil {
return nil
}
return &QAnimationDriver{h: h, QObject: newQObject_U(unsafe.Pointer(h))}
return &QAnimationDriver{h: h, QObject: UnsafeNewQObject(unsafe.Pointer(h))}
}
func newQAnimationDriver_U(h unsafe.Pointer) *QAnimationDriver {
func UnsafeNewQAnimationDriver(h unsafe.Pointer) *QAnimationDriver {
return newQAnimationDriver((*C.QAnimationDriver)(h))
}
@ -332,7 +346,7 @@ func NewQAnimationDriver2(parent *QObject) *QAnimationDriver {
}
func (this *QAnimationDriver) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAnimationDriver_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAnimationDriver_MetaObject(this.h)))
}
func (this *QAnimationDriver) Metacast(param1 string) unsafe.Pointer {

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -7,7 +7,7 @@
#include <QString>
#include <QByteArray>
#include <cstring>
#include "qabstractbutton.h"
#include <qabstractbutton.h>
#include "gen_qabstractbutton.h"
#include "_cgo_export.h"

View File

@ -9,6 +9,7 @@ package qt
import "C"
import (
"github.com/mappu/miqt/libmiqt"
"runtime"
"runtime/cgo"
"unsafe"
@ -26,19 +27,26 @@ func (this *QAbstractButton) cPointer() *C.QAbstractButton {
return this.h
}
func (this *QAbstractButton) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractButton(h *C.QAbstractButton) *QAbstractButton {
if h == nil {
return nil
}
return &QAbstractButton{h: h, QWidget: newQWidget_U(unsafe.Pointer(h))}
return &QAbstractButton{h: h, QWidget: UnsafeNewQWidget(unsafe.Pointer(h))}
}
func newQAbstractButton_U(h unsafe.Pointer) *QAbstractButton {
func UnsafeNewQAbstractButton(h unsafe.Pointer) *QAbstractButton {
return newQAbstractButton((*C.QAbstractButton)(h))
}
func (this *QAbstractButton) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAbstractButton_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAbstractButton_MetaObject(this.h)))
}
func (this *QAbstractButton) Metacast(param1 string) unsafe.Pointer {
@ -66,7 +74,7 @@ func QAbstractButton_TrUtf8(s string) string {
}
func (this *QAbstractButton) SetText(text string) {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
C.QAbstractButton_SetText(this.h, (*C.struct_miqt_string)(text_ms))
}
@ -160,7 +168,7 @@ func (this *QAbstractButton) AutoExclusive() bool {
}
func (this *QAbstractButton) Group() *QButtonGroup {
return newQButtonGroup_U(unsafe.Pointer(C.QAbstractButton_Group(this.h)))
return UnsafeNewQButtonGroup(unsafe.Pointer(C.QAbstractButton_Group(this.h)))
}
func (this *QAbstractButton) SetIconSize(size *QSize) {

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -10,7 +10,7 @@
#include <QByteArray>
#include <cstring>
#include <QThread>
#include "qabstracteventdispatcher.h"
#include <qabstracteventdispatcher.h>
#include "gen_qabstracteventdispatcher.h"
#include "_cgo_export.h"

View File

@ -26,19 +26,26 @@ func (this *QAbstractEventDispatcher) cPointer() *C.QAbstractEventDispatcher {
return this.h
}
func (this *QAbstractEventDispatcher) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractEventDispatcher(h *C.QAbstractEventDispatcher) *QAbstractEventDispatcher {
if h == nil {
return nil
}
return &QAbstractEventDispatcher{h: h, QObject: newQObject_U(unsafe.Pointer(h))}
return &QAbstractEventDispatcher{h: h, QObject: UnsafeNewQObject(unsafe.Pointer(h))}
}
func newQAbstractEventDispatcher_U(h unsafe.Pointer) *QAbstractEventDispatcher {
func UnsafeNewQAbstractEventDispatcher(h unsafe.Pointer) *QAbstractEventDispatcher {
return newQAbstractEventDispatcher((*C.QAbstractEventDispatcher)(h))
}
func (this *QAbstractEventDispatcher) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAbstractEventDispatcher_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAbstractEventDispatcher_MetaObject(this.h)))
}
func (this *QAbstractEventDispatcher) Metacast(param1 string) unsafe.Pointer {
@ -66,7 +73,7 @@ func QAbstractEventDispatcher_TrUtf8(s string) string {
}
func QAbstractEventDispatcher_Instance() *QAbstractEventDispatcher {
return newQAbstractEventDispatcher_U(unsafe.Pointer(C.QAbstractEventDispatcher_Instance()))
return UnsafeNewQAbstractEventDispatcher(unsafe.Pointer(C.QAbstractEventDispatcher_Instance()))
}
func (this *QAbstractEventDispatcher) ProcessEvents(flags QEventLoop__ProcessEventsFlag) bool {
@ -230,7 +237,7 @@ func QAbstractEventDispatcher_TrUtf83(s string, c string, n int) string {
}
func QAbstractEventDispatcher_Instance1(thread *QThread) *QAbstractEventDispatcher {
return newQAbstractEventDispatcher_U(unsafe.Pointer(C.QAbstractEventDispatcher_Instance1(thread.cPointer())))
return UnsafeNewQAbstractEventDispatcher(unsafe.Pointer(C.QAbstractEventDispatcher_Instance1(thread.cPointer())))
}
// Delete this object from C++ memory.
@ -258,6 +265,13 @@ func (this *QAbstractEventDispatcher__TimerInfo) cPointer() *C.QAbstractEventDis
return this.h
}
func (this *QAbstractEventDispatcher__TimerInfo) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractEventDispatcher__TimerInfo(h *C.QAbstractEventDispatcher__TimerInfo) *QAbstractEventDispatcher__TimerInfo {
if h == nil {
return nil
@ -265,7 +279,7 @@ func newQAbstractEventDispatcher__TimerInfo(h *C.QAbstractEventDispatcher__Timer
return &QAbstractEventDispatcher__TimerInfo{h: h}
}
func newQAbstractEventDispatcher__TimerInfo_U(h unsafe.Pointer) *QAbstractEventDispatcher__TimerInfo {
func UnsafeNewQAbstractEventDispatcher__TimerInfo(h unsafe.Pointer) *QAbstractEventDispatcher__TimerInfo {
return newQAbstractEventDispatcher__TimerInfo((*C.QAbstractEventDispatcher__TimerInfo)(h))
}

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -14,7 +14,7 @@
#include <cstring>
#include <QStyleOptionViewItem>
#include <QWidget>
#include "qabstractitemdelegate.h"
#include <qabstractitemdelegate.h>
#include "gen_qabstractitemdelegate.h"
#include "_cgo_export.h"

View File

@ -9,6 +9,7 @@ package qt
import "C"
import (
"github.com/mappu/miqt/libmiqt"
"runtime"
"runtime/cgo"
"unsafe"
@ -36,19 +37,26 @@ func (this *QAbstractItemDelegate) cPointer() *C.QAbstractItemDelegate {
return this.h
}
func (this *QAbstractItemDelegate) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractItemDelegate(h *C.QAbstractItemDelegate) *QAbstractItemDelegate {
if h == nil {
return nil
}
return &QAbstractItemDelegate{h: h, QObject: newQObject_U(unsafe.Pointer(h))}
return &QAbstractItemDelegate{h: h, QObject: UnsafeNewQObject(unsafe.Pointer(h))}
}
func newQAbstractItemDelegate_U(h unsafe.Pointer) *QAbstractItemDelegate {
func UnsafeNewQAbstractItemDelegate(h unsafe.Pointer) *QAbstractItemDelegate {
return newQAbstractItemDelegate((*C.QAbstractItemDelegate)(h))
}
func (this *QAbstractItemDelegate) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAbstractItemDelegate_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAbstractItemDelegate_MetaObject(this.h)))
}
func (this *QAbstractItemDelegate) Metacast(param1 string) unsafe.Pointer {
@ -87,7 +95,7 @@ func (this *QAbstractItemDelegate) SizeHint(option *QStyleOptionViewItem, index
}
func (this *QAbstractItemDelegate) CreateEditor(parent *QWidget, option *QStyleOptionViewItem, index *QModelIndex) *QWidget {
return newQWidget_U(unsafe.Pointer(C.QAbstractItemDelegate_CreateEditor(this.h, parent.cPointer(), option.cPointer(), index.cPointer())))
return UnsafeNewQWidget(unsafe.Pointer(C.QAbstractItemDelegate_CreateEditor(this.h, parent.cPointer(), option.cPointer(), index.cPointer())))
}
func (this *QAbstractItemDelegate) DestroyEditor(editor *QWidget, index *QModelIndex) {
@ -111,7 +119,7 @@ func (this *QAbstractItemDelegate) EditorEvent(event *QEvent, model *QAbstractIt
}
func QAbstractItemDelegate_ElidedText(fontMetrics *QFontMetrics, width int, mode TextElideMode, text string) string {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
var _ms *C.struct_miqt_string = C.QAbstractItemDelegate_ElidedText(fontMetrics.cPointer(), (C.int)(width), (C.int)(mode), (*C.struct_miqt_string)(text_ms))
_ret := C.GoStringN(&_ms.data, C.int(int64(_ms.len)))
@ -149,7 +157,7 @@ func miqt_exec_callback_QAbstractItemDelegate_CommitData(cb C.intptr_t, editor *
}
// Convert all CABI parameters to Go parameters
slotval1 := newQWidget_U(unsafe.Pointer(editor))
slotval1 := UnsafeNewQWidget(unsafe.Pointer(editor))
gofunc(slotval1)
}
@ -169,7 +177,7 @@ func miqt_exec_callback_QAbstractItemDelegate_CloseEditor(cb C.intptr_t, editor
}
// Convert all CABI parameters to Go parameters
slotval1 := newQWidget_U(unsafe.Pointer(editor))
slotval1 := UnsafeNewQWidget(unsafe.Pointer(editor))
gofunc(slotval1)
}
@ -189,7 +197,7 @@ func miqt_exec_callback_QAbstractItemDelegate_SizeHintChanged(cb C.intptr_t, par
}
// Convert all CABI parameters to Go parameters
slotval1 := newQModelIndex_U(unsafe.Pointer(param1))
slotval1 := UnsafeNewQModelIndex(unsafe.Pointer(param1))
gofunc(slotval1)
}
@ -253,7 +261,7 @@ func miqt_exec_callback_QAbstractItemDelegate_CloseEditor2(cb C.intptr_t, editor
}
// Convert all CABI parameters to Go parameters
slotval1 := newQWidget_U(unsafe.Pointer(editor))
slotval1 := UnsafeNewQWidget(unsafe.Pointer(editor))
slotval2 := (QAbstractItemDelegate__EndEditHint)(hint)
gofunc(slotval1, slotval2)

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -11,7 +11,7 @@
#include <QByteArray>
#include <cstring>
#include <QVariant>
#include "qabstractitemmodel.h"
#include <qabstractitemmodel.h>
#include "gen_qabstractitemmodel.h"
#include "_cgo_export.h"
@ -278,7 +278,7 @@ struct miqt_array* QAbstractItemModel_MimeTypes(const QAbstractItemModel* self)
}
QMimeData* QAbstractItemModel_MimeData(const QAbstractItemModel* self, struct miqt_array* /* of QModelIndex* */ indexes) {
QList<QModelIndex> indexes_QList;
QModelIndexList indexes_QList;
indexes_QList.reserve(indexes->len);
QModelIndex** indexes_arr = static_cast<QModelIndex**>(indexes->data);
for(size_t i = 0; i < indexes->len; ++i) {

View File

@ -42,6 +42,13 @@ func (this *QModelIndex) cPointer() *C.QModelIndex {
return this.h
}
func (this *QModelIndex) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQModelIndex(h *C.QModelIndex) *QModelIndex {
if h == nil {
return nil
@ -49,7 +56,7 @@ func newQModelIndex(h *C.QModelIndex) *QModelIndex {
return &QModelIndex{h: h}
}
func newQModelIndex_U(h unsafe.Pointer) *QModelIndex {
func UnsafeNewQModelIndex(h unsafe.Pointer) *QModelIndex {
return newQModelIndex((*C.QModelIndex)(h))
}
@ -128,7 +135,7 @@ func (this *QModelIndex) Flags() ItemFlag {
}
func (this *QModelIndex) Model() *QAbstractItemModel {
return newQAbstractItemModel_U(unsafe.Pointer(C.QModelIndex_Model(this.h)))
return UnsafeNewQAbstractItemModel(unsafe.Pointer(C.QModelIndex_Model(this.h)))
}
func (this *QModelIndex) IsValid() bool {
@ -179,6 +186,13 @@ func (this *QPersistentModelIndex) cPointer() *C.QPersistentModelIndex {
return this.h
}
func (this *QPersistentModelIndex) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQPersistentModelIndex(h *C.QPersistentModelIndex) *QPersistentModelIndex {
if h == nil {
return nil
@ -186,7 +200,7 @@ func newQPersistentModelIndex(h *C.QPersistentModelIndex) *QPersistentModelIndex
return &QPersistentModelIndex{h: h}
}
func newQPersistentModelIndex_U(h unsafe.Pointer) *QPersistentModelIndex {
func UnsafeNewQPersistentModelIndex(h unsafe.Pointer) *QPersistentModelIndex {
return newQPersistentModelIndex((*C.QPersistentModelIndex)(h))
}
@ -289,7 +303,7 @@ func (this *QPersistentModelIndex) Flags() ItemFlag {
}
func (this *QPersistentModelIndex) Model() *QAbstractItemModel {
return newQAbstractItemModel_U(unsafe.Pointer(C.QPersistentModelIndex_Model(this.h)))
return UnsafeNewQAbstractItemModel(unsafe.Pointer(C.QPersistentModelIndex_Model(this.h)))
}
func (this *QPersistentModelIndex) IsValid() bool {
@ -329,19 +343,26 @@ func (this *QAbstractItemModel) cPointer() *C.QAbstractItemModel {
return this.h
}
func (this *QAbstractItemModel) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractItemModel(h *C.QAbstractItemModel) *QAbstractItemModel {
if h == nil {
return nil
}
return &QAbstractItemModel{h: h, QObject: newQObject_U(unsafe.Pointer(h))}
return &QAbstractItemModel{h: h, QObject: UnsafeNewQObject(unsafe.Pointer(h))}
}
func newQAbstractItemModel_U(h unsafe.Pointer) *QAbstractItemModel {
func UnsafeNewQAbstractItemModel(h unsafe.Pointer) *QAbstractItemModel {
return newQAbstractItemModel((*C.QAbstractItemModel)(h))
}
func (this *QAbstractItemModel) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAbstractItemModel_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAbstractItemModel_MetaObject(this.h)))
}
func (this *QAbstractItemModel) Metacast(param1 string) unsafe.Pointer {
@ -450,7 +471,7 @@ func (this *QAbstractItemModel) MimeData(indexes []QModelIndex) *QMimeData {
}
indexes_ma := &C.struct_miqt_array{len: C.size_t(len(indexes)), data: unsafe.Pointer(indexes_CArray)}
defer runtime.KeepAlive(unsafe.Pointer(indexes_ma))
return newQMimeData_U(unsafe.Pointer(C.QAbstractItemModel_MimeData(this.h, indexes_ma)))
return UnsafeNewQMimeData(unsafe.Pointer(C.QAbstractItemModel_MimeData(this.h, indexes_ma)))
}
func (this *QAbstractItemModel) CanDropMimeData(data *QMimeData, action DropAction, row int, column int, parent *QModelIndex) bool {
@ -580,8 +601,8 @@ func miqt_exec_callback_QAbstractItemModel_DataChanged(cb C.intptr_t, topLeft *C
}
// Convert all CABI parameters to Go parameters
slotval1 := newQModelIndex_U(unsafe.Pointer(topLeft))
slotval2 := newQModelIndex_U(unsafe.Pointer(bottomRight))
slotval1 := UnsafeNewQModelIndex(unsafe.Pointer(topLeft))
slotval2 := UnsafeNewQModelIndex(unsafe.Pointer(bottomRight))
gofunc(slotval1, slotval2)
}
@ -832,8 +853,8 @@ func miqt_exec_callback_QAbstractItemModel_DataChanged3(cb C.intptr_t, topLeft *
}
// Convert all CABI parameters to Go parameters
slotval1 := newQModelIndex_U(unsafe.Pointer(topLeft))
slotval2 := newQModelIndex_U(unsafe.Pointer(bottomRight))
slotval1 := UnsafeNewQModelIndex(unsafe.Pointer(topLeft))
slotval2 := UnsafeNewQModelIndex(unsafe.Pointer(bottomRight))
var roles_ma *C.struct_miqt_array = roles
roles_ret := make([]int, int(roles_ma.len))
roles_outCast := (*[0xffff]C.int)(unsafe.Pointer(roles_ma.data)) // hey ya
@ -1028,19 +1049,26 @@ func (this *QAbstractTableModel) cPointer() *C.QAbstractTableModel {
return this.h
}
func (this *QAbstractTableModel) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractTableModel(h *C.QAbstractTableModel) *QAbstractTableModel {
if h == nil {
return nil
}
return &QAbstractTableModel{h: h, QAbstractItemModel: newQAbstractItemModel_U(unsafe.Pointer(h))}
return &QAbstractTableModel{h: h, QAbstractItemModel: UnsafeNewQAbstractItemModel(unsafe.Pointer(h))}
}
func newQAbstractTableModel_U(h unsafe.Pointer) *QAbstractTableModel {
func UnsafeNewQAbstractTableModel(h unsafe.Pointer) *QAbstractTableModel {
return newQAbstractTableModel((*C.QAbstractTableModel)(h))
}
func (this *QAbstractTableModel) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAbstractTableModel_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAbstractTableModel_MetaObject(this.h)))
}
func (this *QAbstractTableModel) Metacast(param1 string) unsafe.Pointer {
@ -1166,19 +1194,26 @@ func (this *QAbstractListModel) cPointer() *C.QAbstractListModel {
return this.h
}
func (this *QAbstractListModel) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractListModel(h *C.QAbstractListModel) *QAbstractListModel {
if h == nil {
return nil
}
return &QAbstractListModel{h: h, QAbstractItemModel: newQAbstractItemModel_U(unsafe.Pointer(h))}
return &QAbstractListModel{h: h, QAbstractItemModel: UnsafeNewQAbstractItemModel(unsafe.Pointer(h))}
}
func newQAbstractListModel_U(h unsafe.Pointer) *QAbstractListModel {
func UnsafeNewQAbstractListModel(h unsafe.Pointer) *QAbstractListModel {
return newQAbstractListModel((*C.QAbstractListModel)(h))
}
func (this *QAbstractListModel) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAbstractListModel_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAbstractListModel_MetaObject(this.h)))
}
func (this *QAbstractListModel) Metacast(param1 string) unsafe.Pointer {

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -12,7 +12,7 @@
#include <cstring>
#include <QVariant>
#include <QWidget>
#include "qabstractitemview.h"
#include <qabstractitemview.h>
#include "gen_qabstractitemview.h"
#include "_cgo_export.h"

View File

@ -9,6 +9,7 @@ package qt
import "C"
import (
"github.com/mappu/miqt/libmiqt"
"runtime"
"runtime/cgo"
"unsafe"
@ -82,19 +83,26 @@ func (this *QAbstractItemView) cPointer() *C.QAbstractItemView {
return this.h
}
func (this *QAbstractItemView) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractItemView(h *C.QAbstractItemView) *QAbstractItemView {
if h == nil {
return nil
}
return &QAbstractItemView{h: h, QAbstractScrollArea: newQAbstractScrollArea_U(unsafe.Pointer(h))}
return &QAbstractItemView{h: h, QAbstractScrollArea: UnsafeNewQAbstractScrollArea(unsafe.Pointer(h))}
}
func newQAbstractItemView_U(h unsafe.Pointer) *QAbstractItemView {
func UnsafeNewQAbstractItemView(h unsafe.Pointer) *QAbstractItemView {
return newQAbstractItemView((*C.QAbstractItemView)(h))
}
func (this *QAbstractItemView) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAbstractItemView_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAbstractItemView_MetaObject(this.h)))
}
func (this *QAbstractItemView) Metacast(param1 string) unsafe.Pointer {
@ -126,7 +134,7 @@ func (this *QAbstractItemView) SetModel(model *QAbstractItemModel) {
}
func (this *QAbstractItemView) Model() *QAbstractItemModel {
return newQAbstractItemModel_U(unsafe.Pointer(C.QAbstractItemView_Model(this.h)))
return UnsafeNewQAbstractItemModel(unsafe.Pointer(C.QAbstractItemView_Model(this.h)))
}
func (this *QAbstractItemView) SetSelectionModel(selectionModel *QItemSelectionModel) {
@ -134,7 +142,7 @@ func (this *QAbstractItemView) SetSelectionModel(selectionModel *QItemSelectionM
}
func (this *QAbstractItemView) SelectionModel() *QItemSelectionModel {
return newQItemSelectionModel_U(unsafe.Pointer(C.QAbstractItemView_SelectionModel(this.h)))
return UnsafeNewQItemSelectionModel(unsafe.Pointer(C.QAbstractItemView_SelectionModel(this.h)))
}
func (this *QAbstractItemView) SetItemDelegate(delegate *QAbstractItemDelegate) {
@ -142,7 +150,7 @@ func (this *QAbstractItemView) SetItemDelegate(delegate *QAbstractItemDelegate)
}
func (this *QAbstractItemView) ItemDelegate() *QAbstractItemDelegate {
return newQAbstractItemDelegate_U(unsafe.Pointer(C.QAbstractItemView_ItemDelegate(this.h)))
return UnsafeNewQAbstractItemDelegate(unsafe.Pointer(C.QAbstractItemView_ItemDelegate(this.h)))
}
func (this *QAbstractItemView) SetSelectionMode(mode QAbstractItemView__SelectionMode) {
@ -299,7 +307,7 @@ func (this *QAbstractItemView) TextElideMode() TextElideMode {
}
func (this *QAbstractItemView) KeyboardSearch(search string) {
search_ms := miqt_strdupg(search)
search_ms := libmiqt.Strdupg(search)
defer C.free(search_ms)
C.QAbstractItemView_KeyboardSearch(this.h, (*C.struct_miqt_string)(search_ms))
}
@ -354,7 +362,7 @@ func (this *QAbstractItemView) SetIndexWidget(index *QModelIndex, widget *QWidge
}
func (this *QAbstractItemView) IndexWidget(index *QModelIndex) *QWidget {
return newQWidget_U(unsafe.Pointer(C.QAbstractItemView_IndexWidget(this.h, index.cPointer())))
return UnsafeNewQWidget(unsafe.Pointer(C.QAbstractItemView_IndexWidget(this.h, index.cPointer())))
}
func (this *QAbstractItemView) SetItemDelegateForRow(row int, delegate *QAbstractItemDelegate) {
@ -362,7 +370,7 @@ func (this *QAbstractItemView) SetItemDelegateForRow(row int, delegate *QAbstrac
}
func (this *QAbstractItemView) ItemDelegateForRow(row int) *QAbstractItemDelegate {
return newQAbstractItemDelegate_U(unsafe.Pointer(C.QAbstractItemView_ItemDelegateForRow(this.h, (C.int)(row))))
return UnsafeNewQAbstractItemDelegate(unsafe.Pointer(C.QAbstractItemView_ItemDelegateForRow(this.h, (C.int)(row))))
}
func (this *QAbstractItemView) SetItemDelegateForColumn(column int, delegate *QAbstractItemDelegate) {
@ -370,11 +378,11 @@ func (this *QAbstractItemView) SetItemDelegateForColumn(column int, delegate *QA
}
func (this *QAbstractItemView) ItemDelegateForColumn(column int) *QAbstractItemDelegate {
return newQAbstractItemDelegate_U(unsafe.Pointer(C.QAbstractItemView_ItemDelegateForColumn(this.h, (C.int)(column))))
return UnsafeNewQAbstractItemDelegate(unsafe.Pointer(C.QAbstractItemView_ItemDelegateForColumn(this.h, (C.int)(column))))
}
func (this *QAbstractItemView) ItemDelegateWithIndex(index *QModelIndex) *QAbstractItemDelegate {
return newQAbstractItemDelegate_U(unsafe.Pointer(C.QAbstractItemView_ItemDelegateWithIndex(this.h, index.cPointer())))
return UnsafeNewQAbstractItemDelegate(unsafe.Pointer(C.QAbstractItemView_ItemDelegateWithIndex(this.h, index.cPointer())))
}
func (this *QAbstractItemView) InputMethodQuery(query InputMethodQuery) *QVariant {
@ -439,7 +447,7 @@ func miqt_exec_callback_QAbstractItemView_Pressed(cb C.intptr_t, index *C.QModel
}
// Convert all CABI parameters to Go parameters
slotval1 := newQModelIndex_U(unsafe.Pointer(index))
slotval1 := UnsafeNewQModelIndex(unsafe.Pointer(index))
gofunc(slotval1)
}
@ -459,7 +467,7 @@ func miqt_exec_callback_QAbstractItemView_Clicked(cb C.intptr_t, index *C.QModel
}
// Convert all CABI parameters to Go parameters
slotval1 := newQModelIndex_U(unsafe.Pointer(index))
slotval1 := UnsafeNewQModelIndex(unsafe.Pointer(index))
gofunc(slotval1)
}
@ -479,7 +487,7 @@ func miqt_exec_callback_QAbstractItemView_DoubleClicked(cb C.intptr_t, index *C.
}
// Convert all CABI parameters to Go parameters
slotval1 := newQModelIndex_U(unsafe.Pointer(index))
slotval1 := UnsafeNewQModelIndex(unsafe.Pointer(index))
gofunc(slotval1)
}
@ -499,7 +507,7 @@ func miqt_exec_callback_QAbstractItemView_Activated(cb C.intptr_t, index *C.QMod
}
// Convert all CABI parameters to Go parameters
slotval1 := newQModelIndex_U(unsafe.Pointer(index))
slotval1 := UnsafeNewQModelIndex(unsafe.Pointer(index))
gofunc(slotval1)
}
@ -519,7 +527,7 @@ func miqt_exec_callback_QAbstractItemView_Entered(cb C.intptr_t, index *C.QModel
}
// Convert all CABI parameters to Go parameters
slotval1 := newQModelIndex_U(unsafe.Pointer(index))
slotval1 := UnsafeNewQModelIndex(unsafe.Pointer(index))
gofunc(slotval1)
}
@ -556,7 +564,7 @@ func miqt_exec_callback_QAbstractItemView_IconSizeChanged(cb C.intptr_t, size *C
}
// Convert all CABI parameters to Go parameters
slotval1 := newQSize_U(unsafe.Pointer(size))
slotval1 := UnsafeNewQSize(unsafe.Pointer(size))
gofunc(slotval1)
}

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -1,6 +1,6 @@
#include <QAbstractNativeEventFilter>
#include <QByteArray>
#include "qabstractnativeeventfilter.h"
#include <qabstractnativeeventfilter.h>
#include "gen_qabstractnativeeventfilter.h"
#include "_cgo_export.h"

View File

@ -24,6 +24,13 @@ func (this *QAbstractNativeEventFilter) cPointer() *C.QAbstractNativeEventFilter
return this.h
}
func (this *QAbstractNativeEventFilter) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractNativeEventFilter(h *C.QAbstractNativeEventFilter) *QAbstractNativeEventFilter {
if h == nil {
return nil
@ -31,7 +38,7 @@ func newQAbstractNativeEventFilter(h *C.QAbstractNativeEventFilter) *QAbstractNa
return &QAbstractNativeEventFilter{h: h}
}
func newQAbstractNativeEventFilter_U(h unsafe.Pointer) *QAbstractNativeEventFilter {
func UnsafeNewQAbstractNativeEventFilter(h unsafe.Pointer) *QAbstractNativeEventFilter {
return newQAbstractNativeEventFilter((*C.QAbstractNativeEventFilter)(h))
}

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -9,7 +9,7 @@
#include <QByteArray>
#include <cstring>
#include <QVariant>
#include "qabstractproxymodel.h"
#include <qabstractproxymodel.h>
#include "gen_qabstractproxymodel.h"
#include "_cgo_export.h"
@ -109,7 +109,7 @@ QModelIndex* QAbstractProxyModel_Sibling(const QAbstractProxyModel* self, int ro
}
QMimeData* QAbstractProxyModel_MimeData(const QAbstractProxyModel* self, struct miqt_array* /* of QModelIndex* */ indexes) {
QList<QModelIndex> indexes_QList;
QModelIndexList indexes_QList;
indexes_QList.reserve(indexes->len);
QModelIndex** indexes_arr = static_cast<QModelIndex**>(indexes->data);
for(size_t i = 0; i < indexes->len; ++i) {

View File

@ -25,19 +25,26 @@ func (this *QAbstractProxyModel) cPointer() *C.QAbstractProxyModel {
return this.h
}
func (this *QAbstractProxyModel) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractProxyModel(h *C.QAbstractProxyModel) *QAbstractProxyModel {
if h == nil {
return nil
}
return &QAbstractProxyModel{h: h, QAbstractItemModel: newQAbstractItemModel_U(unsafe.Pointer(h))}
return &QAbstractProxyModel{h: h, QAbstractItemModel: UnsafeNewQAbstractItemModel(unsafe.Pointer(h))}
}
func newQAbstractProxyModel_U(h unsafe.Pointer) *QAbstractProxyModel {
func UnsafeNewQAbstractProxyModel(h unsafe.Pointer) *QAbstractProxyModel {
return newQAbstractProxyModel((*C.QAbstractProxyModel)(h))
}
func (this *QAbstractProxyModel) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAbstractProxyModel_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAbstractProxyModel_MetaObject(this.h)))
}
func (this *QAbstractProxyModel) Metacast(param1 string) unsafe.Pointer {
@ -69,7 +76,7 @@ func (this *QAbstractProxyModel) SetSourceModel(sourceModel *QAbstractItemModel)
}
func (this *QAbstractProxyModel) SourceModel() *QAbstractItemModel {
return newQAbstractItemModel_U(unsafe.Pointer(C.QAbstractProxyModel_SourceModel(this.h)))
return UnsafeNewQAbstractItemModel(unsafe.Pointer(C.QAbstractProxyModel_SourceModel(this.h)))
}
func (this *QAbstractProxyModel) MapToSource(proxyIndex *QModelIndex) *QModelIndex {
@ -166,7 +173,7 @@ func (this *QAbstractProxyModel) MimeData(indexes []QModelIndex) *QMimeData {
}
indexes_ma := &C.struct_miqt_array{len: C.size_t(len(indexes)), data: unsafe.Pointer(indexes_CArray)}
defer runtime.KeepAlive(unsafe.Pointer(indexes_ma))
return newQMimeData_U(unsafe.Pointer(C.QAbstractProxyModel_MimeData(this.h, indexes_ma)))
return UnsafeNewQMimeData(unsafe.Pointer(C.QAbstractProxyModel_MimeData(this.h, indexes_ma)))
}
func (this *QAbstractProxyModel) CanDropMimeData(data *QMimeData, action DropAction, row int, column int, parent *QModelIndex) bool {

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -7,7 +7,7 @@
#include <QByteArray>
#include <cstring>
#include <QWidget>
#include "qabstractscrollarea.h"
#include <qabstractscrollarea.h>
#include "gen_qabstractscrollarea.h"
#include "_cgo_export.h"

View File

@ -33,14 +33,21 @@ func (this *QAbstractScrollArea) cPointer() *C.QAbstractScrollArea {
return this.h
}
func (this *QAbstractScrollArea) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractScrollArea(h *C.QAbstractScrollArea) *QAbstractScrollArea {
if h == nil {
return nil
}
return &QAbstractScrollArea{h: h, QFrame: newQFrame_U(unsafe.Pointer(h))}
return &QAbstractScrollArea{h: h, QFrame: UnsafeNewQFrame(unsafe.Pointer(h))}
}
func newQAbstractScrollArea_U(h unsafe.Pointer) *QAbstractScrollArea {
func UnsafeNewQAbstractScrollArea(h unsafe.Pointer) *QAbstractScrollArea {
return newQAbstractScrollArea((*C.QAbstractScrollArea)(h))
}
@ -57,7 +64,7 @@ func NewQAbstractScrollArea2(parent *QWidget) *QAbstractScrollArea {
}
func (this *QAbstractScrollArea) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAbstractScrollArea_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAbstractScrollArea_MetaObject(this.h)))
}
func (this *QAbstractScrollArea) Metacast(param1 string) unsafe.Pointer {
@ -93,7 +100,7 @@ func (this *QAbstractScrollArea) SetVerticalScrollBarPolicy(verticalScrollBarPol
}
func (this *QAbstractScrollArea) VerticalScrollBar() *QScrollBar {
return newQScrollBar_U(unsafe.Pointer(C.QAbstractScrollArea_VerticalScrollBar(this.h)))
return UnsafeNewQScrollBar(unsafe.Pointer(C.QAbstractScrollArea_VerticalScrollBar(this.h)))
}
func (this *QAbstractScrollArea) SetVerticalScrollBar(scrollbar *QScrollBar) {
@ -109,7 +116,7 @@ func (this *QAbstractScrollArea) SetHorizontalScrollBarPolicy(horizontalScrollBa
}
func (this *QAbstractScrollArea) HorizontalScrollBar() *QScrollBar {
return newQScrollBar_U(unsafe.Pointer(C.QAbstractScrollArea_HorizontalScrollBar(this.h)))
return UnsafeNewQScrollBar(unsafe.Pointer(C.QAbstractScrollArea_HorizontalScrollBar(this.h)))
}
func (this *QAbstractScrollArea) SetHorizontalScrollBar(scrollbar *QScrollBar) {
@ -117,7 +124,7 @@ func (this *QAbstractScrollArea) SetHorizontalScrollBar(scrollbar *QScrollBar) {
}
func (this *QAbstractScrollArea) CornerWidget() *QWidget {
return newQWidget_U(unsafe.Pointer(C.QAbstractScrollArea_CornerWidget(this.h)))
return UnsafeNewQWidget(unsafe.Pointer(C.QAbstractScrollArea_CornerWidget(this.h)))
}
func (this *QAbstractScrollArea) SetCornerWidget(widget *QWidget) {
@ -133,14 +140,14 @@ func (this *QAbstractScrollArea) ScrollBarWidgets(alignment AlignmentFlag) []*QW
_ret := make([]*QWidget, int(_ma.len))
_outCast := (*[0xffff]*C.QWidget)(unsafe.Pointer(_ma.data)) // hey ya
for i := 0; i < int(_ma.len); i++ {
_ret[i] = newQWidget_U(unsafe.Pointer(_outCast[i]))
_ret[i] = UnsafeNewQWidget(unsafe.Pointer(_outCast[i]))
}
C.free(unsafe.Pointer(_ma))
return _ret
}
func (this *QAbstractScrollArea) Viewport() *QWidget {
return newQWidget_U(unsafe.Pointer(C.QAbstractScrollArea_Viewport(this.h)))
return UnsafeNewQWidget(unsafe.Pointer(C.QAbstractScrollArea_Viewport(this.h)))
}
func (this *QAbstractScrollArea) SetViewport(widget *QWidget) {

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -4,7 +4,7 @@
#include <QByteArray>
#include <cstring>
#include <QWidget>
#include "qabstractslider.h"
#include <qabstractslider.h>
#include "gen_qabstractslider.h"
#include "_cgo_export.h"

View File

@ -39,14 +39,21 @@ func (this *QAbstractSlider) cPointer() *C.QAbstractSlider {
return this.h
}
func (this *QAbstractSlider) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractSlider(h *C.QAbstractSlider) *QAbstractSlider {
if h == nil {
return nil
}
return &QAbstractSlider{h: h, QWidget: newQWidget_U(unsafe.Pointer(h))}
return &QAbstractSlider{h: h, QWidget: UnsafeNewQWidget(unsafe.Pointer(h))}
}
func newQAbstractSlider_U(h unsafe.Pointer) *QAbstractSlider {
func UnsafeNewQAbstractSlider(h unsafe.Pointer) *QAbstractSlider {
return newQAbstractSlider((*C.QAbstractSlider)(h))
}
@ -63,7 +70,7 @@ func NewQAbstractSlider2(parent *QWidget) *QAbstractSlider {
}
func (this *QAbstractSlider) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAbstractSlider_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAbstractSlider_MetaObject(this.h)))
}
func (this *QAbstractSlider) Metacast(param1 string) unsafe.Pointer {

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -7,7 +7,7 @@
#include <cstring>
#include <QVariant>
#include <QWidget>
#include "qabstractspinbox.h"
#include <qabstractspinbox.h>
#include "gen_qabstractspinbox.h"
#include "_cgo_export.h"

View File

@ -9,6 +9,7 @@ package qt
import "C"
import (
"github.com/mappu/miqt/libmiqt"
"runtime"
"runtime/cgo"
"unsafe"
@ -56,14 +57,21 @@ func (this *QAbstractSpinBox) cPointer() *C.QAbstractSpinBox {
return this.h
}
func (this *QAbstractSpinBox) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractSpinBox(h *C.QAbstractSpinBox) *QAbstractSpinBox {
if h == nil {
return nil
}
return &QAbstractSpinBox{h: h, QWidget: newQWidget_U(unsafe.Pointer(h))}
return &QAbstractSpinBox{h: h, QWidget: UnsafeNewQWidget(unsafe.Pointer(h))}
}
func newQAbstractSpinBox_U(h unsafe.Pointer) *QAbstractSpinBox {
func UnsafeNewQAbstractSpinBox(h unsafe.Pointer) *QAbstractSpinBox {
return newQAbstractSpinBox((*C.QAbstractSpinBox)(h))
}
@ -80,7 +88,7 @@ func NewQAbstractSpinBox2(parent *QWidget) *QAbstractSpinBox {
}
func (this *QAbstractSpinBox) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAbstractSpinBox_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAbstractSpinBox_MetaObject(this.h)))
}
func (this *QAbstractSpinBox) Metacast(param1 string) unsafe.Pointer {
@ -142,7 +150,7 @@ func (this *QAbstractSpinBox) SpecialValueText() string {
}
func (this *QAbstractSpinBox) SetSpecialValueText(txt string) {
txt_ms := miqt_strdupg(txt)
txt_ms := libmiqt.Strdupg(txt)
defer C.free(txt_ms)
C.QAbstractSpinBox_SetSpecialValueText(this.h, (*C.struct_miqt_string)(txt_ms))
}
@ -233,13 +241,13 @@ func (this *QAbstractSpinBox) InputMethodQuery(param1 InputMethodQuery) *QVarian
}
func (this *QAbstractSpinBox) Validate(input string, pos *int) QValidator__State {
input_ms := miqt_strdupg(input)
input_ms := libmiqt.Strdupg(input)
defer C.free(input_ms)
return (QValidator__State)(C.QAbstractSpinBox_Validate(this.h, (*C.struct_miqt_string)(input_ms), (*C.int)(unsafe.Pointer(pos))))
}
func (this *QAbstractSpinBox) Fixup(input string) {
input_ms := miqt_strdupg(input)
input_ms := libmiqt.Strdupg(input)
defer C.free(input_ms)
C.QAbstractSpinBox_Fixup(this.h, (*C.struct_miqt_string)(input_ms))
}

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -5,7 +5,7 @@
#include <QString>
#include <QByteArray>
#include <cstring>
#include "qabstractstate.h"
#include <qabstractstate.h>
#include "gen_qabstractstate.h"
#include "_cgo_export.h"

View File

@ -26,19 +26,26 @@ func (this *QAbstractState) cPointer() *C.QAbstractState {
return this.h
}
func (this *QAbstractState) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractState(h *C.QAbstractState) *QAbstractState {
if h == nil {
return nil
}
return &QAbstractState{h: h, QObject: newQObject_U(unsafe.Pointer(h))}
return &QAbstractState{h: h, QObject: UnsafeNewQObject(unsafe.Pointer(h))}
}
func newQAbstractState_U(h unsafe.Pointer) *QAbstractState {
func UnsafeNewQAbstractState(h unsafe.Pointer) *QAbstractState {
return newQAbstractState((*C.QAbstractState)(h))
}
func (this *QAbstractState) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAbstractState_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAbstractState_MetaObject(this.h)))
}
func (this *QAbstractState) Metacast(param1 string) unsafe.Pointer {
@ -66,11 +73,11 @@ func QAbstractState_TrUtf8(s string) string {
}
func (this *QAbstractState) ParentState() *QState {
return newQState_U(unsafe.Pointer(C.QAbstractState_ParentState(this.h)))
return UnsafeNewQState(unsafe.Pointer(C.QAbstractState_ParentState(this.h)))
}
func (this *QAbstractState) Machine() *QStateMachine {
return newQStateMachine_U(unsafe.Pointer(C.QAbstractState_Machine(this.h)))
return UnsafeNewQStateMachine(unsafe.Pointer(C.QAbstractState_Machine(this.h)))
}
func (this *QAbstractState) Active() bool {

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -16,7 +16,7 @@
#include <QTextFormat>
#include <QTextFrame>
#include <QTextObjectInterface>
#include "qabstracttextdocumentlayout.h"
#include <qabstracttextdocumentlayout.h>
#include "gen_qabstracttextdocumentlayout.h"
#include "_cgo_export.h"

View File

@ -26,19 +26,26 @@ func (this *QAbstractTextDocumentLayout) cPointer() *C.QAbstractTextDocumentLayo
return this.h
}
func (this *QAbstractTextDocumentLayout) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractTextDocumentLayout(h *C.QAbstractTextDocumentLayout) *QAbstractTextDocumentLayout {
if h == nil {
return nil
}
return &QAbstractTextDocumentLayout{h: h, QObject: newQObject_U(unsafe.Pointer(h))}
return &QAbstractTextDocumentLayout{h: h, QObject: UnsafeNewQObject(unsafe.Pointer(h))}
}
func newQAbstractTextDocumentLayout_U(h unsafe.Pointer) *QAbstractTextDocumentLayout {
func UnsafeNewQAbstractTextDocumentLayout(h unsafe.Pointer) *QAbstractTextDocumentLayout {
return newQAbstractTextDocumentLayout((*C.QAbstractTextDocumentLayout)(h))
}
func (this *QAbstractTextDocumentLayout) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAbstractTextDocumentLayout_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAbstractTextDocumentLayout_MetaObject(this.h)))
}
func (this *QAbstractTextDocumentLayout) Metacast(param1 string) unsafe.Pointer {
@ -131,11 +138,11 @@ func (this *QAbstractTextDocumentLayout) SetPaintDevice(device *QPaintDevice) {
}
func (this *QAbstractTextDocumentLayout) PaintDevice() *QPaintDevice {
return newQPaintDevice_U(unsafe.Pointer(C.QAbstractTextDocumentLayout_PaintDevice(this.h)))
return UnsafeNewQPaintDevice(unsafe.Pointer(C.QAbstractTextDocumentLayout_PaintDevice(this.h)))
}
func (this *QAbstractTextDocumentLayout) Document() *QTextDocument {
return newQTextDocument_U(unsafe.Pointer(C.QAbstractTextDocumentLayout_Document(this.h)))
return UnsafeNewQTextDocument(unsafe.Pointer(C.QAbstractTextDocumentLayout_Document(this.h)))
}
func (this *QAbstractTextDocumentLayout) RegisterHandler(objectType int, component *QObject) {
@ -147,7 +154,7 @@ func (this *QAbstractTextDocumentLayout) UnregisterHandler(objectType int) {
}
func (this *QAbstractTextDocumentLayout) HandlerForObject(objectType int) *QTextObjectInterface {
return newQTextObjectInterface_U(unsafe.Pointer(C.QAbstractTextDocumentLayout_HandlerForObject(this.h, (C.int)(objectType))))
return UnsafeNewQTextObjectInterface(unsafe.Pointer(C.QAbstractTextDocumentLayout_HandlerForObject(this.h, (C.int)(objectType))))
}
func (this *QAbstractTextDocumentLayout) Update() {
@ -182,7 +189,7 @@ func miqt_exec_callback_QAbstractTextDocumentLayout_UpdateBlock(cb C.intptr_t, b
}
// Convert all CABI parameters to Go parameters
slotval1 := newQTextBlock_U(unsafe.Pointer(block))
slotval1 := UnsafeNewQTextBlock(unsafe.Pointer(block))
gofunc(slotval1)
}
@ -202,7 +209,7 @@ func miqt_exec_callback_QAbstractTextDocumentLayout_DocumentSizeChanged(cb C.int
}
// Convert all CABI parameters to Go parameters
slotval1 := newQSizeF_U(unsafe.Pointer(newSize))
slotval1 := UnsafeNewQSizeF(unsafe.Pointer(newSize))
gofunc(slotval1)
}
@ -290,7 +297,7 @@ func miqt_exec_callback_QAbstractTextDocumentLayout_Update1(cb C.intptr_t, param
}
// Convert all CABI parameters to Go parameters
slotval1 := newQRectF_U(unsafe.Pointer(param1))
slotval1 := UnsafeNewQRectF(unsafe.Pointer(param1))
gofunc(slotval1)
}
@ -320,6 +327,13 @@ func (this *QTextObjectInterface) cPointer() *C.QTextObjectInterface {
return this.h
}
func (this *QTextObjectInterface) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQTextObjectInterface(h *C.QTextObjectInterface) *QTextObjectInterface {
if h == nil {
return nil
@ -327,7 +341,7 @@ func newQTextObjectInterface(h *C.QTextObjectInterface) *QTextObjectInterface {
return &QTextObjectInterface{h: h}
}
func newQTextObjectInterface_U(h unsafe.Pointer) *QTextObjectInterface {
func UnsafeNewQTextObjectInterface(h unsafe.Pointer) *QTextObjectInterface {
return newQTextObjectInterface((*C.QTextObjectInterface)(h))
}
@ -371,6 +385,13 @@ func (this *QAbstractTextDocumentLayout__Selection) cPointer() *C.QAbstractTextD
return this.h
}
func (this *QAbstractTextDocumentLayout__Selection) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractTextDocumentLayout__Selection(h *C.QAbstractTextDocumentLayout__Selection) *QAbstractTextDocumentLayout__Selection {
if h == nil {
return nil
@ -378,7 +399,7 @@ func newQAbstractTextDocumentLayout__Selection(h *C.QAbstractTextDocumentLayout_
return &QAbstractTextDocumentLayout__Selection{h: h}
}
func newQAbstractTextDocumentLayout__Selection_U(h unsafe.Pointer) *QAbstractTextDocumentLayout__Selection {
func UnsafeNewQAbstractTextDocumentLayout__Selection(h unsafe.Pointer) *QAbstractTextDocumentLayout__Selection {
return newQAbstractTextDocumentLayout__Selection((*C.QAbstractTextDocumentLayout__Selection)(h))
}
@ -417,6 +438,13 @@ func (this *QAbstractTextDocumentLayout__PaintContext) cPointer() *C.QAbstractTe
return this.h
}
func (this *QAbstractTextDocumentLayout__PaintContext) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractTextDocumentLayout__PaintContext(h *C.QAbstractTextDocumentLayout__PaintContext) *QAbstractTextDocumentLayout__PaintContext {
if h == nil {
return nil
@ -424,7 +452,7 @@ func newQAbstractTextDocumentLayout__PaintContext(h *C.QAbstractTextDocumentLayo
return &QAbstractTextDocumentLayout__PaintContext{h: h}
}
func newQAbstractTextDocumentLayout__PaintContext_U(h unsafe.Pointer) *QAbstractTextDocumentLayout__PaintContext {
func UnsafeNewQAbstractTextDocumentLayout__PaintContext(h unsafe.Pointer) *QAbstractTextDocumentLayout__PaintContext {
return newQAbstractTextDocumentLayout__PaintContext((*C.QAbstractTextDocumentLayout__PaintContext)(h))
}

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -8,7 +8,7 @@
#include <QString>
#include <QByteArray>
#include <cstring>
#include "qabstracttransition.h"
#include <qabstracttransition.h>
#include "gen_qabstracttransition.h"
#include "_cgo_export.h"
@ -60,7 +60,7 @@ struct miqt_array* QAbstractTransition_TargetStates(const QAbstractTransition* s
}
void QAbstractTransition_SetTargetStates(QAbstractTransition* self, struct miqt_array* /* of QAbstractState* */ targets) {
QList<QAbstractState*> targets_QList;
QList<QAbstractState *> targets_QList;
targets_QList.reserve(targets->len);
QAbstractState** targets_arr = static_cast<QAbstractState**>(targets->data);
for(size_t i = 0; i < targets->len; ++i) {

View File

@ -32,19 +32,26 @@ func (this *QAbstractTransition) cPointer() *C.QAbstractTransition {
return this.h
}
func (this *QAbstractTransition) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAbstractTransition(h *C.QAbstractTransition) *QAbstractTransition {
if h == nil {
return nil
}
return &QAbstractTransition{h: h, QObject: newQObject_U(unsafe.Pointer(h))}
return &QAbstractTransition{h: h, QObject: UnsafeNewQObject(unsafe.Pointer(h))}
}
func newQAbstractTransition_U(h unsafe.Pointer) *QAbstractTransition {
func UnsafeNewQAbstractTransition(h unsafe.Pointer) *QAbstractTransition {
return newQAbstractTransition((*C.QAbstractTransition)(h))
}
func (this *QAbstractTransition) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAbstractTransition_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAbstractTransition_MetaObject(this.h)))
}
func (this *QAbstractTransition) Metacast(param1 string) unsafe.Pointer {
@ -72,11 +79,11 @@ func QAbstractTransition_TrUtf8(s string) string {
}
func (this *QAbstractTransition) SourceState() *QState {
return newQState_U(unsafe.Pointer(C.QAbstractTransition_SourceState(this.h)))
return UnsafeNewQState(unsafe.Pointer(C.QAbstractTransition_SourceState(this.h)))
}
func (this *QAbstractTransition) TargetState() *QAbstractState {
return newQAbstractState_U(unsafe.Pointer(C.QAbstractTransition_TargetState(this.h)))
return UnsafeNewQAbstractState(unsafe.Pointer(C.QAbstractTransition_TargetState(this.h)))
}
func (this *QAbstractTransition) SetTargetState(target *QAbstractState) {
@ -88,7 +95,7 @@ func (this *QAbstractTransition) TargetStates() []*QAbstractState {
_ret := make([]*QAbstractState, int(_ma.len))
_outCast := (*[0xffff]*C.QAbstractState)(unsafe.Pointer(_ma.data)) // hey ya
for i := 0; i < int(_ma.len); i++ {
_ret[i] = newQAbstractState_U(unsafe.Pointer(_outCast[i]))
_ret[i] = UnsafeNewQAbstractState(unsafe.Pointer(_outCast[i]))
}
C.free(unsafe.Pointer(_ma))
return _ret
@ -115,7 +122,7 @@ func (this *QAbstractTransition) SetTransitionType(typeVal QAbstractTransition__
}
func (this *QAbstractTransition) Machine() *QStateMachine {
return newQStateMachine_U(unsafe.Pointer(C.QAbstractTransition_Machine(this.h)))
return UnsafeNewQStateMachine(unsafe.Pointer(C.QAbstractTransition_Machine(this.h)))
}
func (this *QAbstractTransition) AddAnimation(animation *QAbstractAnimation) {
@ -131,7 +138,7 @@ func (this *QAbstractTransition) Animations() []*QAbstractAnimation {
_ret := make([]*QAbstractAnimation, int(_ma.len))
_outCast := (*[0xffff]*C.QAbstractAnimation)(unsafe.Pointer(_ma.data)) // hey ya
for i := 0; i < int(_ma.len); i++ {
_ret[i] = newQAbstractAnimation_U(unsafe.Pointer(_outCast[i]))
_ret[i] = UnsafeNewQAbstractAnimation(unsafe.Pointer(_outCast[i]))
}
C.free(unsafe.Pointer(_ma))
return _ret

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -29,7 +29,7 @@
#include <cstring>
#include <QVariant>
#include <QWindow>
#include "qaccessible.h"
#include <qaccessible.h>
#include "gen_qaccessible.h"
#include "_cgo_export.h"

View File

@ -9,6 +9,7 @@ package qt
import "C"
import (
"github.com/mappu/miqt/libmiqt"
"runtime"
"unsafe"
)
@ -236,6 +237,13 @@ func (this *QAccessible) cPointer() *C.QAccessible {
return this.h
}
func (this *QAccessible) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessible(h *C.QAccessible) *QAccessible {
if h == nil {
return nil
@ -243,7 +251,7 @@ func newQAccessible(h *C.QAccessible) *QAccessible {
return &QAccessible{h: h}
}
func newQAccessible_U(h unsafe.Pointer) *QAccessible {
func UnsafeNewQAccessible(h unsafe.Pointer) *QAccessible {
return newQAccessible((*C.QAccessible)(h))
}
@ -256,7 +264,7 @@ func QAccessible_RemoveActivationObserver(param1 *QAccessible__ActivationObserve
}
func QAccessible_QueryAccessibleInterface(param1 *QObject) *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessible_QueryAccessibleInterface(param1.cPointer())))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessible_QueryAccessibleInterface(param1.cPointer())))
}
func QAccessible_UniqueId(iface *QAccessibleInterface) uint {
@ -264,7 +272,7 @@ func QAccessible_UniqueId(iface *QAccessibleInterface) uint {
}
func QAccessible_AccessibleInterface(uniqueId uint) *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessible_AccessibleInterface((C.uint)(uniqueId))))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessible_AccessibleInterface((C.uint)(uniqueId))))
}
func QAccessible_RegisterAccessibleInterface(iface *QAccessibleInterface) uint {
@ -320,6 +328,13 @@ func (this *QAccessibleInterface) cPointer() *C.QAccessibleInterface {
return this.h
}
func (this *QAccessibleInterface) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleInterface(h *C.QAccessibleInterface) *QAccessibleInterface {
if h == nil {
return nil
@ -327,7 +342,7 @@ func newQAccessibleInterface(h *C.QAccessibleInterface) *QAccessibleInterface {
return &QAccessibleInterface{h: h}
}
func newQAccessibleInterface_U(h unsafe.Pointer) *QAccessibleInterface {
func UnsafeNewQAccessibleInterface(h unsafe.Pointer) *QAccessibleInterface {
return newQAccessibleInterface((*C.QAccessibleInterface)(h))
}
@ -336,27 +351,27 @@ func (this *QAccessibleInterface) IsValid() bool {
}
func (this *QAccessibleInterface) Object() *QObject {
return newQObject_U(unsafe.Pointer(C.QAccessibleInterface_Object(this.h)))
return UnsafeNewQObject(unsafe.Pointer(C.QAccessibleInterface_Object(this.h)))
}
func (this *QAccessibleInterface) Window() *QWindow {
return newQWindow_U(unsafe.Pointer(C.QAccessibleInterface_Window(this.h)))
return UnsafeNewQWindow(unsafe.Pointer(C.QAccessibleInterface_Window(this.h)))
}
func (this *QAccessibleInterface) FocusChild() *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleInterface_FocusChild(this.h)))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleInterface_FocusChild(this.h)))
}
func (this *QAccessibleInterface) ChildAt(x int, y int) *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleInterface_ChildAt(this.h, (C.int)(x), (C.int)(y))))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleInterface_ChildAt(this.h, (C.int)(x), (C.int)(y))))
}
func (this *QAccessibleInterface) Parent() *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleInterface_Parent(this.h)))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleInterface_Parent(this.h)))
}
func (this *QAccessibleInterface) Child(index int) *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleInterface_Child(this.h, (C.int)(index))))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleInterface_Child(this.h, (C.int)(index))))
}
func (this *QAccessibleInterface) ChildCount() int {
@ -375,7 +390,7 @@ func (this *QAccessibleInterface) Text(t QAccessible__Text) string {
}
func (this *QAccessibleInterface) SetText(t QAccessible__Text, text string) {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
C.QAccessibleInterface_SetText(this.h, (C.int)(t), (*C.struct_miqt_string)(text_ms))
}
@ -413,31 +428,31 @@ func (this *QAccessibleInterface) BackgroundColor() *QColor {
}
func (this *QAccessibleInterface) TextInterface() *QAccessibleTextInterface {
return newQAccessibleTextInterface_U(unsafe.Pointer(C.QAccessibleInterface_TextInterface(this.h)))
return UnsafeNewQAccessibleTextInterface(unsafe.Pointer(C.QAccessibleInterface_TextInterface(this.h)))
}
func (this *QAccessibleInterface) EditableTextInterface() *QAccessibleEditableTextInterface {
return newQAccessibleEditableTextInterface_U(unsafe.Pointer(C.QAccessibleInterface_EditableTextInterface(this.h)))
return UnsafeNewQAccessibleEditableTextInterface(unsafe.Pointer(C.QAccessibleInterface_EditableTextInterface(this.h)))
}
func (this *QAccessibleInterface) ValueInterface() *QAccessibleValueInterface {
return newQAccessibleValueInterface_U(unsafe.Pointer(C.QAccessibleInterface_ValueInterface(this.h)))
return UnsafeNewQAccessibleValueInterface(unsafe.Pointer(C.QAccessibleInterface_ValueInterface(this.h)))
}
func (this *QAccessibleInterface) ActionInterface() *QAccessibleActionInterface {
return newQAccessibleActionInterface_U(unsafe.Pointer(C.QAccessibleInterface_ActionInterface(this.h)))
return UnsafeNewQAccessibleActionInterface(unsafe.Pointer(C.QAccessibleInterface_ActionInterface(this.h)))
}
func (this *QAccessibleInterface) ImageInterface() *QAccessibleImageInterface {
return newQAccessibleImageInterface_U(unsafe.Pointer(C.QAccessibleInterface_ImageInterface(this.h)))
return UnsafeNewQAccessibleImageInterface(unsafe.Pointer(C.QAccessibleInterface_ImageInterface(this.h)))
}
func (this *QAccessibleInterface) TableInterface() *QAccessibleTableInterface {
return newQAccessibleTableInterface_U(unsafe.Pointer(C.QAccessibleInterface_TableInterface(this.h)))
return UnsafeNewQAccessibleTableInterface(unsafe.Pointer(C.QAccessibleInterface_TableInterface(this.h)))
}
func (this *QAccessibleInterface) TableCellInterface() *QAccessibleTableCellInterface {
return newQAccessibleTableCellInterface_U(unsafe.Pointer(C.QAccessibleInterface_TableCellInterface(this.h)))
return UnsafeNewQAccessibleTableCellInterface(unsafe.Pointer(C.QAccessibleInterface_TableCellInterface(this.h)))
}
func (this *QAccessibleInterface) VirtualHook(id int, data unsafe.Pointer) {
@ -459,6 +474,13 @@ func (this *QAccessibleTextInterface) cPointer() *C.QAccessibleTextInterface {
return this.h
}
func (this *QAccessibleTextInterface) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleTextInterface(h *C.QAccessibleTextInterface) *QAccessibleTextInterface {
if h == nil {
return nil
@ -466,7 +488,7 @@ func newQAccessibleTextInterface(h *C.QAccessibleTextInterface) *QAccessibleText
return &QAccessibleTextInterface{h: h}
}
func newQAccessibleTextInterface_U(h unsafe.Pointer) *QAccessibleTextInterface {
func UnsafeNewQAccessibleTextInterface(h unsafe.Pointer) *QAccessibleTextInterface {
return newQAccessibleTextInterface((*C.QAccessibleTextInterface)(h))
}
@ -581,6 +603,13 @@ func (this *QAccessibleEditableTextInterface) cPointer() *C.QAccessibleEditableT
return this.h
}
func (this *QAccessibleEditableTextInterface) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleEditableTextInterface(h *C.QAccessibleEditableTextInterface) *QAccessibleEditableTextInterface {
if h == nil {
return nil
@ -588,7 +617,7 @@ func newQAccessibleEditableTextInterface(h *C.QAccessibleEditableTextInterface)
return &QAccessibleEditableTextInterface{h: h}
}
func newQAccessibleEditableTextInterface_U(h unsafe.Pointer) *QAccessibleEditableTextInterface {
func UnsafeNewQAccessibleEditableTextInterface(h unsafe.Pointer) *QAccessibleEditableTextInterface {
return newQAccessibleEditableTextInterface((*C.QAccessibleEditableTextInterface)(h))
}
@ -597,13 +626,13 @@ func (this *QAccessibleEditableTextInterface) DeleteText(startOffset int, endOff
}
func (this *QAccessibleEditableTextInterface) InsertText(offset int, text string) {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
C.QAccessibleEditableTextInterface_InsertText(this.h, (C.int)(offset), (*C.struct_miqt_string)(text_ms))
}
func (this *QAccessibleEditableTextInterface) ReplaceText(startOffset int, endOffset int, text string) {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
C.QAccessibleEditableTextInterface_ReplaceText(this.h, (C.int)(startOffset), (C.int)(endOffset), (*C.struct_miqt_string)(text_ms))
}
@ -637,6 +666,13 @@ func (this *QAccessibleValueInterface) cPointer() *C.QAccessibleValueInterface {
return this.h
}
func (this *QAccessibleValueInterface) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleValueInterface(h *C.QAccessibleValueInterface) *QAccessibleValueInterface {
if h == nil {
return nil
@ -644,7 +680,7 @@ func newQAccessibleValueInterface(h *C.QAccessibleValueInterface) *QAccessibleVa
return &QAccessibleValueInterface{h: h}
}
func newQAccessibleValueInterface_U(h unsafe.Pointer) *QAccessibleValueInterface {
func UnsafeNewQAccessibleValueInterface(h unsafe.Pointer) *QAccessibleValueInterface {
return newQAccessibleValueInterface((*C.QAccessibleValueInterface)(h))
}
@ -709,6 +745,13 @@ func (this *QAccessibleTableCellInterface) cPointer() *C.QAccessibleTableCellInt
return this.h
}
func (this *QAccessibleTableCellInterface) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleTableCellInterface(h *C.QAccessibleTableCellInterface) *QAccessibleTableCellInterface {
if h == nil {
return nil
@ -716,7 +759,7 @@ func newQAccessibleTableCellInterface(h *C.QAccessibleTableCellInterface) *QAcce
return &QAccessibleTableCellInterface{h: h}
}
func newQAccessibleTableCellInterface_U(h unsafe.Pointer) *QAccessibleTableCellInterface {
func UnsafeNewQAccessibleTableCellInterface(h unsafe.Pointer) *QAccessibleTableCellInterface {
return newQAccessibleTableCellInterface((*C.QAccessibleTableCellInterface)(h))
}
@ -729,7 +772,7 @@ func (this *QAccessibleTableCellInterface) ColumnHeaderCells() []*QAccessibleInt
_ret := make([]*QAccessibleInterface, int(_ma.len))
_outCast := (*[0xffff]*C.QAccessibleInterface)(unsafe.Pointer(_ma.data)) // hey ya
for i := 0; i < int(_ma.len); i++ {
_ret[i] = newQAccessibleInterface_U(unsafe.Pointer(_outCast[i]))
_ret[i] = UnsafeNewQAccessibleInterface(unsafe.Pointer(_outCast[i]))
}
C.free(unsafe.Pointer(_ma))
return _ret
@ -740,7 +783,7 @@ func (this *QAccessibleTableCellInterface) RowHeaderCells() []*QAccessibleInterf
_ret := make([]*QAccessibleInterface, int(_ma.len))
_outCast := (*[0xffff]*C.QAccessibleInterface)(unsafe.Pointer(_ma.data)) // hey ya
for i := 0; i < int(_ma.len); i++ {
_ret[i] = newQAccessibleInterface_U(unsafe.Pointer(_outCast[i]))
_ret[i] = UnsafeNewQAccessibleInterface(unsafe.Pointer(_outCast[i]))
}
C.free(unsafe.Pointer(_ma))
return _ret
@ -763,7 +806,7 @@ func (this *QAccessibleTableCellInterface) RowExtent() int {
}
func (this *QAccessibleTableCellInterface) Table() *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleTableCellInterface_Table(this.h)))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleTableCellInterface_Table(this.h)))
}
func (this *QAccessibleTableCellInterface) OperatorAssign(param1 *QAccessibleTableCellInterface) {
@ -795,6 +838,13 @@ func (this *QAccessibleTableInterface) cPointer() *C.QAccessibleTableInterface {
return this.h
}
func (this *QAccessibleTableInterface) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleTableInterface(h *C.QAccessibleTableInterface) *QAccessibleTableInterface {
if h == nil {
return nil
@ -802,20 +852,20 @@ func newQAccessibleTableInterface(h *C.QAccessibleTableInterface) *QAccessibleTa
return &QAccessibleTableInterface{h: h}
}
func newQAccessibleTableInterface_U(h unsafe.Pointer) *QAccessibleTableInterface {
func UnsafeNewQAccessibleTableInterface(h unsafe.Pointer) *QAccessibleTableInterface {
return newQAccessibleTableInterface((*C.QAccessibleTableInterface)(h))
}
func (this *QAccessibleTableInterface) Caption() *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleTableInterface_Caption(this.h)))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleTableInterface_Caption(this.h)))
}
func (this *QAccessibleTableInterface) Summary() *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleTableInterface_Summary(this.h)))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleTableInterface_Summary(this.h)))
}
func (this *QAccessibleTableInterface) CellAt(row int, column int) *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleTableInterface_CellAt(this.h, (C.int)(row), (C.int)(column))))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleTableInterface_CellAt(this.h, (C.int)(row), (C.int)(column))))
}
func (this *QAccessibleTableInterface) SelectedCellCount() int {
@ -827,7 +877,7 @@ func (this *QAccessibleTableInterface) SelectedCells() []*QAccessibleInterface {
_ret := make([]*QAccessibleInterface, int(_ma.len))
_outCast := (*[0xffff]*C.QAccessibleInterface)(unsafe.Pointer(_ma.data)) // hey ya
for i := 0; i < int(_ma.len); i++ {
_ret[i] = newQAccessibleInterface_U(unsafe.Pointer(_outCast[i]))
_ret[i] = UnsafeNewQAccessibleInterface(unsafe.Pointer(_outCast[i]))
}
C.free(unsafe.Pointer(_ma))
return _ret
@ -938,6 +988,13 @@ func (this *QAccessibleActionInterface) cPointer() *C.QAccessibleActionInterface
return this.h
}
func (this *QAccessibleActionInterface) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleActionInterface(h *C.QAccessibleActionInterface) *QAccessibleActionInterface {
if h == nil {
return nil
@ -945,7 +1002,7 @@ func newQAccessibleActionInterface(h *C.QAccessibleActionInterface) *QAccessible
return &QAccessibleActionInterface{h: h}
}
func newQAccessibleActionInterface_U(h unsafe.Pointer) *QAccessibleActionInterface {
func UnsafeNewQAccessibleActionInterface(h unsafe.Pointer) *QAccessibleActionInterface {
return newQAccessibleActionInterface((*C.QAccessibleActionInterface)(h))
}
@ -982,7 +1039,7 @@ func (this *QAccessibleActionInterface) ActionNames() []string {
}
func (this *QAccessibleActionInterface) LocalizedActionName(name string) string {
name_ms := miqt_strdupg(name)
name_ms := libmiqt.Strdupg(name)
defer C.free(name_ms)
var _ms *C.struct_miqt_string = C.QAccessibleActionInterface_LocalizedActionName(this.h, (*C.struct_miqt_string)(name_ms))
_ret := C.GoStringN(&_ms.data, C.int(int64(_ms.len)))
@ -991,7 +1048,7 @@ func (this *QAccessibleActionInterface) LocalizedActionName(name string) string
}
func (this *QAccessibleActionInterface) LocalizedActionDescription(name string) string {
name_ms := miqt_strdupg(name)
name_ms := libmiqt.Strdupg(name)
defer C.free(name_ms)
var _ms *C.struct_miqt_string = C.QAccessibleActionInterface_LocalizedActionDescription(this.h, (*C.struct_miqt_string)(name_ms))
_ret := C.GoStringN(&_ms.data, C.int(int64(_ms.len)))
@ -1000,13 +1057,13 @@ func (this *QAccessibleActionInterface) LocalizedActionDescription(name string)
}
func (this *QAccessibleActionInterface) DoAction(actionName string) {
actionName_ms := miqt_strdupg(actionName)
actionName_ms := libmiqt.Strdupg(actionName)
defer C.free(actionName_ms)
C.QAccessibleActionInterface_DoAction(this.h, (*C.struct_miqt_string)(actionName_ms))
}
func (this *QAccessibleActionInterface) KeyBindingsForAction(actionName string) []string {
actionName_ms := miqt_strdupg(actionName)
actionName_ms := libmiqt.Strdupg(actionName)
defer C.free(actionName_ms)
var _ma *C.struct_miqt_array = C.QAccessibleActionInterface_KeyBindingsForAction(this.h, (*C.struct_miqt_string)(actionName_ms))
_ret := make([]string, int(_ma.len))
@ -1178,6 +1235,13 @@ func (this *QAccessibleImageInterface) cPointer() *C.QAccessibleImageInterface {
return this.h
}
func (this *QAccessibleImageInterface) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleImageInterface(h *C.QAccessibleImageInterface) *QAccessibleImageInterface {
if h == nil {
return nil
@ -1185,7 +1249,7 @@ func newQAccessibleImageInterface(h *C.QAccessibleImageInterface) *QAccessibleIm
return &QAccessibleImageInterface{h: h}
}
func newQAccessibleImageInterface_U(h unsafe.Pointer) *QAccessibleImageInterface {
func UnsafeNewQAccessibleImageInterface(h unsafe.Pointer) *QAccessibleImageInterface {
return newQAccessibleImageInterface((*C.QAccessibleImageInterface)(h))
}
@ -1239,6 +1303,13 @@ func (this *QAccessibleEvent) cPointer() *C.QAccessibleEvent {
return this.h
}
func (this *QAccessibleEvent) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleEvent(h *C.QAccessibleEvent) *QAccessibleEvent {
if h == nil {
return nil
@ -1246,7 +1317,7 @@ func newQAccessibleEvent(h *C.QAccessibleEvent) *QAccessibleEvent {
return &QAccessibleEvent{h: h}
}
func newQAccessibleEvent_U(h unsafe.Pointer) *QAccessibleEvent {
func UnsafeNewQAccessibleEvent(h unsafe.Pointer) *QAccessibleEvent {
return newQAccessibleEvent((*C.QAccessibleEvent)(h))
}
@ -1267,7 +1338,7 @@ func (this *QAccessibleEvent) Type() QAccessible__Event {
}
func (this *QAccessibleEvent) Object() *QObject {
return newQObject_U(unsafe.Pointer(C.QAccessibleEvent_Object(this.h)))
return UnsafeNewQObject(unsafe.Pointer(C.QAccessibleEvent_Object(this.h)))
}
func (this *QAccessibleEvent) UniqueId() uint {
@ -1283,7 +1354,7 @@ func (this *QAccessibleEvent) Child() int {
}
func (this *QAccessibleEvent) AccessibleInterface() *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleEvent_AccessibleInterface(this.h)))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleEvent_AccessibleInterface(this.h)))
}
// Delete this object from C++ memory.
@ -1312,14 +1383,21 @@ func (this *QAccessibleStateChangeEvent) cPointer() *C.QAccessibleStateChangeEve
return this.h
}
func (this *QAccessibleStateChangeEvent) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleStateChangeEvent(h *C.QAccessibleStateChangeEvent) *QAccessibleStateChangeEvent {
if h == nil {
return nil
}
return &QAccessibleStateChangeEvent{h: h, QAccessibleEvent: newQAccessibleEvent_U(unsafe.Pointer(h))}
return &QAccessibleStateChangeEvent{h: h, QAccessibleEvent: UnsafeNewQAccessibleEvent(unsafe.Pointer(h))}
}
func newQAccessibleStateChangeEvent_U(h unsafe.Pointer) *QAccessibleStateChangeEvent {
func UnsafeNewQAccessibleStateChangeEvent(h unsafe.Pointer) *QAccessibleStateChangeEvent {
return newQAccessibleStateChangeEvent((*C.QAccessibleStateChangeEvent)(h))
}
@ -1368,14 +1446,21 @@ func (this *QAccessibleTextCursorEvent) cPointer() *C.QAccessibleTextCursorEvent
return this.h
}
func (this *QAccessibleTextCursorEvent) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleTextCursorEvent(h *C.QAccessibleTextCursorEvent) *QAccessibleTextCursorEvent {
if h == nil {
return nil
}
return &QAccessibleTextCursorEvent{h: h, QAccessibleEvent: newQAccessibleEvent_U(unsafe.Pointer(h))}
return &QAccessibleTextCursorEvent{h: h, QAccessibleEvent: UnsafeNewQAccessibleEvent(unsafe.Pointer(h))}
}
func newQAccessibleTextCursorEvent_U(h unsafe.Pointer) *QAccessibleTextCursorEvent {
func UnsafeNewQAccessibleTextCursorEvent(h unsafe.Pointer) *QAccessibleTextCursorEvent {
return newQAccessibleTextCursorEvent((*C.QAccessibleTextCursorEvent)(h))
}
@ -1425,14 +1510,21 @@ func (this *QAccessibleTextSelectionEvent) cPointer() *C.QAccessibleTextSelectio
return this.h
}
func (this *QAccessibleTextSelectionEvent) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleTextSelectionEvent(h *C.QAccessibleTextSelectionEvent) *QAccessibleTextSelectionEvent {
if h == nil {
return nil
}
return &QAccessibleTextSelectionEvent{h: h, QAccessibleTextCursorEvent: newQAccessibleTextCursorEvent_U(unsafe.Pointer(h))}
return &QAccessibleTextSelectionEvent{h: h, QAccessibleTextCursorEvent: UnsafeNewQAccessibleTextCursorEvent(unsafe.Pointer(h))}
}
func newQAccessibleTextSelectionEvent_U(h unsafe.Pointer) *QAccessibleTextSelectionEvent {
func UnsafeNewQAccessibleTextSelectionEvent(h unsafe.Pointer) *QAccessibleTextSelectionEvent {
return newQAccessibleTextSelectionEvent((*C.QAccessibleTextSelectionEvent)(h))
}
@ -1486,20 +1578,27 @@ func (this *QAccessibleTextInsertEvent) cPointer() *C.QAccessibleTextInsertEvent
return this.h
}
func (this *QAccessibleTextInsertEvent) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleTextInsertEvent(h *C.QAccessibleTextInsertEvent) *QAccessibleTextInsertEvent {
if h == nil {
return nil
}
return &QAccessibleTextInsertEvent{h: h, QAccessibleTextCursorEvent: newQAccessibleTextCursorEvent_U(unsafe.Pointer(h))}
return &QAccessibleTextInsertEvent{h: h, QAccessibleTextCursorEvent: UnsafeNewQAccessibleTextCursorEvent(unsafe.Pointer(h))}
}
func newQAccessibleTextInsertEvent_U(h unsafe.Pointer) *QAccessibleTextInsertEvent {
func UnsafeNewQAccessibleTextInsertEvent(h unsafe.Pointer) *QAccessibleTextInsertEvent {
return newQAccessibleTextInsertEvent((*C.QAccessibleTextInsertEvent)(h))
}
// NewQAccessibleTextInsertEvent constructs a new QAccessibleTextInsertEvent object.
func NewQAccessibleTextInsertEvent(obj *QObject, position int, text string) *QAccessibleTextInsertEvent {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
ret := C.QAccessibleTextInsertEvent_new(obj.cPointer(), (C.int)(position), (*C.struct_miqt_string)(text_ms))
return newQAccessibleTextInsertEvent(ret)
@ -1507,7 +1606,7 @@ func NewQAccessibleTextInsertEvent(obj *QObject, position int, text string) *QAc
// NewQAccessibleTextInsertEvent2 constructs a new QAccessibleTextInsertEvent object.
func NewQAccessibleTextInsertEvent2(iface *QAccessibleInterface, position int, text string) *QAccessibleTextInsertEvent {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
ret := C.QAccessibleTextInsertEvent_new2(iface.cPointer(), (C.int)(position), (*C.struct_miqt_string)(text_ms))
return newQAccessibleTextInsertEvent(ret)
@ -1550,20 +1649,27 @@ func (this *QAccessibleTextRemoveEvent) cPointer() *C.QAccessibleTextRemoveEvent
return this.h
}
func (this *QAccessibleTextRemoveEvent) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleTextRemoveEvent(h *C.QAccessibleTextRemoveEvent) *QAccessibleTextRemoveEvent {
if h == nil {
return nil
}
return &QAccessibleTextRemoveEvent{h: h, QAccessibleTextCursorEvent: newQAccessibleTextCursorEvent_U(unsafe.Pointer(h))}
return &QAccessibleTextRemoveEvent{h: h, QAccessibleTextCursorEvent: UnsafeNewQAccessibleTextCursorEvent(unsafe.Pointer(h))}
}
func newQAccessibleTextRemoveEvent_U(h unsafe.Pointer) *QAccessibleTextRemoveEvent {
func UnsafeNewQAccessibleTextRemoveEvent(h unsafe.Pointer) *QAccessibleTextRemoveEvent {
return newQAccessibleTextRemoveEvent((*C.QAccessibleTextRemoveEvent)(h))
}
// NewQAccessibleTextRemoveEvent constructs a new QAccessibleTextRemoveEvent object.
func NewQAccessibleTextRemoveEvent(obj *QObject, position int, text string) *QAccessibleTextRemoveEvent {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
ret := C.QAccessibleTextRemoveEvent_new(obj.cPointer(), (C.int)(position), (*C.struct_miqt_string)(text_ms))
return newQAccessibleTextRemoveEvent(ret)
@ -1571,7 +1677,7 @@ func NewQAccessibleTextRemoveEvent(obj *QObject, position int, text string) *QAc
// NewQAccessibleTextRemoveEvent2 constructs a new QAccessibleTextRemoveEvent object.
func NewQAccessibleTextRemoveEvent2(iface *QAccessibleInterface, position int, text string) *QAccessibleTextRemoveEvent {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
ret := C.QAccessibleTextRemoveEvent_new2(iface.cPointer(), (C.int)(position), (*C.struct_miqt_string)(text_ms))
return newQAccessibleTextRemoveEvent(ret)
@ -1614,22 +1720,29 @@ func (this *QAccessibleTextUpdateEvent) cPointer() *C.QAccessibleTextUpdateEvent
return this.h
}
func (this *QAccessibleTextUpdateEvent) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleTextUpdateEvent(h *C.QAccessibleTextUpdateEvent) *QAccessibleTextUpdateEvent {
if h == nil {
return nil
}
return &QAccessibleTextUpdateEvent{h: h, QAccessibleTextCursorEvent: newQAccessibleTextCursorEvent_U(unsafe.Pointer(h))}
return &QAccessibleTextUpdateEvent{h: h, QAccessibleTextCursorEvent: UnsafeNewQAccessibleTextCursorEvent(unsafe.Pointer(h))}
}
func newQAccessibleTextUpdateEvent_U(h unsafe.Pointer) *QAccessibleTextUpdateEvent {
func UnsafeNewQAccessibleTextUpdateEvent(h unsafe.Pointer) *QAccessibleTextUpdateEvent {
return newQAccessibleTextUpdateEvent((*C.QAccessibleTextUpdateEvent)(h))
}
// NewQAccessibleTextUpdateEvent constructs a new QAccessibleTextUpdateEvent object.
func NewQAccessibleTextUpdateEvent(obj *QObject, position int, oldText string, text string) *QAccessibleTextUpdateEvent {
oldText_ms := miqt_strdupg(oldText)
oldText_ms := libmiqt.Strdupg(oldText)
defer C.free(oldText_ms)
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
ret := C.QAccessibleTextUpdateEvent_new(obj.cPointer(), (C.int)(position), (*C.struct_miqt_string)(oldText_ms), (*C.struct_miqt_string)(text_ms))
return newQAccessibleTextUpdateEvent(ret)
@ -1637,9 +1750,9 @@ func NewQAccessibleTextUpdateEvent(obj *QObject, position int, oldText string, t
// NewQAccessibleTextUpdateEvent2 constructs a new QAccessibleTextUpdateEvent object.
func NewQAccessibleTextUpdateEvent2(iface *QAccessibleInterface, position int, oldText string, text string) *QAccessibleTextUpdateEvent {
oldText_ms := miqt_strdupg(oldText)
oldText_ms := libmiqt.Strdupg(oldText)
defer C.free(oldText_ms)
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
ret := C.QAccessibleTextUpdateEvent_new2(iface.cPointer(), (C.int)(position), (*C.struct_miqt_string)(oldText_ms), (*C.struct_miqt_string)(text_ms))
return newQAccessibleTextUpdateEvent(ret)
@ -1689,14 +1802,21 @@ func (this *QAccessibleValueChangeEvent) cPointer() *C.QAccessibleValueChangeEve
return this.h
}
func (this *QAccessibleValueChangeEvent) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleValueChangeEvent(h *C.QAccessibleValueChangeEvent) *QAccessibleValueChangeEvent {
if h == nil {
return nil
}
return &QAccessibleValueChangeEvent{h: h, QAccessibleEvent: newQAccessibleEvent_U(unsafe.Pointer(h))}
return &QAccessibleValueChangeEvent{h: h, QAccessibleEvent: UnsafeNewQAccessibleEvent(unsafe.Pointer(h))}
}
func newQAccessibleValueChangeEvent_U(h unsafe.Pointer) *QAccessibleValueChangeEvent {
func UnsafeNewQAccessibleValueChangeEvent(h unsafe.Pointer) *QAccessibleValueChangeEvent {
return newQAccessibleValueChangeEvent((*C.QAccessibleValueChangeEvent)(h))
}
@ -1749,14 +1869,21 @@ func (this *QAccessibleTableModelChangeEvent) cPointer() *C.QAccessibleTableMode
return this.h
}
func (this *QAccessibleTableModelChangeEvent) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleTableModelChangeEvent(h *C.QAccessibleTableModelChangeEvent) *QAccessibleTableModelChangeEvent {
if h == nil {
return nil
}
return &QAccessibleTableModelChangeEvent{h: h, QAccessibleEvent: newQAccessibleEvent_U(unsafe.Pointer(h))}
return &QAccessibleTableModelChangeEvent{h: h, QAccessibleEvent: UnsafeNewQAccessibleEvent(unsafe.Pointer(h))}
}
func newQAccessibleTableModelChangeEvent_U(h unsafe.Pointer) *QAccessibleTableModelChangeEvent {
func UnsafeNewQAccessibleTableModelChangeEvent(h unsafe.Pointer) *QAccessibleTableModelChangeEvent {
return newQAccessibleTableModelChangeEvent((*C.QAccessibleTableModelChangeEvent)(h))
}
@ -1837,6 +1964,13 @@ func (this *QAccessible__State) cPointer() *C.QAccessible__State {
return this.h
}
func (this *QAccessible__State) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessible__State(h *C.QAccessible__State) *QAccessible__State {
if h == nil {
return nil
@ -1844,7 +1978,7 @@ func newQAccessible__State(h *C.QAccessible__State) *QAccessible__State {
return &QAccessible__State{h: h}
}
func newQAccessible__State_U(h unsafe.Pointer) *QAccessible__State {
func UnsafeNewQAccessible__State(h unsafe.Pointer) *QAccessible__State {
return newQAccessible__State((*C.QAccessible__State)(h))
}
@ -1885,6 +2019,13 @@ func (this *QAccessible__ActivationObserver) cPointer() *C.QAccessible__Activati
return this.h
}
func (this *QAccessible__ActivationObserver) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessible__ActivationObserver(h *C.QAccessible__ActivationObserver) *QAccessible__ActivationObserver {
if h == nil {
return nil
@ -1892,7 +2033,7 @@ func newQAccessible__ActivationObserver(h *C.QAccessible__ActivationObserver) *Q
return &QAccessible__ActivationObserver{h: h}
}
func newQAccessible__ActivationObserver_U(h unsafe.Pointer) *QAccessible__ActivationObserver {
func UnsafeNewQAccessible__ActivationObserver(h unsafe.Pointer) *QAccessible__ActivationObserver {
return newQAccessible__ActivationObserver((*C.QAccessible__ActivationObserver)(h))
}

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -6,7 +6,7 @@
#include <QString>
#include <QByteArray>
#include <cstring>
#include "qaccessiblebridge.h"
#include <qaccessiblebridge.h>
#include "gen_qaccessiblebridge.h"
#include "_cgo_export.h"

View File

@ -9,6 +9,7 @@ package qt
import "C"
import (
"github.com/mappu/miqt/libmiqt"
"runtime"
"unsafe"
)
@ -24,6 +25,13 @@ func (this *QAccessibleBridge) cPointer() *C.QAccessibleBridge {
return this.h
}
func (this *QAccessibleBridge) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleBridge(h *C.QAccessibleBridge) *QAccessibleBridge {
if h == nil {
return nil
@ -31,7 +39,7 @@ func newQAccessibleBridge(h *C.QAccessibleBridge) *QAccessibleBridge {
return &QAccessibleBridge{h: h}
}
func newQAccessibleBridge_U(h unsafe.Pointer) *QAccessibleBridge {
func UnsafeNewQAccessibleBridge(h unsafe.Pointer) *QAccessibleBridge {
return newQAccessibleBridge((*C.QAccessibleBridge)(h))
}
@ -73,19 +81,26 @@ func (this *QAccessibleBridgePlugin) cPointer() *C.QAccessibleBridgePlugin {
return this.h
}
func (this *QAccessibleBridgePlugin) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleBridgePlugin(h *C.QAccessibleBridgePlugin) *QAccessibleBridgePlugin {
if h == nil {
return nil
}
return &QAccessibleBridgePlugin{h: h, QObject: newQObject_U(unsafe.Pointer(h))}
return &QAccessibleBridgePlugin{h: h, QObject: UnsafeNewQObject(unsafe.Pointer(h))}
}
func newQAccessibleBridgePlugin_U(h unsafe.Pointer) *QAccessibleBridgePlugin {
func UnsafeNewQAccessibleBridgePlugin(h unsafe.Pointer) *QAccessibleBridgePlugin {
return newQAccessibleBridgePlugin((*C.QAccessibleBridgePlugin)(h))
}
func (this *QAccessibleBridgePlugin) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAccessibleBridgePlugin_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAccessibleBridgePlugin_MetaObject(this.h)))
}
func (this *QAccessibleBridgePlugin) Metacast(param1 string) unsafe.Pointer {
@ -113,9 +128,9 @@ func QAccessibleBridgePlugin_TrUtf8(s string) string {
}
func (this *QAccessibleBridgePlugin) Create(key string) *QAccessibleBridge {
key_ms := miqt_strdupg(key)
key_ms := libmiqt.Strdupg(key)
defer C.free(key_ms)
return newQAccessibleBridge_U(unsafe.Pointer(C.QAccessibleBridgePlugin_Create(this.h, (*C.struct_miqt_string)(key_ms))))
return UnsafeNewQAccessibleBridge(unsafe.Pointer(C.QAccessibleBridgePlugin_Create(this.h, (*C.struct_miqt_string)(key_ms))))
}
func QAccessibleBridgePlugin_Tr2(s string, c string) string {

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -8,7 +8,7 @@
#include <QByteArray>
#include <cstring>
#include <QWindow>
#include "qaccessibleobject.h"
#include <qaccessibleobject.h>
#include "gen_qaccessibleobject.h"
#include "_cgo_export.h"

View File

@ -9,6 +9,7 @@ package qt
import "C"
import (
"github.com/mappu/miqt/libmiqt"
"runtime"
"unsafe"
)
@ -25,14 +26,21 @@ func (this *QAccessibleObject) cPointer() *C.QAccessibleObject {
return this.h
}
func (this *QAccessibleObject) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleObject(h *C.QAccessibleObject) *QAccessibleObject {
if h == nil {
return nil
}
return &QAccessibleObject{h: h, QAccessibleInterface: newQAccessibleInterface_U(unsafe.Pointer(h))}
return &QAccessibleObject{h: h, QAccessibleInterface: UnsafeNewQAccessibleInterface(unsafe.Pointer(h))}
}
func newQAccessibleObject_U(h unsafe.Pointer) *QAccessibleObject {
func UnsafeNewQAccessibleObject(h unsafe.Pointer) *QAccessibleObject {
return newQAccessibleObject((*C.QAccessibleObject)(h))
}
@ -41,7 +49,7 @@ func (this *QAccessibleObject) IsValid() bool {
}
func (this *QAccessibleObject) Object() *QObject {
return newQObject_U(unsafe.Pointer(C.QAccessibleObject_Object(this.h)))
return UnsafeNewQObject(unsafe.Pointer(C.QAccessibleObject_Object(this.h)))
}
func (this *QAccessibleObject) Rect() *QRect {
@ -52,13 +60,13 @@ func (this *QAccessibleObject) Rect() *QRect {
}
func (this *QAccessibleObject) SetText(t QAccessible__Text, text string) {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
C.QAccessibleObject_SetText(this.h, (C.int)(t), (*C.struct_miqt_string)(text_ms))
}
func (this *QAccessibleObject) ChildAt(x int, y int) *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleObject_ChildAt(this.h, (C.int)(x), (C.int)(y))))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleObject_ChildAt(this.h, (C.int)(x), (C.int)(y))))
}
type QAccessibleApplication struct {
@ -73,14 +81,21 @@ func (this *QAccessibleApplication) cPointer() *C.QAccessibleApplication {
return this.h
}
func (this *QAccessibleApplication) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleApplication(h *C.QAccessibleApplication) *QAccessibleApplication {
if h == nil {
return nil
}
return &QAccessibleApplication{h: h, QAccessibleObject: newQAccessibleObject_U(unsafe.Pointer(h))}
return &QAccessibleApplication{h: h, QAccessibleObject: UnsafeNewQAccessibleObject(unsafe.Pointer(h))}
}
func newQAccessibleApplication_U(h unsafe.Pointer) *QAccessibleApplication {
func UnsafeNewQAccessibleApplication(h unsafe.Pointer) *QAccessibleApplication {
return newQAccessibleApplication((*C.QAccessibleApplication)(h))
}
@ -91,7 +106,7 @@ func NewQAccessibleApplication() *QAccessibleApplication {
}
func (this *QAccessibleApplication) Window() *QWindow {
return newQWindow_U(unsafe.Pointer(C.QAccessibleApplication_Window(this.h)))
return UnsafeNewQWindow(unsafe.Pointer(C.QAccessibleApplication_Window(this.h)))
}
func (this *QAccessibleApplication) ChildCount() int {
@ -103,15 +118,15 @@ func (this *QAccessibleApplication) IndexOfChild(param1 *QAccessibleInterface) i
}
func (this *QAccessibleApplication) FocusChild() *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleApplication_FocusChild(this.h)))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleApplication_FocusChild(this.h)))
}
func (this *QAccessibleApplication) Parent() *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleApplication_Parent(this.h)))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleApplication_Parent(this.h)))
}
func (this *QAccessibleApplication) Child(index int) *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleApplication_Child(this.h, (C.int)(index))))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleApplication_Child(this.h, (C.int)(index))))
}
func (this *QAccessibleApplication) Text(t QAccessible__Text) string {

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -5,7 +5,7 @@
#include <QString>
#include <QByteArray>
#include <cstring>
#include "qaccessibleplugin.h"
#include <qaccessibleplugin.h>
#include "gen_qaccessibleplugin.h"
#include "_cgo_export.h"

View File

@ -9,6 +9,7 @@ package qt
import "C"
import (
"github.com/mappu/miqt/libmiqt"
"runtime"
"unsafe"
)
@ -25,19 +26,26 @@ func (this *QAccessiblePlugin) cPointer() *C.QAccessiblePlugin {
return this.h
}
func (this *QAccessiblePlugin) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessiblePlugin(h *C.QAccessiblePlugin) *QAccessiblePlugin {
if h == nil {
return nil
}
return &QAccessiblePlugin{h: h, QObject: newQObject_U(unsafe.Pointer(h))}
return &QAccessiblePlugin{h: h, QObject: UnsafeNewQObject(unsafe.Pointer(h))}
}
func newQAccessiblePlugin_U(h unsafe.Pointer) *QAccessiblePlugin {
func UnsafeNewQAccessiblePlugin(h unsafe.Pointer) *QAccessiblePlugin {
return newQAccessiblePlugin((*C.QAccessiblePlugin)(h))
}
func (this *QAccessiblePlugin) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAccessiblePlugin_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAccessiblePlugin_MetaObject(this.h)))
}
func (this *QAccessiblePlugin) Metacast(param1 string) unsafe.Pointer {
@ -65,9 +73,9 @@ func QAccessiblePlugin_TrUtf8(s string) string {
}
func (this *QAccessiblePlugin) Create(key string, object *QObject) *QAccessibleInterface {
key_ms := miqt_strdupg(key)
key_ms := libmiqt.Strdupg(key)
defer C.free(key_ms)
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessiblePlugin_Create(this.h, (*C.struct_miqt_string)(key_ms), object.cPointer())))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessiblePlugin_Create(this.h, (*C.struct_miqt_string)(key_ms), object.cPointer())))
}
func QAccessiblePlugin_Tr2(s string, c string) string {

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -9,7 +9,7 @@
#include <cstring>
#include <QWidget>
#include <QWindow>
#include "qaccessiblewidget.h"
#include <qaccessiblewidget.h>
#include "gen_qaccessiblewidget.h"
#include "_cgo_export.h"

View File

@ -9,6 +9,7 @@ package qt
import "C"
import (
"github.com/mappu/miqt/libmiqt"
"unsafe"
)
@ -25,14 +26,21 @@ func (this *QAccessibleWidget) cPointer() *C.QAccessibleWidget {
return this.h
}
func (this *QAccessibleWidget) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAccessibleWidget(h *C.QAccessibleWidget) *QAccessibleWidget {
if h == nil {
return nil
}
return &QAccessibleWidget{h: h, QAccessibleObject: newQAccessibleObject_U(unsafe.Pointer(h)), QAccessibleActionInterface: newQAccessibleActionInterface_U(unsafe.Pointer(h))}
return &QAccessibleWidget{h: h, QAccessibleObject: UnsafeNewQAccessibleObject(unsafe.Pointer(h)), QAccessibleActionInterface: UnsafeNewQAccessibleActionInterface(unsafe.Pointer(h))}
}
func newQAccessibleWidget_U(h unsafe.Pointer) *QAccessibleWidget {
func UnsafeNewQAccessibleWidget(h unsafe.Pointer) *QAccessibleWidget {
return newQAccessibleWidget((*C.QAccessibleWidget)(h))
}
@ -50,7 +58,7 @@ func NewQAccessibleWidget2(o *QWidget, r QAccessible__Role) *QAccessibleWidget {
// NewQAccessibleWidget3 constructs a new QAccessibleWidget object.
func NewQAccessibleWidget3(o *QWidget, r QAccessible__Role, name string) *QAccessibleWidget {
name_ms := miqt_strdupg(name)
name_ms := libmiqt.Strdupg(name)
defer C.free(name_ms)
ret := C.QAccessibleWidget_new3(o.cPointer(), (C.int)(r), (*C.struct_miqt_string)(name_ms))
return newQAccessibleWidget(ret)
@ -61,7 +69,7 @@ func (this *QAccessibleWidget) IsValid() bool {
}
func (this *QAccessibleWidget) Window() *QWindow {
return newQWindow_U(unsafe.Pointer(C.QAccessibleWidget_Window(this.h)))
return UnsafeNewQWindow(unsafe.Pointer(C.QAccessibleWidget_Window(this.h)))
}
func (this *QAccessibleWidget) ChildCount() int {
@ -73,7 +81,7 @@ func (this *QAccessibleWidget) IndexOfChild(child *QAccessibleInterface) int {
}
func (this *QAccessibleWidget) FocusChild() *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleWidget_FocusChild(this.h)))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleWidget_FocusChild(this.h)))
}
func (this *QAccessibleWidget) Rect() *QRect {
@ -84,11 +92,11 @@ func (this *QAccessibleWidget) Rect() *QRect {
}
func (this *QAccessibleWidget) Parent() *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleWidget_Parent(this.h)))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleWidget_Parent(this.h)))
}
func (this *QAccessibleWidget) Child(index int) *QAccessibleInterface {
return newQAccessibleInterface_U(unsafe.Pointer(C.QAccessibleWidget_Child(this.h, (C.int)(index))))
return UnsafeNewQAccessibleInterface(unsafe.Pointer(C.QAccessibleWidget_Child(this.h, (C.int)(index))))
}
func (this *QAccessibleWidget) Text(t QAccessible__Text) string {
@ -142,13 +150,13 @@ func (this *QAccessibleWidget) ActionNames() []string {
}
func (this *QAccessibleWidget) DoAction(actionName string) {
actionName_ms := miqt_strdupg(actionName)
actionName_ms := libmiqt.Strdupg(actionName)
defer C.free(actionName_ms)
C.QAccessibleWidget_DoAction(this.h, (*C.struct_miqt_string)(actionName_ms))
}
func (this *QAccessibleWidget) KeyBindingsForAction(actionName string) []string {
actionName_ms := miqt_strdupg(actionName)
actionName_ms := libmiqt.Strdupg(actionName)
defer C.free(actionName_ms)
var _ma *C.struct_miqt_array = C.QAccessibleWidget_KeyBindingsForAction(this.h, (*C.struct_miqt_string)(actionName_ms))
_ret := make([]string, int(_ma.len))

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -13,7 +13,7 @@
#include <cstring>
#include <QVariant>
#include <QWidget>
#include "qaction.h"
#include <qaction.h>
#include "gen_qaction.h"
#include "_cgo_export.h"

View File

@ -9,6 +9,7 @@ package qt
import "C"
import (
"github.com/mappu/miqt/libmiqt"
"runtime"
"runtime/cgo"
"unsafe"
@ -53,14 +54,21 @@ func (this *QAction) cPointer() *C.QAction {
return this.h
}
func (this *QAction) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAction(h *C.QAction) *QAction {
if h == nil {
return nil
}
return &QAction{h: h, QObject: newQObject_U(unsafe.Pointer(h))}
return &QAction{h: h, QObject: UnsafeNewQObject(unsafe.Pointer(h))}
}
func newQAction_U(h unsafe.Pointer) *QAction {
func UnsafeNewQAction(h unsafe.Pointer) *QAction {
return newQAction((*C.QAction)(h))
}
@ -72,7 +80,7 @@ func NewQAction() *QAction {
// NewQAction2 constructs a new QAction object.
func NewQAction2(text string) *QAction {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
ret := C.QAction_new2((*C.struct_miqt_string)(text_ms))
return newQAction(ret)
@ -80,7 +88,7 @@ func NewQAction2(text string) *QAction {
// NewQAction3 constructs a new QAction object.
func NewQAction3(icon *QIcon, text string) *QAction {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
ret := C.QAction_new3(icon.cPointer(), (*C.struct_miqt_string)(text_ms))
return newQAction(ret)
@ -94,7 +102,7 @@ func NewQAction4(parent *QObject) *QAction {
// NewQAction5 constructs a new QAction object.
func NewQAction5(text string, parent *QObject) *QAction {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
ret := C.QAction_new5((*C.struct_miqt_string)(text_ms), parent.cPointer())
return newQAction(ret)
@ -102,14 +110,14 @@ func NewQAction5(text string, parent *QObject) *QAction {
// NewQAction6 constructs a new QAction object.
func NewQAction6(icon *QIcon, text string, parent *QObject) *QAction {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
ret := C.QAction_new6(icon.cPointer(), (*C.struct_miqt_string)(text_ms), parent.cPointer())
return newQAction(ret)
}
func (this *QAction) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAction_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAction_MetaObject(this.h)))
}
func (this *QAction) Metacast(param1 string) unsafe.Pointer {
@ -141,7 +149,7 @@ func (this *QAction) SetActionGroup(group *QActionGroup) {
}
func (this *QAction) ActionGroup() *QActionGroup {
return newQActionGroup_U(unsafe.Pointer(C.QAction_ActionGroup(this.h)))
return UnsafeNewQActionGroup(unsafe.Pointer(C.QAction_ActionGroup(this.h)))
}
func (this *QAction) SetIcon(icon *QIcon) {
@ -156,7 +164,7 @@ func (this *QAction) Icon() *QIcon {
}
func (this *QAction) SetText(text string) {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
C.QAction_SetText(this.h, (*C.struct_miqt_string)(text_ms))
}
@ -169,7 +177,7 @@ func (this *QAction) Text() string {
}
func (this *QAction) SetIconText(text string) {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
C.QAction_SetIconText(this.h, (*C.struct_miqt_string)(text_ms))
}
@ -182,7 +190,7 @@ func (this *QAction) IconText() string {
}
func (this *QAction) SetToolTip(tip string) {
tip_ms := miqt_strdupg(tip)
tip_ms := libmiqt.Strdupg(tip)
defer C.free(tip_ms)
C.QAction_SetToolTip(this.h, (*C.struct_miqt_string)(tip_ms))
}
@ -195,7 +203,7 @@ func (this *QAction) ToolTip() string {
}
func (this *QAction) SetStatusTip(statusTip string) {
statusTip_ms := miqt_strdupg(statusTip)
statusTip_ms := libmiqt.Strdupg(statusTip)
defer C.free(statusTip_ms)
C.QAction_SetStatusTip(this.h, (*C.struct_miqt_string)(statusTip_ms))
}
@ -208,7 +216,7 @@ func (this *QAction) StatusTip() string {
}
func (this *QAction) SetWhatsThis(what string) {
what_ms := miqt_strdupg(what)
what_ms := libmiqt.Strdupg(what)
defer C.free(what_ms)
C.QAction_SetWhatsThis(this.h, (*C.struct_miqt_string)(what_ms))
}
@ -229,7 +237,7 @@ func (this *QAction) Priority() QAction__Priority {
}
func (this *QAction) Menu() *QMenu {
return newQMenu_U(unsafe.Pointer(C.QAction_Menu(this.h)))
return UnsafeNewQMenu(unsafe.Pointer(C.QAction_Menu(this.h)))
}
func (this *QAction) SetMenu(menu *QMenu) {
@ -376,7 +384,7 @@ func (this *QAction) IsShortcutVisibleInContextMenu() bool {
}
func (this *QAction) ParentWidget() *QWidget {
return newQWidget_U(unsafe.Pointer(C.QAction_ParentWidget(this.h)))
return UnsafeNewQWidget(unsafe.Pointer(C.QAction_ParentWidget(this.h)))
}
func (this *QAction) AssociatedWidgets() []*QWidget {
@ -384,7 +392,7 @@ func (this *QAction) AssociatedWidgets() []*QWidget {
_ret := make([]*QWidget, int(_ma.len))
_outCast := (*[0xffff]*C.QWidget)(unsafe.Pointer(_ma.data)) // hey ya
for i := 0; i < int(_ma.len); i++ {
_ret[i] = newQWidget_U(unsafe.Pointer(_outCast[i]))
_ret[i] = UnsafeNewQWidget(unsafe.Pointer(_outCast[i]))
}
C.free(unsafe.Pointer(_ma))
return _ret
@ -395,7 +403,7 @@ func (this *QAction) AssociatedGraphicsWidgets() []*QGraphicsWidget {
_ret := make([]*QGraphicsWidget, int(_ma.len))
_outCast := (*[0xffff]*C.QGraphicsWidget)(unsafe.Pointer(_ma.data)) // hey ya
for i := 0; i < int(_ma.len); i++ {
_ret[i] = newQGraphicsWidget_U(unsafe.Pointer(_outCast[i]))
_ret[i] = UnsafeNewQGraphicsWidget(unsafe.Pointer(_outCast[i]))
}
C.free(unsafe.Pointer(_ma))
return _ret

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -7,7 +7,7 @@
#include <QString>
#include <QByteArray>
#include <cstring>
#include "qactiongroup.h"
#include <qactiongroup.h>
#include "gen_qactiongroup.h"
#include "_cgo_export.h"

View File

@ -9,6 +9,7 @@ package qt
import "C"
import (
"github.com/mappu/miqt/libmiqt"
"runtime"
"runtime/cgo"
"unsafe"
@ -34,14 +35,21 @@ func (this *QActionGroup) cPointer() *C.QActionGroup {
return this.h
}
func (this *QActionGroup) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQActionGroup(h *C.QActionGroup) *QActionGroup {
if h == nil {
return nil
}
return &QActionGroup{h: h, QObject: newQObject_U(unsafe.Pointer(h))}
return &QActionGroup{h: h, QObject: UnsafeNewQObject(unsafe.Pointer(h))}
}
func newQActionGroup_U(h unsafe.Pointer) *QActionGroup {
func UnsafeNewQActionGroup(h unsafe.Pointer) *QActionGroup {
return newQActionGroup((*C.QActionGroup)(h))
}
@ -52,7 +60,7 @@ func NewQActionGroup(parent *QObject) *QActionGroup {
}
func (this *QActionGroup) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QActionGroup_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QActionGroup_MetaObject(this.h)))
}
func (this *QActionGroup) Metacast(param1 string) unsafe.Pointer {
@ -80,19 +88,19 @@ func QActionGroup_TrUtf8(s string) string {
}
func (this *QActionGroup) AddAction(a *QAction) *QAction {
return newQAction_U(unsafe.Pointer(C.QActionGroup_AddAction(this.h, a.cPointer())))
return UnsafeNewQAction(unsafe.Pointer(C.QActionGroup_AddAction(this.h, a.cPointer())))
}
func (this *QActionGroup) AddActionWithText(text string) *QAction {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
return newQAction_U(unsafe.Pointer(C.QActionGroup_AddActionWithText(this.h, (*C.struct_miqt_string)(text_ms))))
return UnsafeNewQAction(unsafe.Pointer(C.QActionGroup_AddActionWithText(this.h, (*C.struct_miqt_string)(text_ms))))
}
func (this *QActionGroup) AddAction2(icon *QIcon, text string) *QAction {
text_ms := miqt_strdupg(text)
text_ms := libmiqt.Strdupg(text)
defer C.free(text_ms)
return newQAction_U(unsafe.Pointer(C.QActionGroup_AddAction2(this.h, icon.cPointer(), (*C.struct_miqt_string)(text_ms))))
return UnsafeNewQAction(unsafe.Pointer(C.QActionGroup_AddAction2(this.h, icon.cPointer(), (*C.struct_miqt_string)(text_ms))))
}
func (this *QActionGroup) RemoveAction(a *QAction) {
@ -104,14 +112,14 @@ func (this *QActionGroup) Actions() []*QAction {
_ret := make([]*QAction, int(_ma.len))
_outCast := (*[0xffff]*C.QAction)(unsafe.Pointer(_ma.data)) // hey ya
for i := 0; i < int(_ma.len); i++ {
_ret[i] = newQAction_U(unsafe.Pointer(_outCast[i]))
_ret[i] = UnsafeNewQAction(unsafe.Pointer(_outCast[i]))
}
C.free(unsafe.Pointer(_ma))
return _ret
}
func (this *QActionGroup) CheckedAction() *QAction {
return newQAction_U(unsafe.Pointer(C.QActionGroup_CheckedAction(this.h)))
return UnsafeNewQAction(unsafe.Pointer(C.QActionGroup_CheckedAction(this.h)))
}
func (this *QActionGroup) IsExclusive() bool {
@ -165,7 +173,7 @@ func miqt_exec_callback_QActionGroup_Triggered(cb C.intptr_t, param1 *C.QAction)
}
// Convert all CABI parameters to Go parameters
slotval1 := newQAction_U(unsafe.Pointer(param1))
slotval1 := UnsafeNewQAction(unsafe.Pointer(param1))
gofunc(slotval1)
}
@ -185,7 +193,7 @@ func miqt_exec_callback_QActionGroup_Hovered(cb C.intptr_t, param1 *C.QAction) {
}
// Convert all CABI parameters to Go parameters
slotval1 := newQAction_U(unsafe.Pointer(param1))
slotval1 := UnsafeNewQAction(unsafe.Pointer(param1))
gofunc(slotval1)
}

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -4,7 +4,7 @@
#include <QString>
#include <QByteArray>
#include <cstring>
#include "qanimationgroup.h"
#include <qanimationgroup.h>
#include "gen_qanimationgroup.h"
#include "_cgo_export.h"

View File

@ -25,19 +25,26 @@ func (this *QAnimationGroup) cPointer() *C.QAnimationGroup {
return this.h
}
func (this *QAnimationGroup) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQAnimationGroup(h *C.QAnimationGroup) *QAnimationGroup {
if h == nil {
return nil
}
return &QAnimationGroup{h: h, QAbstractAnimation: newQAbstractAnimation_U(unsafe.Pointer(h))}
return &QAnimationGroup{h: h, QAbstractAnimation: UnsafeNewQAbstractAnimation(unsafe.Pointer(h))}
}
func newQAnimationGroup_U(h unsafe.Pointer) *QAnimationGroup {
func UnsafeNewQAnimationGroup(h unsafe.Pointer) *QAnimationGroup {
return newQAnimationGroup((*C.QAnimationGroup)(h))
}
func (this *QAnimationGroup) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QAnimationGroup_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QAnimationGroup_MetaObject(this.h)))
}
func (this *QAnimationGroup) Metacast(param1 string) unsafe.Pointer {
@ -65,7 +72,7 @@ func QAnimationGroup_TrUtf8(s string) string {
}
func (this *QAnimationGroup) AnimationAt(index int) *QAbstractAnimation {
return newQAbstractAnimation_U(unsafe.Pointer(C.QAnimationGroup_AnimationAt(this.h, (C.int)(index))))
return UnsafeNewQAbstractAnimation(unsafe.Pointer(C.QAnimationGroup_AnimationAt(this.h, (C.int)(index))))
}
func (this *QAnimationGroup) AnimationCount() int {
@ -89,7 +96,7 @@ func (this *QAnimationGroup) RemoveAnimation(animation *QAbstractAnimation) {
}
func (this *QAnimationGroup) TakeAnimation(index int) *QAbstractAnimation {
return newQAbstractAnimation_U(unsafe.Pointer(C.QAnimationGroup_TakeAnimation(this.h, (C.int)(index))))
return UnsafeNewQAbstractAnimation(unsafe.Pointer(C.QAnimationGroup_TakeAnimation(this.h, (C.int)(index))))
}
func (this *QAnimationGroup) Clear() {

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -15,7 +15,7 @@
#include <cstring>
#include <QStyle>
#include <QWidget>
#include "qapplication.h"
#include <qapplication.h>
#include "gen_qapplication.h"
#include "_cgo_export.h"

View File

@ -9,6 +9,7 @@ package qt
import "C"
import (
"github.com/mappu/miqt/libmiqt"
"runtime"
"runtime/cgo"
"unsafe"
@ -34,14 +35,21 @@ func (this *QApplication) cPointer() *C.QApplication {
return this.h
}
func (this *QApplication) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQApplication(h *C.QApplication) *QApplication {
if h == nil {
return nil
}
return &QApplication{h: h, QGuiApplication: newQGuiApplication_U(unsafe.Pointer(h))}
return &QApplication{h: h, QGuiApplication: UnsafeNewQGuiApplication(unsafe.Pointer(h))}
}
func newQApplication_U(h unsafe.Pointer) *QApplication {
func UnsafeNewQApplication(h unsafe.Pointer) *QApplication {
return newQApplication((*C.QApplication)(h))
}
@ -72,7 +80,7 @@ func NewQApplication2(args []string, param3 int) *QApplication {
}
func (this *QApplication) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QApplication_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QApplication_MetaObject(this.h)))
}
func (this *QApplication) Metacast(param1 string) unsafe.Pointer {
@ -100,7 +108,7 @@ func QApplication_TrUtf8(s string) string {
}
func QApplication_Style() *QStyle {
return newQStyle_U(unsafe.Pointer(C.QApplication_Style()))
return UnsafeNewQStyle(unsafe.Pointer(C.QApplication_Style()))
}
func QApplication_SetStyle(style *QStyle) {
@ -108,9 +116,9 @@ func QApplication_SetStyle(style *QStyle) {
}
func QApplication_SetStyleWithStyle(style string) *QStyle {
style_ms := miqt_strdupg(style)
style_ms := libmiqt.Strdupg(style)
defer C.free(style_ms)
return newQStyle_U(unsafe.Pointer(C.QApplication_SetStyleWithStyle((*C.struct_miqt_string)(style_ms))))
return UnsafeNewQStyle(unsafe.Pointer(C.QApplication_SetStyleWithStyle((*C.struct_miqt_string)(style_ms))))
}
func QApplication_ColorSpec() int {
@ -191,7 +199,7 @@ func QApplication_AllWidgets() []*QWidget {
_ret := make([]*QWidget, int(_ma.len))
_outCast := (*[0xffff]*C.QWidget)(unsafe.Pointer(_ma.data)) // hey ya
for i := 0; i < int(_ma.len); i++ {
_ret[i] = newQWidget_U(unsafe.Pointer(_outCast[i]))
_ret[i] = UnsafeNewQWidget(unsafe.Pointer(_outCast[i]))
}
C.free(unsafe.Pointer(_ma))
return _ret
@ -202,30 +210,30 @@ func QApplication_TopLevelWidgets() []*QWidget {
_ret := make([]*QWidget, int(_ma.len))
_outCast := (*[0xffff]*C.QWidget)(unsafe.Pointer(_ma.data)) // hey ya
for i := 0; i < int(_ma.len); i++ {
_ret[i] = newQWidget_U(unsafe.Pointer(_outCast[i]))
_ret[i] = UnsafeNewQWidget(unsafe.Pointer(_outCast[i]))
}
C.free(unsafe.Pointer(_ma))
return _ret
}
func QApplication_Desktop() *QDesktopWidget {
return newQDesktopWidget_U(unsafe.Pointer(C.QApplication_Desktop()))
return UnsafeNewQDesktopWidget(unsafe.Pointer(C.QApplication_Desktop()))
}
func QApplication_ActivePopupWidget() *QWidget {
return newQWidget_U(unsafe.Pointer(C.QApplication_ActivePopupWidget()))
return UnsafeNewQWidget(unsafe.Pointer(C.QApplication_ActivePopupWidget()))
}
func QApplication_ActiveModalWidget() *QWidget {
return newQWidget_U(unsafe.Pointer(C.QApplication_ActiveModalWidget()))
return UnsafeNewQWidget(unsafe.Pointer(C.QApplication_ActiveModalWidget()))
}
func QApplication_FocusWidget() *QWidget {
return newQWidget_U(unsafe.Pointer(C.QApplication_FocusWidget()))
return UnsafeNewQWidget(unsafe.Pointer(C.QApplication_FocusWidget()))
}
func QApplication_ActiveWindow() *QWidget {
return newQWidget_U(unsafe.Pointer(C.QApplication_ActiveWindow()))
return UnsafeNewQWidget(unsafe.Pointer(C.QApplication_ActiveWindow()))
}
func QApplication_SetActiveWindow(act *QWidget) {
@ -233,19 +241,19 @@ func QApplication_SetActiveWindow(act *QWidget) {
}
func QApplication_WidgetAt(p *QPoint) *QWidget {
return newQWidget_U(unsafe.Pointer(C.QApplication_WidgetAt(p.cPointer())))
return UnsafeNewQWidget(unsafe.Pointer(C.QApplication_WidgetAt(p.cPointer())))
}
func QApplication_WidgetAt2(x int, y int) *QWidget {
return newQWidget_U(unsafe.Pointer(C.QApplication_WidgetAt2((C.int)(x), (C.int)(y))))
return UnsafeNewQWidget(unsafe.Pointer(C.QApplication_WidgetAt2((C.int)(x), (C.int)(y))))
}
func QApplication_TopLevelAt(p *QPoint) *QWidget {
return newQWidget_U(unsafe.Pointer(C.QApplication_TopLevelAt(p.cPointer())))
return UnsafeNewQWidget(unsafe.Pointer(C.QApplication_TopLevelAt(p.cPointer())))
}
func QApplication_TopLevelAt2(x int, y int) *QWidget {
return newQWidget_U(unsafe.Pointer(C.QApplication_TopLevelAt2((C.int)(x), (C.int)(y))))
return UnsafeNewQWidget(unsafe.Pointer(C.QApplication_TopLevelAt2((C.int)(x), (C.int)(y))))
}
func QApplication_Beep() {
@ -346,8 +354,8 @@ func miqt_exec_callback_QApplication_FocusChanged(cb C.intptr_t, old *C.QWidget,
}
// Convert all CABI parameters to Go parameters
slotval1 := newQWidget_U(unsafe.Pointer(old))
slotval2 := newQWidget_U(unsafe.Pointer(now))
slotval1 := UnsafeNewQWidget(unsafe.Pointer(old))
slotval2 := UnsafeNewQWidget(unsafe.Pointer(now))
gofunc(slotval1, slotval2)
}
@ -360,7 +368,7 @@ func (this *QApplication) StyleSheet() string {
}
func (this *QApplication) SetStyleSheet(sheet string) {
sheet_ms := miqt_strdupg(sheet)
sheet_ms := libmiqt.Strdupg(sheet)
defer C.free(sheet_ms)
C.QApplication_SetStyleSheet(this.h, (*C.struct_miqt_string)(sheet_ms))
}

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -1,6 +1,6 @@
#include <QArrayData>
#define WORKAROUND_INNER_CLASS_DEFINITION_QtPrivate__QContainerImplHelper
#include "qarraydata.h"
#include <qarraydata.h>
#include "gen_qarraydata.h"
#include "_cgo_export.h"

View File

@ -43,6 +43,13 @@ func (this *QArrayData) cPointer() *C.QArrayData {
return this.h
}
func (this *QArrayData) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQArrayData(h *C.QArrayData) *QArrayData {
if h == nil {
return nil
@ -50,7 +57,7 @@ func newQArrayData(h *C.QArrayData) *QArrayData {
return &QArrayData{h: h}
}
func newQArrayData_U(h unsafe.Pointer) *QArrayData {
func UnsafeNewQArrayData(h unsafe.Pointer) *QArrayData {
return newQArrayData((*C.QArrayData)(h))
}
@ -79,11 +86,11 @@ func (this *QArrayData) CloneFlags() QArrayData__AllocationOption {
}
func QArrayData_Allocate(objectSize uint64, alignment uint64, capacity uint64) *QArrayData {
return newQArrayData_U(unsafe.Pointer(C.QArrayData_Allocate((C.size_t)(objectSize), (C.size_t)(alignment), (C.size_t)(capacity))))
return UnsafeNewQArrayData(unsafe.Pointer(C.QArrayData_Allocate((C.size_t)(objectSize), (C.size_t)(alignment), (C.size_t)(capacity))))
}
func QArrayData_ReallocateUnaligned(data *QArrayData, objectSize uint64, newCapacity uint64) *QArrayData {
return newQArrayData_U(unsafe.Pointer(C.QArrayData_ReallocateUnaligned(data.cPointer(), (C.size_t)(objectSize), (C.size_t)(newCapacity))))
return UnsafeNewQArrayData(unsafe.Pointer(C.QArrayData_ReallocateUnaligned(data.cPointer(), (C.size_t)(objectSize), (C.size_t)(newCapacity))))
}
func QArrayData_Deallocate(data *QArrayData, objectSize uint64, alignment uint64) {
@ -91,15 +98,15 @@ func QArrayData_Deallocate(data *QArrayData, objectSize uint64, alignment uint64
}
func QArrayData_SharedNull() *QArrayData {
return newQArrayData_U(unsafe.Pointer(C.QArrayData_SharedNull()))
return UnsafeNewQArrayData(unsafe.Pointer(C.QArrayData_SharedNull()))
}
func QArrayData_Allocate4(objectSize uint64, alignment uint64, capacity uint64, options QArrayData__AllocationOption) *QArrayData {
return newQArrayData_U(unsafe.Pointer(C.QArrayData_Allocate4((C.size_t)(objectSize), (C.size_t)(alignment), (C.size_t)(capacity), (C.int)(options))))
return UnsafeNewQArrayData(unsafe.Pointer(C.QArrayData_Allocate4((C.size_t)(objectSize), (C.size_t)(alignment), (C.size_t)(capacity), (C.int)(options))))
}
func QArrayData_ReallocateUnaligned4(data *QArrayData, objectSize uint64, newCapacity uint64, newOptions QArrayData__AllocationOption) *QArrayData {
return newQArrayData_U(unsafe.Pointer(C.QArrayData_ReallocateUnaligned4(data.cPointer(), (C.size_t)(objectSize), (C.size_t)(newCapacity), (C.int)(newOptions))))
return UnsafeNewQArrayData(unsafe.Pointer(C.QArrayData_ReallocateUnaligned4(data.cPointer(), (C.size_t)(objectSize), (C.size_t)(newCapacity), (C.int)(newOptions))))
}
// Delete this object from C++ memory.
@ -127,6 +134,13 @@ func (this *QtPrivate__QContainerImplHelper) cPointer() *C.QtPrivate__QContainer
return this.h
}
func (this *QtPrivate__QContainerImplHelper) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQtPrivate__QContainerImplHelper(h *C.QtPrivate__QContainerImplHelper) *QtPrivate__QContainerImplHelper {
if h == nil {
return nil
@ -134,7 +148,7 @@ func newQtPrivate__QContainerImplHelper(h *C.QtPrivate__QContainerImplHelper) *Q
return &QtPrivate__QContainerImplHelper{h: h}
}
func newQtPrivate__QContainerImplHelper_U(h unsafe.Pointer) *QtPrivate__QContainerImplHelper {
func UnsafeNewQtPrivate__QContainerImplHelper(h unsafe.Pointer) *QtPrivate__QContainerImplHelper {
return newQtPrivate__QContainerImplHelper((*C.QtPrivate__QContainerImplHelper)(h))
}

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -4,7 +4,7 @@
#include <QRegion>
#include <QSize>
#include <QWindow>
#include "qbackingstore.h"
#include <qbackingstore.h>
#include "gen_qbackingstore.h"
#include "_cgo_export.h"

View File

@ -24,6 +24,13 @@ func (this *QBackingStore) cPointer() *C.QBackingStore {
return this.h
}
func (this *QBackingStore) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQBackingStore(h *C.QBackingStore) *QBackingStore {
if h == nil {
return nil
@ -31,7 +38,7 @@ func newQBackingStore(h *C.QBackingStore) *QBackingStore {
return &QBackingStore{h: h}
}
func newQBackingStore_U(h unsafe.Pointer) *QBackingStore {
func UnsafeNewQBackingStore(h unsafe.Pointer) *QBackingStore {
return newQBackingStore((*C.QBackingStore)(h))
}
@ -42,11 +49,11 @@ func NewQBackingStore(window *QWindow) *QBackingStore {
}
func (this *QBackingStore) Window() *QWindow {
return newQWindow_U(unsafe.Pointer(C.QBackingStore_Window(this.h)))
return UnsafeNewQWindow(unsafe.Pointer(C.QBackingStore_Window(this.h)))
}
func (this *QBackingStore) PaintDevice() *QPaintDevice {
return newQPaintDevice_U(unsafe.Pointer(C.QBackingStore_PaintDevice(this.h)))
return UnsafeNewQPaintDevice(unsafe.Pointer(C.QBackingStore_PaintDevice(this.h)))
}
func (this *QBackingStore) Flush(region *QRegion) {

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -1,6 +1,6 @@
#include <QBasicTimer>
#include <QObject>
#include "qbasictimer.h"
#include <qbasictimer.h>
#include "gen_qbasictimer.h"
#include "_cgo_export.h"

View File

@ -24,6 +24,13 @@ func (this *QBasicTimer) cPointer() *C.QBasicTimer {
return this.h
}
func (this *QBasicTimer) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQBasicTimer(h *C.QBasicTimer) *QBasicTimer {
if h == nil {
return nil
@ -31,7 +38,7 @@ func newQBasicTimer(h *C.QBasicTimer) *QBasicTimer {
return &QBasicTimer{h: h}
}
func newQBasicTimer_U(h unsafe.Pointer) *QBasicTimer {
func UnsafeNewQBasicTimer(h unsafe.Pointer) *QBasicTimer {
return newQBasicTimer((*C.QBasicTimer)(h))
}

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -1,6 +1,6 @@
#include <QBitArray>
#include <QBitRef>
#include "qbitarray.h"
#include <qbitarray.h>
#include "gen_qbitarray.h"
#include "_cgo_export.h"

View File

@ -24,6 +24,13 @@ func (this *QBitArray) cPointer() *C.QBitArray {
return this.h
}
func (this *QBitArray) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQBitArray(h *C.QBitArray) *QBitArray {
if h == nil {
return nil
@ -31,7 +38,7 @@ func newQBitArray(h *C.QBitArray) *QBitArray {
return &QBitArray{h: h}
}
func newQBitArray_U(h unsafe.Pointer) *QBitArray {
func UnsafeNewQBitArray(h unsafe.Pointer) *QBitArray {
return newQBitArray((*C.QBitArray)(h))
}
@ -231,6 +238,13 @@ func (this *QBitRef) cPointer() *C.QBitRef {
return this.h
}
func (this *QBitRef) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQBitRef(h *C.QBitRef) *QBitRef {
if h == nil {
return nil
@ -238,7 +252,7 @@ func newQBitRef(h *C.QBitRef) *QBitRef {
return &QBitRef{h: h}
}
func newQBitRef_U(h unsafe.Pointer) *QBitRef {
func UnsafeNewQBitRef(h unsafe.Pointer) *QBitRef {
return newQBitRef((*C.QBitRef)(h))
}

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -7,7 +7,7 @@
#include <QByteArray>
#include <cstring>
#include <QTransform>
#include "qbitmap.h"
#include <qbitmap.h>
#include "gen_qbitmap.h"
#include "_cgo_export.h"

View File

@ -9,6 +9,7 @@ package qt
import "C"
import (
"github.com/mappu/miqt/libmiqt"
"runtime"
"unsafe"
)
@ -25,14 +26,21 @@ func (this *QBitmap) cPointer() *C.QBitmap {
return this.h
}
func (this *QBitmap) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQBitmap(h *C.QBitmap) *QBitmap {
if h == nil {
return nil
}
return &QBitmap{h: h, QPixmap: newQPixmap_U(unsafe.Pointer(h))}
return &QBitmap{h: h, QPixmap: UnsafeNewQPixmap(unsafe.Pointer(h))}
}
func newQBitmap_U(h unsafe.Pointer) *QBitmap {
func UnsafeNewQBitmap(h unsafe.Pointer) *QBitmap {
return newQBitmap((*C.QBitmap)(h))
}
@ -62,7 +70,7 @@ func NewQBitmap4(param1 *QSize) *QBitmap {
// NewQBitmap5 constructs a new QBitmap object.
func NewQBitmap5(fileName string) *QBitmap {
fileName_ms := miqt_strdupg(fileName)
fileName_ms := libmiqt.Strdupg(fileName)
defer C.free(fileName_ms)
ret := C.QBitmap_new5((*C.struct_miqt_string)(fileName_ms))
return newQBitmap(ret)
@ -76,7 +84,7 @@ func NewQBitmap6(other *QBitmap) *QBitmap {
// NewQBitmap7 constructs a new QBitmap object.
func NewQBitmap7(fileName string, format string) *QBitmap {
fileName_ms := miqt_strdupg(fileName)
fileName_ms := libmiqt.Strdupg(fileName)
defer C.free(fileName_ms)
format_Cstring := C.CString(format)
defer C.free(unsafe.Pointer(format_Cstring))

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -11,7 +11,7 @@
#include <cstring>
#include <QVBoxLayout>
#include <QWidget>
#include "qboxlayout.h"
#include <qboxlayout.h>
#include "gen_qboxlayout.h"
#include "_cgo_export.h"

View File

@ -36,14 +36,21 @@ func (this *QBoxLayout) cPointer() *C.QBoxLayout {
return this.h
}
func (this *QBoxLayout) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQBoxLayout(h *C.QBoxLayout) *QBoxLayout {
if h == nil {
return nil
}
return &QBoxLayout{h: h, QLayout: newQLayout_U(unsafe.Pointer(h))}
return &QBoxLayout{h: h, QLayout: UnsafeNewQLayout(unsafe.Pointer(h))}
}
func newQBoxLayout_U(h unsafe.Pointer) *QBoxLayout {
func UnsafeNewQBoxLayout(h unsafe.Pointer) *QBoxLayout {
return newQBoxLayout((*C.QBoxLayout)(h))
}
@ -60,7 +67,7 @@ func NewQBoxLayout2(param1 QBoxLayout__Direction, parent *QWidget) *QBoxLayout {
}
func (this *QBoxLayout) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QBoxLayout_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QBoxLayout_MetaObject(this.h)))
}
func (this *QBoxLayout) Metacast(param1 string) unsafe.Pointer {
@ -213,11 +220,11 @@ func (this *QBoxLayout) Invalidate() {
}
func (this *QBoxLayout) ItemAt(param1 int) *QLayoutItem {
return newQLayoutItem_U(unsafe.Pointer(C.QBoxLayout_ItemAt(this.h, (C.int)(param1))))
return UnsafeNewQLayoutItem(unsafe.Pointer(C.QBoxLayout_ItemAt(this.h, (C.int)(param1))))
}
func (this *QBoxLayout) TakeAt(param1 int) *QLayoutItem {
return newQLayoutItem_U(unsafe.Pointer(C.QBoxLayout_TakeAt(this.h, (C.int)(param1))))
return UnsafeNewQLayoutItem(unsafe.Pointer(C.QBoxLayout_TakeAt(this.h, (C.int)(param1))))
}
func (this *QBoxLayout) Count() int {
@ -330,14 +337,21 @@ func (this *QHBoxLayout) cPointer() *C.QHBoxLayout {
return this.h
}
func (this *QHBoxLayout) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQHBoxLayout(h *C.QHBoxLayout) *QHBoxLayout {
if h == nil {
return nil
}
return &QHBoxLayout{h: h, QBoxLayout: newQBoxLayout_U(unsafe.Pointer(h))}
return &QHBoxLayout{h: h, QBoxLayout: UnsafeNewQBoxLayout(unsafe.Pointer(h))}
}
func newQHBoxLayout_U(h unsafe.Pointer) *QHBoxLayout {
func UnsafeNewQHBoxLayout(h unsafe.Pointer) *QHBoxLayout {
return newQHBoxLayout((*C.QHBoxLayout)(h))
}
@ -354,7 +368,7 @@ func NewQHBoxLayout2(parent *QWidget) *QHBoxLayout {
}
func (this *QHBoxLayout) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QHBoxLayout_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QHBoxLayout_MetaObject(this.h)))
}
func (this *QHBoxLayout) Metacast(param1 string) unsafe.Pointer {
@ -451,14 +465,21 @@ func (this *QVBoxLayout) cPointer() *C.QVBoxLayout {
return this.h
}
func (this *QVBoxLayout) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQVBoxLayout(h *C.QVBoxLayout) *QVBoxLayout {
if h == nil {
return nil
}
return &QVBoxLayout{h: h, QBoxLayout: newQBoxLayout_U(unsafe.Pointer(h))}
return &QVBoxLayout{h: h, QBoxLayout: UnsafeNewQBoxLayout(unsafe.Pointer(h))}
}
func newQVBoxLayout_U(h unsafe.Pointer) *QVBoxLayout {
func UnsafeNewQVBoxLayout(h unsafe.Pointer) *QVBoxLayout {
return newQVBoxLayout((*C.QVBoxLayout)(h))
}
@ -475,7 +496,7 @@ func NewQVBoxLayout2(parent *QWidget) *QVBoxLayout {
}
func (this *QVBoxLayout) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QVBoxLayout_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QVBoxLayout_MetaObject(this.h)))
}
func (this *QVBoxLayout) Metacast(param1 string) unsafe.Pointer {

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -11,7 +11,7 @@
#include <QPointF>
#include <QRadialGradient>
#include <QTransform>
#include "qbrush.h"
#include <qbrush.h>
#include "gen_qbrush.h"
#include "_cgo_export.h"

View File

@ -231,6 +231,13 @@ func (this *QBrush) cPointer() *C.QBrush {
return this.h
}
func (this *QBrush) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQBrush(h *C.QBrush) *QBrush {
if h == nil {
return nil
@ -238,7 +245,7 @@ func newQBrush(h *C.QBrush) *QBrush {
return &QBrush{h: h}
}
func newQBrush_U(h unsafe.Pointer) *QBrush {
func UnsafeNewQBrush(h unsafe.Pointer) *QBrush {
return newQBrush((*C.QBrush)(h))
}
@ -331,7 +338,7 @@ func (this *QBrush) SetStyle(style BrushStyle) {
}
func (this *QBrush) Matrix() *QMatrix {
return newQMatrix_U(unsafe.Pointer(C.QBrush_Matrix(this.h)))
return UnsafeNewQMatrix(unsafe.Pointer(C.QBrush_Matrix(this.h)))
}
func (this *QBrush) SetMatrix(mat *QMatrix) {
@ -372,7 +379,7 @@ func (this *QBrush) SetTextureImage(image *QImage) {
}
func (this *QBrush) Color() *QColor {
return newQColor_U(unsafe.Pointer(C.QBrush_Color(this.h)))
return UnsafeNewQColor(unsafe.Pointer(C.QBrush_Color(this.h)))
}
func (this *QBrush) SetColor(color *QColor) {
@ -384,7 +391,7 @@ func (this *QBrush) SetColorWithColor(color GlobalColor) {
}
func (this *QBrush) Gradient() *QGradient {
return newQGradient_U(unsafe.Pointer(C.QBrush_Gradient(this.h)))
return UnsafeNewQGradient(unsafe.Pointer(C.QBrush_Gradient(this.h)))
}
func (this *QBrush) IsOpaque() bool {
@ -428,6 +435,13 @@ func (this *QBrushData) cPointer() *C.QBrushData {
return this.h
}
func (this *QBrushData) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQBrushData(h *C.QBrushData) *QBrushData {
if h == nil {
return nil
@ -435,7 +449,7 @@ func newQBrushData(h *C.QBrushData) *QBrushData {
return &QBrushData{h: h}
}
func newQBrushData_U(h unsafe.Pointer) *QBrushData {
func UnsafeNewQBrushData(h unsafe.Pointer) *QBrushData {
return newQBrushData((*C.QBrushData)(h))
}
@ -474,6 +488,13 @@ func (this *QGradient) cPointer() *C.QGradient {
return this.h
}
func (this *QGradient) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQGradient(h *C.QGradient) *QGradient {
if h == nil {
return nil
@ -481,7 +502,7 @@ func newQGradient(h *C.QGradient) *QGradient {
return &QGradient{h: h}
}
func newQGradient_U(h unsafe.Pointer) *QGradient {
func UnsafeNewQGradient(h unsafe.Pointer) *QGradient {
return newQGradient((*C.QGradient)(h))
}
@ -569,14 +590,21 @@ func (this *QLinearGradient) cPointer() *C.QLinearGradient {
return this.h
}
func (this *QLinearGradient) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQLinearGradient(h *C.QLinearGradient) *QLinearGradient {
if h == nil {
return nil
}
return &QLinearGradient{h: h, QGradient: newQGradient_U(unsafe.Pointer(h))}
return &QLinearGradient{h: h, QGradient: UnsafeNewQGradient(unsafe.Pointer(h))}
}
func newQLinearGradient_U(h unsafe.Pointer) *QLinearGradient {
func UnsafeNewQLinearGradient(h unsafe.Pointer) *QLinearGradient {
return newQLinearGradient((*C.QLinearGradient)(h))
}
@ -660,14 +688,21 @@ func (this *QRadialGradient) cPointer() *C.QRadialGradient {
return this.h
}
func (this *QRadialGradient) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQRadialGradient(h *C.QRadialGradient) *QRadialGradient {
if h == nil {
return nil
}
return &QRadialGradient{h: h, QGradient: newQGradient_U(unsafe.Pointer(h))}
return &QRadialGradient{h: h, QGradient: UnsafeNewQGradient(unsafe.Pointer(h))}
}
func newQRadialGradient_U(h unsafe.Pointer) *QRadialGradient {
func UnsafeNewQRadialGradient(h unsafe.Pointer) *QRadialGradient {
return newQRadialGradient((*C.QRadialGradient)(h))
}
@ -799,14 +834,21 @@ func (this *QConicalGradient) cPointer() *C.QConicalGradient {
return this.h
}
func (this *QConicalGradient) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQConicalGradient(h *C.QConicalGradient) *QConicalGradient {
if h == nil {
return nil
}
return &QConicalGradient{h: h, QGradient: newQGradient_U(unsafe.Pointer(h))}
return &QConicalGradient{h: h, QGradient: UnsafeNewQGradient(unsafe.Pointer(h))}
}
func newQConicalGradient_U(h unsafe.Pointer) *QConicalGradient {
func UnsafeNewQConicalGradient(h unsafe.Pointer) *QConicalGradient {
return newQConicalGradient((*C.QConicalGradient)(h))
}
@ -882,6 +924,13 @@ func (this *QGradient__QGradientData) cPointer() *C.QGradient__QGradientData {
return this.h
}
func (this *QGradient__QGradientData) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQGradient__QGradientData(h *C.QGradient__QGradientData) *QGradient__QGradientData {
if h == nil {
return nil
@ -889,7 +938,7 @@ func newQGradient__QGradientData(h *C.QGradient__QGradientData) *QGradient__QGra
return &QGradient__QGradientData{h: h}
}
func newQGradient__QGradientData_U(h unsafe.Pointer) *QGradient__QGradientData {
func UnsafeNewQGradient__QGradientData(h unsafe.Pointer) *QGradient__QGradientData {
return newQGradient__QGradientData((*C.QGradient__QGradientData)(h))
}

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -5,7 +5,7 @@
#include <QString>
#include <QByteArray>
#include <cstring>
#include "qbuffer.h"
#include <qbuffer.h>
#include "gen_qbuffer.h"
#include "_cgo_export.h"

View File

@ -25,14 +25,21 @@ func (this *QBuffer) cPointer() *C.QBuffer {
return this.h
}
func (this *QBuffer) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQBuffer(h *C.QBuffer) *QBuffer {
if h == nil {
return nil
}
return &QBuffer{h: h, QIODevice: newQIODevice_U(unsafe.Pointer(h))}
return &QBuffer{h: h, QIODevice: UnsafeNewQIODevice(unsafe.Pointer(h))}
}
func newQBuffer_U(h unsafe.Pointer) *QBuffer {
func UnsafeNewQBuffer(h unsafe.Pointer) *QBuffer {
return newQBuffer((*C.QBuffer)(h))
}
@ -61,7 +68,7 @@ func NewQBuffer4(buf *QByteArray, parent *QObject) *QBuffer {
}
func (this *QBuffer) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QBuffer_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QBuffer_MetaObject(this.h)))
}
func (this *QBuffer) Metacast(param1 string) unsafe.Pointer {
@ -89,11 +96,11 @@ func QBuffer_TrUtf8(s string) string {
}
func (this *QBuffer) Buffer() *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QBuffer_Buffer(this.h)))
return UnsafeNewQByteArray(unsafe.Pointer(C.QBuffer_Buffer(this.h)))
}
func (this *QBuffer) Buffer2() *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QBuffer_Buffer2(this.h)))
return UnsafeNewQByteArray(unsafe.Pointer(C.QBuffer_Buffer2(this.h)))
}
func (this *QBuffer) SetBuffer(a *QByteArray) {
@ -111,7 +118,7 @@ func (this *QBuffer) SetData2(data string, lenVal int) {
}
func (this *QBuffer) Data() *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QBuffer_Data(this.h)))
return UnsafeNewQByteArray(unsafe.Pointer(C.QBuffer_Data(this.h)))
}
func (this *QBuffer) Open(openMode QIODevice__OpenModeFlag) bool {

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -6,7 +6,7 @@
#include <QString>
#include <QByteArray>
#include <cstring>
#include "qbuttongroup.h"
#include <qbuttongroup.h>
#include "gen_qbuttongroup.h"
#include "_cgo_export.h"

View File

@ -26,14 +26,21 @@ func (this *QButtonGroup) cPointer() *C.QButtonGroup {
return this.h
}
func (this *QButtonGroup) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQButtonGroup(h *C.QButtonGroup) *QButtonGroup {
if h == nil {
return nil
}
return &QButtonGroup{h: h, QObject: newQObject_U(unsafe.Pointer(h))}
return &QButtonGroup{h: h, QObject: UnsafeNewQObject(unsafe.Pointer(h))}
}
func newQButtonGroup_U(h unsafe.Pointer) *QButtonGroup {
func UnsafeNewQButtonGroup(h unsafe.Pointer) *QButtonGroup {
return newQButtonGroup((*C.QButtonGroup)(h))
}
@ -50,7 +57,7 @@ func NewQButtonGroup2(parent *QObject) *QButtonGroup {
}
func (this *QButtonGroup) MetaObject() *QMetaObject {
return newQMetaObject_U(unsafe.Pointer(C.QButtonGroup_MetaObject(this.h)))
return UnsafeNewQMetaObject(unsafe.Pointer(C.QButtonGroup_MetaObject(this.h)))
}
func (this *QButtonGroup) Metacast(param1 string) unsafe.Pointer {
@ -98,18 +105,18 @@ func (this *QButtonGroup) Buttons() []*QAbstractButton {
_ret := make([]*QAbstractButton, int(_ma.len))
_outCast := (*[0xffff]*C.QAbstractButton)(unsafe.Pointer(_ma.data)) // hey ya
for i := 0; i < int(_ma.len); i++ {
_ret[i] = newQAbstractButton_U(unsafe.Pointer(_outCast[i]))
_ret[i] = UnsafeNewQAbstractButton(unsafe.Pointer(_outCast[i]))
}
C.free(unsafe.Pointer(_ma))
return _ret
}
func (this *QButtonGroup) CheckedButton() *QAbstractButton {
return newQAbstractButton_U(unsafe.Pointer(C.QButtonGroup_CheckedButton(this.h)))
return UnsafeNewQAbstractButton(unsafe.Pointer(C.QButtonGroup_CheckedButton(this.h)))
}
func (this *QButtonGroup) Button(id int) *QAbstractButton {
return newQAbstractButton_U(unsafe.Pointer(C.QButtonGroup_Button(this.h, (C.int)(id))))
return UnsafeNewQAbstractButton(unsafe.Pointer(C.QButtonGroup_Button(this.h, (C.int)(id))))
}
func (this *QButtonGroup) SetId(button *QAbstractButton, id int) {
@ -139,7 +146,7 @@ func miqt_exec_callback_QButtonGroup_ButtonClicked(cb C.intptr_t, param1 *C.QAbs
}
// Convert all CABI parameters to Go parameters
slotval1 := newQAbstractButton_U(unsafe.Pointer(param1))
slotval1 := UnsafeNewQAbstractButton(unsafe.Pointer(param1))
gofunc(slotval1)
}
@ -159,7 +166,7 @@ func miqt_exec_callback_QButtonGroup_ButtonPressed(cb C.intptr_t, param1 *C.QAbs
}
// Convert all CABI parameters to Go parameters
slotval1 := newQAbstractButton_U(unsafe.Pointer(param1))
slotval1 := UnsafeNewQAbstractButton(unsafe.Pointer(param1))
gofunc(slotval1)
}
@ -179,7 +186,7 @@ func miqt_exec_callback_QButtonGroup_ButtonReleased(cb C.intptr_t, param1 *C.QAb
}
// Convert all CABI parameters to Go parameters
slotval1 := newQAbstractButton_U(unsafe.Pointer(param1))
slotval1 := UnsafeNewQAbstractButton(unsafe.Pointer(param1))
gofunc(slotval1)
}
@ -199,7 +206,7 @@ func miqt_exec_callback_QButtonGroup_ButtonToggled(cb C.intptr_t, param1 *C.QAbs
}
// Convert all CABI parameters to Go parameters
slotval1 := newQAbstractButton_U(unsafe.Pointer(param1))
slotval1 := UnsafeNewQAbstractButton(unsafe.Pointer(param1))
slotval2 := (bool)(param2)
gofunc(slotval1, slotval2)

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -6,7 +6,7 @@
#include <QString>
#include <QByteArray>
#include <cstring>
#include "qbytearray.h"
#include <qbytearray.h>
#include "gen_qbytearray.h"
#include "_cgo_export.h"

View File

@ -9,6 +9,7 @@ package qt
import "C"
import (
"github.com/mappu/miqt/libmiqt"
"runtime"
"unsafe"
)
@ -58,6 +59,13 @@ func (this *QByteArrayDataPtr) cPointer() *C.QByteArrayDataPtr {
return this.h
}
func (this *QByteArrayDataPtr) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQByteArrayDataPtr(h *C.QByteArrayDataPtr) *QByteArrayDataPtr {
if h == nil {
return nil
@ -65,7 +73,7 @@ func newQByteArrayDataPtr(h *C.QByteArrayDataPtr) *QByteArrayDataPtr {
return &QByteArrayDataPtr{h: h}
}
func newQByteArrayDataPtr_U(h unsafe.Pointer) *QByteArrayDataPtr {
func UnsafeNewQByteArrayDataPtr(h unsafe.Pointer) *QByteArrayDataPtr {
return newQByteArrayDataPtr((*C.QByteArrayDataPtr)(h))
}
@ -106,6 +114,13 @@ func (this *QByteArray) cPointer() *C.QByteArray {
return this.h
}
func (this *QByteArray) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQByteArray(h *C.QByteArray) *QByteArray {
if h == nil {
return nil
@ -113,7 +128,7 @@ func newQByteArray(h *C.QByteArray) *QByteArray {
return &QByteArray{h: h}
}
func newQByteArray_U(h unsafe.Pointer) *QByteArray {
func UnsafeNewQByteArray(h unsafe.Pointer) *QByteArray {
return newQByteArray((*C.QByteArray)(h))
}
@ -190,7 +205,7 @@ func (this *QByteArray) Resize(size int) {
}
func (this *QByteArray) Fill(c int8) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Fill(this.h, (C.char)(c))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Fill(this.h, (C.char)(c))))
}
func (this *QByteArray) Capacity() int {
@ -465,105 +480,105 @@ func (this *QByteArray) RightJustified(width int) *QByteArray {
}
func (this *QByteArray) Prepend(c int8) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Prepend(this.h, (C.char)(c))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Prepend(this.h, (C.char)(c))))
}
func (this *QByteArray) Prepend2(count int, c int8) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Prepend2(this.h, (C.int)(count), (C.char)(c))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Prepend2(this.h, (C.int)(count), (C.char)(c))))
}
func (this *QByteArray) PrependWithChar(s string) *QByteArray {
s_Cstring := C.CString(s)
defer C.free(unsafe.Pointer(s_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_PrependWithChar(this.h, s_Cstring)))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_PrependWithChar(this.h, s_Cstring)))
}
func (this *QByteArray) Prepend3(s string, lenVal int) *QByteArray {
s_Cstring := C.CString(s)
defer C.free(unsafe.Pointer(s_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Prepend3(this.h, s_Cstring, (C.int)(lenVal))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Prepend3(this.h, s_Cstring, (C.int)(lenVal))))
}
func (this *QByteArray) PrependWithQByteArray(a *QByteArray) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_PrependWithQByteArray(this.h, a.cPointer())))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_PrependWithQByteArray(this.h, a.cPointer())))
}
func (this *QByteArray) Append(c int8) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Append(this.h, (C.char)(c))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Append(this.h, (C.char)(c))))
}
func (this *QByteArray) Append2(count int, c int8) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Append2(this.h, (C.int)(count), (C.char)(c))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Append2(this.h, (C.int)(count), (C.char)(c))))
}
func (this *QByteArray) AppendWithChar(s string) *QByteArray {
s_Cstring := C.CString(s)
defer C.free(unsafe.Pointer(s_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_AppendWithChar(this.h, s_Cstring)))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_AppendWithChar(this.h, s_Cstring)))
}
func (this *QByteArray) Append3(s string, lenVal int) *QByteArray {
s_Cstring := C.CString(s)
defer C.free(unsafe.Pointer(s_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Append3(this.h, s_Cstring, (C.int)(lenVal))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Append3(this.h, s_Cstring, (C.int)(lenVal))))
}
func (this *QByteArray) AppendWithQByteArray(a *QByteArray) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_AppendWithQByteArray(this.h, a.cPointer())))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_AppendWithQByteArray(this.h, a.cPointer())))
}
func (this *QByteArray) Insert(i int, c int8) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Insert(this.h, (C.int)(i), (C.char)(c))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Insert(this.h, (C.int)(i), (C.char)(c))))
}
func (this *QByteArray) Insert2(i int, count int, c int8) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Insert2(this.h, (C.int)(i), (C.int)(count), (C.char)(c))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Insert2(this.h, (C.int)(i), (C.int)(count), (C.char)(c))))
}
func (this *QByteArray) Insert3(i int, s string) *QByteArray {
s_Cstring := C.CString(s)
defer C.free(unsafe.Pointer(s_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Insert3(this.h, (C.int)(i), s_Cstring)))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Insert3(this.h, (C.int)(i), s_Cstring)))
}
func (this *QByteArray) Insert4(i int, s string, lenVal int) *QByteArray {
s_Cstring := C.CString(s)
defer C.free(unsafe.Pointer(s_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Insert4(this.h, (C.int)(i), s_Cstring, (C.int)(lenVal))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Insert4(this.h, (C.int)(i), s_Cstring, (C.int)(lenVal))))
}
func (this *QByteArray) Insert5(i int, a *QByteArray) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Insert5(this.h, (C.int)(i), a.cPointer())))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Insert5(this.h, (C.int)(i), a.cPointer())))
}
func (this *QByteArray) Remove(index int, lenVal int) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Remove(this.h, (C.int)(index), (C.int)(lenVal))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Remove(this.h, (C.int)(index), (C.int)(lenVal))))
}
func (this *QByteArray) Replace(index int, lenVal int, s string) *QByteArray {
s_Cstring := C.CString(s)
defer C.free(unsafe.Pointer(s_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Replace(this.h, (C.int)(index), (C.int)(lenVal), s_Cstring)))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Replace(this.h, (C.int)(index), (C.int)(lenVal), s_Cstring)))
}
func (this *QByteArray) Replace2(index int, lenVal int, s string, alen int) *QByteArray {
s_Cstring := C.CString(s)
defer C.free(unsafe.Pointer(s_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Replace2(this.h, (C.int)(index), (C.int)(lenVal), s_Cstring, (C.int)(alen))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Replace2(this.h, (C.int)(index), (C.int)(lenVal), s_Cstring, (C.int)(alen))))
}
func (this *QByteArray) Replace3(index int, lenVal int, s *QByteArray) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Replace3(this.h, (C.int)(index), (C.int)(lenVal), s.cPointer())))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Replace3(this.h, (C.int)(index), (C.int)(lenVal), s.cPointer())))
}
func (this *QByteArray) Replace4(before int8, after string) *QByteArray {
after_Cstring := C.CString(after)
defer C.free(unsafe.Pointer(after_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Replace4(this.h, (C.char)(before), after_Cstring)))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Replace4(this.h, (C.char)(before), after_Cstring)))
}
func (this *QByteArray) Replace5(before int8, after *QByteArray) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Replace5(this.h, (C.char)(before), after.cPointer())))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Replace5(this.h, (C.char)(before), after.cPointer())))
}
func (this *QByteArray) Replace6(before string, after string) *QByteArray {
@ -571,7 +586,7 @@ func (this *QByteArray) Replace6(before string, after string) *QByteArray {
defer C.free(unsafe.Pointer(before_Cstring))
after_Cstring := C.CString(after)
defer C.free(unsafe.Pointer(after_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Replace6(this.h, before_Cstring, after_Cstring)))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Replace6(this.h, before_Cstring, after_Cstring)))
}
func (this *QByteArray) Replace7(before string, bsize int, after string, asize int) *QByteArray {
@ -579,41 +594,41 @@ func (this *QByteArray) Replace7(before string, bsize int, after string, asize i
defer C.free(unsafe.Pointer(before_Cstring))
after_Cstring := C.CString(after)
defer C.free(unsafe.Pointer(after_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Replace7(this.h, before_Cstring, (C.int)(bsize), after_Cstring, (C.int)(asize))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Replace7(this.h, before_Cstring, (C.int)(bsize), after_Cstring, (C.int)(asize))))
}
func (this *QByteArray) Replace8(before *QByteArray, after *QByteArray) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Replace8(this.h, before.cPointer(), after.cPointer())))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Replace8(this.h, before.cPointer(), after.cPointer())))
}
func (this *QByteArray) Replace9(before *QByteArray, after string) *QByteArray {
after_Cstring := C.CString(after)
defer C.free(unsafe.Pointer(after_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Replace9(this.h, before.cPointer(), after_Cstring)))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Replace9(this.h, before.cPointer(), after_Cstring)))
}
func (this *QByteArray) Replace10(before string, after *QByteArray) *QByteArray {
before_Cstring := C.CString(before)
defer C.free(unsafe.Pointer(before_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Replace10(this.h, before_Cstring, after.cPointer())))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Replace10(this.h, before_Cstring, after.cPointer())))
}
func (this *QByteArray) Replace11(before int8, after int8) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Replace11(this.h, (C.char)(before), (C.char)(after))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Replace11(this.h, (C.char)(before), (C.char)(after))))
}
func (this *QByteArray) OperatorPlusAssign(c int8) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_OperatorPlusAssign(this.h, (C.char)(c))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_OperatorPlusAssign(this.h, (C.char)(c))))
}
func (this *QByteArray) OperatorPlusAssignWithChar(s string) *QByteArray {
s_Cstring := C.CString(s)
defer C.free(unsafe.Pointer(s_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_OperatorPlusAssignWithChar(this.h, s_Cstring)))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_OperatorPlusAssignWithChar(this.h, s_Cstring)))
}
func (this *QByteArray) OperatorPlusAssignWithQByteArray(a *QByteArray) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_OperatorPlusAssignWithQByteArray(this.h, a.cPointer())))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_OperatorPlusAssignWithQByteArray(this.h, a.cPointer())))
}
func (this *QByteArray) Split(sep int8) []QByteArray {
@ -638,87 +653,87 @@ func (this *QByteArray) Repeated(times int) *QByteArray {
}
func (this *QByteArray) AppendWithQString(s string) *QByteArray {
s_ms := miqt_strdupg(s)
s_ms := libmiqt.Strdupg(s)
defer C.free(s_ms)
return newQByteArray_U(unsafe.Pointer(C.QByteArray_AppendWithQString(this.h, (*C.struct_miqt_string)(s_ms))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_AppendWithQString(this.h, (*C.struct_miqt_string)(s_ms))))
}
func (this *QByteArray) Insert6(i int, s string) *QByteArray {
s_ms := miqt_strdupg(s)
s_ms := libmiqt.Strdupg(s)
defer C.free(s_ms)
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Insert6(this.h, (C.int)(i), (*C.struct_miqt_string)(s_ms))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Insert6(this.h, (C.int)(i), (*C.struct_miqt_string)(s_ms))))
}
func (this *QByteArray) Replace12(before string, after string) *QByteArray {
before_ms := miqt_strdupg(before)
before_ms := libmiqt.Strdupg(before)
defer C.free(before_ms)
after_Cstring := C.CString(after)
defer C.free(unsafe.Pointer(after_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Replace12(this.h, (*C.struct_miqt_string)(before_ms), after_Cstring)))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Replace12(this.h, (*C.struct_miqt_string)(before_ms), after_Cstring)))
}
func (this *QByteArray) Replace13(c int8, after string) *QByteArray {
after_ms := miqt_strdupg(after)
after_ms := libmiqt.Strdupg(after)
defer C.free(after_ms)
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Replace13(this.h, (C.char)(c), (*C.struct_miqt_string)(after_ms))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Replace13(this.h, (C.char)(c), (*C.struct_miqt_string)(after_ms))))
}
func (this *QByteArray) Replace14(before string, after *QByteArray) *QByteArray {
before_ms := miqt_strdupg(before)
before_ms := libmiqt.Strdupg(before)
defer C.free(before_ms)
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Replace14(this.h, (*C.struct_miqt_string)(before_ms), after.cPointer())))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Replace14(this.h, (*C.struct_miqt_string)(before_ms), after.cPointer())))
}
func (this *QByteArray) OperatorPlusAssignWithQString(s string) *QByteArray {
s_ms := miqt_strdupg(s)
s_ms := libmiqt.Strdupg(s)
defer C.free(s_ms)
return newQByteArray_U(unsafe.Pointer(C.QByteArray_OperatorPlusAssignWithQString(this.h, (*C.struct_miqt_string)(s_ms))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_OperatorPlusAssignWithQString(this.h, (*C.struct_miqt_string)(s_ms))))
}
func (this *QByteArray) IndexOfWithQString(s string) int {
s_ms := miqt_strdupg(s)
s_ms := libmiqt.Strdupg(s)
defer C.free(s_ms)
return (int)(C.QByteArray_IndexOfWithQString(this.h, (*C.struct_miqt_string)(s_ms)))
}
func (this *QByteArray) LastIndexOfWithQString(s string) int {
s_ms := miqt_strdupg(s)
s_ms := libmiqt.Strdupg(s)
defer C.free(s_ms)
return (int)(C.QByteArray_LastIndexOfWithQString(this.h, (*C.struct_miqt_string)(s_ms)))
}
func (this *QByteArray) OperatorEqual(s2 string) bool {
s2_ms := miqt_strdupg(s2)
s2_ms := libmiqt.Strdupg(s2)
defer C.free(s2_ms)
return (bool)(C.QByteArray_OperatorEqual(this.h, (*C.struct_miqt_string)(s2_ms)))
}
func (this *QByteArray) OperatorNotEqual(s2 string) bool {
s2_ms := miqt_strdupg(s2)
s2_ms := libmiqt.Strdupg(s2)
defer C.free(s2_ms)
return (bool)(C.QByteArray_OperatorNotEqual(this.h, (*C.struct_miqt_string)(s2_ms)))
}
func (this *QByteArray) OperatorLesser(s2 string) bool {
s2_ms := miqt_strdupg(s2)
s2_ms := libmiqt.Strdupg(s2)
defer C.free(s2_ms)
return (bool)(C.QByteArray_OperatorLesser(this.h, (*C.struct_miqt_string)(s2_ms)))
}
func (this *QByteArray) OperatorGreater(s2 string) bool {
s2_ms := miqt_strdupg(s2)
s2_ms := libmiqt.Strdupg(s2)
defer C.free(s2_ms)
return (bool)(C.QByteArray_OperatorGreater(this.h, (*C.struct_miqt_string)(s2_ms)))
}
func (this *QByteArray) OperatorLesserOrEqual(s2 string) bool {
s2_ms := miqt_strdupg(s2)
s2_ms := libmiqt.Strdupg(s2)
defer C.free(s2_ms)
return (bool)(C.QByteArray_OperatorLesserOrEqual(this.h, (*C.struct_miqt_string)(s2_ms)))
}
func (this *QByteArray) OperatorGreaterOrEqual(s2 string) bool {
s2_ms := miqt_strdupg(s2)
s2_ms := libmiqt.Strdupg(s2)
defer C.free(s2_ms)
return (bool)(C.QByteArray_OperatorGreaterOrEqual(this.h, (*C.struct_miqt_string)(s2_ms)))
}
@ -799,41 +814,41 @@ func (this *QByteArray) ToPercentEncoding() *QByteArray {
}
func (this *QByteArray) SetNum(param1 int16) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNum(this.h, (C.int16_t)(param1))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNum(this.h, (C.int16_t)(param1))))
}
func (this *QByteArray) SetNumWithUshort(param1 uint16) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNumWithUshort(this.h, (C.uint16_t)(param1))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNumWithUshort(this.h, (C.uint16_t)(param1))))
}
func (this *QByteArray) SetNumWithInt(param1 int) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNumWithInt(this.h, (C.int)(param1))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNumWithInt(this.h, (C.int)(param1))))
}
func (this *QByteArray) SetNumWithUint(param1 uint) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNumWithUint(this.h, (C.uint)(param1))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNumWithUint(this.h, (C.uint)(param1))))
}
func (this *QByteArray) SetNumWithQlonglong(param1 int64) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNumWithQlonglong(this.h, (C.longlong)(param1))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNumWithQlonglong(this.h, (C.longlong)(param1))))
}
func (this *QByteArray) SetNumWithQulonglong(param1 uint64) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNumWithQulonglong(this.h, (C.ulonglong)(param1))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNumWithQulonglong(this.h, (C.ulonglong)(param1))))
}
func (this *QByteArray) SetNumWithFloat(param1 float32) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNumWithFloat(this.h, (C.float)(param1))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNumWithFloat(this.h, (C.float)(param1))))
}
func (this *QByteArray) SetNumWithDouble(param1 float64) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNumWithDouble(this.h, (C.double)(param1))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNumWithDouble(this.h, (C.double)(param1))))
}
func (this *QByteArray) SetRawData(a string, n uint) *QByteArray {
a_Cstring := C.CString(a)
defer C.free(unsafe.Pointer(a_Cstring))
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetRawData(this.h, a_Cstring, (C.uint)(n))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetRawData(this.h, a_Cstring, (C.uint)(n))))
}
func QByteArray_Number(param1 int) *QByteArray {
@ -1000,7 +1015,7 @@ func (this *QByteArray) IsNull() bool {
}
func (this *QByteArray) Fill2(c int8, size int) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_Fill2(this.h, (C.char)(c), (C.int)(size))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_Fill2(this.h, (C.char)(c), (C.int)(size))))
}
func (this *QByteArray) IndexOf2(c int8, from int) int {
@ -1077,13 +1092,13 @@ func (this *QByteArray) RightJustified3(width int, fill int8, truncate bool) *QB
}
func (this *QByteArray) IndexOf24(s string, from int) int {
s_ms := miqt_strdupg(s)
s_ms := libmiqt.Strdupg(s)
defer C.free(s_ms)
return (int)(C.QByteArray_IndexOf24(this.h, (*C.struct_miqt_string)(s_ms), (C.int)(from)))
}
func (this *QByteArray) LastIndexOf24(s string, from int) int {
s_ms := miqt_strdupg(s)
s_ms := libmiqt.Strdupg(s)
defer C.free(s_ms)
return (int)(C.QByteArray_LastIndexOf24(this.h, (*C.struct_miqt_string)(s_ms), (C.int)(from)))
}
@ -1182,43 +1197,43 @@ func (this *QByteArray) ToPercentEncoding3(exclude *QByteArray, include *QByteAr
}
func (this *QByteArray) SetNum2(param1 int16, base int) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNum2(this.h, (C.int16_t)(param1), (C.int)(base))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNum2(this.h, (C.int16_t)(param1), (C.int)(base))))
}
func (this *QByteArray) SetNum22(param1 uint16, base int) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNum22(this.h, (C.uint16_t)(param1), (C.int)(base))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNum22(this.h, (C.uint16_t)(param1), (C.int)(base))))
}
func (this *QByteArray) SetNum23(param1 int, base int) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNum23(this.h, (C.int)(param1), (C.int)(base))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNum23(this.h, (C.int)(param1), (C.int)(base))))
}
func (this *QByteArray) SetNum24(param1 uint, base int) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNum24(this.h, (C.uint)(param1), (C.int)(base))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNum24(this.h, (C.uint)(param1), (C.int)(base))))
}
func (this *QByteArray) SetNum25(param1 int64, base int) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNum25(this.h, (C.longlong)(param1), (C.int)(base))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNum25(this.h, (C.longlong)(param1), (C.int)(base))))
}
func (this *QByteArray) SetNum26(param1 uint64, base int) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNum26(this.h, (C.ulonglong)(param1), (C.int)(base))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNum26(this.h, (C.ulonglong)(param1), (C.int)(base))))
}
func (this *QByteArray) SetNum27(param1 float32, f int8) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNum27(this.h, (C.float)(param1), (C.char)(f))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNum27(this.h, (C.float)(param1), (C.char)(f))))
}
func (this *QByteArray) SetNum3(param1 float32, f int8, prec int) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNum3(this.h, (C.float)(param1), (C.char)(f), (C.int)(prec))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNum3(this.h, (C.float)(param1), (C.char)(f), (C.int)(prec))))
}
func (this *QByteArray) SetNum28(param1 float64, f int8) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNum28(this.h, (C.double)(param1), (C.char)(f))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNum28(this.h, (C.double)(param1), (C.char)(f))))
}
func (this *QByteArray) SetNum32(param1 float64, f int8, prec int) *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray_SetNum32(this.h, (C.double)(param1), (C.char)(f), (C.int)(prec))))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray_SetNum32(this.h, (C.double)(param1), (C.char)(f), (C.int)(prec))))
}
func QByteArray_Number2(param1 int, base int) *QByteArray {
@ -1302,6 +1317,13 @@ func (this *QByteRef) cPointer() *C.QByteRef {
return this.h
}
func (this *QByteRef) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQByteRef(h *C.QByteRef) *QByteRef {
if h == nil {
return nil
@ -1309,7 +1331,7 @@ func newQByteRef(h *C.QByteRef) *QByteRef {
return &QByteRef{h: h}
}
func newQByteRef_U(h unsafe.Pointer) *QByteRef {
func UnsafeNewQByteRef(h unsafe.Pointer) *QByteRef {
return newQByteRef((*C.QByteRef)(h))
}
@ -1376,6 +1398,13 @@ func (this *QByteArray__FromBase64Result) cPointer() *C.QByteArray__FromBase64Re
return this.h
}
func (this *QByteArray__FromBase64Result) UnsafePointer() unsafe.Pointer {
if this == nil {
return nil
}
return unsafe.Pointer(this.h)
}
func newQByteArray__FromBase64Result(h *C.QByteArray__FromBase64Result) *QByteArray__FromBase64Result {
if h == nil {
return nil
@ -1383,7 +1412,7 @@ func newQByteArray__FromBase64Result(h *C.QByteArray__FromBase64Result) *QByteAr
return &QByteArray__FromBase64Result{h: h}
}
func newQByteArray__FromBase64Result_U(h unsafe.Pointer) *QByteArray__FromBase64Result {
func UnsafeNewQByteArray__FromBase64Result(h unsafe.Pointer) *QByteArray__FromBase64Result {
return newQByteArray__FromBase64Result((*C.QByteArray__FromBase64Result)(h))
}
@ -1398,11 +1427,11 @@ func (this *QByteArray__FromBase64Result) Swap(other *QByteArray__FromBase64Resu
}
func (this *QByteArray__FromBase64Result) OperatorMultiply() *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray__FromBase64Result_OperatorMultiply(this.h)))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray__FromBase64Result_OperatorMultiply(this.h)))
}
func (this *QByteArray__FromBase64Result) OperatorMultiply2() *QByteArray {
return newQByteArray_U(unsafe.Pointer(C.QByteArray__FromBase64Result_OperatorMultiply2(this.h)))
return UnsafeNewQByteArray(unsafe.Pointer(C.QByteArray__FromBase64Result_OperatorMultiply2(this.h)))
}
func (this *QByteArray__FromBase64Result) OperatorAssign(param1 *QByteArray__FromBase64Result) {

View File

@ -7,7 +7,7 @@
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "binding.h"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {

View File

@ -1,7 +1,7 @@
#include <QByteArray>
#include <QByteArrayMatcher>
#include <QStaticByteArrayMatcherBase>
#include "qbytearraymatcher.h"
#include <qbytearraymatcher.h>
#include "gen_qbytearraymatcher.h"
#include "_cgo_export.h"

Some files were not shown because too many files have changed in this diff Show More