Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Indent HTML lists correctly (Issue 1073) #1170

Merged
merged 45 commits into from
Jun 15, 2024

Commits on May 5, 2024

  1. Configuration menu
    Copy the full SHA
    f794193 View commit details
    Browse the repository at this point in the history
  2. Feature mostly implemented.

    Some debugging and polish needed.
    lcgeneralprojects committed May 5, 2024
    Configuration menu
    Copy the full SHA
    20c035e View commit details
    Browse the repository at this point in the history

Commits on May 6, 2024

  1. Configuration menu
    Copy the full SHA
    eb93711 View commit details
    Browse the repository at this point in the history

Commits on May 11, 2024

  1. Feature implemented.

    Some variables need tweaking.
    Needs testing.
    Code reuse unsatisfactory.
    lcgeneralprojects committed May 11, 2024
    Configuration menu
    Copy the full SHA
    f8f17a5 View commit details
    Browse the repository at this point in the history
  2. Feature implemented.

    Some variables need tweaking.
    Needs testing.
    Code reuse unsatisfactory.
    lcgeneralprojects committed May 11, 2024
    Configuration menu
    Copy the full SHA
    77a1a31 View commit details
    Browse the repository at this point in the history

Commits on May 12, 2024

  1. Feature implemented for <li>.

    Potentially significant issues with tests:
    1. test_html_ln_outside_p - IndexError: list index out of range.
    2. test_html_ol_ul_line_height - actual distance between lines differs slightly from expected.
    
    Code reuse unsatisfactory.
    lcgeneralprojects committed May 12, 2024
    Configuration menu
    Copy the full SHA
    e80d8d9 View commit details
    Browse the repository at this point in the history
  2. Feature implemented for <li>.

    Need feedback for handling <dd> and <blockquote>.
    
    Potentially significant issues with tests:
    1. test_html_ol_ul_line_height - actual distance between lines differs slightly from expected.
    
    Need feedback for whether or not the new indentation that contradicts old tests is satisfactory.
    
    Code reuse unsatisfactory.
    Need feedback.
    lcgeneralprojects committed May 12, 2024
    Configuration menu
    Copy the full SHA
    9bddeca View commit details
    Browse the repository at this point in the history

Commits on May 13, 2024

  1. Configuration menu
    Copy the full SHA
    dbcce1f View commit details
    Browse the repository at this point in the history

Commits on May 16, 2024

  1. Issue mostly fixed.

    Bug present: bullets are made one per line instead of one per paragraph.
    Saving progress before introducing a `Bullet` class.
    lcgeneralprojects committed May 16, 2024
    Configuration menu
    Copy the full SHA
    fb59849 View commit details
    Browse the repository at this point in the history
  2. Issue fixed.

    Feature implemented.
    Testing and adjustments of tests needed.
    lcgeneralprojects committed May 16, 2024
    Configuration menu
    Copy the full SHA
    bc1fab8 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    d487f7d View commit details
    Browse the repository at this point in the history

Commits on May 17, 2024

  1. Added the li_pseudo_marginattribute to HTML2FPDF.

    Prevented from `Paragraph.top_margin` being added to `pdf.y` of first lines of paragraphs with bullets.
    lcgeneralprojects committed May 17, 2024
    Configuration menu
    Copy the full SHA
    2caa750 View commit details
    Browse the repository at this point in the history
  2. Added the list_pseudo_marginattribute to HTML2FPDF.

    Prevented from `Paragraph.top_margin` being added to `pdf.y` of first lines of paragraphs with bullets.
    `<ul>` and `<ol>` tags now cause a creation of a paragraph with the string `\n` being used to generate a fragment of the height `list_pseudo_margin`.
    Adjusted defaults for `li_tag_indent`.
    lcgeneralprojects committed May 17, 2024
    Configuration menu
    Copy the full SHA
    ceaa6d3 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    070a41d View commit details
    Browse the repository at this point in the history

