生成器:实测尺寸取整显示,去掉面板里放不下的源图尺寸

This commit is contained in:
tamakyi
2026-10-20 17:53:10 +08:00
parent 4bd600fb46
commit 1b027df62e
+3 -2
View File
@@ -1226,9 +1226,10 @@ function renderLayerEditor(l){
tip.className = 'hint';
if (over.length){
tip.style.color = '#e0a33e';
tip.textContent = `⚠ ${vp.w}×${vp.h}:${over.join(' / ')} 越界(显示 ${m.w}×${m.h})`;
tip.textContent = `⚠ ${vp.w}×${vp.h}:${over.join(' / ')} 越界`;
} else {
tip.textContent = `${vp.w}×${vp.h} 下显示 ${m.w}×${m.h},完整可见(源 ${a0.w}×${a0.h})`;
// 一律取整:131.25 这种小数在窄面板里既占位置又没意义
tip.textContent = `${vp.w}×${vp.h} 下显示 ${Math.round(m.w)}×${Math.round(m.h)},完整可见`;
}
box.appendChild(tip);
if (over.length){