Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

SciTE-ez - Programmers editor with LSL support

Keiki Lemieux
I make HUDDLES
Join date: 8 Jul 2005
Posts: 1,490
12-18-2005 13:47
This looks great!

I downloaded the editor and I'm wondering what I do with the 1.8 lsl.api file
_____________________
imakehuddles.com/wordpress/
Strife Onizuka
Moonchild
Join date: 3 Mar 2004
Posts: 5,887
12-18-2005 15:46
If you got Scite-ez then just unzip the above to "C:\Program Files\Scite-ez"
or where ever you installed it.
_____________________
Truth is a river that is always splitting up into arms that reunite. Islanded between the arms, the inhabitants argue for a lifetime as to which is the main river.
- Cyril Connolly

Without the political will to find common ground, the continual friction of tactic and counter tactic, only creates suspicion and hatred and vengeance, and perpetuates the cycle of violence.
- James Nachtwey
Keiki Lemieux
I make HUDDLES
Join date: 8 Jul 2005
Posts: 1,490
12-18-2005 15:54
From: Strife Onizuka
If you got Scite-ez then just unzip the above to "C:\Program Files\Scite-ez"
or where ever you installed it.

okie. ty :)
_____________________
imakehuddles.com/wordpress/
Bobby Dayton
Test Pilot for Airfix
Join date: 15 Nov 2003
Posts: 206
01-19-2006 09:10
Has anyone had any luck on running a Mac version of Scite yet. I saw an earlier posting about an X11 version but couldnt get it working. I did find this which hints there might be a full OSX port of it.

http://mailman.lyra.org/pipermail/scintilla-interest/2005-August/006575.html

I don't know if its any use.
Ezhar Fairlight
professional slacker
Join date: 30 Jun 2003
Posts: 310
01-19-2006 09:43
There is a MacOS / X11 build of SciTE available, but it's a bit outdated(?), requires GTK and feels quite alien on the Mac.

The post you linked to refers to porting Scintilla (the editor component) to the Mac, but not SciTE (the editor itself, i.e. the UI).

Personally I'm using SciTE only on Windows, on the Mac I use TextMate for everything. Maybe somebody will like it enough to create a LSL bundle for it :)
_____________________
Folco Boffin
Mad Moo Cow Cultist
Join date: 27 Feb 2005
Posts: 66
02-10-2006 12:36
Tried posting in a seperate thread, but haven't gotten a response yet, so hopefully by bumping this thread I'll get a response.

I've tried a few things to get SciTE-ez to compile an .esl file. Nothing has worked so far and I'm obviously missing something simple. At first I just forgot to add the C++ pre-processor directory to the PATH. Fixed that after slapping myself a few times for good measure.

But then because I tried to use #include "debug.esl" and am getting a error on no include path. So I poked around and found the batch file in the MS C++ directory that sets varibles for INCLUDE and LIB as well as PATH, so I went and added system varibles for INCLUDE and LIB (including both MS's include directory and my own directory for my .esl include files) but still get the error that no include path is set.

I also tried taking out the include and just put the #ifdef DEBUG statements in the original code. But now I get a new error. 'C:\Program' is not recognized as an internal or external command, operable program or batch file. I'm not sure what gives on this one as I'm sure the updated files from Strife are setup properly for use with names with spaces in them. (There are quotation marks around $(FileNameExt) and such.) This one just blows my mind as it should be able to work with spaces and such.

As for the includes not working, I just realized in lsl.properties there's a section for pre-processor settings and has if, ifdef, else, endif, and others, but include isn't included anywhere in this list. I'm guessing that has something to do with me not being able to use includes. But I'm still at a loss on spaces in the name. I suppose I could always run SciTE-ez from a directory with no spaces, re-install MS V C++ to a directory with no spaces and all my scripts are already in a directory with no spaces. But I know it should work with spaces so I'm just confused...

Also, is my hypothesis on why includes aren't working correct? If so, what should I add to the lsl.properties file to get them to work?

