Class MainToolbarItemBase
Base class for all built-in main toolbar items.
Inheritance
Inherited Members
Namespace: PSPDFKit.Sdk.Models.Toolbar.Base
Assembly: Sdk.dll
Syntax
public abstract class MainToolbarItemBase : BindableBase, IMainToolbarItem, INotifyPropertyChanged
Remarks
To create a custom main toolbar item, create a class that inherits IMainToolbarItem interface.
Properties
| Edit this page View SourceMediaQueries
Gets or sets media queries for the toolbar item.
An array of valid
media queries
which are used to determine the visibility of an item.
Internally, media queries are managed using the
Window.matchMedia()
API.
As per the W3C Spec, in many cases, media
queries require parentheses — for example, min-width: 480px
won't work, whereas (min-width: 480px)
will.
Declaration
[JsonProperty("mediaQueries", NullValueHandling = NullValueHandling.Ignore)]
public ObservableCollection<string> MediaQueries { get; }
Property Value
Type | Description |
---|---|
ObservableCollection<string> |
StyleClass
Gets or sets the custom style class name use for the toolbar item.
Declaration
[JsonProperty("class", NullValueHandling = NullValueHandling.Ignore)]
public string StyleClass { get; set; }
Property Value
Type | Description |
---|---|
string |
Methods
| Edit this page View SourceEquals(object)
Determines whether the specified object is equal to the current object.
Declaration
public override bool Equals(object o)
Parameters
Type | Name | Description |
---|---|---|
object | o |
Returns
Type | Description |
---|---|
bool | true if the specified object is equal to the current object; otherwise, false. |
Overrides
| Edit this page View SourceGetHashCode()
Serves as the default hash function.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
int | A hash code for the current object. |
Overrides
| Edit this page View SourceShouldSerializeMediaQueries()
Declaration
public bool ShouldSerializeMediaQueries()
Returns
Type | Description |
---|---|
bool |
ToJson()
Declaration
public string ToJson()
Returns
Type | Description |
---|---|
string |