Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include a watchfaces prototyping webpage #3

Open
FlorentRevest opened this issue Oct 4, 2017 · 4 comments
Open

Include a watchfaces prototyping webpage #3

FlorentRevest opened this issue Oct 4, 2017 · 4 comments

Comments

@FlorentRevest
Copy link
Member

Currently, watchfaces can be prototyped from a computer using some hacks and wizardry described in the following documentation page. https://asteroidos.org/wiki/watchfaces-creation/
This requires a very complex development workflow including an entire SDK.
However, the QmlWeb project https://qmlweb.github.io/ provides an open source in-browser live coding platform that could easily be integrated in a webpage of asteroidos.org https://github.com/qmlweb/qmlweb.github.io/blob/master/index.html#L29 It would even remove the need for the background Image component and "new Date()" hacks.
Moreover, the webpage could export the .qml file and .jpg preview into a tarball that could be deployed on the watch.

@TheLastProject
Copy link
Contributor

When trying to work on this, I found out that QMLWeb doesn't support Canvas yet (only a stub according to https://github.com/qmlweb/qmlweb/projects/8, and it failed to load all the current watchfaces, even when removing the AsteroidOS specific bits like in the documentation page), which is really necessary for the AsteroidOS watches. It still seems to be very incomplete.

So, unfortunately, this seems to not be possible with QMLWeb for now. Not for creating actual watchfaces at least. Quick research of the alternatives gives me the following info:

Qt Quick WebGL streaming: Planned to be released in Qt 5.10, which is scheduled for November 2017. Will require a server.

PureQml framework: Seems possible, but will require a server.

Qt/QML + Emscripten: Can't find any source code with instructions and have no experience with any of this. Most links on the page are dead. Hacker news talks about it being a 30MB JavaScript library, that will hurt to run in any browser.

I probably won't be working on this as it's too much work for me to want to bother with right now, but I hope this info helps whoever tries next.

@FlorentRevest
Copy link
Member Author

Maybe https://www.qt.io/blog/web-based-qt-design-viewer could do the trick :)

@jrtberlin
Copy link
Member

QML online seems like a possible base too. It uses web assembly and has a code editor, samples and sharing built-in.
Source code

image

@beroset
Copy link
Member

beroset commented Oct 31, 2021

I've been working on this with the previously mentioned QML online. Its implementation of QML is definitely sufficient: https://tinyurl.com/2ormgzq9
Here is what I think would be needed

  • modify it so that globals such as wallClock and displayAmbient are available within the QML
  • create a way to upload other resources such as fonts, jpgs
  • provide a means of exporting
  • provide a method for taking a snapshot of just the watch face

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants