On Thursday, January 24, 2002, at 02:28 AM, Entwicklung wrote:
enum{ kBTBadCloseMask = 0x00000001, kBTBigKeysMask=0x00000002, kBTVariableIndexKeysMask=0x00000004 } " In my case I need to set both kBTBigkeysMask and kBTVariableIndexKeysMask. What is meant by bits 1,2 and 4? Do I set attributes = 6 (assuming 2 and 4 refer to positions 1(2^1) and 2(2^2))
Yes. The numbers above are masks, not bit numbers.
Apple typically names constants ending in "Mask" for the value you would logically OR in to produce the composite value. Constants for bit numbers often end in "Bit"; those would be used to determine how many places to shift to get to the correct bit. So, kBTVariableIndexKeysBit would be 2. (The above constants are bits 0, 1 and 2.)
-Mark