how do i remove white background in node inside virtual TVirtualStringTree?
i tried to use TargetCanvas.Brush.Style := bsClear; inside BeforeCellPaint still node have white back ground here is the full code
Delphi-Quellcode:
procedure TForm2.VTs1BeforeCellPaint(Sender: TBaseVirtualTree;
TargetCanvas: TCanvas; Node: PVirtualNode; Column: TColumnIndex; CellPaintMode: TVTCellPaintMode; CellRect: TRect; var ContentRect: TRect); begin TargetCanvas.Brush.Style := bsClear; TargetCanvas.FillRect(CellRect); end; |
AW: how do i remove white background in node inside virtual TVirtualStringTree?
What exactly are you trying to do?
You can set a custom color for each row like this:
Delphi-Quellcode:
If you like to use colored rows while using a background image, try this:
procedure TfrmMain.EditorTreeBeforeItemErase(Sender: TBaseVirtualTree; TargetCanvas: TCanvas;
Node: PVirtualNode; ItemRect: TRect; var ItemColor: TColor; var EraseAction: TItemEraseAction); begin EraseAction := eaColor; ItemColor := clBlue; end; http://stackoverflow.com/a/10537589 |
AW: how do i remove white background in node inside virtual TVirtualStringTree?
Zitat:
|
AW: how do i remove white background in node inside virtual TVirtualStringTree?
So you want to make the cell transparent? I don't think that's possible at all :/ There might be a hacky way by manually drawing the contents of the parent canvas before printing the text, but I never saw something like that in action.
|
AW: how do i remove white background in node inside virtual TVirtualStringTree?
Zitat:
|
AW: how do i remove white background in node inside virtual TVirtualStringTree?
Zitat:
|
AW: how do i remove white background in node inside virtual TVirtualStringTree?
Liste der Anhänge anzeigen (Anzahl: 1)
Zitat:
Delphi-Quellcode:
the white bg of node is the issue see my example
procedure TForm2.VTs1PaintBackground(Sender: TBaseVirtualTree;
TargetCanvas: TCanvas; R: TRect; var Handled: Boolean); begin // GradientFillCanvas(TargetCanvas, clred, clWhite, R, gdHorizontal); // GraphUtil Handled := True; end; |
AW: how do i remove white background in node inside virtual TVirtualStringTree?
Zitat:
|
AW: how do i remove white background in node inside virtual TVirtualStringTree?
Zitat:
|
Alle Zeitangaben in WEZ +1. Es ist jetzt 18:23 Uhr. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz