slint-ui/slint

Zed Syntax highlighting for grammar in callbacks is incorrect

Closed

#11,724 opened on May 13, 2026

 (4 comments) (0 reactions) (0 assignees)Rust (881 forks)batch import
a:editor integrationgood first issue

Repository metrics

Stars
 (22,596 stars)
PR merge metrics
 (Avg merge 4d 18h) (254 merged PRs in 30d)

Description

Bug Description

The callback code should look like the following:

but when I use the concise callback syntax, it seems not to recognize the code as code and highlights it as plain white

This happens in all cases, from what I can tell:

I apologize in advance if I've used any incorrect terminology. I've searched the issues, but didn't find anything related. Since this bug has been around for quite some time now, I figured I'd open a bug report.

Reproducible Code (if applicable)

Environment Details

  • Slint Version: 1.16.1 (this bug has been around for some time though)
  • Platform/OS: NixOS (Wayland)
  • Programming Language: Rust
  • Backend/Renderer: winit (probably, not certain)

Product Impact

I'm just working on a hobby app. This is just an inconvenience. It seems like an easy fix, so I figured I'd open an issue anyway.

Contributor guide