Commit graph

51 commits

Author SHA1 Message Date
Nigel Breslaw
2c5b402909
Tweak to reduce total number of rust-cache (#10017)
50GB of caches in branches is still being created. This doesn't 
eliminate them all but makes a decent dent. This stops the more useful 
master branch cache being evicted.
2025-11-10 14:46:27 +02:00
Nigel Breslaw
20403cd597
Split up the daily (ci.yaml) and nightly tests (#9969)
Some checks are pending
autofix.ci / format_fix (push) Waiting to run
autofix.ci / lint_typecheck (push) Waiting to run
autofix.ci / ci (push) Blocked by required conditions
1. Removed the cron job that ran autofix.ci every morning to warm the cache.
2. A new reusable 'build_and_test_reusable.yaml' can be used by both ci.yaml and nightly snapshots.
3. Reduce ci.yaml build_and_test to macos-14 rust stable, ubuntu 22.04 rust 1.88 and windows 2022 rust beta.
4. With the nightly run on the free CI macos-14 rust nightly, ubuntu 22.04 nightly and windows 2022 rust 1.18.
2025-11-06 12:27:20 +02:00
Nigel Breslaw
ddbc961c39
Install gettext on MacOS instead of compiling from source (#9944)
* Install gettext on MacOS instead of compiling from source

1. Removes the attempt to install Ninja as it's included in the github 
   runner macos-xx images.
2. Brew install gettext and sets the env so it can be used during 
   compilation. This makes no difference on cached runs, but speeds up 
   uncached and initial runs.

* No need to install gettext
2025-11-04 14:26:04 +02:00
Nigel Breslaw
3d770ba379
Tweak how the Rust cache works in CI (#9902)
This adds an option so any job can opt out of using the cache. It defaults to using the cache so right now everything that was using the cache will continue to do so.

The second change is that as we are well over the 10GB cache limit. So we will no longer save the cache created in a PR branch. As only the master branch cache is shared this PR branch cache could only benefit subsequent runs of the same PR. If this turns out to slow PR's down it can be easily turned off later.
2025-10-31 14:51:30 +02:00
Olivier Goffart
5a537a3e1c Prospective CI fix
Error in CI:

```
Chocolatey v2.4.3
Upgrading the following packages:
llvm
By upgrading, you accept licenses for the packages.
A newer version of llvm (v20.1.7) is already installed.
 Use --allow-downgrade or --force to attempt to install older versions.

Chocolatey upgraded 0/1 packages. 1 packages failed.
 See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log).

Failures
 - llvm - A newer version of llvm (v20.1.7) is already installed.
 Use --allow-downgrade or --force to attempt to install older versions.
```

This ammends 4823ffa490
2025-07-08 12:54:26 +02:00
Simon Hausmann
4823ffa490 Fix skia build failure by avoiding llvm 20
MSVC has llvm 19 installed, and somehow llvm 20 would include llvm 19
headers from MSVC. Key details from the failure at bindgen clang
invocation time:

```
GENERATING BINDINGS
    ARGS: -ID:\a\slint\cargo\registry\src\index.crates.io-1949cf8c6b5b557f\skia-bindings-0.86.1\skia -D_CRT_SECURE_NO_WARNINGS -D_HAS_EXCEPTIONS=0 -DWIN32_LEAN_AND_MEAN -DNOMINMAX -DNDEBUG -DSK_CODEC_DECODES_BMP -DSK_CODEC_DECODES_WBMP -DSK_ENABLE_PRECOMPILE -DSK_GANESH -DSK_DISABLE_TRACING -DSK_GAMMA_APPLY_TO_A8 -DSK_USE_VMA -DSK_ENABLE_AVX512_OPTS -DSKIA_IMPLEMENTATION=1 -DSK_TYPEFACE_FACTORY_DIRECTWRITE -DSK_FONTMGR_DIRECTWRITE_AVAILABLE -DSK_FONTMGR_GDI_AVAILABLE -DSK_GL -DSK_DIRECT3D -DSK_VULKAN -DSK_CODEC_ENCODES_JPEG -DSK_SUPPORT_PDF -DSK_CODEC_DECODES_JPEG -DSK_CODEC_ENCODES_PNG -DSK_CODEC_ENCODES_PNG_WITH_LIBPNG -DSK_CODEC_ENCODES_PNG_WITH_CONVERT_PIXELS -DSK_CODEC_DECODES_ICO -DSK_CODEC_DECODES_PNG -DSK_CODEC_DECODES_PNG_WITH_LIBPNG -DSK_HAS_WUFFS_LIBRARY -DSK_CODEC_DECODES_GIF -DSK_XML -DSK_USE_INTERNAL_VULKAN_HEADERS -DSKSHAPER_IMPLEMENTATION=1 -DSK_SHAPER_PRIMITIVE_AVAILABLE -DSK_SHAPER_HARFBUZZ_AVAILABLE -DSK_SHAPER_UNICODE_AVAILABLE -DSK_UNICODE_AVAILABLE -DSK_UNICODE_ICU_IMPLEMENTATION -DSK_ENABLE_PARAGRAPH -DSKUNICODE_IMPLEMENTATION=1 -DU_SHOW_CPLUSPLUS_API=0 -DU_USING_ICU_NAMESPACE=0 -DU_DISABLE_RENAMING=1 -DSK_USING_THIRD_PARTY_ICU -DU_NOEXCEPT= -DU_STATIC_IMPLEMENTATION -DU_COMMON_IMPLEMENTATION -DU_ENABLE_DYLOAD=0 -DU_I18N_IMPLEMENTATION -D_XOPEN_SOURCE=0 -fno-rtti --target=x86_64-pc-windows-msvc
...
Checking for "C:\\Program Files\\LLVM\\bin\\clang-cl.exe"
  clang version 20.1.4
  Target: x86_64-pc-windows-msvc
...
  ignoring nonexistent directory "lib\clang\20\include"
...
C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Tools\Llvm\x64\lib\clang\19\include\mmintrin.h:56:19: error: use of undeclared identifier '__builtin_ia32_vec_init_v2si'
(and a bunch more like this)
```

(note the inclusion of x86 headers from a
--target=x86_64-pc-windows-msvc build)
2025-06-26 22:08:19 +02:00
Simon Hausmann
28b295b33d Revert "Attempt to work around llvm / clang-cl bug for Skia build"
This reverts commit 4fef985fbc.

As per https://github.com/rust-skia/rust-skia/pull/1114 this shouldn't be needed anymore.
2025-03-31 12:17:42 +02:00
Simon Hausmann
2a74201418 CI: trim trailing whitespace 2025-02-28 11:18:54 +01:00
Simon Hausmann
4fef985fbc Attempt to work around llvm / clang-cl bug for Skia build
... by pinning the specific llvm version and applying the upstream patch "by hand".
2025-02-28 11:13:23 +01:00
Simon Hausmann
ec88305867 Update Skia Bindings
This allows reverting 18db3210d6 and

Fixes #6615
2025-02-23 17:11:52 +01:00
Nigel Breslaw
a4bd5bcde5
Remove unused github action (#7625)
This isn't used and the project no longer uses Cypress.
2025-02-13 12:12:58 +02:00
Nigel Breslaw
45cd9a9719
Upgrade PNPM 9.x to 10.3 (#7602)
This also recreates the lock file in an attempt to clear out the old version of esbuild that is causing alerts.
2025-02-11 15:00:43 +02:00
Simon Hausmann
9504a4f090 Fix popupwindow.close() not working for the interpreter when called from other component
The instance passed to close_popup() was not the same as the one passed
to show_popup(), when called from another component. Fix this by
determining the instance in BuiltinFunction::ClosePopupWindow the same
way as in BuiltinFunction::ShowPopupWindow.

This issue was covered by popup_window_close.slint's JS test, but it was
commented out because we used to run the Node.js tests on Linux with Qt,
for which the popup testing doesn't work the same way in terms of
synthetic event delivery.

We decided to change that, also in light of the nodejs binaries we
upload to the NPM registry also being built without Qt support anyway.

This permits running additional popup window tests, providing test
coverage for the interpreter, some of which needed light syntax fixes.

Co-authored-by: Olivier Goffart <olivier.goffart@slint.dev>

Fixes #7318
2025-01-10 18:27:14 +01:00
Olivier Goffart
71e331995c Don't depend on muda on Linux 2025-01-08 14:05:35 +01:00
Olivier Goffart
846664ad45 WIP: native menubar using muda
Only the interpreter is implemented so far

MacOs won't work yet because we don't disable the default winit menubar

The viewer don't support removing the MenuBar yet
2025-01-08 14:05:35 +01:00
Aurindam Jana
0898a5f641
Tweak Docs (#6834)
---------

Co-authored-by: Nigel Breslaw <nigel.breslaw@slint.dev>
2024-11-20 14:27:37 +01:00
Nigel Breslaw
08d90a5f13
Next gen docs for 1.9 (#6766)
Co-authored-by: Aurindam Jana <aurindam.jana@slint.dev>
Co-authored-by: Tobias Hunger <tobias.hunger@slint.dev>
Co-authored-by: Simon Hausmann <simon.hausmann@slint.dev>
2024-11-14 15:52:35 +01:00
Nigel Breslaw
0461abfc73 Avoid building Rust on pnpm install 2024-11-14 12:25:42 +01:00
Nigel Breslaw
a97b7c7d92
Replace npm with pnpm
Replaces the use of NPM with PNPM. This should make it quick and easy to update any of the dependencies as dependabot will now see everything in one go.
2024-10-07 15:38:26 +03:00
Aurindam Jana
3523e86359
Simplify commercial license (#3063)
Base the commercial license on the Royalty-free license adding clauses pertaining to the fees.
2024-05-31 14:06:17 +02:00
Aurindam Jana
9a3aa265d5
Update Royalty-free license (#5257)
Add clarification that Application may not expose Slint APIs.
2024-05-31 10:53:19 +02:00
Aurindam Jana
0cfeec1a31
Update Slint Community License (#4994)
Updated the version from 1.1 to 1.2 
Renamed the header to "Slint Royalty-free Desktop, Mobile, and Web Applications License"
Added definition of "Mobile Application" and grant of right
Moved "Limitations" to 3rd section and "License Conditions - Attributions" to 2nd section
Added flexibility to choose between showing "MadeWithSlint" as a dialog/splash screen or on a public webpage
Moved the para on copyright notices to section under "Limitations"
2024-04-15 15:18:55 +02:00
Tobias Hunger
e639640dc2 ci: Update actions/cache to v4 2024-02-16 19:10:56 +01:00
Tobias Hunger
8eea2851b7 ci: Format all yaml files with our prettier configuration
No code change, just prettier doing its thing in this change!
2024-02-16 19:10:56 +01:00
Olivier Goffart
236f03b96e CI: update github action dependencies
Looked at warning of actions that still uses old node version and update
the onces that had a new release
2024-02-02 12:09:07 +01:00
Simon Hausmann
138443fa8d Add code signing for macOS tool binaries
This signs the slint-lsp/slint-viewer binaries as well
as the lipo'ed binary for the VS code extension.

cc #4240
2024-01-08 15:12:40 +01:00
Tobias Hunger
b12575a4c4 janitor: Go over our spell checking setup
* Extend the cspell word list
* Remove those extensions from individual source files
* white-list licenses and such as we should not meddle with those
* Fix spelling
2023-10-16 09:01:51 +02:00
Simon Hausmann
c2689f3f56 Prospective fix for failing nightly builds
Don't try to install newer packages on older Ubuntu versions
(where we don't need them anyway)
2023-07-29 13:32:16 +02:00
Simon Hausmann
fee44f3f7d Add basic support for libseat
This is not dynamic unfortunately, but at least it forwards device access for OpenGL and remove the need to run it as root.
2023-07-28 13:40:37 +02:00
Simon Hausmann
5c9eed62f1 Add a new backend that supports rendering fullscreen with Vulkan
This doesn't require a windowing system, just Linux and Vulkan drivers
that supports the display extensions.

It's called linuxkms as soon this will go beyond Vulkan and also support
EGL and perhaps dumb buffers for software rendering.
2023-07-28 13:40:37 +02:00
Aurindam Jana
5a4a7fee63
Update royalty free license to 1.1 (#2994) 2023-07-10 10:12:11 +02:00
Olivier Goffart
11dea135f7 Domain: slint-ui.com -> slint.dev 2023-06-16 10:55:08 +02:00
Tobias Hunger
04d1229685 Fix licnese information using xtask 2023-06-16 09:14:20 +02:00
Simon Hausmann
45a6460aa2 Add slightly more elaborate comment about windows longpath support 2023-05-09 08:58:35 +02:00
Simon Hausmann
6d7b5863d0 Fix build of Skia from source on Windows
Long paths cause build issues on Windows.

- Enable support for long paths in git checkouts. The GH action runners
  have the path limits disabled in the registry (good), but git needs to
  know that it can use the right APIs.

- Move the cargo checkouts to the same drive as Slint, so that the
  relative paths computed from the slint build dir to the cargo source
  tree (as part of the skia build) don't include a drive letter (which
  breaks the ninja buid).
2023-05-09 08:58:35 +02:00
Tobias Hunger
de0dc20e5b
slintpad: Move into tools/slintpad (#2435)
* Add "slintpad" to cspell white list for all languages
* Mention online_editor to slintpad rename in CHANGELOG
* Move tools/online_editor into tools/slintpad
* Update github actions accordingly

Co-authored-by: Olivier Goffart <olivier@woboq.com>
2023-03-29 16:32:30 +02:00
Simon Hausmann
b888870705 CI: Don't run apt-get upgrade
Sometimes updates to packages break in the GH provided virtual machines, as
witnessed in current CI breakage. Let's let GH decide when to install security updates.
2023-02-17 09:45:45 +01:00
Tobias Hunger
9ccf6c3bdf ci: Turn of cypress tests of the online editor
The two tests provide somewhat limited value at this time: The Firefox
tests were green before, but we think that should not have been the case
as firefox does not accept the imports in the webworker when serving
with vite in dev mode -- which we did.

Trying to change the test to use the actual generated site fails for
unknown reason: Cypress claims the page reported by `vite prefix` as up
is returning 404 in CI. It works fine locally:-/
2023-01-20 18:27:11 +01:00
Olivier Goffart
f2b527c53b CI: update actions/setup-node 2022-11-15 13:20:02 +01:00
Olivier Goffart
41967e6d19 CI: update actions/upload-artifact 2022-11-15 13:20:02 +01:00
Olivier Goffart
aec8af5273 CI: upgrade actions/cache 2022-11-10 08:58:43 +01:00
Olivier Goffart
5b6762ea70 Ci: don't use deprecated set-output
Just followed the instructions in https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
2022-11-10 08:50:20 +01:00
Olivier Goffart
1fd714b127 CI: Upgrade the rust-toolchain action again
So that we can get rid of the deprecated warnings
2022-11-10 08:37:26 +01:00
Olivier Goffart
8e292bfe94 Ci: upgrade the rust toolchain action
action-rs repos are unmaintained for years, and they show lots of deprecated warnings.
2022-11-10 08:27:33 +01:00
Olivier Goffart
97ef02827e CI: prospective fix for current nightly build failures by cleaning the cache. 2022-11-05 08:52:19 +01:00
Simon Hausmann
3990b2bba1 Bump rust cache version to fix github action deprecation warnings 2022-10-27 09:41:30 +02:00
Tobias Hunger
868d5f9de2 Update node version to 16 2022-10-20 15:42:50 +02:00
Tobias Hunger
0767a70f9e ci: Wire up cypress tests for the online_editor
Run the E2E tests in chrome and firefox on Linux
2022-09-20 12:13:40 +02:00
Tobias Hunger
97a8a26da6 ci: extract nodejs install into an action 2022-09-19 17:13:26 +02:00
Tobias Hunger
9356ee4316 ci: add action to install linux dependencies
... so that we do not need to spell out the same packages everywhere!
2022-09-19 17:13:26 +02:00