Key fixes: - Skip large vector_graphics charts (>50% page coverage) that cover text - Fix font fallback to use NotoSansSC for CJK support instead of Helvetica - Improve translated table rendering with dynamic font sizing - Add merged cell (row_span/col_span) support for reflow tables - Skip text elements inside table bboxes to avoid duplication Archive openspec proposal: fix-pdf-table-rendering 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
1022 B
1022 B
Tasks: Fix PDF Table Rendering
1. Translated Layout PDF - Table Fix (P0)
- 1.1 Refactor
_draw_translated_table()to use layered rendering approach - 1.2 Use
cell_boxesfrom metadata for accurate border positioning - 1.3 Render translated text within each cell's bbox using Paragraph with wordWrap
- 1.4 Handle text overflow (shrink font to minimum 8pt or truncate)
- 1.5 Draw embedded images at correct positions
2. Reflow PDF - Table Fix (P1)
- 2.1 Fix
_create_reflow_table()cell extraction from content dict - 2.2 Add row_span/col_span handling using ReportLab SPAN style
- 2.3 Calculate proportional column widths based on cell_boxes
- 2.4 Embed images in table cells instead of after table
3. Testing & Validation
- 3.1 Test with task 48b9e849-f6e3-462f-83a1-911ded701958 (has merged cells)
- 3.2 Verify translated layout PDF has visible borders
- 3.3 Verify reflow PDF tables align correctly
- 3.4 Verify embedded images appear in both formats