You are here

thinktime

Andrew Pollock: [life] Day 180: Kindergarten, recovery and an afternoon play date

Planet Linux Australia - Mon 28th Jul 2014 21:07

I was away all weekend with Anshu, so I had to play weekend catch up when I got home this morning. After I'd unpacked the car and sorted out some lunch, I did the grocery shopping, and by the time I'd unpacked from that it was pretty much time to pick up Zoe and Megan from Kindergarten.

On the way home from Kindergarten, Zoe asked if they could go to the playground. I'd been intended to offer them the playground or a ferry ride, so this worked out nicely.

Zoe wanted to ride her scooter to the park, and Megan seemed happy to run alongside her, so this seemed like a win-win situation. There were a few other kids from Kindergarten at the playground as well.

The small world factor struck this afternoon. There was a mother at the playground that I'd seen at pick up time at Kindergarten, who I didn't recognise, so I struck up a conversation with her. It turns out she's the mother of a boy who was in Zoe's swim class last year. I'd previously spoken with her husband at swim school. They were from Melbourne, had had a stint up in Brisbane, returned to Melbourne, decided they liked Brisbane better, and just relocated back again. Their son, Miller, had gone to Zoe's Kindergarten last year as well, and his Dad had had good things to say about it Sarah at Zoe's swim class.

After the stint in the park, we came back home, and Zoe and Megan watched a bit of TV while I prepared dinner, and then Jason came to pick up Megan.

We had a nice dinner, and I got Zoe to bed a little bit early.

Categories: thinktime

Andrew Pollock: [life] Day 177: Bike riding practice, picnic

Planet Linux Australia - Mon 28th Jul 2014 14:07

Friday was another loosely planned day. Zoe indicated that she'd like to practice riding her bike, and it was a nice day, so we made a picnic lunch of it.

We went to Minnippi again, and Zoe did pretty well. I used the gentle downhill part of the path this time to give Zoe a bit more momentum, and there were a few brief periods where I let go of the bike completely and she stayed upright. I definitely think she's getting better, and her confidence is improving. Hopefully a few more practices will have her riding on her own.

After she got tired of riding her bike, we checked out the aviation-themed play area. We had some fun alternating between being the "pilot" and the "control tower". We had our picnic lunch up in that part of the park.

Shortly after lunch, another little girl, Lilian, arrived with her mother, and Zoe befriended her, although she didn't want to play with her all that much. I struck up a bit of a conversation with her mother, and when they migrated over to the duck pond, we went as well, as we had some crusts to feed to the ducks.

There was a guy over there with a big loaf of bread, which he was feeding to the ducks unsuccessfully. When Zoe and Lilian arrived, he donated the remainder of the bread to them to feed to the ducks.

After that, we all went to the other play structure for a while.

When Lilian left, we headed back to Cannon Hill to get some more kitty litter and a tennis racquet. We also dropped into Bunnings for a coffee and babyccino. Bunnings has a bit of an indoor play area, so Zoe checked that out too.

It was getting on in the afternoon by this stage, so we headed home and pottered around for a little bit. Zoe watched some TV, Anshu arrived, and then Sarah arrived to pick up Zoe. It was a nice day.

Categories: thinktime

Brendan Scott: brendanscott

Planet Linux Australia - Mon 28th Jul 2014 13:07

Getup alleges that someone has copied one of Getup’s videos, then issuing a takedown over the same video in respect of Getup.  With copyright enforcement rhetoric running hysterical for years now it comes as no surprise that the provider of the video site would remove Getup’s video.  Takedown procedures are specifically designed to be swift and effective against allegations, regardless of the justice of the matter.  Given such a lopsided approach to rights, it is surprising that it has taken until now for people to start abusing the system.  It will get worse in the future.



Categories: thinktime

Andrew Cowie: Vale Peter Miller

Planet Linux Australia - Mon 28th Jul 2014 11:07

Sad to receive news this morning that a long time friend and colleague, Peter Miller, had passed.

“After fighting cancer for many years, finally lost”. No, not lost; if there was ever anyone who fought the battle of life and won it was be Peter. Even knowing he was at his last days he was unbowed. Visiting him last week he proudly showed us the woodworking plans and cut lists for some cabinets he was making for his wife MT. He had created the diagrams himself, writing C++ code to call manually drive a drawing library, outputting postscript. Let’s see you do architectural drawing without a CAD program. The date on the printout was two weeks ago.

“The world is a less interesting place today,” wrote another friend. No. Peter firmly believed that interest comes from within. The world is there to be explored, I can hear him saying. He taught us to go forth, wonder, and understand. And so we should.

AfC

Categories: thinktime

Sridhar Dhanapalan: Twitter posts: 2014-07-21 to 2014-07-27

Planet Linux Australia - Mon 28th Jul 2014 00:07
Categories: thinktime

Brace for impact

Seth Godin - Sun 27th Jul 2014 19:07
I would imagine that there are certain situations, perhaps involving the martial arts, where bracing for impact is a good idea. The rest of the time, not so much. If your car is about to hit a tree at thirty...         Seth Godin
Categories: thinktime

If you can't sell it, you can't build it

