$theTitle=wp_title(" - ", false); if($theTitle != "") { ?>
dabbling, frivolling, idling, loafing, loitering, playing and procrastinating
20 Aug // php the_time('Y') ?>
I recently changed the background image for the Today screen on my XDA Orbit, however when you set an image to background it washes it out with a grey layer so that text is still readable. However, if you used a very light image to begin with, the standard white text of the Today screen becomes almost unreadable.
In true Microsoft style, there’s no way to change this easily through the Settings pane, or through the Theme settings pane either. So how do you do it?
HKEY_LOCAL_MACHINE\Software\Microsoft\Color\If you see a binary key named 4 simply edit that and if you want the colour black, put in 00 00 00 00 then save it.
If you don’t see a binary key named 4 then you’ll need to create it. Do this by right clicking and going to New -> Binary Value…
Value Name:
4
Value Data:00 00 00 00
If you had to create the key then the colour change should be immediate, if you were editing it you probably need to restart the phone.
19 Aug // php the_time('Y') ?>
After finally giving in I decided to work out how to get Firefox 2.0.0.11 and 3.0.1 running side by side. It turned out to be much easier than I thought, so I thought I’d share this with the world (although its probably posted on about 5million other blogs), either way…
That’s the easy part, now for the more complex bit…
firefox -ProfileManager“ff2“Now navigate to the folder you just installed Firefox 2 into, and create a shortcut to the firefox.exe
firefox.exe -P ff2 -no-remote
Put that wherever you please and then you can load Firefox 2 and 3 at the same time! ![]()
18 Aug // php the_time('Y') ?>
So yes, I recently got myself a new home server off of eBuyer, and I decided to install Ubuntu on it. After installing various other packages without issue the first to cause problems was Rails (it always would be wouldnt it). Either way, when you try to run…
sudo gem update --system
It goes…
/usr/bin/gem:23: uninitialized constant Gem::GemRunner (NameError)
Which is really useful and does exactly what you want it to.. not. The fix is to go edit the gem file…
/usr/bin/gem
In there, hunt for the line…
require 'rubygems'
…and just after, put this…
require 'rubygems/gem_runner'
Problem solved!
15 Aug // php the_time('Y') ?>
This video is shows off what Microsoft’s Research team have been doing since they initially did work on an idea called Photo Tourism. This is where you take lots of photo’s of a location and using those to generate a 3D area which the user can move the camera about in. This is the next step up from that with many improvements, and quite frankly, is a fantastic bit of software engineering.
5 Aug // php the_time('Y') ?>
So, this morning I finally entertained Tortoise’s incessant whining to update to its latest version (1.5.2) and I took the plunge. The one thing that annoys me the most about the upgrade process is the fact I have to restart the machine in order for the installation to finish, this I find is so archaic and out of date compared to 99% of all other software installation. (Obviously I’m not stupid enough to realise that there’s quite a bit of interaction on the OS level with Tortoise, but still, it’s one annoyance I would rather do without)
Once I’m restarted and on the go again, I go to browse one of my SVN directories and I’m greeted with some disgusting icons. They’ve gone and replaced the XPStyle icon set with some… quite frankly, god awful ones. They blur horribly at 16×16 size and just don’t look nice at all in my opinion, so it was then finding out how to change the icons.
%commonprogramfiles%\TortoiseOverlays\icons
5 Aug // php the_time('Y') ?>
If you’re a programmer of some description and you use SVN and develop on Windows then chances are you’ll either be using SVN with TortoiseSVN, or you’ll be like one of those trendy kids using GIT. However, those cool kids don’t yet have something like TortoiseGIT. But I’m sure that once it comes out that these optimizations will still apply.
The part of TortoiseSVN that really slows down PC’s is the “TSVNCache.exe” file. This basically allows for drawing of the icons on-top of files and folders to indicate their SVN status. However, doing this requires a lot of monitoring of literally all your files and folders. So whats the most obvious thing to do? Restrict what Tortoise monitors as it goes about its work. We do that as follows…
Other improvements can be made by setting Tortoise to only show the icon overlays when you are browsing directories with explorer. By default whenever you have an open/save dialog it will load in and show you those. These can be disabled by the following…
1 Aug // php the_time('Y') ?>
For those who know me (hi people on facebook) you might know that over the past few weeks I have been slowly making a gallery in Rails for my personal photos. This started off the back end of being annoyed at Flickr’s free account only allowing you to create 3 sets (or albums) before you had to pay for more. This annoyed me as I do like the Flickr layout, but I’m not really prepared to pay for it just yet.
So instead, I decided to make my own Flickr clone, and this has been aptly named Snapr!
![]()
I started off by looking through their design, seeing how they spaced and laid things out, but one thing in particular that interested me was how pictures seemingly look better on Flickr. Now of course, its not just because of its design that compliments images and that’s enough to make them appear to be better. But as stupid as it sounds, pictures on Flickr do look better, it took some research and testing to finally work out how they do it, but here it is.
After digging through the code in the Mac Flickr Uploader, which is quite handily open source, it was just a case of attempting to follow the code through to work out what they did. They use GraphicsMagick for image manipulation and this is the code that makes images look great…
// Find the sharpen sigma as the website does double sigma; if (base <= 800) { sigma = 1.9; } else if (base <= 1600) { sigma = 2.85; } else { sigma = 3.8; }// Create the actual thumbnail img.scale(dim.str()); img.sharpen(1, sigma); img.compressType(Magick::NoCompression); img.write(*thumb_s);
This is the last part of the generation of thumbnails, and as you can see, it scales down the image, then sharpens it by this magical sigma amount. To replicate this I had to actually play around (for quite a while) with that sigma figure so that I could make a like for like replication of their images. Obviously they don’t compress the thumbs, as if you do, they look horrible.
Now initially, this was easily to replicate in Rails with RMagick, however when I switched over to JRuby there isn’t a RMagick gem, which is more than a slight annoyance. After some help from a friend I had my own implementation of pure Java for image manipulation, and this worked fine. However I had been using the attachment_fu plugin to make uploading and resizing of images a breeze. (Read: if you aren’t using attachment_fu, use it!). So the next step, how to get this new Java code to work with attachment_fu. 2 evenings worth of playing and testing later (and my complete lack of any real Java knowledge) I admitted defeat. So, at this point I have a fully working gallery, minus image uploading and processing, which as far as galleries go, meant it pretty much useless. What was I to do next?
Some Googling later and ImageVoodoo was my knight in shining armor! ImageVoodoo is a JRuby gem which has like for like API methods for ImageScience (an image processor supported by attachment_fu). Everything looked like the gallery could finally begin working again. However the next stumbling block was going to appear, ImageVoodoo doesn’t support image sharpening. I was wondering at this point just how much more annoying this could get; this project was only meant to be something quick to get me back into writing Ruby again, but was quickly turning into a complete headache. After some more eventual playing I again had to admit defeat, not so much through not wanting this to work or lack of knowledge, but the want of a working gallery was greater at this point.
Where am I at now then? Well, the gallery is operational, but image sharpening & image compression are out at the moment. So thumbnails look like a 4 year old has been let loose with Photoshop and somehow managed to find the resize controls but on doing so, decided to lower the quality to about 10. Meaning that my lovely photos don’t look as good as they could at this moment. However with attachment_fu storing the original image all is not lost just yet, as when I finally figure it out I can simply regenerate the thumbnails.. (well, I hope I can, haven’t actually looked into how to do that yet).
It baffles me however that RMagick, which is quite frankly a huge part of Ruby image manipulation, doesn’t have a JRuby gem. Admittedly there is RMagick4J, but it’s lacking the same problems as ImageVoodoo, no sharpening support or image compression controls. If only RMagick worked on JRuby without having to think about it…