Control Methods

Overview | Fields | This Package | All Packages

Control Methods

Constructors Description
Control Creates a Control object.

Methods Description
add Adds a child control to this control.

addOnClick Assigns a delegate to the click event.

addOnCreateHandle Assigns a delegate to the createHandle event.

addOnDestroyHandle Assigns a delegate to the destroyHandle event.

addOnDoubleClick Assigns a delegate to the doubleClick event.

addOnDragDrop Assigns a delegate to the dragDrop event.

addOnDragEnter Assigns a delegate to the dragEnter event.

addOnDragLeave Assigns a delegate to the dragLeave event.

addOnDragOver Assigns a delegate to the dragOver event.

addOnEnter Assigns a delegate to the enter event.

addOnGiveFeedback Assigns a delegate to the giveFeedback event.

addOnGotFocus Assigns a delegate to the gotFocus event.

addOnHelp Assigns a delegate to the help event.

addOnKeyDown Assigns a delegate to the keyDown event.

addOnKeyPress Assigns a delegate to the keyPress event.

addOnKeyUp Assigns a delegate to the keyUp event.

addOnLayout Assigns a delegate to the layout event.

addOnLeave Assigns a delegate to the leave event.

addOnLostFocus Assigns a delegate to the lostFocus event.

addOnMouseDown Assigns a delegate to the mouseDown event.

addOnMouseEnter Assigns a delegate to the mouseEnter event.

addOnMouseLeave Assigns a delegate to the mouseLeave event.

addOnMouseMove Assigns a delegate to the mouseMove event.

addOnMouseUp Assigns a delegate to the mouseUp event.

addOnMouseWheel Assigns a delegate to the mouseWheel event.

addOnMove Assigns a delegate to the move event.

addOnPaint Assigns a delegate to the paint event.

addOnQueryContinueDrag Assigns a delegate to the queryContinueDrag event.

addOnResize Assigns a delegate to the resize event.

assignParent Assigns a new parent control.

bringToFront Brings this control to the front of the z-order.

canFocus Retrieves a boolean value indicating whether this control can receive the focus.

canSelect Retrieves a boolean value indicating whether this control can be selected.

contains Retrieves a value indicating whether the specified control is a child of this control.

createControl Forces the creation of the control, including the creation of the control handle and any child controls.

createGraphics Creates a Graphics object that can be used to draw in the client area of the control.

createHandle Creates a handle for this control.

createWindowGraphics Creates a Graphics object that can be used to draw in the entire window of the control rather than just the client area of the control.

destroyHandle This method should be called only by the framework. Destroys the handle associated with this control.

dispose Frees all resources allocated for this control.

doDragDrop Begins a drag-and-drop operation.

finalize Terminates the control window and releases the window handle.

fireDragEvent Triggers a drag event.

fireKeyEvent Triggers a key event.

fireMouseEvent Triggers a mouse event.

focus Attempts to set the focus to this control and activate the form that contains this control, and returns a boolean value indicating whether the attempt succeeded.

fromChildHandle Returns the control that contains the specified handle.

fromHandle Returns the control that is currently associated with the specified handle.

getAcceptsChildren Retrieves a boolean value indicating whether this control can contain child controls.

getAllowDrop Retrieves a boolean value indicating whether this control can accept data that the user drags and drops into it.

getAnchor Retrieves a value indicating which edges of the control are anchored to the edges of its container.

getBackColor Retrieves the background color for this control.

getBottom Retrieves the distance between the bottom edge of the control and the top edge of its container's client area.

getBounds Retrieves the bounding rectangle for the control.

getBrush Retrieves the brush for this control.

getCapture Retrieves a boolean value indicating whether this control has captured the mouse.

getChildAtPoint Retrieves the child control that is located at the specified coordinates.

getClientRect Retrieves the rectangle that represents the client area of the control.

getClientSize Retrieves the height and width of the client area of the control.

getContextMenu Retrieves the shortcut menu (also known as a context menu) associated with this control.

getControl Retrieves the child control with the specified zero-based index within the parent's control array.

getControlCount Retrieves the number of child controls this control contains.

getControlIndex Retrieves the zero-based index of this control within the parent control array.

getControls Retrieves an array of the child controls contained in this control.

getCreated Retrieves a boolean value indicating whether the control has been created.

getCreateParams Retrieves the information used to create the handle for this control.

getCursor Retrieves the cursor that is displayed when the user moves the mouse pointer over this control.

getDisplayRect Retrieves the rectangle that represents the display area of the control.

getDock Retrieves a value indicating which edge of its container this control is docked to.

getEnabled Retrieves a boolean value indicating whether this control is enabled.

getFocused Retrieves a boolean value indicating whether the control has the focus.

getFont Retrieves the current font for this control, which is the font the control uses to draw its text.

getForeColor Retrieves the current foreground color for this control, which is the color the control uses to draw its text.

getForm Retrieves the form that this control is on.

getHandle Retrieves the window handle (HWND) that this control is bound to.

getHandleCreated Retrieves a boolean value indicating whether this control has a handle associated with it.

getHeight Retrieves the height of this control.