Seth Godin - Sat 26th Jul 2014 19:07
Architecture students bristle when Joshua Prince-Ramus tells them that they are entering a rhetorical profession. A great architect isn't one who draws good plans. A great architect gets great buildings built. Now, of course, the same thing is true for...         Seth Godin
Categories: thinktime

Back to the drawing board

Seth Godin - Fri 25th Jul 2014 19:07
Isn't the drawing board the place where all the best work happens? It's not a bad thing to go back there. It's the entire point. (HT to Neil).         Seth Godin
Categories: thinktime

Matt Griffin on How We Work: Being Profitable

a list apart - Thu 24th Jul 2014 22:07

When I recently read Geoff Dimasi’s excellent article I thought: this is great—values-based business decisions in an efficient fashion. But I had another thought, too: where, in that equation, is the money?

If I’m honest with myself, I’ve always felt that on some level it’s wrong to be profitable. That making money on top of your costs somehow equates to bilking your clients. I know, awesome trait for a business owner, right?

Because here’s the thing: a business can’t last forever skating on the edge of viability. And that’s what not being profitable means. This is a lesson I had to learn with Bearded the hard way. Several times. Shall we have a little bit of story time? “Yes, Matt Griffin,” you say, “let’s!” Well OK, then.

At Bearded, our philosophy from the beginning was to focus on doing great web work for clients we believed in. The hope was that all the sweat and care we put into those projects and relationships would show, and that profit would naturally follow quality. For four years we worked our tails off on project after project, and as we did so, we lived pretty much hand-to-mouth. On several occasions we were within weeks and a couple of thousand bucks from going out of business. I would wake up in the night in a panic, and start calculating when bills went out and checks would come in, down to the day. I loved the work and clients, but the other parts of the business were frankly pretty miserable.

Then one day, I went to the other partners at Bearded and told them I’d had it. In the immortal words of Lethal Weapon’s Sergeant Murtaugh, I was getting too old for this shit. I told them I could put in one more year, and if we weren’t profitable by the end of it I was out, and we should all go get well-paid jobs somewhere else. They agreed.

That decision lit a fire under us to pay attention to the money side of things, change our process, and effectively do whatever it took to save the best jobs we’ve ever had. By the end of the next quarter, we had three months of overhead in the bank and were on our way to the first profitable year of our business, with a 50 percent growth in revenue over the previous year and raises for everyone. All without compromising our values or changing the kinds of projects we were doing.

This did not happen on its own. It happened because we started designing the money side of our business the way we design everything else we care about. We stopped neglecting our business, and started taking care.

“So specifically,” you ask, “what did you do to turn things around? I am interested in these things!” you say. Very good, then, let’s take a look.

Now it’s time for a breakdown

Besides my arguably weird natural aversion to profit, there are plenty of other motivations not to examine the books. Perhaps math and numbers are scary to you. Maybe finances just seem really boring (they’re no CSS pseudo-selectors, amiright?). Or maybe it’s that when we don’t pay attention to a thing, it’s easier to pretend that it’s not there. But in most cases, the unknown is far scarier than fact.

When it comes down to it, your businesses finances are made up of two things: money in and money out. Money in is revenue. Money out is overhead. And the difference? That’s profit (or lack thereof). Let’s take a look at the two major components of that equation.

Overhead Overheels

First let’s roll up our sleeves and calculate your overhead. Overhead includes loads of stuff like:

  • Staff salaries
  • Health insurance
  • Rent
  • Utilities
  • Equipment costs
  • Office supplies
  • Snacks, meals, and beverages
  • Service fees (hosting, web services, etc.)

In other words: it’s all the money you pay out to do your work. You can assess these items over whatever period makes sense to you: daily, weekly, annually, or even by project.

For Bearded, we asked our bookkeeper to generate a monthly budget in Quicken based on an average of the last six months of actual costs that we have, broken down by type. This was super helpful in seeing where our money goes. Not surprisingly, most of it was paying staff and covering their benefits.

Once we had that number it was easy to derive whatever variations were useful to us. The most commonly used number in our arsenal is weekly overhead. Knowing that variable is very helpful for us to know how much we cost every week, and how much average revenue needs to come in each week before we break even.

Everything old is revenue again

So how do we bring in that money? You may be using pricing structures that are fixed-fee, hourly, weekly, monthly, or value-based. But at the end of the day you can always divide the revenue gained by the time you spent, and arrive at a period-based rate for the project (whether monthly, weekly, hourly, or project length). This number is crucial in determining profitability, because it lines up so well with the overhead number we already determined.

Remember: money in minus money out is profit. And that’s the number we need to get to a point where it safely sustains the business.

If we wanted to express this idea mathematically, it might look something like this:

(Rate × Time spent × Number of People) - (Salaries + Expenses) = Profit

Here’s an example:

Let’s say that our ten-person business costs $25,000 a week to run. That means each person, on average, needs to do work that earns $2,500 per week for us to break even. If our hourly rate is $100 per hour, that means each person needs to bill 25 hours per week just to maintain the business. If everyone works 30 billable hours per week, the business brings in $30,000—a profit of 20 percent of that week’s overhead. In other words, it takes five good weeks to get one extra week of overhead in the bank.

