Task #700: 셀 paragraph cut 위치 vpos 정합 — compute_cell_line_ranges cum 절대 동기화#706
Open
planet6897 wants to merge 5 commits intoedwardkim:develfrom
Open
Task #700: 셀 paragraph cut 위치 vpos 정합 — compute_cell_line_ranges cum 절대 동기화#706planet6897 wants to merge 5 commits intoedwardkim:develfrom
planet6897 wants to merge 5 commits intoedwardkim:develfrom
Conversation
- mismatch 산술: line metric 누적 vs vpos 누적 ~50px 차이 (cell[11] p[19] 끝) - 한컴 PDF cut 위치 = p[16] 끝 (387.78px), abs_limit (459.7) 보다 72px 일찍 - pagination engine 의 split_end_content_limit 산출이 line metric 기반 = 한컴 vpos 단위와 mismatch - form-002 회귀 원인 분석: paragraph 사이 spacing vpos delta vs line metric mismatch - 정정 방향 3옵션 (A height_measurer / B layout y 보정 / C cum 동기화) 권고: C 우선
- compute_cell_line_ranges 의 cum 을 LINE_SEG.vpos 절대값으로 동기화 (차분 누적 X) - 셀별 가드: cell_first_vpos == 0 (한컴 정상 인코딩 케이스만 적용) - target_cum > cum 조건 — cum 만 전진 허용 - form-002 회귀 가드 — 차분 누적의 paragraph 사이 mismatch 회피 - 단위 테스트 3개 + 회귀 fixture 군 RMSE 검증
- paragraph 진입 시 cum 을 LINE_SEG.vpos 절대값으로 동기화 (전진만 허용) - 셀별 가드: cell_first_vpos == 0 (한컴 정상 인코딩 케이스만) - vpos 리셋 검출 + cum=abs_limit 강제 (Task edwardkim#697 통합) - 차분 누적 (delta) 대신 절대 동기화 — form-002 회귀 가드 검증: - cargo test --release 21 그룹 0 fail - inner-table-01.hwp p2 첫 줄 '- 전사 데이터 수집/유통체계 구축' 정상 ✓ - 회귀 fixture (form-002, k-water-rfp, issue_265, hwp3-sample) RMSE 동일 = 회귀 없음
- inner-table-01.hwp p2 첫 줄 '- 전사 데이터 수집/유통체계 구축' 정상 ✓ - 회귀 fixture (form-002, k-water-rfp, issue_265, hwp3-sample) RMSE 동일 - cargo test --release 21 그룹 0 fail - cell_first_vpos == 0 가드 + 절대 동기화로 form-002 회귀 가드 성공
inner-table-01.hwp p1 의 cell[10] '사업개요' 라벨이 split row 라는 이유만으로 Top 정렬 강제되어 PDF 정합과 어긋남. line_ranges 가 셀의 모든 line 을 visible 처리하면 (= 실제 split 영향 안 받은 cell) cell.vertical_align 보존. 검증: cargo test --release 21 그룹 통과, 시각: 사업개요 라벨이 cell 중앙 정렬.
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.
closes #700
요약
compute_cell_line_ranges의 cum 을 paragraph 진입 시 LINE_SEG.vpos 절대값으로 동기화하여 한컴 vpos 단위 abs_limit 와의 mismatch 정합화.결함
samples/inner-table-01.hwpcell[11] (사업개요, 26 paras) 의 cell-internal split 시:- 전사 데이터 수집/유통체계 구축(p[17]) 누락 → rhwp 가p[18]부터 표시변경
src/renderer/layout/table_layout.rs::compute_cell_line_ranges:가드:
cell_first_vpos == 0— 한컴 정상 인코딩 케이스만target_cum > cum— cum 만 전진 (감소 금지)시각 정합 ✓
p[19]끝p[16]끝 ✓p[18]p[17](- 전사 데이터 수집/유통체계 구축) ✓회귀 검증
cargo test --release전체 (21 그룹)tests/svg_snapshot.rs(form-002 포함)samples/hwpx/form-002.hwpxp1 (cell[73] paras=29)samples/k-water-rfp.hwp(18p)samples/issue_265.hwp/samples/hwp3-sample.hwp→ 회귀 없음.
관련
stream/devel이라 큰 셀 cross-page split 결함 — inner-table-01.hwp 셀 내부 vpos 리셋 인코딩 미반영 (한글 2022 PDF mismatch) #697 의 vpos 리셋 검출도 함께 포함산출물
mydocs/plans/task_m100_700.md— 수행 계획서mydocs/plans/task_m100_700_impl.md— 구현 계획서 (옵션 C)mydocs/working/task_m100_700_stage1.md— 정밀 진단mydocs/working/task_m100_700_stage3_1.md— 구현 결과mydocs/report/task_m100_700_report.md— 최종 보고서