fpspreadsheet: Fix worksheetgrid not showing column titles (A, B, C, ...) any more after Lazarus r57969.

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@6451 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz
2018-06-02 16:18:16 +00:00
parent c7f9a9e7cb
commit 3edd24a215

View File

@ -279,6 +279,7 @@ type
function GetCells(ACol, ARow: Integer): String; override;
function GetCellText(ACol, ARow: Integer; ATrim: Boolean = true): String;
function GetEditText(ACol, ARow: Integer): String; override;
function GetDefaultColumnTitle(Column: Integer): string; override;
function GetDefaultHeaderColWidth: Integer;
function HasBorder(ACell: PCell; ABorder: TsCellBorder): Boolean;
procedure HeaderSizing(const IsColumn:boolean; const AIndex,ASize:Integer); override;
@ -3941,6 +3942,15 @@ begin
end;
end;
function TsCustomWorksheetGrid.GetDefaultColumnTitle(Column: Integer): string;
begin
if Assigned(FGetColHeaderText) then
FGetColHeaderText(Self, Column, Result)
else
Result := GetColString(Column - FHeaderCount);
end;
{@@ ----------------------------------------------------------------------------
Returns the width of the fixed header column 0, in pixels
-------------------------------------------------------------------------------}