functional - Dave's Blog

Search
My timeline on Mastodon

URI functions in Windows Store Applications

2013 Jul 25, 1:00PermalinkCommentsc# c++ javascript technical uri windows windows-runtime windows-store

laughingsquid: Arrested Development Season 4 Trailer Brings...

2013 May 13, 2:47


laughingsquid:

Arrested Development Season 4 Trailer Brings Back the Dysfunctional Bluth Family

Come on!

PermalinkCommentshumor trailer arrested-development awesome

Learn from Haskell - Functional, Reusable JavaScript (github.com)

2012 Feb 21, 3:32PermalinkCommentstechnical programming functional haskell javascript

Command line for finding missing URLACTIONs

2011 May 28, 11:00

I wanted to ensure that my switch statement in my implementation of IInternetSecurityManager::ProcessURLAction had a case for every possible documented URLACTION. I wrote the following short command line sequence to see the list of all URLACTIONs in the SDK header file not found in my source file:

grep URLACTION urlmon.idl | sed 's/.*\(URLACTION[a-zA-Z0-9_]*\).*/\1/g;' | sort | uniq > allURLACTIONs.txt
grep URLACTION MySecurityManager.cpp | sed 's/.*\(URLACTION[a-zA-Z0-9_]*\).*/\1/g;' | sort | uniq > myURLACTIONs.txt
comm -23 allURLACTIONs.txt myURLACTIONs.txt
I'm not a sed expert so I had to read the sed documentation, and I heard about comm from Kris Kowal's blog which happilly was in the Win32 GNU tools pack I already run.

But in my effort to learn and use PowerShell I found the following similar command line:

diff 
(more urlmon.idl | %{ if ($_ -cmatch "URLACTION[a-zA-Z0-9_]*") { $matches[0] } } | sort -uniq)
(more MySecurityManager.cpp | %{ if ($_ -cmatch "URLACTION[a-zA-Z0-9_]*") { $matches[0] } } | sort -uniq)
In the PowerShell version I can skip the temporary files which is nice. 'diff' is mapped to 'compare-object' which seems similar to comm but with no parameters to filter out the different streams (although this could be done more verbosely with the ?{ } filter syntax). In PowerShell uniq functionality is built into sort. The builtin -cmatch operator (c is for case sensitive) to do regexp is nice plus the side effect of generating the $matches variable with the regexp results.
PermalinkCommentspowershell tool cli technical command line

FBJS - Facebook Developer Wiki

2010 May 6, 7:25Another subset of javascript and DOM access to make a sandbox: "FBJS is Facebook's solution for developers who want to use JavaScript in their Facebook applications. We built FBJS to empower developers with all the functionality they need, and to protect our users' privacy at the same time."PermalinkCommentssandbox web browser facebook html javascript technical security web-sandbox

Where's Walden? » Whole-text DOM functionality and Acid3 redux

2010 Mar 18, 7:15This article describes the largest problem with the Acid3 test: "Acid3 often didn’t test things web authors wanted, but instead it tested things that were broken or not implemented regardless whether anyone truly cared."PermalinkCommentsacid3 web browser html dom test technical

GL10 (Java Binding for the OpenGL ES(R) API)

2009 Dec 25, 6:15"The GL10 interface contains the Java(TM) programming language bindings for OpenGL(R) ES 1.0 core functionality."PermalinkCommentsprogramming java opengl android cellphone technical reference 3d

YouTube - Google Chrome OS Demo

2009 Nov 20, 7:20I think I'm stuck on the first part of the Ars review "so it has taken the netbook, which was already a crippled notebook, and crippled it even further by removing a ton of flexibility and functionality". Still conceptually I like the idea and hope they figure out all their use cases.PermalinkCommentsgoogle chrome video os web browser technical

Flickr Visual Search in IE8

2009 Apr 10, 9:48

A while ago I promised to say how an xsltproc Meddler script would be useful and the general answer is its useful for hooking up a client application that wants data from the web in a particular XML format and the data is available on the web but in another XML format. The specific case for this post is a Flickr Search service that includes IE8 Visual Search Suggestions. IE8 wants the Visual Search Suggestions XML format and Flickr gives out search data in their Flickr web API XML format.

So I wrote an XSLT to convert from Flickr Search XML to Visual Suggestions XML and used my xsltproc Meddler script to actually apply this xslt.

After getting this all working I've placed the result in two places: (1) I've updated the xsltproc Meddler script to include this XSLT and an XML file to install it as a search provider - although you'll need to edit the XML to include your own Flickr API key. (2) I've created a service for this so you can just install the Flickr search provider if you're interested in having the functionality and don't care about the implementation. Additionally, to the search provider I've added accelerator preview support to show the Flickr slideshow which I think looks snazzy.

Doing a quick search for this it looks like there's at least one other such implementation, but mine has the distinction of being done through XSLT which I provide, updated XML namespaces to work with the released version of IE8, and I made it so you know its good.

PermalinkCommentsmeddler xml ie8 xslt flickr technical boring search suggestions

G1 Android Phone

2008 Nov 9, 11:29

T-Mobile G1 Wallpapers by romainguy
I finally replaced my old regular cell-phone which was literally being held together by a rubber band with a fancy new G1, my first Internet accessible phone.

I had to call the T-Mobile support line to get data added to my plan and the person helping me was disconcertingly friendly. She asked about my weekend plans and so I felt compelled to ask her the same. Her plans involved replacing her video card so she could get back to World of Warcraft and do I enjoy computer gaming? I couldn't tell if she was genuine or if she was signing me up for magazines.

