mirror of
https://github.com/slint-ui/slint.git
synced 2025-08-04 18:58:36 +00:00
Docs: document that \{...}
is not working in a slint!
macro
Closes #2517
This commit is contained in:
parent
beb7af5a9c
commit
addc1247ec
2 changed files with 14 additions and 4 deletions
|
@ -298,11 +298,19 @@ fn extract_include_paths(
|
|||
(remaining_stream, include_paths)
|
||||
}
|
||||
|
||||
/// This macro allows you to use the `.slint` design markup language inline in Rust code. Within the braces of the macro
|
||||
/// you can use place `.slint` code and the named exported components will be available for instantiation.
|
||||
/// This macro allows you to use the Slint design markup language inline in Rust code. Within the braces of the macro
|
||||
/// you can use place Slint code and the named exported components will be available for instantiation.
|
||||
///
|
||||
/// [The documentation of the `slint`](./index.html) crate contains more information about the language specification and
|
||||
/// how to use the generated code.
|
||||
/// For the documentation about the syntax of the language, see
|
||||
#[doc = concat!("[The Slint Language Documentation](https://slint-ui.com/releases/", env!("CARGO_PKG_VERSION"), "/docs/slint)")]
|
||||
///
|
||||
/// When `import`ing `.slint` files or loading images with `@image-url`, the specified paths are relative to the
|
||||
/// the directory that contains Cargo.toml.
|
||||
///
|
||||
/// ### Limitations
|
||||
///
|
||||
/// Within `.slint` files, you can interpolate string literals using `\{...}` syntax.
|
||||
/// This is not possible in this macro as this wouldn't parse as a Rust string.
|
||||
#[proc_macro]
|
||||
pub fn slint(stream: TokenStream) -> TokenStream {
|
||||
let token_iter = stream.into_iter();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue