Jump to content


Photo

unnecessary line


  • Please log in to reply
2 replies to this topic

#1 Lelik

Lelik
  • Members
  • 28 posts
  • Gender:Male

Posted 05 January 2010 - 05:20 AM

Hello! I have a list of items, separated into 2 root groups. These 2 groups separated with an empty row:

Attached File  111.jpg   37.31KB   1 downloads

I need to get rid of unnecessary tree line like this:

Attached File  222.jpg   36.08KB   0 downloads

How can I make it in custom draw? 


Кручу-верчу, ЛариÑ?у Ивановну хочу :)

#2 Boki (Berg)

Boki (Berg)

    Boki (Berg)

  • Forum Admin
  • PipPipPipPipPip
  • 8,191 posts
  • Gender:Male

Posted 06 January 2010 - 02:30 AM

Hello Lelik,

You may try with OnCustomDrawCell event: LINK

You may try to color this line into white, but I am not sure how it may look smile.gif

Best regards
boki@bergsoft.net | LinkedIn Profile
--
BergSoft Home Page: www.bergsoft.net
Users Section: users.bergsoft.net
Articles and Tutorials: help.bergsoft.net (Developers Network)
--
BergSoft Facebook page
--
Send us applications made with our components and we will submit them on: www.bergsoft.net/apps.htm. Link to this page will be also set on home page too.

#3 Lelik

Lelik
  • Members
  • 28 posts
  • Gender:Male

Posted 19 January 2010 - 05:04 PM

Hello again!
Can you please add an option to NextGrid and DBNextGrid for handling this line (to turn on or off)? It can be done in NxDisplays.pas.
CODE
procedure TTreeColumnDisplay.DrawLines;
......

    { Horizontal lines - }
    X := ClientRect.Left + (Level * 19) + 6;;
    n := X;
    if ChildCount > 0 then Inc(n, 4);
    
   if (level <> 0) then
      Polyline([Point(n, m - 1), Point(X + 9, m - 1)])
   else if (SomeNewOption = true) then  //we already know that this is the root so we add only second rule
      Polyline([Point(n, m - 1), Point(X + 9, m - 1)]);


SomeNewOption parameter can be "ShowParentLines" for ex




so it appeares like this

Attached File  Untitled_1.jpg   47.21KB   5 downloads
Кручу-верчу, ЛариÑ?у Ивановну хочу :)




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users