As I can't find, I think that write one myself would be a good idea.
I began some minutes ago, and this is what I have until now:
#begin _javascript_ API
alert( [string Message])
charCodeAt(index)
concat(Required. The first array object to add to a new using concat,Required. The second array object to add to a new using concat [, array ...]) Joins sereval arrays and returns a new array
deleteRow( [iRowIndex])
fromCharCode(num1, ...., numX) Returns a character from the Unicode value
getDate()
getElementById("id") Returns a reference to the first object with the specified ID
getElementsByTagName("tag") Returns a collection of objects with the specified TAGNAME
floor(x)
go(vLocation)
innerHTML(string)
join(separator) Puts all the elements of an array into a string, divided by a specified separator
match(search) Similar to indexOf() and lastIndexOf(), but this method returns the specified string, or "null", instead of a numeric value
parseFloat("string") Converts an string to a floating point number
parseInt("string", numbersystem) Converts a string argument to a number in a specified number system
pop() Removes and returns the last element of an array
shift() Removes and returns the first element of an array
slice(begin, end) Creates a new array from a selected section of an existing array
sort(Optional. Must be a function capable of comparing the elements of an array) Sorts the elements of an array
splice(index, howmany, element1, ....., elementX) Adds and removes elements of an array
substr(start, howmany) Returns the specified characters. 14,7 returns 7 characters, from the 14th character (starts at 0)
toLowerCase() Converts a string to lower case
toString() Converts a Boolean value to a string
toUpperCase() Converts a string to upper case
reverse() Reverses the order of the elements in an array
#end _javascript_ API
And these are the relevant lines on my config file:
file.patterns.js=*.js
api.$(file.patterns.js).=/home/walter.cruz/.scite/_javascript_.api
calltip.$(file.patterns.js).end.definition=)
As scite use the cpp lexer to analize the js, I'm using this to make the autocomplete (althoug I think that I will get this off)
autocomplete.cpp.start.characters=$(chars.alpha)
But, I'm with a doubt. By example, the getElementById is a static method from the document object.So, the better way to do this on the api file would be:
document.getElementById("id") Returns a reference to the first object with the specified ID
But when I put the . (dot) in the after document, the calltip is not displayed anymore.I've tried to put a line like this:
calltip.$(file.patterns.js).word.characters=.$(chars.alpha)
But doen't work too. How can I do that (i've seen that the lua api files has functions with a dot inside).
Thanks on advance!
_______________________________________________ Scite-interest mailing list [email protected] http://mailman.lyra.org/mailman/listinfo/scite-interest