getInputChar Retrieves a boolean value indicating whether the control processes the specified character itself.

getInputKey Retrieves a boolean value indicating whether the control processes the specified keyboard input.

getInvokeRequired Determines whether the caller must call invoke when making method calls to this control.

getLeft Retrieves the distance between the left edge of the control and the left edge of its container's client area.

getLocation Retrieves coordinates of the upper-left corner of the control relative to the upper-left corner of its container's client area.

getMnemonic Retrieves a boolean value indicating whether the specified character is the mnemonic character in the specified string.

getModifierKeys Retrieves a value indicating the current state of the SHIFT, CTRL, and ALT keys.

getMouseButtons Retrieves a value indicating the current state of the left, right, and middle mouse buttons.

getMousePosition Retrieves the current position of the mouse in screen coordinates.

getNextControl Retrieves the control that follows or precedes the specified control in the tab order.

getPalette Retrieves the palette associated with this control.

getParent Retrieves the parent of this control.

getRecreatingHandle Retrieves a boolean value indicating whether the control is currently re-creating its handle.

getRegion Retrieves the region (the elliptical or polygonal area within a window) associated with this control.

getRight Retrieves the distance between the right edge of the control and the left edge of its container's client area.

getSize Retrieves the height and width of the control.

getStyle Retrieves the current value of the specified bit field in the control's style property.

getTabIndex Retrieves the tab order of this control within the parent form.

getTabList Retrieves all the child controls included in the tab order.

getTabStop Retrieves a boolean value indicating whether the user can give the focus to this control using the TAB key.

getText Retrieves the text associated with this control.

getTop Retrieves the distance between the top edge of the control and the top edge of its container's client area.

getTopLevel Retrieves a boolean value indicating whether this control is a top-level window (a window that has no parent window).

getTopLevelControl Retrieves the top-level control that contains this control.

getVisible Retrieves a boolean value indicating whether this control is visible.

getWidth Retrieves the width of this control.

hide Hides the control by setting the visible property to false.

