Shoutbox

[Release] Programming Language Keywords Script - Printable Version

-Shoutbox (https://shoutbox.menthix.net)
+-- Forum: MsgHelp Archive (/forumdisplay.php?fid=58)
+--- Forum: Messenger Plus! for Live Messenger (/forumdisplay.php?fid=4)
+---- Forum: Scripting (/forumdisplay.php?fid=39)
+----- Thread: [Release] Programming Language Keywords Script (/showthread.php?tid=62949)

[Release] Programming Language Keywords Script by Paril on 07-10-2006 at 02:24 AM

Derived from C/C++ Keywords Script, now comes the same script, with 20 languages! This plugin supports the following languages:

(Name                  Code)

PHP                        php
C/C++                    c
Perl                        perl
Java                       java
Visual Basic            vb
C#                          csharp
Ruby                       ruby
Python                    python
PL/I                         pli
SQL                         sql
Jscript                      jscript
Javascript                javascript
Actionscript             actionscript
HTML                       html
VBScript                  vbscript
BASIC                      basic
COBOL                    cobol
Lisp                          lisp
Scheme                    scheme
Common Lisp           clisp

How to use:

[ code=language code] code [/ code]

(without the spaces between [c and [/c )

When TagCode is on, it will show this:

langname Start:
code
langname End


Commands:
*TagCodeOff - Turn off the langname Start and langname End, and just keep the code
*TagCodeOn - Turn on the langname start/end


Notes/bugs:

1. Putting a newline after your [ code=langname], It will do this:

langname Start:

code
langname End

2. HTML does not fully work. It only supports 3 tags; body, table and and head. the tag "html" is still in progress, as it causes a few minor things to happen.


Menus:

This script also goes into the menu. It shows a list of all languages (Clicking the language will put the proper code in your current window, with the text you have already to inside the tags), a Help dialog that tells you how to use it, and an About dialog to show you that I made it.


Download:

You can find the script at my Apache server, while I send it to MsgPlusLive for the script database.
http://paril.servequake.com:8080/Paril's%20Scripts/


Contact:

If you need any help with this script, please email me or add me to your MSN, at jonno.5000@gmail.com.

Also, if you want to request another programming language for the next released version, give me the name and a list (or site) of the keywords available.


Credits:

I would like to thank various people;
GamingG - For giving me great hosting, and for various testing
ShadowDragon - Helping me with most of the script, and the menuing. Pretty much the co-owner of the script, as he did most of the writing since I was moreso a beginner (and still am, in this case)
J-Thread - For the NickChange script, which was an inspiration on the menuing, being the creator of NickChange, and reminding me I spelt his name wrong
ShawnZ - Testing, commments, suggestions, Language suggesions
ajd - Testing, comments, support.

If I forgot anyone, PM me, and I'll add you :)


!Have fun!


RE: [Release] Programming Language Keywords Script by AberNStein on 07-10-2006 at 02:34 AM

awesome!


RE: [Release] Programming Language Keywords Script by Paril on 07-10-2006 at 02:36 AM

Thank you :)

Expect a new release soon. Fans of Stephen Colbert (of the Colbert Report) will like this next one ;)


RE: [Release] Programming Language Keywords Script by Chestah on 07-10-2006 at 03:47 AM

I'll download now! This looks like a VERY useful script :)! Thankyou very much

Suggestions:

Before you submit fix up the "how to use" window (its not formatted and positioned very well)

In the about box, turn your website address into a clickable link.


RE: [Release] Programming Language Keywords Script by Paril on 07-10-2006 at 05:36 AM

I see nothing wrong with the how-to Window, it's how I wanted it to be >>"

I will turn it into a link. Is it [url][/url]?


RE: [Release] Programming Language Keywords Script by giac jr on 07-10-2006 at 06:03 AM

I..Dont understand :P


RE: [Release] Programming Language Keywords Script by Paril on 07-10-2006 at 06:29 AM

Should be easy to get how to use it, if that's what you're asking.
Check the Help menu.

I'll make the box smaller, but I really don't see the problem with it :P


RE: [Release] Programming Language Keywords Script by Thor on 07-10-2006 at 08:35 AM

Great work!

This is really useful! Thanks :)


RE: [Release] Programming Language Keywords Script by J-Thread on 07-10-2006 at 09:00 AM

quote:
Originally posted by Paril
(The creator of NickChange) - For the NickChange script, which was an inspiration on the menuing

Make that J-Thread(Y);) It is good to hear I helped you!!:D

It is a great script, this is really really usefull!!! I think this will be the script that I use the most:D
RE: [Release] Programming Language Keywords Script by Ezra on 07-10-2006 at 09:09 AM

It's a great script but I'm missing colored literals.

And maybe a way to define your own colors?


RE: [Release] Programming Language Keywords Script by alexp2_ad on 07-10-2006 at 09:16 AM

Good script... couple things:

