wpf - Height and actual height returning zero in converter -
i have items control , placed panel in items panel of items control. want set height of panel using converter, in converter need access height property of items control returns 0.0.
actually requirement is, need arrange objects in particular order in arrangeoverride method of panel, on basis of panels height, need know height or width panel getting, in arrangeoverride method.
<grid grid.row="0" x:name="circlegrid" grid.column="0" grid.columnspan="3"> <itemscontrol name="circlenavigatoritemscontrol" grid.row="1" itemssource="{binding relativesource={relativesource findancestor,ancestortype={x:type usercontrol}}, path=datacontext.documentsitemssource}"> <itemscontrol.itemspanel> <itemspaneltemplate> <controls:circularlayoutpanel x:name="circularpanel" > <controls:circularlayoutpanel.innerradius> <multibinding converter="{staticresource circlenavigatorwidthconverter}" converterparameter="true"> <binding path="actualheight" elementname="circlenavigatoritemscontrol" mode="twoway"/> </multibinding>
you shouldn't need , advise against it. if panel
not getting sized correctly itemscontrol
automatically, can assume logic inside panel.measureoverride
and/or panel.arrangeoverride
methods has 1 or more errors.
Comments
Post a Comment