Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2008-06

More grid issues

3 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Michael Van Canneyt

More issues with grids.

I try to set the color of the edited cell:

Procedure TForm1.StringGrid1SelectEditor(Sender: TObject; aCol, aRow: Integer;
  var Editor: TWinControl);
begin
  Editor.Color:=clTeal;
end;

This works, but just the first time. As soon as the second cell is selected, the color stays the background color of the grid ?

What I find strange is that this event is called twice:
- Once when clicking on a sell (no editing done yet)
- Once again when clicking a second time on a cell (to start editing) This is once too much; The first one should not occur, IMHO.

I've been trying to debug it, but the grids editing code is, well, discouraging to look at :(

Any hints would be appreciated; If I can be of any help, let me know.

Michael.

Reply by email

Jesus Reyes
to Michael Van Canneyt

--- El s?b 21-jun-08, Michael Van Canneyt escribi?:

Show quoted text 19 lines
De:: Michael Van Canneyt Asunto: [Lazarus] More grid issues A: "Lazarus mailing list" Fecha: s?bado, 21 junio, 2008, 9:05 am More issues with grids. I try to set the color of the edited cell: Procedure TForm1.StringGrid1SelectEditor(Sender: TObject; aCol, aRow: Integer; var Editor: TWinControl); begin Editor.Color:=clTeal; end; This works, but just the first time. As soon as the second cell is selected, the color stays the background color of the grid ?

I can't reproduce here, maybe you want to submit a report with a sample.

Show quoted text 6 lines
What I find strange is that this event is called twice: - Once when clicking on a sell (no editing done yet) - Once again when clicking a second time on a cell (to start editing) This is once too much; The first one should not occur, IMHO.

This is a event to gather something at addressed, it might occur several times, the same as OnSelectCell event. I don't know what are you trying to do, can't advice better.

Show quoted text 9 lines
I've been trying to debug it, but the grids editing code is, well, discouraging to look at :( Any hints would be appreciated; If I can be of any help, let me know. Michael.

Jesus Reyes A.

____________________________________________________________________________________ Yahoo! Deportes Beta
?No te pierdas lo ?ltimo sobre el torneo clausura 2008! Ent?rate aqu? http://deportes.yahoo.com

Reply by email

Michael Van Canneyt
to Jesus Reyes

Submitted a bug report. 11529, assigned to you.

There is a sample program and 2 screenshots which show what happens. No idea why it happens.

Michael.

Jesus Reyes wrote 58 lines
--- El s?b 21-jun-08, Michael Van Canneyt escribi?: > De:: Michael Van Canneyt > Asunto: [Lazarus] More grid issues > A: "Lazarus mailing list" > Fecha: s?bado, 21 junio, 2008, 9:05 am > More issues with grids. > > I try to set the color of the edited cell: > > Procedure TForm1.StringGrid1SelectEditor(Sender: TObject; > aCol, aRow: Integer; > var Editor: TWinControl); > begin > Editor.Color:=clTeal; > end; > > This works, but just the first time. As soon as the second > cell is selected, > the color stays the background color of the grid ? > I can't reproduce here, maybe you want to submit a report with a sample. > What I find strange is that this event is called twice: > - Once when clicking on a sell (no editing done yet) > - Once again when clicking a second time on a cell (to > start editing) > This is once too much; The first one should not occur, > IMHO. This is a event to gather something at addressed, it might occur several times, the same as OnSelectCell event. I don't know what are you trying to do, can't advice better. > > I've been trying to debug it, but the grids editing > code is, well, > discouraging to look at :( > > Any hints would be appreciated; If I can be of any help, > let me know. > > Michael. Jesus Reyes A. ____________________________________________________________________________________ Yahoo! Deportes Beta ?No te pierdas lo ?ltimo sobre el torneo clausura 2008! Ent?rate aqu? http://deportes.yahoo.com _______________________________________________ Lazarus mailing list http://www.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply by email