That’s not a super great system, is it? How many quality billable hours can a person really do in a week—30? Maybe 36? And is it likely that all ten people will be able to do that many billable hours each week? After all, there are plenty of non-billable tasks involved in running a business. Not only that, but there will be dry periods in the work cycle—gaps between projects, not to mention vacations! We won’t all be able to work full time every week of the year. Seems like this particular scenario has us pretty well breaking even, if we’re lucky.

So what can we do to get the balance a little more sustainable? Well, everyone could just work more hours. Doing 60-hour weeks every week would certainly take care of things. But how long can real human beings keep that up?

We can lower our overhead by cutting costs. But seeing as most of our costs are paying salaries, that seems like an unlikely place to make a big impact. To truly be more profitable, the business needs to bring in more revenue per hour of effort expended by staff. That means higher rates. Let’s look at a new example:

Our ten-person business still costs $25,000 a week. Our break-even is still at $2,500 per week per person. Now let’s set our hourly rate at $150 per hour. This means that each person has to work just under 17 billable hours per week for the business to break even. If everyone bills 30 hours in a week, the business will now bring in $45,000—or $20,000 in profit. That’s 80 percent of a week’s overhead.

That scenario seems a whole lot more sustainable—a good week now pays for itself, and brings in 80 percent of the next week’s overhead. With that kind of ratio we could, like a hungry bear before hibernation, start saving up to protect ourselves from less prosperous times in the future.

Nature metaphors aside, once we know how these parts work, we can figure out any one component by setting the others and running the numbers. In other words, we don’t just have to see how a specific hourly rate changes profit. We can go the other way, too.

Working for a living or living to work

One way to determine your system is to start with desired salaries and reasonable work hours for your culture, and work backwards to your hourly rate. Then you can start thinking about pricing systems (yes, even fixed price or value-based systems) that let you achieve that effective rate.

Maybe time is the most important factor for you. How much can everyone work? How much does everyone want to work? How much must you then charge for that time to end up with salaries you can be content with?

This is, in part, a lifestyle question. At Bearded, we sat down not too long ago and did an exercise adapted from an IA exercise we learned from Kevin M. Hoffman. We all contributed potential qualities that were important to our business—things like “high quality of life,” “high quality of work,” “profitable,” “flexible,” “clients who do good in the world,” “efficient,” and “collaborative.” As a group we ordered those qualities by importance, and decided we’d let those priorities guide us for the next year, at which point we’d reassess.

That exercise really helped us make decisions about things like what rate we needed to charge, how many hours a week we wanted to work, as well as more squishy topics like what kinds of clients we wanted to work for and what kind of work we wanted to do. Though finances can seem like purely quantitative math, that sort of qualitative exercise ended up significantly informing how we plugged numbers into the profit equation.

Pricing: Where the rubber meets the road

Figuring out the basics of overhead, revenue, and profit, is instrumental in giving you an understanding of the mechanics of your business. It lets you plan knowledgeably for your future. It allows you to make plans and set goals for the growth and maintenance of your business.

But once you know what you want to charge there’s another question—how do you charge it?

There are plenty of different pricing methods out there (time unit-based, deliverable-based, time period-based, value-based, and combinations of these). They all have their own potential pros and cons for profitability. They also create different motivations for clients and vendors, which in turn greatly affect your working process, day-to-day interactions, and project outcomes.

But that, my friends, is a topic for our next column. Stay tuned for part two of my little series on the money side of running a web business: pricing!

Categories: thinktime

Andrew Pollock: [life] Day 176: Museum and swimming

Planet Linux Australia - Thu 24th Jul 2014 22:07

Today was a pretty chill day, after yesterday's crazy busy one.

Zoe jumped into bed with at 5:40am, but snoozed again until about 6:30am. It was exciting to get up and watch the inverter showing an ever-increasing power production as the sun rose.

I let Zoe choose what she wanted to do, which is code for "I had nothing in particular planned". She chose the museum by bus this morning, so we were out the door by 9am and on a bus not long after.

The museum had never mailed out my new membership cards from a month ago, so I stopped by the tickets desk first to try and sort that out. They were very apologetic, and gave me two free tickets to Deep Oceans show. They're valid until October, so we'll go back and check that out another day.

Zoe mostly just wanted to go to the Science Centre, so after some morning tea, we headed over there. The place was almost totally empty, so we had free run, which was pretty cool. That took us through until lunch time.

I was trying to make the 12:34pm bus home, but we managed to miss it by maybe 20 metres, which was a bit of a bummer. The lady who did the indoor air quality testing was going to come back at some point after 1pm. Fortunately she didn't end up coming until closer to 2pm, so we were fine getting the 1:04pm bus instead.

After she'd been, we briefly dropped in on one of our neighbours on the way out to grab a few things for dinner from the Hawthorne Garage.

Zoe wanted to go to the pool, which was going to be a bit tight, but we made it out to Colmslie for a brief splash around in the pool before I had to get home to put dinner on.

I wanted to get out to a seminar about company boards at 5:30pm, and Sarah was coming around to babysit Zoe for me, so I wanted to get dinner on the table at 5 before I had to leave. That didn't work out quite to plan, so I had to leave with dinner about 15 minutes from being ready.

