-
Notifications
You must be signed in to change notification settings - Fork 427
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature request: Frozen columns #26
Comments
It's always a challenge keeping things updated across multiple forks. That said, I'm cautious about 'officially' supporting the frozen column forks because that feature does seem to modify some of the core render code. There seem to be a few options for frozen column implementations out there. It would be good to identify one (if that's even possible!) that's stable and has a good range of features. I've called out in my Wiki for anyone to submit knowledge and experience of the different forks out there. Feel free to submit what you know. |
So will frozen columns be implemented in the 6pac fork? I'm also using the JLynch7 fork for the frozen columns feature. Thank you |
I think officially, no. However, I'd be happy to be a part of taking a look at the fork to see how the differences between the two forks could be minimized. This would maximize the portability of future updates to my repo. |
+1 |
I am also switching to the JLynch7 branch beacuse I need fixedColumns. It would be great to implemet that feature in this repo which is up to date. |
been on the 'to do' list for a while. i'm just too busy. |
No kidding. I tried it once and the frozen code from that branch is interwoven quite nicely. Perhaps a new implementation is in order? Thanks for the replies, Ben. |
In some ways I'm thinking rather than try to integrate JLynch7's changes to my repo, it might be a lot easier to just fork JLynch7's repo and apply my changes to it. |
No intel on that 6pac, but I have been using that fork for frozen column which is very critical feature for me. I worry that in future might have to switch to some other alternative as it is behind in jquery upgrade also. |
The sad fact is that SlickGrid needs months of work put into it to integrate a lot of the branched code, including the post-jQuery branch, etc. I will never have time to do that. The only hope is if it is adopted by a project that is generating cash and considers it critical enough to put some effort into. I have a project that might fill that role, but too early to tell. I keep getting distracted by having to make a living! |
@6pac its very sad =( ; Frozen columns is very necessary feature; |
OK, so I was on a long plane flight, and downloaded the JLynch repo before I left. I have found that the changes are not really that extensive, although they do complicate the rendering code a lot. Also, the Jlynch branch has not been maintained for about 4 years. Using WinMerge (an awesome tool) I have been able to reformat the my current and the JLynch slick.grid.js to highlight the differences. It's probably only a day's work to go through and copy the relevant bits over. Is anyone interested in helping with this task? It's also worth a conversation about exactly what frozen columns means. |
The JLynch design as I understood it was to create two separate, scrollable viewports, where the viewport on the left represented the n number of columns to lock. We could just port over the code from JLynch, but what if there were a better way to do it now? It could warrant some investigation, especially since much of the code is in conflict with the current @6pac master. As for what's expected from it, I see it working like this animation. The identifier or row selection mechanism is in the first column typically, unless someone has a different use case, so optionally locking the first column would be sufficient, I think. Thoughts? |
I would say that the locking of first column is a good start, but in some cases I also like to use the last column frozen as well (for example I would put the edit icon in 1st column but the delete icon in last column, so that they never interfere with each other). EDIT |
Well, making three viewports would be not much more difficult than two! In this case, I think the additional advantage of the much simpler HTML, leading to presumably significantly less work for javascript and the browser, makes this approach compelling. |
Had a look for recent HTML/CSS solutions to this problem, drew a blank :-( |
If I look at the UI-Grid, it looks like concept wise it's actually 3 viewports (left, center, right) which are set with an overflow horizontal (no vertical). These 3 viewports are inside a bigger container which has an overflow vertical so that it controls the 3 viewports while scrolling up/down. You can pin 1 or more column inside each viewport (with this They also seem to calculate margin left and right to center the middle viewport. I guess we could do it too since we know the width of each columns. Consider that your full container has 1000px wide, and you pinned 2 on the left and none on the right and that your columns are 100px wide, that you mean that the middle viewport has a That is just what I seem to understand from the UI-Grid html code, is that even doable with SlickGrid, I seriously don't know but it's a start. |
Hi, I am not a coding expert, but from what I learned about slickgrid, my 5cents of input would be to not compromise the performance of this branch by solving the problem in html/css vs. the underlying canvas technology. We're planning on using slickgrid primarily because of it's awesome performance and memory footprint. Let's not compromise that just to get a feature implemented quick&dirty so to speak... and again, not implying anybody is trying to do that, only 'product development' feedback. Somebody was asking for some help in coding... I possibly have someone who could help out a bit. Clearly, the person needs some intro and guidance, but is familiar with Canvas and js and others. |
Yep, thanks, @kjn2. The pinned column functionality is ready to be integrated, and in this case I don't think there even is a 'quick and dirty' option. We just don't have anyone at present who has the 10 hours or so required to transfer the feature from the (quite outdated) @jlynch repository to this one. I don't think it would be too hard, with the right tools, but it's just a time issue. |
A friend of mine in India has lots of Canvas experience... not sure if that's required. If you think that skill would help you, let me know...I could 'fund' a few hours of his work.
Yep, thanks, @kjn2. The pinned column functionality is ready to be integrated, and in this case I don't think there even is a 'quick and dirty' option. We just don't have anyone at present who has the 10 hours or so required to transfer the feature from the (quite outdated) @jlynch repository to this one. I don't think it would be too hard, with the right tools, but it's just a time issue.—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.
|
@6pac Any updates? Would love to have the pinned column feature, even if it is only for one leftmost column. There was some discussion earlier about how the pinned column should interact in the presence of row grouping. Have you seen airtable.com? It basically combines the row grouping portion with the pinned column viewport. You can also make ag-grid behave somewhat similarly. For example, try the following with their demo: https://www.ag-grid.com/example.php |
I am also very intrested in this frozen columns feature. I am in a project where we need to render huge tables with the functionality of fixed columns (~ 1000 lines and ~1000 columns ). SlickGrid is one of the only frameworks we could use, that have the performance to render that many data without lagging and still have a lot a features for a nice display of data. So I can invest some time in the project. Sadly I am not a very experienced javascript developer regarding rendering, canvas and such and have no overview of the internals of slick grid. Do you think I can help you anyway ? By the way, JLynchs implementation still has a bug: |
@steve192 I forked JLynchs - 2.0-frozenRowsAndColumns branch and did some bug fixes and it works perfectly. Wasn't that hard. Let me know if I can help anyway |
@steve192 @chhunchha I think you are referring to JLynch7/SlickGrid#56 |
OK, so the kind of changes I'm thinking of are:
I would leave the original object and name the extras accordingly, eg.
This has the following advantages:
There have been some good offers, particularly from @kjn2. As I have said, I personally don't need this feature and can't justify the time to do it right now. Especially given that it will probably lead to further complications, as illustrated by @atifsyedali |
Alright everyone, I decided to take the 10 hours needed and I use a tool to compare (ExamDiff), it was painful and there's a LOT of code change. There will be also a lot to review and possibly some changes here and there... However I'm happy to say that... it works!!! The source I used X-Slickgrid Why instructions / notes
Final Note
You're welcome ;) |
I have tested all examples and most behaved as they did with the examples before. The "normal" example-excel-compatible-spreadsheet works as before. HTH |
I also found the issues with example-frozen-columns-and-rows-spreadsheet: HTH |
@ingodjango |
@ghiscoding: okay will do.
|
@ingodjango I tried as much as I understand to merge the 2 |
Thanks @ghiscoding it works. I also test all the other examples again and it's works pretty fine. |
@ingodjango The final step would be to get the code in sync with all the commits that were pushed since I created the branch. The last sync seems to be May 18, so I have a few commits to be up to date but that shouldn't be too bad. I'm not sure when I'll have time to do that but it will happen before xmas for sure. Final note... it's looking good 👍 |
@ghiscoding: Thanks for the update. I'm happy that it works, with the correction. |
@ingodjango So all that to say, we are now in sync with all latest commits (I counted 35 commits in total). We need to do a final round of tests @ingodjango could you redo all the tests? Thanks EDIT Looks all good in my repos |
@ghiscoding: Yes, will do the test within the next days. |
@ghiscoding example16-row-detail.html: example-excel-compatible-spreadsheet.html example-draggable-grouping example-explicit-initialization.html example-spreadsheet.html example-frozen-rows.html BR |
@ingodjango If so, need to find the commit(s) that affected them. By trying to rollback the changes 1 by 1, there's couple of commits that I was not sure about, like this one and this other one EDIT @ingodjango if (!_grid.canCellBeSelected(end.row, end.cell)) {
return;
} it fixes the non frozen grids, but if I try a frozen grid like |
@ghiscoding That option wasn't there before. |
@ingodjango |
@ghiscoding
so if it only copies one value like you describe it, it behaves correctly or as intended. The Error (trying to copy more than one value) is not catched correctly since the |
I just fixed the copy of multiple cell with/without frozen columns. So that's done So from your list,
I'm not sure what you mean with last example, I don't see anything strange. Maybe you can install an App to do animated gif of print screen and show it. I use ShareX for to do that. EDIT I just found the problem with the explicit initialization, 1 line of CSS So there's only the last example, but I don't know what you mean. I don't see anything strange. Can you do another round of retest since I did some code change. I tested all examples (19 of them) in my repo and they are all good. I'll wait for your tests, so far it's looking good. Thanks |
@ghiscoding regarding: |
@ingodjango EDIT I had to rollback the deletion of EDIT 2 I got the draggable grouping example working. The pre-header toggling was using direct jQuery, but we should never do that, instead we need to use the grid EDIT 3 I tested ALL examples, there's only that Frozen example scrolling that is a little weird, but every other examples are all good now. ALL Resolved |
I'm very happy to announce that everything now works and is also in sync with latest commits. I tested all SlickGrid examples (62 of them) and I also tested my repos ( @6pac At some point, I thought we could possibly support both the old and new, but then I see that this PR touches most core files, that is |
I've been using this branch of SlickGrid for the past couple of years:
https://github.com/JLynch7/SlickGrid/tree/2.0-frozenRowsAndColumns
But I would like to keep the underlying SlickGrid up to date with yours. The idea is that one can set the first n columns to be frozen and would remain in place while scrolling. Perhaps more of a spreadsheet feature, but useful when selecting rows.
Many thanks for keeping this current.
The text was updated successfully, but these errors were encountered: