diff options
author | Trygve Aaberge <trygveaa@gmail.com> | 2020-07-14 23:29:59 +0200 |
---|---|---|
committer | Trygve Aaberge <trygveaa@gmail.com> | 2020-07-14 23:29:59 +0200 |
commit | afe461ceaf0536b4d74fd17051f6e06500e2f73d (patch) | |
tree | 0e9361c2012a312078e1d500f4b70dfc7c7cc3d4 /wee_slack.py | |
parent | 1c927f75ff4f77394838c3a74fd15343388d5d54 (diff) | |
download | wee-slack-afe461ceaf0536b4d74fd17051f6e06500e2f73d.tar.gz |
Revert "Use buflist.format.indent for thread short name indent"
This caused some issues, so I think it's best to revert it:
- If you don't set a color in the indent option, and otherwise use
default format options, the normal indent will be colored green while
the thread indent will be colored white.
- It will look worse for people with tree-style indent unless they
specifically change the indent option for Slack.
- The indent will be included when the name is shown in the hotlist,
and other places that show short_name.
Even without this, it's still possible to get nice indenting of threads
if you add the condition `${buffer.local_variables.slack_type}==thread`
in the indent option and use that to print extra indent for threads. You
will get an extra space before the name (the default indent), but I'll
add a commit to remove that if the indent option includes slack_type.
This reverts commit f55bf93ad9dd9a90afa987ee45ac7c862d85084b.
Diffstat (limited to 'wee_slack.py')
-rw-r--r-- | wee_slack.py | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/wee_slack.py b/wee_slack.py index dbbccc5..a6f7b8d 100644 --- a/wee_slack.py +++ b/wee_slack.py @@ -2491,9 +2491,7 @@ class SlackThreadChannel(SlackChannelCommon): if self.label_short_drop_prefix: return name else: - indent_expr = w.config_string(w.config_get("buflist.format.indent")) - indent = w.string_eval_expression(indent_expr, {}, {"slack_thread": "1"}, {}) - return "{}{}${}".format(indent, w.color("default"), name) + return " ${}".format(name) elif style == "long_default": if self.label_full_drop_prefix: return name |