|
title: Put the knife down and take a green herb, dude. |
descrip: One feller's views on the state of everyday computer science & its application (and now, OTHER STUFF) who isn't rich enough to shell out for www.myfreakinfirst-andlast-name.com Using 89% of the same design the blog had in 2001. |
|
x
MarkUpDown is the best Markdown editor for professionals on Windows 10. It includes two-pane live preview, in-app uploads to imgur for image hosting, and MultiMarkdown table support. Features you won't find anywhere else include...
You've wasted more than $15 of your time looking for a great Markdown editor. Stop looking. MarkUpDown is the app you're looking for. Learn more or head over to the 'Store now! |
|
| Wednesday, November 30, 2011 | |
|
As I'm sitting here rewatching Insomnia, I find myself wondering if anyone records the TV Channel. Interesting artifacts on that one. Honestly, the TV Channel deciding to show "real" shows (and only two channels' worth of schedule at a time, which takes forever) is brilliant. I wanted to catch Insomnia, but also got stuck on Dharma and Greg [sic] earlier this afternoon when I was just checking what's on... Labels: Randmo posted by ruffin at 11/30/2011 09:17:00 PM |
|
| 0 comments | |
|
But be prepared. Javascript keystrokes are insane. If anyone tells you that you can provide thick functionality in a browser, they're right, but there match a desktop app's ease when guiding user input? Impossible. JavaScript - Detecting keystrokes: Punctuation keys Another favorite, this time for the number lock. Chaos on Mac. Mozilla and Safari give 12, Opera 27. Labels: javascript posted by ruffin at 11/30/2011 10:31:00 AM |
|
| 0 comments | |
| Friday, November 25, 2011 | |
|
I've been using Word Starter a lot recently. For some reason, it's all I've got at work, and it's also on the new HP subcompact (d1m) I finally received last week. It's not bad, and it even is nice enough to support the menu-based keyboard shortcuts I'm used to using. But when I tried to add a footnote -- I think that's Alt-I-N -- nothing happened. It sat around waiting for me to hit something after I. Perhaps I'm using Word 2000 shortcuts, or perhaps I just didn't remember correctly. But perhaps I can't add a footnote? If you check the help to see how to add a footnote, Word Starter'll tell you that, sure enough, you can't add a footnote to a document. Microsoft Word Starter 2010 is a simplified version of Word that comes pre-loaded on your computer. Word Starter includes features that are basic to creating and working with documents, but it does not include the rich set of features found in the full version of Word. This article lists the differences in features between Word Starter and the full version of Word. That's cute. Here's the footnote specific jive: Footnotes and endnotes Hrm. That seems weird. What if I want to move text that has a footnote by cutting and pasting? What if I want to duplicate text by copy and pasting? Does the footnote go away? No, and that's how you add 'em. Highlight the footnote, copy, and paste in somewhere else. Now edit from the old footnote text to the new. Of course, this requires that you have a doc to cut and paste from that already has a "donor" footnote. Hey, look! Here's one now! (Though always be wary of taking Word docs from strangers.) It's an interesting move by Microsoft -- you're essentially giving Word away for free, except for those who don't like feeling constricted when they edit, in spite of the fact that pretty much everything is still there. Wonder how much we can thank OpenOffice for this? posted by ruffin at 11/25/2011 04:29:00 PM |
|
| 2 comments | |
| Wednesday, November 23, 2011 | |
|
I've got a web app that has a few buttons that I think are better handled purely within the browser, with no asp.net codebehind blind. So one is a "Save" button that includes... onclick="if (Page_ClientValidate()) document.forms[0].submit();" Now I wrote that, but wondered what the heck Page_ClientValidate was as I looked back. There was no other Page_ClientValidate in the project or even the entire solution. Argh. It was pretty obviously running some Microsoft validation code, and I'm currently using plain jane ASP.NET validators on this page. So I figured MS had hidden the function on me somewhere Sure enough. Here's what I suspect is the javascript file include with the function. 1 <script src="/WebResource.axd?d=RqZmHVG6Bo97ETCETCETC&t=634245046914809245" And sure enough, in that page we find the function in question. 1 function Page_ClientValidate(validationGroup) {I don't know why I don't like the setup. I mean, ASP.NET either has to throw this stuff into your page, and there's already plenty of wacky javascript in there, or slap it into an include. They chose the second, and I'm often a little upset when they do the former. Go figure. I mean, heck, they even use human-readable var names to make it easy for you to figure out what they're doing. Just like any other lib (I'm looking at you, jQuery), there's going to be stuff you didn't write, you know? I guess I just don't like all the overhead and the way their whitespace and code includes completely break with the way I do it. When I use jQuery, there are some includes and a few lines of code in a specialized format. I can still manage the way the code feels when you run through the logic and whitespace. With this auto-generated stuff, I can't as easily. I don't know. Anyhow, that's where Page_ClientValidate is. Labels: asp.net posted by ruffin at 11/23/2011 02:28:00 PM |
|
| 0 comments | |
|
I love to comment code. Sometimes I think it's past the point of usefulness, where my code looks like it might be approaching half comments. That could be bad, but each time I come into code cold, after a break, I'm awfully glad the commenting is there. I hope it's at least half as helpful to others that use my jive. But there is at least one place that lots of comments probably isn't helpful, for two reasons, and that's in code that's sent via network to your user. If it's a javascript include, comments are less useful. Unlike, well, most anything else, that compiles your code to some not exactly interpreted state, javascript sends EVERYTHING to your user. I'll admit, I'm often a bad programmer, and leave everything in there, helping only those two want to prank my code or, more likely, myself when I want to remember what I did in a past project and don't have my codebase handy. But ultimately comments are bad news in Javascript because 1.) you want to obfuscate how your code works in the wild and 2.) more bytes means more network traffic for your server to pump out means, ultimately, slower performance, even in the 2010s. So the easy way out is to minimize your Javascript. It looks like The Right Way to do that is with Yahoo's YUI Compressor: In terms of code minification, the most widely used tools to minify JavaScript code are Douglas Crockford's JSMIN, the Dojo compressor and Dean Edwards' Packer. Each of these tools, however, has drawbacks. JSMIN, for example, does not yield optimal savings (due to its simple algorithm, it must leave many line feed characters in the code in order not to introduce any new bugs). Goodbye comments! And hello greater than average savings. posted by ruffin at 11/23/2011 02:00:00 PM |
|
| 0 comments | |
| Tuesday, November 22, 2011 | |
|
Interesting. I'm seeing this too: I believe I noticed that the "Enter key" functionality depends on the I was actually Googling up how to stop folks from being able to submit a form by pressing return in a textbox, but it looks like if you remove the Submit button (and/or turn it into a normal type="button" INPUT element), that already happens. Interesting. Hope that's a crossbrowser solution. Hello, testing time. posted by ruffin at 11/22/2011 08:35:00 AM |
|
| 0 comments | |
|
If your spam filter can't catch these, you're doing it wrong, okay? I've posted about this before, and it's about the fifth or sixth time I've had one get through. How does this happen? Add a hard-coded rule, for heaven's sake. ... Labels: gmail fail posted by ruffin at 11/22/2011 06:37:00 AM |
|
| 0 comments | |
| Monday, November 21, 2011 | |
|
c# - JQuery UI Dialog with Asp .NET button postback - Stack Overflow: $('#divname').parent().appendTo($("form:first")); That was a pulling hair out situation. Got more help (and fuller description of what was going on) here: One of the first things you will notice when you try and use JQuery UI Dialog in ASP.Net page is it does not perform post backs from within the dialog window. This is because in a ASP.Net page there is only one form element and Jquery appends the dialog "div" outside of the form element. posted by ruffin at 11/21/2011 03:38:00 PM |
|
| 0 comments | |
| Wednesday, November 16, 2011 | |
1 //=======================================================================Labels: jqGrid, jquery, noteToSelf posted by ruffin at 11/16/2011 03:26:00 PM |
|
| 0 comments | |
| Tuesday, November 15, 2011 | |
|
Linux GUI Development: Monodevelop 2.6 review and screenshots � The Mac Daddy: This blog is part of a series looking at programming tools on linux and covers MonoDevelop 2.6 I've got to say that I've had a similar experience. Last time I tried Mono/MonoDevelop, it stunk. And I was largely using SharpDevelop for my C# play (from which MonoDevelop forked), so it wasn't simply disliking the IDE's setup. Now, it seems ready to do some work, and I'm going to try this morning. It does seem to eat up the battery on OS X, but we'll see if I can't get a couple of hours. I've had to remove the Ajax Control Toolkit reference, which I was using for its pretty danged impressive ComboBox implementation, but that was my only change to get things running. Oh, that, and using ClearSelection on DropDownLists, as having a default selected and then filling the GUI with values later apparently clashes in Mono-land. But it's otherwise pixel perfect so far. I'm using data serialized to XML already for testing, so there's no chance for a connection issue. We'll see. posted by ruffin at 11/15/2011 07:55:00 AM |
|
| 0 comments | |
| Monday, November 14, 2011 | |
|
MonoDevelop WinForms? - Ubuntu Forums: Re: MonoDevelop WinForms? Welp, that kinda stinks. I actually ordered a horrendously inexpensive, likely wholly underpowered laptop so that I could program ASP.NET on the go (well, and to have an inexpensive copy of Windows 7 handy), and I think MonoDevelop on OS X might make me think I was an idiot for doing that for ASP.NET, but now not so much for when I want to run Windows applications. (A laptop just for Windows? RLY? I seriously considered the MacBook Air and $130 for Windows 7, but I couldn't justify the extra price. And there are times I've got to get out of the home office and run to Starbucks to keep programming, so mobility is relatively important. And, finally, I had Boot Camp on my MacBook, which doubles as my primary OS X box, before, but it wasn't particularly wieldy. I often like to boot into OS X, and being a hard reboot away was simply too far. Another laptop "needed". There's just nothing good under $400. We'll see if that AMD E-450 is any good, though CPU Benchmarks tells me probably not (compare to my Core 2 Duo and Athlon X4. Ouch.)) That said, the Windows.Forms project does run with MonoDevelop/Mono without any tinkering, which is quite impressive. Obviously GTK look and feel, but it runs! Much more robust/mature than the last time I fooled around with this, iirc. posted by ruffin at 11/14/2011 11:33:00 AM |
|
| 0 comments | |
| Sunday, November 13, 2011 | |
|
My iPod touch (8 gigs) was pretty much full, and one of the worst culprits was the Apps section. It was well over two gigs. But when I added up all the sizes reported in iTunes, it wasn't close. I didn't have more than a gig of apps on there. Long story short, after removing lots of apps I thought might have been hiding how much space they were taking (Kindle, my Gmail account in Mail, etc), I finally figured out it was Al Gore's Our Choice app. It was taking up about a gig all by itself, though it only reported about 60 megs [sic!]. It must be downloading tons of stuff in the background though I can never remember it not showing something when I was outside of WiFi range. Perhaps it was uncompressing files to show them and never recompressing, perhaps even doing it again with each view. Strange. But that explained the lack o' space. And when you're shooting more pictures and movies because of how awsomez!11! iCloud's photo stream is, well, choo needs cho space. posted by ruffin at 11/13/2011 06:01:00 PM |
|
| 0 comments | |
| Thursday, November 10, 2011 | |
|
An Introduction to JavaScript Object Notation (JSON) in JavaScript and .NET: * Jayrock is open-source, making it possible to extend or customize as needed. That's the kind of attitude I like to see. So much stuff is overkill, like XML for AJAX. EDIT: Also good -- The comments in json2.js, a reference impl for JSON here. // Due to a specification blunder in ECMAScript, typeof null is 'object', Labels: json posted by ruffin at 11/10/2011 08:31:00 AM |
|
| 0 comments | |
| Wednesday, November 09, 2011 | |
|
System.Diagnostics.Debugger.Break(); Enjoy. Labels: noteToSelf posted by ruffin at 11/09/2011 09:40:00 AM |
|
| 0 comments | |
| Sunday, November 06, 2011 | |
|
I've been impressed to find that my iPod touch has been synchronizing over WiFi when I start iTunes now, which is admittedly pretty neat. The more transparent the content loading process, the better -- and here, that's "Better as in magical" better. Was looking to see where the magic was with my pictures, though, and things took a dive. I'd just gotten an extended battery for my Android phone that required a replacement phone back to cover the battery on steroids, and the back I received had much of its matte finish sluff off in the packaging. I took a picture to email the merchant with my iPod touch, and went to my Mac, ready to email it. It's nowhere. I have Lion, but never upgraded iPhoto to match, so no Photo Stream there. Nor is Photo Stream automatically synchronizing with my Pictures folder. But guess what? It is syncing with Windows Vista for free. How To Get iCloud's Photo Stream Working On A PC: I find it interesting that Windows users can get this utility for free. Whereas on the Mac, in order to get iCloud syncing you have to upgrade to OS X Lion, which costs $30. One of the few times PCs get the advantage over Macs with iDevices. Yep, not just Lion, but also iPhoto for $15 more. So that's $45 to use Photo Stream on my Mac, $0 on Windows. I recently defended Apple to someone who asked why they had to upgrade everything to the latest version to have it all work like this... I think this way of doing business (having a very small set of supported devices and software) fairly obviously allows Apple to offer better integration and fancier features. And the market seems to respond to it. But it still makes you wonder when Windows users come out ahead at times. (I believe the last time I posted about it was when a version of iTunes worked with a much older Windows computer than Mac.) posted by ruffin at 11/06/2011 09:29:00 AM |
|
| 0 comments | |
| Friday, November 04, 2011 | |
|
Every so often I talk myself out of believing I know which JOIN I want to use in SQL-land. "LEFT OUTER doesn't mean "OUTER" from the point of view of the LEFT table does it? There's no way. It's the entire LEFT table's OUTERness. Right? Yes. Right? Well, try it. But it's a compound statement. I don't really want to write a stupid trial statement, do I? I know this. It's all of the LEFT." "Right?" This visual review is great. LEFT OUTER JOIN is exactly what I thought it was. (Thanks Denny Green): Left outer join produces a complete set of records from Table A, with the matching records (where available) in Table B. If there is no match, the right side will contain null. And continue... That'll last me another year or so. Labels: SQL posted by ruffin at 11/04/2011 11:10:00 AM |
|
| 0 comments | |
| Thursday, November 03, 2011 | |
|
Codige follows. This is the first "seems to work" version. The Microsoft AJAX Control Toolkit ComboBox does a good job of providing almost identical functionality, but doesn't always show the "select"/dropdown portion of the pair. 1 var gintStart = 0;Labels: asp.net, code, problem solved posted by ruffin at 11/03/2011 08:27:00 AM |
|
| 0 comments | |
|
|
All posts can be accessed here: Just the last year o' posts: |
|||||||||||||||||||||
|
||||||||||||||||||||||
|
|
|
|