Jump to content


karl

Member Since 25 Nov 2015
Offline Last Active Dec 10 2015 10:07 PM
-----

Topics I've Started

NextVirtualGrid6 weird bugs

07 December 2015 - 01:10 PM

Hi Boki,

 

I just experienced some very weird bugs in NextVirtualGrid6:

 

This only happens if scrolling the grid using the mouse-wheel:

 

-some of the grid-lines just disappear

 

-some grid lines become thicker then others

 

-some of the grid lines become the SelectionColor of the grid

 

 

Also one time after I clicked on the vertical scrollbar it just disappeared, and then the grid didn't update anymore.

 

 

All of these bugs happen very rarely and I've not been able to reproduce them deliberately :(

Maybe you know where to start looking?

Please investigate.

 

Regards, Karl

 

PS I've started to use DoubleBuffered := true recently, maybe this has something to do with it?


A little memory leak

04 December 2015 - 02:08 AM

Hi Boki,
 
I just discovered a little Memory leak in nextinspector6.
 
If one moves the mouse over a node and there is not enough space to diplay the full NodeCaption, (so the node caption is diplayed eg with ellipsis)
 
this white box, showing the whole node-caption text appears right next to the cursor. (I don't know how its called)
 
This somehow leaks memory. (I always monitor my applications memory usage)
 
Please investigate.
 
Thanks, Karl.

NextGrid6 string processing, NextVirtualGrid6 and a few questions and bugs

30 November 2015 - 04:52 PM

Hi Boki,

 

I recently tried using your NextGrid6 component with some large datastructure containing  6 cols with a lot of very long strings

and over 3 000 Rows (the grid consists of TextColums only).

But I figured that it was quite slow compared to the standard Vcl-StringGrid.

Where populating the Vcl-StringGrid (with the exact same data) happend without any noticable delay,

when populating NextGrid6 the application froze for about 2 seconds (I used BeginUpdate; EndUpdate and AddRow(3 000)- all Rows at once, like you suggest in the documentation).

 

I'm guessing this is becouse you use WideString for all internal string processing.

Vcl-StringGrid uses the default String type which is UnicodeString (in Delphi Versions starting with Delphi 2010 I think).

Using UnicodeString is much faster then using WideString becouse it uses reference counting with copy on write.

WideString uses copy by value. (see http://docwiki.embar..._Types_(Delphi) )

 

You probably use WideString becouse of compatability to older Versions of Delphi, but it would be really

nice to have your components use UnicodeString (just string) for newer Versions ;) .

 

 

 

To circumvent this speed issue I now use NextVirtualGrid6, but I ran into some questions and bugs:

 

1) I don't know how to make the grid reload it's data, for example when i change the data of my data-structure which gets queried in the getCell-Event.

    I tried              NextVirtualGrid61.DataChanged;            but nothing happens.

 

2) There is an OnCulumnHeaderClick event, but it seems to never get called when i click on a ColumnHeader, maybe there is a bug?

 

3) If I pull the NextVirtualGrid6 and NextCellSource components on my Form their units are not automatically added to the uses list

   (not really a big deal, but I wanted to point it out to you)

 

4) I noticed that NextVirtualGrid6 has some procedures for sorting. How do they work and how do I use them?

 

5) Feature Request: It would be nice to have an AfterCellSetEvent. I would like to call bestFitCol() in that event.

 

6) Also It would be nice to have an OnColumnHeaderClick-Event with a (aCol: Integer) parameter, let me illustrate that with some code:

 

   Now if I want to assign the OnHeaderClick event with eg some custom sorting for the column I clicked,

   I would have to assign an event for every column to implement some custom behavior for clicks on different columns:

 

                                                                                                         Column1.OnHeaderClick := OnHeaderClick1;

                                                                                                         Column2.OnHeaderClick := OnHeaderClick2;                      and so on..

 

What I would like to do instead is this:

                                  

interface

   procedure FormCreate;

   procedure OnHeaderClick(aCol: integer);

 

implemementation

 

procedure OnHeaderClick(aCol: integer);

begin

  doSomeCustomStuffWithClickedColumn(aCol);

end;

 

procedure FormCreate;

begin

  Column1.OnHeaderClick := OnHeaderClick;

  Column2.OnHeaderClick := OnHeaderClick;

end;                                                               

 

 

I added a tiny sample project for better understanding of my obove points.

Attached File  VirtualGrid_Sample.zip   53.82KB   5 downloads


Autofit-Option: Resize Column Height

25 November 2015 - 07:42 PM

Hi,

I recently bought a copy of your components and now I have a few questions:

 

1.) In NxGrid6 if I enable the autofit option the column height is not adjusted on resize. However if I edit a cell, after editing it the column height is adjusted correctly.

     Is there a way to trigger the colum height resizing on resize?

 

2.) Also I would like to resize a column to fit the text the user typed into it (triggered after editing is finished). How can this be accomplished ?

 

3.) I noticed that if i resize my form, the font size of NxInspector6 stays the same. Is there a way to make it scale like NxGrid6 with auto fitting enabled ?