Can you recommend a language to

Hi,

Second question for the evening, but very closely related to the first.

I’ve written some monitoring software at work, and would like to
extend it quite a bit, including a gui with a few graphs.
Ruby is causing me grief when it comes to distributing it (see ‘Oh
the Pain!..’), and assuming there’s no way to overcome this, can
anyone recommend a language that:

  • has a canvas with anti-aliasing, alpha-blending and double
    buffering (or binding to a toolkit with one)
  • is simple to distribute
  • is cross platform (*nix and Windows)
  • is not Java (I actually like Java, I’m just trying to get away from
    it)
  • graphing libraries a bonus. Don’t mind writing my own.

I’ve considered a web app, but two things stand in my way:

  • Somewhere to host it (not much here you guys can help with)
  • Graphs becoming images and constant page refreshes chewing up
    bandwidth on the LAN.
    I need to be able to update the graphs and any other displays
    regularly (every minute or so) without sending another whole page.
    Currently all I’ve seen of web graphs are generated on the server and
    sent out as images. I’d like the ability to make them interactive
    down the track, if possible.

Any help, advice or war stories much appreciated.

Cheers,
Dave

On 7/6/07, Sharon P. [email protected] wrote:

  • has a canvas with anti-aliasing, alpha-blending and double
    buffering (or binding to a toolkit with one)
  • is simple to distribute
  • is cross platform (*nix and Windows)
  • is not Java (I actually like Java, I’m just trying to get away from
    it)
  • graphing libraries a bonus. Don’t mind writing my own.

Consider JRuby,
pth

On 7/6/07, Sharon P. [email protected] wrote:

Currently all I’ve seen of web graphs are generated on the server and
sent out as images. I’d like the ability to make them interactive
down the track, if possible.

It is possible to do real time graphs on the web using JavaScript.

www.okcupid.com has JS-generated graphs that seems to work everywhere;
they’re fairly slow, though.

A quick search found this open source library for generating graphs,
not sure if it is fully portable or not:
http://www.liquidx.net/plotkit/

There’s a commercial component in Bindows; I’ve not tried them, and
can’t say if they’re good or not. http://www.ejschart.com/ is a
commercial component that specialize in this.

I’m fairly sure I’ve seen other ones, too, I just don’t have links
handy.

Eivind.

On 7/6/07, Sharon P. [email protected] wrote:

the Pain!..'), and assuming there’s no way to overcome this, can
anyone recommend a language that:

  • has a canvas with anti-aliasing, alpha-blending and double
    buffering (or binding to a toolkit with one)
  • is simple to distribute
  • is cross platform (*nix and Windows)
  • is not Java (I actually like Java, I’m just trying to get away from
    it)
  • graphing libraries a bonus. Don’t mind writing my own.

Python. I hate to say it, especially since Ruby is my usual first
choice, but Python’s bindings to libraries to do the graphical things
you mention are far more mature than those available to Rubyists.
Python is also possibly more cross-platform (in a pragmatic sense),
especially as it comes as default with many Unix variants.

Cheers,
Peter C.

On 7/6/07, Sharon P. [email protected] wrote:

  • has a canvas with anti-aliasing, alpha-blending and double
    buffering (or binding to a toolkit with one)
  • is simple to distribute
  • is cross platform (*nix and Windows)
  • is not Java (I actually like Java, I’m just trying to get away from
    it)
  • graphing libraries a bonus. Don’t mind writing my own.

Consider JRuby, or another of the JVM languages - there’s a lot more
to the JVM than Java, and you’ll get the entire range of library
support.

martin

On Jul 06, 2007, at 07:29 , Sharon P. wrote:

  • has a canvas with anti-aliasing, alpha-blending and double
    bandwidth on the LAN.
    I need to be able to update the graphs and any other displays
    regularly (every minute or so) without sending another whole page.
    Currently all I’ve seen of web graphs are generated on the server
    and sent out as images. I’d like the ability to make them
    interactive down the track, if possible.

Any help, advice or war stories much appreciated.

Cheers,
Dave

http://fiveruns.com/ is not just for rails and it might do everything
you need already.

Sharon P. wrote:

(or binding to a toolkit with one)
(every minute or so) without sending another whole page. Currently all

By monitoring, are you talking about a bunch of systems, processor
utilization, network bandwidth, disk, memory, etc.? If so, there are
full open-source packages that do this already! Many of them have at
their core a marvelous invention called “rrdtool”, which has bindings
for all of the major scripting languages including Ruby. But if you’re
willing to do Perl, PHP and/or Python, there are two fairly complete
front ends, Cricket and Cacti. I forget which languages these two use,
but given that RRDTool is the core, you should be able to hack upon them
in Ruby as well.

On Jul 6, 2007, at 7:29 AM, Sharon P. wrote:

You’re looking to hard!

Assembly will do what your looking for! You just need to know a
little more than your average assembly developer.

aRi
--------------------------------------------|
If you’re not living on the edge,
then you’re just wasting space.

Firefox supports the Javascript canvas component, which can do all
those things for you in ok speed (I think) (it’s based on Cairo which
I love).

Hosting a web app in a LAN should really not be a problem. Just host
it on your own box.

That should make the web app viable.

Aur

Hi everyone,

Thanks for the suggestions. There’s a little more detail I’ve put in
the other post, ‘Oh the pain!’, but I’ve spent the last half a day
playing with JRuby and think this may be the way to go.

Looks like a brilliant idea and I can use swing for the gui (I’m
quite familiar with swing, so no new learning here).

On a related note, anyone got anti-aliasing working with JRuby? My
code (canvas is a JPanel):
canvas.getGraphics.setRenderingHint(RenderingHints::KEY_ANTIALIASING,
RenderingHints::VALUE_ANTIALIAS_ON)
runs with no errors, draws what I expect, but no anti_aliasing. I’m
pretty sure this is due to my not understanding properly the change
in syntax from Java to Ruby.
[I’ve also posted this to the JRuby list ([email protected]). but don’t know how popular it is.]

Cheers,
Dave