Bug 80308 - poppler_structure_element_get_table_{row,column}_span() apply to cell elements; not table elements
Summary: poppler_structure_element_get_table_{row,column}_span() apply to cell element...
Status: RESOLVED MOVED
Alias: None
Product: poppler
Classification: Unclassified
Component: glib frontend (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: poppler-bugs
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: tagged-pdf
  Show dependency treegraph
 
Reported: 2014-06-20 19:30 UTC by Joanmarie Diggs
Modified: 2018-08-21 10:45 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
proposed patch (2.86 KB, patch)
2014-06-20 19:30 UTC, Joanmarie Diggs
Details | Splinter Review

Description Joanmarie Diggs 2014-06-20 19:30:14 UTC
Created attachment 101452 [details] [review]
proposed patch

As per the PDF spec, cell elements (TD and TH) have row and column spans. But poppler_structure_element_get_table_row_span() and poppler_structure_element_get_table_column_span() each expect a table element -- which of course has no span attributes defined and thus the default value of 1 (as per the spec) is always returned by these methods. (Unless of course you ask for the spans of a cell in which case you get an error.)
Comment 1 Carlos Garcia Campos 2014-06-23 15:46:38 UTC
(In reply to comment #0)
> Created attachment 101452 [details] [review] [review]
> proposed patch
> 
> As per the PDF spec, cell elements (TD and TH) have row and column spans.
> But poppler_structure_element_get_table_row_span() and
> poppler_structure_element_get_table_column_span() each expect a table
> element -- which of course has no span attributes defined and thus the
> default value of 1 (as per the spec) is always returned by these methods.
> (Unless of course you ask for the spans of a cell in which case you get an
> error.)

hmm, it seems other table elements have the same problem:

  - poppler_structure_element_get_table_headers: This attribute may apply to header cells (TH) as well as data cells (TD)

  - poppler_structure_element_get_table_scope: This attribute shall only be used
when the structure type of the element is TH

Could you please fix those too?
Comment 2 GitLab Migration User 2018-08-21 10:45:50 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/poppler/poppler/issues/360.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.