Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Style/Indentation - Remove defaults for all variables. #2841

Open
@rasamassen

Description

Describe the problem

PhpWord/Style/Font.php

RTF (and I assume other formats) has the ability to inherited ParagraphStyle formatting from a parent ParagraphStyle. However, because IndentationStyle currently have default values, there's no way to tell if the values have been intentionally set or are simply the defaults. Null default is needed to determine whether the value is intentional or not.

Imaging this scenario: A parent ParagraphStyle sets indentLeft to -500, and the child ParagraphStyle wants indentLeft to be 0. How would ParagraphStyle know that the 0 value is an intentional choice or simply the default value. If it's the default, then the user did not intend for indentLeft to change from the parent, but if intentional, then they did.

I can implement if there is agreement. But because I currently don't know how the other formats work and am only beginning to understand RTF, I want to verify this change makes sense and would not break the other writers.

Describe the expected behavior

When indentation variables are not set, nothing happens. When they are set, the values are provided.

Priority

  • I want to crowdfund the feature (with @algora-io) and fund a community developer.
  • I want to pay the feature and fund a maintainer for that. (Contact @Progi1984)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /