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

${cutscr mess with ${color} #1264

Closed
pascalpoitras opened this issue Oct 9, 2018 · 3 comments
Closed

${cutscr mess with ${color} #1264

pascalpoitras opened this issue Oct 9, 2018 · 3 comments
Assignees
Labels
bug Unexpected problem or unintended behavior
Milestone

Comments

@pascalpoitras
Copy link

Bug summary

If I put, for example, ${color:31}+ in the second field of ${cutscr, it works great

/eval -n ${cutscr:2,${color:31}+,hello}

this return he+ as expected

However, if I add a background color, ${cutscr start to cut the color somehow:

/eval -n ${cutscr:2,${color:31,32}+,hello}

this return @0 instead of he+

Additional information

I have only tested ${cut and ${cutscr


  • WeeChat version: WeeChat 2.3-dev (git: v2.2-112-g82697714e)
  • OS, distribution and version: Debian Stable Stretch
@flashcode
Copy link
Member

The problem is that the comma is used as separator between count, suffix and string, and that ${color:31,32} is adding a comma.
Not easy to fix, I'm thinking about a way to use another separator (keeping the comma by default for compatibility).

@flashcode flashcode self-assigned this Oct 9, 2018
@flashcode flashcode added bug Unexpected problem or unintended behavior in progress Someone is working on this issue labels Oct 9, 2018
@flashcode
Copy link
Member

There's a workaround which is working: /eval -n ${cutscr:2,${color:31}${color:,32}+,hello}

@pascalpoitras
Copy link
Author

thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Unexpected problem or unintended behavior
Projects
None yet
Development

No branches or pull requests

2 participants