Roy Wiseman | 1 Jan 2004 23:46
Picon

Re: Scite-interest Digest, Vol 7, Issue 30

Hi,
Checked the documentation but I can't see a way to add buttons to the toolbar. It could be good to have options to make Compile, Build, Go, Stop Execution, Wrap buttons visible for instance ?
Scite is the best editor i've ever used, but I guess that one thing I did like having in TextPad was an option to have multiple documents open as seperate tabs. Any chance that could be added to scite ? I tried setting tabbar.visible=1 but it doesn't seem to do anything ... 
Cheers,
Roy.

Message sent via Totalise Webmail - http://www.totalise.co.uk/
_______________________________________________
Scite-interest mailing list
Scite-interest <at> lyra.org
http://mailman.lyra.org/mailman/listinfo/scite-interest
Bruce Dodson | 2 Jan 2004 20:55
Picon
Favicon

Lua scripting update

I made a few small changes to the scite/lua source code
published on my web page,
http://gisdeveloper.tripod.com/scite_lua.html.

New stuff listed below:

Support for the keymod type in iface functions: Pass in a
string with the same notation as is used for keybindings in
SciTEGlobal, and it gets parsed into a keymod.  (This
feature is untested.)

Support for implicit string length: if an iface function's
first parameter is "int length", and its other parameter is
a string, then the length parameter is optional; it is
inferred from the string if it's not specified explicitly.

Likewise, if an iface function's first parameter is "int
length" and its other parameter is a stringresult, then you
can just pass in the length; a buffer will be allocated and
the stringresult returned as a second return value.
(Functions that take a stringresult but don't have a length
param are also handled; just pass the length that you want
the buffer to be.  If this is too hackish I'll remove it.)

I didn't add support for the findtext type because the only
function that uses this is FindText, which is already
exposed nicely as editor:search (could be renamed
editor:find).

I have not fully tested these changes, but have to get going
now and I wanted to share what I have so far.

Sincerely,
Bruce

ps. I'm not too worried about the stability / robustness of
the code anymore; it seems to be holding up much better to
testing than it was in the first half of December.  No more
unexplained crashes.  Darren's results with VC are very
encouraging as well.
Mike Wuetherick | 3 Jan 2004 00:17

getting started

just wanted to thank the developers of scite (and filerx).

i've been looking for something similar for a while now and haven't 
found as thorough of an ide anywhere yet (that isn't dependent on an 
existing language).  i've already got the basics of an api for our game 
engine's scripting language started and should have context-help lookup 
working shortly as well.

i'm currently developing/expanding filerx as an ide of sorts for our 
game engine, providing the high-level management of resources, etc. 
scite has become the starting point for a scripteditor for our scripting 
language (simkin), which is based off of 'c', so it's been pretty easy 
to integrate so far.

awesome contribution to the open source community.

couple of initial questions:

- what are the base minimal files that i need to include for JUST c++ 
compatibility?  can i remove all of the 'properties' files for the other 
languages?  just curious, i'll figure it out from experimentation i'm sure.

- about auto-complete.  do i just need to create an 'api' doc for our 
scripting language, based on the same format as the existing ones?  is 
there anything special i need to add to a properties file to get scite 
to do the lookup in the api?

thanx in advance

cheers
mike w
rf dev team
www.realityfactory.ca
April White | 4 Jan 2004 21:07
Picon

lua scripting and other events

Hello everyone, and a Happy New Year belated

I was foreseeing a wee bit of snow around here today - damn late if you
ask me :-) so I was going to play with SciTE and Lua some more.

Well, the snow has not arrived, but I'm still going to play!

I have successfully got everything to work together, even the interface
to all exposed functions in the .iface file.  Thank you Neil and Bruce!

My current script file saves the current position when the file
is closed, and restores it when the file is opened again.

I have other ideas in my mind for what I want, but some of them are not
implementable via the existing events, nor possibly even new events.

For examine, while I am working on sorce code, I have a habit of placing
my name and date in a comment when I make a change.  In the dos editor I
used, I could create hot-key shortcuts to functions that were then
compiled into the exe itself.  This way, I hit Ctrl+Shift+D to insert
what I want.

I know I can write a script something like:
function Me( CommentCharacter )
    editor:insert( GetCurrentPos(),
     CommentCharacter .. ' ' ..
     os.getenv( "USERNAME" ) ..
     os.date( " %Y-%m-%d %H:%M:%S" ) )
end
but how would SciTE access it?

I tried using the OnChar() event, but two difficulties quickly showed.
First, returning 1 or 0 did not tell SciTE to discard the key entered
- it got inserted into the file along with the comment; secondly, since
only the character itself it passed in and not any control/shift/alt
status, it would be hit-or-miss to get the proper key code.  For
examine, string.byte( TheChar ) == 4 matched for Ctrl+Shift+D, but
nothing appeared for Ctrl+Alt+D.

