function getLayout(guesses) {
      return reduce(guesses, function(result, guess) {
        return result || RegExp('\\b' + (
          guess.pattern || qualify(guess)
        ) + '\\b', 'i').exec(ua) && (guess.label || guess);
      });
    }
Picks the layout engine from an array of guesses.

@private
@param {Array} guesses An array of guesses.
@returns {null|string} The detected layout engine.