Archive for category Development

Wacom Bamboo Tablet Experience


My awesome first tablet design

My awesome first tablet design

(This post was started using my new tablet!)

Well, I suppose that now that I have a tablet, I oughta start practicing. You see, I’ve never been one to have exceptional handwriting skills, so it’s a good thing that I now have a computer that can understand my handwriting better than my 8th-grade Spanish teacher could. I used to get a LOT of zeros on my homework.

(At this point, I’m back to my keyboard because my hand began cramping up. I tried, at least… Typing at 90WPM  on my keyboard is superior to writing using a plastic pen on a mat.)

I’ve long dreamed of owning a graphics tablet, for quick mockups (I included my first here. Creative Commons license, feel free to derive from its awesomeness.) I picked up the Wacom Pen & Touch. Three days in, it has been fun to play with; while it hasn’t been 100% everything that I ever imagined it would be, I think that it may be more of a learning curve issue rather than an issue with the technology itself. I’m used to using a mouse that I have to throw all over a mousepad, not a pen and a tablet that maps 1:1 with my monitor (originally, it mapped to both monitors before I turned off the second monitor in the tablet settings.)

One of the troubles I was having was that it seemed somewhat laggy when I was using my pen on Windows 7 with Photoshop CS3. I noticed mostly that when I was writing, I couldn’t add small details well (look at how crazy all of the lines in my As are); it would sort of stick and think it was supposed to pull up some kind of command menu. I’d like to blame it on myself, as a user error… but it isn’t at all obvious how I fix that issue, if it is one.

Regardless, I’m going to soldier on and try a few more mockups before passing more severe judgement. There are probably some hidden settings somewhere to fix; and once I have those figured out, I’ll post a follow-up on how I did it. Hopefully I do it. Don’t crush my dreams, Wacom.

Tags: , ,

jQuery 1.4.2 updates, and the release of jQuery UI 1.8rc2

jQuery 1.4.2 is out- not officially on their website, but you can be sneaky and get it here:

http://code.jquery.com/jquery-1.4.2.js

http://code.jquery.com/jquery-1.4.2.min.js (not really “minified” as much as “closure compiled”… can we get a verb for that?) The changelog isn’t up yet, but that’s generally the last thing to go (and hey, we snuck in the back door to grab the update anyway, right?) I imagine it’ll eventually find it’s way to their API page for 1.4.2.  I ran a quick diff; here’s some changes that I found notable from jQuery 1.4.1 to 1.4.2:

  • Optimizations for the body selector
  • A few changes to how arrays of elements selected are built, I’ll go with my gut and say that they’re optimizations too
  • Trimming whitespace from JSON data responses, for good ol’ IE
  • A more few various bugfixy-looking things, mostly targeting IE
  • It looks like there was a lot done to the event-adding code; I think mostly internal changes. Probably more optimizations? I’ll leave it to Resig or someone to explain whenever the changelog comes out. A few (generally pretty deep) methods had some parameters changed, or were renamed (things like “jQuery.event.special.submit.remove” becoming “jQuery.event.special.submit.teardown”)
  • A smattering of changes within “live” and “die” mostly centering around the usage of namespaces
  • Blackberry browser bugfix concerning converting NodeLists to arrays
  • jQuery.getText changed to jQuery.text
  • Changes to caching fragments to help out WebKit and IE 6

I haven’t really dug too deeply in the jQuery core before, so I’m not totally qualified to give a whole lot more detail than that. I used SourceGear Diffmerge between 1.4.1 and 1.4.2 to find out what I found out.

Also, in related (and perhaps more official news),  the jQuery UI team released jQuery UI 1.8rc2 – which includes bugfixes in the already pretty stable 1.8rc1 (changelog). You can grab it:

http://jquery-ui.googlecode.com/files/jquery-ui-1.8rc2.zip (development bundle)

http://labs.crimsondeviations.com/jquery-ui-1.8rc2-min.js (I threw it into a closure compiler, it seems the dev package doesn’t include a “minified” version.)

As of right now, I’m testing it in our application at MeM. Let’s see how things go!

Reblog this post [with Zemanta]

Tags: , , , , ,

ASP.NET Controls, How I Hate Them

MSDN Error
Image by ttrentham via Flickr

I’ve always, for some reason, felt innately that PHP allowed me more control over my code than ASP.NET. My brain kept saying “but .NET is more organized! It compiles! It’s faster! It’s easier to write,” but my mind kept saying “PHP lets me do what I want how I want it… screw .NET!”

What I finally figured out was that I love C#, I even like the .NET framework, but I hate is, in fact, ASP.NET.

Every time I see an example of simple, elegant code, the most complex control on the page is a label or a panel. While the intentions behind FormView may be good, writing my own forms and hooking them up saves hundreds of lines (literally- I just refactored almost 800 lines of code into 150 by removing a formview) as well as reduces complexity and maintenance (now I no longer have to maintain view and edit and whatever other modes FormView has.) ASP.NET perhaps made sense in a day before OO principles and ORMs came into play; the controls were written for the same kind of people that use the drag-and-drop design mode. Easy to slap down haphazardly, not so easy to maintain.