So I got to thinking :-)  yes it is dangerous

The SciTE.h file states "These are located 100 apart. No one will want
more than 100 in each menu ;)", so there is already enough space for
custom commands, it should only be a matter of getting SciTE to retrieve
the proper script info and execute.  If we assume that no more thank 10
commands will be associated with keyboard shortcuts, the other 90 should
be free to exploit.

If  I added:
user.shortcuts=\
Ctrl+Shift+D|IDM_TOOL+20|
(where IDM_TOOL+20 would be replaced by the actual value)

and
command.20.*.cpp=Me( "// " );
command.20.*.bat=Me( "rem " );
command.20.*.lua=Me( "-- " );

Then SciTE detects that the command number is above the base 10 keyboard
values, retrieves the command and passes it onto Lua instead of the
shell system.
I would hazard that either the command string be pre-processed by the
environment expansion code, or environment variables be made available
to Lua scripts so that current conditions may be determined.
ie.  command.20.*=Me( "$(FileNameExt)" ) --  the script will determine
the command indicator to use based on the extension of the file

Comments, criticism, discussion... all are welcome, to help pass a
wonderfully snowy day in doors :-)

ttfn
April

--

-- 
If you want breakfast in bed, sleep in the kitchen.
April White | 5 Jan 2004 03:29
Picon

Re: lua scripting and other events

April White wrote:

> ...  If we assume that no more thank 10
> commands will be associated with keyboard shortcuts, the other 90 should
> be free to exploit.

I guess the SciTE list is down, but I'll try to post this anyway :-)

I've played with the changes I described before - relatively simple 
changes, to get the ::ToolMenu() code to retrieve the script, and to be 
ready to pass it onto Lua.  However, since the Lua engine interface is 
buried within LuaExtesion.cxx, my attempts to create a new lua_State and 
use it caused an ABEND.

Maybe a method added to the extendor class, doCommand() or 
ExecuteCommand() or some such, that will receive the command string and 
execute it...

> ie.  command.20.*=Me( "$(FileNameExt)" ) --

The ToolMenu() code did not replace the above property - I display it 
via MessageBox().  Could it be because of the enclosing quotes?
April
Roy Wood | 5 Jan 2004 20:33

Re: REQ: Functions and other lists

> > used this in a dos editor at work for years and rely so much upon it it 
> > is second nature

I haven't had time to actually implement it, but I took a look at the feasibility of adding a popup menu (like
the auto-complete popup) to support this sort of thing, and it seems pretty straightforward.  I too miss
this functionality from CodeWarrior, and would love to add it.

If anyone has suggestions for how he/she would like this to work, please sound off now.  

So far, my only thoughts are to run a regex on the current textfile, putting the output into the popup menu. 
The regex is specific to the type of file being edited (e.g. C/C++, Python, etc.), and is configured in the
usual properties files.  When a popup item is selected, the cursor moves to the associated location, and
everyone is happy.

Oh-- and I know that doing this via a regex is NOT always going to work perfectly, but running ctags every time
is a little heavy.

Comments?

-Roy
Avi Yegudin | 6 Jan 2004 15:18
Favicon

verilog/specman coloring.

Hi, All.
  Are somebody planning to add verilog and/or specman(e) lexers.

Thanks,
 Avi.

--

-- 
___________________________________________________________
Sign-up for Ads Free at Mail.com
http://promo.mail.com/adsfreejump.htm
KenCheri Randall | 7 Jan 2004 04:07
Picon

testing receiving email

Hi
 
I've not got anything from SciTE list after 12/24/2003.
If all well, I'll get this back.
 
Ken Randall
 
email kencheri at austin dot rr dot com
_______________________________________________
Scite-interest mailing list
Scite-interest <at> lyra.org
http://mailman.lyra.org/mailman/listinfo/scite-interest
Stefan Daugaard Poulsen | 7 Jan 2004 08:59
Picon

New features...Simple ?

Hey guess

I wondered why there ain't a "Close All", i could se a use of it when i open
one of my sessions and need to clear all buffers, before i start a new
project.

Regarding sessions is it possible to make a drag'n'drop feature so i can
drag .ses files into SciTE.

From
	Stefan D. Poulsen
Roy Wood | 7 Jan 2004 16:20

List still active?

Is this mailing list still working?  Seems like nothing has come through since the new year.  And the archives
at http://mailman.lyra.org/pipermail/scite-interest/ don't show any traffic either.  Maybe
something broke?

Testing....1....2....3....

-Roy

Gmane