I managed to order a taxi and get it almost immediately, and it got me into the city within 15 minutes, which was pretty good. On the way home afterwards, I managed to hail a taxi within minutes of leaving the building, so overall, the transport piece worked really well.

The seminar itself was vaguely interesting. I'm curious about getting on a company board, as I think it could be a good use of my experience, and also a non-9-to-5 way of making some income. I'm not quite sure how to get that first board seat though, and exactly what to expect from a time commitment.

Categories: thinktime

It's only high school if you let it

Seth Godin - Thu 24th Jul 2014 19:07
"I'll show them!" Creative people need fuel. Overcoming the resistance and quieting the lizard brain takes a lot of work. Often, we seek external forces to excite us, inspire us or push us to take the leap necessary to do...         Seth Godin
Categories: thinktime

Matt Palmer: First Step with Clojure: Terror

Planet Linux Australia - Thu 24th Jul 2014 10:07
$ sudo apt-get install -y leiningen [...] $ lein new scratch [...] $ cd scratch $ lein repl Downloading: org/clojure/clojure/1.3.0/clojure-1.3.0.pom from repository central at http://repo1.maven.org/maven2 Transferring 5K from central Downloading: org/sonatype/oss/oss-parent/5/oss-parent-5.pom from repository central at http://repo1.maven.org/maven2 Transferring 4K from central Downloading: org/clojure/clojure/1.3.0/clojure-1.3.0.jar from repository central at http://repo1.maven.org/maven2 Transferring 3311K from central [...]

Wait… what? lein downloads some random JARs from a website over HTTP1, with, as far as far I can tell, no verification that what I’m asking for is what I’m getting (has nobody ever heard of Man-in-the-Middle attacks in Maven land?). It downloads a .sha1 file to (presumably) do integrity checking, but that’s no safety net – if I can serve you a dodgy .jar, I can serve you an equally-dodgy .sha1 file, too (also, SHA256 is where all the cool kids are at these days). Finally, jarsigner tells me that there’s no signature on the .jar itself, either.

It gets better, though. The repo1.maven.org site is served by the fastly.net2 pseudo-CDN3, which adds another set of points in the chain which can be subverted to hijack and spoof traffic. More routers, more DNS zones, and more servers.

I’ve seen Debian take a kicking more than once because packages aren’t individually signed, or because packages aren’t served over HTTPS. But at least Debian’s packages can be verified by chaining to a signature made by a well-known, widely-distributed key, signed by two Debian Developers with very well-connected keys.

This repository, on the other hand… oy gevalt. There are OpenPGP (GPG) signatures available for each package (tack .asc onto the end of the .jar URL), but no attempt was made to download the signatures for the .jar I downloaded. Even if the signature was downloaded and checked, there’s no way for me (or anyone) to trust the signature – the signature was made by a key that’s signed by one other key, which itself has no signatures. If I were an attacker, it wouldn’t be hard for me to replace that key chain with one of my own devising.

Even ignoring everyone living behind a government- or company-run intercepting proxy, and everyone using public wifi, it’s pretty well common knowledge by now (thanks to Edward Snowden) that playing silly-buggers with Internet traffic isn’t hard to do, and there’s no shortage of evidence that it is, in fact, done on a routine basis by all manner of people. Serving up executable code to a large number of people, in that threat environment, with no way for them to have any reasonable assurance that code is trustworthy, is very disappointing.

Please, for the good of the Internet, improve your act, Maven. Putting HTTPS on your distribution would be a bare minimum. There are attacks on SSL, sure, but they’re a lot harder to pull off than sitting on public wifi hijacking TCP connections. Far better would be to start mandating signatures, requiring signature checks to pass, and having all signatures chain to a well-known, widely-trusted, and properly secured trust root. Signing all keys that are allowed to upload to maven.org with a “maven.org distribution root” key (itself kept in hardware and only used offline), and then verifying that all signatures chain to that key, wouldn’t be insanely difficult, and would greatly improve the security of the software supply chain. Sure, it wouldn’t be perfect, but don’t make the perfect the enemy of the good. Cost-effective improvements are possible here.

Yes, security is hard. But you don’t get to ignore it just because of that, when you’re creating an attractive nuisance for anyone who wants to own up a whole passel of machines by slipping some dodgy code into a widely-used package.

  1. To add insult to injury, it appears to ignore my http_proxy environment variable, and the repo1.maven.org server returns plain-text error responses with Content-Type: text/xml. But at this point, that’s just icing on the shit cake.

  2. At one point in the past, my then-employer (a hosting provider) blocked Fastly’s caching servers from their network because they took down a customer site with a massive number of requests to a single resource, and the incoming request traffic was indistinguishable from a botnet-sourced DDoS attack. The requests were coming from IP space registered to a number of different ISPs, with no distinguishing rDNS (184-106-82-243.static.cloud-ips.com doesn’t help me to distinguish between “I’m a professionally-run distributed proxy” and “I’m a pwned box here to hammer your site into the ground”).

  3. Pretty much all of the new breed of so-called CDNs aren’t actually pro-actively distributing content, they’re just proxies. That isn’t a bad thing, per se, but I rather dislike the far-too-common practice of installing varnish (and perhaps mod_pagespeed, if they’re providing “advanced” capabilities) on a couple of AWS instances, and hanging out your shingle as a CDN. I prefer a bit of truth in my advertising.