Here's what it has in the pre-processor section:
CODE
# Preprocessor settings
preprocessor.symbol.$(file.patterns.cpp)=#
preprocessor.start.$(file.patterns.cpp)=if ifdef ifndef
preprocessor.middle.$(file.patterns.cpp)=else elif
preprocessor.end.$(file.patterns.cpp)=endif


But for that matter, it recognized #define I think... Gah, I'm just confusing myself more now.

Can someone spare a minute or two to help me get this working?
_____________________
^-^

Signed,
Gorgarath,
Whom in this game called Second Life,
plays the avatar Folco Boffin,
and in this game called First Life,
plays the avatar John McDonnell.
Masakazu Kojima
ケロ
Join date: 23 Apr 2004
Posts: 232
02-10-2006 15:32
From: Folco Boffin
'C:\Program' is not recognized as an internal or external command, operable program or batch file.
Are you doing something similar to this?
From: someone
command.compile.*.esl=cmd.exe /c "C:\Program Files\Microsoft Visual Studio 8\vc\bin\cl" /X /u $(esl.strip.comment) /Tc"$(FileNameExt)" /EP > "$(FileName).wsl" && "$(SciteDefaultHome)\stripper.exe" "$(FileName).wsl" "$(FileName).lsl" && del "$(FileName).wsl"


If so, cmd.exe is sort of stupid when you start the command with a quote: it will eat the first and last quote, even if the last quote isn't at the end. So you need to change it to:
From: someone
command.compile.*.esl=cmd.exe /c ""C:\Program Files\Microsoft Visual Studio 8\vc\bin\cl" /X /u $(esl.strip.comment) /Tc"$(FileNameExt)" /EP > "$(FileName).wsl" && "$(SciteDefaultHome)\stripper.exe" "$(FileName).wsl" "$(FileName).lsl" && del "$(FileName).wsl""


