comparison dynamin/gui/theme.d @ 106:acdbb30fee7e

Port to D2. Most of the effort was dealing with immutable and const.
author Jordan Miner <jminer7@gmail.com>
date Mon, 17 Dec 2012 23:41:50 -0600
parents 5c8c1c2e12c0
children
comparison
equal deleted inserted replaced
105:97997a544ac0 106:acdbb30fee7e
62 bool oddRow; 62 bool oddRow;
63 int squareSize2 = squareSize * 2; 63 int squareSize2 = squareSize * 2;
64 for(int i = 0; i < height; ++i) { 64 for(int i = 0; i < height; ++i) {
65 oddRow = i % squareSize2 < squareSize; 65 oddRow = i % squareSize2 < squareSize;
66 for(int j = 0; j < width; ++j) { 66 for(int j = 0; j < width; ++j) {
67 if(oddRow ^ j % squareSize2 < squareSize) 67 if(oddRow ^ (j % squareSize2 < squareSize))
68 data[j+i*width] = pixel1; 68 data[j+i*width] = pixel1;
69 else 69 else
70 data[j+i*width] = pixel2; 70 data[j+i*width] = pixel2;
71 } 71 }
72 } 72 }