55.2 F
Los Angeles
Friday, April 26, 2024

Trump Lawyer Resigns One Day Before Trial To Begin

Joseph Tacopina has filed with the courts that he will not represent Donald J. Trump. The E. Jean Carroll civil case is schedule to begin Tuesday January 16,...

Judge Lewis A. Kaplan Issues Order RE Postponement

On May 9, 2023, a jury found Donald J. Trump liable for sexual assault and defamation. The jury awarded Ms. Carroll $5 million in damages. Seven months ago,...

ASUS Announces 2023 Vivobook Classic Series

On April 7, 2023, ASUS introduced five new models in the 2023 Vivobook Classic series of laptops. The top laptops in the series use the 13th Gen Intel® Core™...
HardwareTablet PCEnhanced comments for developers

Enhanced comments for developers

I’ve heard it said many times: “I’m a developer. I type code. Why do I need a Tablet PC or even ink?”

Sure, few developer tools support ink directly, but what if they did?

How might you debug an application if you could sketch out and archive the intermediate state of a program within your source code? No more ASCII diagrams to fiddle with. And what if you could capture a screenshot, mark it up with ink and embed it in your source code to archive a particular state of the program? Or maybe take a screenshot of a properties dialog and archive it as well?

These are a few of the possible uses of enhanced ink comments that I’ve been exploring.

Here’s a screenshot that shows enhanced ink comments in Visual Studio 2003.

VS2003EnhancedComments.gif

It’s fairly straightforward. A tool window hosts the ink. Actually the toolwindow can hold more than just ink. You can insert screenshots, type freeform text, highlight items, draw simple diagrams, and more. Minimmaly, macros within the IDE synchronize comment markers within your code with the actual enhanced ink comments. (I call these “xnk” comments. Pronounced like “zinc.”)

When you create a new xnk comment, a marker similar to:

// <xnk id=”1″/>

is placed in the source code. In this example, the enhanced comment has an ID of “1” and is placed in a separate file (think resource file). One comment file exists per source code file that contains ink. In this way, the ink doesn’t get in the way of the source code. I have experimented with embedding base64 encoded versions of the ink and pictures and so forth in the source code, but the downside here is that the source files can get huge. In order to make this approach practical, source code editors and the like need to be able to better hide and ignore these data blocks when desired.

OK. You’re probably wondering how useful this stuff is outside of Visual Studio? What if you want to use another IDE? Well, the basic idea is fairly portable within Windows. (In fact, you don’t really need a Tablet PC. It’ll work on a regular Windows XP system too.)

Here’s a similar version of the tool window implemented in the Eclipse IDE–a development environment written for Java in Java that another developer is working on. Yes, Java. (Dont’ forget that Java backer IBM has a Tablet PC now. 🙂 )

EclipseInkScreenshot.gif

An implementation using a standalone Xnk viewer also makes a similar tool possible for other development environments. I posted a demo of this a few weeks back–albeit it was shown using Visual Studio. Think Emacs or SlickEdit. Haven’t done it, but they should work too.

Now there are other ways of using ink in a development environment. One approach is to use ink as an overlay within the source code block like this:

VSInkOverlay.gif

Yes, this ink was actually drawn from within the Visual Studio editor. Turns out a feature like this involves some tricky problems (read bugs) that I have yet to overcome, but wouldn’t this be great to be able to explain source code in a classroom or conference session by marking it up at will?

There are a couple other ink-and-code efforts that I’ve seen on the Inkernet too. I’ll pull together a listing of them.

Yeah, I know I need a video or better yet a download, but first things first. I’d also like to write a more formal article that lists out some of the various ways I’ve been experimenting with ink in a development environment.

Loren
Lorenhttp://www.lorenheiny.com
Loren Heiny (1961 - 2010) was a software developer and author of several computer language textbooks. He graduated from Arizona State University in computer science. His first love was robotics.

Latest news

Related news

  1. Does it work in Visual Studio 2005?

    This is pretty cool. I’ve been using VS2005 on my Tablet now, and I’m still waiting for an ink-enabled IDE that lets me use gestures/shortcuts/symbols for language keywords. That would make my life so much easier.

  2. I’ve been working on a Visual Studio 2005 version too, however, VS2005 is still in beta and there are some bugs that are getting in the way. I imagine in the coming months these will be worked out and I’ll have a 2005 version running.

    In terms of keyword programming via gestures, I haven’t gotten that far yet. I agree that accessing features faster when using the stylus can make all the difference. Good ideas are sure to be lurking here.

  3. Rob, thanks.

    Next up I want to get this working with ASP and HTML pages. It would be an interesting way to capture and archive the states of the UI along with the source.

  4. Casey, code reviews could be a lot more interesting with ink.

    Michael, Yeah, programming languages designed around “tap, select, drag and drop” are much better suited to the stylus than text-oriented languages. Looks like Gamemaker would be a great candidate for some additional Tablet enabling.