Hello,
I'm using TCheckBox as EditorClass for one TeeGrid column. But it doesn't work as expected.
- User can check/uncheck this box despite the cell isn't in editing mode.
- If editing mode is activated, the checkbox is drawn beside the original checkbox.
In demo application TeeGridFeatures the behavior is the same.
TCheckBox as column EditorClass
Re: TCheckBox as column EditorClass
To make it working I did the following points (if somebody is interested):
Code: Select all
TFMXTeeGrid.TryChangeEditorData function GetEditorText if IEditor is TCheckBox then begin if TCheckBox(IEditor).IsChecked then result:='True' else result:='False'; end
- Draw a hook (not a cross) in TShapePainter.Check
- Assign TCheckBox(AEditor).OnPainting := CheckBoxPainting; and set there the position of editor checkbox to the center of cell
- (Sender.Render as TBooleanRender).Paint(AData); in OnPaint Handler
- Data handling in OnCellEditing and OnCellEdited Handler
Re: TCheckBox as column EditorClass
Thank you for the feedback.
Regards,
Marc Meumann
Regards,
Marc Meumann
Steema Support
Re: TCheckBox as column EditorClass
Is it planned to make the checkbox more convenient?
Re: TCheckBox as column EditorClass
Hello,
Do you mean; implementing the steps that you described in your penultimate post?
Regards,
Marc
Do you mean; implementing the steps that you described in your penultimate post?
Regards,
Marc
Steema Support
Re: TCheckBox as column EditorClass
The implementation is up to you. But I do not want to change the steema units every time I (or my colleague) installed a newer version.