Re: [Interest] Running Qt app in a browser
> Sent: Monday, April 25, 2016 at 4:59 PM > From: "Larry Martell" <larry.mart...@gmail.com> > To: interest@qt-project.org > Subject: [Interest] Running Qt app in a browser > > Is it possible to run a Qt app in a browser? I have googled for this, > and found some hits, but none seen like they ever worked out. The most > promising seems to be http://wiki.qt.io/Qt_for_Google_Native_Client > but the readme link is broken, so that's discouraging. Anyone have any > pointers on if this can be done and if so how? 1 . Someone already mentioned Wt, I have used Wt, and Qt, and even tried to merge the two a little by patching uic to produce Wt code from the .ui files. It worked ok, not 100%. I am very happy with WT, but I prefer making REST servers so that web and non-web mobile (QML?) clients can use them. 2. I had proposed and worked on for a short while a project called vaudeville, which would enable QPainter with with a HTML Canvas painter. It worked really well in terms of pixel-perfect, but the fonts were not. They were good, but the pixel hinting was a little different. That would be the closest to what you want that isn't NaCL. But that only got so far as an engineering level test. QPA (what I would need to plug it into Qt properly) was still very much in flux at the time. I postponed it and ever got back to it. 3. You might want to look at QxtWeb. ( http://libqxt.bitbucket.org/doc/tip/qxtweb.html ) You'll get more code re-use, but you'll have to code a special web client yourself. However, to the rescue, is QMLWeb, which is QML compatible, would allow you to produce some degree of QML re-usable code . 4. A final option is asm.js, you could (in theory, I've not tried this) load all of the Qt in a browser and run it through ASM.js ( http://asmjs.org/ ) Check out the slide deck which specifically mentions Qt. That's about all there is. My current MO is a NodeJS REST server and AJAX to the various clients, in whatever they are (QML/HTML usually) ___ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest
Re: [Interest] Running Qt app in a browser
K. Frank said: > Hi Larry! > > On Mon, Apr 25, 2016 at 4:59 PM, Larry Martell> wrote: > > Is it possible to run a Qt app in a browser? I have googled for this, > > and found some hits, but none seen like they ever worked out. The most > > promising seems to be http://wiki.qt.io/Qt_for_Google_Native_Client > > but the readme link is broken, so that's discouraging. Anyone have any > > pointers on if this can be done and if so how? > > This doesn't answer your question, but as an aside, there is a web-application > framework called Wt: > >https://www.webtoolkit.eu/wt > > Wt shares some of the Qt philosophy -- application code (and the Wt library) > is written in C++, it is widget-based, and it uses signals and slots. I don't know > Wt's history, but I think Qt that significantly influenced the design of Wt. > > Of course, high-level similarities notwithstanding, the details are entirely > different. You couldn't, for example, compile a Qt application into a Wt > application. > > But if you like Qt and were starting a new web-application development > project, Wt could make sense, and if you really needed to port a Qt > application to the web, porting from Qt to Wt would still be a substantive > port, but the similar philosophy might make the port a little smoother. > > > Thanks! > > Good luck! > > K. Frank I am currently creating a Wt based web application that reuses many of our non-GUI Qt based classes. I works really well based on the prototypes done so far. Theoretically, you could create a QPaintEngine that uses the WPainter interface to draw GUI objects, but I haven't investigated that. Tony ___ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest
Re: [Interest] Running Qt app in a browser
Hi Larry! On Mon, Apr 25, 2016 at 4:59 PM, Larry Martellwrote: > Is it possible to run a Qt app in a browser? I have googled for this, > and found some hits, but none seen like they ever worked out. The most > promising seems to be http://wiki.qt.io/Qt_for_Google_Native_Client > but the readme link is broken, so that's discouraging. Anyone have any > pointers on if this can be done and if so how? This doesn't answer your question, but as an aside, there is a web-application framework called Wt: https://www.webtoolkit.eu/wt Wt shares some of the Qt philosophy -- application code (and the Wt library) is written in C++, it is widget-based, and it uses signals and slots. I don't know Wt's history, but I think Qt that significantly influenced the design of Wt. Of course, high-level similarities notwithstanding, the details are entirely different. You couldn't, for example, compile a Qt application into a Wt application. But if you like Qt and were starting a new web-application development project, Wt could make sense, and if you really needed to port a Qt application to the web, porting from Qt to Wt would still be a substantive port, but the similar philosophy might make the port a little smoother. > Thanks! Good luck! K. Frank ___ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest
Re: [Interest] Running Qt app in a browser
Not a full solution, but just a thought, you could use some sort of CGI script to call your Qt Application backend? For the Gui, I wonder if rendering the image into a texture or an image. Send the image to the client (delta compressed). Make the rendering into a canvas and apply changed. You could send the mouse click from the client back to the application as JSON call to your CGI as relative coordinate and simulate them into the Qt application. This would be bandwidth intensive, but depending on what you try to achieve. On Mon, Apr 25, 2016 at 4:59 PM, Larry Martellwrote: > Is it possible to run a Qt app in a browser? I have googled for this, > and found some hits, but none seen like they ever worked out. The most > promising seems to be http://wiki.qt.io/Qt_for_Google_Native_Client > but the readme link is broken, so that's discouraging. Anyone have any > pointers on if this can be done and if so how? > > Thanks! > ___ > Interest mailing list > Interest@qt-project.org > http://lists.qt-project.org/mailman/listinfo/interest > ___ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest