Noticeable changes:
- The input "view" is smarter, it always move to a decent position so we can
see enough text around the cursor.
- The cursor goes at the end of the input when pasting some long text
- The formatting chars (^C and o, b, a, 1, 2, 3 etc) are now visible in the
input. This makes it a lot easier to know where these special characters
are, to change them and efficiently edit our text (we just lose a little,
on the cosmetic side, but who cares)
- The code is actually a lot simpler in the functions to move the cursor,
insert/delete chars: we do not have to deal with special cases where the
formatting characters are actually composed of two chars.
fixes#2183
A command argument can now be completed even if it isn’t the last
one in the input.
- Add a new method Input.new_completion
Almost like the old auto_completion method, except taht it takes
another argument: argument_position, which is the argument to be
completed.
- Methods using the old completion method still work
- All completion methods in poezio now use the new one if necessary
- Further details can be found in the docstring of new_completion
- now case-insensitive
- search in the bare jid instead of userpart only (and still in roster
names)
- do not display groups when searching
- display offline contacts
- do not expand resources if they were before the search
When an external (or internal) event may cause the order of the
cache to be modified, or new elements to be added, schedule it
for a rebuild. Otherwise, don’t, and only rebuild it when
refreshing (that should improve refresh speed a lot).
Also, if the position in the roster is further than the total size
of the roster, go back to the top instead of displaying an empty
window with “+++”.
- The input is split in two parts: on the left is what the user enters,
on the right is the first match (the right part has a different
color)
- Start and cancel a search with ^R
- Validate a search with enter, then press another time enter to send
- CommandInput and MessageInput now inherit from the HistoryInput class
and share some methods
- Added as always new theming variables:
CHAR_ROSTER_MOOD, CHAR_ROSTER_ACTIVITY (a SNOWMAN!)
COLOR_ROSTER_MOOD, COLOR_ROSTER_ACTIVITY
- Added two new notification types in Theme.INFO_COLORS (mood/activity)
- Added new configuration options:
display_mood/activity/tune_notifications (those can be set for a
specific JID)
enable_user_tune/nick/activity/mood
- Added /activity and /mood commands, with completions
- Moved the old /activity to /last_activity
- Details are show in the ContactInfoWin if there is room, or with "i"
on a contact in the roster.
This makes it easy to review all the highlights after the separator was
placed, using M-h, M-n, M-n, M-n…
We just add a counter of highlights which is incremented each time there’s
an hl, and set to zero when we reset the separator. We use that counter to
set hl_pos when we scroll to the separator.
With a few specific behaviours: When manually opening a conversation with a
bare jid, we open a normal conversation that follows the XEP (locked and
unlocked accordingly). If the user manually opens a conversation with a
fulljid (by selecting a specific resource in the roster, or by specifying a
fulljid to the /message command), we open a special tab that doesn’t follow
the XEP (it is always locked to the same resource, and cannot be unlocked).
When a message is received, unless a special tab has been manually opened by
the other with that specific resource, we always send the messages to a uniq
normal tab, unlocking or locking it according to the XEP.
This means that only one tab can be opened with a given contact, unless the
user specifically chooses to open a special tab for a specific resource.
fixes#2159
- The code is more understandable
- The number of iterations may have slightly increased
- Less things are done inside the lock, so the overall experience should
be smoother