PDA

View Full Version : IRC Client



zabadab
7 Sep 2008, 5:51 PM
EDIT: I'm no longer developing this and the source is not available. Please do not PM or E-Mail me about this. I don't use Ext JS anymore due to its license restrictions.
-----
First post. :-X



Let's face it: Java Applet clients like "pjirc", "jirc", etc. all suck. They are ugly, big in size, take ages (more than 20 seconds on your average computer) before they load up a UI (that doesn't include the download time) and are generally not very intuitive to use. On a "Web 2.0" page, they feel out of place.

I've gone ahead and am now working on an Ext 2.2-based IRC Client written in Java and JavaScript. It uses a relatively tiny (50KiB) Java Applet that contains an implementation of the IRC protocol (using "irclib") and a command parser (so stuff like /me works). It forwards all IRC events (join, part, etc.) to JavaScript, which takes care of taking the incoming data and putting it into a nice UI.

It takes less than 2 seconds to load the entire thing so far.

Here's a screenshot:

REMOVED

As you can see, it's still in a very early stage of development, but it does already support cool things like mIRC's color codes. Processing events from the Java Applet also works already.

The best thing is that it's extensible. Since JavaScript does all the work with the incoming data, you can just add your own logic to different event functions that get called. Here's a list of events currently supported:


Error : function(num, msg)
Invite : function(chan, user, passiveNick)
Join : function(chan, user)
Kick : function(chan, user, passiveNick, msg)
UserMode : function(user, passiveNick, mode)
ChanMode : function(chan, user, modeParser)
Nick : function(user, newNick)
Notice : function(target, user, msg)
Part : function(chan, user, msg)
Ping : function(ping)
Privmsg : function(target, user, msg)
Quit : function(user, msg)
Registered : function()
Reply : function(num, value, msg)
Topic : function(chan, user, topic)

I plan on making some code or at least a working demo available very soon (i.e. tomorrow or the day after). I just need to reorganize some parts of the JavaScript and take out some debugging code.

I don't intend this to be a full-featured mIRC replacement, but it should be comfortable enough for people who have no IRC experience and just want to chat.

What I'd be interested in is hearing what kinds of features people expect from a web-based IRC client.

Vaevictus
7 Sep 2008, 11:05 PM
Nothing constructive to say but wow, nice work.

devnull
8 Sep 2008, 6:18 AM
Very good stuff, I have always had a desire to make an IRC client in Adobe Air using Ext, but have never gotten around to it :)

aconran
8 Sep 2008, 7:11 AM
Looks very nice, fabulous first post :D

One slight bug I notice from your screenshot and is a common mistake is on the east region you are nesting a TreePanel inside a Panel. Because TreePanel is a Panel it can be used directly within the container that has its layout set to border.

Be sure to put a demo up when you feel it is stable enough and let people hammer at it.

Scorpie
8 Sep 2008, 1:02 PM
Looks very nice indeed!

zabadab
8 Sep 2008, 5:20 PM
Thanks for the feedback so far! :)

Here's an early alpha version: REMOVED
All the interesting stuff is in REMOVED

You need to accept the Java warning in order to connect to anything.

Note that CLICKING CONNECT WON'T WORK. It will try to connect to "localhost"; I didn't want to preset a specific server or channel because that would could possibly annoy the server/channel operator.

To connect to a server, just type /server <server> <port> (the port is optional and defaults to 6667). More information is in the block of text shown on the demo page.

PROTIP: Tools->Java Console is a nice place to look at. It will log all raw IRC activity there. If something doesn't work, you might find relevant information there (which you can then tell me :p)

crawl_from_death
8 Sep 2008, 10:00 PM
Hello zabadab,

Nice tool but ...

when i connected to a greek irc server chat.mad.gr and joined at #mad it couldnt retrieve users... i used IE6,IE7,FF2,WinXP,WinVista

You can see from screenshot

zabadab
9 Sep 2008, 3:44 AM
when i connected to a greek irc server chat.mad.gr and joined at #mad it couldnt retrieve users...

Did you read what it says under the chat window?


Incomplete list of things that don't work:
------------------------------------------
* Nicklist (proving to be rather difficult to implement in JavaScript, but
a skeleton is already there. The code just needs to be written...)

