コード例 #1
0
ファイル: ViewModel.cs プロジェクト: kantharajals/wpf-demos
        /// <summary>
        /// Adding ribbon design items items to the ribbon bar.
        /// </summary>
        /// <param name="customRibbonBar">Ribbonbar.</param>
        private void PopulateDesignItems(CustomRibbonBar customRibbonBar)
        {
            CustomRibbonItem firstItem = new CustomRibbonItem()
            {
                ItemHeader = "Header Row", IsCheckBox = true, Checked = true
            };
            CustomRibbonItem secondItem = new CustomRibbonItem()
            {
                ItemHeader = "Total Row", IsCheckBox = true, Checked = false
            };
            CustomRibbonItem thirdItem = new CustomRibbonItem()
            {
                ItemHeader = "Banded Row", IsCheckBox = true, Checked = true
            };
            CustomRibbonItem fourthItem = new CustomRibbonItem()
            {
                ItemHeader = "First Column", IsCheckBox = true, Checked = true
            };
            CustomRibbonItem fifthItem = new CustomRibbonItem()
            {
                ItemHeader = "Last Column", IsCheckBox = true, Checked = false
            };
            CustomRibbonItem sixthItem = new CustomRibbonItem()
            {
                ItemHeader = "Banded Column", IsCheckBox = true, Checked = false
            };

            customRibbonBar.CustomRibbonItems.Add(firstItem);
            customRibbonBar.CustomRibbonItems.Add(secondItem);
            customRibbonBar.CustomRibbonItems.Add(thirdItem);
            customRibbonBar.CustomRibbonItems.Add(fourthItem);
            customRibbonBar.CustomRibbonItems.Add(fifthItem);
            customRibbonBar.CustomRibbonItems.Add(sixthItem);
        }
コード例 #2
0
ファイル: ViewModel.cs プロジェクト: kantharajals/wpf-demos
        /// <summary>
        /// populate ribbon items (illustration) to the insert tab.
        /// </summary>
        /// <param name="customRibbonBar">Specifies the ribbon bar.</param>
        private void PopulateRibbonIllustrationsItems(CustomRibbonBar customRibbonBar)
        {
            CustomRibbonItem firstItem = new CustomRibbonItem()
            {
                ItemHeader = "Picture", IsLarge = true, Image = "Picture.png", Command = ButtonCommand
            };
            CustomRibbonItem secondItem = new CustomRibbonItem()
            {
                ItemHeader = "Comment", IsLarge = true, Image = "0356_NewComment_32.png", Command = ButtonCommand
            };
            CustomRibbonItem thirdItem = new CustomRibbonItem()
            {
                ItemHeader = "Shapes", IsLarge = true, IsDropDownButton = true, Image = "0202_InsertShape_32.png"
            };
            CustomRibbonItem fourthItem = new CustomRibbonItem()
            {
                ItemHeader = "Chart", IsLarge = true, IsDropDownButton = true, Image = "base_charts.png"
            };

            customRibbonBar.CustomRibbonItems.Add(firstItem);
            customRibbonBar.CustomRibbonItems.Add(secondItem);
            customRibbonBar.CustomRibbonItems.Add(thirdItem);
            customRibbonBar.CustomRibbonItems.Add(fourthItem);

            PopulateShapeDropDownItems(thirdItem);
            PopulateChartDropDownItems(fourthItem);
        }
コード例 #3
0
        private void PopulateDesignItems(CustomRibbonBar Bar)
        {
            CustomRibbonItem Item1 = new CustomRibbonItem()
            {
                ItemHeader = "Header Row", IsCheckBox = true, Checked = true
            };
            CustomRibbonItem Item2 = new CustomRibbonItem()
            {
                ItemHeader = "Total Row", IsCheckBox = true, Checked = false
            };
            CustomRibbonItem Item3 = new CustomRibbonItem()
            {
                ItemHeader = "Banded Row", IsCheckBox = true, Checked = true
            };
            CustomRibbonItem Item4 = new CustomRibbonItem()
            {
                ItemHeader = "First Column", IsCheckBox = true, Checked = true
            };
            CustomRibbonItem Item5 = new CustomRibbonItem()
            {
                ItemHeader = "Last Column", IsCheckBox = true, Checked = false
            };
            CustomRibbonItem Item6 = new CustomRibbonItem()
            {
                ItemHeader = "Banded Column", IsCheckBox = true, Checked = false
            };

            Bar.CustomRibbonItems.Add(Item1);
            Bar.CustomRibbonItems.Add(Item2);
            Bar.CustomRibbonItems.Add(Item3);
            Bar.CustomRibbonItems.Add(Item4);
            Bar.CustomRibbonItems.Add(Item5);
            Bar.CustomRibbonItems.Add(Item6);
        }
