degerjy Posted September 2, 2020 Share Posted September 2, 2020 I haven't find any way to get in dbgird one cell underlined when hover cursor over. Is there any way to do that? Hover over is easy to handle with CSS, but that hapens for all cells (columns) in focused row and I want only particular cell is working that way. The idea is that when user hover over some cells there comes underline and handcursor when there is possible to click that cell to get something more from that. Quote Link to comment Share on other sites More sharing options...
Sherzod Posted September 2, 2020 Share Posted September 2, 2020 2 hours ago, degerjy said: I haven't find any way to get in dbgird one cell underlined when hover cursor over. Is there any way to do that? Hover over is easy to handle with CSS, but that hapens for all cells (columns) in focused row and I want only particular cell is working that way. The idea is that when user hover over some cells there comes underline and handcursor when there is possible to click that cell to get something more from that. Hello, One possible solution (demo: \FMSoft\Framework\uniGUI\Demos\Desktop\GridEditors). 1. UniServerModule.CustomCSS .x-cursor-pointer { cursor:pointer !important; } .x-cursor-pointer:hover { text-decoration: underline; } 2. UniDBGrid1.ClientEvents.ExtEvents -> function reconfigure(sender, store, columns, oldStore, oldColumns, eOpts) { //for the second column = LastName columns[1].renderer = function (value, meta, record) { meta.tdCls += 'x-cursor-pointer'; return value; }; } 3. procedure TMainForm.UniDBGrid1CellClick(Column: TUniDBGridColumn); begin if Column.FieldName = 'LastName' then ShowMessage(Column.Field.Value); end; Quote Link to comment Share on other sites More sharing options...
degerjy Posted September 6, 2020 Author Share Posted September 6, 2020 On 9/2/2020 at 9:29 PM, Sherzod said: Hello, One possible solution (demo: \FMSoft\Framework\uniGUI\Demos\Desktop\GridEditors). 1. UniServerModule.CustomCSS .x-cursor-pointer { cursor:pointer !important; } .x-cursor-pointer:hover { text-decoration: underline; } 2. UniDBGrid1.ClientEvents.ExtEvents -> function reconfigure(sender, store, columns, oldStore, oldColumns, eOpts) { //for the second column = LastName columns[1].renderer = function (value, meta, record) { meta.tdCls += 'x-cursor-pointer'; return value; }; } 3. procedure TMainForm.UniDBGrid1CellClick(Column: TUniDBGridColumn); begin if Column.FieldName = 'LastName' then ShowMessage(Column.Field.Value); end; Sorry to say, but I couldn't get that work. No underline when hoovering over and at the same time all formats of that field (color, bold...) was gone. Quote Link to comment Share on other sites More sharing options...
Sherzod Posted September 6, 2020 Share Posted September 6, 2020 1 minute ago, degerjy said: Sorry to say, but I couldn't get that work. No underline when hoovering over and at the same time all formats of that field (color, bold...) was gone. Hello, Sorry, can you please make a simple app to check? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.