pub struct StandardKey(/* private fields */);
Expand description

This enum represent standard key bindings. They can be used to assign platform dependent keyboard shortcuts to a QAction.

C++ enum: QKeySequence::StandardKey.

C++ documentation:

This enum represent standard key bindings. They can be used to assign platform dependent keyboard shortcuts to a QAction.

Note that the key bindings are platform dependent. The currently bound shortcuts can be queried using keyBindings().

This enum was introduced or modified in Qt 4.2.

Implementations§

source§

impl StandardKey

source

pub fn to_int(&self) -> c_int

source§

impl StandardKey

source

pub const UnknownKey: StandardKey = _

Unbound key. (C++ enum variant: UnknownKey = 0)

source

pub const HelpContents: StandardKey = _

Open help contents. (C++ enum variant: HelpContents = 1)

source

pub const WhatsThis: StandardKey = _

Activate “what’s this”. (C++ enum variant: WhatsThis = 2)

source

pub const Open: StandardKey = _

Open document. (C++ enum variant: Open = 3)

source

pub const Close: StandardKey = _

Close document/tab. (C++ enum variant: Close = 4)

source

pub const Save: StandardKey = _

Save document. (C++ enum variant: Save = 5)

source

pub const New: StandardKey = _

Create new document. (C++ enum variant: New = 6)

source

pub const Delete: StandardKey = _

Delete. (C++ enum variant: Delete = 7)

source

pub const Cut: StandardKey = _

Cut. (C++ enum variant: Cut = 8)

source

pub const Copy: StandardKey = _

Copy. (C++ enum variant: Copy = 9)

source

pub const Paste: StandardKey = _

Paste. (C++ enum variant: Paste = 10)

source

pub const Undo: StandardKey = _

Undo. (C++ enum variant: Undo = 11)

source

pub const Redo: StandardKey = _

Redo. (C++ enum variant: Redo = 12)

source

pub const Back: StandardKey = _

Navigate back. (C++ enum variant: Back = 13)

source

pub const Forward: StandardKey = _

Navigate forward. (C++ enum variant: Forward = 14)

source

pub const Refresh: StandardKey = _

Refresh or reload current document. (C++ enum variant: Refresh = 15)

source

pub const ZoomIn: StandardKey = _

Zoom in. (C++ enum variant: ZoomIn = 16)

source

pub const ZoomOut: StandardKey = _

Zoom out. (C++ enum variant: ZoomOut = 17)

source

pub const Print: StandardKey = _

Print document. (C++ enum variant: Print = 18)

source

pub const AddTab: StandardKey = _

Add new tab. (C++ enum variant: AddTab = 19)

source

pub const NextChild: StandardKey = _

Navigate to next tab or child window. (C++ enum variant: NextChild = 20)

source

pub const PreviousChild: StandardKey = _

Navigate to previous tab or child window. (C++ enum variant: PreviousChild = 21)

source

pub const Find: StandardKey = _

Find in document. (C++ enum variant: Find = 22)

source

pub const FindNext: StandardKey = _

Find next result. (C++ enum variant: FindNext = 23)

source

pub const FindPrevious: StandardKey = _

Find previous result. (C++ enum variant: FindPrevious = 24)

source

pub const Replace: StandardKey = _

Find and replace. (C++ enum variant: Replace = 25)

source

pub const SelectAll: StandardKey = _

Select all text. (C++ enum variant: SelectAll = 26)

source

pub const Bold: StandardKey = _

Bold text. (C++ enum variant: Bold = 27)

source

pub const Italic: StandardKey = _

Italic text. (C++ enum variant: Italic = 28)

source

pub const Underline: StandardKey = _

Underline text. (C++ enum variant: Underline = 29)

source

pub const MoveToNextChar: StandardKey = _

Move cursor to next character. (C++ enum variant: MoveToNextChar = 30)

source

pub const MoveToPreviousChar: StandardKey = _

Move cursor to previous character. (C++ enum variant: MoveToPreviousChar = 31)

source

pub const MoveToNextWord: StandardKey = _

Move cursor to next word. (C++ enum variant: MoveToNextWord = 32)

source

pub const MoveToPreviousWord: StandardKey = _

Move cursor to previous word. (C++ enum variant: MoveToPreviousWord = 33)

source

pub const MoveToNextLine: StandardKey = _

Move cursor to next line. (C++ enum variant: MoveToNextLine = 34)

source

pub const MoveToPreviousLine: StandardKey = _

Move cursor to previous line. (C++ enum variant: MoveToPreviousLine = 35)

source

pub const MoveToNextPage: StandardKey = _

Move cursor to next page. (C++ enum variant: MoveToNextPage = 36)

source

pub const MoveToPreviousPage: StandardKey = _

Move cursor to previous page. (C++ enum variant: MoveToPreviousPage = 37)

source

pub const MoveToStartOfLine: StandardKey = _

Move cursor to start of line. (C++ enum variant: MoveToStartOfLine = 38)

source

pub const MoveToEndOfLine: StandardKey = _

Move cursor to end of line. (C++ enum variant: MoveToEndOfLine = 39)

source

pub const MoveToStartOfBlock: StandardKey = _

Move cursor to start of a block. This shortcut is only used on macOS. (C++ enum variant: MoveToStartOfBlock = 40)

source

pub const MoveToEndOfBlock: StandardKey = _

Move cursor to end of block. This shortcut is only used on the macOS. (C++ enum variant: MoveToEndOfBlock = 41)

source

pub const MoveToStartOfDocument: StandardKey = _

Move cursor to start of document. (C++ enum variant: MoveToStartOfDocument = 42)