コード例 #4
0
        private void PopuplateZoomItems(CustomRibbonBar Bar)
        {
            CustomRibbonItem Item1 = new CustomRibbonItem()
            {
                ItemHeader = "Zoom", IsLarge = true, Image = "Zoom_32x32.png"
            };
            CustomRibbonItem Item2 = new CustomRibbonItem()
            {
                ItemHeader = "100%", IsLarge = true, Image = "portrait.png"
            };
            CustomRibbonItem Item3 = new CustomRibbonItem()
            {
                ItemHeader = "One Page", Image = "Team Email.png"
            };
            CustomRibbonItem Item4 = new CustomRibbonItem()
            {
                ItemHeader = "Two Pages", Image = "Reading Pane.png"
            };
            CustomRibbonItem Item5 = new CustomRibbonItem()
            {
                ItemHeader = "Page Width", Image = "Reading Pane.png"
            };

            Bar.CustomRibbonItems.Add(Item1);
            Bar.CustomRibbonItems.Add(Item2);
            Bar.CustomRibbonItems.Add(Item3);
            Bar.CustomRibbonItems.Add(Item4);
            Bar.CustomRibbonItems.Add(Item5);
        }
コード例 #5
0
ファイル: ViewModel.cs プロジェクト: kantharajals/wpf-demos
        /// <summary>
        /// Adding ribbon items to the second ribbon bar(Zoom).
        /// </summary>
        /// <param name="customRibbonBar">Specifies the ribbon bar.</param>
        private void PopuplateZoomItems(CustomRibbonBar customRibbonBar)
        {
            CustomRibbonItem firstItem = new CustomRibbonItem()
            {
                ItemHeader = "Zoom", IsLarge = true, Image = "Zoom_32x32.png", Command = ButtonCommand
            };
            CustomRibbonItem secondItem = new CustomRibbonItem()
            {
                ItemHeader = "100%", IsLarge = true, Image = "portrait.png", Command = ButtonCommand
            };
            CustomRibbonItem thirdItem = new CustomRibbonItem()
            {
                ItemHeader = "One Page", Image = "Team Email.png", Command = ButtonCommand
            };
            CustomRibbonItem fourthItem = new CustomRibbonItem()
            {
                ItemHeader = "Two Pages", Image = "Reading Pane.png", Command = ButtonCommand
            };
            CustomRibbonItem fifthItem = new CustomRibbonItem()
            {
                ItemHeader = "Page Width", Image = "Reading Pane.png", Command = ButtonCommand
            };

            customRibbonBar.CustomRibbonItems.Add(firstItem);
            customRibbonBar.CustomRibbonItems.Add(secondItem);
            customRibbonBar.CustomRibbonItems.Add(thirdItem);
            customRibbonBar.CustomRibbonItems.Add(fourthItem);
            customRibbonBar.CustomRibbonItems.Add(fifthItem);
        }
コード例 #6
0
ファイル: ViewModel.cs プロジェクト: kantharajals/wpf-demos
        /// <summary>
        /// Adding ribbon tables to the ribbon tab (insert).
        /// </summary>
        /// <param name="customRibbonBar">Specifies the ribbon bar.</param>
        private void PopulateRibbonTableItems(CustomRibbonBar customRibbonBar)
        {
            CustomRibbonItem firstItem = new CustomRibbonItem()
            {
                ItemHeader = "Tables", IsLarge = true, IsDropDownButton = true, Image = "Table_32.png", HasTablePicker = true
            };

            customRibbonBar.CustomRibbonItems.Add(firstItem);
        }
