Example #1
0
        protected override Size MeasureOverrideCore(Size availableSize)
        {
            _elements.Clear();

            var found = false;

            Offset = 0;

            foreach (RibbonPageCategory pageCategory in Children)
            {
                if (found == false && string.IsNullOrEmpty(pageCategory.Header))
                {
                    Offset += pageCategory.PagesSize.Width;
                    continue;
                }

                found = true;
                _elements.Add(pageCategory);
            }

            return(StackPanelLayout.Measure(this, availableSize));
        }
Example #2
0
 protected override Size MeasureOverrideCore(Size availableSize)
 {
     return(StackPanelLayout.Measure(this, availableSize));
 }