![]() |
![]() |
![]() |
![]() |
![]() |
FTP | ![]() |
![]() |
CCD | ![]() |
![]() |
Buscar | ![]() |
![]() |
Trucos | ![]() |
![]() |
Trabajo | ![]() |
![]() |
Foros | ![]() |
|
Registrarse | FAQ | Miembros | Calendario | Guía de estilo | Temas de Hoy |
|
Herramientas | Buscar en Tema | Desplegado |
#1
|
|||
|
|||
Problema al alinear texto en StringGrid en XE
Utilizo el siguiente codigo para alinear texto en un StringGrid:
Código:
procedure TFormComandes.PartidesGridDrawCell(Sender: TObject; ACol, ARow: Integer; Rect: TRect; State: TGridDrawState); var txt:String; i: integer; begin if ACol = 2 then //* Columna a alinear *// if ARow > 0 then //* Para no alinear la línea de los títulos *// if PartidesGrid.Cells[ ACol, ARow ] <> '' then begin txt := PartidesGrid.Cells[ ACol, ARow ]; with PartidesGrid do with Canvas,Rect do begin i := Right-TextWidth( txt + ' ' ); Canvas.FillRect( Rect ); Canvas.TextOut( i, Top + 1, txt ); end; end; end; end; alinear, parece como si ejecutara tanto el evento capturado como la rutina por defecto. Se os ocurre alguna solución a este comportamiento tan extraño? OBSERVACION: Este hecho solo ocurre si cambio el StringGrid.DrawingStyle a gdsGradient. Última edición por adrall fecha: 21-06-2011 a las 12:10:21. |
|
|
![]() |
||||
Tema | Autor | Foro | Respuestas | Último mensaje |
alinear a la derecha texto de un stringgrid | ctronx | Varios | 10 | 07-09-2007 21:54:59 |
alinear texto en el pdf | dimitri | PHP | 2 | 23-05-2007 18:28:01 |
Alinear texto de un label | Tecnic2 | OOP | 2 | 15-02-2005 16:42:39 |
Alinear Texto a derecha | jollodel | Varios | 1 | 05-08-2004 13:33:26 |
Alinear texto de Tedit | cisterpe | OOP | 2 | 11-09-2003 13:00:36 |
![]() |
|