MacBook, defective by design banner

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.

FOR ENTERTAINMENT PURPOSES ONLY!!!
Back-up your data and, when you bike, always wear white.

As an Amazon Associate, I earn from qualifying purchases. Affiliate links in green.

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!

Monday, September 05, 2016

I think I was reading about CommonMark when I saw this mentioned.

Xkcd on Standards

Sad because true?

Honestly, I think CommonMark is probably a pretty good idea, all things considered. There are people that are going to get concerned with a "spec" that's, as CommonMark puts it, "ambiguous". You don't want strange edge cases that seem to conflict with reasonably hard and fast rules. I think the best complaint I've seen (and I can't dig the source back up in 10 mins of googling) is the "underline for headers" issue.

What do you do here?

This is a header. Or is it the last thing in a section before a horizontal line?
--------------------------------------------------------------------------------
I'm not sure. You tell me.

Apparently the original spec didn't address many edge cases like this, and you'd have to go to the code. I can't recall why that code wasn't good enough, other than folks occasionally disagreeing with it. And different users do have different needs, so I think that's a fair complaint.

And most importantly for coders, CommonMark gives you a test suite. We like to have explicit pass/fail conditions. You're only as good as your metrics and QA.

But yeah, any time somebody's providing something called Babelmark to help you see what's going on in different flavors of a markup format with unresolved edge cases, you've got a fragmentation problem.


Also worth mentioning: Is HTML a Humane Markup Language? from Atwood. Probably as good a visualization of why we might prefer Markdown to some other markup language that's got some traction right now as I've seen, though Atwood here (contra Atwood now, afaict) strangely decides that HTML is easier to eyeball than Markdown.


In other news, I had this choice definition of POJO open from Martin Fowler's site. I was pretty confident when I read "Anemic Domain Model" that he'd meant Plain Old Java Object, but the backstory is both hilarious and tragic.

POJO An acronym for: Plain Old Java Object.

The term was coined while Rebecca Parsons, Josh MacKenzie and I were preparing for a talk at a conference in September 2000. In the talk we were pointing out the many benefits of encoding business logic into regular java objects rather than using Entity Beans. We wondered why people were so against using regular objects in their systems and concluded that it was because simple objects lacked a fancy name. So we gave them one, and it's caught on very nicely.

(ใƒผ_ใƒผ๏นก)

Labels: , , ,


posted by ruffin at 9/05/2016 04:56:00 PM
Thursday, May 28, 2015

While reading up on how to properly respond to Accept-Encoding:gzip requests with a quick node server I'm hacking up, I ran into this support article about IE6:

In Internet Explorer, the Urlmon.dll file uses an internal buffer to read compressed data. Urlmon.dll fills this buffer when more data arrives and empties the buffer when Urlmon's client, Mshtml, reads data. The bytes that remain to be decoded in the buffer may be small (8 bytes or less) and the data contained in the buffer decompresses to 0 bytes. Frequently, this data is gzip frame data. When Mshtml receives 0 bytes, it thinks that all the data is read and closes the data stream. As a result, the HTML page sometimes appears truncated.

No, I'm not saying you necessarily need to code around the foibles of a now [thankfully] fairly rare version of IE.

What I am saying is that this is a rookie mistake that made it out of QA at one of the best software engineering companies (particularly in 2002-2003) there is, and in one of its marquee products. Anyone who has used streams has run into issues with buffers similar to this one. This is, at worst, a slight variation on theme.

Though I'm not suggesting you forgive bad code either, it is slightly comforting to know that, at least 12 years ago, Microsoft let something so [okay, potentially anachronistically] glaring slip.

Labels: , , , ,


posted by ruffin at 5/28/2015 09:12:00 AM
Monday, August 06, 2012

WebKit Isn't Breaking the Web. You Are | Webmonkey | Wired.com:

We at Webmonkey hope itโ€™s obvious that building WebKit-only sites is a waste of time. If youโ€™re only interested in iOS users then take a tip from Instagram and build a native app.


Let's just quickly say that's crazy advice, and it misses the point of Glazman's critique.

If you don't know Objective-C, by all means, leverage what you do know if it'll make a strong HTML5 app for mobile devices. Use PhoneGap. Enjoy. No guilt required. Seriously, if you can't code HTML5 for other browsers you need to learn to code Obj-C in Xcode? Insane and inane.

The point is that those who use HTML5 shouldn't use browser-specific prefixes. Not sure how I feel about that either. If one browser (or rendering engine) is so far in front of another, then it's going to "win" the adoption war. Examples are written with webkit prefixes, they're copy and pasted, seem to work okay for their intended browser, and we're done. It's a non-trivial expense to learn that webkit isn't a standard if you're a gunslinger. (I'm not arguing we should be gunslingers, but that browsers should realize they exist. LOTS of them.)

