c# - ListView with columns and bindings performance -


i have performance issue listview:

single item takes 13-30 ms create (50 items on 1 second). virtualization (recyling mode) on, scrolling 100 items uncomfortable.

at first thought it's layout problem. reason seems - bindings.

there multiple columns , each column cell has different template different bindings, example:

<gridviewcolumn>     <gridviewcolumn.celltemplate>         <datatemplate>             <grid>                 <textblock text="{binding value}"                            visibility="{binding iseditable, converter={local:truetocollapsedconverter}}" />                 <grid local:gridbehavior.columns=",auto"                       visibility="{binding iseditable, converter={local:falsetocollapsedconverter}}">                     <textbox text="{local:exceptionbinding path=value, converter={local:doubletostringconverter}}"                              local:textboxbehavior.selectallonfocus="true"                              local:listboxbehavior.selectlistboxitemonfocus="true" />                     <textblock grid.column="1" text="{local:lng key=unit.mm}" />                </grid>            </grid>        </datatemplate>    </gridviewcolumn.celltemplate> 

any single binding add 0.1 ms. there 20 columns, each cell has 1 20 bindings, leads this:

binding take majority of time, e.g. 2.83 of 3.07 ms first column on screenshot.

is there way gain performance? doing obvious mistake?


Comments

Popular posts from this blog

sequelize.js - Sequelize group by with association includes id -

delphi - Take screenshot in webcam using VFrames in Console Application -

php - Few issues in voting -