Commit graph

944 commits

Author SHA1 Message Date
Ashley Wulber
e8d53b14ea chore: various fixes and some cleanup 2026-03-04 12:04:32 -05:00
Ashley Wulber
e10459fb37 wip rebase updates 2026-03-04 12:04:32 -05:00
Hojjat Abdollahi
bd1d3d5a73
fix: ellipsize headerbar title instead of wrapping (#1140) 2026-03-02 12:01:19 -07:00
Michael Aaron Murphy
a37be90e81 fix(single-instance): unminimize main window on dbus activate 2026-02-24 16:02:56 +01:00
Alex Marín
384e8f6e21
fix(segmented_button): clear bold button text on context menu close 2026-02-20 12:06:45 +01:00
Hojjat Abdollahi
b9bd773940
feat: ellipsize text (#1132) 2026-02-19 10:06:45 -07:00
mariinkys
c1c09624bd fix: right-clicking any sidebar item makes all sidebar items bold 2026-02-19 16:43:56 +01:00
Vukašin Vojinović
cb288070af chore: cargo fmt 2026-02-17 21:18:55 +01:00
Vukašin Vojinović
990e2e291b refactor(calendar): use jiff instead of chrono
This refactors the calendar widget to use `jiff` instead of `chrono`.
Also mostly matches the design of the widget to the time applet.
2026-02-17 21:18:55 +01:00
Frieder Hannenheim
21c5a4f34a
feat(dnd_destination): xdg file transfer portal support
Requires the `xdg-portal` feature to be enabled to use these features.

- Adds `DndDestination::on_file_transfer` method to handle `application/vnd.portal.filetransfer` drop requests
- Adds `command::file_transfer_receive` function to handle the file transfer request messages
- Adds `command::file_transfer_send` to initiate a file transfer from the application
2026-02-16 16:41:35 +01:00
Michael Aaron Murphy
031818c6b0
fix(font): explicitly drop read guard in on font family lookup 2026-02-13 18:30:14 +01:00
Michael Aaron Murphy
ae830ca21d
perf(font): use RwLock when getting fonts instead of Mutex 2026-02-12 15:52:40 +01:00
Michael Aaron Murphy
a3cf875793
fix(single-instance): unminimize main window on dbus activate 2026-02-09 22:04:13 +01:00
Ashley Wulber
fdcba7d8ec fix(segmented_button): dnd hover 2026-01-29 00:07:00 +01:00
Vukašin Vojinović
b71a7c9edf improv: remove double coloring of content_container windows
This sets the main content and the header bar to transparent when `content_container` is true, so that things aren't colored twice and overlayed on top of each other.
This ensures that modifying color alpha behaves as expected, especially for frosted glass.
2026-01-27 18:07:35 -07:00
Ashley Wulber
9fcd449611 fix(segmented_button): hover state handling
when hover state changes, paragraphs also need to be updated. I'll make a not to check this again after the rebase though.
2026-01-27 14:10:04 -05:00
Ashley Wulber
927035809f refactor(segmented button): only clear tab drag after source event cancel or finish 2026-01-24 00:53:30 +01:00
Ashley Wulber
beddbf1770 improv(segmented_button): dnd state handling 2026-01-22 10:26:58 -05:00
Ashley Wulber
d71c42102d fix(segmented button): tab dnd 2026-01-22 02:11:08 +01:00
vacenty
689f25be53
feat(spin_button): when value is min/maxed, disable decrease/increase button 2026-01-21 14:08:25 +01:00
Jonatan Pettersson
3e6c9a6add feat: add optional placeholder text to dropdown 2026-01-16 08:50:58 -07:00
Michael Aaron Murphy
b0cbb54bf2
chore(widget): remove unused RcWrapper method 2026-01-13 17:01:57 +01:00
Michael Aaron Murphy
f000433690
fix(spin_button): compiler error on build without a11y 2026-01-13 17:01:27 +01:00
Michael Aaron Murphy
b9c24d2421 feat(a11y): screen reader name and description support for button widgets 2026-01-09 23:35:28 +01:00
Michael Aaron Murphy
421552dea1
fix!(desktop): IconSourceExt::as_cosmic_icon should return Handle with SVG preference 2026-01-06 02:25:46 +01:00
Ashley Wulber
dd3610b8ae fix(dnd_destination): layout for dnd rectangle children 2025-12-19 16:05:40 -05:00
Ian Douglas Scott
2f0b333491 Add helper for accumulating scroll into discrete delta
This converts `ScrollDelta::Pixels` and `ScrollDelta::Lines` into
integer values, accumulating partial scrolls until a full integer is
reached.

It also has a configurable rate-limit, so discrete integer events can
occur at a certain maximum frequency. This may need tuning for different
use cases, though I haven't tried using it for things other than
changing workspaces so far.
2025-12-06 20:00:59 -08:00
Michael Aaron Murphy
f39ad728c9
examples(calendar): update and fix compile 2025-12-05 17:29:11 +01:00
Michael Aaron Murphy
cdf4eafc9e
fix(segmented_button): set icon to symbolic 2025-12-05 17:18:26 +01:00
Michael Aaron Murphy
6793950bbc
fix(icon): from_svg_bytes should not default to symbolic 2025-12-05 17:16:35 +01:00
Michael Aaron Murphy
e13ab24151
revert: "fix(popover): match popup styling to designs"
Some application popovers required the previous behavior

This reverts commit 882481e518.
2025-12-05 16:46:23 +01:00
Michael Aaron Murphy
866da0f94b
revert: "fix(popover): set default position to Bottom"
Causes popups to be misplaced in applications that required the previous
behavior.

This reverts commit 18182e5f97.
2025-12-05 16:44:39 +01:00
Kyle Scheuing
80875d5962
fix: compiling on windows requires cosmic-icons in project root
* fix: compiling on windows requires cosmic-icons in project root

crabtime provides crabtime::WORKSPACE_PATH to refer to the
CARGO_MANIFEST_DIR of the top level crate being built, which means when
building libcosmic directly, crabtime::WORKSPACE_PATH will work, but
when building it as a dependency of another crate,
crabtime::WORKSPACE_PATH will no longer refer to the path to libcosmic.

I don't think there's a good workaround, since when in the context of
crabtime, CARGO_MANIFEST_DIR refers to the path to the crate generated
by crabtime rather than to libcosmic.

This replaces crabtime with a simple build.rs script that generates a
file in OUT_DIR.

* fix: do not generate icon bundle for unix targets

---------

Co-authored-by: Michael Aaron Murphy <michael@mmurphy.dev>
2025-12-04 17:31:47 +01:00
Vukašin Vojinović
18182e5f97 fix(popover): set default position to Bottom
I didn't see this part in my previous PR (sorry!).
2025-12-02 18:03:05 +01:00
Vukašin Vojinović
882481e518 fix(popover): match popup styling to designs 2025-12-02 16:37:20 +01:00
Kyle Scheuing
62f661e077 fix: compile errors on windows
calendar.rs had some left over icon! macro_rules macros referencing now
deleted files.

bundle::get was defined twice on non-unix platforms.

A known remaining issue is that projects using libcosmic need to have
cosmic-icons in their project root, since the crabtime macro uses
crabtime::WORKSPACE_PATH rather than the path to wherever cargo puts
libcosmic's git submodule.

See: 639326fcc3
2025-11-26 15:39:32 -05:00
Michael Aaron Murphy
639326fcc3 feat(icon): optimize & bundle icons with crabtime for non-unix platforms 2025-11-21 18:37:49 +01:00
Stephan Buys
ce0868582b tests: fix env guard and pipe read for tab dnd 2025-11-20 22:33:13 +01:00
Stephan Buys
7f321cb0a3 segmented button: support tab drag + drop 2025-11-20 22:33:13 +01:00
Michael Aaron Murphy
fc85fcac3e fix(dropdown): refresh popup when selections change 2025-11-18 19:03:23 +01:00
Michael Aaron Murphy
7eecbe30d7 feat(dropdown): add Id support with custom close, open operations 2025-11-18 19:03:23 +01:00
Stephan Buys
690f1d331d
feat(desktop): add DesktopEntryCache and unit tests for known problematic entries 2025-11-13 16:02:12 +01:00
Ashley Wulber
2296e8e94d
feat(applets): configurable applet overlap and padding increases 2025-11-11 21:04:09 +01:00
Cheong Lau
bc744bd4e3
fix(segmented_button): use less restrictive FnOnce for builder method over Fn 2025-11-11 17:18:38 +01:00
Michael Aaron Murphy
6439507aa2
fix(icon): default to prefer_svg if symbolic 2025-11-06 07:57:03 +01:00
Vukašin Vojinović
37ae722320 fix(context_drawer): match to designs 2025-11-06 07:33:31 +01:00
Vukašin Vojinović
b6c6d1cb7b improv(context_drawer): move title out of header row
This moves the title below the header row containing actions and the close button, allowing more room for the title and actions.
Also makes actions an `Element` instead of a `Vec<Element>`, providing more flexibility for developers.
2025-11-04 16:58:33 +01:00
Ashley Wulber
a1b64dde3e fix(input): handle ctrl shortcuts with caps lock 2025-10-27 13:22:05 -04:00
Ashley Wulber
0c6c85429e
chore: update iced (#1029) 2025-10-27 16:24:02 +01:00
UchiWerfer
e49a30104b added localization for month and weekday to calendar-widget 2025-10-22 04:31:38 +02:00