Thursday 10 June 2010

Google background image

This morning I was surprised to find a fading background of flowers on my google home page.  Its quite nice black and white picture, and I thought hmm that's nice; how to I get rid of it?

I clicked the change background image to reveal lots of images that I can use as the background for my homepage.  Unfortunately, there is no option to remove the background image all together. The help section directs you to "Remove background image" in the bottom left, but there is no remove background image in the bottom left.  Very Frustrating.

After a quick search on the interwebs, it became apparent I am not the only one who wants to remove their background, a quick search in google reveals over a million webpages for "google homepage remove background image".  It appears to be bad coding by google to not provide the option to remove the picture.  Surely they did not expect everyone to roll over and like their changes.  They google labs everything for acceptance testing, but this one clearly got okayed by the yes men.

I could not have been the only person in the world who does not like change forced on me.  Firefox did the same thing with their persona a while back, but they were kind enough to ask whether we wanted the change rather than forcing it on us; with no option to remove.  What's worse, if you have no google account, you cannot even change or remove the background; you are stuck with what google gives you. "Do no evil" eh?

For now the only choice is to use the "From my computer" option and pick a white image (800x600 pixels minimum) to get a white background at least. I will update this post with info on how to successfully remove the background when more information becomes available, until then, suffer maggots!

UPDATE: Google has fixed the issue, by default, no images are displayed until you choose the change background image option from the bottom left.  And removing it, correctly resets you to the default google homepage.

Thursday 13 May 2010

String to an Input Stream

Recently I came across an issue in java where xml data retrieved from a database. The returned string needs to be converted into an input stream to be useful in the program.

The following is a solution I used; you may find it useful. I have used UTF-8 encoding as it was required for my case, altername as required.

InputStream is = new ByteArrayInputStream (myXMLString.getBytes ("UTF-8"));

Wednesday 28 April 2010

Visual Studio 2010

A few days ago I received an email from Microsoft advertising the release of the new version of Visual Studio.  Now I work as a .NET developer, so Visual Studio is the most used application for me - next to firefox :o - so I took notice.

I had been pretty busy with new projects, so not had time to look at Visual Studio 2010 release candidates, so this was going to be my first attempt with Visual Studio.  Fortunately, I have an active MSDN subscription with a Visual Studio license, so I can get a copy for free.  Awesome I though, and fired up firefox to get myself a copy.

A length download later - 2+ Gb - and lots of grumbles from my co-workers as I took up the office bandwidth with my download, I had my copy of Visual Studio ready to go.

Now after a week or so of usage, I am not exactly impressed with the application, but it does have a few nice features.  Enough to dislodge Visual Studio 2008 from the most used application slot (not enough to out Firefox obviously).

Visual Studio 2010 brings in allot of new features, in addition to those publicised by Microsoft, I found the following interesting.

Usage Highlighting
When you put the caret on variable/function etc, all other occurrences of that particular item are highlighted also.  This is the feature I most loved about Netbeans and is a massive help when debugging code to track the usage of an item.

Multi-screen Support
Finally.  This has been a thorn to my side for a while now, when developing complex objects, I tend to have a few windows split horizontally, but I cant see all the code on both the panes easily.  Now I can simply drag out a window to my second screen and presto, all good!

Live Semantic Errors in C#
In the previous versions of visual studio, I loved working in Visual Basic because I could spot right away where I had mistyped something.  C# was not so kind, it would reveal the problems when compiling.  This happened more often than not with my light fingers and bad spelling skills.  Not any more, C# now provides the nagging red wavy underlines.

Auto-Code generation
Ability to generate method stubs of code based on their usage.  This allows me to flow with my codding and puts reminders for me to fill in the gaps later without the red wavy lines interfering with me spotting actual errors.

Threaded Add Reference box
In Visual Studio 2008 and prior, when adding reference for the first time in the instance of visual studio it would freeze while loading up the list of all the references available, only for me to click project and browse to the one I wanted.  Now that its on a separate thread, its much less of a nuisance.

Windows Presentation Foundation look and feel
This is a bit of a mix bag.  Though not fundamentally changed (like office 2003 -> office 2007), the looks have been dressed up a bit.  I think it does look nice without adding too much overhead in loading, others might disagree.

.Net 4
The next iteration of the .NET frame work.  There are some nice features in the new framework that I cant wait to get to grips with.

And I am sure other users have their own thoughts on what they like.