tvplanit: draw month header dividing lines so that they do not run through week headers. Fix showing of month/week/day column headers.

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@8501 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz
2022-09-23 20:07:48 +00:00
parent 8de2203a9b
commit 31a2f25a42
2 changed files with 23 additions and 10 deletions

View File

@ -196,6 +196,9 @@ var
R, R1: TRect;
P: TPoint;
begin
if not (gchDay in FGanttView.ColHeaderAttributes.Visible) then
exit;
// Offset due to scrolling
dx := FGanttView.LeftCol * FScaledColWidth;
@ -236,7 +239,8 @@ begin
// No dividing line at last day of month because it already has been
// drawn as the month divider.
if (DayOf(dayRec.Date) <> DaysInMonth(dayRec.Date)) then
if (DayOf(dayRec.Date) <> DaysInMonth(dayRec.Date)) or
([gchWeek, gchDay] * FGanttView.ColHeaderAttributes.Visible = [gchWeek, gchDay]) then
begin
if FGanttView.DrawingStyle = ds3D then
DrawBevelLine(
@ -405,6 +409,9 @@ var
str: String;
strLen: Integer;
begin
if not (gchMonth in FGanttView.ColHeaderAttributes.Visible) then
exit;
// Offset due to scrolling
dx := FGanttView.LeftCol * FScaledColWidth;
@ -593,6 +600,9 @@ var
str: String;
strLen: Integer;
begin
if not (gchWeek in FGanttView.ColHeaderAttributes.Visible) then
exit;
// Offset due to scrolling
dx := FGanttView.LeftCol * FScaledColWidth;
@ -624,14 +634,6 @@ begin
BevelShadow,
BevelHighlight
)
(*
DrawBevelRect(
RenderCanvas,
TPSRotateRectangle(Angle, RenderIn, R1),
BevelHighlight,
BevelShadow
)
*)
end else
begin
TPSMoveTo(RenderCanvas, Angle, RenderIn, R.Right, R.Top);