Code Highlighting, Blogs, and SyntaxHighlighter

Scott Hanselman blogged about a great blog-engine-agnostic hilighter for code. Out of the box, Alex Gorbatchev’s tool called SyntaxHighlighter supports many languages, including C#, C++, Ruby, CSS, and JavaScript. This will be invaluable for posting code samples here.

Anthony Bouch brings things full circle by writing a plugin called PreCode for Windows Live Writer to allow you to paste code in a format that SyntaxHighlighter can handle.

Posted on 12/14/2008 1:53:02 PM by Jason Nadal

Permalink | Comments |

Categories:

Tags:

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

C# 3.5 List Compiler Quirk

I had attended a great ASP.NET FireStarter session yesterday down at Infragistics HQ in West Windsor, NJ. Peter Laudati did a great job at presenting the material without making it seem like a marketing pitch. This was very refreshing, compared to other MS events.

One thing I took away from the meeting was an emphasis on the new Object Initializer. While this is not more than ‘syntactic sugar’, it does provide an easier way to set multiple properties simultaneously. (This will become more useful in the C# 4.0 timeframe with movement towards anonymous types – an extension of the theme of anonymous delegates, also known as lambda expressions)

While the MVC discussions were cursory in code, but deep in discussion and deserve longer blog posts than this, I saw an interesting quirk of the compiler. The following syntax is surprisingly valid (note the hanging comma on the last list element).

public class BlogController : Controller
{
    public ActionResult PostList()
    {
        List<Post> posts = new List<Post>{
                            Post.GetPost(0),
                            Post.GetPost(1),
                            Post.GetPost(2),
                            Post.GetPost(3),
                            Post.GetPost(4),
                           };


        // Add action logic here
        return View();
    }
}

Posted on 12/14/2008 1:36:59 PM by Jason Nadal

Permalink | Comments |

Categories:

Tags:

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Test Post from Windows Live Writer

This looks like a pretty intuitive editor, but it’s still in beta. The good thing about it is that it will make posting code snippets much better. Scott Hanselman writes about it here.

Posted on 12/14/2008 1:20:25 PM by Jason Nadal

Permalink | Comments |

Categories:

Tags:

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Microsoft Cardspace Codename "Geneva"

It seems the cardspace team has been at work simplifying the user experience for Cardspace prompts. See codename "Geneva". This looks pretty good; they've even included the new Geneva server for creating managed cards, which is something I'd like to explore at some point. I'm very curious what work if any has been done to integrate OpenID in conjunction with cardspace.

I'm not sure just how far Cardspace is penetrating, as I've yet to run across a site (aside from Windows Live, and even that's in beta, and has been since at least August of 2007!), which actually uses cardspace for authentication. I have found many articles from the 2006/2007 timeframe purporting firefox 3.0 support of cardspace, however the plugins online don't show them. Windows live login requires IE to even attempt a cardspace login.

Posted on 12/5/2008 8:07:00 PM by Jason Nadal

Permalink | Comments |

Categories: development | network | vista | windows | cardspace | security

Tags:

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Google Friend Connect Test

Testing out the Google Friend Connect in a post, while considering adding it to the site in general. You can see some additions to the site on the left; I've added the Google login, in anticipation of adding some other gadgets; it was a pretty simple add-in as a widget to the BlogEngine.NET backend of this site; just have google generate the markup, dump it in a user control, and you're good to go.

Posted on 12/5/2008 5:27:00 PM by Jason Nadal

Permalink | Comments |

Categories:

Tags:

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5