コード例 #7
0
        private void PopulateRibbonTableItems(CustomRibbonBar Bar)
        {
            CustomRibbonItem Item1 = new CustomRibbonItem()
            {
                ItemHeader = "Tables", IsLarge = true, IsDropDownButton = true, Image = "Table_32.png"
            };

            Bar.CustomRibbonItems.Add(Item1);
        }
コード例 #8
0
        private void PopulateDesignBar(CustomRibbonTab tab)
        {
            CustomRibbonBar Bar1 = new CustomRibbonBar()
            {
                BarHeader = "Table Style Options"
            };

            PopulateDesignItems(Bar1);
            tab.CustomChild1RibbonBars.Add(Bar1);
        }
コード例 #9
0
ファイル: ViewModel.cs プロジェクト: kantharajals/wpf-demos
        /// <summary>
        /// Populating ribbon items to the ribbon bar.
        /// </summary>
        /// <param name="customRibbonTab">Ribbontab.</param>
        private void PopulateDesignBar(CustomRibbonTab customRibbonTab)
        {
            CustomRibbonBar firstBar = new CustomRibbonBar()
            {
                BarHeader = "Table Style Options"
            };

            PopulateDesignItems(firstBar);
            customRibbonTab.CustomFirstChildRibbonBars.Add(firstBar);
        }
コード例 #10
0
        private void PopulatePrintItems(CustomRibbonBar Bar)
        {
            CustomRibbonItem Item1 = new CustomRibbonItem()
            {
                ItemHeader = "Print", IsLarge = true, Image = "PrintAreaflat.png"
            };
            CustomRibbonItem Item2 = new CustomRibbonItem()
            {
                ItemHeader = "Options", IsLarge = true, Image = "View Setting.png"
            };

            Bar.CustomRibbonItems.Add(Item1);
            Bar.CustomRibbonItems.Add(Item2);
        }
コード例 #11
0
        private void PopulateCreateItems(CustomRibbonBar Bar)
        {
            CustomRibbonItem Item1 = new CustomRibbonItem()
            {
                ItemHeader = "Envelopes", IsLarge = true, Image = "Read unread.png"
            };
            CustomRibbonItem Item2 = new CustomRibbonItem()
            {
                ItemHeader = "Labels", IsLarge = true, Image = "Send and recive all folder.png"
            };

            Bar.CustomRibbonItems.Add(Item1);
            Bar.CustomRibbonItems.Add(Item2);
        }
コード例 #12
0
ファイル: ViewModel.cs プロジェクト: kantharajals/wpf-demos
        /// <summary>
        /// Adding ribbon items to the first ribbon bar(Print).
        /// </summary>
        /// <param name="customRibbonBar">Specifies the ribbon bar.</param>
        private void PopulatePrintItems(CustomRibbonBar customRibbonBar)
        {
            CustomRibbonItem firstItem = new CustomRibbonItem()
            {
                ItemHeader = "Print", IsLarge = true, Image = "PrintAreaflat.png", Command = ButtonCommand
            };
            CustomRibbonItem secondItem = new CustomRibbonItem()
            {
                ItemHeader = "Options", IsLarge = true, Image = "View Setting.png", Command = ButtonCommand
            };

            customRibbonBar.CustomRibbonItems.Add(firstItem);
            customRibbonBar.CustomRibbonItems.Add(secondItem);
        }
コード例 #13
0
ファイル: ViewModel.cs プロジェクト: kantharajals/wpf-demos
        /// <summary>
        /// populate ribbon items(MDI items) to the ribbon bars(Home).
        /// </summary>
        /// <param name="customRibbonBar">Specifies the ribbon bar</param>
        private void PopulateMDIItems(CustomRibbonBar customRibbonBar)
        {
            CustomRibbonItem firstItem = new CustomRibbonItem()
            {
                ItemHeader = "MDI", Image = "MDI_blue.png", Command = MDICommand
            };
            CustomRibbonItem secondItem = new CustomRibbonItem()
            {
                ItemHeader = "TDI", Image = "Tabblue.png", Command = TDICommand
            };

            customRibbonBar.CustomRibbonItems.Add(firstItem);
            customRibbonBar.CustomRibbonItems.Add(secondItem);
        }