I was with Sarah in her new car, trying out the phone's GPS functionality via Google Maps while she drove. I switched to Street View and happened to find my car. It was a weird feeling, kind of like those Google conspiracy videos.

The phone runs Google's open source OS and I really enjoy the application API. Its all in Java and URIs and mime-types are sort of basics. Rather than invoking the builtin item picker control directly you invoke an 'intent' specifying the URI of your list of items, a mime-type describing the type of items in the list, and an action 'PICK' and whatever is registered as the picker on the system pops up and lets the user pick from that list. The same goes if you want to 'EDIT' an image, or 'VIEW' an mp3.

I wanted to replace the Google search box gadget that appears on the home screen with my own search box widget that uses OpenSearch descriptors but apparently in the current API you can't make home screen gadgets without changing parts of the OS. My other desired application is something to replace this GPS photo tracker device by recording my location to a file and an additional program on my computer to apply those locations to photos.

PermalinkCommentstmobile personal api phone technical g1 android google

Mozilla Labs launches geolocation extension

2008 Oct 13, 2:21Neat geolocation API for web apps: "Mozilla Labs has announced the availability of Geode, an experimental Firefox extension that implements the W3C Geolocation Specification. Geode provides an early preview of the same location-aware functionality that will be included in both Fennec and Firefox 3.1."PermalinkCommentsgeolocation geo w3c mozilla javascript web

Disemvowelment and Reemvowelment Tools

2008 Oct 3, 5:29I thought the disemvowelment of trolls was a pretty funny punishment -- much better than simply removing the comment: "Disemvowelment is - obviously enough - the act of removing the vowels from a passage of text, as well as a pun on the word 'disembowelling'. A number of blogs and websites do this to offensive text which has been placed in their 'comments' section. ... This site exists because I couldn't resists the challenge of trying to re-emvowel disemvowelled text. This is a challenging task, as the disemvowelled word 'dg' may well have been 'dog', but also 'dig', 'dug', 'doge', diego' and so on. I have a first cut of this functionality at the re-emvowel link at the side of the page. A more advanced version is in progress."PermalinkCommentstool disemvowelment web comment forum troll language

Why Verbs? - Not The User's Fault

2008 Aug 28, 11:15I can't say why this is funny: "First, the really big picture of what Ubiquity is supposed to be all about: It's a step towards a Web where verbs (i.e. functionality, i.e. commands, i.e. services) are first-class citizens. And that's why I'm thinking it should be renamed from Ubiquity to something like "Mozilla Verbs", maybe."PermalinkCommentsmozilla firefox ubiquity ui via:ethan_t_hein

Feed Folder Deprecated; Use Internet Explorer 8

2008 Mar 7, 7:20

Internet Explorer 8 has made my plugin Feed Folder obselete in functionality and implementation -- which is good!

IE8's Feed Folder feature screen shot.IE7 Feed Folder plugin screen shot.

I made Feed Folder for IE7 because I wanted the Live Bookmarking feature from FireFox. The Feed Folder plugin for IE7 would allow you to display your feeds as virtual folders in your Links Bar. When your feed is updated the virtual folder is updated as well with the new feed items. I use del.icio.us to store all my links so I could add virtual folders of my daily links, my friends blogs links, quick reference links, etc. etc.

My plugin relied on shell folders to implement the virtual folders I described above, but IE8 doesn't support shell folders in the Favorites Bar. But I'm OK with Feed Folder not working in IE8 since there's a much better implementation already there. IE8 does better than my plugin on a number of points: First, there isn't the horrible perf. issue that my plugin had on Vista. Second, when a feed is updated the virtual folder flashes to note the change in status. Third, unread items are bolded and the bolding bubbles up from feeds contained in subfolders. And lastly, the middle click button is supported to open items in a new tab.

Accordingly, I don't plan to work on Feed Folder anymore unless someone comes up with a good reason. Instead I mark Feed Folder deprecated and suggest you use Internet Explorer 8 instead.

To use this feature in IE8 simply drag a feed from your feed list in your Favorites Center onto your Favorites Bar. Or, when viewing a feed, click on the 'Add to Favorites' Star Plus icon thing in the upper left, and select 'Monitor on Favorites Bar'. A .url Internet Shortcut file is produced as usual, but if you open up the .url file you'll see there's some additional info about the feed.

PermalinkCommentsie8 feed feedfolder plugin technical browser ie rss

Summary of data visualisation utilities measured by functionality - Swivel

2008 Jan 3, 12:30This just in from Swivel: Swivel is the best!PermalinkCommentsswivel data visualization website

Functional Requirements for Uniform Resource Names (RFC 1737)

2007 Feb 21, 6:30Standard describing the requirements of URNs.PermalinkCommentsurn standard reference rfc ietf uri

Representing vCard Objects in RDF/XML

2006 Nov 28, 5:15This note specifies a Resource Description Framework (RDF) encoding of the vCard profile defined by RFC 2426 and to provide equivalent functionality to its standard format. The motivation is to enable the common and consistent description of persons (usinPermalinkCommentsrdf reference semanticweb specification standards w3c xml vcard schema example

Vroom

2004 Sep 10, 12:04I got my driver's license today. Imagine that. I lost all of the points that I could on the parallel parking portion of the test. You know in California they don't test you on parallel parking ability. With my new license my functional impairment level has moved from minor to non-existent. Hoo-raw. Incidentally if you search for the phrase "stealth geriatrics" on google, the first link is to a power point presentation entitled "stealth geriatrics." I just thought that was a funny phrase.PermalinkComments
Older Entries Creative Commons License Some rights reserved.