jaybaz [MS] WebLog

We believe in nothing.

March, 2004

  • jaybaz [MS] WebLog

    Formatting code in blogs

    • 12 Comments
    In a comment , Steve asks how I format code in my blog. Here's the answer: Write the code in Visual Studio. Include correct references, 'using' directives, helper classes, fields, etc. Make sure the code builds. (I really should use NUnit to make...
  • jaybaz [MS] WebLog

    Another clear code challenge

    • 0 Comments
    Zhanyong posted his own programming challenge , including this comment: “The merit of an entry will be judged mainly by how clear the code is , not necessarily the efficiency” Right on! This one is a little bit more challenging that...
  • jaybaz [MS] WebLog

    Clearest Code Challenge: Jesse Ezel's answer inspires!

    • 5 Comments
    Jesse posted a comment with a unique approach: Make a class that's good at laying out buttons on the bottom-right of a form. I could definitely imagine adding a Help button, for example, which would make this generality helpful. As for clarity, the...
  • jaybaz [MS] WebLog

    Tech Preview now available!

    • 1 Comments
    Wahoo! As I had previously discussed , the first Technology Preview for Whidbey became available this week. We will have a lot to learn about the whole process here - collecting & responding to feedback, delivering releases, etc. So, it makes sense...
  • jaybaz [MS] WebLog

    Clearest Code Challenge: My answer

    • 12 Comments
    Here’s my solution. const int spacing = 12; _buttonCancel.Location = new Point ( this .ClientSize - _buttonCancel.Size - new Size (spacing, spacing)); _buttonOK.Location = _buttonCancel.Location - new Size (spacing + _buttonCancel...
  • jaybaz [MS] WebLog

    Clearest Code Challenge: Honorable Mention

    • 1 Comments
    Honorable mention to Thomas Eyde. His submission uses a new class, so he gets points for trying to be OO. I don't think this approach was fruitfull, though; the result is pretty complex to my eyes. He’s also the only one who submitted legal code...
  • jaybaz [MS] WebLog

    // blue cheese & brie

    • 5 Comments
    A comment on the Clearest Code Challenge inspires this post. In particular the bit about how someone can figure out the code if it's commented, “no matter how crap the code is”. Perhaps. Comments are smelly. Really. From Ward's Wiki...
  • jaybaz [MS] WebLog

    Clearest code challenge

    • 18 Comments
    This is a real problem I had recently. Suppose you have a form with OK and Cancel buttons. You want the buttons to be placed in the bottom-right corner of the form. Normally you'd place them where they go, then set their Anchor properties to Bottom...
  • jaybaz [MS] WebLog

    Edit & Continue vs. Test-Driven Development

    • 4 Comments
    When you do TDD , your code takes on a very different structure than without TDD. Each line of code is motivated & tested by a test. Code is decoupled, just like my Computer Science profs used to talk about. You may not write the correct piece of...
  • jaybaz [MS] WebLog

    Safely firing an event

    • 14 Comments
    This came up on an internal alias, and I thought I should spread it around. If you’re going to fire an event, you may have code like this: void F() { if (SomeEvent != null ) { SomeEvent(); } } There’s a...
  • jaybaz [MS] WebLog

    Retrofitting unit tests on legacy code

    • 0 Comments
    What I say here isn't original, but maybe you'll find it useful. I wrote it for today's C# Unit Testing chat. Q: I'm quite new to TDD - are there any best practices for retrofitting existing code with unit test. A huge task. A: A common question, and...
  • jaybaz [MS] WebLog

    Unit Testing chat TODAY!

    • 2 Comments
    Microsoft is hosting a chat on C# & Unit Testing today. Jim Newkirk will be there. I will, too. Edit: log from the chat available at http://www.msdn.microsoft.com/chats/recent.asp
  • jaybaz [MS] WebLog

    Edit and Continue vs. Elvis

    • 26 Comments
    Continuing on a theme, today we talk about Elivs and E&C. We don't have a good way of measuring how Elvis uses E&C, since C# has never had the feature in a released product. So, what I say here is even more likely to be wrong than normal. Elvis...
  • jaybaz [MS] WebLog

    Suggest a topic

    • 5 Comments
    What would you like me to blog about? More of what you've seen? Something completely different? Comment here...
  • jaybaz [MS] WebLog

    Whidbey Implement Interface

    • 1 Comments
    Anson talks about what some work we've done on Implement Interface. When I code today, I always use “Explicit Implementation” for interfaces. My thinking is that the interface represents a contract with an “external”. If I happen...
  • jaybaz [MS] WebLog

    Sloop-a-palooza!

    • 4 Comments
    This past weekend I took the Sloop-a-palooza class at the Center for Wooden Boats . It was a beautiful day. Warm (60 deg F) and sunny. We sat on the docks and talked about sail shape & hull hydrodynamics. The big lesson for me was about overtrimming...
  • jaybaz [MS] WebLog

    Putting the tee BACK in tee dee dee

    • 6 Comments
    Christian posts about the word “tests” in test driven development. He's absolutely right: we get hung up on the word all the time. Around here, every time we start talking about TDD, the testers get all nervous. “Does that mean you...
  • jaybaz [MS] WebLog

    Edit and Continue vs. Einstein

    • 6 Comments
    Continuing the discussion with Einstein , the prototypcial C++ developer. Einstein often creates software solutions to some pretty complex problems. He spends a lot of time trying thinking about different approaches to the problem, and tries to pick...
  • jaybaz [MS] WebLog

    Edit and Continue vs. Mort

    • 9 Comments
    All this talk about E&C, I thought it'd be a good idea to talk about the personas. Ian has a good description of the personas we use when talking about Visual Studio users. There's a language correlation, too. VB primarily targets Mort, C# targets...
  • jaybaz [MS] WebLog

    C# Edit & Continue vs. Refactoring

    • 22 Comments
    Sean asks for it, and Andy blogs some of the thinking behind no E&C for C# . I really like using E&C when writing C++, and I know that VB users find it pretty valuable. Seems strange that we wouldn't have it for C#, yeah? When we talk about...
  • jaybaz [MS] WebLog

    Software Performance & Hardware configurations

    • 7 Comments
    The minimum hardware requirements for Visual Studio 2002 and 2003 are a machine with a 600MHz CPU and 128M RAM. A few months ago I picked up a new HTPC for cheap. Dell 2.4GHz, 128M RAM for $324. I see the deal reappear about once / month. I just added...
  • jaybaz [MS] WebLog

    Performance Scenarios

    • 4 Comments
    Perf for an editor is extremely important. Because editing is completely interactive, you really don't want a noticible delay in most cases. One of the first things to decide is what kinds of things you want to measure. Here's the list we're working...
  • jaybaz [MS] WebLog

    SailNOW Graduate!

    • 6 Comments
    This entry is a departure from my other entries, in that it has 0 to do with computers. Please comment on whether you liked it or not. I've just completed the SailNOW! program at the Center for Wooden Boats . I've been wanting to sail for about 8 years...
Page 1 of 1 (23 items)