Task #295: exam_math.hwp 12쪽 좌단 레이아웃 붕괴 수정#298
Merged
Conversation
…#295) `layout_table_item`의 out-of-flow 분기를 vert=Page 및 본문 아래(꼬리말) 영역까지 확장하여 페이지 하단 푸터 표가 in-flow로 처리되며 후속 본문이 페이지 하단으로 밀려 LAYOUT_OVERFLOW를 일으키던 문제를 해소. 부수: Square wrap 표의 halign 반영, 자가 wrap host 본문 렌더링 가드 제거, 호스트 본문 다중 줄 렌더링 복원. - LAYOUT_OVERFLOW: 18건 → 0건 (12쪽 + 전체 샘플) - cargo test --release: 1028 passed / 0 failed - 우측 컬럼 단락 높이 과대 별건은 #297로 분리
Owner
|
잠 좀 자볼까 했는데 ... 열심히 리뷰하겠습니다. |
# Conflicts: # mydocs/orders/20260424.md
edwardkim
approved these changes
Apr 24, 2026
edwardkim
left a comment
Owner
There was a problem hiding this comment.
Approved. 🎉
@planet6897 님, exam_math.hwp 12쪽 좌단 붕괴 수정 완료 감사합니다.
평가 포인트
- 루트 원인 정확 —
renders_above_body함수가vert=Paper+ '본문 위' 케이스만 out-of-flow 처리.vert=Page valign=Bottom푸터 표가 in-flow 로 처리되어 y_offset 점프 → 후속 좌단 콘텐츠 붕괴 - 의미있는 묶음 수정 — 좌단 붕괴 수정 후 드러난 잔여 3문제(halign, 자가 wrap host, 다중 줄)를 일괄 처리. 각 수정이 서로 의존적이라 묶음 처리가 타당
- 데이터 기반 범위 제어 — #297 (우측 컬럼 단락 높이) 을 좌표 비교(수정 전/후 동일 147.4..497.3)로 '사전 존재 버그' 확정 후 분리. 범위 확장 유혹 방지
- 검증 광범위 — cargo test --release 1028, 4개 샘플 LAYOUT_OVERFLOW 0건, 시각 비교 PNG 3면
메인테이너 검증
| 항목 | 결과 |
|---|---|
| cargo test --lib (merge 시뮬레이션) | ✅ 992 / 0 / 1 ignored |
| cargo test --test svg_snapshot | ✅ 6 / 0 (golden 유지) |
| cargo test --test tab_cross_run | ✅ 1 / 0 (#290 회귀 없음) |
| cargo clippy / wasm32 | ✅ clean |
| CI (원본) | ✅ 전부 SUCCESS |
| exam_math.hwp 12쪽 LAYOUT_OVERFLOW | ✅ 0건 (작성자 주장 일치) |
| exam_math.hwp 전체 / exam_math_no / equation-lim | ✅ 0건 |
| WASM Docker 빌드 + rhwp-studio 브라우저 시각 검증 | ✅ 12쪽 좌단 정상 (작업지시자 확인) |
처리 절차
- orders 문서 충돌(Task #295 vs #296 섹션 배치) 메인테이너 직접 해결
- planet6897/task295 에 push (09261b8..d53572e)
- 재승인 + admin merge
후속
Merge 진행합니다.
edwardkim
added a commit
that referenced
this pull request
Apr 24, 2026
edwardkim
added a commit
that referenced
this pull request
Apr 24, 2026
#295) - 작성자: @planet6897 (Task #295, PR #298, 오늘 5번째 기여) - Merge commit: 42ae6ff (admin merge, orders 문서 충돌 직접 해결) - 이슈 #295 CLOSED 처리 절차: - PR 브랜치에 origin/devel 머지 → orders 섹션 재배치 (#295 "## 7", #296 "## 8") - planet6897/task295 에 push (maintainerCanModify 허용) - WASM Docker 빌드 + rhwp-studio 브라우저 시각 검증 성공 - 재승인 + admin merge 변경 (1 file): - src/renderer/layout.rs +40 -20: 1. renders_above_body → renders_outside_body 확장 (vert=Paper|Page, above|below body) 2. Square wrap 표 halign 반영 (Left/Right/Center/Outside) 3. 어울림 호출 가드 제거 (wrap_around_paras.is_empty()) 4. 호스트 본문 다중 줄 렌더링 복원 (첫 줄 → rposition) 성과: - 12쪽 LAYOUT_OVERFLOW: 18건 → 0건 - 4개 샘플 (exam_math/exam_math_no/equation-lim/text-align-2) LAYOUT_OVERFLOW: 0건 검증: - cargo test --lib: 992 passed - svg_snapshot: 6 passed (golden 유지) - clippy + wasm32 check: clean - WASM 빌드 + 브라우저 시각 검증: 작업지시자 판정 성공 후속 추적: - #297 (우측 컬럼 단락 높이 과대, #295 에서 분리된 사전 존재 버그) Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 tasks
edwardkim
added a commit
that referenced
this pull request
Apr 24, 2026
#297) - 작성자: @planet6897 (Task #297, PR #300, 오늘 6번째 기여) - Merge commit: 0e3fb02 (admin merge, orders 3구간 충돌 직접 해결) - 이슈 #297 CLOSED 처리 절차: - PR 브랜치에 origin/devel 머지 → orders 섹션 3구간 해결 (#295 "## 7", #296 "## 8", #297 "## 9") - planet6897/task297 에 push - 재승인 + admin merge 변경 (1파일): - src/renderer/layout/table_layout.rs +5 -2: - VertRelTo::Page => (col_area.y, col_area.height) [쪽 본문 영역] - VertRelTo::Paper => (0, page_h_approx) [용지 전체, 유지] - HWP 스펙 Page=쪽 본문, Paper=용지 전체 반영 성과: - pi=22 "* 확인 사항" 박스 y: 1371.5 → 1224.07 (PDF 1226.5 ±2 일치) - 145 샘플 중 본문 Page 표 13건 + 바탕쪽 5건 회귀 스캔 완료 (의도 범위 외 무회귀) 검증: - cargo test --lib: 992 passed - svg_snapshot: 6 passed (golden 유지) - 실제 SVG y 좌표 확인: 1224.07px (PDF 일치) #295 → #297 연결 모범 사례: PR #298 리뷰 중 사전 존재 버그로 분리 → 1시간 만에 PR #300 해결. 초기 가설(바탕쪽 Paper) 폐기 → pdftotext 실측으로 근본 원인(enum 미구분) 발견 → 1줄 수정. ===== 오늘 9번째 PR 머지 ===== #284 #285 #266 #273 #277 #278 #289 #292 #298 #300 + 메인테이너 핀셋 #296 Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
edwardkim
added a commit
that referenced
this pull request
Apr 25, 2026
samples/basic/KTX.hwp 1페이지 2단 구성에서 오른쪽 단의 TAC 표 (pi=31 16x15, pi=32 10x9) 가 단의 좌측 끝에 붙어 렌더되던 회귀 수정. 한컴 PDF 는 단의 우측 정렬. 근본 원인: src/renderer/layout.rs::layout_columns 의 표 위치 계산 (tbl_inline_x): - 비-TAC + Square wrap 분기는 Task #295 (PR #298) 에서 horz_align 반영 - 그러나 TAC 분기는 ParaShape alignment 무시 → align=Right/Center 인 TAC 표가 단/문단 좌측에 강제 정렬 KTX.hwp pi=31 (TAC, align=Right): - 한컴 기대: x=518.56 (단 우측 정렬) - rhwp: x=494.10 (단 좌측 강제) - 차이: 24.46px (6.5mm) 수정 (src/renderer/layout.rs +15줄): - TAC 분기에 ParaShape alignment 매치 추가 - Right → col_area.x + col_area.width - tbl_w - margin_right - Center → col_area.x + (col_area.width - tbl_w) / 2.0 - 기타 (Justify/Left/...) → 기존 base_x 유지 - .max(base_x) 안전장치로 leading 보존 (TAC 표 앞에 텍스트 있는 경우) 검증: - cargo test --lib: 992 passed (golden 무회귀) - svg_snapshot 6 / issue_301 1 / tab_cross_run 1 모두 통과 - clippy + wasm32 check: clean - 5샘플 byte-diff: - KTX.hwp: 1/1 (의도된 수정) - exam_math: 0/20 (무영향) - 21_언어: 0/19 (무영향) - aift.hwp: 18/74 (모두 align=Center/Right TAC 표의 의도된 개선) - biz_plan: 1/6 (의도된 개선) - WASM Docker 빌드 + 브라우저 시각 검증: 작업지시자 판정 성공 부가 성과: KTX 외 aift.hwp 18페이지 + biz_plan.hwp 1페이지 = 총 20개 페이지 의 TAC 표 정렬 개선 (제보 안 된 잠재 회귀 함께 해소). 산출물: - mydocs/plans/task_m100_291{,_impl}.md - mydocs/working/task_m100_291_stage{1,2,3}.md - mydocs/report/task_m100_291_report.md - mydocs/troubleshootings/tac_table_para_align.md (재발 방지) - mydocs/orders/20260425.md 갱신 후속 이슈 후보 (별도 분리): - t.common.horz_align 과 ParaShape alignment 우선순위 정립 Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
samples/exam_math.hwp12쪽 다단 레이아웃에서 좌측 컬럼 본문(29번 문제)이 페이지 하단으로 밀려 압축·겹침 발생하던 문제 해소 (closes exam_math.hwp 12쪽 좌단 레이아웃 붕괴 (다단 + 표 오버플로) #295)vert=Page valign=Bottom앵커)가 in-flow로 처리되어y_offset이 푸터 위치(≈y=1371)로 점프하던 것이 근본 원인변경 내용 (
src/renderer/layout.rs)renders_outside_body(≈1995)tbl_y < body.y || tbl_y + tbl_h > body_bottomis_outside_body(≈2103)tbl_inline_xSquare 분기 (≈1978)wrap_around_paras비어 있어도 호출 → 자가 wrap host 처리layout_wrap_around_paras호스트 텍스트 (≈2509)검증
cargo test --releaseTest plan
cargo test --release전체 통과 (1028 passed / 0 failed)samples/exam_math.hwp전체 export-svg → LAYOUT_OVERFLOW 0건samples/exam_math_no.hwp전체 export-svg → LAYOUT_OVERFLOW 0건samples/equation-lim.hwp,samples/text-align-2.hwp회귀 0건exam_math.hwp1쪽(머리말 vert=Page 표 + 풋터) 정상 유지exam_math.hwp12쪽 좌단 시각 비교 (PDF vs before vs after)후속 이슈 (분리)
참고 문서
mydocs/plans/task_m100_295{,_impl}.mdmydocs/working/task_m100_295_stage{1,3,4}.mdmydocs/report/task_m100_295_report.mdmydocs/working/task_m100_295_p12_{pdf,before,after}.png(시각 비교)