Textredux is a module for the Textadept editor that offers text-based interfaces for core Textadept functionality.
- A text-based file browser. Completely keyboard driven, with powerful search and seamless switching between traditional and snapopen (recursive) listings.
- A text-based replacement for the buffer list, also providing an easy way to close buffers and directories.
- A simple function call that automatically integrates all Textredux functionality in the Textadept editor. No need to configure anything further unless you want to – once you’ve loaded this you will be using Textredux. In addition to integrating the above modules, it will hook into Textadept and inject text based interfaces whereever it can (e.g. file open or theme selection).
To install the module, just unpack the module into the
directory. Alternatively you can clone Textredux into it:
cd ~/.textadept/modules git clone https://github.com/rgieseke/textredux.git
Having installed the module, there are two ways you can use it. Note that due to
Textredux re-using colors defined in your theme file, loading Textredux should happen
after a custom theme is set using
ui.set_theme in your
1) Cherrypick the functionality you want from the different modules by assigning
key bindings to the desired functions. As an example, if you would like to use
the text based file browser and normally open files using
Ctrl-O, then the
following code in your
init.lua would do the trick:
textredux = require 'textredux' keys.co = textredux.fs.open_file
2) If you can’t get enough of text based interfaces and the joy they provide,
then the Textredux
hijack function is for you. Simple place this in your
As the name suggest, Textredux has now hijacked your environment. All your regular key bindings should now use Textredux where applicable. Clicking the menu will still open the standard GUI dialogs.
Regardless of the approach chosen, the module documentation contains more in-depth documentation for the various modules, including customization tips.
Also, make sure to take a brief look at the screen shots for some quick tips on using Textredux.
Textredux is released under the MIT license (see the LICENSE file in the source for the full details). The source code is available from GitHub. It was written by Nils Nordman and is now maintained by Robert Gieseke.
Any feedback, be it patches, feature request or bug reports is most welcome.
If you want to provide patches, the preferred way of doing so would be as a pull request via GitHub, or as a pull request from some other Git server. Should that not be an option patches are gladly accepted through other means as well.
- Don't hijack
- Allow drive selection on Windows
- Bug fixes, styling improvements
- Requires a nightly build with fixes for
spawnon OS X and the terminal version
- Fix console window popup on Windows for Ctags list (Thanks to Feng Li)
- Add example file to show output of
- Fix bug caused by loading
lfsexplicitly after Textadept switched to
- Fix styling bugs
- Add note on updating styles
- Requires Textadept 7.4 or later
- Hijack is now a function, no longer a module
- Waiting for
events.INITIALIZEDis no longer necessary when requiring Textredux
- Keys use Textadept's
keys.MODEunder the hood
- Removed support for on_keypress events
- Add support for
list.luafor an example
- Removed (flaky) support for modifiers on key presses and mouse clicks
- Removed reduxbuffer.newline function
- Hide Textadept's line numbers in Textredux buffers
- All Textredux buffers can be closed with
- Indicators and styles are now set using an
applyfunction bound to each table
- The Ctags list colorises the kind of symbol (class, function, …)
- The current search is kept when toggling between snapopen and directory view
- In lists scrolling is limited to the selectable items
- The search in lists can be reset using
- Workaround for bug on Windows
- New layout and updates for the documentation
- Fix using default filtered list when not hi-jacked
- Fix bug when opening buffers in a new view
- Fix indicator example
- Update for API changes until Textadept 7.0 beta 4
- Update for module name change to
file_typesin Textadept 7.0 beta
- Compatibility with Textadept 7.0 alpha 2
- Better workaround for item selection in Curses version (Thanks to Chris Emerson)
- Compatibility with Textadept 6.6 and 7.0 alpha
- Added ctags symbol filtered list search
- Removed workaround for Curses version
- Updates for API changes in Textadept 6.5 and 6.6 beta.
- Integrate TextUI module back into Textredux as the
- Update to snapopen API change in Textadept 6.2.
- Updates for API changes until Textadept 6.
- Don’t hijack menu entries, use the default widgets when clicking the menu.
- Make ctrl+enter open entries in another view (buffer list / file browser)
- Make buffer list keys configurable
- Handle buffers with nil directories in the buffer list
- Added support for indicators
- Improved auto-loading of not-shown list items
- Added highlighting of list matches
- Added mouse support for buffer hotspots
- Font names are now included for default styles
- List selection callbacks now receive modifiers as well
First public release.