docs(cursor): explain outline alignment and Linux density scope

This commit is contained in:
fufesou
2026-09-12 20:51:59 +08:00
parent 02e4f02815
commit 4d064a8445
2 changed files with 6 additions and 0 deletions

View File

@@ -35,6 +35,10 @@ use std::{
use terminfo::{capability as cap, Database};
use wallpaper;
// Scope density lookup to Flutter host builds to preserve legacy capture
// behavior. These builds include density in cursor IDs to refresh on DPI
// changes; non-Flutter builds retain original IDs and unknown density.
// This gate describes the host binary, not the connected controller's UI.
#[cfg(feature = "flutter")]
mod cursor;

View File

@@ -413,6 +413,8 @@ extern "C"
{
auto in = in0;
auto out0_end = out0 + out0_size;
// The output adds a pixel on each side; place the source at (1, 1)
// using the padded stride to match the caller's hotspot +1 adjustment.
auto offset = (width + 2) * 4 + 4;
auto out = out0 + offset;
for (int y = 0; y < height; y++)