Commit graph

37 commits

Author SHA1 Message Date
therecipe
3738bb9320 greatly extend the Go <-> Qml/JS interoperability
These changes introduce two new functions called (*qml.QJSEngine).NewGoType and (*qml.QJSEngine).ToGoType, that can be used (similiar to how core.NewQVariant1 and (*core.QVariant).ToGoType can be used) to convert Go objects and functions to *qml.QJSValues and vice versa.
This allows for a more natural communication between Go and Qml/JS and makes it possible to simply pass a Go structs to Qml/JS and then call Go methods on that object.
For this to work, the object passed to Qml/JS needs to implement the `Pointer() unsafe.Pointer` and `SetPointer(unsafe.Pointer)` functions atm.
Which means, since all Qt classes already implement these functions, that you can now use the whole binding from Qml/JS as well and theoretically create a full Qt application inside an QJSEngine as well. A few example applications almost entirely written in JS can be found here: https://github.com/therecipe/examples/tree/master/js/
Furthermore, the `widgets_playground` example (https://github.com/therecipe/widgets_playground) now fully works on desktop and mobile targets as well.

other changes:
* core.NewQVariant1 and (*core.QVariant).ToGoType now recognize json tags
* workaround for qtmoc issue related to named imports
* speed-up go module android docker deployments
* fix webengine related qtdeploy bug on macOS
* fix int overflow issue for arm docker images
* fix js docker images
2019-11-17 18:05:18 +01:00
therecipe
6e660afb3d fix go module related docker deployment issue + hide env patch fallback warning for non go module dev on macOS + fix docker images 2019-11-10 19:46:04 +01:00
therecipe
79e83fbcfd make it possible to use NewQVariant1 + (*QVariant).ToGoType to convert a Go object to an QVariant and vice versa
* support a few more QVariant + QJSValue functions
* support for QWebEngineProfile + QJSValueIterator
* docker deployments now automatically uses the pinned tooling version for projects making use of go modules
* bump Go version for docker images to 1.13.4
2019-11-01 23:45:04 +01:00
therecipe
98ccee3b6f fix qtrcc issue + skip initEnv for docker deployments 2019-10-10 19:41:53 +02:00
therecipe
89b7941f48 overall deployment speedup and size reduction
* various fixes for js/wasm ([]byte support, quickcompiler support, moc fixes)
* docker go modules support
* android arm64 support
* hide rarely used dependencies behind build flags
* various minor fixes
2019-05-13 20:37:59 +02:00
therecipe
01e05b1d5c support for the uic
* fix faulty dealloc
* fix qtminimal issue
* fix windows 32 bit deployment issue
* update sailfish docker image
2019-05-06 23:55:31 +02:00
therecipe
9f97258ffe support for quickcompiler + minor cleanup + qtmoc speedup 2019-05-01 02:39:02 +02:00
therecipe
47435cc1dd various fixes for wasm, raspberry, go 1.12 and minor issues + initial support for Felgo (former V-Play)
* js/wasm GOCACHE fix for Go 1.12+
* make use of the official Go 1.12 wasm build and replace js.NewCallback with js.FuncOf
* update docker images to Go 1.12.4
* revive raspberry images
* fix raspberry related bundling issue
* add the multimedia module to the raspberry images
* fix raspberry related QT_API issue
* remove unecessary *char to []byte copy overhead in some unlikely cases
* fix Qt install script
* initial partially support for Felgo (former V-Play) on darwin
* fix charts/audio example and darwin
* fix common/widgets_demo example on iOS (issue #451)
* fix widgets/renderer memory leak
* fix possible QT_PKG_CONFIG + QT_VERSION race condition
* fix static linux docker image
2019-04-16 18:28:55 +02:00
therecipe
be7a7d5463 new static linux docker image + add qtsetup failfast flag + minor fix for docker deployments 2019-04-07 00:31:32 +02:00
therecipe
c97efc221f fix nativeEvent functions + various fixes for minor issues 2019-03-22 20:48:57 +01:00
therecipe
be468a4be7 more fixes for go modules 2019-01-21 19:28:43 +01:00
therecipe
3d04e41a82 fix desktop env related issues 2018-12-21 02:11:22 +01:00
therecipe
a790897844 the tooling now supports the pkg path format + initial support for the go get-able desktop env
these changes should make the life of all newly incoming developers (or consumers of applications build with this binding) way easier

all one needs to do now is to install Git, Go and an C/C++ compiler then the binding can be setup by running:
go get -v github.com/therecipe/qt/cmd/... && $(go env GOPATH)/bin/qtsetup

or if one is only interested in building a specific application:
go get -v github.com/therecipe/qt/cmd/... && $(go env GOPATH)/bin/qtdeploy test desktop github.com/therecipe/examples/basic/widgets

for this to work, the tooling now recognizes a pkg path and "go gets" the package if necessary

beside these changes, the deployed binaries are now properly stripped on linux and console debugging is now enabled by default on windows
2018-12-20 22:26:22 +01:00
therecipe
70c935202e fixes for various minor issues + webassembly support 2018-10-30 16:53:05 +01:00
therecipe
41dadd489d minor cleanup + fix signal/slot error type issue 2018-07-23 22:18:06 +02:00
therecipe
7038382d6c fix minor qtrcc issue 2018-04-30 22:56:13 +02:00
therecipe
0f99eb634c initial inclusion of vagrant + register missing std types for moc 2017-07-11 23:33:08 +02:00
therecipe
4db4e9c202 misc changes
recursive dependency resolution for qtrcc
fix ci qtmoc issue
support for fluid + demo
support for kirigami + demo
init files for c++ modules
new webkit 5.8.0 *.index file
2017-05-28 20:43:28 +02:00
Kenneth Shaw
567a430704 Dropping exec permissions on files 2017-04-12 15:21:13 +07:00
therecipe
a0460f5a46 selfstanding docker setup 2017-03-23 21:06:55 +01:00
therecipe
1c2fcd441f breaking changes; make use of qmake + drop legacy code
The cgo files are now generated by parsing the Makefiles generated by
qmake.
This greatly simplifies the support for additional targets, and also
removes the need to maintain extra backward and forward compatibility
code.

But these (backend) changes needed to come along with some breaking
changes to the (fontend) tooling.
So there is now the need to always specify the target when you use
qtmoc, qtrcc or qtminimal.

Some other minor breaking changes were:
The moc and rcc files are not automatically removed anymore by qtdeploy.
Because qtdeploy now has a -fast flag to make used of these cached
files.

The use of docker is now specified by using the -docker flag.

And the docker images were renamed to make their use case more clear.
2017-03-16 20:18:32 +01:00
therecipe
b07306acc2 further qmake related changes + more refactoring 2017-03-10 22:54:09 +01:00
therecipe
256c681ec8 further preparations for qmake + pre-build openssl for docker 2017-02-26 22:03:27 +01:00
therecipe
9cb2c840ec initial update to Qt 5.8 + breaking changes + new speech module
1. the qt api changed in various places
2. dropped the "_minimal" suffix for the deployment folders
3. to keep using older versions of Qt (5.7.1 for example), one would
now need to explicit export "QT_VERSION=5.7.1" and also
"QT_DIR=/path/to/Qt5.7.1"
2017-02-10 18:18:44 +01:00
therecipe
e3e91ae71b support ldflags for qtdeploy + support for tooling from docker containers 2017-01-17 17:29:33 +01:00
Alexey Kamenskiy
2e34965cf8 Add env var QTRCC_CWD to specify where to look for resources 2017-01-08 18:46:49 +08:00
Alexey Kamenskiy
438dd998a1 Temporary fix for qtdeploy not able to pass flags to qtrcc (pass them as environment then) 2017-01-08 18:00:55 +08:00
therecipe
8a83cb4e3e qt_dir & qt_version flags + partial automatic version detection 2017-01-07 18:26:06 +01:00
therecipe
7f3481d85f refactor + minor cleanup 2017-01-04 16:18:11 +01:00
therecipe
8e6d46d68e additional flags for qtrcc 2017-01-02 19:17:38 +01:00
therecipe
e201af8a0f add support for custom qrc files to qtrcc 2016-12-29 18:04:48 +01:00
therecipe
d10ed7da32 cleanup internal/parser 2016-12-11 21:03:06 +01:00
therecipe
6cdfc0c047 minor fix + cleanup 2016-11-21 21:15:53 +01:00
therecipe
c9176cdd9a cleanup qtmoc + static qRegisterMetaType 2016-11-21 17:55:44 +01:00
therecipe
26cfcccaed support cross compilation on Linux for Windows 64bit 2016-11-07 02:48:18 +01:00
therecipe
d0152ba905 support MSYS2 2016-11-05 20:49:45 +01:00
therecipe
bac79d8fdd cleanup + split qtdeploy 2016-10-29 23:28:13 +02:00