* Default code colour should be black imo, and not your text colour.  That's nice and easy to do.
* More importantly, when you add tags to your script, make them compatible with the [n] tags!


RE: [Release] Programming Language Keywords Script by Paril on 07-10-2006 at 01:04 PM

quote:
It's a great script but I'm missing colored literals.

And maybe a way to define your own colors?[/code]

Actually, yes, there will be next version.. you read my mind >>;;

quote:
Originally posted by J-Thread
Make that J-Thread(Y);) It is good to hear I helped you!!:D

It is a great script, this is really really usefull!!! I think this will be the script that I use the most:D

Alright, I will edit it.
Thanks for the feedback. I do like the script myself, and I use it alot.

quote:
Originally posted by Nitrolinken
Great work!

This is really useful! Thanks :)

Ditto, thanks :)

EDIT:

quote:
Originally posted by alexp2_ad

* Default code colour should be black imo, and not your text colour.  That's nice and easy to do.
* More importantly, when you add tags to your script, make them compatible with the [n] tags!
[/code]
Well, the default colour for most applications for syntax highlighting is blue, and I seem to like it.
You will be able to select your colours, later on, next version.

EDIT:
The script uses the [c] tag to color, so no matter what, the script won't work with [n] >>'


-Paril


RE: [Release] Programming Language Keywords Script by Silentdragon on 07-10-2006 at 07:49 PM

I think he means if its not a keyword make that text black instead of it being the regular font color, I mean hey I know plenty of people who use blue which would defeat the purpose of syntax highlighting.

And I think I deserve a bit more credit than helping you, so its unfair you say you wrote the script. We more of co-wrote it.


RE: [Release] Programming Language Keywords Script by NiteMare on 07-10-2006 at 08:02 PM

nice script, (y), very useful


RE: RE: [Release] Programming Language Keywords Script by alexp2_ad on 07-10-2006 at 09:40 PM

quote:
Originally posted by Paril

Well, the default colour for most applications for syntax highlighting is blue, and I seem to like it.
You will be able to select your colours, later on, next version.

EDIT:
The script uses the [c] tag to color, so no matter what, the script won't work with [n] >>'

-Paril

You misunderstood both my suggestions. :P  You should set the default, non-highlighted text to black, eg variable names etc.

And the [n] tag, you should make it so the n tag shows what you have entered, so if I put in an n tag, my contacts will see [code= jscript]function cheese(){ return "cheese"; }[ /code]  and not the highlighted version... it should show it as I typed it, not replaced, not highlighted, not changed.  I know that isn't particularly useful but it's just good coding practice for tags.
RE: [Release] Programming Language Keywords Script by Paril on 07-10-2006 at 11:07 PM

Oh, Thanks.

Yeah, I was thinking of that, but next version supports color changing ;)

About the [n] tag, it'll take a while, but I'll see what I can do for you :)


RE: [Release] Programming Language Keywords Script by Paril on 07-10-2006 at 11:24 PM

quote:
Originally posted by Silentdragon
And I think I deserve a bit more credit than helping you, so its unfair you say you wrote the script. We more of co-wrote it.

Yeah, I know, I couldn't think of the right thing to write under your name.. It's moreso our script, as you did do most of the code, because I didn't really know alot about how to use Jscript or consuming code.. :(


EDIT:
And about the black text, Yes, I know what he meant, just that I don't like people being limited to one color, which is why the next version will contain a configuration menu to change your colors (except the main text, just keywords, comments and strings).
RE: [Release] Programming Language Keywords Script by J-Thread on 07-11-2006 at 07:08 AM

quote:
J-Script - For the NickChange script, which was an inspiration on the menuing

Err LOL, that's not exactly how my name is spelled*-)
RE: [Release] Programming Language Keywords Script by Paril on 07-11-2006 at 02:26 PM

AHaha, sorry, I must of been typing something else at the same time >>;;


Update:
The new version is running smoothly, I'm still trying to get all of the colors in one list. The [n] tag fixer will also be in the next version. Expect a version out in a few days!


RE: [Release] Programming Language Keywords Script by Silentdragon on 07-17-2006 at 06:00 AM

Well since he never decided to release the update, I will. [n] [/n] tags will omit parsing for colors for everything inside. Configuration Menu lets you style your Default, String, Comment, Keyword colors manually or through the little color dialog. If you want colors that are not choosable you have to do [c=#HexColor] for those ones. Stores your settings in registry, and provides a preview of your coloring styles in the window. I also updated the about window a bit. Enjoy.

Ps. I did the final touchups on linux so I dunno if it mangled the files are not. Someone test and see if the xml files are still unicode please.


RE: [Release] Programming Language Keywords Script by Paril on 07-19-2006 at 02:30 PM

Yeah, MSN's been acting really weird lately, such as not showing everyone on my list or showing no one.

I wasn't done with it though, I still have a few more things to do.