2 problems noted

Started by hsmyers, April 28, 2008, 10:41:55 AM

Previous topic - Next topic

hsmyers

I don't know how easy this will be to duplicate, but I've had to deal with two problems in the editor.



1. use ALT-2 to place cursor in REPL window, then

2. a simple click back in editor window flips the changed status.

3. next, after a save and a switch to the REPL window, hitting return results in:

newLISP v.9.3.11 on Win32 IPv4, execute 'newlisp -h' for more info.

>
> --- 9841 bytes saved to C:/Documents and Settings/hsmyers/My Documents/newLISP-Dev/newBoard/ps.lsp ---

nil
nil
nil
nil
nil
nil
nil
newlisp
nil
for
nil
nil
> > > <40CF0C>
> > <40CF0C>
nil
9841
nil
nil
nil
nil
and <4097A1>
nil
nil
nil
> >

I don't think that is correct? Perhaps the save message is being evaluated?



--hsm
\"Censeo Toto nos in Kansa esse decisse.\"—D. Gale \"[size=117]ℑ♥λ[/size]\"—Toto

Lutz

#1
Yes, it was evaluating the text on the line under the cursor. When switching windows with Alt-1/2 (or Command 1/2 on Mac OS X). The cursor positions itself wherever it has been before.



In the next version there will be a semicolon prepended to all messages in the monitor area. That will inhibit evaluation, taking them as comments. What I always do, is hit Ctrl-M to clear the monitor area after messages, or position the cursor with the mouse after the text output.

hsmyers

#2
This can also happen after executing code that uses println...



Any ideas about the change after clicking in the editor (dirty bit flip)?



--hsm

p.s. I'd wondered what the keystroke(s) for clear screen were, thanks!
\"Censeo Toto nos in Kansa esse decisse.\"—D. Gale \"[size=117]ℑ♥λ[/size]\"—Toto

Lutz

#3
here is an updated version: http://newlisp.org/download/development/newlisp-edit-114.lsp">http://newlisp.org/download/development ... it-114.lsp">http://newlisp.org/download/development/newlisp-edit-114.lsp

hsmyers

#4
Improvement on several fronts; save state seems fixed and the save statement shows up with a semi-colon. That said, some problems remain. Edited buffer work flow:

newLISP v.9.3.11 on Win32 IPv4, execute 'newlisp -h' for more info.

> (lambda () (set 'ps-template '(("prolog" ("%!PS-Adobe-2.0") ("%%Creator: newBoard.lsp")
    ("%%Title: .ps")
    ("%%CreationDate: ")
    ("%%Pages: 1")
    ("%%DocumentFonts: Zurich ZurichFigurine-Bold ZurichDiagram Helvetica-BoldOblique")
    ("%%PageOrder: Ascend")
    ("%%BoundingBox: 0 0 612 792")
    ("%%DocumentPaperSizes: Letter")
    ("%%EndComments")
    (" ")
    ("/gamenumber 1 def")
    ("/pagenumber 1 def")
    ("/leading 12 def")
    ("/pagetop 720 def")
    ("/nextline 720 def")
    ("/left-margin 72 def")
    ("/column-width 216 def")
    ("/right-margin left-margin column-width add def")
    (" ")
    ("/hrule {")

422 lines left out for clairity...

(lambda (n) (zero? (% n 2)))
(lambda (n) (not (even? n)))
(lambda (n) (+ (/ n 2) (% n 2)))
true
>

Then:



1. make a change (bogus change state seems fixed...) and save

> ;--- 15855 bytes saved to C:/Documents and Settings/hsmyers/My Documents/newLISP-Dev/newBoard/ps.lsp ---


2. ALT-2

3. return



Results in:

nil
nil
nil
nil
nil
nil
nil
newlisp
nil
for
nil
nil
> > > <40CF0C>

ERR: missing parenthesis : "...obe-2.0") ("%%Creator: newBoard.lsp")8199""
>
ERR: invalid function : ("%%Title: .ps")
>
ERR: invalid function : ("%%CreationDate: ")
>
ERR: invalid function : ("%%Pages: 1")
>
ERR: invalid function : ("%%DocumentFonts: Zurich ZurichFigurine-Bold ZurichDiagram Helvetica-BoldOblique")
>
ERR: invalid function : ("%%PageOrder: Ascend")
>
ERR: invalid function : ("%%BoundingBox: 0 0 612 792")
>
ERR: invalid function : ("%%DocumentPaperSizes: Letter")
>
ERR: invalid function : ("%%EndComments")
>
ERR: invalid function : (" ")
>
ERR: invalid function : ("/gamenumber 1 def")
>
ERR: invalid function : ("/pagenumber 1 def")
>
ERR: invalid function : ("/leading 12 def")
>
ERR: invalid function : ("/pagetop 720 def")
>
ERR: invalid function : ("/nextline 720 def")
>


955 lines left out for clairity...



> nil
"nil "

ERR: missing parenthesis : "...  (println line)))n                  "
> (lambda (n) (zero? (% n 2)))
> (lambda (n) (not (even? n)))
> (lambda (n) (+ (/ n 2) (% n 2)))
> true
> > <40CF0C>
> >


So un-authorized buffer eval-ing seems to remain.



--hsm
\"Censeo Toto nos in Kansa esse decisse.\"—D. Gale \"[size=117]ℑ♥λ[/size]\"—Toto

Lutz

#5
this one always puts the cursor at the end of the buffer:



http://newlisp.org/download/development/newlisp-edit-115.lsp">http://newlisp.org/download/development ... it-115.lsp">http://newlisp.org/download/development/newlisp-edit-115.lsp

hsmyers

#6
Excellent! Not only looks better(at least to my compulsively neat-freak eyes) but works as well!!



--hsm
\"Censeo Toto nos in Kansa esse decisse.\"—D. Gale \"[size=117]ℑ♥λ[/size]\"—Toto