コード例 #14
0
        private void PopulateMDIItems(CustomRibbonBar Bar)
        {
            CustomRibbonItem Item1 = new CustomRibbonItem()
            {
                ItemHeader = "MDI", Image = "MDI_blue.png", Command = MDICommand
            };
            CustomRibbonItem Item2 = new CustomRibbonItem()
            {
                ItemHeader = "TDI", Image = "Tabblue.png", Command = TDICommand
            };

            Bar.CustomRibbonItems.Add(Item1);
            Bar.CustomRibbonItems.Add(Item2);
        }
コード例 #15
0
ファイル: ViewModel.cs プロジェクト: kantharajals/wpf-demos
        /// <summary>
        /// Adding ribbon items to the first ribbon bar(Create items) inside the secondChildRibbon ribbon tabs.
        /// </summary>
        /// <param name="customRibbonBar">Specifies the ribbon bar</param>
        private void PopulateCreateItems(CustomRibbonBar customRibbonBar)
        {
            CustomRibbonItem firstItem = new CustomRibbonItem()
            {
                ItemHeader = "Envelopes", IsLarge = true, Image = "Read unread.png", Command = ButtonCommand
            };
            CustomRibbonItem secondItem = new CustomRibbonItem()
            {
                ItemHeader = "Labels", IsLarge = true, Image = "Send and recive all folder.png", Command = ButtonCommand
            };

            customRibbonBar.CustomRibbonItems.Add(firstItem);
            customRibbonBar.CustomRibbonItems.Add(secondItem);
        }
コード例 #16
0
ファイル: ViewModel.cs プロジェクト: kantharajals/wpf-demos
        /// <summary>
        /// Adding ribbon items to the child(paragraph) ribbon bar.
        /// </summary>
        /// <param name="customRibbonBar">Child ribbon tab.</param>
        private void PopulateParagraphItems(CustomRibbonBar customRibbonBar)
        {
            CustomRibbonItem firstItem = new CustomRibbonItem()
            {
                Image = "Bullets16.png", Command = ButtonCommand
            };
            CustomRibbonItem secondItem = new CustomRibbonItem()
            {
                Image = "AlignTextLeft16.png", Command = ButtonCommand
            };
            CustomRibbonItem thirdItem = new CustomRibbonItem()
            {
                Image = "DecreaseIndent16.png", Command = ButtonCommand
            };
            CustomRibbonItem fourthItem = new CustomRibbonItem()
            {
                Image = "Numbering16.png", Command = ButtonCommand
            };
            CustomRibbonItem fifthItem = new CustomRibbonItem()
            {
                Image = "AlignTextCenter16.png", Command = ButtonCommand
            };
            CustomRibbonItem sixthItem = new CustomRibbonItem()
            {
                Image = "IncreaseIndent16.png", Command = ButtonCommand
            };
            CustomRibbonItem seventhItem = new CustomRibbonItem()
            {
                Image = "MultilevelList16.png", Command = ButtonCommand
            };
            CustomRibbonItem eigthItem = new CustomRibbonItem()
            {
                Image = "AlignTextRight16.png", Command = ButtonCommand
            };
            CustomRibbonItem ninthItem = new CustomRibbonItem()
            {
                Image = "LineSpacing16.png", Command = ButtonCommand
            };

            customRibbonBar.CustomRibbonItems.Add(firstItem);
            customRibbonBar.CustomRibbonItems.Add(secondItem);
            customRibbonBar.CustomRibbonItems.Add(thirdItem);
            customRibbonBar.CustomRibbonItems.Add(fourthItem);
            customRibbonBar.CustomRibbonItems.Add(fifthItem);
            customRibbonBar.CustomRibbonItems.Add(sixthItem);
            customRibbonBar.CustomRibbonItems.Add(seventhItem);
            customRibbonBar.CustomRibbonItems.Add(eigthItem);
            customRibbonBar.CustomRibbonItems.Add(ninthItem);
        }
