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

Specification Missing Documentation #2771

Closed
ForeverZer0 opened this issue Mar 17, 2020 · 1 comment
Closed

Specification Missing Documentation #2771

ForeverZer0 opened this issue Mar 17, 2020 · 1 comment
Assignees
Labels
documentation Issue related to the Tiled Manual.

Comments

@ForeverZer0
Copy link

In my current project, I am implementing a parser for the TMX format. I have only gotten as far as the top-level "map" element, and am already running into missing/incorrect documentation on a couple attributes.

I am using the examples in this repo for initial testing purposes, and have thus far discovered the following:

  • There is no documentation for the infinite attribute in the map tag
  • The documentation states that a compressionlevel attribute should be present, and set to -1 as a "default", though no examples seem to use this, nor is documented anywhere how this would be used, or if is only used internally by the editor to determine ZLIB compression levels, etc.

There is no mention of either of these in the changelogs regarding these attributes being added or removed that I have seen.

The documentation seems rather light on indicating what attributes and tags are required, and whch are optional. #2702 seemed to indicate that it addressed this issue, at least for elements, though it seems to never have made it into the specification documentation found here.

@bjorn bjorn self-assigned this Mar 17, 2020
@bjorn bjorn added the documentation Issue related to the Tiled Manual. label Mar 17, 2020
@bjorn
Copy link
Member

bjorn commented Mar 17, 2020

  • There is no documentation for the infinite attribute in the map tag

This appears to be fixed in the latest version, though it still needs to be added to the changelog.

  • The documentation states that a compressionlevel attribute should be present, and set to -1 as a "default", though no examples seem to use this, nor is documented anywhere how this would be used, or if is only used internally by the editor to determine ZLIB compression levels, etc.

As a general rule, any attribute that has a default value does not need to be present (otherwise specifying a default value would be somewhat pointless). The examples use the default compression level and Tiled 1.3.3 will not write this attribute if it is left on -1. Regarding usage, the documentation states "The compression level to use for tile layer data". It is only used when the tile layer data is compressed (zlib, gzip and zstd are currently supported).

Actually I will move the compressionlevel attribute into the new editorsettings element (which still needs to be documented), since it is not relevant outside of the editor.

The documentation seems rather light on indicating what attributes and tags are required, and whch are optional. #2702 seemed to indicate that it addressed this issue, at least for elements, though it seems to never have made it into the specification documentation found here.

Those changes were merged to master, so they will not show up in the "stable" documentation until Tiled 1.4 is released. They are visible on the latest version though.

We have two versions of the documentation to avoid confusing users with changes that do not apply to the current release of Tiled. However, the "stable" version will only update whenever there is a new release tagged. Of course, some of the changes above that were on master should really have gone into the release. :-/

@bjorn bjorn closed this as completed in 0585122 Mar 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Issue related to the Tiled Manual.
Projects
None yet
Development

No branches or pull requests

2 participants