Commit graph

15 commits

Author SHA1 Message Date
Simon Hausmann
f1e7f876f9 Make the showing/hiding of language snippets explicit in the markup
Use a data attribute instead of relying on the structure of rustdoc and myst-parser/sphinx.
2022-04-04 10:01:26 +02:00
Simon Hausmann
1eaee7809d Show/hide the language specific example blocks in the recipes 2022-04-04 10:01:26 +02:00
Simon Hausmann
ed5b76e7fc Improve syntax highlighting in the language reference
Highlight all Slint code and don't do the preview on snippets where it
doesn't make sense.

Some snippets, such as the bare statement or expression snippets, are
now highlighted, but they are continued to be excluded from the doctest.
2022-04-04 09:58:09 +02:00
Olivier Goffart
5a3f2551ad Docs preview: keep the browser default canvas size by default
Setting it to 0 will then use the winit default that are way too big

And in this case, the preferred size is still respected
2022-04-01 16:18:59 +02:00
Simon Hausmann
079a8a75d6 Fix sizes of some of the preview canvas elements in the docs
Don't fix the canvas to 100/100 physical pixels, as not all examples fit into that. Instead
let the GL backend resize according to constraints,
and add some missing sizes to some examples.
2022-03-21 16:53:30 +01:00
Olivier Goffart
1aaa48c6a6 Revert "Update URL for the release"
This reverts commit c04c0946f3.

Release was done
2022-03-10 09:47:30 +01:00
Olivier Goffart
c04c0946f3 Update URL for the release 2022-03-10 08:48:42 +01:00
Olivier Goffart
af328037c0 Revert "Update the URL in the generated docs in preparation for the release"
This reverts commit d5726a9269.

The release is done: go back to nightly
2022-02-10 09:28:14 +01:00
Olivier Goffart
d5726a9269 Update the URL in the generated docs in preparation for the release 2022-02-10 07:32:35 +01:00
Simon Hausmann
e339b057cd Fix url to wasm interpreter in doc snapshots 2022-02-09 18:49:24 +01:00
Simon Hausmann
1f74f30c42 Prevent the doc preview slint instances from being collected by the garbage collector
We need to keep the VRc alive
2022-02-09 17:55:05 +01:00
Simon Hausmann
1cdbc88762 Fix non-interactive doc preview
Only the last shown preview was interactive. This was because we started the winit event loop for each preview,
which kind of invalidates the previous instance in winit.

Instead, create all components, call show() on each instance to register the window with winit
and spin the event loop with its exception magic only once.
2022-02-09 17:55:05 +01:00
Olivier Goffart
1425ef63de Change the Url from sixtyfps.io to slint-ui.com
Also, change the URL of the logo in the docs
2022-02-08 08:52:46 +01:00
Olivier Goffart
0d8142c93a Fix snapshot URL 2022-02-04 15:50:21 +01:00
Olivier Goffart
7f7b620a35 Update the injected scripts to the new name 2022-02-02 12:26:55 +01:00
Renamed from docs/resources/sixtyfps-docs-preview.html (Browse further)