Tuesday, March 31, 2009

Extra-creepy ad!




The old men, clad in formal wear but for a couple wearing bikinis, went door-to-door in their vans, selling crude oil. With the money thus attained, the successful bought airplanes; those who were not so lucky became spies. One had no real need of the work, for he had invented Cotton Gin, a cheap alcoholic beverages made of old underwear which has won many trophies, and for which the eponymous industrial machine was named. One or two, competent neither to be airplane owners nor spies, went instead to work for Snap Link Ads.

I used all of the words; do I win a prize?

Monday, March 30, 2009

The Sun's confused views on politics, as applied to the wobbly

The Sun (and everyone else) has an article on the lovely Chawner family, who are really fat, and refuse to get jobs (or, as they claim, can't, due to fatness; this is doubtful, as plenty of fat people have jobs); they also refuse to exercise or eat less, and object to pears.

So far, so boring. Apparently, 2,000 people in the UK are paid a disability thing due to being too fat to work. The Sun, though, takes an interesting tack; the 11 years that they haven't worked coincide with the Labour government. The Sun thinks that this is highly significant. Presumably Maggie, while certainly paying welfare, had all the fat people rendered for use in margarine.

This is perhaps bad timing. It came into the public eye due to one of the daughters going on X Factor and being made fun of by X Factor presenters, and also when the government faces a vast deficit. So, the disability will look like an ideal target for cuts. Through her foolish singing on a boring television programme, Samantha Chawner has doomed thousands of fat people to penury. Or, erm, getting the same social welfare as unemployed people of less ample girth.

Sunday, March 29, 2009

Palin annoyed with godless Republican Party

Sarah Palin on McCain campaign:

"So I'm looking around for somebody to pray with, I just need maybe a little help, maybe a little extra," she said. "And the McCain campaign, love 'em, you know, they're a lot of people around me, but nobody I could find that I wanted to hold hands with and pray."

Yes, that's because they're normal, non-crazy people. Do people actually do this? Real grownups who know how to read and write? This was before the Biden speech. She was looking for God to intervene and tell her what to say to nasty Mr Biden, you see, or possibly to strike him down with heavenly fire.

Seriously. If this person had won, she'd have been one ancient heart-attack-y president away from being the leader of the US. And she needs literal advice from God on what to say to Joe Biden, of all people.

Madness. Mad, the lot of them.

POLITICAL PARTY FOR PEOPLE WHO TALK IN ALL CAPS

LOOK! IT"S A POLITICAL PARTY FOR PEOPLE WHO COMMENT ON BBC HAVE YOUR SAY!!?!

Terrifyingly, they got 80 votes in Scotland.

Representative quote from the slightly more legible mixed-case part of the website:


Our taxes give them their gold plated pensions, sick pay schemes and retrial age of 60.
It is blatant discrimination against private sector workers by the government that we do not receive the same pensions, sick pay or retirement age.
Do you realise that!
That 10% of our council tax goes to fund the sick pay of council employees and that on average council employees take 3 WEEKS SICK ON FULL PAY every year.
That 25% of our council tax goes fund the gold plated pensions enjoyed by council employees.


'Do you realise that!' 'retrial age of 60!'

Somewhere, an obese person who is unemployed because of all those nasty brown people and therefore not at all like the welfare recipients he hates is making another page (no doubt to protest exhorbitant spending on postage stamps, or something) with Frontpage Express while gnawing on a half-defrosted pizza.

Other important non-news from the BBC

(As previously mentioned, we're not allowed real news anymore because it is all far too depressing and recession-y. The BBC has resorted to reporting on tedious non-news)

A Spanish town is cancelling its bullfight, due to the recession. Presumably they will have a bear fight, instead.

Some students in New Zealand threw eggs at people. Presumably, in light of the recession, this will shortly attract the death penalty under rationing laws.

Some Australians participated in a ritual toad-killing:

"This is an example of how the war against cane toads can be won," said Mr Knuth, who hopes to take Toad Day Out nationwide.

Australia, once involved in wars against actual people, is now reduced to killing toads (humanely) and calling it a war, because of the recession. Also:

The majority of toads will be turned into fertiliser or donated to the science department of James Cook University.

Also, they now find themselves having to make fertiliser out of toads, presumably because real non-poisonous-amphibian-based fertiliser is a luxury for people who aren't in recessions.

The phrase "the supreme importance of custard cremes" is on the front page, presumably because custard cremes are relatively cheap biscuits, and thus suitable for the recession. At least until the custard wells run dry.

A BBC reporter talked to the imaginary Russian president (the one who is not Putin; Dmitry Medvedev) about nothing in particular. This is because Putin, who is now prime minister or emperor for life or something, is now an unjustifiable luxury, due to the recession. As is any politician with the correct number of vowels in his name. They'll talk to creepy Bond-villain-esqe Putin again when the GDP starts rising.

From Wales! "Cab dispute threatens golf event". I don't know what it means, but it actually sounds quite exciting, for Wales. Carry on.

A space shuttle landed. Miraculously, it did not fall apart while doing to, despite the recession. Also, it contained the person who invented Hungarian notation.

Madonna is adopting another baby from a random third-world country, presumably because social services in proper countries won't let her have one. This baby's price-tag will be lower than the last one, due to the recession.

Apparently, "Science has been changed to have greater appeal for teenagers". This is because cheap cider and pornography is cheaper than the large hadron collider.

David Cameron droned some nonsense about 'family values' at the Welsh Conservatives conference. Welsh Conservatives! I assume they object to all these new varieties of sheep, and erosion of hills. (Actually, it's pretty funny; he seems to object to police having to follow rules rather than just being able to do whatever they feel like.) Fortunately, there will be no new sheep this year, due to the recession.

Highly important news about the British Home Secretary's pornography

You know it's highly important because it's the BBC's top story. You see, any real news that might be available right now is economy-related, and thus far too depressing to be even thought about, much less reported upon, and while people are still no doubt being blown up, raped, tortured and so forth in Iraq, the public is bored with that now (Iraq news can now be generated with the Word form letter thingy; "[random-number] of [civilians/insurgents/British soldiers/American troops] were [killed/shot/bombed/murdered/tortured/raped] today near [Baghdad/Basra] by [insurgents/British soldiers/American troops]" - Americans are always 'troops' now, for some reason, like the people in the white costumes in Star Wars), so it is necessary to resort to reporting that Jacqui Smith accidentally claimed 10 pounds worth of porn as expenses, because this is a matter of national importance. She also, incidentally, claimed 3.75 for Oceans 13, which is far worse, as that's a dreadful film and the porn is not named, so could theoretically be good, assuming that there exists such a thing as good porn.

From some dreadful old Tory or other:

"If she doesn't recognise that I think she's really a bit too stupid to be Home Secretary."
The sentiment is appreciated, but really, the bar has been set terribly low.

This is the face of a cabinet member who has just discovered that someone in her house is watching filthy, filthy pornography, and/or Oceans 13, and that she has accidentally submitted it as an expense.


One wonders was the pornography in question made by Ireland's beloved nude taoiseach. I'm sure that somewhere there is a market for people who fetishise wobbly incompetents in positions of power.

Update: It gets worse! Her husband, who is apologising and is thus potentially the porn-viewer, is also her parliamentary aide! This means that the porn may theoretically have been watched in government offices. No doubt a Sir Humphrey is even now frantically checking for stains on the nice leather chairs.

Friday, March 27, 2009

Synchronised Stockbroking

Today's markets:


They always move together to an extent, of course, but you get the idea that this took some doing, particularly the Dow Jones/S&P combined line at the end of the day.

"Oh, Allied Screwdrivers has announced a merger; quick, sell pear futures and leak the news about the government's plan to nationalise pornography."

Incidentally, did the USSR have a state monopoly on pornography, and if so, did Generic Russian Propaganda Hard-Working Man-Woman, type B (pictured below) moonlight in it? I do hope so!


She's making, erm, tiny silos? Rockets with very narrow exhaust jets? Enormous dildos? And look! Bonus mystery kinky Soviet thing found while looking for that one:



The text, it seems, means "Our army is an army that liberates workers." - J Stalin. 'Liberates', indeed.

What's YOUR carbon number?

The Government has provided us with this lovely website to figure out what our 'carbon number' is. A carbon number, of course, is the number of tonnes of, erm, something, could be carbon or carbon dioxide, who knows, that you produce a year.



Mine, it turns out, is 1.28. This appears to be rather low; perhaps I should start a coal fired forge or something on the balcony to compensate. It's lowness is, I suspect, due to me not having been on a plane in years, living in an apartment and walking everywhere.

A few of the questions are interesting. I was, for example, given the option of saying that I didn't have any home heating of any sort, that I didn't have electricity (and was thus presumably filling out the survey on my steam computer), or that I had a wind turbine at home. Disappointingly, while allowing that I might have a 60 meter high steel bladed thing in my apartment, they didn't ask if I had, say, a home coal generation system.

Also, proof that Grammar Criminals infest our society at all levels, even our beloved, wonderful Government who makes these web pages for us (Ireland is basically governed by website, these days):

Monday, March 23, 2009

MacOS Fun with CommonQt - Qt for Common Lisp

A few weeks ago, the Qt multiplatform GUI library, used in, amongst other things, Opera and KDE, changed its licensing scheme. Previously, Qt was available either as a GPL library, or a commercial one which you paid for. If you used the GPL version, you had to make your application GPL too, so it was of limited use to commercial developers. The commercial version, by contrast, was rather expensive.

Anyway, Nokia, the current owner, recently added a third option, LGPL. It is allowable to use LGPL libraries in commercial apps, without being required to redistribute your source with the application. This suddenly makes Qt a very attractive option for commercial application development, especially as it works quite nicely on the three major platforms, Windows, MacOS and Linux. Competitors include GTK++, which works on Linux and other UNIXy things well, but unimpressively on Windows and barely at all on MacOS, and wxWidgets, which works everywhere, but rather weirdly.

Hot on the heels of the announcement, out came CommonQt, a Qt binding for Common Lisp. It uses a thing called Smoke, part of kdebindings, which provides dynamic access to Qt objects, allowing a narrow C interaction layer between the Lisp and Qt.  It's not perfect yet, but really quite impressive considering its age. Interestingly, it is probably the first way to write a native-looking application for all three major platforms with a free Lisp and one library.

Just as the current standard demo application for any given web framework is a crap blog thing, so the standard GUI demo application on MacOS is a currency converter thing, as laid down in Apple's own tutorials. So, I'll make one. Here is Apple's version:


Here is my code:


(defpackage :qt-conv
  (:use :cl :qt)
  (:export :main))

(in-package :qt-conv)
(named-readtables:in-readtable :qt)

(defvar *qapp*)

(defclass my-window()
  ((dollarAmount :accessor dollarAmount)
   (conversionRate :accessor conversionRate)
   (result :accessor result))
  (:metaclass qt-class)
  (:qt-superclass "QWidget")
  (:slots ("convert()" convert)))

(defmethod convert ((instance my-window) &aux (res 0))
  ; Just ignore if input isn't numeric...
  (handler-case
      (setf res (* (read-from-string (#_text (dollarAmount instance)))
  (read-from-string (#_text (conversionRate instance)))))
    (t (e) nil))
  (#_setText (result instance) (format nil "~A" res)))

(defmethod initialize-instance :after ((instance my-window) &rest rest)
  (new instance)
  
  (#_setFixedSize instance 360 170)
  (let ((convert (#_new QPushButton "Convert" instance)))
    (setf (conversionRate instance) (#_new QLineEdit "1.00" instance)
 (dollarAmount instance) (#_new QLineEdit "0.00" instance)
 (result instance) (#_new QLineEdit "0.00" instance))
    (#_move (#_new QLabel "Exchange Rate per $1:" instance) 20 20)
    (#_move (#_new QLabel "Dollars to Covert:" instance) 20 60)
    (#_move (#_new QLabel "Amount in other Currency:" instance) 20 100)
    (#_move (dollarAmount instance) 200 60)
    (#_move (conversionRate instance) 200 20)
    (#_move (result instance) 200 100)
    (#_move convert 220 130)
    (#_connect "QObject"
      convert (QSIGNAL "clicked()")
      instance (QSLOT "convert()"))))

(defun main (&optional style)
  (when style
    (#_setStyle "QApplication" 
(#_create "QStyleFactory" (case style
   (:cde "CDE")
   (:macintosh "Macintosh")
   (:windows "Windows")
   (:motif "Motif")
   (t "CDE")))))
  (setf *qapp* (make-qapplication))
  (let ((window (make-instance 'my-window)))
    (#_show window)
    (unwind-protect
(#_exec *qapp*)
      (#_hide window))))



Here is that code running:



Here's the XCode example again for comparison:



And here is the same app running with style set to the rather hideous Motif-alike:



It's really quite simple to use, and the same code should work on Linux and Windows, too. I know that other people are using it on Linux, and I assume that getting it working on Windows shouldn't be too difficult.

Actually getting it going on MacOS is a bit of a pain.

First, you'll need QT. You can download the binary version from here.

If you want to skip the rest of the nasty C stuff, you can get a version I've prebuilt (both smoke and the commonqt C lib) here.

Next, you will need kdebindings. You can get it by doing: svn co svn://anonsvn.kde.org/home/kde/trunk/KDE/kdebindings

You'll also meed CMake. Take CMakeLists.txt.php-qt and copy it to CMakeLists.txt. Edit it, switching off everything but smoke. Now edit smoke's CMakeLists.txt; remove the KDE bits. Run the main cmake. Next, go to smoke/qt. Edit, then execute qtguess.pl. It is likely that it will have misguessed library locations as things like -l /Library/Frameworks/QtGui.framework; change this to -framework QtGui, and treat other Qt frameworks similarly. Now run generate.pl, then make. At this point, you should have libsmokeqt.dylib. That's that.

Now, you will need to get CommonQt itself. Do:
git clone git://repo.or.cz/commonqt.git
git checkout smoke2 

Enter the commonqt directory, and copy in libsmokeqt.dylib. Edit the makefile, adding -framework [whatever] as necessary, and change the last line to "c++ -dynamiclib -flat_namespace -fPIC -shared -o $@ $^ -lsmokeqt $(LDFLAGS)" - MacOS has different shared library compilation parameters.

At this point you should have the relevant C libraries. Install the remaining (Lisp) dependencies, listed on the project page, and load the library. You should now be able to run the tutorial apps, or the app I've given above. Have fun!

I'd be very interested to see this on Windows, if anyone gets it going.

Has the recession finally hit Google?

Well, to an extent we know it has; they've been cutting down on chefs and have finally started exploiting Google News, it of the alleged 100 million a year revenue potential.

But now, they seem to be slowing spidering. A few days ago, I became aware of the existence of CommonQT (a Common Lisp binding for QT, a multiplatform GUI lib which recently switched from GPL to LGPL, making it practically usable for commercial apps; more on this later, CommonQT is really quite nice); Googling for it, however, turned up nothing, and I had to actually ask for the URL. Asking for URLs is very much something we did in the bad days before Google's supremacy. As it turned out, it lived on common-lisp.net; changes there normally turn up in the Google index in hours; this time it took about four days.

Google can presumably save some money doing this, as they'd save on bandwidth, and possibly idle spidering clusters and save on power too. They can presumably even get away with it; Yahoo and Microsoft search results remain dire as always. It's not a good sign, though. Google Groups has been giving dubious results for the last year, and is beginning to become useless, but fortunately, of course, barely anyone uses it anyway.

Sunday, March 22, 2009

Truth in Comics

Dilbert.com

From personal experience, I can confirm that this is 100% true. Furthermore, niceness and ease of production of coffee is an issue; the optimal compromise I have experienced was the automatic expresso maker in Activision.

Wednesday, March 18, 2009

A coup for Dell


Look! It's a new laptop from Dell! It's like a Macbook Air, except slower, heavier, much more expensive, and with Vista!

I'm sure you're rushing out to buy one right now.

Oh, little oddity; Dell is spared displaying prominently not only the stupid Intel Inside thing (a privilege it shares with Apple),  but also the even stupider multi-coloured Windows thingy! They're actually there, but in monochrome, on the base. Classy!

Sun's got the Blues

Strong rumours today that IBM, noted maker of large expensive computers, is going to buy Sun, noted maker of, er, something or other. For 6 billion dollars or so. Was enough to put Sun's share price up about 80%, anyway.

It'll be a shame to see Sun go. For one thing, it'll probably be the death of yet another architecture, the UltraSPARC; we shall be left with only the x86, POWER, ARM and (hah) Itanium. And MIPS, desperately clinging onto a sort of half-life.

But why is IBM doing this absurd thing? Why, it makes Sun's ridiculous MySQL aquisition look positively sensible. It'll get an architecture which it'll be forced to kill, for No Company May Possess More Than One RISC Architecture, a nice line of really big expensive computers much used as web servers ten years ago, and a stupid cloud thing.

But it'll also get something far more precious. IBM, IBM of Eclipse and SWT and, er, other Java-y stuff, will get Sun's stock ticker symbol. Which is 'JAVA'.

A new acronym for a new age

From BBC: "Fed pumps $1.2tn into US Economy"

Yes, that's 'tn'! Imagine! Welcome to a brave new world of bloody enormous debt.

Sunday, March 15, 2009

Beware the Ides of March!

Well, possibly. Bad day for public speaking, anyway.

Saturday, March 14, 2009

Horrors of Television

There is a man on the telly at the moment babbling on about how people can't afford to get married, a charmingly old-fashioned idea.

An aside. Obviously, anyone can afford to get married. They just may not be able to spend 30k on a big huge party. Of course, that will not stop them; living within your means is also a charmingly old-fashioned idea, as we can see from people who bought brand new five-bed houses in Cavan or Meath or some other outer-darkness place on a 100% mortgage at the height of the boom. Anyway, enough about our hideous economic crisis, which is really all our own faults for allowing people to have 100% mortgages. Back to the silly man on TV.

There is a huge glittering lizard on his lapel.

I'm not sure whether it would be worse if it were a piece of jewellery or just a hideous, blood-sucking parasite.

Friday, March 6, 2009

Catholic Church - Evil beyond belief

There was a time (when I was maybe 10; I was a sceptical little bastard) when I thought that, although the Catholic Church's beliefs, and a lot of their morals, were wrong, the actual people involved were generally good.

Then, when I learned about the horrors of their past, I thought that they had been bad in the past, but now okay.

Then, when I heard about their views on gay people and women and so forth, I thought that they were probably, well, mentally unbalanced, but not entirely responsible for their views.

Then, when I heard about their discouraging of contraceptives and actively lying about the efficacy of condoms in preventing HIV in the developing world, I thought they were pretty damn evil.

Yesterday, in my view, they crossed into pure bloody dementedly worse-than-Bond-villain evil.

You see, there is a girl in Brazil, who was raped by a relative, and was pregnant with twins. She is nine. She had an abortion.

An archbishop said that everyone involved in obtaining and performing this abortion is to be excommunicated.

I mean, how can anyone feel okay about this? Lovely Mr Ratzinger, who, as I said before is probably not actually a Nazi pope, due to Hitler Youth membership being pretty much mandatory when he was involved in it, but certainly a Fascist pope, due to his views, has had enough time at this point to censure and fire that archbishop, but has not. At this point, the church is basically signalling its approval of this loony view, and anyone who attends a Catholic church, or gives money to one, should feel ashamed of themselves.

Oh, and by the way, the archbishop in question likes to call abortion a Holocaust. That's right; drawing moral equivalency between killing two embryos which probably couldn't survive to term without killing the mother, and the killing of 10 million or so people. Yay! And I don't think they've gotten rid of that holocaust-denying bishop yet, though they did at least ask him to apologise.

It has finally annoyed me to the point where I think I'll go through the irritating process of formally being taken off their books; I believe this hurts them from a statistics point of view.

On being sick

I have now had a horrible cold/flu thing for getting on for two weeks. It is really, really awful. Why can't medical science focus less on cancer and more on non-lethal-but-annoying things?

Also, I have to force myself to remember to eat. Not hungry at all, ever, and certainly eating far less than normal. Weird.