Exemplo n.º 1
0
        DocumentPanel CreateNoteDocument(Note note)
        {
            DocumentPanel document = new DocumentPanel();

            document.HorizontalScrollBarVisibility = ScrollBarVisibility.Disabled;
            document.VerticalScrollBarVisibility   = ScrollBarVisibility.Disabled;
            document.AllowFloat = false;
            document.AllowMove  = false;
            document.Name       = note.Caption;
            document.Caption    = note.Caption;

            Note.SetNote(document, note);
            LayoutGroup tabs = new LayoutGroup();

            tabs.Caption          = "Pages";
            tabs.ShowCaption      = true;
            tabs.GroupBorderStyle = GroupBorderStyle.Tabbed;
            tabs.CaptionLocation  = CaptionLocation.Bottom;
            tabs.AddRange(CreateNotePages(note));
            tabs.Add(CreateNewItemPage());
            LayoutGroup group = new LayoutGroup();

            group.Add(tabs);
            document.Content = group;
            return(document);
        }
Exemplo n.º 2
0
        private void CreateFloatPanels()
        {
            FloatGroup fGroup1 = new FloatGroup()
            {
                FloatLocation = new Point(100, 100), FloatSize = new Size(200, 200)
            };
            LayoutGroup group = new LayoutGroup()
            {
                Orientation = Orientation.Vertical
            };
            LayoutPanel panel4 = CreateLayoutPanel("Panel4");
            LayoutPanel panel5 = CreateLayoutPanel("Panel5");

            group.AddRange(new BaseLayoutItem[] { panel4, panel5 });
            fGroup1.Add(group);

            FloatGroup fGroup2 = new FloatGroup()
            {
                FloatLocation = new Point(150, 150), FloatSize = new Size(200, 200)
            };
            LayoutPanel panel6 = CreateLayoutPanel("Panel6");

            fGroup2.Add(panel6);

            dockManager.FloatGroups.AddRange(new FloatGroup[] { fGroup1, fGroup2 });
        }
Exemplo n.º 3
0
        LayoutGroup CreateRow(int row, int itemsCount)
        {
            LayoutGroup group = new LayoutGroup()
            {
                AllowSplitters = false
            };

            BaseLayoutItem[] items = new BaseLayoutItem[itemsCount];
            for (int i = 0; i < itemsCount; i++)
            {
                items[i] = CreateItem(row * itemsCount + i);
            }
            group.AddRange(items);
            return(group);
        }
Exemplo n.º 4
0
        private void CreateLayoutRoot()
        {
            LayoutGroup root  = new LayoutGroup();
            LayoutGroup group = new LayoutGroup()
            {
                Orientation = Orientation.Vertical
            };
            LayoutPanel panel1 = CreateLayoutPanel("Panel3");
            LayoutPanel panel2 = CreateLayoutPanel("Panel3");
            LayoutPanel panel3 = CreateLayoutPanel("Panel3");

            group.AddRange(new BaseLayoutItem[] { panel2, panel3 });
            root.AddRange(new BaseLayoutItem[] { panel1, group });
            dockManager.LayoutRoot = root;
        }