This link works on the slint web site, but not when run locally. We do
not expect this to have users outside of the Slint site, so we are
willing to accept this limitation.
Please open a bug report if you indeed use the online editor elsewhere
and are bothered by the link.
we need to use commonjs for the extension
If we start the client before the server has loaded the wasm, we don't
listen yet to the init message, so make sure not to start the client
before we sent the "OK" message back.
But it's still not working, the wasm code is called, but the parameter are
not properly passed
* Use wasm-pack's web mode to create a .wasm file and an ESM module for the
glue code
* Import the .wasm file directly in browserServerMain.ts
* And process it all with esbuild, which succeeds in seeing the .wasm import in
browserServerMain.ts and then bundles it inline.
This refactor the LSP to be possible to compile for wasm.
When using wasm we can't use the lsp-server crate because that one use the
stdin/stdout to communicate.
Instead, we need will do the communication in TypeScript using the vscode
language server protocol library, and serialize the types to wasm. Fortunately
that's easy because the lsp-types crate contains all the serialized types.
This also "duplicate" the extension as a web extension that do not use process
to start the LSP, but use a web worker. Some of the extension code could
be refactored to avoid some duplication (like the status bar handling and such).
And add a "browser" entry point in the package.json
Finally, add a browserServerMain.ts entry point for our worker, it will try to load
the wasm code.
Currently this doesn't wirk: the browserServerMain.ts can't load the wasm.
Also todo is to write the code so that the wasm code can send the response and
notifications.
To debug, I type these commands in editor/vscode directory
npm run compile-web
code --extensionDevelopmentKind=web --extensionDevelopmentPath=$PWD ../..
When the percentage is missing, we should interpolate between the
last valid entry to the first valid entry after that, not always the
last valid entry in the whole gradient
Qt implementation only keep one stop if two are at the same location.
So mangle the stop position to be sure they are all at sligntly different position
The loop was skipping one of the stop to interpolate
because when one iterator was returning None, the other
one had also advenced and its result discared.
We can just unwrap the value instead from the longer chain.
For the radial gradiant, we need to interpolate the last
colors to avoid a flash at the beginning for all the area
"outside" the circle.
We changed the MSRV in the last release because some dependency depended on
Rust 1.59. But that did not concern the C++ build, for example.
Now that we rely on rust 1.59 in our own code, we should make it explicit
so that the compilation error show the proper error
The `lower_property_to_element` pass usually disallows that because it
injects the Layer element and we can't do that for components. But we
can handle this like with opacity and inline.
femtovg's large fragment shader with much code and many branches (on
uniforms though) is paying a hefty price on GPUs like the GC7000UL.
This brings in an open merge request to femotvg that splits up the
fragment shader into smaller programs, giving a speed bump of ~15FPS on
a moderately complex scene.