Here's what I do for table cells - you could use WinPush/PopDrawState() as well. Not sure that it's the best way, but it works for me ;-) Alexander --- //draw the row with the selected fill color selectedFillColorIndex = UIColorGetTableEntryIndex(UIObjectSelectedFill); RectangleType tableRect; TblGetBounds (tableP, &tableRect); TblGetItemBounds(tableP, row, column, &itemRect); IndexedColorType prevForeColor = WinSetForeColor(selectedFillColorIndex); WinDrawRectangle(&itemRect, 0); WinSetForeColor(prevForeColor); //draw the text in white IndexedColorType prevBackColor = WinSetBackColor(selectedFillColorIndex); IndexedColorType prevTextColor; IndexedColorType whiteTextColor; RGBColorType whiteRGB; whiteRGB.r = whiteRGB.g = whiteRGB.b = 255; whiteTextColor = WinRGBToIndex(&whiteRGB); prevTextColor = WinSetTextColor(whiteTextColor); WinGlueDrawTruncChars(text, StrLen(text), bounds->topLeft.x, bounds->topLeft.y, bounds->extent.x-2); WinSetBackColor(prevBackColor); WinSetTextColor(prevTextColor); > -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]On Behalf Of Ty > Brower > Sent: Tuesday, April 04, 2000 6:06 PM > To: Palm Developer Forum > Subject: Color control inversion? > > > I'm trying to do my own control inversion, but I can't seem > to get it quite right. What is the correct combination of: > > WinSetDrawMode() // winInvert? winSwap? > WinInvertRectangle() / WinPaintRectangle() > > to get a control to invert to blue like the system does? > > -Ty Brower > iambic Software > > -- > For information on using the Palm Developer Forums, or to > unsubscribe, please see http://www.palm.com/devzone/mailinglists.html -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palm.com/devzone/mailinglists.html