We replaced every ASP.NET Ajax control we used anywhere (after I evangelized it, to my chagrin) with jQuery after about 6 months of use; while the controls did what we needed on the surface, underneath there was always some caveat, like the linked DropDowns needed web services, or the datepicker control had missing options… there was always something somewhere that I needed a bit of flexibility on that just wasn’t there, or was buggy. It seemed very odd for it to be out of beta in such a state. So, I ended up starting my own control library using jQuery, and now it’s easily extensible, easy to modify from the client, and I can control the markup.

Oh, and the markup… don’t get me started on the markup. Tables for everything. I can’t rearrange the otherwise useful Wizard control because it’s so static in its display.

So, I guess the point I’m trying to make is, that the longer I use .NET, the less and less I use the complex controls and the more I roll my own. Because it’s easier.
Kind of ironic.

Reblog this post [with Zemanta]

Tags: , , , , , , , ,

Neflaria V2: HTML 5, jQuery 1.4.1

Yay! I love jQuery! I love HTML html 5! I love CSS 3!

And, I’ve decided that Neflaria, Version 2, will be my playground.

Neflaria, for the unacquainted, is the online game that my friend and I inherited a couple years ago. You make a character, you log in, and you fight monsters and chat with other players; while there’s not a whole lot to the game, it has been around for about 10 years, and as such, has a lot of character. And a lot of characters. I mean that endearingly. (Hi, Chris)

However, to a lot of the players, and definitely to me, its 2001-era look is a little stale. Its 12px Times New Roman on 100×100 pixel repeating background. Another word might be “dated.” The server-side database and file structure is a little crazy and unorganized, and it is time for an upgrade. So, here’s where Neflaria version 2 comes in.

One of the decisions we made was to move forward and to use jQuery 1.4.1, which niftily came out just as we were restarting development, to use html 5 (by including the wonderful html 5 shiv [blog post, javascript] for backwards compatibility), and do as much as we can to bring Neflaria into 2010 while at the same time making sure that the people playing the game- who are probably still on IE6- aren’t left out in the dark. Now, I’ve always railed against IE6, and I hate IE6 support more than anything… but by building on a solid base of well-structured html, css, and javascript, we can bend the styles later on to suit IE6’s needs, while maintaining future compatibility. “Graceful Degredation” is the term of the day.

We’re developing Neflaria V2 looking for the future. We’re building our javascript more like a framework and less like a loose collection of methods called “x2″ and “j5″. We’re restructuring the database (aka normalizing the heck out of it) and using JSON served piping hot via short but precise PHP pagelets. It’ll be very client-heavy, assuring server-side performance, and it’ll be extensible for future features. We’re even working on multilingual support, using jQuery to query a language-based XML file by key.

I’m pretty excited. Get a preview here (only the home, terms of service, privacy policy, and “create” and “login” buttons do anything, and it isn’t wired up to the database): http://labs.crimsondeviations.com/NeflariaV2Preview/

Tags: , , , ,

jQuery 1.4 Released! (Let’s have an end-to-end testing party)

Query 1.4 was released as final on January 14, 2010, at 1pm (or so) EST.  The day it came out, I went to my boss and said “let’s update! Woohoo! I’ll order some cake” and he (yeah, yeah, rightfully) said “we need to discuss implications.” Which was a good thing, because- well, why should we even bother with the days of testing that it’ll require to switch out our framework?

I did some research, and there are some very, very compelling reasons. Here’s what I wrote to our team:

We may want to look at updating, or at least putting it in and testing, soon.

Benefits of upgrading:

  • Performance updates
  • IE fixes, including some fixes to IE event bubbling
  • Includes extra API calls and additions to existing functions
  • Maintaining possibility to use new plugins as they are created for the latest version of jQuery
  • Better handling for events (outside of just IE)- we can (should) refactor and reduce a lot of our jQuery code using events
  • Better support for multiple simultaneous animations
  • More granular “does my browser support X” checks

The downside is that we’re going to have to do pretty thorough testing in all browsers to make sure that the update hasn’t broken anything. The main areas to hit will be places that plugins are used:

  • Autocomplete for country/state
  • Loading screen in DE / Admin
  • Media plugin that sets up flash for Audio Guest Book in display
  • Simple Uploader
  • Help boxes in DE

We’ll need to spot-check around other areas of the site for javascript errors as well. jQuery still supports the same browsers- FF 2+, IE 6+, Safari 3+, Opera 9+, Chrome 1+ (http://docs.jquery.com/Browser_Compatibility) so we shouldn’t expect any new weirdness in archaic browsers like IE6.

More information about the update can be found at:

Also: “15 new features you must know”: http://net.tutsplus.com/tutorials/javascript-ajax/jquery-1-4-released-the-15-new-features-you-must-know/

(Lower is better):

Performance of .html()Performance of .remove() and .empty()

Performance of .css()

Performance of DOM Insertion

# of Function Calls for Popular jQuery Methods

Tags: , ,