jQuery to Highlight the Current Menu Item

4 Sep

Here is a little bit of jQuery code to highlight the current menu item. This presumes you are using a UL > LI > A structure to build your menu.

<script type="text/javascript">
  $(document).ready(function() {
    var path = location.pathname;
  $("li:has(a[href$='" + path + "'])").addClass("selected");  });
</script>

Are all WPF Programs Usability Bad?

3 Sep

I have yet to run to into a usable program written in WPF. I tried another one out this morning and it barely ran. Is there a WPF based application that isn’t a mess?

The most notable WPF program that I have tried is the twitter client blu by thirteen23.com. It seems like the only WPF programs I have come across are twitter clients.

Most of the WPF programs I have tried seem to have the following issues in common that make them unusable for me personally.

  1. There don’t seem to be any keyboard shortcuts which drives me nuts.
  2. The font sizes are to small and the fonts look awful, they are blurry and hard to read.
  3. The interface design is way over the top, yet poorly implement. Interface elements will overlap and don’t layout correctly.

The first and third items in my list seem like they should be blamed on the developers but I have never seen a program developed for another platform with these issues. Number 2 should be blamed on WPF as I believe there is a framework fix for this coming in the next version of .Net.

These problems make me inclined to avoid trying to use anything written in WPF and to certainly avoid trying to develop anything with it.

Scheduled Posts Fix

27 Aug

If this posts correctly then here is what I did to fix WordPress scheduled posts being broken in 2.8.x.

I added the following line to the wp-config.php file.

define('ALTERNATE_WP_CRON', true);

The Demolished Man

24 Aug

I finished up reading “The Demolished Man” by Alfred Bester last weekend. I enjoyed it but I don’t think it is in the same league as “The Stars My Destination” which I absolutely love. The prose in Demolished Man really feels like its coming out of the 1950’s.  The story concept though is pretty thought provoking.

The premise that the highly driven individual should not have to conform to societies rules, that he is exempt by virtue of his drive to succeed is a very relevant topic today. I see the main character in the financial flim-flam men of today, those who manipulated markets and companies solely for their own gain at the expense of the home buyer, the investor, the company employee, and the share holder.  These are men who believe that they are exempt from societies rules and the morals of regular men.

Bester warns us of these men and the damage that they can do to the world as a whole. I see “The Demolished Man” as a cautionary tale more than a work of great fiction. I believe “The Demolished Man” is a unique piece of American literature and would encourage you to read it.

Test Post

21 Aug

This is a test post to try and figure out what is going on with my blog.
 

Example C# IDataContext interface

    public interface IDataContext {
        System.Data.Linq.DataContext Context { get; }
        void SubmitChanges();
    }