Edit: here is the relevant part from cmd.exe /?
CODE
If /C or /K is specified, then the remainder of the command line after
the switch is processed as a command line, where the following logic is
used to process quote (") characters:

1. If all of the following conditions are met, then quote characters
on the command line are preserved:

- no /S switch
- exactly two quote characters
- no special characters between the two quote characters,
where special is one of: &<>()@^|
- there are one or more whitespace characters between the
the two quote characters
- the string between the two quote characters is the name
of an executable file.

2. Otherwise, old behavior is to see if the first character is
a quote character and if so, strip the leading character and
remove the last quote character on the command line, preserving
any text after the last quote character.


If that's not your problem, post your lsl.properties and the output of "set" from the command line and I'll see if I can help.
Folco Boffin
Mad Moo Cow Cultist
Join date: 27 Feb 2005
Posts: 66
02-10-2006 16:18
Yay! Almost. I'm closer. It's running now. But cl is tossing me a bunch of errors.

(Names are changed to protect certain parties.)
CODE

>cmd /c cl /nologo /X /u /Tc""Awesome-People Totally Cool Thingy.esl" /EP >"Awesome-People Totally Cool Thingy.wsl" && "C:\Program Files\SciTE-ez\stripper.exe" "Awesome-People Totally Cool Thingy.wsl" "Awesome-People Totally Cool Thingy.lsl"" && cmd /c ""C:\Program Files\SciTE-ez\clipboard.exe" "Awesome-People Totally Cool Thingy.lsl""
cl : Command line warning D4024 : unrecognized source file type 'Totally', object file assumed
cl : Command line warning D4024 : unrecognized source file type 'Cool', object file assumed
cl : Command line warning D4024 : unrecognized source file type 'Thingy.esl /EP >Awesome-People', object file assumed
cl : Command line warning D4024 : unrecognized source file type 'Totally', object file assumed
cl : Command line warning D4024 : unrecognized source file type 'Cool', object file assumed
cl : Command line warning D4024 : unrecognized source file type 'Thingy.wsl && C:\Program', object file assumed
cl : Command line warning D4024 : unrecognized source file type 'Files\SciTE-ez\stripper.exe Awesome-People', object file assumed
cl : Command line warning D4024 : unrecognized source file type 'Totally', object file assumed
cl : Command line warning D4024 : unrecognized source file type 'Cool', object file assumed
cl : Command line warning D4024 : unrecognized source file type 'Thingy.wsl Awesome-People', object file assumed
cl : Command line warning D4024 : unrecognized source file type 'Totally', object file assumed
cl : Command line warning D4024 : unrecognized source file type 'Cool', object file assumed
cl : Command line warning D4024 : unrecognized source file type 'Thingy.lsl', object file assumed
Awesome-People
c1 : fatal error C1083: Cannot open source file: 'Awesome-People': No such file or directory
>Exit code: 2 Time: 0.310


Any ideas? I need to head to a funeral right now so I can't try anything on my own until I get back. Hopefully someone here can let me know sooner.

EDIT:>> Figure I'll toss in my lsl.properties incase that helps.

CODE

command.go.needs.*.lsl=cmd /c ""$(SciteDefaultHome)\clipboard.exe" "$(FileName).lsl""

command.4.*.esl=cmd /c start scite.exe "$(FileName).lsl"
command.needs.4.*.esl=cmd /c cl /nologo /X /u $(esl.strip.comment) /Tc""$(FileNameExt)" /EP >"$(FileName).wsl" && "$(SciteDefaultHome)\stripper.exe" "$(FileName).wsl" "$(FileName).lsl""
command.name.4.*.esl=Open LSL
command.shortcut.4.*.esl=F6
command.save.before.4.*.esl=1

command.compile.*.esl=$(command.needs.4.*.esl) && $(command.go.needs.*.lsl)

# put LSL or ESL script into clipboard
command.go.$(file.patterns.lsl)="$(SciteDefaultHome)\clipboard.exe" "..\LSL\$(FileName).lsl"
#command.go.needs.*.esl=cmd /c cl /nologo /X /u $(esl.strip.comment) /Tc"$(FileNameExt)" /EP >"$(FileName).lsl"
# ESL scripts are "compiled" first, then the resulting LSL file is put into clipboard (by the line above)
command.go.needs.*.esl=$(command.compile.*.esl)


EDIT AGAIN:>> cl is in my path, already tested in a command promt to make sure it runs.

APPOLOGY:>> Sorry for the side scrolling but I'm posting this while getting dressed and now I really need to get out the door. Thanks for all your help so far, I really appreciate it. And thanks for any additional help you can give.

P.S. Includes work properly now too.
_____________________
^-^

Signed,
Gorgarath,
Whom in this game called Second Life,
plays the avatar Folco Boffin,
and in this game called First Life,
plays the avatar John McDonnell.
Masakazu Kojima
ケロ
Join date: 23 Apr 2004
Posts: 232
02-10-2006 16:53
From: Folco Boffin
command.go.needs.*.lsl=cmd /c ""$(SciteDefaultHome)\clipboard.exe" "$(FileName).lsl""
This one was probably giving you the problem.

From: Folco Boffin
command.needs.4.*.esl=cmd /c cl /nologo /X /u $(esl.strip.comment) /Tc""$(FileNameExt)" /EP >"$(FileName).wsl" && "$(SciteDefaultHome)\stripper.exe" "$(FileName).wsl" "$(FileName).lsl""
Since cl is in your path, you don't need to have a quote right after the /c, so you don't need to double them up. It looks like you added them but put the starting one in the wrong place. Anyway, changing just this line should make it work:
From: someone
command.needs.4.*.esl=cmd /c cl /nologo /X /u $(esl.strip.comment) /Tc"$(FileNameExt)" /EP >"$(FileName).wsl" && "$(SciteDefaultHome)\stripper.exe" "$(FileName).wsl" "$(FileName).lsl"
Folco Boffin
Mad Moo Cow Cultist
Join date: 27 Feb 2005
Posts: 66
02-10-2006 19:13
Ah ha! The clipboard command is probabally the one that was giving me issues since the quote was the first thing after the call to cmd. As for the double quotes in the line with cl, yup that's what was screwing that part up. Which brings me back to this.

I was wrong, includes aren't working (properly). It compiles fine if I give the absolute path to my include, but if I just type the name it gives me the no include path error. This really thows me for a loop since if I go into command and type: echo %INCLUDE% it will tell me my 2 paths for includes. The one for my script includes is first and the one for C++'s includes is second.

Does there need to be something setting the path for includes in the lsl.properties file? If so, what?

While I'm now able to work with this, I'd like to not have to specify absolute path if possible.

But yay! Thank you oh so much. That's odd with cmd ignoring quotes like that. Odd that I never new about it too, though most of my DOS work is in actual DOS w/o long file name support.

I can now get this project finished hopefully by my deadline of noon SL time tomorrow!

I think I already got it fixed by hard coding it in, but hay, now I re-write the debug function at the top to an include and presto, no more debug code in my LSL after I'm done debugging.

*would do a dance of joy if I could dance*

And now I can say horray for semi-global functions of a sort. And if anyone's got ideas on how to get it to recognize that I do have an include path set, that would be great too, though I'll be ok without it.
_____________________
^-^

Signed,
Gorgarath,
Whom in this game called Second Life,
plays the avatar Folco Boffin,
and in this game called First Life,
plays the avatar John McDonnell.
Strife Onizuka
Moonchild
Join date: 3 Mar 2004
Posts: 5,887
02-10-2006 19:20
From: Folco Boffin
This really thows me for a loop since if I go into command and type: echo %INCLUDE% it will tell me my 2 paths for includes.


Is there a semicolon ( ; ) between the two paths?
_____________________
Truth is a river that is always splitting up into arms that reunite. Islanded between the arms, the inhabitants argue for a lifetime as to which is the main river.
- Cyril Connolly

Without the political will to find common ground, the continual friction of tactic and counter tactic, only creates suspicion and hatred and vengeance, and perpetuates the cycle of violence.
- James Nachtwey
Folco Boffin
Mad Moo Cow Cultist
Join date: 27 Feb 2005
Posts: 66
02-10-2006 20:33
Yes. Though I've missed some pretty obvious stuff, I can happily say I didn't forget that one. :D

And yes, I do tech support sometimes, so I know you gotta ask the basics before you get into more complex stuff.

(Has actually had someone who remembered to turn their surge protector on before trying to turn the computer on, but forgot to plug the surge protector into the wall.)
_____________________
^-^

Signed,
Gorgarath,
Whom in this game called Second Life,
plays the avatar Folco Boffin,
and in this game called First Life,
plays the avatar John McDonnell.
Folco Boffin
Mad Moo Cow Cultist
Join date: 27 Feb 2005
Posts: 66
02-11-2006 05:49
In referance to your post over here, I did run the batch file, but it didn't set any varibles within XP itself for some reason. After closting that command prompt and opening a new one, it wouldn't have the varibles set. So I manually put them into my XP system varibles. Now when I start a command prompt I will get:
CODE

>echo %INCLUDE%
D:\include;C:\Program Files\Microsoft Visual C++ Toolkit 2003\include;

>


Just don't see why it doesn't get read when cl is run.
_____________________
^-^

Signed,
Gorgarath,
Whom in this game called Second Life,
plays the avatar Folco Boffin,
and in this game called First Life,
plays the avatar John McDonnell.
Masakazu Kojima
ケロ
Join date: 23 Apr 2004
Posts: 232
02-11-2006 08:18
From: Folco Boffin
no include path error
Adding /I"D:\include" to your cl command line should fix your problem and avoids polluting your normal include paths.

edit:
From: Folco Boffin
Just don't see why it doesn't get read when cl is run.

From: Your lsl.properties
command.needs.4.*.esl=cmd /c cl /nologo /X /u $(esl.strip.comment) /Tc"$(FileNameExt)" /EP >"$(FileName).wsl" && "$(SciteDefaultHome)\stripper.exe" "$(FileName).wsl" "$(FileName).lsl"

From: cl.exe /help
/X ignore "standard places"
Folco Boffin
Mad Moo Cow Cultist
Join date: 27 Feb 2005
Posts: 66
02-11-2006 10:33
Gah! I never learn. I just need to learn to RTFM one of these days. Though I still would have been stumped on cmd removing quotes because I wouldn't expect MS to be that dumb. But I suppose I should have...
Thank you though. It works like a charm now.

(And just to note, I did take a glance at cl /? but the fact it's like 3 pages long was a deterrant from looking too close. Meanwhile I'll read an entire book on it instead, doesn't make sense does it.)

One more question if you don't mind is it possible to go about having it compile normal LSL files with lslint while still running ESL files through the pre-processor (which I'm now piping through lslint)?

Unless I'm mis-reading I can't. Though I suppose it's not a big problem since I can just make everything .esl and cleanup the extra files when working on smaller projects offline.
_____________________
^-^

Signed,
Gorgarath,
Whom in this game called Second Life,
plays the avatar Folco Boffin,
and in this game called First Life,
plays the avatar John McDonnell.
Masakazu Kojima
ケロ
Join date: 23 Apr 2004
Posts: 232
02-11-2006 10:58
From: Folco Boffin
One more question if you don't mind is it possible to go about having it compile normal LSL files with lslint while still running ESL files through the pre-processor (which I'm now piping through lslint)?
If you set lslint as the compiler for *.lsl files, it shouldn't interfere with *.esl files:
command.compile.*.lsl="C:\lsl\lslint.exe" "$(FileNameExt)"

