A graphical text editor

A

Go Report Card CircleCI

A is a text editor inspired by the Sam and Acme text editors for the Plan 9 operating system.

binary

paint paint

  • Latest Binaries
  • Written in Go (no dependencies)
  • Resembles Acme and Sam text editors.
    • Mouse chording
    • Text is executable
    • Standard UNIX keyboard shortcuts
    • Implements the Edit command language
    • Plumbing
  • Graphics
    • Frame implementation stores bytes and works with '\0'
    • UTF-8 rendering support
    • Structure highlighting
    • Image support (TBD)
  • Files
    • Optimized for editing huge binary files.

note

This repository is still in the alpha stage, and frequently changes. The program comes with no warranty expressed or implied.

install or build

Binary releases for linux, windows, and darwin are available for v0.6.7+. You can install from source on these systems by running:

go get -u -t github.com/as/a

If you want to install a prior version (v0.5.5, for example, which uses the original exp/shiny)

go get github.com/as/a
go get github.com/golang/vgo
cd $GOPATH/src/github.com/as/a
git checkout v0.5.5-release 
vgo build

You can also build the latest with vgo, but vgo is not necessary for that

git checkout master
vgo build

usage

a [file ...]

differences and issues

https://github.com/as/a/issues

hints

To reshape the windows and columns, click on the invisible 10x10px sizer that I haven't rendered yet with the left mouse button. Hold the button down and move the window to the location. Release the button.

edit

  • 80% of the sam command language is implemented.

Edit ,x,the standard editor is any editor,x,any editor,c,ed,

