C# Class GR.Win32.Window

Datei anzeigen Open project: alexhanh/Botting-Library Class Usage Examples

Public Methods

Method Description
AttachToCorner ( ScreenCorner corner ) : void

This method tries to set the position of the window so that it's fully visible but one of it's corners is attached to given parameter.

Capture ( ) : Bitmap
Capture ( Rectangle rect ) : Bitmap
CaptureScreen ( IntPtr hwnd, Rectangle rect ) : Bitmap
CaptureScreenNew ( IntPtr hwnd ) : Bitmap
ChildWindowFromPoint ( Point point, string class_name, Window begin_with ) : Window
Equals ( object obj ) : bool
FindChildWindow ( string text_begin ) : Window
FindChildWindow ( string class_name, string text_begin, Window begin_with ) : Window

Pass empty string to class_name to match all. Pass empty string to text_begin to match all. Pass null to begin_with to skip.

FindWindow ( string title_begin ) : Window
FindWindows ( string title_begin ) : GR.Win32.Window[]
Focus ( ) : void
ForegroundWindow ( ) : Window
GetHashCode ( ) : int
GetOpenWindowFromProcessID ( int process_id, string title_begins, string &matched_title ) : Window
GetOpenWindowsFromPID ( int processID ) : string>.IDictionary
GetOpenWindowsFromProcessID ( int process_id, string title_begins ) : List
GetOpenWindowsFromProcessID ( int process_id, string title_begins ) : GR.Win32.Window[]
GetText ( ) : string
GetWindowRect ( IntPtr hwnd ) : Rectangle
GetWindowText ( IntPtr hwnd ) : string
Hide ( ) : void
IsMinimized ( ) : bool
MakeVisible ( ) : void
Minimize ( ) : void
Resize ( Size size ) : void
Restore ( ) : void
SetForeground ( ) : void
SetPosition ( Point position ) : void
Window ( IntPtr window_handle ) : System

Private Methods

Method Description
EnumCallback ( IntPtr hwnd, int lParam ) : bool

Method Details

AttachToCorner() public method

This method tries to set the position of the window so that it's fully visible but one of it's corners is attached to given parameter.
public AttachToCorner ( ScreenCorner corner ) : void
corner ScreenCorner
return void

Capture() public method

public Capture ( ) : Bitmap
return System.Drawing.Bitmap

Capture() public method

public Capture ( Rectangle rect ) : Bitmap
rect System.Drawing.Rectangle
return System.Drawing.Bitmap

CaptureScreen() public static method

public static CaptureScreen ( IntPtr hwnd, Rectangle rect ) : Bitmap
hwnd System.IntPtr
rect System.Drawing.Rectangle
return System.Drawing.Bitmap

CaptureScreenNew() public static method

public static CaptureScreenNew ( IntPtr hwnd ) : Bitmap
hwnd System.IntPtr
return System.Drawing.Bitmap

ChildWindowFromPoint() public method

public ChildWindowFromPoint ( Point point, string class_name, Window begin_with ) : Window
point Point
class_name string
begin_with Window
return Window

Equals() public method

public Equals ( object obj ) : bool
obj object
return bool

FindChildWindow() public method

public FindChildWindow ( string text_begin ) : Window
text_begin string
return Window

FindChildWindow() public method

Pass empty string to class_name to match all. Pass empty string to text_begin to match all. Pass null to begin_with to skip.
public FindChildWindow ( string class_name, string text_begin, Window begin_with ) : Window
class_name string
text_begin string
begin_with Window
return Window

FindWindow() public static method

public static FindWindow ( string title_begin ) : Window
title_begin string
return Window

FindWindows() public static method

public static FindWindows ( string title_begin ) : GR.Win32.Window[]
title_begin string
return GR.Win32.Window[]

Focus() public method

public Focus ( ) : void
return void

ForegroundWindow() public static method

public static ForegroundWindow ( ) : Window
return Window

GetHashCode() public method

public GetHashCode ( ) : int
return int

GetOpenWindowFromProcessID() public static method

public static GetOpenWindowFromProcessID ( int process_id, string title_begins, string &matched_title ) : Window
process_id int
title_begins string
matched_title string
return Window

GetOpenWindowsFromPID() public static method

public static GetOpenWindowsFromPID ( int processID ) : string>.IDictionary
processID int
return string>.IDictionary

GetOpenWindowsFromProcessID() public static method

public static GetOpenWindowsFromProcessID ( int process_id, string title_begins ) : List
process_id int
title_begins string
return List

GetOpenWindowsFromProcessID() public static method

public static GetOpenWindowsFromProcessID ( int process_id, string title_begins ) : GR.Win32.Window[]
process_id int
title_begins string
return GR.Win32.Window[]

GetText() public method

public GetText ( ) : string
return string

GetWindowRect() public static method

public static GetWindowRect ( IntPtr hwnd ) : Rectangle
hwnd System.IntPtr
return System.Drawing.Rectangle

GetWindowText() public static method

public static GetWindowText ( IntPtr hwnd ) : string
hwnd System.IntPtr
return string

Hide() public method

public Hide ( ) : void
return void

IsMinimized() public method

public IsMinimized ( ) : bool
return bool

MakeVisible() public method

public MakeVisible ( ) : void
return void

Minimize() public method

public Minimize ( ) : void
return void

Resize() public method

public Resize ( Size size ) : void
size System.Drawing.Size
return void

Restore() public method

public Restore ( ) : void
return void

SetForeground() public method

public SetForeground ( ) : void
return void

SetPosition() public method

public SetPosition ( Point position ) : void
position Point
return void

Window() public method

public Window ( IntPtr window_handle ) : System
window_handle System.IntPtr
return System