IP and Web Technology

I recently had a conversation with the principals of another startup, who I’m an informal advisor for, that uses SVG as a central technology. They told me they’d applied for a patent on a combination of SVG and CSS media features (aka “media queries”) for darkmode. I told them then, as I’d told them before, that they can’t do that.

As a public service, I thought it would be useful for them, and for everyone else, if I explained why (or rather, why not) in detail. I hope this will save people from wasting money on patents, from paying for advice from IP lawyers and advisors who don’t know what they’re talking about, and more importantly, save anyone else from frivolous lawsuits regarding web tech.

W3C has a patent policy–a very clever patent policy–that protects their web technologies from predatory practices, and keeps a level playing field for everyone using them. If you’re a lawyer, you should read it; for everyone else, I’m going to highlight some key aspects.

This patent policy has two primary protections: one for members and contributors, and one for users.

  1. Members and contributors to W3C technologies explicitly grant royalty-free permissions to any applicable patents they have for a technology–any technology–developed while they are members of W3C. Does this mean they give up their rights to those patents? Not at all. It means that if Company A has a patent on, say, making a clip-path in a photo so you can insert your face on a mermaid’s body (yes, this is based on a real patent), and they were members of the W3C when the clip-path feature was added to SVG (that is, when it was first published circa 2001, and any subsequent publication that includes the clip-path), they must grant an irrevocable royalty-free (that is, no charge) license for anyone using clip-paths in SVG… but only in SVG. If someone wanted to make a physical photo-booth where they used clip-paths in raster images only, and didn’t use SVG in any way, they would be infringing on Company A’s patent, and would have to negotiate a license at whatever price Company A wanted to charge. (Or, you know, simply use SVG instead.) Company A still holds the patent and licensing rights for all non-SVG uses. But SVG users are protected. (I’ll explain why this is so vital in a bit.)
  2. Users of W3C technologies are protected from lawsuits by any W3C members or contributors who hold patents that are included in those technologies… unless they sue somebody else for infringing on one of their own patents that applies to a W3C technology. This is the very clever bit. Let’s say Company B has a patent on something that is later added to a W3C technology, and Company B shrewdly avoided joining W3C or making any patent policy commitments. Let’s say it’s a specific bezier-curve algorithm, or something. They can certainly sue some other company for using their patented bezier algorithm in SVG… or they can instead choose to use HTML, CSS, SVG, any of the DOM APIs, etc. You can’t have both. You can either assert your rights over your specific IP used on W3C tech, or you can use W3C tech–any W3C tech. You either share with everybody else, or you take your ball and go home, any everyone else will use one of the thousands of other balls at their disposal, and keep playing the game. Because the patent policy protects all W3C technologies, it protects everyone using any of them.

Thus, W3C protects users of their tech both explicitly (from legal agreements by people and companies who joined or contributed to W3C tech) and implicitly (from people who want to use W3C tech).

So, let’s take Company C, who is using W3C tech years after it was developed. They develop what they think–or more insidiously, they are advised by an ill-informed IP lawyer–is a novel technique using W3C technologies. They decide to patent it. Now, as the old regex joke goes, you’ve got two problems.

  1. You can either enforce your IP, and lose the rights to use any W3C technology–a real chicken-egg paradox–or;
  2. You can realize that the very act of using the combination of different W3C technologies for their explicitly intended effect is not patentable, but waste the money anyway.

Why is is not patentable? Because a) there prior art (someone’s already done the same thing), and b) it is “obvious to one skilled in the art”. Both of these are disqualifying from obtaining an enforceable patent. Can you get a patent anyway? Of course, because the patent office is overworked and understaffed and the IP landscape is far too vast for anyone to have a firm grasp on what’s already been done. So the lawyers and patent office take your money and give you the piece of paper (or rather, the registration number), and you can claim “Patented” or “Patent Pending”… but try to assert that patent in court and you’ll lose, either in the lower courts, or in appeal. And in the process of losing the case, you’ll also lose your rights to use W3C technologies as a bonus.

Okay, why is this important? Because without this very clever patent policy, there were be countless frivolous law suits that put a chilling effect on people publishing (or even using) web sites or web apps. That would be a terrible world. This is a legal framework for companies to cooperate to make a public commons without the tragedy.

This is what allows for innovation. Millions of web developers come up with elegant techniques for mixing and matching web tech to solve problems both trivial and devilish, and usually they share how to do this with others, and we all benefit.

