-Sir Richard Branson
Geeks and Delegation: A Match Made in Hell
(via thenextweb)
(via thenextweb)
East Asian characters, font colors, and Windows
I ran across an interesting display issue on a project today. I had a page with a mix of Latin and non-Latin (East Asian) characters on it. The majority of the body copy was in Korean with some English words and phrases interspersed (mostly trade names and the like). The text color, defined in the style sheet, was set to a dark gray color (#323232). On a Mac, the page displayed just fine. However, on Windows machines, there was a color shift between the Latin (displaying in #323232) and non-Latin characters (displaying in black).
My page was tagged with the correct ISO 639-1 language code. The body copy was set to render in Arial.
I scoured the Internet in hopes of finding other poor souls who had faced this particular bug before. Upon more experimentation, I found that most hexadecimal colors worked just fine. It was only when the desired text color was darker than #555555 that the non-Latin characters shifted to black. Craziness!
This display issue seems to stem from the bitmap files within the standard Windows version of Arial. Once I updated the CSS to use “Arial Unicode MS” for the non-Latin sections of the page, my color woes were resolved. As a bonus, the character renderings look a bit better/cleaner, too.
UI Matters…so does communication. Opening skit from Hive 2011 shows the challenges of designers and developers discussing project changes.
Printing: Acrobat vs Preview
I recently purchased a Brother black-and-white laser printer for my home office. I had wanted one for quite a while since they have great shelf life, offer quick print times, and output sharp lines and text. I also wanted to get one with duplexing capability to cut down on paper consumption and desk clutter.
So why is two-sided printing of a PDF from Acrobat Pro so difficult? Seriously. I really don’t understand why the folks at Adobe thought that two-sided output belongs in the Settings section of each document.
The expected behavior is exhibited by Apple’s own Preview app:

See the nice little checkbox with the straight-forward “Two-Sided” label? Easy. And it fits logically next to the option for collating the output.
Imagine my surprise and frustration when trying to print the same document, on the same computer, to the same printer, using Acrobat Pro:

Nothing. Nada. Spelunking around in Page Setup, Printer, and Advanced proved fruitless. After expanding my search to various menus, I stumbled upon Properties (File > Properties). At long last, I had discovered the requisite print option:

And, since this is a property of the file itself, you have to save the file in order to save this “Print Dialog Preset.” Not a fan. Presets should specify the default values for things that can also be tweaked or overridden on-the-fly. I see no way to set, adjust, or override the duplexing settings in the actual Print Dialog. Maybe I should do all of my PDF printing from Preview from here on…
First time for everything
So I’ve used a couple different Subversion clients before. Today I figured out (with help from some buddies) how to use Tortoise SVN to check out a fresh working copy of a project. The biggest challenge had nothing to do with source control…it had to do with the strange implementation of user permissions on Windows 7. If I’m signed in to my box using my administrator account name/password, why am I not considered an administrator? When you display a cautionary message saying that I need permission from myself to do something (delete a folder full of foo and bar), why don’t you allow me the opportunity to supply the necessary credentials?
Look, Windows 7 looks a lot better than previous versions. Occasionally, it shows its underwear in various dialogs, wizards, etc. But it’s these kind of “keyboard not detected, press any key to continue” pitfalls that really hinder the usability and enjoyment of interacting with the OS. After all, I am doing all of this to get work done, not to fiddle around with the file system manager all day.
The upside is that now I have a fresh working copy of my project and have the solutions file all up-and-running in Visual Studio. Joy! Now for the file update that should take me, oh, five minutes.
Enjoy your day!
Color Scheme Designer is a quick tool to work out color relationships. Not as detailed as something like Adobe’s Kuler but very fast and very easy to use.
iOS CGContext errors
I added some new UI elements to my mobile app earlier this week and noticed some odd-looking errors in the log:
CGContextConcatCTM: invalid context 0x0
CGContextSetInterpolationQuality: invalid context 0x0
CGContextDrawImage: invalid context 0x0
CGBitmapContextCreateImage: invalid context 0x0
After some digging (and a visit to the Appcelerator Q&A site), I located the offending code. Basically, I got in a hurry and was using a Label to do the job intended for a View. Solution? Wrap the Label inside of a View and add the View to the Window.
var win = Titanium.UI.currentWindow;
var myView = Titanium.UI.createView({
backgroundImage: ‘path/to/image.png’, // set bg here instead of on Label
height: 35
});var lbl = Titanium.UI.createLabel({
text: ‘My Label Name’
});myView.add(lbl);
win.add(myView);
Pushing data, not just pixels
While working on my iOS/Android mobile app, I find myself in need of quite a few TableView elements. This interface element is the basic building block for most working apps, especially web service apps like the one I’m building now.
TableViews are driving by an array of TableViewRows. The basic TableViewRow only needs one property: title.
var data = [] // blank array to hold row data
for (var i=0; i < 10; i++) // create 10 simple rows
{
var row = Titanium.UI.createTableViewRow({title: ‘This is a row’});
data[i] = row;
}var tv = Titanium.UI.createTableView({
data: data // set our data array as the source for the rows
});
For simple TableViews, this method works well. However, what if you need a few different loops to construct a complicated TV? Enter .push().
If you don’t know the current size of the data array (and don’t want to bother calculating it only to increase it by 1), you can push the next item onto the array.
Simply replace “data[i] = row” with this:
data.push(row); // add current row as next item in the array

