Ver Mensaje Individual
  #2  
Antiguo 14-02-2008
keyboy keyboy is offline
Miembro
 
Registrado: oct 2004
Posts: 367
Reputación: 20
keyboy Va por buen camino
Puedes usar el evento OnCustomDrawItem del ListView:

Código Delphi [-]
procedure TForm1.ListView1CustomDrawItem(
  Sender: TCustomListView;
  Item: TListItem; State: TCustomDrawState; var DefaultDraw: Boolean);
begin
  if Item.SubItems[1] = 'mexico' then
    Sender.Canvas.Brush.Color := RGB($66,$99, $66)
  else if Item.SubItems[1] = 'españa' then
    Sender.Canvas.Brush.Color := RGB($ff,$cc, $33)
  else if Item.SubItems[1] = 'brasil' then
    Sender.Canvas.Brush.Color := RGB($00,$66, $ff);

  // Dejar que pinte el texto normalmente
  DefaultDraw := true;
end;

Bye
Responder Con Cita