fix: stabilize web loading and paper rendering

This commit is contained in:
Hakan Seven committed 2026-07-25 21:34:29 +03:00
1 parent fe49cc8eb5
commit bca65600cd
25 files changed
+109 -62

No files matched your search

+1
View File
@@ -388,6 +388,7 @@ pub fn extract_to_png(input: &std::path::Path, output: &std::path::Path, size: u
/// Read a DWG's embedded preview and decode it to an iced image handle for the
/// Start page's recent-file thumbnails. `None` for DXF/other files, a missing
/// preview, or an undecodable format (WMF).
#[cfg(not(target_arch = "wasm32"))]
pub fn read_handle(path: &std::path::Path) -> Option<iced::widget::image::Handle> {
let img = dwg_thumbnailer::extract(path, MAX_DIM)?;
let (w, h) = (img.width(), img.height());