commands

  • Currently only in CWD
  • Put [go build] in the tag
  • Double click inside [
  • Middle click to execute

look

  • Right click on a string
  • If its a file, it will open it
  • If win32, it will also move the mouse
  • if you highlight a valid mode in the guru tag, right clicking in a go source file will run guru on that selection

mouse

1 Select text/sweep
1-2 Snarf (cut)
1-3 Paste
2 Execute select
3 Look select

keyboard

^U  Delete from cursor to start of line.
^W  Delete word before the cursor.
^H  Delete character before the cursor.
^A  Move cursor to start of the line.
^E  Move cursor to end of the line.
^+  Increase font size
^-  Decrease font size
^i	Run goimports (in a tag ending in .go)

extras

  • Looking (right click) in the main tag finds the result in all open windows paint

future

  • Fixing the bugs
  • Cleaning the code up
  • Live multi-client editing
  • Go specific ast/compiler stuff
  • Better CMD exec
  • File system interface to shiny events

see also

History of good text editors

  • The Acme User Interface for Programmers (Rob Pike)
  • A Tutorial for the Sam Command Language (Rob Pike)
  • Plan 9
  • Inferno
  • Acme SAC
Owner
You have to try it as hard as you can throw it
null
Comments
  • a: windows gives me a black window.

    a: windows gives me a black window.

    C:\> go get github.com/as/a
    C:\> a
    guide
    CreateFile guide: Das System kann die angegebene Datei nicht finden.
    .
    +Errors
    CreateFile +Errors: Das System kann die angegebene Datei nicht finden.
    

    I get a black, empty window. That's all.

  • a: not building on darwin

    a: not building on darwin

    Trying a build on Mac OSX 10.13.3; go version go1.10 darwin/amd64

    $ go get -u -t github.com/as/a

    github.com/as/ms/win

    GitHub/go/src/github.com/as/ms/win/win.go:10:12: undefined: Open GitHub/go/src/github.com/as/ms/win/win.go:25:12: undefined: Open GitHub/go/src/github.com/as/ms/win/win.go:53:2: not enough arguments to return have ([]uintptr) want ([]uintptr, error)

    github.com/as/shiny/driver/gldriver

    cocoa.m:24:5: error: redefinition of enumerator 'NSEventTypeScrollWheel' /System/Library/Frameworks/AppKit.framework/Headers/NSEvent.h:40:5: note: previous definition is here cocoa.m:25:5: error: redefinition of enumerator 'NSEventTypeKeyDown' /System/Library/Frameworks/AppKit.framework/Headers/NSEvent.h:32:5: note: previous definition is here cocoa.m:28:5: error: redefinition of enumerator 'NSWindowStyleMaskTitled' /System/Library/Frameworks/AppKit.framework/Headers/NSWindow.h:36:5: note: previous definition is here cocoa.m:29:5: error: redefinition of enumerator 'NSWindowStyleMaskResizable' /System/Library/Frameworks/AppKit.framework/Headers/NSWindow.h:39:5: note: previous definition is here cocoa.m:30:5: error: redefinition of enumerator 'NSWindowStyleMaskMiniaturizable' /System/Library/Frameworks/AppKit.framework/Headers/NSWindow.h:38:5: note: previous definition is here cocoa.m:31:5: error: redefinition of enumerator 'NSWindowStyleMaskClosable' /System/Library/Frameworks/AppKit.framework/Headers/NSWindow.h:37:5: note: previous definition is here

    ain't that peculiar.

  • Constant overflows int

    Constant overflows int

    Not sure this is an issue, but I get the following:

    > go get -u -t github.com/as/a
    # github.com/as/edit
    c:\devenv\projects\_go\src\github.com\as\edit\lex.go:33:21: constant 9223372036854775807 overflows int
    
  • Cannot build; errors with as/font

    Cannot build; errors with as/font

    +(128) pechkin ~ % \go get -u -t github.com/as/a 
    # github.com/as/ui/win
    go/src/github.com/as/ui/win/win.go:25:3: cannot use "github.com/as/font".NewFace(11) (type "github.com/as/font"
    .Face) as type "github.com/as/frame/vendor/github.com/as/font".Face in field value:
            "github.com/as/font".Face does not implement "github.com/as/frame/vendor/github.com/as/font".Face (wron
    g type for Glyph method)
                    have Glyph("golang.org/x/image/math/fixed".Point26_6, rune) (image.Rectangle, image.Image, imag
    e.Point, "golang.org/x/image/math/fixed".Int26_6, bool)
                    want Glyph("github.com/as/frame/vendor/golang.org/x/image/math/fixed".Point26_6, rune) (image.R
    ectangle, image.Image, image.Point, "github.com/as/frame/vendor/golang.org/x/image/math/fixed".Int26_6, bool)
    go/src/github.com/as/ui/win/win.go:203:33: cannot use w.Config.Frame.Face (type "github.com/as/frame/vendor/git
    hub.com/as/font".Face) as type "golang.org/x/image/font".Face in argument to "github.com/as/font".Open:
            "github.com/as/frame/vendor/github.com/as/font".Face does not implement "golang.org/x/image/font".Face 
    (wrong type for Glyph method)
                    have Glyph("github.com/as/frame/vendor/golang.org/x/image/math/fixed".Point26_6, rune) (image.R
    ectangle, image.Image, image.Point, "github.com/as/frame/vendor/golang.org/x/image/math/fixed".Int26_6, bool)
                    want Glyph("golang.org/x/image/math/fixed".Point26_6, rune) (image.Rectangle, image.Image, imag
    e.Point, "golang.org/x/image/math/fixed".Int26_6, bool)
    go/src/github.com/as/ui/win/win.go:209:22: cannot use ft (type "github.com/as/font".Face) as type "github.com/a
    s/frame/vendor/github.com/as/font".Face in assignment:
            "github.com/as/font".Face does not implement "github.com/as/frame/vendor/github.com/as/font".Face (wron
    g type for Glyph method)
                    have Glyph("golang.org/x/image/math/fixed".Point26_6, rune) (image.Rectangle, image.Image, imag
    e.Point, "golang.org/x/image/math/fixed".Int26_6, bool)
                    want Glyph("github.com/as/frame/vendor/golang.org/x/image/math/fixed".Point26_6, rune) (image.R
    ectangle, image.Image, image.Point, "github.com/as/frame/vendor/golang.org/x/image/math/fixed".Int26_6, bool)
    
  • Logo design

    Logo design

    Hi Hello I am looking for open source projects to contribute with graphical design, I have been contributing to several opensource projects for free, I would like to know if you are interested that I make a logo for this your project ?. It´s all free, I just need to know what do you want for the logo.

    Greetings

    Nuno Jesus

  • a: vgo: v0.6.7 code cannot compile

    a: vgo: v0.6.7 code cannot compile

    ➜  a git:(master) ✗ vgo build
    # github.com/as/a
    ./look.go:35:17: undefined: fs.Resolver
    ./look.go:165:38: undefined: fs.Path
    

    Because the dependent version of as/srv has not been updated. Please tag a new version of as/srv and update go.mod.

  • a: too many

    a: too many "New" functions

    github.com\as\a\col.go:23,24:  func NewCol(src screen.Screen, wind screen.Window, ft *font.Font, sp, size image.Point, files ...string) *Col {
    github.com\as\a\col.go:57,58:  func NewCol2(g *Grid, filenames ...string) (w Plane) {
    github.com\as\a\col.go:77,78:  func New(co *Col, filename string) (w Plane) {
    github.com\as\a\grid.go:15,16: func NewGrid(src screen.Screen, wind screen.Window, ft *font.Font, sp, size image.Point, files ...string) *Grid {
    
  • a: win: scroll+sweep is O(2n)

    a: win: scroll+sweep is O(2n)

    The traditional method for scroll+sweep is to transpose the background and foreground colors during insertion of new text. This is because the new text is being selected, so there is no need to highlight it again (just insert it with the right color in the first place). Currently, the logic in frame/win doesn't account for that. Text is inserted with the regular text color, and then repainted (which essentially means redrawn). A trivial performance improvement can be ascertained by fixing this.

  • a: text: single line without newline doesn't get selected on double click

    a: text: single line without newline doesn't get selected on double click

    When you double click to the right of a line, it selects the entire line. This doesn't work when you have a single line in the file without a trailing newline.

  • a: scroll: out-of-bounds selection hold results in no scroll feedback unless cursor moves

    a: scroll: out-of-bounds selection hold results in no scroll feedback unless cursor moves

    The text should scroll if you make a selection and move the cursor out of vertical bounds of the window, even if the mouse isn't moved. Currently, it only scrolls if the mouse is moved (ever so slightly works).

    This bug was introduced during the shiny hard fork.

  • a: resizing/moving difficult without different colored col/win handle square

    a: resizing/moving difficult without different colored col/win handle square

    In acme it is easy to visually grok where to click if you want to resize a win/col or move a win to another col. 1537498228

    By comparison, there is no quick visual way of determining where to click to resize columns or windows or for moving windows to another column, see image below from a. 1537498254

    I don't really have any opinion as to how to indicate these two areas, just that they are easy to distinguish from each other and from the scroll bar when the window above has a scroll handle that isn't the size of the window itself, see image below.

    1537499567

    Also, thanks for the excellent work on this project :+1:

A Programmer's Text Editor
A Programmer's Text Editor

The de Editor de is a programmer's editor. (Where that programmer happens to be driusan.) It's kind of like a bastard child of vim and Plan 9's acme e

Dec 8, 2022
A very religious text editor

--== Godit - a very religious text editor ==-- Screenshots: * https://nosmileface.dev/images/godit-linux1.png * https://nosmileface.dev/images/god

Dec 27, 2022
A modern and intuitive terminal-based text editor
A modern and intuitive terminal-based text editor

micro is a terminal-based text editor that aims to be easy to use and intuitive, while also taking advantage of the capabilities of modern terminals.

Dec 30, 2022
Source code editor written in Go using go-gtk bindings. It aims to handle navigation effectively among large number of files.
Source code editor written in Go using go-gtk bindings. It aims to handle navigation effectively among large number of files.

tabby Source code editor written in Go using go-gtk bindings. It aims to handle navigation effectively among large number of files. screenshot: depend

Nov 16, 2022
An Enhanced Go Experience For The Atom Editor
An Enhanced Go Experience For The Atom Editor

go-plus An Improved Go Experience For The Atom Editor Github: https://github.com/joefitzgerald/go-plus Atom: https://atom.io/packages/go-plus Overview

Dec 26, 2022
Go version of Plan9 Acme Editor

Overview Go port of Rob Pike's Acme editor. Derived from ProjectSerenity but now increasingly divergent. ProjectSerenity was itself a transliteration

Dec 24, 2022
Binary editor written in Go
Binary editor written in Go

bed Binary editor written in Go Screenshot Why? Why not? Programming is so fun! I learned so much while creating this editor; handling of file pointer

Jan 5, 2023
WYSIWYG theme editor for Fyne
WYSIWYG theme editor for Fyne

fyne-theme-generator WYSIWYG theme editor for Fyne Installation go get github.com/lusingander/fyne-theme-generator Usage You can change each parameter

Jan 5, 2023
MdEdit is a Vi-like markdown editor built using Gio

MdEdit MdEdit is a Vi-like markdown editor built using Gio. It is extremely early stage software. The Vi editor lacks most functionality and might be

Jun 29, 2022
Mini is a small text editor, inspred by antirez's kilo editor.
Mini is a small text editor, inspred by antirez's kilo editor.

mini Mini is a small text editor, inspred by antirez's kilo editor. It aims to Keep it simple, stupid.

Dec 23, 2022
NERV Editor - A simple but peculiar text editor
NERV Editor - A simple but peculiar text editor

nerved a simple but peculiar text editor introduction nerved is a text editor bu

Oct 24, 2022
A Programmer's Text Editor
A Programmer's Text Editor

The de Editor de is a programmer's editor. (Where that programmer happens to be driusan.) It's kind of like a bastard child of vim and Plan 9's acme e

Dec 8, 2022
A very religious text editor

--== Godit - a very religious text editor ==-- Screenshots: * https://nosmileface.dev/images/godit-linux1.png * https://nosmileface.dev/images/god

Dec 27, 2022
A modern and intuitive terminal-based text editor
A modern and intuitive terminal-based text editor

micro is a terminal-based text editor that aims to be easy to use and intuitive, while also taking advantage of the capabilities of modern terminals.

Dec 30, 2022
A modern and intuitive terminal-based text editor
A modern and intuitive terminal-based text editor

micro is a terminal-based text editor that aims to be easy to use and intuitive, while also taking advantage of the capabilities of modern terminals

Jan 7, 2023
A modern and intuitive terminal-based text editor
A modern and intuitive terminal-based text editor

micro is a terminal-based text editor that aims to be easy to use and intuitive, while also taking advantage of the capabilities of modern terminals.

Jan 5, 2023
a simple and lightweight terminal text editor written in Go

Simple Text editor written in Golang build go build main.go

Oct 4, 2021
Are you programming and suddenly your stomach is rumbling? No problem, order your Ifood without leaving your favorite text editor ❤️

vim-ifood Você ta programando e de repente bateu aquela fome? Sem problemas, peça seu Ifood sem sair do seu editor de texto favorito ❤️ Are you progra

Jun 2, 2022
Tool to easily rename or move a bunch of files with a text editor of your choice
Tool to easily rename or move a bunch of files with a text editor of your choice

batch-rename With batch-rename you can utilize your favorite text editor to rename or move a bunch of files at once. It doesn't come with any features

Nov 2, 2022
Built Virtual Operating System and integrated application like calculator, gallery app , weather app, and text editor.
Built Virtual Operating System and integrated application like calculator, gallery app , weather app, and text editor.

Virtual Operating System Built Virtual Operating System and integrated application like calculator, gallery app , weather app, and text editor. Langua

Nov 2, 2021