Categories: thinktime

Andrew Pollock: [tech] Going solar

Planet Linux Australia - Wed 23rd Jul 2014 23:07

With electricity prices in Australia seeming to be only going up, and solar being surprisingly cheap, I decided it was a no-brainer to invest in a solar installation to reduce my ongoing electricity bills. It also paves the way for getting an electric car in the future. I'm also a greenie, so having some renewable energy happening gives me the warm and fuzzies.

So today I got solar installed. I've gone for a 2 kWh system, consisting of 8 250 watt Seraphim panels (I'm not entirely sure which model) and an Aurora UNO-2.0-I-OUTD inverter.

It was totally a case of decision fatigue when it came to shopping around. Everyone claims the particular panels they want to sell at the best. It's pretty much impossible to make a decent assessment of their claims. In the end, I went with the Seraphim panels because they scored well on the PHOTON tests. That said, I've had other solar companies tell me the PHOTON tests aren't indicative of Australian conditions. It's hard to know who to believe. In the end, I chose Seraphim because of the PHOTON test results, and they're also apparently one of the few panels that pass the Thresher test, which tests for durability.

The harder choice was the inverter. I'm told that yield varies wildly by inverter, and narrowed it down to Aurora or SunnyBoy. Jason's got a SunnyBoy, and the appeal with it was that it supported Bluetooth for data gathering, although I don't much care for the aesthetics of it. Then I learned that there was a WiFi card coming out soon for the Aurora inverter, and that struck me as better than Bluetooth, so I went with the Aurora inverter. I discovered at the eleventh hour that the model of Aurora inverter that was going to be supplied wasn't supported by the WiFi card, but was able to switch models to the one that was. I'm glad I did, because the newer model looks really nice on the wall.

The whole system was up at running just in time to catch the setting sun, so I'm looking forward to seeing it in action tomorrow.

Apparently the next step is Energex has to come out to replace my analog power meter with a digital one.

I'm grateful that I was able to get Body Corporate approval to use some of the roof. Being on the top floor helped make the installation more feasible too, I think.

Categories: thinktime

Ten CSS One-Liners to Replace Native Apps

a list apart - Wed 23rd Jul 2014 22:07

Håkon Wium Lie is the father of CSS, the CTO of Opera, and a pioneer advocate for web standards. Earlier this year, we published his blog post, “CSS Regions Considered Harmful.” When Håkon speaks, whether we always agree or not, we listen. Today, Håkon introduces CSS Figures and argues their case.

Tablets and mobile devices require us to rethink web design. Moused scrollbars will be replaced by paged gestures, and figures will float in multi-column layouts. Can this be expressed in CSS?

Paged designs, floating figures, and multi-column layout are widely used on mobile devices today. For some examples, see Flipboard, the Our Choice ebook, or Facebook Paper. These are all native apps. If we want the web to win on these devices (we do), it’s vital that designers can build these kinds of presentations using web standards. If web standards cannot express this, authors will be justified in making native apps.

Over the past years, I’ve been editing two specifications that, when combined, provide this kind of functionality: CSS Multi-column Layout and CSS Figures. I believe they are important to make sure the web remains a compelling environment for content providers.

In this article, I will demonstrate how simple it is to write CSS code with these specs. I will do so through 10 one-liners. Real stylesheets will be slightly longer, but still compact, readable, and reusable. Here are some screenshots to give you a visual indication of what we are aiming for:

Building a page

The starting point for my code examples is an article with a title, text, and some images. In a traditional browser, the article will be shown in one column, with a scrollbar on the right. Using CSS Multi-column Layout, you can give the article two columns instead of one:

article { columns: 2 }

That’s a powerful one-liner, but we can do better; we can make the number of columns depend on the available space, so that a narrow screen will have one column, a wider screen will have two columns, etc. This is all it takes to specify that the optimal line length is 15em and for the number of columns to be calculated accordingly:

article { columns: 15em }

To me, this is where CSS code morphs into poetry: one succinct line of code scales from the narrowest phone to the widest TV, from the small print to text for the visually impaired. There is no JavaScript, media queries, or expensive authoring tool involved. There is simply one highly responsive line of code. That line is used to great effect to produce the screenshots above. And it works in current browsers (which is not yet the case for the following examples).

The screenshots above show paged presentations, as opposed to scrolled presentations. This is easily expressed with:

article { overflow: paged-x }

The above code says that the article should be laid out as pages, stacked along the x-axis (which, in English, is toward the right). Browsers that support this feature must provide an interface for navigating in these pages. For example, the user may reach the next page by making a swiping gesture or tilting the device. A visual indication of which page you are reading may also be provided, just like scrollbars provide a visual indication in scrolled environments. On a tablet or mobile phone, swiping to the next page or document will be easier than scrolling.

Images

Adding images to the article creates some challenges. Lines of text can easily be poured into several columns, but if figures are interspersed with text, the result will be uneven; because images are unbreakable, they will cause unused whitespace if they appear at a column break. To avoid this, traditional paper-based layouts place images at the top or bottom of columns, thereby allowing other text to fill the whitespace. This can naturally be expressed in CSS by adding top and bottom to the float property. For example:

