MUI DataGrid renderCell for all columns - material-ui

I want to add a tooltip for each cell in my MUI DataGrid (for all DataGrids).
For this, I will create a new component that inherits from MUI DataGrid, but I want to apply renderCell for every column directly (instead of having to rewrite the renderCell param in each column definition).
Is this possible? Thank you.

Related

Adding border to ag-grid column groupings/ pivot

Is it possible to add a border to the pivot groupings (or possibly just column groupings) on ag-grid? My groups are quite wide and I'm using material theme which makes it hard to read the grid clearly.
There doesn't seem to be any api exposed or css class to use?
e.g. sum (gold) or whatever column is on the left of the group would have border-left css to demark from the previous group.
https://www.ag-grid.com/javascript-grid-pivoting/#example-simple-pivot
Try to add cellClass and headerClass.
Add CSS to this class and also to ag-header-group-cell-with-group.
Plunkr:
https://next.plnkr.co/edit/ZQ1rv0cwau99oarH

Not able add combobox as edittor for a combobox cell GXT 3.1.2

I want to add a combobox in my grid, which would populate its store(of grid) as user provide the word.
If i am adding a custom abstract cell in to grid, I can able to add combobox as edittor to it. But when i am trying to use combobox cell (need to display text in a input tag/ Editable), Combobox is not adding to Grid.
Mean to say when I click on that column, it's not converting to combobox.
Tried with adding keyuphandler to addHandler method. But It's not coming to that handler.

How to add an entry to Datagrid in GWT

I know the way that initialize datagrid with data.
But I want to be able to add entry at runtime with add button and a form.
You have to create a List of the objects which your DataGrid should contain. Also you can append an object to the list, if you want to add a new entry.The objects should be of the same type as your DataGrid,you are defining it when you create or extend the Datagrid (between the < > ) . Then call the .setRowData(list) and the datagrid will be filled up. If you want to add a new list, clear the datagrid before and call .setRowCount(0).

Setting column style in FlexTable

I'm new to GWT and trying to understand it, but have encountered with a problem. When I try to add column style to the specified column in the table
table.getColumnFormatter().addStyleName(column, "columnStyle");
it doesn't take effect, but when I apply this style to each cell in the column
table.getCellFormatter().addStyleName(row, column, "columnStyle");
it works fine. Why I can not apply the style to the whole column?
It's possible that you're adding unsupported CSS elements to <col>, it only accepts backgrounds, width and borders CSS properties, whereas a <td> can accept many more.

How do you change the mouse over highlighting?

In GWT, I am using CellTable.
When you mouse over the CellTable it highlights each row.
How do change the behavior of the highlighting from the mouse over? Specifically:
change the color of highlighting
disable/enable
make it highlight only the specific grid item at your cursor (instead of the entire row)
( The current hack I have is to create a bunch of 1 column wide CellTables and add them to a VerticalPanel layout... creating the illusion that there is one CellTable and it highlights each grid according to your cursor. Is this bad? Why? performance? )
You will notice the CellTable uses a ResourceBundle, which means all the css styles get obfuscated ... this makes it more difficult to override styles.
The CellTable constructor will actually allow you to override the default ResourceBundle. So first, you need to create your own resource bundle like this:
public interface CellTableResources extends Resources {
public CellTableResources INSTANCE =
GWT.create(CellTableResources.class);
/**
* The styles used in this widget.
*/
#Source("CellTable.css")
CellTable.Style cellTableStyle();
}
Then you need to create your own CSS file. I recommend copying the CellTable style directly into your project and use that as a starting point. You can find it here:
http://code.google.com/p/google-web-toolkit/source/browse/trunk/user/src/com/google/gwt/user/cellview/client/CellTable.css
Make sure the style is injected first, and then you just feed it into the CellTable's constructor like this:
CellTableResources.INSTANCE.cellTableStyle().ensureInjected();
myCellTable = new CellTable<T>(Integer.MAX_VALUE,CellTableResources.INSTANCE);
Specifically, you'll want to tweak these styles:
cellTableKeyboardSelectedRow
cellTableKeyboardSelectedRowCell
cellTableSelectedRow
cellTableSelectedRowCell
cellTableKeyboardSelectedCell
It is important to note that the cell table differentiates between the 'selected row' and the 'keyboard selected row'. The selected row is the actual row selected (ie via SelectionModel). The keyboard selected row refers to what is highlighted when the user is pressing the up / down key, but does not mean the row is actually selected (if that makes sense).
I'll just add for number 2) on your list, you can simply do
cellList.setSkipRowHoverStyleUpdate(true)
That completely disables highlighting. There are also two more setSkip-functions on CellList related to hovering.
CellTable can be styled via CSS: How do I style a gwt 2.1 CellTables headers?
To disable highlighting just set the hover CSS property to nothing.
Possibly - try tweaking the .cellTableSelectedRow and .cellTableSelectedRowCell.
Here is the original CellTable.css: http://www.google.com/codesearch/p?hl=en#A1edwVHBClQ/user/src/com/google/gwt/user/cellview/client/CellTable.css&q=cellTableLastColumn&d=8