Skip to content
This repository has been archived by the owner on Dec 16, 2021. It is now read-only.

Improving the text editor #145

Closed
19 of 21 tasks
Bios-Marcel opened this issue Sep 3, 2019 · 0 comments
Closed
19 of 21 tasks

Improving the text editor #145

Bios-Marcel opened this issue Sep 3, 2019 · 0 comments
Labels
enhancement New feature or request

Comments

@Bios-Marcel
Copy link
Owner

Bios-Marcel commented Sep 3, 2019

Currently the editor is only implemented halfway and doesn't solve all the problems we have. As seen in:

What we need is an editor that can be used for both the commandline input and the message input. Looking at it from a general perspective, there are some core features we need:

Proper text editing capabilities

The following functions are needed for the text editing:

  • MoveCursorLeft
  • MoveCursorRight
  • MoveCursorWordRight (Move to the end of the word to the right)
  • MoveCursorWordLeft (Move to the beginning of the word to the left)
  • MoveCursorToStartOfLine
  • MoveCursorToEndOfLine
  • MoveCursorToStartOfText
  • MoveCursorToEndOfText
  • MoveLineUp (Keep cursor on same X position if possible) (Dropped for now)
  • MoveLineDown (Keep cursor on same X position if possible) (Dropped for now)
  • SelectionToLeft (Extended selection to left or decrease selection if previously selected to right)
  • SelectionToRight (Extended selection to right or decrease selection if previously selected to left)
  • SelectionWordToLeft (Same rules as for SelectionToLeft but with words instead of characters)
  • SelectionWordToRight (Same rules as for SelectionToRight but with words instead of characters)
  • SelectToStartOfLine
  • SelectToEndOfLine
  • SelectToEndOfText
  • SelectToEndOfText
  • DeleteLeft (delete character left to the cursor or the current selection)
  • DeleteRight (delete character the cursor is on or the current selection)

The Cursor always needs to be visible and selection also has to be visible immediately. Selection of empty lines has to be possible and visible as well. The editor needs to be usable for multiline editing and be able to grow as needed.

Tab-Autocomplete

Similar to how bash auto-completes commands and possible parameters, cordless should do the same. The message input most likely won't be needing this though, as it's mainly useful for stuff like commands.

*Will be moved into separate issue

Autocomplete with live suggestions

This feature is necessary for emojis, mentions and maybe more at some point. Since this feature is required for more than one thing, it needs to have some generic API that allows to easily register a new type of live suggestions for a certain pattern.

  • Done
@Bios-Marcel Bios-Marcel added the enhancement New feature or request label Sep 3, 2019
@Bios-Marcel Bios-Marcel changed the title New and better editor Improving the text editor Nov 10, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant