Tooltips in a window are popups beside their widget, theme SVGs with plus-lighter highlights are no longer painted grey, and the folder-files icon is shaped as a folder
CI / build + test (push) Canceled after 0s
CI / cargo audit (push) Canceled after 0s

A tooltip was a layer-shell surface spanning the output, placed at the coordinates of its widget in the main surface. In a layer-shell shell the two share an origin, but an xdg-shell window does not know where it sits on screen, so in a window the tooltip appeared shifted by the window's position, wherever that put it. The application icons of the default theme, exported from Figma, light their glass with `feBlend mode="plus-lighter"`, which resvg does not know and paints as `normal`, so the highlights came out as grey edges; at dock size those edges cover whole pixels and the icon looks dirty. And `archives/folder-files`, the icon applications show for a folder, was a clipboard and a sheet rather than a folder.
Tooltips. `tooltip_popup` tells when the tooltip must be an xdg-popup, that is when the main surface is a window and the widget is on it, and gives its anchor rect and logical size. `reconcile_overlays` then creates the tooltip's overlay as a popup child of the window, anchored to the widget's rect, above it with a 6 px gap (`TOOLTIP_GAP`), flipped below or slid sideways when it does not fit, so the compositor puts it beside the widget. It takes no grab and keeps the empty input region, so it never takes the pointer from the widget it describes. Its view is the pill centred in the popup. Layer-shell surfaces keep the previous placement, now in `tooltip_on_screen`. `tooltip_id` and `tooltip_size` hold the id and the estimated size both paths share. `OverlaySpec` is unchanged, so applications that build overlays need no change.
Blend modes. `decode_svg_bytes` replaces `plus-lighter` with `screen`, the closest mode resvg supports, before parsing; a document without it is parsed as it comes, without a copy. A test covers both cases.
The folder icon. Both variants of `archives/folder-files` are now the outline of `folder-empty` with the sheet of the previous icon inside, placed and sized as the lock of `folder-locked`: drawn in strokes in `line`, cut out of the filled folder in `filled`.
This commit is contained in:
2026-10-15 10:32:50 +02:00
parent dcb1c7dff3
commit 312fb7e0fd
5 changed files with 133 additions and 34 deletions
@@ -1,8 +1,8 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 23.428 23.420" fill="none">
<g transform="translate(-468.286 -5092.290)" fill="#000000">
<path d="M489.214 5103.21C489.214 5102.9 488.958 5102.64 488.643 5102.64H480.786C480.47 5102.64 480.214 5102.9 480.214 5103.21V5112.64C480.214 5112.96 480.47 5113.21 480.786 5113.21H488.643C488.958 5113.21 489.214 5112.96 489.214 5112.64V5103.21ZM491.214 5112.64C491.214 5114.06 490.063 5115.21 488.643 5115.21H480.786C479.365 5115.21 478.214 5114.06 478.214 5112.64V5103.21C478.214 5101.79 479.365 5100.64 480.786 5100.64H488.643C490.063 5100.64 491.214 5101.79 491.214 5103.21V5112.64Z"/>
<path d="M487.071 5105.36C487.623 5105.36 488.071 5105.8 488.071 5106.36C488.071 5106.91 487.623 5107.36 487.071 5107.36H482.357C481.805 5107.36 481.357 5106.91 481.357 5106.36C481.357 5105.8 481.805 5105.36 482.357 5105.36H487.071Z"/>
<path d="M487.071 5108.5C487.623 5108.5 488.071 5108.95 488.071 5109.5C488.071 5110.05 487.623 5110.5 487.071 5110.5H482.357C481.805 5110.5 481.357 5110.05 481.357 5109.5C481.357 5108.95 481.805 5108.5 482.357 5108.5H487.071Z"/>
<path d="M479.607 5092.79C479.915 5092.79 480.207 5092.93 480.396 5093.17C480.585 5093.41 480.652 5093.73 480.577 5094.03L480.494 5094.36H480.786C481.467 5094.36 482.122 5094.63 482.604 5095.11C483.086 5095.59 483.357 5096.25 483.357 5096.93V5098.5C483.357 5099.05 482.909 5099.5 482.357 5099.5C481.805 5099.5 481.357 5099.05 481.357 5098.5V5096.93C481.357 5096.78 481.297 5096.63 481.19 5096.52C481.083 5096.42 480.937 5096.36 480.786 5096.36H479.988L479.932 5096.58C479.839 5096.96 479.621 5097.3 479.311 5097.55C478.997 5097.79 478.609 5097.93 478.208 5097.93L473.934 5097.93C473.534 5097.93 473.145 5097.79 472.832 5097.55C472.522 5097.3 472.304 5096.96 472.211 5096.58L472.156 5096.36H471.357C471.205 5096.36 471.06 5096.42 470.953 5096.52C470.846 5096.63 470.786 5096.78 470.786 5096.93V5107.93C470.786 5108.08 470.846 5108.23 470.953 5108.33C471.06 5108.44 471.206 5108.5 471.357 5108.5H475.286C475.838 5108.5 476.285 5108.95 476.286 5109.5C476.286 5110.05 475.838 5110.5 475.286 5110.5H471.357C470.675 5110.5 470.021 5110.23 469.539 5109.75C469.056 5109.26 468.786 5108.61 468.786 5107.93V5096.93C468.786 5096.25 469.056 5095.59 469.539 5095.11C470.021 5094.63 470.675 5094.36 471.357 5094.36H471.649L471.566 5094.03C471.49 5093.73 471.557 5093.41 471.747 5093.17C471.936 5092.93 472.227 5092.79 472.536 5092.79H479.607ZM474.109 5095.93H478.034L478.323 5094.79H473.82L474.109 5095.93Z"/>
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 23.428 22.650" fill="none">
<g transform="translate(-364.286 -5092.670)" fill="#000000">
<path d="M364.786 5112.25V5095.75C364.786 5095.07 365.056 5094.41 365.539 5093.93C366.021 5093.45 366.675 5093.18 367.357 5093.18H373.156C373.733 5093.17 374.297 5093.35 374.757 5093.7C375.224 5094.06 375.556 5094.56 375.697 5095.13L375.995 5096.32H384.643C385.325 5096.32 385.979 5096.59 386.461 5097.07C386.943 5097.56 387.214 5098.21 387.214 5098.89V5112.25C387.214 5112.93 386.943 5113.59 386.461 5114.07L386.46 5114.07C385.978 5114.55 385.325 5114.82 384.643 5114.82H367.357C366.675 5114.82 366.021 5114.55 365.539 5114.07C365.056 5113.59 364.786 5112.93 364.786 5112.25ZM366.786 5112.25C366.786 5112.4 366.846 5112.55 366.953 5112.65L366.954 5112.65C367.061 5112.76 367.205 5112.82 367.357 5112.82H384.643C384.795 5112.82 384.94 5112.76 385.046 5112.65L385.119 5112.57C385.181 5112.47 385.214 5112.36 385.214 5112.25V5098.89C385.214 5098.74 385.154 5098.6 385.046 5098.49C384.939 5098.38 384.794 5098.32 384.643 5098.32H375.214C374.755 5098.32 374.355 5098.01 374.244 5097.56L373.757 5095.62L373.756 5095.61C373.725 5095.49 373.651 5095.37 373.547 5095.29C373.443 5095.21 373.315 5095.17 373.185 5095.18C373.175 5095.18 373.165 5095.18 373.156 5095.18H367.357C367.205 5095.18 367.06 5095.24 366.953 5095.35C366.846 5095.45 366.786 5095.6 366.786 5095.75V5112.25Z"/>
<path d="M379.375 5102.034C379.375 5101.801 379.183 5101.606 378.947 5101.606H373.054C372.817 5101.606 372.625 5101.801 372.625 5102.034V5109.106C372.625 5109.346 372.817 5109.534 373.054 5109.534H378.947C379.183 5109.534 379.375 5109.346 379.375 5109.106V5102.034ZM380.875 5109.106C380.875 5110.171 380.012 5111.034 378.947 5111.034H373.054C371.988 5111.034 371.125 5110.171 371.125 5109.106V5102.034C371.125 5100.969 371.988 5100.106 373.054 5100.106H378.947C380.012 5100.106 380.875 5100.969 380.875 5102.034V5109.106Z"/>
<path d="M377.768 5103.646C378.182 5103.646 378.518 5103.976 378.518 5104.396C378.518 5104.809 378.182 5105.146 377.768 5105.146H374.232C373.818 5105.146 373.482 5104.809 373.482 5104.396C373.482 5103.976 373.818 5103.646 374.232 5103.646H377.768Z"/>
<path d="M377.768 5106.001C378.182 5106.001 378.518 5106.339 378.518 5106.751C378.518 5107.164 378.182 5107.501 377.768 5107.501H374.232C373.818 5107.501 373.482 5107.164 373.482 5106.751C373.482 5106.339 373.818 5106.001 374.232 5106.001H377.768Z"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.4 KiB

After

Width:  |  Height:  |  Size: 2.4 KiB