ctlUniCanvas ControlUnicode API window that you can use like a normal Device Context.
|
Name | Description |
---|---|
eUniCanvas_BorderStyle | Border Style |
Name | Description |
---|---|
Paint | |
KeyDown | check here for details |
KeyPress | check here for details |
KeyUp | check here for details |
Click | |
DblClick | |
MouseDown | |
MouseMove | |
MouseUp | |
MouseWheel | Raised when the mouse wheel scrolls |
CanvasGotFocus | Raised when the control gets the focus. This works, the VB6 one doesn't. |
CanvasLostFocus | Raised when the control loses the focus. This works, the VB6 one doesn't. |
Resize | |
IMEComposition | Raised when the user confirms a string in the IME editor, check here for details |
OLEStartDrag | |
OLESetData | |
OLEGiveFeedback | |
OLEDragOver | |
OLEDragDrop | |
OLECompleteDrag |
Name | Type | Description |
---|---|---|
BackColorOut | (OLE_COLOR) | Gets or sets the Color of the area out of the border (when using Rounded Borders in a non WindowLess control) Leave -1& for automatic management |
BorderColor | (OLE_COLOR) | Gets or sets the Border color |
BorderStyle | (eUniCanvas_BorderStyle) | Gets or sets the Border Style of the control |
ClientHeight | (Long) | Returns the height of the client area |
ClientWidth | (Long) | Returns the width of the client area |
Enabled | (Boolean) | Enables or disables the control |
Font | (Font) | Gets or sets the font used for text in the control, check the [ApplyFontChanges] for details |
MouseIcon | (Picture) | Gets or sets the MouseIcon for the control |
MousePointer | (VBRUN.MousePointerConstants) | Gets or sets the MousePointer for the control |
OLEDropMode | (eCtlOLEDropMode) | Gets or sets the OleDropMode for the control |
RightToLeft | (Boolean) | Gets or sets the ability to show bidirectional text on the control |
RoundedBorders | (Boolean) | Gets or sets Rounded borders |
Tip | (String) | Gets or sets the Unicode Tooltip for the control |
TrapTabKey | (Boolean) | Gets or sets the ability for the control to catch Tab keys |
UseMouseSetCapture | (Boolean) | Permits you to capture the mouse movements even if the mouse is out of the control (when pressing the mouse button into the control and then exiting from it maintaining the button pressed) like a normal PictureBox control |
UseRoundRegions | (Boolean) | Gets or sets the ability to use Round Regions for round borders instead of using the [BackColorOut] property; |
Name | Type | Description |
---|---|---|
ApplyFontChanges | When setting a new font on the control you need to call this function in order to refresh the interface | |
hWnd | (Long) | Retuns the handle associated with the control |
IsInIME | (Boolean) | You can use this property for knowing if the KeyPress, KeyDown and KeyUp events have been raised by the active IME window associated to your control. |
OLEDrag | Starts an OLEDrag operation | |
Refresh | Invalidates the client area of the control |
Private oMemDC As New clsMEMDC
Private oWrap As New clsCommonWrapper
Private Sub Form_Load()
'Create the memory DC
oMemDC.CreateDC ctlUniCanvas1.ClientWidth, _
ctlUniCanvas1.ClientHeight
'Draw into DC using Windows API
oWrap.DrawRectCoords oMemDC.Hdc, 0, 0, 100, 100, vbRed, True
End Sub
Private Sub ctlUniCanvas1_Paint(lHDC As Long)
'Draw the memory DC to the visible DC
oMemDC.PaintPicture lHDC
End Sub