コード例 #17
0
        private void PopulateParagraphItems(CustomRibbonBar Bar)
        {
            CustomRibbonItem Item1 = new CustomRibbonItem()
            {
                ItemHeader = "", Image = "Bullets16.png"
            };
            CustomRibbonItem Item2 = new CustomRibbonItem()
            {
                ItemHeader = "", Image = "AlignTextLeft16.png"
            };
            CustomRibbonItem Item3 = new CustomRibbonItem()
            {
                ItemHeader = "", Image = "DecreaseIndent16.png"
            };
            CustomRibbonItem Item4 = new CustomRibbonItem()
            {
                ItemHeader = "", Image = "Numbering16.png"
            };
            CustomRibbonItem Item5 = new CustomRibbonItem()
            {
                ItemHeader = "", Image = "AlignTextCenter16.png"
            };
            CustomRibbonItem Item6 = new CustomRibbonItem()
            {
                ItemHeader = "", Image = "IncreaseIndent16.png"
            };
            CustomRibbonItem Item7 = new CustomRibbonItem()
            {
                ItemHeader = "", Image = "MultilevelList16.png"
            };
            CustomRibbonItem Item8 = new CustomRibbonItem()
            {
                ItemHeader = "", Image = "AlignTextRight16.png"
            };
            CustomRibbonItem Item9 = new CustomRibbonItem()
            {
                ItemHeader = "", Image = "LineSpacing16.png"
            };

            Bar.CustomRibbonItems.Add(Item1);
            Bar.CustomRibbonItems.Add(Item2);
            Bar.CustomRibbonItems.Add(Item3);
            Bar.CustomRibbonItems.Add(Item4);
            Bar.CustomRibbonItems.Add(Item5);
            Bar.CustomRibbonItems.Add(Item6);
            Bar.CustomRibbonItems.Add(Item7);
            Bar.CustomRibbonItems.Add(Item8);
            Bar.CustomRibbonItems.Add(Item9);
        }
コード例 #18
0
        //Home Tab
        void PopulateRibbonHomeBars(CustomRibbonTab Tab)
        {
            CustomRibbonBar Bar1 = new CustomRibbonBar()
            {
                BarHeader = "Clipboard"
            };
            CustomRibbonBar Bar2 = new CustomRibbonBar()
            {
                BarHeader = "MDI Styles"
            };

            PopulateRibbonNewItems(Bar1);
            PopulateMDIItems(Bar2);
            Tab.CustomRibbonBars.Add(Bar1);
            Tab.CustomRibbonBars.Add(Bar2);
        }
コード例 #19
0
ファイル: ViewModel.cs プロジェクト: kantharajals/wpf-demos
        /// <summary>
        /// Adding child ribbon bars to the ribbon tab(Home).
        /// </summary>
        /// <param name="Tab">Specifies the ribbon bar</param>
        void PopulateRibbonHomeBars(CustomRibbonTab Tab)
        {
            CustomRibbonBar firstBar = new CustomRibbonBar()
            {
                BarHeader = "Clipboard"
            };
            CustomRibbonBar secondBar = new CustomRibbonBar()
            {
                BarHeader = "MDI Styles"
            };

            PopulateRibbonNewItems(firstBar);
            PopulateMDIItems(secondBar);
            Tab.CustomRibbonBars.Add(firstBar);
            Tab.CustomRibbonBars.Add(secondBar);
        }
コード例 #20
0
ファイル: ViewModel.cs プロジェクト: kantharajals/wpf-demos
        /// <summary>
        /// Populating child ribbon bar inside the parent bar.
        /// </summary>
        /// <param name="customRibbonTab">Child ribbon tab.</param>
        private void PopulateChildHomeBar(CustomRibbonTab customRibbonTab)
        {
            CustomRibbonBar firstBar = new CustomRibbonBar()
            {
                BarHeader = "Editing"
            };
            CustomRibbonBar secondBar = new CustomRibbonBar()
            {
                BarHeader = "Paragraph"
            };

            PopulateEditingItems(firstBar);
            PopulateParagraphItems(secondBar);
            customRibbonTab.CustomFirstChildRibbonBars.Add(firstBar);
            customRibbonTab.CustomFirstChildRibbonBars.Add(secondBar);
        }