invalidate Invalidates the specified part of the control (adds it to the control's update region, which is the area that will be repainted at the next paint operation), and causes a paint message to be sent to the control.

invoke Executes the specified delegate on the thread that created the control's handle and returns when the delegate has completed execution.

invokeAsync Executes the specified delegate on the thread that created the control's handle and returns immediately (because the delegate is invoked asynchronously).

onClick Triggers the click event.

onCreateHandle Triggers the createHandle event.

onDestroyHandle Triggers the destroyHandle event.

onDoubleClick Triggers the doubleClick event.

onDragDrop Triggers the dragDrop event.

onDragEnter Triggers the dragEnter event.

onDragLeave Triggers the dragLeave event.

onDragOver Triggers the dragOver event.

onEnter Triggers the enter event.

onEraseBackground Triggers the eraseBackground event.

onGiveFeedback Triggers the giveFeedback event.

onGotFocus Triggers the gotFocus event.

onHelp Triggers the help event.

onKeyDown Triggers the keyDown event.

onKeyPress Triggers the keyPress event.

onKeyUp Triggers the keyUp event.

onLayout Triggers the layout event.

onLeave Triggers the leave event.

onLostFocus Triggers the lostFocus event.

onMouseDown Triggers the mouseDown event.

onMouseEnter Triggers the mouseEnter event.

onMouseLeave Triggers the mouseLeave event.

onMouseMove Triggers the mouseMove event.

onMouseUp Triggers the mouseUp event.

onMouseWheel Triggers the mouseWheel event.

onMove Triggers the move event.

onPaint Triggers the paint event.

onQueryContinueDrag Triggers the queryContinueDrag event.

onResize Triggers the resize event.

performLayout Forces the control to apply layout logic to all its child controls.

pointToClient Converts the coordinates of a point from screen coordinates to client coordinates.

pointToScreen Converts the coordinates of a point from client coordinates to screen coordinates.

preProcessMessage This method is called by the application's message loop to preprocess input messages before they are dispatched.

processCmdKey Processes a command key.

processDialogChar Processes a dialog character, checking for mnemonics, and forwards the appropriate messages.

processDialogKey Processes a dialog key, checking for mnemonics, tabs, and arrows, and forwards the appropriate messages.

processKeyEvent Processes a key message and generates the appropriate control events.

processKeyMessage Processes a key message.

processKeyPreview Processes key preview messages.

processMnemonic Processes a mnemonic character.

propertyChanged This method is called by the control when any property changes.

recreateHandle Forces the re-creation of the handle for this control.

rectToClient Converts the coordinates of a rectangle from screen coordinates to client coordinates.

rectToScreen Converts the coordinates of a rectangle from client coordinates to screen coordinates.

reflectMessage Reflects the specified message to the control that is bound to the specified handle.

remove Removes the specified child control from this control.

removeOnClick Removes the delegate that is assigned to the click event.

removeOnCreateHandle Removes the delegate that is assigned to the createHandle event.

removeOnDestroyHandle Removes the delegate that is assigned to the destroyHandle event.

removeOnDoubleClick Removes the delegate that is assigned to the doubleClick event.

removeOnDragDrop Removes the delegate that is assigned to the dragDrop event.

removeOnDragEnter Removes the delegate that is assigned to the dragEnter event.

removeOnDragLeave Removes the delegate that is assigned to the dragLeave event.

removeOnDragOver Removes the delegate that is assigned to the dragOver event.

removeOnEnter Removes the delegate that is assigned to the enter event.

removeOnGiveFeedback Removes the delegate that is assigned to the giveFeedback event.

removeOnGotFocus Removes the delegate that is assigned to the gotFocus event.

removeOnHelp Removes the delegate that is assigned to the help event.

removeOnKeyDown Removes the delegate that is assigned to the keyDown event.

removeOnKeyPress Removes the delegate that is assigned to the keyPress event.

removeOnKeyUp Removes the delegate that is assigned to the keyUp event.

removeOnLayout Removes the delegate that is assigned to the layout event.

removeOnLeave Removes the delegate that is assigned to the leave event.

removeOnLostFocus Removes the delegate that is assigned to the lostFocus event.

removeOnMouseDown Removes the delegate that is assigned to the mouseDown event.

removeOnMouseEnter Removes the delegate that is assigned to the mouseEnter event.

removeOnMouseLeave Removes the delegate that is assigned to the mouseLeave event.

removeOnMouseMove Removes the delegate that is assigned to the mouseMove event.

removeOnMouseUp Removes the delegate that is assigned to the mouseUp event.

removeOnMouseWheel Removes the delegate that is assigned to the mouseWheel event.

removeOnMove Removes the delegate that is assigned to the move event.

removeOnPaint Removes the delegate that is assigned to the paint event.

removeOnQueryContinueDrag Removes the delegate that is assigned to the queryContinueDrag event.

removeOnResize Removes the delegate that is assigned to the resize event.

resetBackColor Resets the background color of the control to the parent's background color.

resetFont Resets the font for the control to the parent's font.

resetForeColor Resets the foreground color of the control to the parent's foreground color.

resumeLayout Resumes normal layout logic.

scale Scales the entire control and any child controls.

scaleCore Performs the work of scaling the entire control and any child controls.

select Activates this control.

selectNextControl Selects the control that follows or precedes the specified control in the tab order.

sendMessage Sends the specified Win32 message to this control.

sendToBack Sends this control to the back of the z-order.

setAllowDrop Sets a boolean value indicating whether this control can accept data that the user drags and drops into it.

setAnchor Sets a value indicating which edges of the control are anchored to the edges of its container.

setBackColor Sets the background color for this control.

setBounds Sets the bounding rectangle for the control.

setBoundsCore Performs the work of setting the bounds of this control.

setBrush Sets the brush for this control.

setCapture Sets a boolean value indicating whether this control has captured the mouse.

setClientSize Sets the height and width of the client area of the control.

setClientSizeCore Performs the work of setting the size of the client area of the control.

setContextMenu Sets the shortcut menu (also known as a context menu) associated with this control.

setControlIndex Sets the zero-based index of the specified child control within the parent's control array.

setControls Sets the array of the child controls contained in this control.

setCursor Sets the cursor that is displayed when the user moves the mouse pointer over this control.

setDock Sets a value indicating which edge of its container this control is docked to.

setEnabled Sets a boolean value indicating whether this control is enabled.

setFont Sets the font for this control, which is the font the control uses to draw its text.

setForeColor Sets the current foreground color for this control, which is the color the control uses to draw its text.

setHeight Sets the height of this control.

setLeft Sets the distance between the left edge of the control and the left edge of its container's client area.

setLocation Sets coordinates of the upper-left corner of the control relative to the upper-left corner of its container's client area.

setNewControls Performs the work of setting the array of the child controls contained in this control.

setParent Sets the parent for this control.

setRegion Sets the region (the elliptical or polygonal area within a window) associated with this control.

setSize Sets the height and width of the control.

setStyle Sets the value of the specified bit field in the control's style property.

setTabIndex Sets the tab order of this control within the parent form.

setTabStop Sets a boolean value indicating whether the user can give the focus to this control using the TAB key.

setText Sets the text associated with this control.

setTop Sets the distance between the top edge of the control and the top edge of its container's client area.

setTopLevel Sets a boolean value indicating whether this control is a top-level window (a window that has no parent window).

setVisible Sets a boolean value indicating whether this control is visible.

setWidth Sets the width of this control.

shouldPersistBackColor Retrieves a boolean value indicating whether the background color for the control has been explicitly set.

shouldPersistFont Retrieves a boolean value indicating whether the background color for the control has been explicitly set.

shouldPersistForeColor Retrieves a boolean value indicating whether the background color for the control has been explicitly set.

show Displays the control by setting the visible property to true.

suspendLayout Suspends the layout logic for the control.

update Forces the control to paint its update region (regions that have been marked as needing repainting).

updateBounds Updates the bounding rectangle of the control based on the handle the control is bound to.

updateStyles Forces styles to be reapplied to the handle without recreating the handle.

updateZOrder Updates this control's position within its parent's z-order.