Struct winsafe::HDC[][src]

#[repr(C)]
pub struct HDC { /* fields omitted */ }
Expand description

Handle to a device context.

Implementations

The null, invalid handle.

This constant is common to all handle types.

Creates a new handle instance by wrapping a pointer.

This method is common to all handle types.

Consumes the handle returning the underlying raw pointer.

This method is common to all handle types.

Tells if the handle is invalid (null).

This method is common to all handle types.

Consumes the handle into an option, which is None if the handle pointer is null.

This method is common to all handle types.

AborthPath method.

AngleArc method.

BeginPath method.

BitBlt method.

CancelDC method.

Chord method.

CreateCompatibleBitmap method.

Note: Must be paired with an HBITMAP::DeleteObject call.

CreateCompatibleDC method.

Note: Must be paired with an HDC::DeleteDC call.

DeleteDC method.

EndPath method.

EnumDisplayMonitors method.

Examples

use winsafe::{HDC, HMONITOR, RECT};

let my_hdc: HDC; // initialized somewhere

my_hdc.EnumDisplayMonitors(|hmon: HMONITOR, hdc: HDC, rc: &RECT| -> bool {
    println!("HMONITOR: {}, ", hmon);
    true
})?;

FillPath method.

FillRect method.

GetDCPenColor method.

GetDeviceCaps method.

GetTextColor method.

LineTo method.

MoveToEx method.

PatBlt method.

PathToRegion method.

Note: Must be paired with an HRGN::DeleteObject call.

Pie method.

PolyBezier method.

PolyBezierTo method.

Polyline method.

PolylineTo method.

PtVisible method.

Rectangle method.

RestoreDC method.

RoundRect method.

SaveDC method.

SelectObject method for HBITMAP.

SelectObject method for HBRUSH.

SelectObject method for HFONT.

SelectObject method for HPEN.

SelectObject method for HRGN.

SetBkMode method.

SetTextAlign method.

SetTextColor method.

StrokePath method.

TextOut method.

WidenPath method.

Trait Implementations

Formats the value using the given formatter.

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Formats the value using the given formatter. Read more

Formats the value using the given formatter.

Formats the value using the given formatter.

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Formats the value using the given formatter.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

Converts the given value to a String. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.