img { float: bottom }

The bluish harbor images in the screenshots above have been floated to the bottom of the page with this one-liner. CSS is used to express something that HTML cannot say; it is impossible to know how much textual content will fit on a screen in advance of formatting. Therefore, an author cannot know where to insert the image in the source code in order for it to appear at the bottom of the column. Being able to float figures to the top and bottom (in addition to the already existing left and right) is a natural extension to the float property.

Spanning columns

Another trick from traditional layout is for figures to span several columns. Consider this newspaper clipping:

Used with permission from the Bristol Observer

In the newspaper article, the image on the left spans two columns and is floated to the bottom of the columns. The code to achieve this in CSS is simple:

figure { float: bottom; column-span: 2 }

HTML5’s figure element is perfect for holding both an image and the caption underneath it:

<figure> <img src=cats.jpg> <figcaption>Isabel loves the fluffy felines</figcaption> </figure>

The newspaper article also has a figure that spans three columns, and is floated to the top right corner. In a previous version of the CSS Figures specification, this was achieved by setting float: top-corner. However, after discussions with implementers, it became clear that they were able to float content to more places than just corners. Therefore, CSS Figures introduces new properties to express that content should be deferred to a later column, page, or line.

Deferring figures

To represent that the cat picture in the newspaper clipping should be placed at the top of the last column, spanning three columns, this code can be used:

figure { float: top; float-defer-column: last; column-span: 3 }

This code is slightly less intuitive (compared to the abandoned top-corner keyword), but it opens up a range of options. For example, you can float an element to the second column:

.byline { float: top; float-defer-column: 1 }

The above code defers the byline, “By Collette Jackson”, by one. That is, if the byline would naturally appear in the first column, it will instead appear in the second column (as is the case in the newspaper clipping). For this to work with HTML code, it is necessary for the byline to appear early in the article. For example, like this:

<article> <h1>New rescue center pampers Persians</h1> <p class=byline>By Collette Jackson</p> ... </article> Deferring ads

Advertisements are another type of content which is best declared early in the source code and deferred for later presentation. Here’s some sample HTML code:

<article> <aside id=ad1 src=ad1.png> <aside id=ad2 src=ad2.png> <h1>New rescue center pampers Persians</h1> </article>

And here is the corresponding CSS code, with a one-liner for each advertisement:

#ad1 { float-defer-page: 1 } #ad2 { float-defer-page: 3 }

As a result of this code, the ads would appear on page two and four. Again, this is impossible to achieve by placing ads inside the text flow, because page breaks will appear in different places on different devices.

I think both readers and advertisers will like a more page-oriented web. In paper magazines, ads rarely bother anyone. Likewise, I think ads will be less intrusive in paged, rather than scrolled, media.

Deferring pull quotes

The final example of content that can be deferred is pull quotes. A pull quote is a quote lifted from the article, and presented in larger type at some predetermined place on the page. In this example, the pull quote is shown midway down the second column:

Here’s the CSS code to express this in CSS:

.pullquote#first { float-defer-line: 50% }

Other types of content can also be positioned by deferring lines. For example, a photograph may be put above the fold of a newspaper by deferring a number of lines. This will also work on the foldable screens of the future.

Pull quotes, however, are an interesting use case that deserve some discussion. A pull quote has two functions. First, it presents to the reader an interesting line of text to gain attention. Second, the presentation of the article becomes visually more varied when the body text is broken up by the larger type. Typically, you want one pull quote on every page. On paper, where you know how many pages an article will take up, it is easy to supply the right number of pull quotes. On the web, however, content will be reformatted for all sorts of screens; some readers will see many small pages, other will see fewer larger pages. To ensure that each page has a pull quote, authors must provide a generous supply of pull quotes. Rather than showing the extraneous quotes at the end of the article (which would be a web browser’s instinct), they should be discarded; the content will anyway appear in the main article. This can be achieved with a one-liner:

.pullquote { float-policy: drop-tail }

In prose, the code reads: if the pull quote is at the tail-end of the article, it should not be displayed. The same one-liner would be used to extraneous images at the end of the article; authors will often want to have one image per page, but not more than one.

Exercises

The studious reader may want to consult the CSS Multi-column Layout and CSS Figures specifications. They have more use cases and more knobs to allow designers to describe the ideal presentation of figures on the web.

The easiest way to play with CSS Figures is to download Opera 12.16 and point it to this document, which generated the screenshots in Figure 1. Based on implementation experience, the specifications have changed and not all one-liners presented in this article will work. Also, Prince and AntennaHouse have partial support for CSS Figures—these are batch formatters that output PDF documents.

I’d love to hear from those who like the approach taken in this article, and those who don’t. Do you want this added to browsers? Let me know below, or request if from your favorite browser (Firefox, Chrome, Opera, IE). If you don’t like the features, how would you express the use cases that have been discussed?

Pages and columns have been basic building blocks in typography since the Romans started cutting scrolls into pages. This is not why browsers should support them. We should do so because they help us make better, more beautiful, user experiences on mobile devices.

Categories: thinktime

Andrew Pollock: [life] Day 175: Kindergarten, cleaning, swim class and a lot of general madness

