All Projects → agorf → Femto

agorf / Femto

Licence: unlicense
A toy text editor with no dependencies written in Ruby

Programming Languages

ruby
36898 projects - #4 most used programming language

Projects that are alternatives of or similar to Femto

Zep
Zep - An embeddable editor, with optional support for using vim keystrokes.
Stars: ✭ 477 (+1302.94%)
Mutual labels:  editor, text-editor, text
Mle
Flexible terminal-based text editor (C)
Stars: ✭ 378 (+1011.76%)
Mutual labels:  editor, text-editor, text
Zmjimageeditor
ZMJImageEditor is a picture editing component like WeChat. It is powerful and easy to integrate, supporting rendering, text, rotation, tailoring, mapping and other functions. (ZMJImageEditor 是一个和微信一样图片编辑的组件,功能强大,极易集成,支持绘制、文字、旋转、剪裁、贴图等功能)
Stars: ✭ 470 (+1282.35%)
Mutual labels:  editor, text-editor, text
Left
Distractionless Writing Tool
Stars: ✭ 1,538 (+4423.53%)
Mutual labels:  editor, text-editor, text
tedit
simple tabbed text editor written in core Tcl/Tk
Stars: ✭ 17 (-50%)
Mutual labels:  text, text-editor
boxquote.el
Quote text with a semi-box.
Stars: ✭ 16 (-52.94%)
Mutual labels:  text, text-editor
Slingcode
personal computing platform
Stars: ✭ 277 (+714.71%)
Mutual labels:  editor, text-editor
A
A graphical text editor
Stars: ✭ 280 (+723.53%)
Mutual labels:  editor, text
Text
📑 Collaborative document editing using Markdown
Stars: ✭ 282 (+729.41%)
Mutual labels:  editor, text
Micro
A modern and intuitive terminal-based text editor
Stars: ✭ 18,526 (+54388.24%)
Mutual labels:  editor, text-editor
Slate
A completely customizable framework for building rich text editors. (Currently in beta.)
Stars: ✭ 23,104 (+67852.94%)
Mutual labels:  editor, text-editor
jot
Command-line note-taking for minimalists
Stars: ✭ 24 (-29.41%)
Mutual labels:  minimal, text-editor
pro-writer
Minimal yet Pro Writer 🚀
Stars: ✭ 22 (-35.29%)
Mutual labels:  minimal, text-editor
That editor
*That* editor.
Stars: ✭ 262 (+670.59%)
Mutual labels:  editor, text-editor
classy
Super simple text classifier using Naive Bayes. Plug-and-play, no dependencies
Stars: ✭ 12 (-64.71%)
Mutual labels:  minimal, text
instagram-text-editor
An Instagram like text editor Flutter widget that helps you to change your text style.
Stars: ✭ 66 (+94.12%)
Mutual labels:  text, text-editor
Vue Quill Editor
🍡@quilljs editor component for @vuejs
Stars: ✭ 6,874 (+20117.65%)
Mutual labels:  editor, text-editor
text-style-editor
Text style editor widget for flutter
Stars: ✭ 25 (-26.47%)
Mutual labels:  text, text-editor
mg
OpenBSD Mg editor. Portable Public Domain Micro Emacs for *BSD, Cygwin, Linux, Mac OS X.
Stars: ✭ 99 (+191.18%)
Mutual labels:  text, text-editor
Ewig
The eternal text editor — Didactic Ersatz Emacs to show immutable data-structures and the single-atom architecture
Stars: ✭ 422 (+1141.18%)
Mutual labels:  editor, text

femto

A minimal text editor written for fun in plain Ruby with no dependencies.

asciicast

I wrote it from memory after watching the relevant screencast by Gary Bernhardt. It supports:

  • Quitting
  • Moving the cursor up/down/right/left
  • Deleting the character before the cursor, like backspace
  • Breaking a line (Enter)
  • Undoing!

Additional functionality

The following are also implemented (not covered in the screencast):

  • Flicker-free screen
  • Ignoring non-printable characters
  • Creating a file if it doesn't exist (not just editing)
  • Saving
  • Redoing!
  • Moving left at the beginning of a line causes the cursor to jump to the end of the previous line
  • Moving right at the end of a line causes the cursor to jump to the beginning of the next line
  • Moving the cursor to the beginning of the line
  • Moving the cursor to the end of the line
  • Deleting the character before the cursor at the beginning of a line joins lines
  • Deleting the character at the cursor, like delete
  • Deleting the character at the cursor when at the end of a line joins lines
  • Deleting the line text before the cursor
  • Deleting the line text after (and including) the cursor
  • Support for arrow, Backspace, Delete, Home and End keys

Usage

./femto.rb myfile.txt

Keyboard shortcuts

  • Ctrl-Q quits
  • Ctrl-S saves
  • Ctrl-P (previous), or the Up arrow key, moves the cursor up
  • Ctrl-N (next), or the Down arrow key, moves the cursor down
  • Ctrl-F (forward), or the Right arrow key, moves the cursor right
  • Ctrl-B (backward), or the Left arrow key, moves the cursor left
  • Ctrl-A or Home moves the cursor to the beginning of the line
  • Ctrl-E or End moves the cursor to the end of the line
  • Ctrl-H or Backspace deletes the previous character
  • Ctrl-D or Delete deletes the current character
  • Ctrl-U deletes the line text before the cursor
  • Ctrl-K deletes the line text after (and including) the cursor
  • Ctrl-- undoes the last change
  • Ctrl-R redoes the last change

Roadmap

  • Tests
  • Scroll-buffer

Disclaimer

This is an experimental program. Do NOT use it to edit files that you don't want to lose/damage.

License

The Unlicense

Author

Angelos Orfanakos, https://agorf.gr/

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].