Repository navigation
[inputlength] Add feature to count backwards from the maximum possible length - #914
Merged
Merged
Conversation
kontaxis
force-pushed
the
inputlength_countdown_auto
branch
from
August 16, 2026 11:29
d7eaf4f to
7aefaca
Compare
Member
|
thx |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This change adds boolean setting
inputlength_countdown. WhenON, instead of counting the length ofinputlineup from zero, it counts down from the maximum length of a contiguous message per RFC 1459, i.e., 512 minus overhead.The code dynamically determines the overhead given the current nickname,
userhost, and channel.This is useful when the user wants avoid their message being split into two, e.g., because they are over the limit by a word.
Setting
inputlength_countdownisOFFby default.This change also adds an integer setting
inputlength_offset. Its value is added to the actual length ofinputline. This is useful when other settings affect the final length, e.g.,split_line_startorsplit_line_end. In that caseinputlength_offsetshould be set to account for those additional characters.As an example, when
split_line_end = "> "andsplit_line_start = " >"theninputlength_offset = 4.Setting
inputlength_offsetis 0 by default.