source

pub const MoveToEndOfDocument: StandardKey = _

Move cursor to end of document. (C++ enum variant: MoveToEndOfDocument = 43)

source

pub const SelectNextChar: StandardKey = _

Extend selection to next character. (C++ enum variant: SelectNextChar = 44)

source

pub const SelectPreviousChar: StandardKey = _

Extend selection to previous character. (C++ enum variant: SelectPreviousChar = 45)

source

pub const SelectNextWord: StandardKey = _

Extend selection to next word. (C++ enum variant: SelectNextWord = 46)

source

pub const SelectPreviousWord: StandardKey = _

Extend selection to previous word. (C++ enum variant: SelectPreviousWord = 47)

source

pub const SelectNextLine: StandardKey = _

Extend selection to next line. (C++ enum variant: SelectNextLine = 48)

source

pub const SelectPreviousLine: StandardKey = _

Extend selection to previous line. (C++ enum variant: SelectPreviousLine = 49)

source

pub const SelectNextPage: StandardKey = _

Extend selection to next page. (C++ enum variant: SelectNextPage = 50)

source

pub const SelectPreviousPage: StandardKey = _

Extend selection to previous page. (C++ enum variant: SelectPreviousPage = 51)

source

pub const SelectStartOfLine: StandardKey = _

Extend selection to start of line. (C++ enum variant: SelectStartOfLine = 52)

source

pub const SelectEndOfLine: StandardKey = _

Extend selection to end of line. (C++ enum variant: SelectEndOfLine = 53)

source

pub const SelectStartOfBlock: StandardKey = _

Extend selection to the start of a text block. This shortcut is only used on macOS. (C++ enum variant: SelectStartOfBlock = 54)

source

pub const SelectEndOfBlock: StandardKey = _

Extend selection to the end of a text block. This shortcut is only used on macOS. (C++ enum variant: SelectEndOfBlock = 55)

source

pub const SelectStartOfDocument: StandardKey = _

Extend selection to start of document. (C++ enum variant: SelectStartOfDocument = 56)

source

pub const SelectEndOfDocument: StandardKey = _

Extend selection to end of document. (C++ enum variant: SelectEndOfDocument = 57)

source

pub const DeleteStartOfWord: StandardKey = _

Delete the beginning of a word up to the cursor. (C++ enum variant: DeleteStartOfWord = 58)

source

pub const DeleteEndOfWord: StandardKey = _

Delete word from the end of the cursor. (C++ enum variant: DeleteEndOfWord = 59)

source

pub const DeleteEndOfLine: StandardKey = _

Delete end of line. (C++ enum variant: DeleteEndOfLine = 60)

source

pub const InsertParagraphSeparator: StandardKey = _

Insert a new paragraph. (C++ enum variant: InsertParagraphSeparator = 61)

source

pub const InsertLineSeparator: StandardKey = _

Insert a new line. (C++ enum variant: InsertLineSeparator = 62)

source

pub const SaveAs: StandardKey = _

Save document after prompting the user for a file name. (C++ enum variant: SaveAs = 63)

source

pub const Preferences: StandardKey = _

Open the preferences dialog. (C++ enum variant: Preferences = 64)

source

pub const Quit: StandardKey = _

Quit the application. (C++ enum variant: Quit = 65)

source

pub const FullScreen: StandardKey = _

Toggle the window state to/from full screen. (C++ enum variant: FullScreen = 66)

source

pub const Deselect: StandardKey = _

Deselect text. Since 5.1 (C++ enum variant: Deselect = 67)

source

pub const DeleteCompleteLine: StandardKey = _

Delete the entire line. (C++ enum variant: DeleteCompleteLine = 68)

source

pub const Backspace: StandardKey = _

Delete previous character. (C++ enum variant: Backspace = 69)

source

pub const Cancel: StandardKey = _

Cancel the current operation. (C++ enum variant: Cancel = 70)

Trait Implementations§

source§

impl Clone for StandardKey

source§

fn clone(&self) -> StandardKey

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for StandardKey

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<StandardKey> for c_int

source§

fn from(value: StandardKey) -> Self

Converts to this type from the input type.
source§

impl From<i32> for StandardKey

source§

fn from(value: c_int) -> Self

Converts to this type from the input type.
source§

impl PartialEq<StandardKey> for QKeyEvent

source§

fn eq(&self, key: &StandardKey) -> bool

Returns true if page layout lhs is equal to page layout rhs, i.e. if all the attributes are exactly equal.

Calls C++ function: bool operator==(QKeyEvent* e, QKeySequence::StandardKey key).

Warning: no exact match found in C++ documentation. Below is the C++ documentation for bool operator==(const QPageLayout &lhs, const QPageLayout &rhs):

Returns true if page layout lhs is equal to page layout rhs, i.e. if all the attributes are exactly equal.

Note that this is a strict equality, especially for page size where the QPageSize ID, name and size must exactly match, and the margins where the units must match.

See also QPageLayout::isEquivalentTo().

1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialEq for StandardKey

source§

fn eq(&self, other: &StandardKey) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Copy for StandardKey

source§

impl Eq for StandardKey

source§

impl StructuralEq for StandardKey

source§

impl StructuralPartialEq for StandardKey

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T, U> CastInto<U> for T
where U: CastFrom<T>,

source§

unsafe fn cast_into(self) -> U

Performs the conversion. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> StaticUpcast<T> for T

source§

unsafe fn static_upcast(ptr: Ptr<T>) -> Ptr<T>

Convert type of a const pointer. Read more
source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

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

fn clone_into(&self, target: &mut T)

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

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.