Klasa ShapeContainer
Stanowi kontener dla LineShape, OvalShape, RectangleShape formantów i dla wszelkich innych kontroli, która wynika z Shape.
Hierarchia dziedziczenia
Object
MarshalByRefObject
Component
Control
ScrollableControl
ContainerControl
UserControl
Microsoft.VisualBasic.PowerPacks.ShapeContainer
Przestrzeń nazw: Microsoft.VisualBasic.PowerPacks
Zestaw: Microsoft.VisualBasic.PowerPacks.Vs (w Microsoft.VisualBasic.PowerPacks.Vs.dll)
Składnia
'Deklaracja
<BrowsableAttribute(False)> _
Public NotInheritable Class ShapeContainer _
Inherits UserControl
[BrowsableAttribute(false)]
public sealed class ShapeContainer : UserControl
[BrowsableAttribute(false)]
public ref class ShapeContainer sealed : public UserControl
[<Sealed>]
[<BrowsableAttribute(false)>]
type ShapeContainer =
class
inherit UserControl
end
public final class ShapeContainer extends UserControl
Typ ShapeContainer uwidacznia następujące elementy członkowskie.
Konstruktorzy
Nazwa | Opis | |
---|---|---|
ShapeContainer | Inicjuje nowe wystąpienie ShapeContainer klasy. |
Początek
Właściwości
Nazwa | Opis | |
---|---|---|
AccessibilityObject | Gets the AccessibleObject assigned to the control. (Odziedziczone z Control). | |
AccessibleDefaultActionDescription | Gets or sets the default action description of the control for use by accessibility client applications. (Odziedziczone z Control). | |
AccessibleDescription | Gets or sets the description of the control used by accessibility client applications. (Odziedziczone z Control). | |
AccessibleName | Gets or sets the name of the control used by accessibility client applications. (Odziedziczone z Control). | |
AccessibleRole | Zwraca lub ustawia dostępne rolę ShapeContainer. | |
ActiveControl | Gets or sets the active control on the container control. (Odziedziczone z ContainerControl). | |
AllowDrop | Gets or sets a value indicating whether the control can accept data that the user drags onto it. (Odziedziczone z Control). | |
Anchor | Gets or sets the edges of the container to which a control is bound and determines how a control is resized with its parent. (Odziedziczone z Control). | |
AutoScaleDimensions | Gets or sets the dimensions that the control was designed to. (Odziedziczone z ContainerControl). | |
AutoScaleMode | Gets or sets the automatic scaling mode of the control. (Odziedziczone z ContainerControl). | |
AutoScroll | Pobiera lub ustawia wartość wskazującą, czy kontener umożliwia użytkownikowi przewijać się wszelkim kontrolom umieszczony poza jego granice widoczne. (Odziedziczone z ScrollableControl). | |
AutoScrollMargin | Pobiera lub ustawia rozmiar marginesu przewijania automatycznego. (Odziedziczone z ScrollableControl). | |
AutoScrollMinSize | Pobiera lub ustawia minimalny rozmiar przewijania automatycznego. (Odziedziczone z ScrollableControl). | |
AutoScrollOffset | Gets or sets where this control is scrolled to in ScrollControlIntoView. (Odziedziczone z Control). | |
AutoScrollPosition | Pobiera lub Ustawia lokalizację pozycji przewijania automatycznego. (Odziedziczone z ScrollableControl). | |
AutoSize | This property is not relevant for this class. (Odziedziczone z UserControl). | |
AutoSizeMode | Gets or sets how the control will resize itself. (Odziedziczone z UserControl). | |
AutoValidate | Gets or sets how the control performs validation when the user changes focus to another control. (Odziedziczone z UserControl). | |
BackColor | Gets or sets the background color for the control. (Odziedziczone z Control). | |
BackgroundImage | Gets or sets the background image displayed in the control. (Odziedziczone z Control). | |
BackgroundImageLayout | Gets or sets the background image layout as defined in the ImageLayout enumeration. (Odziedziczone z Control). | |
BindingContext | Gets or sets the BindingContext for the control. (Odziedziczone z ContainerControl). | |
BorderStyle | Gets or sets the border style of the user control. (Odziedziczone z UserControl). | |
Bottom | Gets the distance, in pixels, between the bottom edge of the control and the top edge of its container's client area. (Odziedziczone z Control). | |
Bounds | Gets or sets the size and location of the control including its nonclient elements, in pixels, relative to the parent control. (Odziedziczone z Control). | |
CanFocus | Gets a value indicating whether the control can receive focus. (Odziedziczone z Control). | |
CanSelect | Gets a value indicating whether the control can be selected. (Odziedziczone z Control). | |
Capture | Gets or sets a value indicating whether the control has captured the mouse. (Odziedziczone z Control). | |
CausesValidation | Gets or sets a value indicating whether the control causes validation to be performed on any controls that require validation when it receives focus. (Odziedziczone z Control). | |
ClientRectangle | Gets the rectangle that represents the client area of the control. (Odziedziczone z Control). | |
ClientSize | Gets or sets the height and width of the client area of the control. (Odziedziczone z Control). | |
CompanyName | Gets the name of the company or creator of the application containing the control. (Odziedziczone z Control). | |
Container | Pobiera IContainer , która zawiera Component. (Odziedziczone z Component). | |
ContainsFocus | Gets a value indicating whether the control, or one of its child controls, currently has the input focus. (Odziedziczone z Control). | |
ContextMenu | Gets or sets the shortcut menu associated with the control. (Odziedziczone z Control). | |
ContextMenuStrip | Gets or sets the ContextMenuStrip associated with this control. (Odziedziczone z Control). | |
Controls | Gets the collection of controls contained within the control. (Odziedziczone z Control). | |
Created | Gets a value indicating whether the control has been created. (Odziedziczone z Control). | |
CurrentAutoScaleDimensions | Gets the current run-time dimensions of the screen. (Odziedziczone z ContainerControl). | |
Cursor | Zwraca lub ustawia kursor, który jest wyświetlany, gdy wskaźnik myszy znajduje się nad ShapeContainer. (Zastępuje Control.Cursor). | |
DataBindings | Gets the data bindings for the control. (Odziedziczone z Control). | |
DisplayRectangle | Pobiera prostokąt, który reprezentuje obszar wyświetlania wirtualnego formantu. (Odziedziczone z ScrollableControl). | |
Disposing | Gets a value indicating whether the base Control class is in the process of disposing. (Odziedziczone z Control). | |
Dock | Pobiera lub ustawia, które obramowania formantu są zadokowane do formantu nadrzędnego i określa, w jaki sposób zostanie zmieniony rozmiar formantu, gdy zmieniany jest rozmiar jego obiektu nadrzędnego. (Zastępuje Control.Dock). | |
DockPadding | Pobiera ustawienia dopełnienia stacji dokującej dla wszystkich krawędzi formantu. (Odziedziczone z ScrollableControl). | |
Enabled | Gets or sets a value indicating whether the control can respond to user interaction. (Odziedziczone z Control). | |
Focused | Gets a value indicating whether the control has input focus. (Odziedziczone z Control). | |
Font | Gets or sets the font of the text displayed by the control. (Odziedziczone z Control). | |
ForeColor | Gets or sets the foreground color of the control. (Odziedziczone z Control). | |
Handle | Gets the window handle that the control is bound to. (Odziedziczone z Control). | |
HasChildren | Gets a value indicating whether the control contains one or more child controls. (Odziedziczone z Control). | |
Height | Gets or sets the height of the control. (Odziedziczone z Control). | |
HorizontalScroll | Pobiera właściwości związane z poziomego paska przewijania. (Odziedziczone z ScrollableControl). | |
ImeMode | Gets or sets the Input Method Editor (IME) mode of the control. (Odziedziczone z Control). | |
InvokeRequired | Gets a value indicating whether the caller must call an invoke method when making method calls to the control because the caller is on a different thread than the one the control was created on. (Odziedziczone z Control). | |
IsAccessible | Gets or sets a value indicating whether the control is visible to accessibility applications. (Odziedziczone z Control). | |
IsDisposed | Gets a value indicating whether the control has been disposed of. (Odziedziczone z Control). | |
IsHandleCreated | Gets a value indicating whether the control has a handle associated with it. (Odziedziczone z Control). | |
IsMirrored | Gets a value indicating whether the control is mirrored. (Odziedziczone z Control). | |
LayoutEngine | Gets a cached instance of the control's layout engine. (Odziedziczone z Control). | |
Left | Gets or sets the distance, in pixels, between the left edge of the control and the left edge of its container's client area. (Odziedziczone z Control). | |
Location | Gets or sets the coordinates of the upper-left corner of the control relative to the upper-left corner of its container. (Odziedziczone z Control). | |
Margin | Gets or sets the space between controls. (Odziedziczone z Control). | |
MaximumSize | Gets or sets the size that is the upper limit that GetPreferredSize can specify. (Odziedziczone z Control). | |
MinimumSize | Gets or sets the size that is the lower limit that GetPreferredSize can specify. (Odziedziczone z Control). | |
Name | Gets or sets the name of the control. (Odziedziczone z Control). | |
Padding | Gets or sets padding within the control. (Odziedziczone z Control). | |
Parent | Gets or sets the parent container of the control. (Odziedziczone z Control). | |
ParentForm | Gets the form that the container control is assigned to. (Odziedziczone z ContainerControl). | |
PreferredSize | Gets the size of a rectangular area into which the control can fit. (Odziedziczone z Control). | |
ProductName | Gets the product name of the assembly containing the control. (Odziedziczone z Control). | |
ProductVersion | Gets the version of the assembly containing the control. (Odziedziczone z Control). | |
RecreatingHandle | Gets a value indicating whether the control is currently re-creating its handle. (Odziedziczone z Control). | |
Region | Gets or sets the window region associated with the control. (Odziedziczone z Control). | |
RenderRightToLeft | Nieaktualne. This property is now obsolete. (Odziedziczone z Control). | |
Right | Gets the distance, in pixels, between the right edge of the control and the left edge of its container's client area. (Odziedziczone z Control). | |
RightToLeft | Gets or sets a value indicating whether control's elements are aligned to support locales using right-to-left fonts. (Odziedziczone z Control). | |
Shapes | Zwraca kolekcję kształtów, które są zawarte w ShapeContainer. | |
ShowFocusCues | Gets a value indicating whether the control should display focus rectangles. (Odziedziczone z Control). | |
ShowKeyboardCues | Gets a value indicating whether the user interface is in the appropriate state to show or hide keyboard accelerators. (Odziedziczone z Control). | |
Site | Gets or sets the site of the control. (Odziedziczone z Control). | |
Size | Gets or sets the height and width of the control. (Odziedziczone z Control). | |
TabIndex | Gets or sets the tab order of the control within its container. (Odziedziczone z Control). | |
TabStop | Gets or sets a value indicating whether the user can give the focus to this control using the TAB key. (Odziedziczone z Control). | |
Tag | Gets or sets the object that contains data about the control. (Odziedziczone z Control). | |
Text | Gets or sets the text associated with this control. (Odziedziczone z UserControl). | |
Top | Gets or sets the distance, in pixels, between the top edge of the control and the top edge of its container's client area. (Odziedziczone z Control). | |
TopLevelControl | Gets the parent control that is not parented by another Windows Forms control.Typically, this is the outermost Form that the control is contained in. (Odziedziczone z Control). | |
UseWaitCursor | Gets or sets a value indicating whether to use the wait cursor for the current control and all child controls. (Odziedziczone z Control). | |
VerticalScroll | Pobiera właściwości związane z pionowego paska przewijania. (Odziedziczone z ScrollableControl). | |
Visible | Gets or sets a value indicating whether the control and all its child controls are displayed. (Odziedziczone z Control). | |
Width | Gets or sets the width of the control. (Odziedziczone z Control). | |
WindowTarget | Infrastruktura. This property is not relevant for this class. (Odziedziczone z Control). |
Początek
Metody
Nazwa | Opis | |
---|---|---|
AccessibilityNotifyClients | Notifies the accessibility client applications of the specified AccessibleEvents for the specified child control. (Odziedziczone z Control). | |
BeginInvoke(Delegate) | Executes the specified delegate asynchronously on the thread that the control's underlying handle was created on. (Odziedziczone z Control). | |
BeginInvoke(Delegate, Object) | Executes the specified delegate asynchronously with the specified arguments, on the thread that the control's underlying handle was created on. (Odziedziczone z Control). | |
BringToFront | Brings the control to the front of the z-order. (Odziedziczone z Control). | |
Contains | Retrieves a value indicating whether the specified control is a child of the control. (Odziedziczone z Control). | |
CreateControl | Forces the creation of the visible control, including the creation of the handle and any visible child controls. (Odziedziczone z Control). | |
CreateGraphics | Creates the Graphics for the control. (Odziedziczone z Control). | |
CreateObjRef | Krytyczny pod względem zabezpieczeń Tworzy obiekt, który zawiera wszystkie istotne informacje wymagane do wygenerowania serwera proxy, używany do komunikowania się z obiektem zdalnym. (Odziedziczone z MarshalByRefObject). | |
Dispose | Zwalnia wszystkie zasoby używane przez Component. (Odziedziczone z Component). | |
DoDragDrop | Begins a drag-and-drop operation. (Odziedziczone z Control). | |
DrawToBitmap | Supports rendering to the specified bitmap. (Odziedziczone z Control). | |
EndInvoke | Retrieves the return value of the asynchronous operation represented by the IAsyncResult passed. (Odziedziczone z Control). | |
Equals | Determines whether the specified object is equal to the current object. (Odziedziczone z Object). | |
FindForm | Retrieves the form that the control is on. (Odziedziczone z Control). | |
Focus | Sets input focus to the control. (Odziedziczone z Control). | |
GetChildAtPoint(Point) | Pobiera kształtu, który znajduje się w określonych współrzędnych. | |
GetChildAtPoint(Point, GetChildAtPointSkip) | Retrieves the child control that is located at the specified coordinates, specifying whether to ignore child controls of a certain type. (Odziedziczone z Control). | |
GetContainerControl | Returns the next ContainerControl up the control's chain of parent controls. (Odziedziczone z Control). | |
GetHashCode | Serves as the default hash function. (Odziedziczone z Object). | |
GetLifetimeService | Krytyczny pod względem zabezpieczeń Pobiera obiekt usługi bieżącego okresu istnienia, który kontroluje politykę okres istnienia dla tego wystąpienia. (Odziedziczone z MarshalByRefObject). | |
GetNextControl | Retrieves the next control forward or back in the tab order of child controls. (Odziedziczone z Control). | |
GetNextShape | Pobiera następne lub poprzednie kształt w kolejności od ShapeCollection. | |
GetPreferredSize | Retrieves the size of a rectangular area into which a control can be fitted. (Odziedziczone z Control). | |
GetType | Gets the Type of the current instance. (Odziedziczone z Object). | |
Hide | Conceals the control from the user. (Odziedziczone z Control). | |
InitializeLifetimeService | Krytyczny pod względem zabezpieczeń Uzyskuje obiekt usługi istnienia kontroli zasad okres istnienia dla tego wystąpienia. (Odziedziczone z MarshalByRefObject). | |
Invalidate | Invalidates the entire surface of the control and causes the control to be redrawn. (Odziedziczone z Control). | |
Invalidate(Region) | Invalidates the specified region 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. (Odziedziczone z Control). | |
Invalidate(Boolean) | Invalidates a specific region of the control and causes a paint message to be sent to the control.Optionally, invalidates the child controls assigned to the control. (Odziedziczone z Control). | |
Invalidate(Rectangle) | Invalidates the specified region 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. (Odziedziczone z Control). | |
Invalidate(Region, Boolean) | Invalidates the specified region 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.Optionally, invalidates the child controls assigned to the control. (Odziedziczone z Control). | |
Invalidate(Rectangle, Boolean) | Invalidates the specified region 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.Optionally, invalidates the child controls assigned to the control. (Odziedziczone z Control). | |
Invoke(Delegate) | Executes the specified delegate on the thread that owns the control's underlying window handle. (Odziedziczone z Control). | |
Invoke(Delegate, Object) | Executes the specified delegate, on the thread that owns the control's underlying window handle, with the specified list of arguments. (Odziedziczone z Control). | |
PerformAutoScale | Performs scaling of the container control and its children. (Odziedziczone z ContainerControl). | |
PerformLayout | Forces the control to apply layout logic to all its child controls. (Odziedziczone z Control). | |
PerformLayout(Control, String) | Forces the control to apply layout logic to all its child controls. (Odziedziczone z Control). | |
PointToClient | Computes the location of the specified screen point into client coordinates. (Odziedziczone z Control). | |
PointToScreen | Computes the location of the specified client point into screen coordinates. (Odziedziczone z Control). | |
PreProcessControlMessage | Preprocesses keyboard or input messages within the message loop before they are dispatched. (Odziedziczone z Control). | |
PreProcessMessage | Preprocesses keyboard or input messages within the message loop before they are dispatched. (Odziedziczone z Control). | |
ProcessKeyMessage | Processes a keyboard message. (Odziedziczone z Control). | |
ProcessMnemonic | Infrastruktura. Processes a mnemonic character. (Odziedziczone z ContainerControl). | |
RectangleToClient | Computes the size and location of the specified screen rectangle in client coordinates. (Odziedziczone z Control). | |
RectangleToScreen | Computes the size and location of the specified client rectangle in screen coordinates. (Odziedziczone z Control). | |
Refresh | Forces the control to invalidate its client area and immediately redraw itself and any child controls. (Odziedziczone z Control). | |
ResetBackColor | Resets the BackColor property to its default value. (Odziedziczone z Control). | |
ResetBindings | Causes a control bound to the BindingSource to reread all the items in the list and refresh their displayed values. (Odziedziczone z Control). | |
ResetCursor | Resets the Cursor property to its default value. (Odziedziczone z Control). | |
ResetFont | Resets the Font property to its default value. (Odziedziczone z Control). | |
ResetForeColor | Resets the ForeColor property to its default value. (Odziedziczone z Control). | |
ResetImeMode | Resets the ImeMode property to its default value. (Odziedziczone z Control). | |
ResetRightToLeft | Resets the RightToLeft property to its default value. (Odziedziczone z Control). | |
ResetText | Resets the Text property to its default value. (Odziedziczone z Control). | |
ResumeLayout | Resumes usual layout logic. (Odziedziczone z Control). | |
ResumeLayout(Boolean) | Resumes usual layout logic, optionally forcing an immediate layout of pending layout requests. (Odziedziczone z Control). | |
RtlTranslateContent | Converts the specified ContentAlignment to the appropriate ContentAlignment to support right-to-left text. (Odziedziczone z Control). | |
Scale(Single) | Nieaktualne. Scales the control and any child controls. (Odziedziczone z Control). | |
Scale(SizeF) | Scales the control and all child controls by the specified scaling factor. (Odziedziczone z Control). | |
Scale(Single, Single) | Nieaktualne. Scales the entire control and any child controls. (Odziedziczone z Control). | |
ScrollControlIntoView | Przewija określonego formantu podrzędnego do wyświetlenia w formancie włączone automatyczne przewijanie. (Odziedziczone z ScrollableControl). | |
Select | Activates the control. (Odziedziczone z Control). | |
SelectNextControl | Activates the next control. (Odziedziczone z Control). | |
SelectNextShape | Zaznacza następny lub poprzedni kształt w kolejności od ShapeCollection. | |
SendToBack | Sends the control to the back of the z-order. (Odziedziczone z Control). | |
SetAutoScrollMargin | Ustawia rozmiar marginesów przewijania automatycznego. (Odziedziczone z ScrollableControl). | |
SetBounds(Int32, Int32, Int32, Int32) | Sets the bounds of the control to the specified location and size. (Odziedziczone z Control). | |
SetBounds(Int32, Int32, Int32, Int32, BoundsSpecified) | Sets the specified bounds of the control to the specified location and size. (Odziedziczone z Control). | |
Show | Displays the control to the user. (Odziedziczone z Control). | |
SuspendLayout | Temporarily suspends the layout logic for the control. (Odziedziczone z Control). | |
ToString | Zwraca String zawierający nazwę Component, jeśli istnieje.Metoda ta nie powinna być pomijana. (Odziedziczone z Component). | |
Update | Causes the control to redraw the invalidated regions within its client area. (Odziedziczone z Control). | |
UpdateBounds | Updates the bounds of the control with the current size and location. (Odziedziczone z Control). | |
Validate | Verifies the value of the control losing focus by causing the Validating and Validated events to occur, in that order. (Odziedziczone z ContainerControl). | |
Validate(Boolean) | Verifies the value of the control that is losing focus; conditionally dependent on whether automatic validation is turned on. (Odziedziczone z ContainerControl). | |
ValidateChildren | Causes all of the child controls within a control that support validation to validate their data. (Odziedziczone z UserControl). | |
ValidateChildren(ValidationConstraints) | Causes all of the child controls within a control that support validation to validate their data. (Odziedziczone z UserControl). |
Początek
Zdarzenia
Nazwa | Opis | |
---|---|---|
AutoSizeChanged | Occurs when the AutoSize property changes. (Odziedziczone z UserControl). | |
AutoValidateChanged | Occurs when the AutoValidate property changes. (Odziedziczone z UserControl). | |
BackColorChanged | Occurs when the value of the BackColor property changes. (Odziedziczone z Control). | |
BackgroundImageChanged | Occurs when the value of the BackgroundImage property changes. (Odziedziczone z Control). | |
BackgroundImageLayoutChanged | Occurs when the BackgroundImageLayout property changes. (Odziedziczone z Control). | |
BindingContextChanged | Occurs when the value of the BindingContext property changes. (Odziedziczone z Control). | |
CausesValidationChanged | Occurs when the value of the CausesValidation property changes. (Odziedziczone z Control). | |
ChangeUICues | Occurs when the focus or keyboard user interface (UI) cues change. (Odziedziczone z Control). | |
Click | Occurs when the control is clicked. (Odziedziczone z Control). | |
ClientSizeChanged | Occurs when the value of the ClientSize property changes. (Odziedziczone z Control). | |
ContextMenuChanged | Occurs when the value of the ContextMenu property changes. (Odziedziczone z Control). | |
ContextMenuStripChanged | Occurs when the value of the ContextMenuStrip property changes. (Odziedziczone z Control). | |
ControlAdded | Occurs when a new control is added to the ControlCollection. (Odziedziczone z Control). | |
ControlRemoved | Occurs when a control is removed from the ControlCollection. (Odziedziczone z Control). | |
CursorChanged | Occurs when the value of the Cursor property changes. (Odziedziczone z Control). | |
Disposed | Występuje, gdy składnik jest usuwany przez wywołanie do Dispose metody. (Odziedziczone z Component). | |
DockChanged | Occurs when the value of the Dock property changes. (Odziedziczone z Control). | |
DoubleClick | Occurs when the control is double-clicked. (Odziedziczone z Control). | |
DragDrop | Occurs when a drag-and-drop operation is completed. (Odziedziczone z Control). | |
DragEnter | Occurs when an object is dragged into the control's bounds. (Odziedziczone z Control). | |
DragLeave | Occurs when an object is dragged out of the control's bounds. (Odziedziczone z Control). | |
DragOver | Occurs when an object is dragged over the control's bounds. (Odziedziczone z Control). | |
EnabledChanged | Occurs when the Enabled property value has changed. (Odziedziczone z Control). | |
Enter | Occurs when the control is entered. (Odziedziczone z Control). | |
FontChanged | Occurs when the Font property value changes. (Odziedziczone z Control). | |
ForeColorChanged | Occurs when the ForeColor property value changes. (Odziedziczone z Control). | |
GiveFeedback | Occurs during a drag operation. (Odziedziczone z Control). | |
GotFocus | Occurs when the control receives focus. (Odziedziczone z Control). | |
HandleCreated | Occurs when a handle is created for the control. (Odziedziczone z Control). | |
HandleDestroyed | Occurs when the control's handle is in the process of being destroyed. (Odziedziczone z Control). | |
HelpRequested | Occurs when the user requests help for a control. (Odziedziczone z Control). | |
ImeModeChanged | Occurs when the ImeMode property has changed. (Odziedziczone z Control). | |
Invalidated | Occurs when a control's display requires redrawing. (Odziedziczone z Control). | |
KeyDown | Occurs when a key is pressed while the control has focus. (Odziedziczone z Control). | |
KeyPress | Occurs when a character.space or backspace key is pressed while the control has focus. (Odziedziczone z Control). | |
KeyUp | Occurs when a key is released while the control has focus. (Odziedziczone z Control). | |
Layout | Occurs when a control should reposition its child controls. (Odziedziczone z Control). | |
Leave | Occurs when the input focus leaves the control. (Odziedziczone z Control). | |
Load | Occurs before the control becomes visible for the first time. (Odziedziczone z UserControl). | |
LocationChanged | Occurs when the Location property value has changed. (Odziedziczone z Control). | |
LostFocus | Occurs when the control loses focus. (Odziedziczone z Control). | |
MarginChanged | Occurs when the control's margin changes. (Odziedziczone z Control). | |
MouseCaptureChanged | Occurs when the control loses mouse capture. (Odziedziczone z Control). | |
MouseClick | Occurs when the control is clicked by the mouse. (Odziedziczone z Control). | |
MouseDoubleClick | Occurs when the control is double clicked by the mouse. (Odziedziczone z Control). | |
MouseDown | Occurs when the mouse pointer is over the control and a mouse button is pressed. (Odziedziczone z Control). | |
MouseEnter | Occurs when the mouse pointer enters the control. (Odziedziczone z Control). | |
MouseHover | Occurs when the mouse pointer rests on the control. (Odziedziczone z Control). | |
MouseLeave | Occurs when the mouse pointer leaves the control. (Odziedziczone z Control). | |
MouseMove | Occurs when the mouse pointer is moved over the control. (Odziedziczone z Control). | |
MouseUp | Occurs when the mouse pointer is over the control and a mouse button is released. (Odziedziczone z Control). | |
MouseWheel | Occurs when the mouse wheel moves while the control has focus. (Odziedziczone z Control). | |
Move | Occurs when the control is moved. (Odziedziczone z Control). | |
PaddingChanged | Occurs when the control's padding changes. (Odziedziczone z Control). | |
Paint | Occurs when the control is redrawn. (Odziedziczone z Control). | |
ParentChanged | Occurs when the Parent property value changes. (Odziedziczone z Control). | |
PreviewKeyDown | Occurs before the KeyDown event when a key is pressed while focus is on this control. (Odziedziczone z Control). | |
QueryAccessibilityHelp | Occurs when AccessibleObject is providing help to accessibility applications. (Odziedziczone z Control). | |
QueryContinueDrag | Occurs during a drag-and-drop operation and enables the drag source to determine whether the drag-and-drop operation should be canceled. (Odziedziczone z Control). | |
RegionChanged | Occurs when the value of the Region property changes. (Odziedziczone z Control). | |
Resize | Occurs when the control is resized. (Odziedziczone z Control). | |
RightToLeftChanged | Occurs when the RightToLeft property value changes. (Odziedziczone z Control). | |
Scroll | Występuje, gdy użytkownik lub kod Przewija obszaru klienckiego. (Odziedziczone z ScrollableControl). | |
SizeChanged | Occurs when the Size property value changes. (Odziedziczone z Control). | |
StyleChanged | Occurs when the control style changes. (Odziedziczone z Control). | |
SystemColorsChanged | Occurs when the system colors change. (Odziedziczone z Control). | |
TabIndexChanged | Occurs when the TabIndex property value changes. (Odziedziczone z Control). | |
TabStopChanged | Occurs when the TabStop property value changes. (Odziedziczone z Control). | |
TextChanged | Infrastruktura. Raises the TextChanged event. (Odziedziczone z UserControl). | |
Validated | Occurs when the control is finished validating. (Odziedziczone z Control). | |
Validating | Occurs when the control is validating. (Odziedziczone z Control). | |
VisibleChanged | Occurs when the Visible property value changes. (Odziedziczone z Control). |
Początek
Jawne implementacje interfejsu
Nazwa | Opis | |
---|---|---|
System#Windows#Forms#IContainerControl#ActivateControl | Activates the specified control. (Odziedziczone z ContainerControl). | |
System#Windows#Forms#IDropTarget#OnDragDrop | Infrastruktura. Raises the DragDrop event. (Odziedziczone z Control). | |
System#Windows#Forms#IDropTarget#OnDragEnter | Infrastruktura. Raises the DragEnter event. (Odziedziczone z Control). | |
System#Windows#Forms#IDropTarget#OnDragLeave | Infrastruktura. Raises the DragLeave event. (Odziedziczone z Control). | |
System#Windows#Forms#IDropTarget#OnDragOver | Infrastruktura. Raises the DragOver event. (Odziedziczone z Control). |
Początek
Uwagi
A LineShape, OvalShape, lub RectangleShape kontroli, które mogą być zawarte wyłącznie w ShapeContainer obiekt, który działa jako obszaru roboczego dla linii i kształtów formantów.
Po dodaniu linii lub kształtu do formularza lub kontenera w czasie projektowania, ShapeContainer jest tworzona automatycznie, jeśli już nie istnieje.Parent Właściwość linię lub kształt jest ustawiona do tego ShapeContainer.Parent Właściwość ShapeContainer jest ustawiona do formantu formularza lub kontener, do którego dodano linię lub kształt.
Po utworzeniu linii lub kształtu w czasie wykonywania za pomocą New metody, formantu Parent właściwość musi być ustawiona na ShapeContainer.Jeśli ShapeContainer już istnieje dla formularza lub kontenera, należy ustawić Parent właściwość, która ShapeContainer.Jeśli nie ShapeContainer istnieje, można utworzyć ShapeContainer za pomocą New metody i ustawianie jej Parent właściwości formularza lub kontenera.
[!UWAGA]
Należy uważać, że nie utworzysz więcej niż jeden ShapeContainer dla każdego formularza lub kontenera; w ten sposób mogą wprowadzić nieoczekiwane zachowanie.Po dodaniu linii w czasie projektowania lub formant kształtu do formularza lub kontenera po pisać kod, aby utworzyć programowo, należy modyfikować kodu w celu użycia ShapeContainer utworzone przez projektanta.
Przykłady
Poniższy przykład sprawdza, czy istniejący ShapeContainer i ustawia Parent właściwość OvalShape kontroli utworzone w czasie wykonywania za pomocą New metody.
Private Sub Form1_Load() Handles MyBase.Load
Dim NewOval As New OvalShape
Dim i As Integer
Dim found As Boolean
' Loop through the Controls collection.
For i = 0 To Me.Controls.Count - 1
' If a ShapeContainer is found, make it the parent.
If TypeOf Controls.Item(i) Is ShapeContainer Then
NewOval.Parent = Controls.Item(i)
found = True
Exit For
End If
Next
' If no ShapeContainer is found, create one and set the parents.
If found = False Then
Dim sc As New ShapeContainer
sc.Parent = Me
NewOval.Parent = sc
End If
NewOval.Size = New Size(200, 300)
End Sub
private void form1_Load(System.Object sender, System.EventArgs e)
{
OvalShape NewOval = new OvalShape();
int i;
bool found = false;
// Loop through the Controls collection.
for (i = 0; i < this.Controls.Count; i++)
{
// If a ShapeContainer is found, make it the parent.
if (this.Controls[i] is ShapeContainer)
{
NewOval.Parent = ((ShapeContainer)this.Controls[i]);
found = true;
break;
}
}
// If no ShapeContainer is found, create one and set the parents.
if (found == false)
{
ShapeContainer sc = new ShapeContainer();
sc.Parent = this;
NewOval.Parent = sc;
}
NewOval.Size = new Size(200, 300);
}
Bezpieczeństwo wątku
Wszystkie publiczne static (Shared w języku Visual Basic) elementy członkowskie tego typu są bezpieczne dla wątków. Wystąpienia elementów członkowskich nie dają gwarancji bezpieczeństwa wątków.
Zobacz też
Informacje
Przestrzeń nazw Microsoft.VisualBasic.PowerPacks
Inne zasoby
Linie i kształty — Wprowadzenie do formantów (Visual Studio)
Porady: rysowanie linii za pomocą formantów LineShape (Visual Studio)
Porady: rysowanie kształtów za pomocą formantów OvalShape i RectangleShape (Visual Studio)