crawl_from_death
9 Sep 2008, 4:38 AM
Sorry my mistake. Maybe you should place it in a better position :)

Anyway eep up the good work

zabadab
9 Sep 2008, 7:49 PM
The nicklist is there now, and with that in place, it's starting to look much more like a proper client.

Take a look at the CSS (http://zabadab.eu/chat/res/style.css) (towards the bottom); I figured using CSS to allow users to customize nicklist icons and colors would be the best way to go.

Additionally, the autoscroller works properly now (it measures each incoming line instead of just assuming each line is 35px high) and Opera/Firefox compatibility was improved. Funnily enough, IE is best at supporting the Java<->JavaScript interaction; it's the only one that can properly convert Java's primitive types to their JS equivalents.


The nicklist still needs to be sorted. I'm not really sure how to go about it. I'm using a TreeSorter now, but I guess I will either have to write my own TreeSorter or use "sortType" to fiddle with the strings before they get sorted.

Richie1985
28 Oct 2008, 7:42 AM
hi, is there any working example? an extjs irc client sound so good :)

drew
2 Nov 2008, 3:47 AM
great idea

xantus
29 Nov 2008, 9:27 PM
I have an IRC client... It's built using web sockets so it could easily port to Adobe AIR. Is anyone interested in helping me turn it into a full featured client? I'd GPL it of course.

To see a demo, go to http://cometdesktop.com/, login and click the IRC icon.

I'm also working on a jabber client with a friend. We also plan on GPL'ing it too.
A working demo of the jabber client is also on the desktop.

Richie1985
19 Mar 2009, 9:53 AM
Hi,

where can i found a demo version? or where can i download something?

thanks :)

zipi
23 Mar 2009, 12:49 AM
nice work, by the screenshots. but sadly, there is no download? please give us :)

thanks

xantus
24 Mar 2009, 11:25 AM
I'm working on a lightweight server in Perl, and then I will release my IRC client after that.

We will be showing Extjs comet stuff at the Ext conference. Get your tickets now...there are only 10 seats left!

Richie1985
25 Mar 2009, 11:51 AM
thats a good idea, but its a far way to florida :(

Foggy
31 Mar 2009, 12:59 AM
Why you want a server in perl if there exists many IRC servers out there?
An installation of any of these IRC server programs is really easy, so i dont see the point of a perl server right now...

Richie1985
31 Mar 2009, 10:20 PM
~o)

Richie1985
16 Apr 2009, 7:38 AM
are there any news?

xantus
17 Apr 2009, 1:56 PM
are there any news?

Read the first post, The original poster stopped working on it.

Richie1985
20 Apr 2009, 11:56 PM
ohh thats realy sad :(

did he removed the source code or can i download a example anywhere?

thx

apphacker
23 Jun 2009, 6:18 PM
I have created an IRC client for Adobe AIR (http://www.apphackers.com) using JavaScript. I haven't officially made it open source or added any kind of license but you can take a look at the code if you unzip the .air file. In particular the irc.js file drives the connection to irc servers. It does not use ExtJS yet either and it comes 'as is' It's still in a very early alpha stage, and there may be some bugs.

xantus
23 Jun 2009, 6:21 PM
I have created an IRC client for Adobe AIR (http://www.apphackers.com) using JavaScript. I haven't officially made it open source or added any kind of license but you can take a look at the code if you unzip the .air file. In particular the irc.js file drives the connection to irc servers. It does not use ExtJS yet either and it comes 'as is' It's still in a very early alpha stage, and there may be some bugs.

If it has nothing to do with extjs, then this can be considered spam...

When do you plan on converting it?

apphacker
23 Jun 2009, 9:59 PM
Seemed like people were interested in code for javascript irc client. I had some. I'm satisfying the need. There's nothing I gain from this by posting it here. I'm still learning ext js so I don't know when I'll convert it. If you feel it's spam, feel free to delete. The only people to lose anything will be the posters who were interested in irc client code in javascript.

xantus
23 Jun 2009, 10:53 PM
Seemed like people were interested in code for javascript irc client. I had some. I'm satisfying the need. There's nothing I gain from this by posting it here. I'm still learning ext js so I don't know when I'll convert it. If you feel it's spam, feel free to delete. The only people to lose anything will be the posters who were interested in irc client code in javascript.

No prob, everything's cool.