C# Class Patagames.Pdf.Net.Controls.Wpf.ToolBars.PdfToolBarZoomEx

Provides a container for Windows toolbar objects with predefined functionality for zooming
Inheritance: PdfToolBar
Afficher le fichier Open project: Patagames/Pdf.Wpf

Méthodes protégées

Méthode Description
CalcCurrentZoomLevel ( ) : void

Calculate zoom level for current Zoom and store it in internal field

InitializeButtons ( ) : void

Create all buttons and add its into toolbar. Override this method to create custom buttons

OnActualSizeClick ( System.Windows.Controls.MenuItem item ) : void

Occurs when the Actual Size item is clicked

OnFitHeightClick ( System.Windows.Controls.MenuItem item ) : void

Occurs when the Fit To Height item is clicked

OnFitPageClick ( System.Windows.Controls.MenuItem item ) : void

Occurs when the Fit To Page item is clicked

OnFitWidthClick ( System.Windows.Controls.MenuItem item ) : void

Occurs when the Fit To Width item is clicked

OnPdfViewerChanging ( PdfViewer oldValue, PdfViewer newValue ) : void

Called when the current PdfViewer control associated with the ToolBar is changing.

OnPropertyChanged ( System.Windows.DependencyPropertyChangedEventArgs e ) : void

Invoked whenever the effective value of any dependency property on this System.Windows.FrameworkElement has been updated. The specific dependency property that changed is reported in the arguments parameter. Overrides System.Windows.DependencyObject.OnPropertyChanged(System.Windows.DependencyPropertyChangedEventArgs).

OnToolBarOrientationChanged ( ) : void

Raises the LayoutCompleted event.

OnTrackBarValueChanged ( System.Windows.Controls.Slider item ) : void

Occurs when the Value property of a track bar changes, either by movement of the scroll box or by manipulation in code.

OnZoomExInClick ( System.Windows.Controls.Button item ) : void

Occurs when the Zoom In button is clicked

OnZoomExOutClick ( System.Windows.Controls.Button item ) : void

Occurs when the Zoom Out button is clicked

OnZoomLevelClick ( System.Windows.Controls.Button item, double zoom ) : void

Occurs when the any item with zoom level clicked in ZoomDropDown button

SetZoom ( double zoom ) : void

Sets specified zoom for Pdf document

SetZoom ( int zoomIndex ) : void

Sets specified zoom level for Pdf document

UpdateButtons ( ) : void

Called when the ToolBar's items need to change its states

Private Methods

Méthode Description
CreateTrackBar ( ) : System.Windows.Controls.Slider
CreateZoomDropDown ( ) : System.Windows.Controls.Button
PdfViewer_SomethingChanged ( object sender, EventArgs e ) : void
SubscribePdfViewEvents ( PdfViewer newValue ) : void
TrackBar_ValueChanged ( object sender, EventArgs e ) : void
UnsubscribePdfViewEvents ( PdfViewer oldValue ) : void
ZoomLevel_ButtonClick ( object sender, EventArgs e ) : void
ZoomLevel_Click ( object sender, EventArgs e ) : void
ZoomLevel_DropDownOpening ( object sender, EventArgs e ) : void
btn_ActualSizeClick ( object sender, System e ) : void
btn_FitHeightClick ( object sender, System e ) : void
btn_FitPageClick ( object sender, System e ) : void
btn_FitWidthClick ( object sender, System e ) : void
btn_ZoomExInClick ( object sender, System e ) : void
btn_ZoomExOutClick ( object sender, System e ) : void

Method Details

CalcCurrentZoomLevel() protected méthode

Calculate zoom level for current Zoom and store it in internal field
protected CalcCurrentZoomLevel ( ) : void
Résultat void

InitializeButtons() protected méthode

Create all buttons and add its into toolbar. Override this method to create custom buttons
protected InitializeButtons ( ) : void
Résultat void

OnActualSizeClick() protected méthode

Occurs when the Actual Size item is clicked
protected OnActualSizeClick ( System.Windows.Controls.MenuItem item ) : void
item System.Windows.Controls.MenuItem The item that has been clicked
Résultat void

OnFitHeightClick() protected méthode

Occurs when the Fit To Height item is clicked
protected OnFitHeightClick ( System.Windows.Controls.MenuItem item ) : void
item System.Windows.Controls.MenuItem The item that has been clicked
Résultat void

OnFitPageClick() protected méthode

Occurs when the Fit To Page item is clicked
protected OnFitPageClick ( System.Windows.Controls.MenuItem item ) : void
item System.Windows.Controls.MenuItem The item that has been clicked
Résultat void

OnFitWidthClick() protected méthode

Occurs when the Fit To Width item is clicked
protected OnFitWidthClick ( System.Windows.Controls.MenuItem item ) : void
item System.Windows.Controls.MenuItem The item that has been clicked
Résultat void

OnPdfViewerChanging() protected méthode

Called when the current PdfViewer control associated with the ToolBar is changing.
protected OnPdfViewerChanging ( PdfViewer oldValue, PdfViewer newValue ) : void
oldValue PdfViewer PdfViewer control of which was associated with the ToolBar.
newValue PdfViewer PdfViewer control of which will be associated with the ToolBar.
Résultat void

OnPropertyChanged() protected méthode

Invoked whenever the effective value of any dependency property on this System.Windows.FrameworkElement has been updated. The specific dependency property that changed is reported in the arguments parameter. Overrides System.Windows.DependencyObject.OnPropertyChanged(System.Windows.DependencyPropertyChangedEventArgs).
protected OnPropertyChanged ( System.Windows.DependencyPropertyChangedEventArgs e ) : void
e System.Windows.DependencyPropertyChangedEventArgs The event data that describes the property that changed, as well as old and new values
Résultat void

OnToolBarOrientationChanged() protected méthode

Raises the LayoutCompleted event.
protected OnToolBarOrientationChanged ( ) : void
Résultat void

OnTrackBarValueChanged() protected méthode

Occurs when the Value property of a track bar changes, either by movement of the scroll box or by manipulation in code.
protected OnTrackBarValueChanged ( System.Windows.Controls.Slider item ) : void
item System.Windows.Controls.Slider The item that has been clicked
Résultat void

OnZoomExInClick() protected méthode

Occurs when the Zoom In button is clicked
protected OnZoomExInClick ( System.Windows.Controls.Button item ) : void
item System.Windows.Controls.Button The item that has been clicked
Résultat void

OnZoomExOutClick() protected méthode

Occurs when the Zoom Out button is clicked
protected OnZoomExOutClick ( System.Windows.Controls.Button item ) : void
item System.Windows.Controls.Button The item that has been clicked
Résultat void

OnZoomLevelClick() protected méthode

Occurs when the any item with zoom level clicked in ZoomDropDown button
protected OnZoomLevelClick ( System.Windows.Controls.Button item, double zoom ) : void
item System.Windows.Controls.Button The item that has been clicked
zoom double The zoom value of item that was clicked
Résultat void

SetZoom() protected méthode

Sets specified zoom for Pdf document
protected SetZoom ( double zoom ) : void
zoom double zoom value
Résultat void

SetZoom() protected méthode

Sets specified zoom level for Pdf document
protected SetZoom ( int zoomIndex ) : void
zoomIndex int Index of the zoom in ZoomLevel
Résultat void

UpdateButtons() protected méthode

Called when the ToolBar's items need to change its states
protected UpdateButtons ( ) : void
Résultat void