rjkroege / edwood Goto Github PK
View Code? Open in Web Editor NEWGo version of Plan9 Acme Editor
License: Other
Go version of Plan9 Acme Editor
License: Other
I couldn't select starting from any rune on the first line in a Text
. I presume that I am incorrectly computing the target rune from the mouse position. Investigate Ptofchar
implementation. In particular: notion is to validate that the box model aligns correctly with the containing Frame
rectangle.
Currently Edwood doesn't support the HTML selection constructs that Acme offers. This is inconvenient while editing HTML.
Copying / cutting text does not update the system clipboard.
mouse pointer needs to be warped on MacOS 10.13.4. Maybe this is actually a devdraw issue.
I need to add back the keybindings that I've hacked into my own fork of p9p acme in a way that multiple different bindings can exist in the same binary.
Something in win's setup is causing frame to freak out. I think it's fr.Deleting a tag that has not yet been fr.Inserted, leading to bounds errors in box handling and messing up Nchars and Nlines. And panics. So many panics.
Frame probably wants to be robust to incorrect usage ;-)
I have a script that adds some tag contents when I create a certain kind of file. The first string is not space separated from the default tag contents in Edwood vs Acme.
Acme/Edwood (#46) have some complicated code to make double-clicking useful in HTML files. This doesn't really fit the Acme philosophy. We should consider a mechanism to make it possible to write an external command to customize double clicking.
Somewhere in the code stack between pasting a string and its display, there is a confusion about number of runes vs number of bytes.
Replication: paste a string containing a multi-byte UTF8 rune repeatedly. Eventually see incorrect display updates. Contents of Text
would appear to be correct as scrolling will fix the issue. I blame frame
.
It would be awesome if the Get command would reload a file back at (approximately) the same scroll offset.
The first time that I middle-executed |fmt
on a selection, all was well. The second and subsequent times, the selection was deleted and the stdout of fmt
was dropped on the floor with the following warning:
Failed to open 4/rdsel: already in use
Tags when collapsed should still be split by a visible line but it's missing. Maybe a bitblit offset issue in the tag redraw code?
in Acme, win
would regularly lock up in some fashion. Like 1/week.
In Edwood, win
also regularly locks up. It just does it a lot more frequently: like every few commands.
Will do this next. Can't do without.
Set the tick on mouse-down. This is a UI regression compared to standard Acme.
Painting stops. Edwood live-locks.
args featuring globs don't work as expected. e.g.
echo *.go
from a directory window ../edwood
complains with a syntax error in the shell
Lots and lots of 9pserve processes left lying around.
Also leaves the $NAMESPACE/acme endpoint lying around.
Dump doesn't work. And it would be convenient to have it (and have it happen regularly) given the current reliability of Edwood.
Instead of to their proper directory +Errors. pwd in two different windows yielded
/Users/plalonde/dev/src/github.com/rjkroege/edwood
/Users/plalonde/dev/src/github.com/9fans/go/draw
both in /+Errors
I keep on trying things with Edit and being surprised compared to Acme.
Edit x/^/ i://:
to comment out a selection. Or not? I must have misunderstood.Edit x://: d
to remove the comments? ssam
did the right thing with this command with the exception of inserting 4 invalid rune characters at the end of the selection. (Is that Edwood or ssam
? Edwood also left the selection in a bad state for which we can see #30.Edit ,x/\(image\.Point, image\.Point\)/ c/(image.Point, image.Point, *Frame)/
did something odd. ssam
worked as expected (except for more invalid runes at the end of the buffer.)@fluxlalonde: I thought that you had fixed the first one?
It's not currently possible to drag Window
objects up and down. (They can however be dragged between columns.)
I drag (well, move I suppose) a Window from a larger to smaller column and it
Double clicking caused this crash. The offsets seem suspicious.
Text.Select: DoubleClick returned 3067, 3075
panic: acme: textsetselect p0=903 p1=0 q0=3081 q1=0 t.org=0 nchars=903
goroutine 35 [running, locked to thread]:
main.(*Text).SetSelect(0xc4201aad28, 0xc09, 0x0)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/text.go:1308 +0x352
main.(*Text).Select(0xc4201aad28)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/text.go:1195 +0x4cc
main.MovedMouse(0x104, 0x1a2, 0x1, 0xa56f001d)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/acme.go:418 +0x4fb
main.mousethread(0xc4200b60c0)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/acme.go:297 +0x31c
created by main.main
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/acme.go:171 +0x934
The B command failed to open anything.
Console output (possibly suspect) at roughly the same time:
9pserve: announce unix!/tmp/ns.rjkroege.:0/acme: Address already in use
acme: can't post service: 9pserve failed
Columntag and regular Tag support typing and seem to work but Rowtag doesn't support adding text?
oops.
panic: runtime error: index out of range
goroutine 11 [running]:
github.com/rjkroege/edwood/frame.(*Frame).Delete(0xc4201a4fc0, 0x237, 0x238, 0x5d4)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/frame/delete.go:51 +0xdd2
main.(*Text).Delete(0xc420477d20, 0x237, 0x238, 0x0)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/text.go:608 +0x3a8
main.(*Text).Type(0xc420477d20, 0xc400000008)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/text.go:942 +0x8bb
main.(*Window).Type(0xc420477c00, 0xc420477d20, 0x8)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/wind.go:392 +0x37
main.(*Row).Type(0x12cde00, 0x8, 0x256, 0x3b6, 0x1)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/row.go:277 +0x139
main.keyboardthread(0xc4200ce0c0)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/acme.go:456 +0x274
created by main.main
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/acme.go:181 +0x907
Note to self... Hit Put
way more frequently.
Frame has some bugs. Make it more robust.
Untested: main.plumbthread(): /Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/look.go:48 +0x204
Got a message: &{B edit /Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood text 0xc4204de2a0 [47 85 115 101 114 115 47 114 106 107 114 111 101 103 101 47 116 111 111 108 115 47 103 111 112 107 103 47 115 114 99 47 103 105 116 104 117 98 46 99 111 109 47 114 106 107 114 111 101 103 101 47 101 100 119 111 111 100 47 46 103 105 116 47 67 79 77 77 73 84 95 69 68 73 84 77 83 71]}
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x8 pc=0x1139453]
goroutine 7 [running, locked to thread]:
github.com/rjkroege/edwood/frame.nrune(...)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/frame/util.go:144
github.com/rjkroege/edwood/frame.(*Frame).strlen(0x12d8ac0, 0x1, 0x13e)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/frame/draw.go:278 +0x43
github.com/rjkroege/edwood/frame.(*Frame)._draw(0x12d8ac0, 0x4ed, 0x13e, 0xc4204de300, 0x4ed)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/frame/draw.go:248 +0x1f0
github.com/rjkroege/edwood/frame.(*Frame).bxscan(0xc420338d80, 0xc420200000, 0x5f, 0x5f, 0xc4202b97f0, 0x0, 0xc4202b9740)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/frame/insert.go:104 +0x88e
github.com/rjkroege/edwood/frame.(*Frame).Insert(0xc420338d80, 0xc420200000, 0x5f, 0x5f, 0x0)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/frame/insert.go:165 +0x16c
main.(*Text).Fill(0xc4202c8418)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/text.go:545 +0xc0
main.(*Text).Redraw(0xc4202c8418, 0x4ed, 0x122, 0x800, 0x15a, 0xc420188000, 0xc4200c48c0, 0x334)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/text.go:143 +0x268
main.(*Text).Resize(0xc4202c8418, 0x4ed, 0x122, 0x800, 0x15a, 0x1, 0x5d4)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/text.go:165 +0x1c0
main.(*Window).Resize(0xc4202c8400, 0x4cc, 0x122, 0x800, 0x2e4, 0xc420160000, 0x0)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/wind.go:254 +0x549
main.(*Column).Add(0xc420001800, 0x0, 0x0, 0xffffffffffffffff, 0x1)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/col.go:140 +0x45c
main.makenewwindow(0x0, 0x4e)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/util.go:225 +0x2b6
main.openfile(0x0, 0xc4201628c0, 0x4)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/look.go:765 +0x8b
main.plumblook(0xc4200b2ae0)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/look.go:248 +0x121
main.mousethread(0xc4200ce0c0)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/acme.go:291 +0x310
created by main.main
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/acme.go:168 +0x8a1
Though it gives back an Unimplemented line.
Right-click on a directory. It opens in a Window. Yay! But also generates a great deal of unnecessary warning spew in +Errors
for stat
failures.
Put always fails on the first click with a time comparison failure.
Type in the text of a window's tag, left of the |. Whoops.
Implement vendoring per rsc's scheme. Note that this will require building with vgo
.
Why vendor: largely so that we can reuse / modify other packages. Like 9fans.net/go
in particular. But we might want to use some other packages as we extend/augment edwood.
Acme has a built-in simple autocomplete system that Edwood has inherited. The inclusion of this functionality isn't necessarily compatible with the Acme "IDE built of UNIX commands" model. We should consider implementing a scheme where an external command (perhaps configurable per Window
) would be responsible for autocompletion functionality.
I right dragged a fraction of the win tag (the current working directory) and expected to get a directory opened. Nothing happened.
ls output isn't columnated in win session.
I attempted:
9p read acme/3/body | head
where I believed that window 3 contained more than sufficient text and got this:
goroutine 66 [running]:
main.xfidutfread(0xc4203c4000, 0xc420468128, 0xda9, 0xb)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/xfid.go:902 +0x3f5
main.xfidread(0xc4203c4000)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/xfid.go:332 +0x30a
main.xfidctl(0xc4203c4000, 0xc4200ac0c0)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/xfid.go:46 +0x87
created by main.xfidallocthread
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/acme.go:616 +0x1e5
Looks like an external program exiting incorrectly crashes edwood?
Attempt to activate an invalid Font (say by providing an argument to the Font
command) and the UI will become permanently non-responsive.
I middle click on go build
in the tag of a .../edwood
and got the following sadness:
The full stack trace was very long. We leak go routines in exec somewhere...
Untested: main.execute(0xc420045c18, 0x59, 0x59, 0x0, 0x0): /Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/exec.go:121 +0x37
q1 == q0
selection chosen
Full path is /Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood
Untested: main.run(0xc420045c00, 0xc420210110, 0xa, 0xc42046fa40, 0x3a, 0x1, 0x0, 0x0, 0x0, 0x0, ...): /Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/exec.go:637 +0x34
fatal error: sync: unlock of unlocked mutex
goroutine 22 [running]:
runtime.throw(0x11e484c, 0x1e)
/usr/local/Cellar/go/1.10.1/libexec/src/runtime/panic.go:616 +0x81 fp=0xc420054e90 sp=0xc420054e70 pc=0x102a0f1
sync.throw(0x11e484c, 0x1e)
/usr/local/Cellar/go/1.10.1/libexec/src/runtime/panic.go:605 +0x35 fp=0xc420054eb0 sp=0xc420054e90 pc=0x102a065
sync.(*Mutex).Unlock(0x12dc220)
/usr/local/Cellar/go/1.10.1/libexec/src/sync/mutex.go:184 +0xc2 fp=0xc420054ed8 sp=0xc420054eb0 pc=0x10680d2
main.fsysdelid(0xc4202ba180)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/fsys.go:191 +0x1b2 fp=0xc420054f40 sp=0xc420054ed8 pc=0x1157002
...
Not much point writing a Dump command unless there's a way to load the result back.
On double-clicking and not a Frame issue. ๐
Text.Select: DoubleClick returned 27783, 0
panic: acme: textsetselect p0=518 p1=0 q0=27783 q1=0 t.org=27265 nchars=1134
goroutine 11 [running, locked to thread]:
main.(*Text).SetSelect(0xc420458528, 0x6c87, 0x0)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/text.go:1303 +0x352
main.(*Text).Select(0xc420458528)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/text.go:1118 +0x670
main.MovedMouse(0x4c6, 0x241, 0x1, 0x2b2ef9bc)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/acme.go:418 +0x4fb
main.mousethread(0xc4200b60c0)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/acme.go:297 +0x31c
created by main.main
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/acme.go:171 +0x934
I miss the box cursor while dragging windows. Add this.
I created a win
session. I typed some commands. I used the "
shell command by itself. (Which shouldn't have worked properly but never mind that.) Edwood promptly crashed:
panic: runtime error: slice bounds out of range
goroutine 50 [running]:
main.xfidutfread(0xc420394000, 0xc420382128, 0xc40, 0xb)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/xfid.go:901 +0x3f8
main.xfidread(0xc420394000)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/xfid.go:332 +0x30a
main.xfidctl(0xc420394000, 0xc4200b60c0)
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/xfid.go:46 +0x87
created by main.xfidallocthread
/Users/rjkroege/tools/gopkg/src/github.com/rjkroege/edwood/acme.go:628 +0x1e5
I think this is a regression. Basic issue:
Selection is no longer painted.
Xerox locks the main thread
Kapow! The UI stops responding
Middling Edit x/^/ i:// :
inserts //
before every rune. Conceivably this is the right behaviour (is it?) but it deviates significantly from Acme.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.