コード例 #21
0
        private void PopulateChildHomeBar(CustomRibbonTab tab)
        {
            CustomRibbonBar Bar1 = new CustomRibbonBar()
            {
                BarHeader = "Editing"
            };
            CustomRibbonBar Bar2 = new CustomRibbonBar()
            {
                BarHeader = "Paragraph"
            };

            PopulateEditingItems(Bar1);
            PopulateParagraphItems(Bar2);
            tab.CustomChild1RibbonBars.Add(Bar1);
            tab.CustomChild1RibbonBars.Add(Bar2);
        }
コード例 #22
0
ファイル: ViewModel.cs プロジェクト: kantharajals/wpf-demos
        /// <summary>
        /// Allocating ribbon bars to secong ribbon tab inside the child2ribbon tabs.
        /// </summary>
        /// <param name="Tab">Specifies the ribbon tab.</param>
        private void PopulateMailingsBars(CustomRibbonTab Tab)
        {
            CustomRibbonBar firstBar = new CustomRibbonBar()
            {
                BarHeader = "Create"
            };

            PopulateCreateItems(firstBar);
            CustomRibbonBar secondBar = new CustomRibbonBar()
            {
                BarHeader = "Mail"
            };

            PopuplateRibbonMailItems(secondBar);
            Tab.CustomSecondChildRibbonBars.Add(firstBar);
            Tab.CustomSecondChildRibbonBars.Add(secondBar);
        }
コード例 #23
0
        private void PopulateMailingsBars(CustomRibbonTab Tab)
        {
            CustomRibbonBar Bar1 = new CustomRibbonBar()
            {
                BarHeader = "Create"
            };

            PopulateCreateItems(Bar1);
            CustomRibbonBar Bar2 = new CustomRibbonBar()
            {
                BarHeader = "Mail"
            };

            PopuplateRibbonMailItems(Bar2);
            Tab.CustomChild2RibbonBars.Add(Bar1);
            Tab.CustomChild2RibbonBars.Add(Bar2);
        }
コード例 #24
0
ファイル: ViewModel.cs プロジェクト: kantharajals/wpf-demos
        /// <summary>
        /// Allocating ribbon bars inside the secondChildRibbon ribbon  tab.
        /// </summary>
        /// <param name="Tab">Specifies the ribbon tab.</param>
        private void PopulatePrintBars(CustomRibbonTab Tab)
        {
            CustomRibbonBar firstBar = new CustomRibbonBar()
            {
                BarHeader = "Print"
            };

            PopulatePrintItems(firstBar);
            CustomRibbonBar secondBar = new CustomRibbonBar()
            {
                BarHeader = "Zoom"
            };

            PopuplateZoomItems(secondBar);
            Tab.CustomSecondChildRibbonBars.Add(firstBar);
            Tab.CustomSecondChildRibbonBars.Add(secondBar);
        }
コード例 #25
0
        private void PopulatePrintBars(CustomRibbonTab Tab)
        {
            CustomRibbonBar Bar1 = new CustomRibbonBar()
            {
                BarHeader = "Print"
            };

            PopulatePrintItems(Bar1);
            CustomRibbonBar Bar2 = new CustomRibbonBar()
            {
                BarHeader = "Zoom"
            };

            PopuplateZoomItems(Bar2);
            Tab.CustomChild2RibbonBars.Add(Bar1);
            Tab.CustomChild2RibbonBars.Add(Bar2);
        }
コード例 #26
0
        private void PopulateRibbonLinkItems(CustomRibbonBar Bar)
        {
            CustomRibbonItem Item1 = new CustomRibbonItem()
            {
                ItemHeader = "Hyperlink", IsLarge = true, Image = "Hyperlink32.png"
            };
            CustomRibbonItem Item2 = new CustomRibbonItem()
            {
                ItemHeader = "Replace", IsLarge = true, Image = "replace_32.png"
            };
            CustomRibbonItem Item3 = new CustomRibbonItem()
            {
                ItemHeader = "Zoom", IsLarge = true, Image = "Zoom_32x32.png"
            };

            Bar.CustomRibbonItems.Add(Item1);
            Bar.CustomRibbonItems.Add(Item2);
            Bar.CustomRibbonItems.Add(Item3);
        }