Planet Linux Australia - Wed 23rd Jul 2014 22:07

Today was ridiculously busy.

I woke up pretty early, but ended up not getting out of bed until about 7:30am. While I was in the shower, the guy from Origin buzzed to get let in because he wanted to replace the building's hot water meters. Then I raced next door for my chiropractic adjustment.

I got back home, had breakfast, and started cleaning the house, which I mostly finished by 11am, then I biked over for my massage. While I was getting my massage, the solar installer tried calling me because they'd arrived. Fortunately they didn't have to wait too long.

I did a bit more cleaning for 45 minutes, raced out to Grill'D to grab some lunch and then over to Kindergarten to chair the PAG meeting.

After the meeting, I picked up Zoe and Megan, and we went home to see how the solar installers were going.

They were making a spectacular mess, and we didn't have a lot of time before we had to head out again for Zoe's swim class. We drove over to the pool, and discovered a few other kids from Zoe's Kindergarten were in the preceding classes. Zoe's swim school is running a 2 for 1 thing this term because of the cold weather, to try and keep kids enrolled. I figured twice as many swim classes could only help, so jumped at the chance.

Megan was happy to play around while we waited for Zoe to have her class, and then we went home again. The solar installers were just finishing up.

No sooner had they walked out the door and the woman I'd organised to do indoor air quality testing arrived. I'm wanting to rule out living on a busy road having any contribution to Zoe's suspected asthma.

I was making a new Thermomix recipe for dinner, and Laura was coming over for dinner after she picked up Megan's little sister from day care. Dinner turned out really well, but with all of the preceding madness, I didn't get it started until a bit later than I had hoped, and so it was on the table later than I'd have liked.

Once Laura left with her kids, I chucked Zoe in the shower and got her down to bed only about 20 minutes later than normal. She slept through the night last night for Sarah, so I'm hoping she'll sleep through the night again tonight.

Categories: thinktime

Same as it ever was

Seth Godin - Wed 23rd Jul 2014 19:07
Here are two of the first photographic portraits ever taken, far more than a hundred years ago: They could have been taken with Instagram, no? I'm all in favor of self-driving cars and advanced robotics that will change everything. But...         Seth Godin
Categories: thinktime

Matt Palmer: Per-repo update hooks with gitolite

Planet Linux Australia - Wed 23rd Jul 2014 15:07

Gitolite is a popular way to manage collections of git repositories entirely from the command line – it’s configured using configuration stored in a git repo, which is nicely self-referential. Providing per-branch access control and a wide range of addons, it’s quite a valuable system.

In recent versions (3.6), it added support for configuring per-repository git hooks from within the gitolite-admin repo itself – something which previously required directly jiggering around with the repo metadata on the filesystem. It allows you to “chain” multiple hooks together, too, which is a nice touch. You can, for example, define hooks for “validate style guidelines”, “submit patch to code review” and “push to the CI server”. Then for each repo you can pick which of those hooks to execute. It’s neat.

There’s one glaring problem, though – you can only use these chained, per-repo hooks on the pre-receive, post-receive, and post-update hooks. The update hook is special, and gitolite wants to make sure you never, ever forget it. You can hook into the update processing chain by using something called a “virtual ref”; they’re stored in a separate configuration directory, use a different syntax in the config file, and if you’re trying to learn what they do, you’ll spend a fair bit of time on them. The documentation describes VREFs as “a mechanism to add additional constraints to a push”. The association between that and the update hook is one you get to make for yourself.

The interesting thing is that there’s no need for this gratuitous difference in configuration methods between the different hooks. I wrote a very small and simple patch that makes the update hook configurable in exactly the same way as the other server-side hooks, with no loss of existing functionality.

The reason I’m posting it here is that I tried to submit it to the primary gitolite developer, and was told “I’m not touching the update hook […] I’m not discussing this […] take it or leave it”. So instead, I’m publicising this patch for anyone who wants to locally patch their gitolite installation to have a consistent per-repo hook UI. Share and enjoy!

Categories: thinktime

Where's your bumper?

Seth Godin - Tue 22nd Jul 2014 19:07
If you spend just a few minutes listening to a great radio station, you'll know it's them. They've worked hard to make sure that the promos they run sound unique and welcome and friendly. You're home. People in radio call...         Seth Godin
Categories: thinktime

Russell Coker: Public Lectures About FOSS

Planet Linux Australia - Tue 22nd Jul 2014 18:07
Eventbrite

I’ve recently started using the Eventbrite Web site [1] and the associated Eventbrite Android app [2] to discover public events in my area. Both the web site and the Android app lack features for searching (I’d like to save alerts for my accounts and have my phone notify me when new events are added to their database) but it is basically functional. The main issue is content, Eventbrite has a lot of good events in their database (I’ve got tickets for 6 free events in the next month). I assume that Eventbrite also has many people attending their events, otherwise the events wouldn’t be promoted there.

At this time I haven’t compared Eventbrite to any similar services, Eventbrite events have taken up much of my available time for the next 6 weeks (I appreciate the button on the app to add an entry to my calendar) so I don’t have much incentive to find other web sites that list events. I would appreciate comments from users of competing event registration systems and may write a post in future comparing different systems. Also I have only checked for events in Melbourne, Australia as I don’t have any personal interest in events in other places. For the topic of this post Eventbrite is good enough, it meets all requirements for Melbourne and I’m sure that if it isn’t useful in other cities then there are competing services.

