Devexpress Tiles' content display issue -


i have user control:

<usercontrol.resources>     <resourcedictionary>         <resourcedictionary.mergeddictionaries>             <resourcedictionary source="/userinterface;component/skins/mainskin.xaml" />         </resourcedictionary.mergeddictionaries>         <converters:widgetwidthconverter x:key="widgetwidthconverter" />         <converters:tilesizeconverter x:key="tilesizeconverter" />         <converters:listcounttovisibilityconverter x:key="listcounttovisibilityconverter" />         <views:subplantmainstaticcontrol x:key="subplantmainstaticcontrol" />         <views:subplantmainactualcontrol x:key="subplantmainactualcontrol" />     </resourcedictionary> </usercontrol.resources>  <dxlc:tilelayoutcontrol background="{x:null}"                         x:name="tilecontrol"                         margin="10"                         padding="0"                         scrollbars="none"                         layoutupdated="ontilecontrolupdated">      <dxlc:tile style="{staticresource customizedtilestyle}"                height="{binding source={staticresource subplantmainstaticcontrol}, path=actualheight, converter={staticresource tilesizeconverter}}"                name="staticdatatile"                verticalcontentalignment="top">         <custom:widget name="staticdatawidget"                        datacontext="{binding path=staticviewmodel}"                        canresize="false">             <custom:widget.header>                 <stackpanel orientation="horizontal">                     <textblock text="{binding source={staticresource dataviewresources}, path=resource.staticdatatext}"                                style="{staticresource widgetheadertextblock}" />                 </stackpanel>             </custom:widget.header>             <stackpanel>                 <contentpresenter content="{staticresource subplantmainstaticcontrol}" />             </stackpanel>         </custom:widget>     </dxlc:tile>      <dxlc:tile style="{staticresource customizedtilestyle}"                height="{binding source={staticresource subplantmainactualcontrol}, path=actualheight, converter={staticresource tilesizeconverter}}"                name="actualdatatile"                verticalcontentalignment="top">         <custom:widget name="actualdatawidget"                        datacontext="{binding path=actualviewmodel}"                        canresize="false">             <custom:widget.header>                 <stackpanel orientation="horizontal">                     <textblock text="{binding source={staticresource dataviewresources}, path=resource.latestdatatext}"                                style="{staticresource widgetheadertextblock}" />                 </stackpanel>             </custom:widget.header>             <stackpanel>                 <contentpresenter content="{staticresource subplantmainactualcontrol}" />             </stackpanel>         </custom:widget>     </dxlc:tile> </dxlc:tilelayoutcontrol> 

where views:subplantmainactualcontrol :

<usercontrol x:class="userinterface.views.subplantmainactualcontrol"          xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"          xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"          xmlns:dx="http://schemas.devexpress.com/winfx/2008/xaml/core"          dx:thememanager.themename="seven"          xmlns:views="clr-namespace:userinterface.views">      <views:layoutlabelvaluecontrol grid.row="0"                                itemssource="{binding path=actualrepresentations}" />  </usercontrol> 

and widget :

