Discussion:
[Lazarus] TStringGrid sort symbol in TitleButton
Landmesser John via Lazarus
2018-05-14 11:43:32 UTC
Permalink
In a StringGrid without(!) defined columns you never see that up and
down arrow in the TitleButton if you click to sort this column.

It's ok if you define at least one column, but i think that shouldn't be
this way.

Attached patch comments out

//FImageIndex := -1;

My first patch :-)

Lazarus 1.9.0 r57932M FPC 3.0.4 i386-win32-win32/win64
Landmesser John via Lazarus
2018-05-14 12:08:06 UTC
Permalink
forget the patch, it doesn't solve the problem!
Post by Landmesser John via Lazarus
In a StringGrid without(!) defined columns you never see that up and
down arrow in the TitleButton if you click to sort this column.
It's ok if you define at least one column, but i think that shouldn't
be this way.
Attached patch comments out
//FImageIndex := -1;
My first patch :-)
Lazarus 1.9.0 r57932M FPC 3.0.4 i386-win32-win32/win64
zeljko via Lazarus
2018-05-14 12:30:53 UTC
Permalink
Post by Landmesser John via Lazarus
In a StringGrid without(!) defined columns you never see that up and
down arrow in the TitleButton if you click to sort this column.
It's ok if you define at least one column, but i think that shouldn't be
this way.
I don't get what is exact problem. If there's no columns why Sort
indicator should be visible at all (and where) ?
In any case you can create bug report and attach example project.

zeljko
Post by Landmesser John via Lazarus
Attached patch comments out
//FImageIndex := -1;
My first patch :-)
Lazarus 1.9.0 r57932M FPC 3.0.4 i386-win32-win32/win64
--
John Landmesser via Lazarus
2018-05-14 16:37:41 UTC
Permalink
Hi Zeljko,

think of a *.csv file and StringGrid.LoadFromCSV...

No columns defined in StringGrid, they will be created "on the fly" and
user wants to sort a column by click on columnTitle.

There are default arrows that only show up if you define at least one
column and thats not ok i think!

Bug report:
https://bugs.freepascal.org/view.php?id=33731
Post by zeljko via Lazarus
Post by Landmesser John via Lazarus
In a StringGrid without(!) defined columns you never see that up and
down arrow in the TitleButton if you click to sort this column.
It's ok if you define at least one column, but i think that shouldn't
be this way.
I don't get what is exact problem. If there's no columns why Sort
indicator should be visible at all (and where) ?
In any case you can create bug report and attach example project.
zeljko
Post by Landmesser John via Lazarus
Attached patch comments out
//FImageIndex := -1;
My first patch :-)
Lazarus 1.9.0 r57932M FPC 3.0.4 i386-win32-win32/win64
--

Loading...