From 2e2acca4dac4948d906158c687d3dff06878bdaa Mon Sep 17 00:00:00 2001 From: wp_xxyyzz Date: Thu, 17 May 2018 22:51:07 +0000 Subject: [PATCH] tvplanit: Draw transparent category icons in VpDayView. git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@6434 8e941d3f-bd1b-0410-a28a-d453659cc2b4 --- components/tvplanit/source/vpdayviewpainter.pas | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/components/tvplanit/source/vpdayviewpainter.pas b/components/tvplanit/source/vpdayviewpainter.pas index 7c7f66c9e..918e84a40 100644 --- a/components/tvplanit/source/vpdayviewpainter.pas +++ b/components/tvplanit/source/vpdayviewpainter.pas @@ -1570,9 +1570,6 @@ begin ShowCategory := False; ShowCustom := False; - // FDayView.IconAttributes.AlarmBitmap.SaveToFile('d:\test.bmp'); - - if Event.AlarmSet then begin dvBmpAlarm.Assign(FDayView.IconAttributes.AlarmBitmap); ShowAlarm := (dvBmpAlarm.Width <> 0) and (dvBmpAlarm.Height <> 0); @@ -1596,12 +1593,15 @@ begin if Event.Category < 10 then begin cat := FDayView.Datastore.CategoryColorMap.GetCategory(Event.Category); + dvBmpCategory.Assign(cat.Bitmap); + { w := cat.Bitmap.Width; h := cat.Bitmap.Height; dvBmpCategory.Width := w; dvBmpCategory.Height := h; R := Rect(0, 0, w, h); dvBmpCategory.Canvas.CopyRect(R, cat.Bitmap.canvas, R); + } end else begin dvBmpCategory.Width := 0;