about summary refs log tree commit diff stats
path: root/src
diff options
context:
space:
mode:
authorbptato <nincsnevem662@gmail.com>2024-06-23 13:14:49 +0200
committerbptato <nincsnevem662@gmail.com>2024-06-23 13:14:49 +0200
commit5f6e6630bf853550b09388c75d605da376adc88a (patch)
treec67f07530639bb393548516ea080c1356fd876a0 /src
parent8b517a111d6020f448ff747ac4a2555d2e4160dc (diff)
downloadchawan-5f6e6630bf853550b09388c75d605da376adc88a.tar.gz
layout: get rid of incorrect hack
Diffstat (limited to 'src')
-rw-r--r--src/layout/engine.nim2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/layout/engine.nim b/src/layout/engine.nim
index b40f15d4..e8f8a02b 100644
--- a/src/layout/engine.nim
+++ b/src/layout/engine.nim
@@ -899,7 +899,7 @@ proc resolveContentWidth(sizes: var ResolvedSizes; widthpx: LayoutUnit;
   let total = widthpx + sizes.margin[dtHorizontal].sum() +
     sizes.padding[dtHorizontal].sum()
   let underflow = parentWidth.u - total
-  if isauto or sizes.space.w.t == scFitContent:
+  if isauto:
     if underflow >= 0:
       sizes.space.w = SizeConstraint(t: sizes.space.w.t, u: underflow)
     else: