while debugging some javascript i have come to see that TexMate has an issue with the CSS selector, border-width written in Javascript as style.borderWidth
If i write style.backgroundColor, it will show in color green in Textmate.
I have retained the TextMate default color scheme in preferences/fonts colors/Mac classic.
when i write style.borderWidth it stays black as if it were a variable.
I would assume the Browser compiler or interpreter engine ? would accept the Javascript script as is, and that TextMate would not be adding any encoding to its interpretation of the script while showing style.borderWidth as invalid.
i am learning javascript from a book and the author is not ordained by thy holy one and this script works to some degree, yet is off balance, this is what i am working on. <!-- /* <code> var d1 = document.getElementById("div1"); var d2 = document.getElementById("div2");
d1.onmouseover = function() { d1.style.backgroundColor = "00ff00"; d2.style.borderWidth = "7px"; };
d1.onmouseout = function() { d1.style.backgroundColor = "#ffffff"; d2.style.borderWidth = "1px"; }; </code> */ --> I have composed this message offline going over the message many times to see that it is concise and to the point, forgive me if it is long winded and confusing. Thank you
On Dec 12, 2010, at 12:39 AM, trout swim wrote:
while debugging some javascript i have come to see that TexMate has an issue with the CSS selector, border-width written in Javascript as style.borderWidth
If i write style.backgroundColor, it will show in color green in Textmate.
I have retained the TextMate default color scheme in preferences/fonts colors/Mac classic.
when i write style.borderWidth it stays black as if it were a variable.
This just happens because the JavaScript grammar in TextMate isn't aware of a constant named “borderWidth”. The maintainer of that bundle is probably on this list and can add it. (Or you could add it yourself, but language grammars can be pretty intense.)
I would assume the Browser compiler or interpreter engine ? would accept the Javascript script as is, and that TextMate would not be adding any encoding to its interpretation of the script while showing style.borderWidth as invalid.
Yes, the code (in any language) will work if it's written correctly, regardless of how TextMate displays it.
On 13 Dec 2010, at 15:02, Rob McBroom wrote:
On Dec 12, 2010, at 12:39 AM, trout swim wrote:
when i write style.borderWidth it stays black as if it were a variable.
This just happens because the JavaScript grammar in TextMate isn't aware of a constant named “borderWidth”. The maintainer of that bundle is probably on this list and can add it […]
I opened this issue: https://github.com/textmate/javascript.tmbundle/issues#issue/1
I believe Michael Sheets is looking into it.
Thank you Rob McBroom -----------------------------------------------------
On Mon, Dec 13, 2010 at 6:02 AM, Rob McBroom mailinglist0@skurfer.comwrote:
On Dec 12, 2010, at 12:39 AM, trout swim wrote:
while debugging some javascript i have come to see that TexMate has an
issue with the CSS selector, border-width written in Javascript as style.borderWidth
If i write style.backgroundColor, it will show in color green in
Textmate.
I have retained the TextMate default color scheme in preferences/fonts
colors/Mac classic.
when i write style.borderWidth it stays black as if it were a variable.
This just happens because the JavaScript grammar in TextMate isn't aware of a constant named “borderWidth”. The maintainer of that bundle is probably on this list and can add it. (Or you could add it yourself, but language grammars can be pretty intense.)
I would assume the Browser compiler or interpreter engine ? would accept
the Javascript script as is, and that TextMate would not be adding any encoding to its interpretation of the script while showing style.borderWidth as invalid.
Yes, the code (in any language) will work if it's written correctly, regardless of how TextMate displays it.
-- Rob McBroom http://www.skurfer.com/
textmate mailing list textmate@lists.macromates.com http://lists.macromates.com/listinfo/textmate