API-referenca za izborničke trake, toolbare i Ribbon.
Manager za izbornike i toolbare.
WvdS.UI.Controls.Bars
<BarManager> <BarManager.MainMenu> <Bar> <BarSubItem Caption="File"> <BarButton Caption="New" Command="{Binding NewCommand}" Shortcut="Ctrl+N" /> <BarButton Caption="Open" Command="{Binding OpenCommand}" Shortcut="Ctrl+O" /> <BarSeparator /> <BarButton Caption="Exit" Command="{Binding ExitCommand}" /> </BarSubItem> <BarSubItem Caption="Edit"> <BarButton Caption="Undo" Command="{Binding UndoCommand}" Shortcut="Ctrl+Z" /> <BarButton Caption="Redo" Command="{Binding RedoCommand}" Shortcut="Ctrl+Y" /> </BarSubItem> </Bar> </BarManager.MainMenu> <BarManager.Toolbars> <Bar Name="Standard"> <BarButton Caption="New" Icon="new" Command="{Binding NewCommand}" /> <BarButton Caption="Open" Icon="open" Command="{Binding OpenCommand}" /> <BarButton Caption="Save" Icon="save" Command="{Binding SaveCommand}" /> </Bar> </BarManager.Toolbars> </BarManager>
| Property | Tip | Default | Opis |
| MainMenu | TBar | nil | Glavni izbornik |
|---|---|---|---|
| Toolbars | TBarCollection | nil | Toolbari |
| PopupMenus | TPopupMenuCollection | nil | Kontekstni izbornici |
| AllowCustomization | Boolean | True | Prilagodba dopuštena |
Microsoft Office-stil Ribbon.
WvdS.UI.Controls.Bars
<RibbonControl ApplicationButtonText="File"> <RibbonControl.ApplicationMenu> <RibbonApplicationMenu> <BarButton Caption="New" Icon="new" Command="{Binding NewCommand}" /> <BarButton Caption="Open" Icon="open" Command="{Binding OpenCommand}" /> <BarButton Caption="Save" Icon="save" Command="{Binding SaveCommand}" /> <BarSeparator /> <BarButton Caption="Exit" Command="{Binding ExitCommand}" /> </RibbonApplicationMenu> </RibbonControl.ApplicationMenu> <RibbonPage Caption="Home"> <RibbonGroup Caption="Clipboard"> <BarButton Caption="Paste" Icon="paste" Size="Large" /> <BarButton Caption="Cut" Icon="cut" /> <BarButton Caption="Copy" Icon="copy" /> </RibbonGroup> <RibbonGroup Caption="Font"> <BarEditItem> <ComboBoxEdit Width="100" ItemsSource="{Binding Fonts}" /> </BarEditItem> <BarButton Caption="Bold" Icon="bold" IsToggle="True" /> <BarButton Caption="Italic" Icon="italic" IsToggle="True" /> </RibbonGroup> </RibbonPage> <RibbonPage Caption="Insert"> <RibbonGroup Caption="Tables"> <BarButton Caption="Table" Icon="table" Size="Large" /> </RibbonGroup> </RibbonPage> </RibbonControl>
| Property | Tip | Default | Opis |
| Pages | TRibbonPageCollection | nil | Ribbon-stranice |
|---|---|---|---|
| SelectedPage | TRibbonPage | nil | Aktivna stranica |
| ApplicationButtonText | string | | Tekst App-gumba |
^ ApplicationMenu | TRibbonApplicationMenu | nil | App-izbornik |
^ QuickAccessToolbar | TBar | nil | Brzi pristup |
^ IsMinimized | Boolean | False | Ribbon minimiziran |
^ Style | TRibbonStyle | rsOffice2019 | Office2007, Office2010, Office2013, Office2016, Office2019 |
—-
===== TWvdSRibbonPage =====
Ribbon-stranica (Tab).
==== Namespace ====
WvdS.UI.Controls.Bars
==== Properties ====
| Property | Tip | Default | Opis |
^ Caption | string | | Naslov taba |
| Groups | TRibbonGroupCollection | nil | Grupe |
| IsVisible | Boolean | True | Vidljivo |
| ContextualTabGroup | string | | Kontekstualni tab |
—-
===== TWvdSRibbonGroup =====
Ribbon-grupa unutar stranice.
==== Namespace ====
WvdS.UI.Controls.Bars
==== Properties ====
| Property | Tip | Default | Opis |
^ Caption | string | | Naziv grupe |
| Items | TBarItemCollection | nil | Sadržane stavke |
| ShowDialogLauncher | Boolean | False | Dialog-Launcher |
| CollapsePriority | Integer | 0 | Prioritet sklapanja |
Toolbar/Izbornik-gumb.
WvdS.UI.Controls.Bars
<BarButton Caption="Save" Icon="save" Command="{Binding SaveCommand}" Shortcut="Ctrl+S" Hint="Save the current document" />
| Property | Tip | Default | Opis |
| Caption | string | | Tekst gumba |
^ Icon | TWvdSImageSource | nil | Ikona |
^ Command | IWvdSCommand | nil | Command |
^ Shortcut | string | | Tipkovnička prečica |
|---|---|---|---|
| Hint | string | | Tooltip |
^ Size | TBarButtonSize | bsSmall | Small, Large |
^ IsToggle | Boolean | False | Toggle-gumb |
^ IsPressed | Boolean | False | Toggle-status |
^ IsEnabled | Boolean | True | Aktiviran |
==== Events ====
| Event | Signatura | Opis |
^ OnClick | TNotifyEvent | Gumb kliknut |
—-
===== TWvdSBarSubItem =====
Podizbornik.
==== Namespace ====
WvdS.UI.Controls.Bars
==== PXAML ====
<code xml>
<BarSubItem Caption=„Recent Files“>
<BarButton Caption=„Document1.txt“ />
<BarButton Caption=„Document2.txt“ />
<BarSeparator />
<BarButton Caption=„Clear Recent“ />
</BarSubItem>
</code>
==== Properties ====
| Property | Tip | Default | Opis |
^ Caption | string | | Tekst izbornika |
| Icon | TWvdSImageSource | nil | Ikona |
| Items | TBarItemCollection | nil | Stavke podizbornika |
Editor u Toolbar/Izborniku.
WvdS.UI.Controls.Bars
<BarEditItem Caption="Zoom:"> <SpinEdit Value="{Binding ZoomLevel}" Minimum="25" Maximum="400" Width="80" /> </BarEditItem>
| Property | Tip | Default | Opis |
| Caption | string |
|---|
<DataGrid ContextMenu="{StaticResource GridContextMenu}" /> <PopupMenu x:Key="GridContextMenu"> <BarButton Caption="Edit" Command="{Binding EditCommand}" /> <BarButton Caption="Delete" Command="{Binding DeleteCommand}" /> <BarSeparator /> <BarSubItem Caption="Export"> <BarButton Caption="Excel" Command="{Binding ExportExcel}" /> <BarButton Caption="PDF" Command="{Binding ExportPdf}" /> </BarSubItem> </PopupMenu>
| Property | Tip | Default | Opis |
| Items | TBarItemCollection | nil | Stavke izbornika |
|---|
| Metoda | Opis |
| ShowAt(x, y) | Prikaži izbornik na poziciji |
|---|---|
| ShowAtCursor | Prikaži izbornik na kursoru |
| Close | Zatvori izbornik |