Re: VIP Auto-Load and ASCII Diagrams
Hi Kashyap, > I have spent quite some time in the past drawing these in emails by hand!!! > > Hey Alex - do you have SVG output planned too? Good idea! Actually, I have not thought about it, because my use cases were (like your emails) text files. But it should be not too difficult, I think, using 'rect' and 'polyline' in @lib/svg.l. ☺/ A!ex -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe
Re: VIP Auto-Load and ASCII Diagrams
Sorry, a little late to the party! but it's really lovely ... i've not looked at the details but I was floored by "arrow" doing the right thing :) I have spent quite some time in the past drawing these in emails by hand!!! Hey Alex - do you have SVG output planned too? Regards, Kashyap On Sat, Jul 13, 2019 at 11:29 PM Alexander Burger wrote: > Hi Grant, > > > I played around with this for a while, and really enjoy the ability to > draw > > arbitrary structures with `cells`. i wondered if this drawing library > only > > works for Vip? I like using it, but i'm too stuck in my emacs ways (and > the > > other modal key map i use). > > Yes, @lib/vip/draw.l directly operates on the internal code and data > structures > of Vip, so it is not usable in another editor. But the algorithms itself > surely > could be ported to Emacs. > > > > I'd like to be able to hook up viewing the ascii drawings outside of Vip. > > This is easy. As the "v" or ":w" commands create and then update a > normal > Vip buffer, you can do any other editing with it. > > For example, to view the ASCII drawing outside of Vip, just save it with > ":w myfile". > > ☺/ A!ex > > -- > UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe >
Re: VIP Auto-Load and ASCII Diagrams
Hi Grant, > I played around with this for a while, and really enjoy the ability to draw > arbitrary structures with `cells`. i wondered if this drawing library only > works for Vip? I like using it, but i'm too stuck in my emacs ways (and the > other modal key map i use). Yes, @lib/vip/draw.l directly operates on the internal code and data structures of Vip, so it is not usable in another editor. But the algorithms itself surely could be ported to Emacs. > I'd like to be able to hook up viewing the ascii drawings outside of Vip. This is easy. As the "v" or ":w" commands create and then update a normal Vip buffer, you can do any other editing with it. For example, to view the ASCII drawing outside of Vip, just save it with ":w myfile". ☺/ A!ex -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe
Re: VIP Auto-Load and ASCII Diagrams
Hi All, I played around with this for a while, and really enjoy the ability to draw arbitrary structures with `cells`. i wondered if this drawing library only works for Vip? I like using it, but i'm too stuck in my emacs ways (and the other modal key map i use). I'd like to be able to hook up viewing the ascii drawings outside of Vip. Thanks! Grant -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe
Re: VIP Auto-Load and ASCII Diagrams
Great news. Congrats! W dniu piątek, 5 lipca 2019 Alexander Burger napisał(a): > Hi all, > > now I found it (with help from Mike)! > > It was a stupid bug in 'super', which was there all the time, but for some > reason never showed up. > > I made a new release. > > > BTW, a note for invoking Vip: As long as the current version is not in the > global release, the best way is > >$ ./pil @lib/vip.l + >: (vi "file") > > because bin/vip has a gloral path in its hash-bang. > > ☺/ A!ex > > -- > UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe >
Re: VIP Auto-Load and ASCII Diagrams
Hi all, now I found it (with help from Mike)! It was a stupid bug in 'super', which was there all the time, but for some reason never showed up. I made a new release. BTW, a note for invoking Vip: As long as the current version is not in the global release, the best way is $ ./pil @lib/vip.l + : (vi "file") because bin/vip has a gloral path in its hash-bang. ☺/ A!ex -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe
Re: VIP Auto-Load and ASCII Diagrams
'v' also drew a box in my case. czw., 4 lip 2019 o 14:08 Mike napisał(a): > > # VIP @lib/vip/draw.l > > (box 3 4 10 15) > > > > then open it with 'vip' and press "v" to view the drawing, I suspect it > crashes > > too. Is that the case? > > > > No, It draw a box > > -- > UNSUBSCRIBE: mailto:picolisp@software-lab.de?subjectUnsubscribe >
Re: VIP Auto-Load and ASCII Diagrams
> # VIP @lib/vip/draw.l > (box 3 4 10 15) > > then open it with 'vip' and press "v" to view the drawing, I suspect it > crashes > too. Is that the case? > No, It draw a box -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe
Re: VIP Auto-Load and ASCII Diagrams
confirmed, crashed. corrected steps to reproduce: echo "# VIP @lib/vip/draw.l" > /root/mike1 vip /root/mike1 :w = bottom of editor = 1/1 mike1 1,1/1 0% :wSegmentation fault BTW, openbsd too, backtrace from gdb #0 doSuper () at x86-64.openBsd.base.s:12883 12883 cmovnzq (%r13), %r13 (gdb) bt #0 doSuper () at x86-64.openBsd.base.s:12883 #1 0x0002124f86b0 in ?? () #2 0x0002124f86c0 in ?? () #3 0x7f7c4398 in ?? () #4 0x0022d488 in SymTab () #5 0x00214b61 in .851 () at x86-64.openBsd.base.s:12125 #6 0x in ?? () Current language: auto; currently asm (gdb) July 4, 2019 1:18 PM, "Wojciech Gac" wrote: > Provided you have Vip in your path, just run it, open a new file, input the > line: > # VIP @lib/vip/draw.land try saving via :w > > czw., 4 lip 2019 o 12:03 Mike napisał(a): > >> I've never used vip before and dont understand what steps I should do to >> crash >> >> July 4, 2019 12:51 PM, "Alexander Burger" wrote: >> >>> On Tue, Jul 02, 2019 at 06:58:21PM +0900, Alexander Burger wrote: >>> On Tue, Jul 02, 2019 at 11:28:19AM +0200, Wojciech Gac wrote: Weird... I've updated my PicoLisp and when I try to save a file with the following line: # VIP @lib/vip/draw.l Vip dies and I get a segmentation fault. Strange! Can you try to strace or something? >>> >>> Does anybody else can reproduce this crash? >>> >>> ☺/ A!ex >>> >>> -- >>> UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe >> >> -- >> UNSUBSCRIBE: mailto:picolisp@software-lab.de?subjectUnsubscribe -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe
Re: VIP Auto-Load and ASCII Diagrams
On Thu, Jul 04, 2019 at 01:19:11PM +0200, Wojciech Gac wrote: > Yes, it crashes either way. :w with other files works fine. OK, then it must be the 'save>' method. @lib/vip/draw.l defines in the end: (dm (save> 0 . This) (Win) (super) (view> This Win) ) (dm (view> 0 . This) (Win) (off *Draw *Boxes) (symbols '(draw vip pico) (evCmd (load (fName (: file ) (mapc 'hv> *Boxes) (with Win (scratch (tmp "draw") *Draw) ) ) As normal saving (in super) works, it is probably the 'view>' method. 'view>' is also called if you press "v" (without save). So if you prepare a file with e.g. with 'cat' or 'vim' with # VIP @lib/vip/draw.l (box 3 4 10 15) then open it with 'vip' and press "v" to view the drawing, I suspect it crashes too. Is that the case? ☺/ A!ex -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe
Re: VIP Auto-Load and ASCII Diagrams
Yes, it crashes either way. :w with other files works fine. czw., 4 lip 2019 o 13:04 Alexander Burger napisał(a): > On Thu, Jul 04, 2019 at 12:06:02PM +0200, Wojciech Gac wrote: > > Provided you have Vip in your path, just run it, open a new file, input > the > > line: > > > > # VIP @lib/vip/draw.l > > > > and try saving via :w > > Does it also crash also if the file is initially not empty? E.g. if it has > ># VIP @lib/vip/draw.l >(box 3 4 10 15) > > before you do :w ? > > > Also, does Vip work when editing a plain file? > > ☺/ A!ex > > -- > UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe >
Re: VIP Auto-Load and ASCII Diagrams
On Thu, Jul 04, 2019 at 12:06:02PM +0200, Wojciech Gac wrote: > Provided you have Vip in your path, just run it, open a new file, input the > line: > > # VIP @lib/vip/draw.l > > and try saving via :w Does it also crash also if the file is initially not empty? E.g. if it has # VIP @lib/vip/draw.l (box 3 4 10 15) before you do :w ? Also, does Vip work when editing a plain file? ☺/ A!ex -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe
Re: VIP Auto-Load and ASCII Diagrams
Provided you have Vip in your path, just run it, open a new file, input the line: # VIP @lib/vip/draw.l and try saving via :w czw., 4 lip 2019 o 12:03 Mike napisał(a): > I've never used vip before and dont understand what steps I should do to > crash > > > > > > > July 4, 2019 12:51 PM, "Alexander Burger" wrote: > > > On Tue, Jul 02, 2019 at 06:58:21PM +0900, Alexander Burger wrote: > > > >> On Tue, Jul 02, 2019 at 11:28:19AM +0200, Wojciech Gac wrote: > >> Weird... I've updated my PicoLisp and when I try to save a file with the > >> following line: > >> > >> # VIP @lib/vip/draw.l > >> > >> Vip dies and I get a segmentation fault. > >> > >> Strange! Can you try to strace or something? > > > > Does anybody else can reproduce this crash? > > > > ☺/ A!ex > > > > -- > > UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe > > -- > UNSUBSCRIBE: mailto:picolisp@software-lab.de?subjectUnsubscribe >
Re: VIP Auto-Load and ASCII Diagrams
I've never used vip before and dont understand what steps I should do to crash July 4, 2019 12:51 PM, "Alexander Burger" wrote: > On Tue, Jul 02, 2019 at 06:58:21PM +0900, Alexander Burger wrote: > >> On Tue, Jul 02, 2019 at 11:28:19AM +0200, Wojciech Gac wrote: >> Weird... I've updated my PicoLisp and when I try to save a file with the >> following line: >> >> # VIP @lib/vip/draw.l >> >> Vip dies and I get a segmentation fault. >> >> Strange! Can you try to strace or something? > > Does anybody else can reproduce this crash? > > ☺/ A!ex > > -- > UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe
Re: VIP Auto-Load and ASCII Diagrams
On Tue, Jul 02, 2019 at 06:58:21PM +0900, Alexander Burger wrote: > On Tue, Jul 02, 2019 at 11:28:19AM +0200, Wojciech Gac wrote: > > Weird... I've updated my PicoLisp and when I try to save a file with the > > following line: > > > > # VIP @lib/vip/draw.l > > > > Vip dies and I get a segmentation fault. > > Strange! Can you try to strace or something? Does anybody else can reproduce this crash? ☺/ A!ex -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe
Re: VIP Auto-Load and ASCII Diagrams
On Tue, Jul 02, 2019 at 01:47:26PM +0200, Wojciech Gac wrote: > Attaching my strace output. Hmm, not much to see. It echoes the "w" you wrote (write) and the enter, then it sigfaults. Somewhere in ("w" # (Write) Save buffer (if Line (out (fName (rplFile @)) (mapc prinl (: buffer text)) ) (save> (: buffer) This) ) ) I have no idea ... :( -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe
Re: VIP Auto-Load and ASCII Diagrams
Attaching my strace output. wt., 2 lip 2019 o 12:04 Alexander Burger napisał(a): > On Tue, Jul 02, 2019 at 11:28:19AM +0200, Wojciech Gac wrote: > > Weird... I've updated my PicoLisp and when I try to save a file with the > > following line: > > > > # VIP @lib/vip/draw.l > > > > Vip dies and I get a segmentation fault. > > Strange! Can you try to strace or something? > ☺/ A!ex > > -- > UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe > draw-test-strace.out Description: Binary data
Re: VIP Auto-Load and ASCII Diagrams
On Tue, Jul 02, 2019 at 11:28:19AM +0200, Wojciech Gac wrote: > Weird... I've updated my PicoLisp and when I try to save a file with the > following line: > > # VIP @lib/vip/draw.l > > Vip dies and I get a segmentation fault. Strange! Can you try to strace or something? ☺/ A!ex -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe
Re: VIP Auto-Load and ASCII Diagrams
Weird... I've updated my PicoLisp and when I try to save a file with the following line: # VIP @lib/vip/draw.l Vip dies and I get a segmentation fault. wt., 2 lip 2019 o 10:06 Wojciech Gac napisał(a): > This is very cool! One step further along the way to a self-sufficient > development environment :). > > wt., 2 lip 2019 o 09:12 napisał(a): > >> Am 2019-07-02 04:26, schrieb Alexander Burger: >> > I made a little video explaining two relatively new features in Vip: >> > >> >1. Vip has an Auto-Load functionality, inspired by shell hash-bang >> > scripts. >> >2. It comes with a library that generates ASCII drawings from Lisp >> > code. >> >> Very nice! >> Thank you Alex for creating and sharing this :-) >> >> -- >> UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe >> >
Re: VIP Auto-Load and ASCII Diagrams
This is very cool! One step further along the way to a self-sufficient development environment :). wt., 2 lip 2019 o 09:12 napisał(a): > Am 2019-07-02 04:26, schrieb Alexander Burger: > > I made a little video explaining two relatively new features in Vip: > > > >1. Vip has an Auto-Load functionality, inspired by shell hash-bang > > scripts. > >2. It comes with a library that generates ASCII drawings from Lisp > > code. > > Very nice! > Thank you Alex for creating and sharing this :-) > > -- > UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe >
Re: VIP Auto-Load and ASCII Diagrams
Am 2019-07-02 04:26, schrieb Alexander Burger: I made a little video explaining two relatively new features in Vip: 1. Vip has an Auto-Load functionality, inspired by shell hash-bang scripts. 2. It comes with a library that generates ASCII drawings from Lisp code. Very nice! Thank you Alex for creating and sharing this :-) -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe
VIP Auto-Load and ASCII Diagrams
Hi all, I made a little video explaining two relatively new features in Vip: 1. Vip has an Auto-Load functionality, inspired by shell hash-bang scripts. 2. It comes with a library that generates ASCII drawings from Lisp code. As I use Vip itself to generate a simple slide show, I call it a "Vip-Video": https://picolisp.com/pub/VipAsciiDiagrams.mp4 I hid the PentiKeyboard between each action. If it is all a bit to fast, just pause the video whenever you like. ☺/ A!ex -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe