Commit graph

15 commits

Author SHA1 Message Date
Michael Aaron Murphy
8cf372c9b9
perf: inline public getters/setters, and use non-generic inner functions
To reduce compile-times and avoid some overhead to binary size, this will modify some of our
generic functions to use non-generic inner functions where possible. The inner functions are
marked carefully with `#[inline(never)]` to prevent being inlined by LLVM at their callsites

While looking for generic functions to optimize, I have also taken the opportunity to annotate
public non-generic getters and setters with `#[inline]` to ensure that LLVM will inline them
across crate boundaries. By default, only generic functions are automatically inlined, and
only when enabling fat LTO are constant functions reliably inlined across crate boundaries.
2025-03-21 13:31:34 +01:00
Ashley Wulber
337b80d4ca
feat: Tooltips and Better Surface Management 2025-03-14 16:56:21 +01:00
Ashley Wulber
0491c4baaa libcosmic updates 2024-10-18 14:04:39 -04:00
Michael Aaron Murphy
9e064e7fa0 feat: configurable fonts 2024-10-05 01:47:37 +02:00
Michael Aaron Murphy
f12de010ec fix!(widget): rename button function to button::custom 2024-09-16 11:36:42 -06:00
Victoria Brekenfeld
b40839638a fix: Use globals instead of thread-locals
Better support for multi-threaded applications,
especially cosmic-comp rendering in parallel on
multiple threads, each potentially accessing
global configurations such as the active theme,
icon_theme and more...
2024-08-02 20:27:08 +02:00
Michael Aaron Murphy
f4936344f0
chore(doc): add documentation for a handful of widgets 2024-05-20 20:01:47 +02:00
Michael Aaron Murphy
9e6d94c7eb
fix(button): use correct paddings for icon buttons 2024-03-15 22:38:49 +01:00
Ashley Wulber
e47684ffdb refactor: icon styling and headerbar icon styling
Headerbar icons are transparent when their window is not focused, but otherwise share the same style as icons with selection. This updates the icon styles to match figma when selected.
2024-03-11 16:26:48 -04:00
Michael Aaron Murphy
78647db0ea chore(widget): set Button width and height with impl Into 2023-09-19 17:22:20 +02:00
Michael Aaron Murphy
b404497e76
fix(widget): allow None for button text color to inherit from container 2023-09-18 08:28:57 +02:00
Michael Aaron Murphy
c2d62bad52 fix(button): icon style variant to inherit colors from container 2023-09-14 01:38:56 +02:00
Michael Aaron Murphy
2e11d62de5 feat(widget): custom style variant for button widget 2023-09-14 01:38:56 +02:00
Michael Aaron Murphy
9dbc1be269 refactor(widget): improvements to button and icon widgets 2023-09-14 01:38:56 +02:00
Michael Aaron Murphy
4e4eeaac12 feat!(widget): rewrite button & icon widget APIs 2023-09-14 01:38:56 +02:00