If the other browsers support those CSS standards with their own prefixes (and with standardized ones), it's a heck of a lot easier to have the browsers support the different models than every programmer. Any time you're asking a programmer to write something twice to do things right (really, I'm pretty tired of if (document.getElementById) { branch1 } else...), you're doing it wrong. Get the cheese off of your face. Normalize. Put the logic where it belongs.

To be clear: In this case, it means Firefox needs to get over itself and chase WebKit. IE might follow. Do we care?

It's an ivory tower versus the market issue. You can't control programmers absolutely. I, in theory, like where Glazman is going. And in practice, just mentioning it will lessen the issue. Let's just stop pretending it's a zero-effort change for programmers to write platform neutral code and, therefore, as long as browsers are less than 100% equal, you'll always have a percentage of the code in the wild that supports one over the other.

Degrade? Sure. Write to treat each version of each browser equally? Impossible. [sic]

Labels: , , ,


posted by ruffin at 8/06/2012 09:02:00 AM
Thursday, March 22, 2012

I'm finally getting to the point that my hands hurt from typing too much, especially my index fingers, thumb, and wrists. I use a Microsoft Natural Keyboard Pro, which has helped in the past, but it's not enough. I think the reaching for gthy is getting to me. The mouse isn't helping either.

So for the usual reasons, I'm considering Dvorak.

How to Switch to a Dvorak Keyboard Layout: 8 steps - wikiHow:
In this sample paragraph, 70% of the letters are on the home row in Dvorak, with 15% top and 15% bottom. In QWERTY 30% are on the home row. Beware, it takes a little getting used to, especially if you're transitioning from a standard QWERTY keyboard.
...
The standard QWERTY keyboard layout was designed to prevent typewriter jams (which is no longer necessary with computers), whereas the Dvorak layout was designed specifically to be easy on the hands.


The problem is, of course, that we don't just use keyboards for typing English any more. And there's a good negative in that piece, however, that got me thinking... "Depending on your operating system, keyboard shortcuts such as CTRL+C may lose their convenient placement."

So the question for becomes, even if I could rethread my head around the layout, how would I do in VIm?

Let's check the vim Wikia entry for "Using Vim with the Dvorak keyboard layout":

Many Dvorak users have no problem learning the normal Vim commands with a Dvorak layout. The movement keys may not look it at first but are in fact pretty intuitive -- J and K are on the middle and index fingers of the left hand, right next to each other in the same order as on the qwerty layout, while H and L are the index and pinky fingers of the right hand, so the one for left is on the left -- again perfectly accessible.

[from the comments from the same page:]
I have been using Dvorak (as X keyboard map) and Vim for about two years now, without *any* adjustments (concerning Dvorak) to Vim at all, and it works great. The solution imho is to simply remember Vim commands by their name, rather than their keyboard position (e.g. I think I want to d(elete) 2 w(ords), and hit d2w without thinking about the key positions (my fingers know the position themselves).


I have a hard time buying that. Why do I want to leave roguelike controls again? Sounds like a mess.

It's an interesting example of standards inertia.

Guess I'm looking for a new keyboard.

EDIT: I think I'm trending towards this camp.

Effectively my brain was trying to wire three kinds of cursor movement modes:

1) Dvorak Vim with remappings (when I'm on my own machine)

2) Dvorak Vim with no remappings (when I'm on someone else's machine and have the keyboard remapped)

3) Qwerty Vim (when I'm on someone else's machine and don't have the keyboard remapped)

This is, simply, too much. Your life as a programmer is hard enough without you having to learn three different spatial layouts for text editing commands.

Labels: , ,


posted by ruffin at 3/22/2012 09:33:00 AM

<< Older | Newer >>


Support freedom
All posts can be accessed here:


Just the last year o' posts:

URLs I want to remember:
* Atari 2600 programming on your Mac
* joel on software (tip pt)
* Professional links: resume, github, paltry StackOverflow * Regular Expression Introduction (copy)
* The hex editor whose name I forget
* JSONLint to pretty-ify JSON
* Using CommonDialog in VB 6 * Free zip utils
* git repo mapped drive setup * Regex Tester
* Read the bits about the zone * Find column in sql server db by name
* Giant ASCII Textifier in Stick Figures (in Ivrit) * Quick intro to Javascript
* Don't [over-]sweat "micro-optimization" * Parsing str's in VB6
* .ToString("yyyy-MM-dd HH:mm:ss.fff", CultureInfo.InvariantCulture); (src) * Break on a Lenovo T430: Fn+Alt+B
email if ya gotta, RSS if ya wanna RSS, (?_?), ยข, & ? if you're keypadless


Powered by Blogger etree.org Curmudgeon Gamer badge
The postings on this site are [usually] my own and do not necessarily reflect the views of any employer, past or present, or other entity.