Commits on May 19, 2024

  1. Configuration menu
    Copy the full SHA
    4ab204e View commit details
    Browse the repository at this point in the history
  2. Fixed the inappropriate TextMode importation.

    Changed `Paragraph.generate_bullet_frag()` into `generate_bullet_frag_and_tl`, and made it also generate the bullet text line.
    Dealing with the issue of inappropriately large distance between `<dt>` and their child `<dd>` elements when `Paragraph.top_margin` is 0.
    lcgeneralprojects committed May 19, 2024
    Configuration menu
    Copy the full SHA
    7b8923c View commit details
    Browse the repository at this point in the history
  3. Fixed the inappropriate TextMode importation.

    Changed `Paragraph.generate_bullet_frag()` into `generate_bullet_frag_and_tl`, and made it also generate the bullet text line.
    lcgeneralprojects committed May 19, 2024
    Configuration menu
    Copy the full SHA
    1e1eb29 View commit details
    Browse the repository at this point in the history
  4. Merge remote-tracking branch 'origin/issue_1073' into issue_1073

    # Conflicts:
    #	fpdf/html.py
    lcgeneralprojects committed May 19, 2024
    Configuration menu
    Copy the full SHA
    dc3d8f8 View commit details
    Browse the repository at this point in the history

Commits on May 20, 2024

  1. Introduced new test test_html_long_list_entries.

    Adjusted old tests.
    lcgeneralprojects committed May 20, 2024
    Configuration menu
    Copy the full SHA
    3f56811 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    ce7cb9b View commit details
    Browse the repository at this point in the history

Commits on May 25, 2024

  1. Changed the name of the relevant variables from list_top_margin to …

    …`list_vertical_margin`.
    
    Removed the `MultiLineBreak.indent` attribute.
    Added a test for long `<ol>` bullets.
    lcgeneralprojects committed May 25, 2024
    Configuration menu
    Copy the full SHA
    24626f9 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    208e3b3 View commit details
    Browse the repository at this point in the history
  3. Merge branch 'refs/heads/master' into issue_1073

    # Conflicts:
    #	CHANGELOG.md
    lcgeneralprojects committed May 25, 2024
    Configuration menu
    Copy the full SHA
    8cceb1d View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    bf5f0fa View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    82fbfda View commit details
    Browse the repository at this point in the history
  6. Merge remote-tracking branch 'origin/issue_1073' into issue_1073

    # Conflicts:
    #	fpdf/text_region.py
    lcgeneralprojects committed May 25, 2024
    Configuration menu
    Copy the full SHA
    a75a948 View commit details
    Browse the repository at this point in the history
  7. Adjusted handling of fragments in the `Paragraph.generate_bullet_fr…

    …ags_and_tl` method and in the `Bullet` class.
    lcgeneralprojects committed May 25, 2024
    Configuration menu
    Copy the full SHA
    fc38846 View commit details
    Browse the repository at this point in the history

Commits on May 26, 2024

  1. Added docstring to Paragraph.

    Edited `TextRegion.md` to reflect the introduced changes for `Paragraph`s.
    Added tests for `Paragraph` generation in `test_html.py`
    lcgeneralprojects committed May 26, 2024
    Configuration menu
    Copy the full SHA
    2f69001 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f7908e4 View commit details
    Browse the repository at this point in the history

Commits on May 27, 2024

  1. Merge branch 'refs/heads/master' into issue_1073

    # Conflicts:
    #	CHANGELOG.md
    #	test/html/html_features.pdf
    lcgeneralprojects committed May 27, 2024
    Configuration menu
    Copy the full SHA
    5afb935 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    4e7118b View commit details
    Browse the repository at this point in the history

Commits on May 31, 2024

  1. Introduced conversion of 'magic numbers', and default tag indent and …

    …margin values in `html.py` to the chosen document unit of measurement.
    
    Adjusted default tag indent values.
    Moved the `Paragraph` docstring to the `ParagraphCollectorMixin.paragraph()` method.
    Changed the `CustomPDF` class in `test_html_customize_ul` to have non-static attributes `li_tag_indent` and `ul_bullet_char`.
    Adjusted tests.
    lcgeneralprojects committed May 31, 2024
    Configuration menu
    Copy the full SHA
    1ead6a3 View commit details
    Browse the repository at this point in the history

