Olivier Goffart
58cdaeb8dd
Update license header to mention that commertial option are available
2020-08-26 13:23:42 +02:00
Simon Hausmann
2823f32692
Apply license headers to all non-binary/non-json sources
2020-08-17 17:55:20 +02:00
Simon Hausmann
3d5d112deb
Fix paths to logos
2020-08-11 16:57:04 +02:00
Olivier Goffart
b259a09338
Rename the types float32 and int32 to float and int
2020-08-03 16:15:41 +02:00
Olivier Goffart
de188e0a54
Add the as_weak to rust generated component
2020-08-03 15:36:54 +02:00
Olivier Goffart
8aef208340
Rust: add on_* to set signal handler
2020-08-03 15:01:10 +02:00
Olivier Goffart
cb67e40c32
Rename WeakPin -> PinWeak
2020-07-31 18:19:26 +02:00
Olivier Goffart
6c54dfb67d
Layout the item in a PathLayout if they are part of a repeater
2020-07-17 15:00:12 +02:00
Olivier Goffart
8e7e3aaa7a
Make the length its own unit
2020-07-14 17:45:03 +02:00
Olivier Goffart
952ddda7c4
Force duration to have an unit
2020-07-14 16:18:12 +02:00
Olivier Goffart
e00491811b
Get rid of the context in properties/signal
2020-07-13 18:49:06 +02:00
Olivier Goffart
ab7ae9f3e2
Some refactoring of the rust generated code
...
Always use a Pin<Rc> for the component. (This is required to support repeater
within repeater as well anyway)
Do not use the context within the binding. We can get along by simply capturing
a weak pointer to the component
2020-07-13 16:37:54 +02:00
Simon Hausmann
c17c06c6e7
Making closing of a path optional
...
By default paths are not closed and they can be closed using a Close {}
element.
2020-07-09 09:52:09 +02:00
Olivier Goffart
1cbd522a03
Rust: make non-constant model and if expression work
2020-07-03 14:04:23 +02:00
Simon Hausmann
5e61ed4ad2
Implement Path and LineTo in the markup
2020-07-01 15:13:23 +02:00
Simon Hausmann
b8ca0fe3c9
Add support for animating color properties
2020-06-27 16:51:48 +02:00
Olivier Goffart
2d22bac451
Use Pin<&Self> for Property::get
2020-06-26 13:18:04 +02:00
Simon Hausmann
f14eb956bf
Silly tweak to example for animations
...
Move the minus button a little to the right when pressing. This isn't
great useabilty, but it demonstrates the concept easily for a moment ;-)
2020-06-24 17:54:25 +02:00
Olivier Goffart
caca0d0ba4
Put the component in a Pin<>
...
Removed the drop and create from the ComponentVTable:
since we are not using VBox<ComponentVTable>, this simplifies a bit
the code of the interpreter and everything else.
But there is still a lot of changes everywhere to support that the Component
is pinned.
This is just for the component. Which would be required if later we want
to access the properties as Pin<Property<_>>. But we have not yet ability
to do projections
2020-06-24 14:13:27 +02:00
Olivier Goffart
7bd186a159
Small fixups
2020-06-17 10:35:30 +02:00
Olivier Goffart
d7fe69ff74
Lookup the index from a repeater expression
2020-06-16 17:23:38 +02:00
Olivier Goffart
6122f91fba
Begin with the generation of rhe repeater (rust only for now)
2020-06-16 13:47:02 +02:00
Olivier Goffart
8713c10d48
Color literals
2020-06-11 19:26:41 +02:00
Simon Hausmann
63f81e1991
Add basic support for conditional expressions
...
Todo are automated tests and cleaning up the C++ implementation.
2020-06-10 16:04:15 +02:00
Olivier Goffart
dc276290e9
Add support for self assignment (+=, -=, ...)
2020-05-28 17:02:06 +02:00
Simon Hausmann
b8a8abcdf9
Make the plus minus use-case work with the Rust frontend
...
Initialize the counter label from a property that we modify in signals handlers
from Rust code.
2020-05-28 15:20:30 +02:00
Olivier Goffart
95b671c97c
Support for code blocks and signal call
2020-05-28 12:30:08 +02:00
Simon Hausmann
4f9c53879b
Implement property references as bindings in the Rust frontend
2020-05-28 11:37:59 +02:00
Olivier Goffart
e34ac8c3f4
Get signals and toucharea working on the rust example
2020-05-25 17:41:24 +02:00
Olivier Goffart
dd756ef112
Adapt the parser to parse := instead of =
2020-05-25 10:46:00 +02:00
Olivier Goffart
ab28828351
Support for img!("foo.png") to make string absolute
...
This is a temporary solution until we get better ressource handling
2020-05-19 16:30:48 +02:00
Simon Hausmann
23d3964a0d
Add boilerplate for text items
...
Forward the text and color properties to the rendering backend, where
right now we just rendering all the glyphs into a dedicated texture.
Next steps are a glyph atlas texture, blending the specified color with
the alpha of the glyphs, configurable size and family, shaping with
Harfbuzz and may more things.
2020-05-18 19:04:12 +02:00
Simon Hausmann
3142883ca8
Render the contents of image elements
...
The source property is a path relative to the path of the executable.
That is still rather inconvenient. It would be more convenient to make
it relative to the source file, but the corresponding proc-macro span
source_file() accessor is not public/stable.
Perhaps there's a way of doing this also through the generated code and
std::file!().
2020-05-13 10:27:09 +02:00
Simon Hausmann
3aac8282a8
Allow passing string literals to string properties in Rust
...
In the Rust code generator, convert to a null terminated byte literal.
2020-05-13 10:01:19 +02:00
Olivier Goffart
7c2f40da90
Generator for the rust API
2020-05-12 11:43:29 +02:00
Olivier Goffart
b9cd725f78
Allow to use proc_macro tokens
...
And report errors
2020-05-11 22:24:28 +02:00
Olivier Goffart
dc33cbbcda
Dummy structure for the rust example
2020-05-11 20:39:16 +02:00