C# Class OpenTK.NativeWindow

Instances of this class implement the OpenTK.INativeWindow interface on the current platform.
Inheritance: INativeWindow
Afficher le fichier Open project: andykorth/opentk Class Usage Examples

Private Properties

Свойство Type Description
OnClosedInternal void
OnClosingInternal void
OnDisposedInternal void
OnFocusedChangedInternal void
OnIconChangedInternal void
OnKeyPressInternal void
OnMouseEnterInternal void
OnMouseLeaveInternal void
OnMoveInternal void
OnResizeInternal void
OnTitleChangedInternal void
OnVisibleChangedInternal void
OnWindowBorderChangedInternal void
OnWindowStateChangedInternal void

Méthodes publiques

Méthode Description
Close ( ) : void

Closes the NativeWindow.

Dispose ( ) : void

Releases all non-managed resources belonging to this NativeWindow.

NativeWindow ( ) : System

Constructs a new NativeWindow with default attributes without enabling events.

NativeWindow ( int x, int y, int width, int height, string title, GameWindowFlags options, OpenTK.Graphics.GraphicsMode mode, DisplayDevice device ) : System

Constructs a new NativeWindow with the specified attributes.

NativeWindow ( int width, int height, string title, GameWindowFlags options, OpenTK.Graphics.GraphicsMode mode, DisplayDevice device ) : System

Constructs a new centered NativeWindow with the specified attributes.

PointToClient ( Point point ) : Point

Transforms the specified point from screen to client coordinates.

PointToScreen ( Point point ) : Point

Transforms the specified point from client to screen coordinates.

ProcessEvents ( ) : void

Processes operating system events until the NativeWindow becomes idle.

Méthodes protégées

Méthode Description
EnsureUndisposed ( ) : void

Ensures that this NativeWindow has not been disposed.

OnClosed ( EventArgs e ) : void

Called when the NativeWindow has closed.

OnClosing ( CancelEventArgs e ) : void

Called when the NativeWindow is about to close.

OnDisposed ( EventArgs e ) : void

Called when the NativeWindow is disposed.

OnFocusedChanged ( EventArgs e ) : void

Called when the OpenTK.INativeWindow.Focused property of the NativeWindow has changed.

OnIconChanged ( EventArgs e ) : void

Called when the OpenTK.INativeWindow.Icon property of the NativeWindow has changed.

OnKeyDown ( KeyboardKeyEventArgs e ) : void

Occurs whenever a keybord key is pressed.

OnKeyPress ( KeyPressEventArgs e ) : void

Called when a character is typed.

OnKeyUp ( KeyboardKeyEventArgs e ) : void

Called when a keybord key is released.

OnMouseEnter ( EventArgs e ) : void

Called whenever the mouse cursor reenters the window Bounds.

OnMouseLeave ( EventArgs e ) : void

Called whenever the mouse cursor leaves the window Bounds.

OnMove ( EventArgs e ) : void

Called when the NativeWindow is moved.

OnResize ( EventArgs e ) : void

Called when the NativeWindow is resized.

OnTitleChanged ( EventArgs e ) : void

Called when the OpenTK.INativeWindow.Title property of the NativeWindow has changed.

OnVisibleChanged ( EventArgs e ) : void

Called when the OpenTK.INativeWindow.Visible property of the NativeWindow has changed.

OnWindowBorderChanged ( EventArgs e ) : void

Called when the WindowBorder of this NativeWindow has changed.

OnWindowStateChanged ( EventArgs e ) : void

Called when the WindowState of this NativeWindow has changed.

ProcessEvents ( bool retainEvents ) : void

Processes operating system events until the NativeWindow becomes idle.

Private Methods

Méthode Description
OnClosedInternal ( object sender, EventArgs e ) : void
OnClosingInternal ( object sender, CancelEventArgs e ) : void
OnDisposedInternal ( object sender, EventArgs e ) : void
OnFocusedChangedInternal ( object sender, EventArgs e ) : void
OnIconChangedInternal ( object sender, EventArgs e ) : void
OnKeyPressInternal ( object sender, KeyPressEventArgs e ) : void
OnMouseEnterInternal ( object sender, EventArgs e ) : void
OnMouseLeaveInternal ( object sender, EventArgs e ) : void
OnMoveInternal ( object sender, EventArgs e ) : void
OnResizeInternal ( object sender, EventArgs e ) : void
OnTitleChangedInternal ( object sender, EventArgs e ) : void
OnVisibleChangedInternal ( object sender, EventArgs e ) : void
OnWindowBorderChangedInternal ( object sender, EventArgs e ) : void
OnWindowStateChangedInternal ( object sender, EventArgs e ) : void

Method Details

Close() public méthode

Closes the NativeWindow.
public Close ( ) : void
Résultat void

Dispose() public méthode

Releases all non-managed resources belonging to this NativeWindow.
public Dispose ( ) : void
Résultat void

EnsureUndisposed() protected méthode

Ensures that this NativeWindow has not been disposed.
/// If this NativeWindow has been disposed. ///
protected EnsureUndisposed ( ) : void
Résultat void

NativeWindow() public méthode

Constructs a new NativeWindow with default attributes without enabling events.
public NativeWindow ( ) : System
Résultat System

NativeWindow() public méthode