I pioneered my share of clever SVG techniques through the years, and benefited even more from techniques other pioneered. In the specific case we’re talking about, using CSS media feature to change the colors of an SVG when a user has darkmode enabled… I don’t know who first did that, but I did it well over a decade ago. It’s not novel, but it is useful. And it’s useful because hundreds, maybe thousands, of people were involved in the conception, specification, standardization, testing, implementation, and deployment of the prefers-color-scheme feature to make sure that we could shift colors for people who needed them (for example, people with vision disabilities like low vision) or who just prefer darkmode. If people could patent that (which–again–they can’t), it would prevent all of us from trying to make our websites and graphics more accessible. To hell with that.

Please, don’t try to patent W3C tech features. Don’t believe people who say you can. And certainly don’t believe people who say you can’t use that tech because they own it; they don’t, and you can and should use it.

Recipe for Spam

I just found this combinatorial comment trapped in my spam filter. It’s interesting to see how the raw script is composed, so they can randomly select phrases, perhaps to throw off spam filters; this one was obviously a misfire.

It’s like a Choose-Your-Own-Adventure or Ad-Lib, but for spam. 🙂

I was impressed that it did have some minimal contextualization, automatically pulling in the title of my previous post and of my blog itself (“Annotators Anonymous � Reinventing Fire”), but was disappointed that they don’t have some sort of topic map to try to pull in related terms to truly customize the comment in a more sophisticated way.

It’s much longer than a typical spam, and pretty repetitive, with several greeting intros, so I assume that  in addition to selecting phrases, whole paragraphs were included or removed. It’s not clear if this was posted by a bot, or by a human who was meant to manually select the phrases and context; I hope for the sake of some underpaid person that it was a bot.

I’m rather skeptical about the topic of the link they chose, to “burberry outlet”, which seems to be some sort of knockoff purse vendor, and is unlikely to appeal to my audience; I’d have preferred something like a knockoff electronics shop in China, which would have had at least minimal appeal.

It linked to songsketches.com (a relatively cool domain name, presumably once populated with more compelling content), and it was posted by “agnes.bungaree@web.de” (IP address 36.250.191.69) on 2014/04/05 at 11:22 am ET.

Some of my favorite highlights:

  • It asks if I get a lot of spam, and how I combat it (very meta!)
  • There is a section with a variety of smileys and winkies, giving them the emotional range of a fine actor
  • The adjective options (and there are a lot of them!) are all very positive and encouraging, a touch I appreciate and which flatters my ego.

C+ for content, D for spelling (quite a few errors, which I’d guess would make the spam more detectable, and which frankly grates on my nerves), F for  execution. However, I will give them a passing grade overall, because they did show their work.

Continue reading “Recipe for Spam”

WebFonts in SVG

Several times recently, people have asked on IRC how they can use nice fonts with SVG. My answer in the long-ago past, when Adobe’s excellent SVG Viewer plugin roamed the Earth, was to use SVG Fonts directly embedded in the SVG file… but that’s no longer practical with the current varied browser support.

By far the easiest way to do this today is to use webfonts, such as WOFF.

Authoring tools, like Inkscape and Adobe Illustrator, should simply manage this for authors, but until that happens, I thought I’d share a relatively simple workflow that has helped others. (Warning: I will use the words font and typeface with careless abandon to semantics in this article, though I know the difference. I’m afraid the more sensitive souls among you may suffer apoplectic righteous indignation.)

I will walk you through this workflow step-by-step, but if you get lost, just look at the source code… it’s pretty self-explanatory.

  1. Find a font you like. For this example, I chose Riesling, an Art Deco typeface by “Bright Ideas”. I made sure the font was free and didn’t have any restrictions for online or commercial use.
  2. Upload the font to FontSquirrel’s @font-face generator, and download the resulting package. This contains the webfonts, as well as some sample files (though not an example of how to use the files in SVG).
  3. Copy the resulting webfont files (*.eot, *.ttf, *.woff, *.svg) into the same directory as the SVG file that will reference them. (Note: do not confuse the SVG file in the FontSquirrel package for a content file; it is an SVG font, with no rendering content.)
  4. Copy the CSS @font-face style rule from the FontSquirrel package file (“stylesheet.css”), and put it in your SVG’s <style> element.
  5. Optionally, for local testing, install the original TTF file as a system font, and add the local value to the @font-face style rule
  6. Add a style rule for text elements, using the resulting font-family. In my example, I also created a style rule for textPath elements.
  7. No, really, that’s it. You’re done.

Here is the resulting SVG using webfonts:

Please use a modern browser.

A Word on the Future of SVG Fonts

Since I’ve mentioned SVG Fonts a couple of times, I thought I’d leave you with a final note about what the future seems to hold for them.