Commits on Jun 6, 2024

  1. Configuration menu
    Copy the full SHA
    619c250 View commit details
    Browse the repository at this point in the history
  2. Introduced unit conversion for li_tag_indent.

    Minor changes to HTML contents of `test_html_measurement_units()`.
    lcgeneralprojects committed Jun 6, 2024
    Configuration menu
    Copy the full SHA
    418f213 View commit details
    Browse the repository at this point in the history
  3. Updated test files

    lcgeneralprojects committed Jun 6, 2024
    Configuration menu
    Copy the full SHA
    c6c8d8b View commit details
    Browse the repository at this point in the history
  4. Renamed bullet_rel_x_displacement, bullet_rel_y_displacement and …

    …associated class attributes and docstring mentions to `bullet_r_margin`, `bullet_t_margin`, `bullet.r_margin`, `bullet.t_margin`.
    lcgeneralprojects committed Jun 6, 2024
    Configuration menu
    Copy the full SHA
    18dddd7 View commit details
    Browse the repository at this point in the history
  5. Undone changes to handling non-default values for li_tag_indent and…

    … `dd_tag_indent` in `html.py`.
    lcgeneralprojects committed Jun 6, 2024
    Configuration menu
    Copy the full SHA
    b345631 View commit details
    Browse the repository at this point in the history

Commits on Jun 9, 2024

  1. Requested changes to conversion of default values implemented.

    `bullet_t_margin` and associated variables removed.
    `li_tag_indent` and `dd_tag_indent` default values are changed to None.
    Changes to `test_html_measurement_units` not included.
    lcgeneralprojects committed Jun 9, 2024
    Configuration menu
    Copy the full SHA
    fb3305b View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    cc7f247 View commit details
    Browse the repository at this point in the history

Commits on Jun 11, 2024

  1. Adjusted CHANGELOG.md.

    Added `test_html_list_vertical_margin`.
    Fixed the non-assignment of `HTML2FPDF.list_vertical_margin` when the constructor argument `list_vertical_margin` is not None.
    lcgeneralprojects committed Jun 11, 2024
    Configuration menu
    Copy the full SHA
    37a8d81 View commit details
    Browse the repository at this point in the history

Commits on Jun 12, 2024

  1. Added the 'bullet_r_margin' parameter to `ParagraphCollectorMixin.par…

    …agraph()`. Updated relevant docstring and `TextRegion.md` documentation.
    
    Adjusted `test_bulleted_paragraphs` to remove mentions of `rel_y_displacement`, changed instances of string `"rel_x_displacement"` to `bullet_r_margin` and introduced usage of `case["bullet_r_margin"]` in the test.
    lcgeneralprojects committed Jun 12, 2024
    Configuration menu
    Copy the full SHA
    f6eb85b View commit details
    Browse the repository at this point in the history

Commits on Jun 14, 2024

  1. Configuration menu
    Copy the full SHA
    d847eb8 View commit details
    Browse the repository at this point in the history

Commits on Jun 15, 2024

  1. Merge branch 'refs/heads/master' into issue_1073

    # Conflicts:
    #	test/html/html_customize_ul.pdf
    #	test/html/test_html.py
    lcgeneralprojects committed Jun 15, 2024
    Configuration menu
    Copy the full SHA
    14ddcc4 View commit details
    Browse the repository at this point in the history
  2. Merged changes from master.

    Correctly this time.
    lcgeneralprojects committed Jun 15, 2024
    Configuration menu
    Copy the full SHA
    691ad2b View commit details
    Browse the repository at this point in the history
  3. Update TextRegion.md

    gmischler committed Jun 15, 2024
    Configuration menu
    Copy the full SHA
    2c475ab View commit details
    Browse the repository at this point in the history