drawCtx->DrawString(red, 50, 351, 50);
drawCtx->DrawString(red, 50, y, 200); y += TEXT_HEIGHT+2;
nsEventStatus PR_CALLBACK HandleEventControlPane(nsGUIEvent *aEvent){    printf("aEvent->message %d on 0x%X\n", aEvent->message, aEvent->widget);    nsEventStatus result = nsEventStatus_eConsumeNoDefault;    switch(aEvent->message) {        case NS_PAINT:        {            // paint the background            nsIRenderingContext *drawCtx = ((nsPaintEvent*)aEvent)->renderingContext;            drawCtx->SetColor(aEvent->widget->GetBackgroundColor());            drawCtx->FillRect(*(((nsPaintEvent*)aEvent)->rect));            // draw the line separating the two panes            drawCtx->SetColor(aEvent->widget->GetForegroundColor());            drawCtx->DrawLine(198, 0, 198, 800);            drawCtx->DrawLine(199, 0, 199, 800);            drawCtx->DrawLine(200, 0, 200, 800);            // draw the colors text            nsFont font("Times", NS_FONT_STYLE_NORMAL,                         NS_FONT_VARIANT_NORMAL,                         NS_FONT_WEIGHT_BOLD,                         0,                         12);            drawCtx->SetFont(font);            nsString red("Red");            drawCtx->SetColor(NS_RGB(255, 0, 0));            drawCtx->DrawString(red, 50, 351, 50);            nsString green("Green");            drawCtx->SetColor(NS_RGB(0, 255, 0));            drawCtx->DrawString(green, 50, 372, 50);            nsString blue("Blue");            drawCtx->SetColor(NS_RGB(0, 0, 255));            drawCtx->DrawString(blue, 50, 393, 50);            return nsEventStatus_eConsumeNoDefault;        }    }    return nsEventStatus_eIgnore;}