SVG Fonts were added in SVG 1.0, way back in 1999, as a way to embed fonts in the same file, using vectors and all the capabilities of SVG, including separate fill and stroke (which could be gradients or other paint sources), and even exotic features like clip-paths, animation, and so on; Jérémie Patonnier has a great article on the topic. As cool as this is, it doesn’t necessarily work well with existing font engines… The Adobe SVG Viewer had support for SVG Fonts, and Opera and WebKit added support for the less-powerful SVG Tiny 1.2 subset as well; but Mozilla and Microsoft decided not to add support for SVG Fonts, and that limits their usefulness. It doesn’t seem likely that SVG2 (being developed now) will include SVG Fonts, not necessarily even the more limited subset (though there is not yet consensus in the SVG Working Group).

In practical usage, SVG Fonts were once the only way to use webfonts on iOS devices (e.g. the iPhone and iPad), which is why FontSquirrel includes them in their font-face package; but this is no longer the case, and iOS 4.2 added support for TTF fonts, which reportedly perform better. I expect this use of SVG Fonts to dwindle away… people will naturally want to use as few font formats as possible.

But for all of you out there who, like me, love the cool things you can do with SVG Fonts that aren’t possible in traditional outline font formats, don’t despair! Even as I write this, a proposal is being prepared by the SVG glyphs for OpenType Community Group to add a subset of SVG to OpenType, for more interesting typeface capabilities.

SVG Fonts are dead! Long live SVG Fonts!

Archived Link Thunderbird Extension

This week is our first Geek Week at W3C. The idea is to have a week where we improve our skills, collaborate with each other on prototypes and fun projects that help W3C, and to come up for air from our everyday duties. I’m working on a few projects, some small and some larger.

One of my projects is to make a plugin for Thunderbird, my email client of choice, which exposes the Archived-At email message header field, normally hidden, as a hyperlink. This is useful for W3C work because we often discuss specific email messages during teleconferences (“telcons”), and we want to share links to (or otherwise find or browse to) the message in W3C’s email archives. It’s also handy when you are composing messages and want to drop in links referring to other emails. (I do way too much of both of these.)

I’ve made extensions for Firefox before, but never for Thunderbird, so this was an interesting project for me.

Continue reading “Archived Link Thunderbird Extension”

Retain Accessibility Immediately

There has been a heated argument recently on the W3C Canvas API mailing list between accessibility advocates and browser vendors over a pretty tricky topic: should the Canvas API have graphical “objects” to make it more accessible, or should authors use SVG for that? I think it’s a false dichotomy, and I offer a proposal to suggests a way to improve the accessibility potential of the Canvas 2D API by defining how SVG and the Canvas 2D API can be used together.

This brings together some ideas I’ve had for a while, but with some new aspects. This is still a rough overview, but the technical details don’t seem too daunting to me.

Continue reading “Retain Accessibility Immediately”

Getting In Touch

Last week, I published the first draft (and subsequent updates) of the Web Interface specification, which defines touch events. This is the first spec from the new W3C Web Events Working Group.

Peter-Paul Koch (PPK) gave it a positive initial review. Apparently, others thought it was news-worthy as well, because there were a few nice write-ups in various tech sites. Naturally, cnet’s Shank scooped it first (he has his ear to the ground), and it was fairly quickly picked up by macgasm, electronista, and Wired webmonkey.

I thought I’d go into a few of the high-level technical details and future plans for those who are interested.
Continue reading “Getting In Touch”

Translation Services at a Loss for Words

Text in SVG is text. Visually, you can use webfonts like WOFF or SVG Fonts (where they are supported, like in Opera or the iPhone) to make it look cool, and you can style both the stroke and fill to make it all fancy, or apply filters to pop it out or make it glow or give it a dropshadow, but it’s not just a raster image like many text headers… it’s human- and machine-readable text, as nature intended.

So, SVG is translatable, right?
Continue reading “Translation Services at a Loss for Words”

SVG Game Resources

Mozilla is holding an Open Web Games competition. I expect that many of the games will be use the Canvas API, since many programmers are more familiar with the imperative programming mode, and there are some games libraries that have been developed for Canvas or adapted from existing drawing or gaming libraries.

But I’m calling for SVG developers and designers to step up to the plate, as well. SVG has a lot of features that make it easier out of the box to build interfaces, animations, and even games. There is a scene graph, and the DOM event model that gives you free hit detection for pointer events, for example. And I’d love to see someone make an open-web game that’s both accessible and fun…

To help developers along, I thought I’d share a few free, open-source SVG resources that could be useful in building games:
Continue reading “SVG Game Resources”