Constructs a new NativeWindow with the specified attributes.
If width or height is less than 1. If mode or device is null.
public NativeWindow ( int x, int y, int width, int height, string title, GameWindowFlags options, OpenTK.Graphics.GraphicsMode mode, DisplayDevice device ) : System
x int Horizontal screen space coordinate of the NativeWindow's origin.
y int Vertical screen space coordinate of the NativeWindow's origin.
width int The width of the NativeWindow in pixels.
height int The height of the NativeWindow in pixels.
title string The title of the NativeWindow.
options GameWindowFlags GameWindow options specifying window appearance and behavior.
mode OpenTK.Graphics.GraphicsMode The OpenTK.Graphics.GraphicsMode of the NativeWindow.
device DisplayDevice The OpenTK.Graphics.DisplayDevice to construct the NativeWindow in.
Résultat System

NativeWindow() public méthode

Constructs a new centered NativeWindow with the specified attributes.
If width or height is less than 1. If mode or device is null.
public NativeWindow ( int width, int height, string title, GameWindowFlags options, OpenTK.Graphics.GraphicsMode mode, DisplayDevice device ) : System
width int The width of the NativeWindow in pixels.
height int The height of the NativeWindow in pixels.
title string The title of the NativeWindow.
options GameWindowFlags GameWindow options specifying window appearance and behavior.
mode OpenTK.Graphics.GraphicsMode The OpenTK.Graphics.GraphicsMode of the NativeWindow.
device DisplayDevice The OpenTK.Graphics.DisplayDevice to construct the NativeWindow in.
Résultat System

OnClosed() protected méthode

Called when the NativeWindow has closed.
protected OnClosed ( EventArgs e ) : void
e System.EventArgs Not used.
Résultat void

OnClosing() protected méthode

Called when the NativeWindow is about to close.
protected OnClosing ( CancelEventArgs e ) : void
e CancelEventArgs /// The for this event. /// Set e.Cancel to true in order to stop the NativeWindow from closing.
Résultat void

OnDisposed() protected méthode

Called when the NativeWindow is disposed.
protected OnDisposed ( EventArgs e ) : void
e System.EventArgs Not used.
Résultat void

OnFocusedChanged() protected méthode

Called when the OpenTK.INativeWindow.Focused property of the NativeWindow has changed.
protected OnFocusedChanged ( EventArgs e ) : void
e System.EventArgs Not used.
Résultat void

OnIconChanged() protected méthode

Called when the OpenTK.INativeWindow.Icon property of the NativeWindow has changed.
protected OnIconChanged ( EventArgs e ) : void
e System.EventArgs Not used.
Résultat void

OnKeyDown() protected méthode

Occurs whenever a keybord key is pressed.
protected OnKeyDown ( KeyboardKeyEventArgs e ) : void
e OpenTK.Input.KeyboardKeyEventArgs
Résultat void

OnKeyPress() protected méthode

Called when a character is typed.
protected OnKeyPress ( KeyPressEventArgs e ) : void
e KeyPressEventArgs The for this event.
Résultat void

OnKeyUp() protected méthode

Called when a keybord key is released.
protected OnKeyUp ( KeyboardKeyEventArgs e ) : void
e OpenTK.Input.KeyboardKeyEventArgs The for this event.
Résultat void

OnMouseEnter() protected méthode

Called whenever the mouse cursor reenters the window Bounds.
protected OnMouseEnter ( EventArgs e ) : void
e System.EventArgs Not used.
Résultat void

OnMouseLeave() protected méthode

Called whenever the mouse cursor leaves the window Bounds.
protected OnMouseLeave ( EventArgs e ) : void
e System.EventArgs Not used.
Résultat void

OnMove() protected méthode

Called when the NativeWindow is moved.
protected OnMove ( EventArgs e ) : void
e System.EventArgs Not used.
Résultat void

OnResize() protected méthode

Called when the NativeWindow is resized.
protected OnResize ( EventArgs e ) : void
e System.EventArgs Not used.
Résultat void

OnTitleChanged() protected méthode

Called when the OpenTK.INativeWindow.Title property of the NativeWindow has changed.
protected OnTitleChanged ( EventArgs e ) : void
e System.EventArgs Not used.
Résultat void

OnVisibleChanged() protected méthode

Called when the OpenTK.INativeWindow.Visible property of the NativeWindow has changed.
protected OnVisibleChanged ( EventArgs e ) : void
e EventArgs Not used.
Résultat void

OnWindowBorderChanged() protected méthode

Called when the WindowBorder of this NativeWindow has changed.
protected OnWindowBorderChanged ( EventArgs e ) : void
e EventArgs Not used.
Résultat void

OnWindowStateChanged() protected méthode

Called when the WindowState of this NativeWindow has changed.
protected OnWindowStateChanged ( EventArgs e ) : void
e EventArgs Not used.
Résultat void

PointToClient() public méthode

Transforms the specified point from screen to client coordinates.
public PointToClient ( Point point ) : Point
point Point /// A to transform. ///
Résultat Point

PointToScreen() public méthode

Transforms the specified point from client to screen coordinates.
public PointToScreen ( Point point ) : Point
point Point /// A to transform. ///
Résultat Point

ProcessEvents() public méthode

Processes operating system events until the NativeWindow becomes idle.
public ProcessEvents ( ) : void
Résultat void

ProcessEvents() protected méthode

Processes operating system events until the NativeWindow becomes idle.
protected ProcessEvents ( bool retainEvents ) : void
retainEvents bool If true, the state of underlying system event propagation will be preserved, otherwise event propagation will be enabled if it has not been already.
Résultat void