View Issue Details

IDProjectCategoryView StatusLast Update
0038203LazarusLCLpublic2020-12-12 16:53
ReporterDamir Šeligo Assigned Towp  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
PlatformWin32/Win64OSWindows 10 
Summary0038203: ValueListEditor "cuts" lower part of values when TitleFont.Size is smaller than Font.Size
DescriptionValueListEditor "cuts" lower part of values when TitleFont.Size is smaller than Font.Size
Steps To ReproducePut ValueListEditor on a form, insert a couple of strings in it.
Change TitleFont.Size to 7.
When you click with a mouse on a value, the lower part of text is missing.
TagsNo tags attached.
Fixed in Revisionr64195
LazTarget-
WidgetsetWin32/Win64
Attached Files

Activities

Damir Šeligo

2020-12-11 05:49

reporter  

valuelisteditor.png (4,189 bytes)   
valuelisteditor.png (4,189 bytes)   

wp

2020-12-11 15:54

developer   ~0127538

Last edited: 2020-12-11 15:59

View 2 revisions

Does this happen also in a TStringGrid which is the descendant of TValueListEditor?

[EDIT]
Tried it myself: Yes, TStringGrid has the same issue.

wp

2020-12-11 16:20

developer   ~0127539

Attaching a test program to see the issue with TValueListEditor and TStringGrid.

wp

2020-12-11 16:25

developer   ~0127541

Is caused because the grid title is drawn after the cells. As a consequence the grid.Canvas.Font is that of the title when a cell is prepared for editing. Added a line to reset the Canvas.Font to that of the grid before the editor size is calculated.

Please test and close if ok.

jamie philbrook

2020-12-11 17:50

reporter   ~0127542

Last edited: 2020-12-11 18:13

View 2 revisions

ValueListEditor does not seem to be working correctly between the Titefont and font for the grid.

the size of the cell for the title is the size of the grid cell when ever you change the grid.font.size but the font size for the title remains to that of the Title setting font..

basically, it's messed up the other way, too..

so what to do ?

EDIT
 Checking older versions of Laz, it appears this behavior has been there so maybe this can be addressed at some other time as to the font.size in the grid making changes to the title cell size too.

wp

2020-12-11 18:40

developer   ~0127545

Do you want the height of the title row to change along with the TitleFont.Size? This would be a feature request - the current report is about a bug. And I am not sure whether this should be implemented at all because there may be other criteria to determine the title row height conflicting with such an automatism. And it's a one-liner, after all, to adjust the title row height after an update of the TitleFont.Size.

Issue History

Date Modified Username Field Change
2020-12-11 05:49 Damir Šeligo New Issue
2020-12-11 05:49 Damir Šeligo File Added: valuelisteditor.png
2020-12-11 15:54 wp Note Added: 0127538
2020-12-11 15:56 Bart Broersma Project Lazarus CCR => Lazarus
2020-12-11 15:59 wp Note Edited: 0127538 View Revisions
2020-12-11 16:11 wp Assigned To => wp
2020-12-11 16:11 wp Status new => assigned
2020-12-11 16:20 wp Note Added: 0127539
2020-12-11 16:20 wp File Added: 38203 - valuelisteditor truncates cells.zip
2020-12-11 16:25 wp Status assigned => resolved
2020-12-11 16:25 wp Resolution open => fixed
2020-12-11 16:25 wp Fixed in Revision => r64195
2020-12-11 16:25 wp LazTarget => -
2020-12-11 16:25 wp Widgetset Win32/Win64 => Win32/Win64
2020-12-11 16:25 wp Note Added: 0127541
2020-12-11 17:50 jamie philbrook Note Added: 0127542
2020-12-11 18:13 jamie philbrook Note Edited: 0127542 View Revisions
2020-12-11 18:40 wp Note Added: 0127545
2020-12-12 16:53 Damir Šeligo Status resolved => closed