<dxlc:groupbox x:class="customcontrols.widget"            xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"            xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"            xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"            xmlns:d="http://schemas.microsoft.com/expression/blend/2008"            xmlns:dxlc="http://schemas.devexpress.com/winfx/2008/xaml/layoutcontrol"            xmlns:dxe="http://schemas.devexpress.com/winfx/2008/xaml/editors"            xmlns:dxb="http://schemas.devexpress.com/winfx/2008/xaml/bars"            xmlns:dx="http://schemas.devexpress.com/winfx/2008/xaml/core"            xmlns:custom="clr-namespace:customcontrols"            xmlns:converters="clr-namespace:customcontrols.converters"            xmlns:constants="clr-namespace:business.constants;assembly=business"            mc:ignorable="d"            x:name="basetile"            dx:thememanager.themename="seven"            margin="0,2,0,2"            ismanipulationenabled="true"            foreground="black"            padding="1"            background="transparent"            minimizeelementvisibility="visible"            style="{dynamicresource groupboxstyle1}"            visualtexthintingmode="animated"            previewmouseleftbuttondown="onpreviewmouseleftbuttondown"> <dxlc:groupbox.resources>     <resourcedictionary>         <resourcedictionary.mergeddictionaries>             <resourcedictionary source="/customcontrols;component/themes/mainskin.xaml" />         </resourcedictionary.mergeddictionaries>          <converters:booltovisibilityconverter x:key="booltovisibilityconverter" />          <style x:key="groupboxstyle1"                targettype="{x:type dxlc:groupbox}">             <setter property="background"                     value="transparent" />             <style.basedon>                 <style targettype="{x:type dxlc:groupbox}">                     <setter property="cornerradius"                             value="3" />                     <setter property="minimizationdirection"                             value="vertical" />                     <setter property="padding"                             value="11" />                     <setter property="template">                         <setter.value>                             <controltemplate targettype="{x:type dxlc:groupbox}">                                 <dx:container x:name="container">                                     <visualstatemanager.visualstategroups>                                         <visualstategroup x:name="layoutstates">                                             <visualstate x:name="normallayout" />                                             <visualstate x:name="minimizedlayout">                                                 <storyboard>                                                     <objectanimationusingkeyframes duration="0"                                                                                    storyboard.targetproperty="visibility"                                                                                    storyboard.targetname="titlestretcher">                                                         <discreteobjectkeyframe keytime="0">                                                             <discreteobjectkeyframe.value>                                                                 <visibility>visible</visibility>                                                             </discreteobjectkeyframe.value>                                                         </discreteobjectkeyframe>                                                     </objectanimationusingkeyframes>                                                     <objectanimationusingkeyframes duration="300"                                                                                    storyboard.targetproperty="visibility"                                                                                    storyboard.targetname="separatorelement">                                                         <discreteobjectkeyframe keytime="0">                                                             <discreteobjectkeyframe.value>                                                                 <visibility>collapsed</visibility>                                                             </discreteobjectkeyframe.value>                                                         </discreteobjectkeyframe>                                                     </objectanimationusingkeyframes>                                                     <objectanimationusingkeyframes duration="0"                                                                                    storyboard.targetproperty="visibility"                                                                                    storyboard.targetname="contentpresenter">                                                         <discreteobjectkeyframe keytime="0">                                                             <discreteobjectkeyframe.value>                                                                 <visibility>collapsed</visibility>                                                             </discreteobjectkeyframe.value>                                                         </discreteobjectkeyframe>                                                     </objectanimationusingkeyframes>                                                 </storyboard>                                             </visualstate>                                             <visualstate x:name="maximizedlayout" />                                         </visualstategroup>                                     </visualstatemanager.visualstategroups>                                      <contentcontrol x:name="widgetcontet"                                                     template="{dynamicresource designeritemtemplate}">                                         <border x:name="borderelement"                                                 borderbrush="{templatebinding borderbrush}"                                                 borderthickness="{templatebinding borderthickness}"                                                 background="{templatebinding background}"                                                 dx:borderextensions.clipchild="true"                                                 cornerradius="{templatebinding cornerradius}"                                                 style="{dynamicresource contentborderstyle}">                                             <grid x:name="layoutgrid">                                                 <dxlc:layoutcontrol itemspace="0"                                                                     orientation="vertical"                                                                     padding="0"                                                                     scrollbars="none">                                                     <dxlc:layoutgroup x:name="groupboxheaderlayoutgroup"                                                                       background="{templatebinding titlebackground}"                                                                       itemspace="0"                                                                       padding="2"                                                                       visibility="{templatebinding titlevisibility}">                                                         <rectangle x:name="titlestretcher"                                                                    visibility="collapsed"                                                                    width="0" />                                                         <dx:dxcontentpresenter contenttemplate="{templatebinding headertemplate}"                                                                                content="{templatebinding header}"                                                                                istabstop="false"                                                                                margin="9,0"                                                                                verticalalignment="center">                                                             <dx:dxcontentpresenter.template>                                                                 <controltemplate targettype="{x:type dx:dxcontentpresenter}">                                                                     <contentpresenter contenttemplate="{templatebinding contenttemplate}"                                                                                       content="{templatebinding content}" />                                                                 </controltemplate>                                                             </dx:dxcontentpresenter.template>                                                         </dx:dxcontentpresenter>                                                         <button x:name="columnselement"                                                                 horizontalalignment="right"                                                                 margin="2"                                                                 verticalalignment="center"                                                                 content="{binding source={staticresource dataviewresources}, path=resource.columnstext}"                                                                 command="{binding path=columnscommand, elementname=basetile, mode=oneway}"                                                                 visibility="{binding path=columnsbuttonvisibility, elementname=basetile, mode=oneway}"                                                                 style="{dynamicresource headerbuttonstyle}" />                                                         <button x:name="settingselement"                                                                 horizontalalignment="right"                                                                 margin="2,0,0,0"                                                                 verticalalignment="center"                                                                 content="{binding source={staticresource dataviewresources}, path=resource.settingstext}"                                                                 visibility="collapsed"                                                                 style="{dynamicresource settingsbuttonstyle}" >                                                             <button.contextmenu>                                                                 <contextmenu hasdropshadow="true">                                                                     <contextmenu.items>                                                                         <!--<menuitem header="setting 1"                                                                           command="{binding path=settingscommand, elementname=basetile, mode=twoway}" />                                                                 <menuitem header="setting 2"                                                                           command="{binding path=settingscommand, elementname=basetile, mode=twoway}" />-->                                                                     </contextmenu.items>                                                                 </contextmenu>                                                             </button.contextmenu>                                                         </button>                                                         <dxlc:groupboxbutton x:name="minimizeelement"                                                                              horizontalalignment="right"                                                                              kind="maximize"                                                                              margin="2,0,0,0"                                                                              visibility="{templatebinding minimizeelementvisibility}"                                                                              verticalalignment="center">                                                         </dxlc:groupboxbutton>                                                         <dxlc:groupboxbutton x:name="maximizeelement"                                                                              horizontalalignment="right"                                                                              kind="minimize"                                                                              margin="2,0,0,0"                                                                              visibility="{templatebinding maximizeelementvisibility}"                                                                              verticalalignment="center">                                                         </dxlc:groupboxbutton>                                                     </dxlc:layoutgroup>                                                     <rectangle x:name="separatorelement"                                                                fill="{templatebinding separatorbrush}"                                                                height="1"                                                                visibility="{templatebinding titlevisibility}" />                                                      <!--horizontalscrollbarvisibility="auto"-->                                                     <dx:dxcontentpresenter x:name="contentpresenter"                                                                            contenttemplate="{templatebinding currentcontenttemplate}"                                                                            content="{templatebinding content}"                                                                            istabstop="false"                                                                            margin="{templatebinding padding}"                                                                            maxheight="{templatebinding maxheight}"                                                                            minheight="{templatebinding minheight}">                                                         <dx:dxcontentpresenter.template>                                                             <controltemplate targettype="{x:type dx:dxcontentpresenter}">                                                                 <contentpresenter contenttemplate="{templatebinding contenttemplate}"                                                                                   content="{templatebinding content}"/>                                                             </controltemplate>                                                         </dx:dxcontentpresenter.template>                                                     </dx:dxcontentpresenter>                                                 </dxlc:layoutcontrol>                                                 <custom:busyspinner visibility="{binding path=dataloading, converter={staticresource booltovisibilityconverter}}"                                                                     style="{staticresource busyspinnerstyle}" />                                             </grid>                                         </border>                                      </contentcontrol>                                     <control template="{dynamicresource resizedecoratortemplate}"                                              datacontext="{binding elementname=basetile}" />                                 </dx:container>                              </controltemplate>                         </setter.value>                     </setter>                 </style>             </style.basedon>         </style>         <!-- designer item template-->         <controltemplate x:key="designeritemtemplate"                          targettype="contentcontrol">             <grid x:name="contextgrid"                   datacontext="{binding relativesource={relativesource templatedparent}}">                 <contentpresenter content="{templatebinding contentcontrol.content}" />             </grid>         </controltemplate>          <!-- resizedecorator template -->         <controltemplate x:key="resizedecoratortemplate"                          targettype="{x:type control}">             <grid>                 <custom:resizethumb x:name="resizethumbbottom"                                     height="1"                                     cursor="sizens"                                     margin="3 0 3 -1"                                     verticalalignment="bottom"                                     horizontalalignment="stretch"                                     visibility="{binding path=canresize, mode=twoway, updatesourcetrigger=propertychanged, converter={staticresource booltovisibilityconverter}}">                     </custom:resizethumb>                  </grid>             </controltemplate>          </resourcedictionary>     </dxlc:groupbox.resources> </dxlc:groupbox> 

now, tile called "actualdatatile" displayed containing header of widget (a.k.a group box) if height of widget 0. if reload control, tile's content displayed correctly.

can tell me can lead me in right direction?


Comments

Popular posts from this blog

java - Jmockit String final length method mocking Issue -

asp.net - Razor Page Hosted on IIS 6 Fails Every Morning -

c++ - wxwidget compiling on windows command prompt -