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

Renaming or duplicating a sequence attachment removes space at the end of the image path #813

Open
misaki-eymard opened this issue Jul 5, 2024 · 1 comment

Comments

@misaki-eymard
Copy link
Collaborator

Description:
If the images that make up a sequence attachment are named Layer 1, Layer 2, Layer 3, or something like name + space + number, changing the attachment name or duplicating the attachment removes the last space in the image path and breaks the reference. This is a bit annoying and should be corrected to keep the trailing spaces.

Expected behavior:
The space at the end of the image path is retained even after renaming or duplicating an attachment.

Steps to reproduce:

  1. Download the attached .zip file: Renaming or duplicating a sequence attachment removes space at the end of the image path.zip
  2. In the tree view, double-click on the name of the attachment "muzzle" to bring up the renaming dialog.
    muzzle
  3. Press OK to close it without making any changes.
    rename
  4. Then you can see that the attachment is missing and the image path is changed from <muzzle > to <muzzle>.
    Screenshot 2024-07-05 at 18 39 02

The version of Spine in which this problem was found:
Spine 4.2.33

This problem was reported in the following thread on the forum:
https://esotericsoftware.com/forum/d/26472-sequence-attachment-trims-the-space-at-the-end-of-the-name

@NathanSweet
Copy link
Member

So far our stance on all names is to strip whitespace characters at the start and end. They can't be seen and it's easy to be confused about why something doesn't work. It may be better to continue that and users should not use invisible space characters in the base part of their names.

I'll leave this open as an enhancement. We could toast a warning when whitespace is stripped and the attachment has a sequence.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

2 participants