You can run lslint as an extra step for .esl files too, but the line numbers will not be very helpful.
Folco Boffin
Mad Moo Cow Cultist
Join date: 27 Feb 2005
Posts: 66
02-11-2006 23:21
Hehe, yeah. I've noticed that about the numbers. But I open up a copy of the generated LSL file when I can't figure out where the errors are at. Then leave it open until they're all gone since it will re-load the file when changed.

And thanks for the help on straight LSL files. Just wasn't sure how that would work because of the needs.*.esl statements.
_____________________
^-^

Signed,
Gorgarath,
Whom in this game called Second Life,
plays the avatar Folco Boffin,
and in this game called First Life,
plays the avatar John McDonnell.
Strife Onizuka
Moonchild
Join date: 3 Mar 2004
Posts: 5,887
Whitespace stripper
02-13-2006 20:10
The old whitespace stripper that ESL uses only supports lines upto 2047 characters. I was expecting it would handle longer lines by parsing them in chunks. This is not the case.

So i've rewriten the stripper to create a dynamic buffer the size of the file it's stripping. Not optimal for multi megabyte files but will not get stuck in a infinite loop like the old version.

As usual it comes with the C++ source.
_____________________
Truth is a river that is always splitting up into arms that reunite. Islanded between the arms, the inhabitants argue for a lifetime as to which is the main river.
- Cyril Connolly

Without the political will to find common ground, the continual friction of tactic and counter tactic, only creates suspicion and hatred and vengeance, and perpetuates the cycle of violence.
- James Nachtwey
Stylez Gomez
Union Micro
Join date: 4 Jun 2004
Posts: 146
03-06-2006 19:56
Anyone have a download mirror for SciTE-ez? Getting a 404 on the original website. :(
_____________________
Kermitt Quirk
Registered User
Join date: 4 Sep 2004
Posts: 267
03-06-2006 20:49
Looks like the files have been moved and some of the links on the site haven't been updated.
I found the files here.... http://sl.sdfjkl.org/secondlife/scite/download/ by clicking the 'Download' link right at the top of http://sl.sdfjkl.org/secondlife/scite/.
Stylez Gomez
Union Micro
Join date: 4 Jun 2004
Posts: 146
03-06-2006 22:57
DER I didn't see that link up there. Thanks!
_____________________
1 2 3