コード例 #27
0
        private void PopuplateRibbonMailItems(CustomRibbonBar Bar)
        {
            CustomRibbonItem Item1 = new CustomRibbonItem()
            {
                ItemHeader = "Attach File", IsLarge = true, Image = "base_paperclip_32.png", IsSplitButton = true
            };
            CustomRibbonItem Item2 = new CustomRibbonItem()
            {
                ItemHeader = "Business card", IsLarge = true, Image = "base_business_contacts.png"
            };
            CustomRibbonItem Item3 = new CustomRibbonItem()
            {
                ItemHeader = "Audio", IsLarge = true, Image = "base_speaker_32.png"
            };

            Bar.CustomRibbonItems.Add(Item1);
            Bar.CustomRibbonItems.Add(Item2);
            Bar.CustomRibbonItems.Add(Item3);
        }
コード例 #28
0
ファイル: ViewModel.cs プロジェクト: kantharajals/wpf-demos
        /// <summary>
        /// Populate ribbon items (link items to the insert tab.
        /// </summary>
        /// <param name="customRibbonBar">Specifies the ribbon bar.</param>
        private void PopulateRibbonLinkItems(CustomRibbonBar customRibbonBar)
        {
            CustomRibbonItem firstItem = new CustomRibbonItem()
            {
                ItemHeader = "Hyperlink", IsLarge = true, Image = "Hyperlink32.png", Command = ButtonCommand
            };
            CustomRibbonItem secondItem = new CustomRibbonItem()
            {
                ItemHeader = "Replace", IsLarge = true, Image = "replace_32.png", Command = ButtonCommand
            };
            CustomRibbonItem thirdItem = new CustomRibbonItem()
            {
                ItemHeader = "Zoom", IsLarge = true, Image = "Zoom_32x32.png", Command = ButtonCommand
            };

            customRibbonBar.CustomRibbonItems.Add(firstItem);
            customRibbonBar.CustomRibbonItems.Add(secondItem);
            customRibbonBar.CustomRibbonItems.Add(thirdItem);
        }
コード例 #29
0
ファイル: ViewModel.cs プロジェクト: kantharajals/wpf-demos
        /// <summary>
        /// Adding ribbon items to the child(Editing) ribbon bar.
        /// </summary>
        /// <param name="customRibbonBar">Child ribbon tab.</param>
        private void PopulateEditingItems(CustomRibbonBar customRibbonBar)
        {
            CustomRibbonItem firstItem = new CustomRibbonItem()
            {
                ItemHeader = "Find", Image = "Search.png", Command = ButtonCommand
            };
            CustomRibbonItem secondItem = new CustomRibbonItem()
            {
                ItemHeader = "Replace", Image = "replace_32.png", Command = ButtonCommand
            };
            CustomRibbonItem thirdItem = new CustomRibbonItem()
            {
                ItemHeader = "Select", Image = "start2.png", Command = ButtonCommand
            };

            customRibbonBar.CustomRibbonItems.Add(firstItem);
            customRibbonBar.CustomRibbonItems.Add(secondItem);
            customRibbonBar.CustomRibbonItems.Add(thirdItem);
        }
コード例 #30
0
        private void PopulateEditingItems(CustomRibbonBar Bar)
        {
            CustomRibbonItem Item1 = new CustomRibbonItem()
            {
                ItemHeader = "Find", Image = "Search.png"
            };
            CustomRibbonItem Item2 = new CustomRibbonItem()
            {
                ItemHeader = "Replace", Image = "replace_32.png"
            };
            CustomRibbonItem Item3 = new CustomRibbonItem()
            {
                ItemHeader = "Select", Image = "start2.png"
            };

            Bar.CustomRibbonItems.Add(Item1);
            Bar.CustomRibbonItems.Add(Item2);
            Bar.CustomRibbonItems.Add(Item3);
        }