I think that we need to have free FOSS events announced through Eventbrite. We regularly have experts in various fields related to FOSS visiting Melbourne who give a talk for the Linux Users of Victoria (and sometimes other technical groups). This is a good thing but I think we could do better. Most people in Melbourne probably won’t attend a LUG meeting and if they did they probably wouldn’t find it a welcoming experience.

Also I recommend that anyone who is looking for educational things to do in Melbourne visit the Eventbrite web site and/or install the Android app.

Accessible Events

I recently attended an Eventbrite event where a professor described the work of his research team, it was a really good talk that made the topic of his research accessible to random members of the public like me. Then when it came to question time the questions were mostly opinion pieces disguised as questions which used a lot of industry specific jargon and probably lost the interest of most people in the audience who wasn’t from the university department that hosted the lecture. I spent the last 15 minutes in that lecture hall reading Wikipedia and resisted the temptation to load an Android game.

Based on this lecture (and many other lectures I’ve seen) I get the impression that when the speaker or the MC addresses a member of the audience by name (EG “John Smith has a question”) then it’s strongly correlated with a low quality question. See my previous post about the Length of Conference Questions for more on this topic [3].

It seems to me that when running a lecture everyone involved has to agree about whether it’s a public lecture (IE one that is for any random people) as opposed to a society meeting (which while free for anyone to attend in the case of a LUG is for people with specific background knowledge). For a society meeting (for want of a better term) it’s OK to assume a minimum level of knowledge that rules out some people. If 5% of the audience of a LUG don’t understand a lecture that doesn’t necessarily mean it’s a bad lecture, sometimes it’s not possible to give a lecture that is easily understood by those with the least knowledge that also teaches the most experienced members of the audience.

For a public lecture the speaker has to give a talk for people with little background knowledge. Then the speaker and/or the MC have to discourage or reject questions that are for a higher level of knowledge.

As an example of how this might work consider the case of an introductory lecture about how an OS kernel works. When one of the experienced Linux kernel programmers visits Melbourne we could have an Eventbrite event organised for a lecture introducing the basic concepts of an OS kernel (with Linux as an example). At such a lecture any questions about more technical topics (such as specific issues related to compilers, drivers, etc) could be met with “we are having a meeting for more technical people at the Linux Users of Victoria meeting tomorrow night” or “we are having coffee at a nearby cafe afterwards and you can ask technical questions there”.

Planning Eventbrite Events

When experts in various areas of FOSS visit Melbourne they often offer a talk for LUV. For any such experts who read this post please note that most lectures at LUV meetings are by locals who can reschedule, so if you are only in town for a short time we can give you an opportunity to speak at short notice.

I would like to arrange to have some of those people give a talk aimed at a less experienced audience which we can promote through Eventbrite. The venue for LUV talks (Melbourne University 7PM on the first Tuesday of the month) might not work for all speakers so we need to find a sponsor for another venue.

I will contact Linux companies that are active in Melbourne and ask whether they would be prepared to sponsor the venue for such a talk. The fallback option would be to have such a lecture at a LUV meeting.

I will talk to some of the organisers of science and technology events advertised on Eventbrite and ask why they chose the times that they did. Maybe they have some insight into which times are best for getting an audience. Also I will probably get some idea of the best times by just attending many events and observing the attendance. I think that the aim of an Eventbrite event is to attract delegates who wouldn’t attend other meetings, so it is a priority to choose a suitable time and place.

Finally please note that while I am a member of the LUV committee I’m not representing LUV in this post. My aim is that community feedback on this post will help me plan such events. I will discuss this with the LUV committee after I get some comments here.

Please comment if you would like to give such a public lecture, attend such a lecture, or if you just have any general ideas.

Related posts:

  1. Sex and Lectures about Computers I previously wrote about the appropriate references to porn in...
  2. Phone Based Lectures Early this month at a LUV meeting I gave a...
  3. Car vs Public Transport to Save Money I’ve just been considering when it’s best to drive and...
Categories: thinktime

Andrew Pollock: [debian] Day 174: Kindergarten, startup stuff, tennis

Planet Linux Australia - Tue 22nd Jul 2014 18:07

I picked up Zoe from Sarah this morning and dropped her at Kindergarten. Traffic seemed particularly bad this morning, or I'm just out of practice.

I spent the day powering through the last two parts of the registration block of my real estate licence training. I've got one more piece of assessment to do, and then it should be done. The rest is all dead-tree written stuff that I have to mail off to get marked.

Zoe's doing tennis this term as her extra-curricular activity, and it's on a Tuesday afternoon after Kindergarten at the tennis court next door.

I'm not sure what proportion of the class is continuing on from previous terms, and so how far behind the eight ball Zoe will be, but she seemed to do okay today, and she seemed to enjoy it. Megan's in the class too, and that didn't seem to result in too much cross-distraction.

After that, we came home and just pottered around for a bit and then Zoe watched some TV until Sarah came to pick her up.

Categories: thinktime

Pages

Subscribe to KatteKrab aggregator