diff options
author | bptato <nincsnevem662@gmail.com> | 2021-11-23 14:08:37 +0100 |
---|---|---|
committer | bptato <nincsnevem662@gmail.com> | 2021-11-23 14:08:37 +0100 |
commit | a413a3115f242395ef1149c263d3280e62f1608e (patch) | |
tree | 84d3d0e813f5695711a3e29dec3f74f9ddb6df52 /src/layout | |
parent | fbac38a0b0ce15954f8ba441a7a1adfb67dd8a80 (diff) | |
download | chawan-a413a3115f242395ef1149c263d3280e62f1608e.tar.gz |
Add margin to p, fix inline wrapping
Diffstat (limited to 'src/layout')
-rw-r--r-- | src/layout/engine.nim | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/layout/engine.nim b/src/layout/engine.nim index 6ca232b7..0fbaf882 100644 --- a/src/layout/engine.nim +++ b/src/layout/engine.nim @@ -116,7 +116,7 @@ proc processInlineBox(parent: CSSBox, str: string): CSSBox = ibox.context.whitespace = false fastRuneAt(str, i, r) rw = r.width() - if rowbox.width + r.width() > ibox.width: + if fromx + rowbox.width + r.width() > ibox.width: inlineWrap(ibox, rowi, fromx, rowbox) rowbox.width += rw |